From 270ae8ce93f83cd118627c7de12adf7f6da1253e Mon Sep 17 00:00:00 2001 From: Markus Multrus Date: Thu, 28 May 2026 11:17:10 +0200 Subject: [PATCH] fix condition in tcx_encoder_memory_update_*_fx(), bring inline with float --- lib_com/options.h | 1 + lib_enc/tcx_utils_enc_fx.c | 8 ++++++++ 2 files changed, 9 insertions(+) diff --git a/lib_com/options.h b/lib_com/options.h index 8242a0b71..609f56ec4 100644 --- a/lib_com/options.h +++ b/lib_com/options.h @@ -96,6 +96,7 @@ #define FIX_FLOAT_1539_G192_FORMAT_SWITCH /* VA/Nokia: reintroduce format switching for g192 bitstreams */ #define HARMONIZE_2595_reconfig_decoder_LPD /* FhG: Harmonize reconfig_decoder_LPD with its ivas derivate */ #define HARMONIZE_2596_SetModeIndex /* FhG: Harmonize SetModeIndex with its ivas derivate */ +#define FIX_BASOP_2550_TCX_ENC_MEM_UPDATE /* FhG: fix condition in tcx_encoder_memory_update_*_fx(), bring inline with float */ /* #################### End BE switches ################################## */ diff --git a/lib_enc/tcx_utils_enc_fx.c b/lib_enc/tcx_utils_enc_fx.c index 82ff1cb61..358bcd605 100644 --- a/lib_enc/tcx_utils_enc_fx.c +++ b/lib_enc/tcx_utils_enc_fx.c @@ -2406,7 +2406,11 @@ void tcx_encoder_memory_update_fx( Copy( synth + sub( L_frame_glob, L_SYN_MEM ), LPDmem->mem_syn_r, L_SYN_MEM ); test(); +#ifdef FIX_BASOP_2550_TCX_ENC_MEM_UPDATE + IF( st->tcxonly == 0 || EQ_16( L_frame_glob, L_FRAME16k ) ) +#else IF( st->tcxonly == 0 || LE_16( L_frame_glob, L_FRAME16k ) ) +#endif { /* Update excitation */ IF( LT_16( L_frame_glob, L_EXC_MEM ) ) @@ -2483,7 +2487,11 @@ void tcx_encoder_memory_update_ivas_fx( move16(); test(); +#ifdef FIX_BASOP_2550_TCX_ENC_MEM_UPDATE + IF( st->tcxonly == 0 || EQ_16( L_frame_glob, L_FRAME16k ) ) +#else IF( st->tcxonly == 0 || LE_16( L_frame_glob, L_FRAME16k ) ) +#endif { /* Update excitation */ IF( LT_16( L_frame_glob, L_EXC_MEM ) ) -- GitLab