Removed smoothing from sync delay time

This commit is contained in:
Roland Rabien 2023-10-03 08:47:14 -07:00
commit 2c94495f02
2 changed files with 16 additions and 12 deletions

View file

@ -4,6 +4,7 @@
- Added retrigger to oscillators
- Added 25% and 12.5% pulse wave sub oscillators
- Added 50 more wavetables
- Removed smoothing from sync delay time
1.0.7:

View file

@ -698,13 +698,8 @@ void WavetableAudioProcessor::setupModMatrix()
modMatrix.build();
}
float WavetableAudioProcessor::getSmoothingTime (gin::Parameter* p)
float WavetableAudioProcessor::getSmoothingTime (gin::Parameter*)
{
if (p == delayParams.delay) return 0.0f;
if (p == delayParams.cf) return 0.0f;
if (p == delayParams.fb) return 0.0f;
if (p == delayParams.mix) return 0.0f;
return 0.02f;
}
@ -873,7 +868,12 @@ void WavetableAudioProcessor::applyEffects (juce::AudioSampleBuffer& buffer)
// Apply Delay
if (delayParams.enable->isOn())
{
if (delayParams.sync->isOn())
stereoDelay.process (buffer);
else
stereoDelay.processSmoothed (buffer);
}
// Apply Reverb
if (reverbParams.enable->isOn())
@ -976,17 +976,20 @@ void WavetableAudioProcessor::updateParams (int newBlockSize)
{
auto& duration = gin::NoteDuration::getNoteDurations()[(size_t)modMatrix.getValue (delayParams.beat)];
delayParams.delay->setUserValue (duration.toSeconds (getPlayHead()));
stereoDelay.setParams (delayParams.delay->getUserValue(),
modMatrix.getValue (delayParams.mix),
modMatrix.getValue (delayParams.fb),
modMatrix.getValue (delayParams.cf));
}
else
{
delayParams.delay->setUserValue (modMatrix.getValue (delayParams.time));
}
stereoDelay.setParams (modMatrix.getValue (delayParams.delay),
modMatrix.getValue (delayParams.mix),
modMatrix.getValue (delayParams.fb),
modMatrix.getValue (delayParams.cf));
}
}
// Update Reverb
if (reverbParams.enable->isOn())