From 37dde11711904924ee763ae383fdcfe5317173d9 Mon Sep 17 00:00:00 2001 From: Tommy Vaillancourt Date: Wed, 4 Feb 2026 15:06:19 -0500 Subject: [PATCH 1/2] fix proposal for 2406 --- lib_com/gs_gains_fx.c | 6 +++++- lib_com/options.h | 2 +- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/lib_com/gs_gains_fx.c b/lib_com/gs_gains_fx.c index 769af2692..f5eb21c0b 100644 --- a/lib_com/gs_gains_fx.c +++ b/lib_com/gs_gains_fx.c @@ -422,7 +422,7 @@ static void GSC_gain_adj( } ELSE { - Gain_off = 0; + Gain_off = 0; /* For higher bitrate, thus for L_frame == L_FRAME16k as well */ move16(); test(); @@ -460,7 +460,11 @@ static void GSC_gain_adj( } /*mimic ACELP decay of energy for low rates*/ +#ifndef FIX_2406_FIX_GAIN_ON_INACTIVE FOR( i = 0; i < MBANDS_GN; i++ ) +#else + FOR( i = 0; i < Mbands_gn; i++ ) +#endif { old_y_gain[i] = y_gain_tmp[i]; move16(); diff --git a/lib_com/options.h b/lib_com/options.h index 0ea316a82..be695527b 100644 --- a/lib_com/options.h +++ b/lib_com/options.h @@ -122,7 +122,7 @@ #define FIX_1283_STEREO_DFT_COLLAPSE /* FhG: float issue 1283: fix for critical issue with DFT stereo core coder */ #define FIX_2379_REMOVE_previoussynth_fx_32 /* VA: basop issue 2379: remove duplicated buffer st->previoussynth_fx_32[] */ #define FIX_2396_CONSTANT_STRIDE_IN_TC_BUFFER /* FhG/VA: basop issue 2396: keep TC channel pointers in one constant place during decoding and rendering */ - +#define FIX_2406_FIX_GAIN_ON_INACTIVE /* VA: basop issue 2406: gain between 6.4 and 8kHz was too weak during inactive content with Fs=16kHz */ /* ##################### End NON-BE switches ########################### */ /* ################## End MAINTENANCE switches ######################### */ -- GitLab From 2dbe0ae3fc1bda078a785f57ad46acba8c99038f Mon Sep 17 00:00:00 2001 From: vaclav Date: Thu, 5 Feb 2026 09:11:18 +0100 Subject: [PATCH 2/2] comments --- lib_com/gs_gains_fx.c | 4 ++-- lib_com/options.h | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/lib_com/gs_gains_fx.c b/lib_com/gs_gains_fx.c index f5eb21c0b..5490701f2 100644 --- a/lib_com/gs_gains_fx.c +++ b/lib_com/gs_gains_fx.c @@ -50,7 +50,7 @@ static Word16 VDQ_vec_fx( Word16 *Qvec_out_fx, const Word16 *mean_dic_fx, const /*========================================================================*/ -/* FUNCTION : void Comp_and_apply_gain_enc_fx */ +/* FUNCTION : void Comp_and_apply_gain_fx */ /*------------------------------------------------------------------------*/ /* PURPOSE : Compute and apply the quantized per band gain */ /*------------------------------------------------------------------------*/ @@ -479,7 +479,7 @@ static void GSC_gain_adj( /*==========================================================================*/ -/* FUNCTION : Word16 gsc_gaindec_ivas_fx() */ +/* FUNCTION : Word16 gsc_gaindec_fx() */ /*--------------------------------------------------------------------------*/ /* PURPOSE : Generic signal frequency band decoding and application */ /*--------------------------------------------------------------------------*/ diff --git a/lib_com/options.h b/lib_com/options.h index be695527b..142b54952 100644 --- a/lib_com/options.h +++ b/lib_com/options.h @@ -123,6 +123,7 @@ #define FIX_2379_REMOVE_previoussynth_fx_32 /* VA: basop issue 2379: remove duplicated buffer st->previoussynth_fx_32[] */ #define FIX_2396_CONSTANT_STRIDE_IN_TC_BUFFER /* FhG/VA: basop issue 2396: keep TC channel pointers in one constant place during decoding and rendering */ #define FIX_2406_FIX_GAIN_ON_INACTIVE /* VA: basop issue 2406: gain between 6.4 and 8kHz was too weak during inactive content with Fs=16kHz */ + /* ##################### End NON-BE switches ########################### */ /* ################## End MAINTENANCE switches ######################### */ -- GitLab