Share a rng between voices

This commit is contained in:
Roland Rabien 2023-09-29 20:20:07 -07:00
commit cdd3fd99f3
3 changed files with 3 additions and 3 deletions

View file

@ -63,10 +63,10 @@ void WavetableVoice::noteStarted()
a.noteOn();
for (auto idx = 0; auto& l : modLFOs)
l.noteOn (proc.lfoParams[idx++].retrig->getBoolValue() ? -1 : rng.nextFloat());
l.noteOn (proc.lfoParams[idx++].retrig->getBoolValue() ? -1 : proc.rng.nextFloat());
modStepLFO.reset();
modStepLFO.noteOn (proc.stepLfoParams.retrig->getBoolValue() ? -1 : rng.nextFloat());
modStepLFO.noteOn (proc.stepLfoParams.retrig->getBoolValue() ? -1 : proc.rng.nextFloat());
adsr.reset();
adsr.noteOn();