ref: 8733f5cc1504c08044c19f7d6c4f0dce6d39c349
parent: e60c993bac54d14d59a2e7967f1e5fd487a523a4
author: Jeff Snyder <jeff@snyderphonics.com>
date: Sun Apr 14 10:38:02 EDT 2019
fixed sample rate problem in oversampler
--- a/LEAF/Src/leaf-oversampler.c
+++ b/LEAF/Src/leaf-oversampler.c
@@ -77,10 +77,10 @@
// 4X Oversampler
void tOversampler4x_init(tOversampler4x* const os)
{
- tOversamplerFilter_init(&os->filters[0], leaf.sampleRate*0.5f, 0.1f, 2.f);
- tOversamplerFilter_init(&os->filters[1], leaf.sampleRate*0.5f, 0.1f, 4.f);
- tOversamplerFilter_init(&os->filters[2], leaf.sampleRate*0.5f, 0.1f, 4.f);
- tOversamplerFilter_init(&os->filters[3] , leaf.sampleRate*0.5f, 0.1f, 2.f);
+ tOversamplerFilter_init(&os->filters[0], leaf.sampleRate*0.25f, 0.1f, 2.f); //sample rate was *0.5 but I assume that was copypaste mistake (copied from 2X filter) - JS
+ tOversamplerFilter_init(&os->filters[1], leaf.sampleRate*0.25f, 0.1f, 4.f);
+ tOversamplerFilter_init(&os->filters[2], leaf.sampleRate*0.25f, 0.1f, 4.f);
+ tOversamplerFilter_init(&os->filters[3] , leaf.sampleRate*0.25f, 0.1f, 2.f);
}
float tOversampler4x_tick(tOversampler4x* const os, float input, float (*nonLinearTick)(float))