diff options
author | Filippos Karapetis | 2010-11-27 17:29:42 +0000 |
---|---|---|
committer | Filippos Karapetis | 2010-11-27 17:29:42 +0000 |
commit | 49afe9ccffbf9f0bc9416f925a6b56bfdb02db7d (patch) | |
tree | 02998ae4274c0240eb68af5d79a89bc80584850e /engines/sci | |
parent | 0d4ef4854a381e0b206a966e8d0a081b44d2a1df (diff) | |
download | scummvm-rg350-49afe9ccffbf9f0bc9416f925a6b56bfdb02db7d.tar.gz scummvm-rg350-49afe9ccffbf9f0bc9416f925a6b56bfdb02db7d.tar.bz2 scummvm-rg350-49afe9ccffbf9f0bc9416f925a6b56bfdb02db7d.zip |
SCI: Fix for bug #3119713 - "PQ2: song-specific reverb changes are ignored" (thanks to waltervn)
svn-id: r54509
Diffstat (limited to 'engines/sci')
-rw-r--r-- | engines/sci/sound/midiparser_sci.cpp | 31 |
1 files changed, 19 insertions, 12 deletions
diff --git a/engines/sci/sound/midiparser_sci.cpp b/engines/sci/sound/midiparser_sci.cpp index c65e144704..c9f132fc5e 100644 --- a/engines/sci/sound/midiparser_sci.cpp +++ b/engines/sci/sound/midiparser_sci.cpp @@ -495,19 +495,26 @@ void MidiParser_SCI::parseNextEvent(EventInfo &info) { case 0xB: info.basic.param1 = *(_position._play_pos++); info.basic.param2 = *(_position._play_pos++); - if (info.channel() == 0xF) {// SCI special - // Reference for some events: - // http://wiki.scummvm.org/index.php/SCI/Specifications/Sound/SCI0_Resource_Format#Status_Reference - // Also, sci/sound/iterator/iterator.cpp, function BaseSongIterator::parseMidiCommand() - switch (info.basic.param1) { - case kSetReverb: - if (info.basic.param2 == 127) // Set global reverb instead - _pSnd->reverb = _music->getGlobalReverb(); - else - _pSnd->reverb = info.basic.param2; - ((MidiPlayer *)_driver)->setReverb(_pSnd->reverb); - break; + // Reference for some events: + // http://wiki.scummvm.org/index.php/SCI/Specifications/Sound/SCI0_Resource_Format#Status_Reference + // Handle common special events + switch (info.basic.param1) { + case kSetReverb: + if (info.basic.param2 == 127) // Set global reverb instead + _pSnd->reverb = _music->getGlobalReverb(); + else + _pSnd->reverb = info.basic.param2; + + ((MidiPlayer *)_driver)->setReverb(_pSnd->reverb); + break; + default: + break; + } + + // Handle events sent to the SCI special channel (15) + if (info.channel() == 0xF) { + switch (info.basic.param1) { case kMidiHold: // Check if the hold ID marker is the same as the hold ID // marker set for that song by cmdSetSoundHold. |