mirror of
https://github.com/yokemura/Magical8bitPlug2.git
synced 2025-07-17 11:04:16 -04:00
Fixed: Sound never stops when MIDI channels of note-on and note-off are different
This commit is contained in:
@ -98,8 +98,9 @@ void TonalVoice::controllerMoved (int type, int amount)
|
||||
}
|
||||
|
||||
|
||||
void TonalVoice::setLegatoMode(double time) {
|
||||
void TonalVoice::setLegatoMode(double time, int midiCh) {
|
||||
portamentoTime = time;
|
||||
primaryMidiChannel = midiCh;
|
||||
}
|
||||
|
||||
// The interface says "add" but the implementation is just using the latest value.
|
||||
@ -128,13 +129,14 @@ int TonalVoice::removeLegatoNote(int midiNoteNumber) {
|
||||
}
|
||||
|
||||
|
||||
void TonalVoice::setArpeggioMode(double interval)
|
||||
void TonalVoice::setArpeggioMode(double interval, int midiCh)
|
||||
{
|
||||
arpeggioFrameLength = interval;
|
||||
arpeggioFrameTimer = 0;
|
||||
currentArpeggioFrame = 0;
|
||||
currentNumNoteBuffer = 1;
|
||||
noteBuffer[0] = noteNumber;
|
||||
primaryMidiChannel = midiCh;
|
||||
}
|
||||
|
||||
void TonalVoice::addArpeggioNoteAscending(int midiNoteNumber)
|
||||
|
Reference in New Issue
Block a user