Merge pull request #1113 from paulfd/keyswitch-cc-140
Last keyswitches don't change the midi state
This commit is contained in:
commit
18d55a0263
1 changed files with 8 additions and 2 deletions
|
|
@ -1262,7 +1262,10 @@ void Synth::hdNoteOn(int delay, int noteNumber, float normalizedVelocity) noexce
|
|||
ASSERT(noteNumber >= 0);
|
||||
Impl& impl = *impl_;
|
||||
ScopedTiming logger { impl.dispatchDuration_, ScopedTiming::Operation::addToDuration };
|
||||
impl.resources_.getMidiState().noteOnEvent(delay, noteNumber, normalizedVelocity);
|
||||
|
||||
if (impl.lastKeyswitchLists_[noteNumber].empty())
|
||||
impl.resources_.getMidiState().noteOnEvent(delay, noteNumber, normalizedVelocity);
|
||||
|
||||
impl.noteOnDispatch(delay, noteNumber, normalizedVelocity);
|
||||
}
|
||||
|
||||
|
|
@ -1283,7 +1286,10 @@ void Synth::hdNoteOff(int delay, int noteNumber, float normalizedVelocity) noexc
|
|||
// way in sfz to specify that a release trigger should NOT use the note-on velocity?
|
||||
// auto replacedVelocity = (velocity == 0 ? getNoteVelocity(noteNumber) : velocity);
|
||||
MidiState& midiState = impl.resources_.getMidiState();
|
||||
midiState.noteOffEvent(delay, noteNumber, normalizedVelocity);
|
||||
|
||||
if (impl.lastKeyswitchLists_[noteNumber].empty())
|
||||
midiState.noteOffEvent(delay, noteNumber, normalizedVelocity);
|
||||
|
||||
const auto replacedVelocity = midiState.getNoteVelocity(noteNumber);
|
||||
|
||||
for (auto& voice : impl.voiceManager_)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue