Added pitch wheel region activation
This commit is contained in:
parent
53b702d07e
commit
f66aedfc4f
1 changed files with 7 additions and 2 deletions
|
|
@ -382,7 +382,7 @@ void sfz::Synth::renderBlock(AudioSpan<float> buffer) noexcept
|
||||||
const auto callbackStartTime = std::chrono::high_resolution_clock::now();
|
const auto callbackStartTime = std::chrono::high_resolution_clock::now();
|
||||||
|
|
||||||
buffer.fill(0.0f);
|
buffer.fill(0.0f);
|
||||||
|
|
||||||
resources.filePool.cleanupPromises();
|
resources.filePool.cleanupPromises();
|
||||||
|
|
||||||
if (freeWheeling)
|
if (freeWheeling)
|
||||||
|
|
@ -490,7 +490,7 @@ void sfz::Synth::cc(int delay, int ccNumber, uint8_t ccValue) noexcept
|
||||||
resetAllControllers(delay);
|
resetAllControllers(delay);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
midiState.ccEvent(ccNumber, ccValue);
|
midiState.ccEvent(ccNumber, ccValue);
|
||||||
for (auto& voice : voices)
|
for (auto& voice : voices)
|
||||||
voice->registerCC(delay, ccNumber, ccValue);
|
voice->registerCC(delay, ccNumber, ccValue);
|
||||||
|
|
@ -512,6 +512,11 @@ void sfz::Synth::pitchWheel(int delay, int pitch) noexcept
|
||||||
ASSERT(pitch >= -8192);
|
ASSERT(pitch >= -8192);
|
||||||
|
|
||||||
midiState.pitchBendEvent(pitch);
|
midiState.pitchBendEvent(pitch);
|
||||||
|
|
||||||
|
for (auto& region: regions) {
|
||||||
|
region->registerPitchWheel(pitch);
|
||||||
|
}
|
||||||
|
|
||||||
for (auto& voice: voices) {
|
for (auto& voice: voices) {
|
||||||
voice->registerPitchWheel(delay, pitch);
|
voice->registerPitchWheel(delay, pitch);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue