aboutsummaryrefslogtreecommitdiff
path: root/engines/sci
diff options
context:
space:
mode:
authorFilippos Karapetis2010-11-25 22:23:14 +0000
committerFilippos Karapetis2010-11-25 22:23:14 +0000
commitaf15ac6f6aa693ee0dd1222ee892d63432661c8c (patch)
tree7d61aadaf8fc7a488ec03d811b65862869705a03 /engines/sci
parent3a8648c4db69160e31e2d9b59f40e192a5060514 (diff)
downloadscummvm-rg350-af15ac6f6aa693ee0dd1222ee892d63432661c8c.tar.gz
scummvm-rg350-af15ac6f6aa693ee0dd1222ee892d63432661c8c.tar.bz2
scummvm-rg350-af15ac6f6aa693ee0dd1222ee892d63432661c8c.zip
SCI: Some reverb-related changes in the MIDI driver, based on a patch by waltervn
svn-id: r54484
Diffstat (limited to 'engines/sci')
-rw-r--r--engines/sci/sound/drivers/midi.cpp12
1 files changed, 8 insertions, 4 deletions
diff --git a/engines/sci/sound/drivers/midi.cpp b/engines/sci/sound/drivers/midi.cpp
index 2627f0728c..05d88e5436 100644
--- a/engines/sci/sound/drivers/midi.cpp
+++ b/engines/sci/sound/drivers/midi.cpp
@@ -385,10 +385,11 @@ int MidiPlayer_Midi::getVolume() {
void MidiPlayer_Midi::setReverb(int8 reverb) {
assert(reverb < kReverbConfigNr);
- _reverb = reverb;
+
+ if (_hasReverb && (_reverb != reverb))
+ sendMt32SysEx(0x100001, _reverbConfig[reverb], 3, true);
- if (_hasReverb)
- sendMt32SysEx(0x100001, _reverbConfig[_reverb], 3, true);
+ _reverb = reverb;
}
void MidiPlayer_Midi::playSwitch(bool play) {
@@ -477,7 +478,10 @@ void MidiPlayer_Midi::readMt32Patch(const byte *data, int size) {
setMt32Volume(volume);
// Reverb default only used in (roughly) SCI0/SCI01
- _reverb = str->readByte();
+ byte reverb = str->readByte();
+ if (_version <= SCI_VERSION_0_LATE)
+ setReverb(reverb);
+
_hasReverb = true;
// Skip reverb SysEx message