diff --git a/lib_com/options.h b/lib_com/options.h index 9bdbbc81aad8448ff940a6a3c2bf795c0c91c3fb..8c9e60ab79b87c2e61ba827ddc39690e0f084f76 100644 --- a/lib_com/options.h +++ b/lib_com/options.h @@ -153,6 +153,7 @@ #define FIX_I173_I174 /* Issues 173 and 174: Remove frame and subframe index from ISm metadata and headtracking respectively. */ #define FIX_TCX_DEC_RECONF_BFI #define FIX_SBA_DTX_DECODE_ERROR /* Issue 176: SBA decoder error with DTX at 80kbps SWB, Issue 21: SBA front-VAD threshold (203) */ +#define FIX_MSAN_ERROR_STEREO_RATE_SWITCHING /* addresses Issue 177 */ /* ################## End DEVELOPMENT switches ######################### */ /* clang-format on */ diff --git a/lib_dec/ivas_post_proc.c b/lib_dec/ivas_post_proc.c index a295a8b2a285ca96e3eea6d52382c601b7991924..b2cc27d5efdc50fd48ead6fb003758d5ec57ed86 100644 --- a/lib_dec/ivas_post_proc.c +++ b/lib_dec/ivas_post_proc.c @@ -478,7 +478,11 @@ void stereo_dft_dec_core_switching( mvr2r( output, pAp_input, st->L_frame ); } +#ifdef FIX_MSAN_ERROR_STEREO_RATE_SWITCHING + if ( st->last_core == ACELP_CORE && !( st->prev_bfi == 1 && st->last_core == ACELP_CORE && st->last_con_tcx == 1 ) && !st->tcxonly ) /* ACELP -> TCX/HQ-Core */ +#else if ( st->last_core == ACELP_CORE && !( st->prev_bfi == 1 && st->last_core == ACELP_CORE && st->last_con_tcx == 1 ) ) /* ACELP -> TCX/HQ-Core */ +#endif { mvr2r( tcx_core_buf, tmp_fade, ap_fade_len ); for ( i = 0; i < ap_fade_len; i++ )