From acc933add3bc2a1c26defb08ed9610f045223a48 Mon Sep 17 00:00:00 2001 From: Dimas Leenman Date: Wed, 20 Jul 2022 13:57:40 +0200 Subject: [PATCH] increment sample rate --- src/dsp/node_formant.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/dsp/node_formant.rs b/src/dsp/node_formant.rs index 70fefa6..dadf4e1 100644 --- a/src/dsp/node_formant.rs +++ b/src/dsp/node_formant.rs @@ -104,6 +104,9 @@ impl DspNode for Formant { // entire wave let wave = carrier * modulator; + // increment phase (very imporant) + self.phase += self.inv_sample_rate; + out.write(frame, wave); } }