From 4bca98ab1fac75b1a69d3c4b739dd0881f806652 Mon Sep 17 00:00:00 2001 From: KubaPro010 Date: Mon, 4 May 2026 13:34:50 +0200 Subject: [PATCH] fix --- src/fm95.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/fm95.c b/src/fm95.c index aba358a..63d5013 100644 --- a/src/fm95.c +++ b/src/fm95.c @@ -440,10 +440,11 @@ void init_runtime(FM95_Runtime* runtime, const FM95_Config config) { } if(runtime->bs412.init == true && (runtime->bs412.sample_rate == config.sample_rate)) { - reinit_bs412(&runtime->bs412, config.mpx_deviation, config.mpx_power, config.bs412_attack, config.bs412_release, config.bs412_max, config.bs412_gate) + reinit_bs412(&runtime->bs412, config.mpx_deviation, config.mpx_power, config.bs412_attack, config.bs412_release, config.bs412_max, config.bs412_gate); } else init_bs412(&runtime->bs412, config.mpx_deviation, config.mpx_power, config.bs412_attack, config.bs412_release, config.bs412_max, config.bs412_gate, config.sample_rate); init_stereo_encoder(&runtime->stencode, config.stereo_ssb, 4.0f, &runtime->osc, config.volumes.audio, config.volumes.pilot); + float last_gain = 0.0f; if(config.agc_max != 0.0) { last_gain = 1.0f; if(runtime->agc.sampleRate == config.sample_rate) last_gain = runtime->agc.currentGain;