| 94 | } |
| 95 | |
| 96 | void MidiOutputModule::PlayNote(double time, int pitch, int velocity, int voiceIdx, ModulationParameters modulation) |
| 97 | { |
| 98 | int channel = voiceIdx + 1; |
| 99 | if (voiceIdx == -1) |
| 100 | channel = 1; |
| 101 | channel = mUseVoiceAsChannel ? channel : mChannel; |
| 102 | |
| 103 | mDevice.SendNote(time, pitch, velocity, false, channel); |
| 104 | |
| 105 | int modIdx = channel - 1; |
| 106 | if (voiceIdx == -1) |
| 107 | modIdx = kGlobalModulationIdx; |
| 108 | |
| 109 | mChannelModulations[modIdx].mModulation = modulation; |
| 110 | } |
| 111 | |
| 112 | void MidiOutputModule::SendCC(int control, int value, int voiceIdx /*=-1*/) |
| 113 | { |