From 20fc24a45bf24005b8583363177a707f13f5375d Mon Sep 17 00:00:00 2001 From: Sandesh Venkatesh Date: Wed, 15 May 2024 22:11:56 +0530 Subject: [PATCH] dirac dec binaural function loop range corrected --- lib_rend/ivas_dirac_dec_binaural_functions.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib_rend/ivas_dirac_dec_binaural_functions.c b/lib_rend/ivas_dirac_dec_binaural_functions.c index 04e02ca10..4985fe097 100644 --- a/lib_rend/ivas_dirac_dec_binaural_functions.c +++ b/lib_rend/ivas_dirac_dec_binaural_functions.c @@ -1438,7 +1438,7 @@ static void ivas_dirac_dec_binaural_internal( floatToFixed_arr32( hDiracDecBin->earlyPartEneCorrection, hDiracDecBin->earlyPartEneCorrection_fx, q_earlyPartEneCorrection, hSpatParamRendCom->num_freq_bands ); floatToFixed_arr32( hDiracDecBin->diffuseFieldCoherence, hDiracDecBin->diffuseFieldCoherence_fx, Q31, hSpatParamRendCom->num_freq_bands ); - FOR( j = 0; j < CLDFB_NO_CHANNELS_MAX; j++ ) + FOR( j = 0; j < nBins; j++ ) { f2me( hDiracDecBin->ChCrossRePrev[j], &hDiracDecBin->ChCrossRePrev_fx[j], &hDiracDecBin->ChCrossRePrev_e[j] ); f2me( hDiracDecBin->ChCrossImPrev[j], &hDiracDecBin->ChCrossImPrev_fx[j], &hDiracDecBin->ChCrossImPrev_e[j] ); @@ -1543,7 +1543,7 @@ static void ivas_dirac_dec_binaural_internal( } } - FOR( j = 0; j < CLDFB_NO_CHANNELS_MAX; j++ ) + FOR( j = 0; j < nBins; j++ ) { hDiracDecBin->ChCrossRePrev[j] = me2f( hDiracDecBin->ChCrossRePrev_fx[j], hDiracDecBin->ChCrossRePrev_e[j] ); hDiracDecBin->ChCrossImPrev[j] = me2f( hDiracDecBin->ChCrossImPrev_fx[j], hDiracDecBin->ChCrossImPrev_e[j] ); @@ -6013,7 +6013,7 @@ static void ivas_masa_ext_rend_parambin_internal( hDiracDecBin->q_earlyPartEneCorrection = q_earlyPartEneCorrection; floatToFixed_arr32( hDiracDecBin->earlyPartEneCorrection, hDiracDecBin->earlyPartEneCorrection_fx, q_earlyPartEneCorrection, hSpatParamRendCom->num_freq_bands ); floatToFixed_arr32( hDiracDecBin->diffuseFieldCoherence, hDiracDecBin->diffuseFieldCoherence_fx, Q31, hSpatParamRendCom->num_freq_bands ); - FOR( j = 0; j < CLDFB_NO_CHANNELS_MAX; j++ ) + FOR( j = 0; j < nBins; j++ ) { f2me( hDiracDecBin->ChCrossRePrev[j], &hDiracDecBin->ChCrossRePrev_fx[j], &hDiracDecBin->ChCrossRePrev_e[j] ); f2me( hDiracDecBin->ChCrossImPrev[j], &hDiracDecBin->ChCrossImPrev_fx[j], &hDiracDecBin->ChCrossImPrev_e[j] ); @@ -6186,7 +6186,7 @@ static void ivas_masa_ext_rend_parambin_internal( } } - FOR( j = 0; j < CLDFB_NO_CHANNELS_MAX; j++ ) + FOR( j = 0; j < nBins; j++ ) { hDiracDecBin->ChCrossRePrev[j] = me2f( hDiracDecBin->ChCrossRePrev_fx[j], hDiracDecBin->ChCrossRePrev_e[j] ); hDiracDecBin->ChCrossImPrev[j] = me2f( hDiracDecBin->ChCrossImPrev_fx[j], hDiracDecBin->ChCrossImPrev_e[j] ); -- GitLab