diff options
author | Max Horn | 2002-09-24 23:45:25 +0000 |
---|---|---|
committer | Max Horn | 2002-09-24 23:45:25 +0000 |
commit | 1bfaa3c02f0a3fb56c581fc204b644d457d45ae0 (patch) | |
tree | 609f369bda19b6c5a6753dade1e87baf34854327 /sound/mididrv.cpp | |
parent | 77d62a61d7d9a4256a24cc37057f515d123ecfeb (diff) | |
download | scummvm-rg350-1bfaa3c02f0a3fb56c581fc204b644d457d45ae0.tar.gz scummvm-rg350-1bfaa3c02f0a3fb56c581fc204b644d457d45ae0.tar.bz2 scummvm-rg350-1bfaa3c02f0a3fb56c581fc204b644d457d45ae0.zip |
removed even the last traces of Scumm dependencies from NewGUI. Yes, you heard right NewGUI is now 100% Scumm free and we can go for the launcher/message dialogs!
svn-id: r5016
Diffstat (limited to 'sound/mididrv.cpp')
-rw-r--r-- | sound/mididrv.cpp | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/sound/mididrv.cpp b/sound/mididrv.cpp index 0738436470..a0190488d8 100644 --- a/sound/mididrv.cpp +++ b/sound/mididrv.cpp @@ -87,7 +87,7 @@ void MidiDriver_WIN::set_stream_callback(void *param, StreamCallback *sc) } void CALLBACK MidiDriver_WIN::midi_callback(HMIDIOUT hmo, UINT wMsg, - DWORD dwInstance, DWORD dwParam1, DWORD dwParam2) + DWORD dwInstance, DWORD dwParam1, DWORD dwParam2) { switch (wMsg) { @@ -111,13 +111,26 @@ int MidiDriver_WIN::open(int mode) MMRESULT res = midiOutOpen((HMIDIOUT *) & _mo, MIDI_MAPPER, NULL, NULL, 0); if (res != MMSYSERR_NOERROR) check_error(res); + + // Send initial pitch bend sensitivity values for +/- 12 semitones. + // For information on control change registered parameters, + // which includes the Pitch Bend sensitivity settings, + // visit http://www.midi.org/about-midi/table3.htm, + // Table 3a. + int chan; + for (chan = 0; chan < 16; ++chan) { + send(( 0 << 16) | (101 << 8) | (0xB0 | chan)); + send(( 0 << 16) | (100 << 8) | (0xB0 | chan)); + send((12 << 16) | ( 6 << 8) | (0xB0 | chan)); + send(( 0 << 16) | ( 38 << 8) | (0xB0 | chan)); + } // next for } else { /* streaming mode */ MIDIPROPTIMEDIV mptd; UINT _midi_device_id = 0; check_error(midiStreamOpen(&_ms, &_midi_device_id, 1, - (uint32)midi_callback, (uint32)this, CALLBACK_FUNCTION)); + (uint32)midi_callback, (uint32)this, CALLBACK_FUNCTION)); prepare(); |