| 20 | } |
| 21 | |
| 22 | void CtrlrPanelProcessor::processBlock(MidiBuffer &midiMessages, MidiBuffer &leftoverBuffer, const AudioPlayHead::CurrentPositionInfo &info) |
| 23 | { |
| 24 | if (owner.getMidiOptionBool(panelMidiInputFromHostCompare)) |
| 25 | { |
| 26 | owner.getMIDIInputThread().handleMIDIFromHost(midiMessages); |
| 27 | } |
| 28 | |
| 29 | leftoverBuffer.clear(); |
| 30 | |
| 31 | processLua(midiMessages, info); |
| 32 | |
| 33 | MidiBuffer::Iterator i(midiMessages); |
| 34 | MidiMessage m; |
| 35 | int time; |
| 36 | |
| 37 | while (i.getNextEvent(m,time)) |
| 38 | { |
| 39 | _MIN("VST INPUT", m, time); |
| 40 | if (owner.getMidiOptionBool(panelMidiThruH2D) == true) |
| 41 | { |
| 42 | if (owner.getMidiOptionBool(panelMidiThruH2DChannelize)) |
| 43 | { |
| 44 | m.setChannel (owner.getMidiChannel(panelMidiOutputChannelDevice)); |
| 45 | } |
| 46 | |
| 47 | owner.sendMidi(m); |
| 48 | } |
| 49 | |
| 50 | if (owner.getMidiOptionBool(panelMidiThruH2H) == true) |
| 51 | { |
| 52 | if (owner.getMidiOptionBool(panelMidiThruH2HChannelize)) |
| 53 | { |
| 54 | m.setChannel (owner.getMidiChannel(panelMidiOutputChannelHost)); |
| 55 | } |
| 56 | |
| 57 | leftoverBuffer.addEvent (m, time); |
| 58 | } |
| 59 | } |
| 60 | } |
| 61 | |
| 62 | void CtrlrPanelProcessor::midiOptionChanged(const CtrlrPanelMidiOption optionThatChanged) |
| 63 | { |
nothing calls this directly
no test coverage detected