RCS file: /cvsroot/scummvm/scummvm/scumm/imuse.cpp,v
retrieving revision 2.128
diff -u -r2.128 imuse.cpp
|
|
|
1531 | 1531 | mc = _player->getMidiDriver()->getPercussionChannel(); |
1532 | 1532 | if (!mc) |
1533 | 1533 | return; |
1534 | | mc->volume(_vol_eff); |
1535 | | // mc->programChange(_bank); |
| 1534 | static byte prev_vol_eff = 128; |
| 1535 | if (_vol_eff != prev_vol_eff){ |
| 1536 | mc->volume(_vol_eff); |
| 1537 | prev_vol_eff = _vol_eff; |
| 1538 | } |
| 1539 | if ((note < 35) && (!_player->_se->isNativeMT32())) |
| 1540 | note = Instrument::_gmRhythmMap[note]; |
| 1541 | |
1536 | 1542 | mc->noteOn(note, velocity); |
1537 | 1543 | } |
1538 | 1544 | } |
RCS file: /cvsroot/scummvm/scummvm/scumm/instrument.cpp,v
retrieving revision 2.31
diff -u -r2.31 instrument.cpp
|
|
|
114 | 115 | // { "trickle4 ", ??? } |
115 | 116 | }; |
116 | 117 | |
| 118 | const byte Instrument::_gmRhythmMap[35] = { |
| 119 | 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, |
| 120 | 0, 0, 0, 0, 0, 0, 0, 0, 36, 37, 38, 39, 40, 41, 66, 47, |
| 121 | 65, 48, 56}; |
| 122 | // This emulates the percussion bank setup LEC used with the MT-32, |
| 123 | // where notes 24 - 34 were assigned instruments without reverb. |
| 124 | // It also fixes problems on GS devices that map sounds to these |
| 125 | // notes by default. |
| 126 | |
117 | 127 | class Instrument_Program : public InstrumentInternal { |
118 | 128 | private: |
119 | 129 | byte _program; |
RCS file: /cvsroot/scummvm/scummvm/scumm/instrument.h,v
retrieving revision 2.14
diff -u -r2.14 instrument.h
|
|
|
57 | 57 | Instrument() : _type (0), _instrument (0) { } |
58 | 58 | ~Instrument() { delete _instrument; } |
59 | 59 | static void nativeMT32 (bool native); |
| 60 | static const byte _gmRhythmMap[35]; |
60 | 61 | |
61 | 62 | void clear(); |
62 | 63 | void copy_to (Instrument *dest) { if (_instrument) _instrument->copy_to (dest); else dest->clear(); } |