From d21df80631b481010e6530d3dc32a1280c409b0d Mon Sep 17 00:00:00 2001 From: Erik Norvell Date: Fri, 13 Jan 2023 13:52:39 +0100 Subject: [PATCH] Bug fix in ENV_STAB_FIX causing EVS non-BE and reenable ENV_STAB_FIX --- lib_com/options.h | 2 +- lib_dec/core_switching_dec.c | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/lib_com/options.h b/lib_com/options.h index 471b41f502..9e000aae89 100644 --- a/lib_com/options.h +++ b/lib_com/options.h @@ -155,7 +155,7 @@ #define FIX_245_RANGE_CODER_VOIP_MSAN /* Issue 245: fix use-of-uninitialized-value in range coder in VoIP mode */ #define FIX_272_COV /* Issue 272: Cleanup for code coverage related to calls to ivas_binaural_cldfb() */ #define FIX_235 /* Issue 235: Deallocation of HR filter memory separately for lib_rend (ROM) and lib_util (from file) */ -/*#define ENV_STAB_FIX*/ /* Contribution 23: HQ envelope stability memory fix */ +#define ENV_STAB_FIX /* Contribution 23: HQ envelope stability memory fix */ #define STABILIZE_GIPD /* FhG: Contribution 22: gIPD stabilization */ /* ################## End DEVELOPMENT switches ######################### */ diff --git a/lib_dec/core_switching_dec.c b/lib_dec/core_switching_dec.c index 20819ceb27..2d0e26b52c 100644 --- a/lib_dec/core_switching_dec.c +++ b/lib_dec/core_switching_dec.c @@ -449,6 +449,11 @@ ivas_error core_switching_pre_dec( st->hHQ_core->prev_ni_ratio = 0.5f; set_f( st->hHQ_core->prev_En_sb, 0.0f, NB_SWB_SUBBANDS ); } + else + { + set_f( st->hHQ_core->old_out, 0, output_frame ); + set_f( st->hHQ_core->old_outLB, 0, L_FRAME16k ); + } #else set_f( st->hHQ_core->old_out, 0, output_frame ); set_f( st->hHQ_core->old_outLB, 0, L_FRAME16k ); -- GitLab