diff options
author | athrxx | 2011-05-08 18:19:51 +0200 |
---|---|---|
committer | Willem Jan Palenstijn | 2011-05-17 20:36:32 +0200 |
commit | baaae9d97a92da28ec8d8293a391cbca955cbbea (patch) | |
tree | 9b849c968ad9bd15e27b8cdf676e81923aeeffcd | |
parent | 8fb5906117c67f4265e868b33aa343698bceac73 (diff) | |
download | scummvm-rg350-baaae9d97a92da28ec8d8293a391cbca955cbbea.tar.gz scummvm-rg350-baaae9d97a92da28ec8d8293a391cbca955cbbea.tar.bz2 scummvm-rg350-baaae9d97a92da28ec8d8293a391cbca955cbbea.zip |
SCUMM: Add missing imuse feature
This adds an extra detune parameter which is assigned via sysex code 0.
Most tracks don't use this (= assign a value of 0), so it isn't really a
very noticeable feature.
-rw-r--r-- | engines/scumm/imuse/sysex_scumm.cpp | 1 | ||||
-rw-r--r-- | engines/scumm/scumm.cpp | 8 | ||||
-rw-r--r-- | engines/scumm/sound.cpp | 2 |
3 files changed, 4 insertions, 7 deletions
diff --git a/engines/scumm/imuse/sysex_scumm.cpp b/engines/scumm/imuse/sysex_scumm.cpp index d6cf2e1a08..6ab71c2fa5 100644 --- a/engines/scumm/imuse/sysex_scumm.cpp +++ b/engines/scumm/imuse/sysex_scumm.cpp @@ -72,6 +72,7 @@ void sysexHandler_Scumm(Player *player, const byte *msg, uint16 len) { part->volume((p[5] & 0x0F) << 4 |(p[6] & 0x0F)); part->set_pan((p[7] & 0x0F) << 4 | (p[8] & 0x0F)); part->_percussion = player->_isMIDI ? ((p[9] & 0x08) > 0) : false; + part->set_detune((p[11] & 0x0F) << 4 | (p[12] & 0x0F)); part->pitchBendFactor((p[13] & 0x0F) << 4 | (p[14] & 0x0F)); if (part->_percussion) { if (part->_mc) { diff --git a/engines/scumm/scumm.cpp b/engines/scumm/scumm.cpp index c37ff25977..e8dd6cb548 100644 --- a/engines/scumm/scumm.cpp +++ b/engines/scumm/scumm.cpp @@ -1833,12 +1833,8 @@ void ScummEngine::setupMusic(int midi) { if (nativeMidiDriver != NULL && _native_mt32) nativeMidiDriver->property(MidiDriver::PROP_CHANNEL_MASK, 0x03FE); bool multi_midi = ConfMan.getBool("multi_midi") && _musicType != MDT_NONE && (midi & MDT_ADLIB); - if (_musicType == MDT_ADLIB || multi_midi) { - adlibMidiDriver = MidiDriver::createMidi(MidiDriver::detectDevice(MDT_ADLIB)); - adlibMidiDriver->property(MidiDriver::PROP_OLD_ADLIB, (_game.features & GF_SMALL_HEADER) ? 1 : 0); - } - if (_musicType == MDT_TOWNS) { - adlibMidiDriver = MidiDriver::createMidi(MidiDriver::detectDevice(MDT_TOWNS)); + if (_musicType == MDT_ADLIB || MDT_TOWNS || multi_midi) { + adlibMidiDriver = MidiDriver::createMidi(MidiDriver::detectDevice(_musicType == MDT_TOWNS ? MDT_TOWNS : MDT_ADLIB)); adlibMidiDriver->property(MidiDriver::PROP_OLD_ADLIB, (_game.features & GF_SMALL_HEADER) ? 1 : 0); } diff --git a/engines/scumm/sound.cpp b/engines/scumm/sound.cpp index 9d14c1688a..c22da8e7c7 100644 --- a/engines/scumm/sound.cpp +++ b/engines/scumm/sound.cpp @@ -1118,7 +1118,7 @@ int ScummEngine::readSoundResource(ResId idx) { break; case MKTAG('A','D','L',' '): pri = 1; - if (_musicType == MDT_ADLIB) + if (_musicType == MDT_ADLIB || _musicType == MDT_TOWNS) pri = 10; break; case MKTAG('A','M','I',' '): |