diff --git a/lib_com/options.h b/lib_com/options.h index a3a96d070928df75b0c35b6ae02b285f9cad51d2..b4e366ca6d504919c003b20eb86aba21e3efa1a5 100644 --- a/lib_com/options.h +++ b/lib_com/options.h @@ -89,7 +89,7 @@ #define FIX_2082_FP_LEFTOVERS_OMASA_DEC /* Nokia: fix for issue 2082, cleaning remaining floating point code */ #define FIX_2174_JBM_BASOP_ALIGNMENT /* VoiceAge, Nokia: Fixes to JBM BASOP implementation and alignment to float */ - +#define FIX_2176_ASSERT_DEC_MAP_PARAMS_DIRAC2STEREO /* FhG: Reduce hStereoDft->q_smooth_buf_fx by one to prevent overflow in the subframe_band_nrg[][] calculation */ /* ################### End FIXES switches ########################### */ /* #################### Start BASOP porting switches ############################ */ diff --git a/lib_dec/ivas_stereo_dft_dec_fx.c b/lib_dec/ivas_stereo_dft_dec_fx.c index aa8d428c7af303c3412fca48b142e3ab22c09220..186306209fbe39d48451785efa1ef1a9043410ab 100644 --- a/lib_dec/ivas_stereo_dft_dec_fx.c +++ b/lib_dec/ivas_stereo_dft_dec_fx.c @@ -220,7 +220,11 @@ void stereo_dft_dec_reset_fx( { set32_fx( hStereoDft->smooth_buf_fx[i], 0, SBA_DIRAC_NRG_SMOOTH_LONG + 1 ); } +#ifdef FIX_2176_ASSERT_DEC_MAP_PARAMS_DIRAC2STEREO + hStereoDft->q_smooth_buf_fx = Q6; +#else hStereoDft->q_smooth_buf_fx = Q7; +#endif move16(); set16_fx( hStereoDft->smooth_fac_fx[0], 0, SBA_DIRAC_STEREO_NUM_BANDS ); set16_fx( hStereoDft->smooth_fac_fx[1], 0, SBA_DIRAC_STEREO_NUM_BANDS );