diff options
author | Tim E. Real <termtech@rogers.com> | 2013-02-02 07:37:31 +0000 |
---|---|---|
committer | Tim E. Real <termtech@rogers.com> | 2013-02-02 07:37:31 +0000 |
commit | f118ed0cfca8ab717b87e1f00459199acba80bb9 (patch) | |
tree | 7a5a46771dcea1a978182d0da0134e6a5d049745 /muse2/muse/mididev.cpp | |
parent | 5d8ab88bd418da3a4047b38707b5a49f32e912ba (diff) |
Solved: "Old style" Drums: Track channel/port re-enabled, drum list columns default to them.
Required some icon and colour changes. See ChangeLog.
Fixed Old Style Drum lockup: Certain item channel overrides caused infinite loop in Audio::processMidi().
Diffstat (limited to 'muse2/muse/mididev.cpp')
-rw-r--r-- | muse2/muse/mididev.cpp | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/muse2/muse/mididev.cpp b/muse2/muse/mididev.cpp index 46db236a..8657991f 100644 --- a/muse2/muse/mididev.cpp +++ b/muse2/muse/mididev.cpp @@ -730,9 +730,16 @@ void MidiDevice::handleSeek() drum_found = true; for(int i = 0; i < DRUM_MAPSIZE; ++i) { - if(MusEGlobal::drumMap[i].port != _port || usedChans[MusEGlobal::drumMap[i].channel]) + // Default to track port if -1 and track channel if -1. + int mport = MusEGlobal::drumMap[i].port; + if(mport == -1) + mport = (*imt)->outPort(); + int mchan = MusEGlobal::drumMap[i].channel; + if(mchan == -1) + mchan = (*imt)->outChannel(); + if(mport != _port || usedChans[mchan]) continue; - usedChans[MusEGlobal::drumMap[i].channel] = true; + usedChans[mchan] = true; ++usedChanCount; if(usedChanCount >= MIDI_CHANNELS) break; // All are used, done searching. |