From 07167a95baec8b688d4db767714c58e3695e14cb Mon Sep 17 00:00:00 2001 From: Tapani Pihlajakuja Date: Mon, 11 Aug 2025 12:18:02 +0300 Subject: [PATCH 1/3] Port float MR 1765 to BASOP. --- apps/decoder.c | 2 + apps/renderer.c | 2 + lib_com/common_api_types.h | 2 + lib_com/options.h | 1 + lib_dec/ivas_binRenderer_internal_fx.c | 90 +++++++++++-------- lib_dec/lib_dec_fx.c | 4 + .../ivas_dirac_dec_binaural_functions_fx.c | 13 +++ lib_rend/ivas_render_config_fx.c | 2 + lib_rend/ivas_reverb_fx.c | 6 ++ lib_rend/lib_rend_fx.c | 19 ++++ 10 files changed, 103 insertions(+), 38 deletions(-) diff --git a/apps/decoder.c b/apps/decoder.c index 179ad3273..df8ee806c 100644 --- a/apps/decoder.c +++ b/apps/decoder.c @@ -561,7 +561,9 @@ int main( #endif goto cleanup; } +#ifndef FIX_587_DEFAULT_REVERB renderConfig.roomAcoustics.override = true; +#endif } /* ISAR frame size is set from command line, not renderer config file. * This will be ignored if output format is not split rendering. */ diff --git a/apps/renderer.c b/apps/renderer.c index 5917e4d29..5cb2ed811 100644 --- a/apps/renderer.c +++ b/apps/renderer.c @@ -1191,7 +1191,9 @@ int main( #endif goto cleanup; } +#ifndef FIX_587_DEFAULT_REVERB renderConfig.roomAcoustics.override = 1; +#endif } /* ISAR frame size is set from command line, not renderer config file. diff --git a/lib_com/common_api_types.h b/lib_com/common_api_types.h index 81c6137a5..a80ac3c4e 100644 --- a/lib_com/common_api_types.h +++ b/lib_com/common_api_types.h @@ -315,7 +315,9 @@ typedef enum typedef struct _IVAS_ROOM_ACOUSTICS_CONFIG { +#ifndef FIX_587_DEFAULT_REVERB Word16 override; +#endif Word16 nBands; /* Number of frequency bands for which reverb properties are provided, integer, range [2..256] */ float pFc_input[IVAS_CLDFB_NO_CHANNELS_MAX]; /* Center frequencies for which following values are provided: */ float pAcoustic_rt60[IVAS_CLDFB_NO_CHANNELS_MAX]; /* - The room's T60 per center frequency */ diff --git a/lib_com/options.h b/lib_com/options.h index 25d559cae..18ed60054 100644 --- a/lib_com/options.h +++ b/lib_com/options.h @@ -130,6 +130,7 @@ #define FIX_1138_SBA_EXT_ERROR_PRINTOUT /* VA: issue 1138: Fix SBA EXT output call of audioCfg2channels() */ #define NONBE_FIX_981_PARAMBIN_DEFAULT_EARLY_PART /* Nokia: Set default early part energy correction to unity for BINAURAL_ROOM_REVERB */ #define NONBE_FIX_1174_MCMASA_LBR_LOOP_ERROR /* Nokia: Fix issue 1174 by removing the unnecessary inner loop causing problems. */ +#define FIX_587_DEFAULT_REVERB /* Philips: issue 587: inconsistent default reverb parameters across renderers */ /* #################### End BASOP porting switches ############################ */ diff --git a/lib_dec/ivas_binRenderer_internal_fx.c b/lib_dec/ivas_binRenderer_internal_fx.c index 53f1c271a..52f0d2d64 100644 --- a/lib_dec/ivas_binRenderer_internal_fx.c +++ b/lib_dec/ivas_binRenderer_internal_fx.c @@ -1274,6 +1274,9 @@ ivas_error ivas_binRenderer_open_fx( Word16 convBand, chIdx, k; #endif ivas_error error; +#ifdef FIX_587_DEFAULT_REVERB + const IVAS_ROOM_ACOUSTICS_CONFIG_DATA *pRoomAcoustics; +#endif error = IVAS_ERR_OK; move32(); @@ -1436,61 +1439,72 @@ ivas_error ivas_binRenderer_open_fx( #else IF( ( EQ_32( st_ivas->renderer_type, RENDERER_BINAURAL_FASTCONV_ROOM ) || EQ_32( st_ivas->renderer_type, RENDERER_BINAURAL_FASTCONV ) ) && EQ_32( st_ivas->hOutSetup.output_config, IVAS_AUDIO_CONFIG_BINAURAL_ROOM_REVERB ) ) #endif + { +#ifdef FIX_587_DEFAULT_REVERB + pRoomAcoustics = NULL; + IF( EQ_32( st_ivas->hOutSetup.output_config, IVAS_AUDIO_CONFIG_BINAURAL_ROOM_REVERB ) ) { - IF( NE_32( ( error = ivas_binaural_reverb_init( &( hBinRenderer->hReverb ), st_ivas->hHrtfStatistics, hBinRenderer->conv_band, hBinRenderer->timeSlots, &( st_ivas->hRenderConfig->roomAcoustics ), st_ivas->hDecoderConfig->output_Fs, st_ivas->hHrtfFastConv->fastconvReverberationTimes_fx, st_ivas->hHrtfFastConv->fastconvReverberationEneCorrections_fx ) ), IVAS_ERR_OK ) ){ - return error; -} + pRoomAcoustics = &( st_ivas->hRenderConfig->roomAcoustics ); + } + + IF( NE_32( ( error = ivas_binaural_reverb_init( &( hBinRenderer->hReverb ), st_ivas->hHrtfStatistics, hBinRenderer->conv_band, hBinRenderer->timeSlots, pRoomAcoustics, st_ivas->hDecoderConfig->output_Fs, st_ivas->hHrtfFastConv->fastconvReverberationTimes_fx, st_ivas->hHrtfFastConv->fastconvReverberationEneCorrections_fx ) ), IVAS_ERR_OK ) ) +#else + IF( NE_32( ( error = ivas_binaural_reverb_init( &( hBinRenderer->hReverb ), st_ivas->hHrtfStatistics, hBinRenderer->conv_band, hBinRenderer->timeSlots, &( st_ivas->hRenderConfig->roomAcoustics ), st_ivas->hDecoderConfig->output_Fs, st_ivas->hHrtfFastConv->fastconvReverberationTimes_fx, st_ivas->hHrtfFastConv->fastconvReverberationEneCorrections_fx ) ), IVAS_ERR_OK ) ) +#endif + { + return error; + } /* initialize the dmx matrix */ #ifndef FIX_1053_REVERB_RECONFIGURATION -IF( NE_16( hBinRenderer->nInChannels, HOA3_CHANNELS ) ) -{ - FOR( chIdx = 0; chIdx < BINAURAL_CHANNELS; chIdx++ ) - { - FOR( k = 0; k < hBinRenderer->nInChannels; k++ ) + IF( NE_16( hBinRenderer->nInChannels, HOA3_CHANNELS ) ) { - hBinRenderer->hReverb->dmxmtx_fx[chIdx][k] = dmxmtx_table_fx[chIdx][k]; - move32(); + FOR( chIdx = 0; chIdx < BINAURAL_CHANNELS; chIdx++ ) + { + FOR( k = 0; k < hBinRenderer->nInChannels; k++ ) + { + hBinRenderer->hReverb->dmxmtx_fx[chIdx][k] = dmxmtx_table_fx[chIdx][k]; + move32(); + } + } } - } -} #endif -} -ELSE -{ - hBinRenderer->hReverb = NULL; -} + } + ELSE + { + hBinRenderer->hReverb = NULL; + } -hBinRenderer->hEFAPdata = NULL; + hBinRenderer->hEFAPdata = NULL; -IF( hBinRenderer->hReverb != NULL && NE_16( hBinRenderer->nInChannels, HOA3_CHANNELS ) ) -{ - test(); - test(); - IF( hBinRenderer->hInputSetup->is_loudspeaker_setup == 0 ) + IF( hBinRenderer->hReverb != NULL && NE_16( hBinRenderer->nInChannels, HOA3_CHANNELS ) ) { - FOR( k = 0; k < 11; k++ ) + test(); + test(); + IF( hBinRenderer->hInputSetup->is_loudspeaker_setup == 0 ) { - ivas_dirac_dec_get_response_fx( extract_l( L_shr_r( ls_azimuth_CICP19_fx[k], 22 ) ), extract_l( L_shr_r( ls_elevation_CICP19_fx[k], 22 ) ), hBinRenderer->hReverb->foa_enc_fx[k], 1, Q29 ); - // Q29: hBinRenderer->hReverb->foa_enc_fx[k] + FOR( k = 0; k < 11; k++ ) + { + ivas_dirac_dec_get_response_fx( extract_l( L_shr_r( ls_azimuth_CICP19_fx[k], 22 ) ), extract_l( L_shr_r( ls_elevation_CICP19_fx[k], 22 ) ), hBinRenderer->hReverb->foa_enc_fx[k], 1, Q29 ); + // Q29: hBinRenderer->hReverb->foa_enc_fx[k] + } } - } - ELSE IF( EQ_32( st_ivas->ivas_format, MC_FORMAT ) && ( st_ivas->hDecoderConfig->Opt_Headrotation || st_ivas->hDecoderConfig->Opt_ExternalOrientation ) ) - { - IF( NE_32( ( error = efap_init_data_fx( &( st_ivas->hEFAPdata ), st_ivas->hIntSetup.ls_azimuth_fx, st_ivas->hIntSetup.ls_elevation_fx, st_ivas->hIntSetup.nchan_out_woLFE, EFAP_MODE_EFAP ) ), IVAS_ERR_OK ) ) + ELSE IF( EQ_32( st_ivas->ivas_format, MC_FORMAT ) && ( st_ivas->hDecoderConfig->Opt_Headrotation || st_ivas->hDecoderConfig->Opt_ExternalOrientation ) ) { - return error; - } + IF( NE_32( ( error = efap_init_data_fx( &( st_ivas->hEFAPdata ), st_ivas->hIntSetup.ls_azimuth_fx, st_ivas->hIntSetup.ls_elevation_fx, st_ivas->hIntSetup.nchan_out_woLFE, EFAP_MODE_EFAP ) ), IVAS_ERR_OK ) ) + { + return error; + } - /* Copy handles to bin renderer handle*/ - hBinRenderer->hEFAPdata = st_ivas->hEFAPdata; + /* Copy handles to bin renderer handle*/ + hBinRenderer->hEFAPdata = st_ivas->hEFAPdata; + } } -} -/* Copy the handles to main handle */ -st_ivas->hBinRenderer = hBinRenderer; + /* Copy the handles to main handle */ + st_ivas->hBinRenderer = hBinRenderer; -return error; + return error; } /*------------------------------------------------------------------------- diff --git a/lib_dec/lib_dec_fx.c b/lib_dec/lib_dec_fx.c index cc985f288..df934a322 100644 --- a/lib_dec/lib_dec_fx.c +++ b/lib_dec/lib_dec_fx.c @@ -2694,7 +2694,9 @@ static ivas_error copyRendererConfigStruct( return IVAS_ERR_UNEXPECTED_NULL_POINTER; } +#ifndef FIX_587_DEFAULT_REVERB hRCout->roomAcoustics.override = hRCin->roomAcoustics.override; +#endif hRCout->roomAcoustics.nBands = hRCin->roomAcoustics.nBands; hRCout->roomAcoustics.acousticPreDelay_fx = hRCin->roomAcoustics.acousticPreDelay_fx; hRCout->roomAcoustics.inputPreDelay_fx = hRCin->roomAcoustics.inputPreDelay_fx; @@ -2799,7 +2801,9 @@ ivas_error IVAS_DEC_FeedRenderConfig( } hRenderConfig = hIvasDec->st_ivas->hRenderConfig; +#ifndef FIX_587_DEFAULT_REVERB hRenderConfig->roomAcoustics.override = renderConfig.roomAcoustics.override; +#endif hRenderConfig->roomAcoustics.nBands = renderConfig.roomAcoustics.nBands; hRenderConfig->roomAcoustics.acousticPreDelay_fx = renderConfig.roomAcoustics.acousticPreDelay_fx; hRenderConfig->roomAcoustics.inputPreDelay_fx = renderConfig.roomAcoustics.inputPreDelay_fx; diff --git a/lib_rend/ivas_dirac_dec_binaural_functions_fx.c b/lib_rend/ivas_dirac_dec_binaural_functions_fx.c index 7d2327599..73eccef92 100644 --- a/lib_rend/ivas_dirac_dec_binaural_functions_fx.c +++ b/lib_rend/ivas_dirac_dec_binaural_functions_fx.c @@ -178,6 +178,9 @@ ivas_error ivas_dirac_dec_init_binaural_data_fx( ivas_error error; Word16 num_poses, pos_idx; +#ifdef FIX_587_DEFAULT_REVERB + const IVAS_ROOM_ACOUSTICS_CONFIG_DATA *pRoomAcoustics; +#endif num_poses = 1; IF( st_ivas->hSplitBinRend != NULL ) @@ -301,10 +304,16 @@ ivas_error ivas_dirac_dec_init_binaural_data_fx( IF( EQ_32( st_ivas->hDecoderConfig->output_config, IVAS_AUDIO_CONFIG_BINAURAL_ROOM_IR ) ) { Copy32( ( *phHrtfParambin )->parametricEarlyPartEneCorrection_fx, hDiracDecBin->earlyPartEneCorrection_fx, nBins ); +#ifdef FIX_587_DEFAULT_REVERB + pRoomAcoustics = NULL; +#endif } ELSE { set32_fx( hDiracDecBin->earlyPartEneCorrection_fx, ONE_IN_Q28, CLDFB_NO_CHANNELS_MAX ); +#ifdef FIX_587_DEFAULT_REVERB + pRoomAcoustics = &( st_ivas->hRenderConfig->roomAcoustics ); +#endif } #else Copy32( ( *phHrtfParambin )->parametricEarlyPartEneCorrection_fx, hDiracDecBin->earlyPartEneCorrection_fx, nBins ); @@ -327,7 +336,11 @@ ivas_error ivas_dirac_dec_init_binaural_data_fx( { #ifdef NONBE_FIX_991_PARAMBIN_BINARY_HRTF +#ifdef FIX_587_DEFAULT_REVERB + if ( NE_32( ( error = ivas_binaural_reverb_init( &hDiracDecBin->hReverb, st_ivas->hHrtfStatistics, nBins, CLDFB_NO_COL_MAX / MAX_PARAM_SPATIAL_SUBFRAMES, pRoomAcoustics, output_Fs, ( *phHrtfParambin )->parametricReverberationTimes_fx, ( *phHrtfParambin )->parametricReverberationEneCorrections_fx ) ), IVAS_ERR_OK ) ) +#else if ( NE_32( ( error = ivas_binaural_reverb_init( &hDiracDecBin->hReverb, st_ivas->hHrtfStatistics, nBins, CLDFB_NO_COL_MAX / MAX_PARAM_SPATIAL_SUBFRAMES, &( st_ivas->hRenderConfig->roomAcoustics ), output_Fs, ( *phHrtfParambin )->parametricReverberationTimes_fx, ( *phHrtfParambin )->parametricReverberationEneCorrections_fx ) ), IVAS_ERR_OK ) ) +#endif #else if ( ( error = ivas_binaural_reverb_init( &hDiracDecBin->hReverb, st_ivas->hHrtfStatistics, nBins, CLDFB_NO_COL_MAX / MAX_PARAM_SPATIAL_SUBFRAMES, &( st_ivas->hRenderConfig->roomAcoustics ), output_Fs, st_ivas->hHrtfParambin->parametricReverberationTimes_fx, st_ivas->hHrtfParambin->parametricReverberationEneCorrections_fx ) ) != IVAS_ERR_OK ) #endif diff --git a/lib_rend/ivas_render_config_fx.c b/lib_rend/ivas_render_config_fx.c index 14e2c2a5d..3507ca00d 100644 --- a/lib_rend/ivas_render_config_fx.c +++ b/lib_rend/ivas_render_config_fx.c @@ -109,8 +109,10 @@ ivas_error ivas_render_config_init_from_rom_fx( { return IVAS_ERROR( IVAS_ERR_UNEXPECTED_NULL_POINTER, "Unexpected null pointer while attempting to fill renderer configuration from ROM" ); } +#ifndef FIX_587_DEFAULT_REVERB ( *hRenderConfig )->roomAcoustics.override = FALSE; move16(); +#endif ( *hRenderConfig )->roomAcoustics.nBands = IVAS_REVERB_DEFAULT_N_BANDS; move16(); ( *hRenderConfig )->roomAcoustics.acousticPreDelay_fx = IVAS_REVERB_DEFAULT_PRE_DELAY_FX; diff --git a/lib_rend/ivas_reverb_fx.c b/lib_rend/ivas_reverb_fx.c index 6c0604ccc..bb3fc4b1f 100644 --- a/lib_rend/ivas_reverb_fx.c +++ b/lib_rend/ivas_reverb_fx.c @@ -1574,8 +1574,10 @@ ivas_error ivas_reverb_open_fx( /* set reverb acoustic configuration based on renderer config */ +#ifndef FIX_587_DEFAULT_REVERB pState->pConfig.roomAcoustics.override = hRenderConfig->roomAcoustics.override; move16(); +#endif pState->pConfig.roomAcoustics.nBands = hRenderConfig->roomAcoustics.nBands; move16(); @@ -2542,7 +2544,11 @@ ivas_error ivas_binaural_reverb_init( error = IVAS_ERR_OK; +#ifdef FIX_587_DEFAULT_REVERB + if ( roomAcoustics != NULL ) +#else if ( ( roomAcoustics != NULL ) && roomAcoustics->override ) +#endif { float t60_temp[CLDFB_NO_CHANNELS_MAX]; float ene_temp[CLDFB_NO_CHANNELS_MAX]; diff --git a/lib_rend/lib_rend_fx.c b/lib_rend/lib_rend_fx.c index 96db56e54..ab5d40ccf 100644 --- a/lib_rend/lib_rend_fx.c +++ b/lib_rend/lib_rend_fx.c @@ -4686,12 +4686,16 @@ Word16 IVAS_REND_GetRenderConfig( } hRCin = hIvasRend->hRendererConfig; +#ifndef FIX_587_DEFAULT_REVERB hRCout->roomAcoustics.override = hRCin->roomAcoustics.override; +#endif hRCout->roomAcoustics.nBands = hRCin->roomAcoustics.nBands; hRCout->roomAcoustics.acousticPreDelay_fx = hRCin->roomAcoustics.acousticPreDelay_fx; hRCout->roomAcoustics.inputPreDelay_fx = hRCin->roomAcoustics.inputPreDelay_fx; Copy( hRCin->directivity_fx, hRCout->directivity_fx, 3 * MAX_NUM_OBJECTS ); +#ifndef FIX_587_DEFAULT_REVERB move16(); +#endif move16(); move32(); move32(); @@ -4751,8 +4755,10 @@ Word16 IVAS_REND_FeedRenderConfig( } hRenderConfig = hIvasRend->hRendererConfig; +#ifndef FIX_587_DEFAULT_REVERB hRenderConfig->roomAcoustics.override = renderConfig.roomAcoustics.override; move16(); +#endif hRenderConfig->roomAcoustics.nBands = renderConfig.roomAcoustics.nBands; move16(); hRenderConfig->roomAcoustics.acousticPreDelay_fx = renderConfig.roomAcoustics.acousticPreDelay_fx; @@ -9666,6 +9672,9 @@ static ivas_error ivas_masa_ext_rend_parambin_init( ivas_error error; Word16 frequency_axis_fx[CLDFB_NO_CHANNELS_MAX]; int16_t pos_idx; +#ifdef FIX_587_DEFAULT_REVERB + const IVAS_ROOM_ACOUSTICS_CONFIG_DATA *pRoomAcoustics; +#endif Word16 tmp; Word16 tmp_e; @@ -9784,10 +9793,16 @@ static ivas_error ivas_masa_ext_rend_parambin_init( IF( EQ_32( *inputMasa->base.ctx.pOutConfig, IVAS_AUDIO_CONFIG_BINAURAL_ROOM_IR ) ) { Copy32( ( *phHrtfParambin )->parametricEarlyPartEneCorrection_fx, hDiracDecBin->earlyPartEneCorrection_fx, nBins ); +#ifdef FIX_587_DEFAULT_REVERB + pRoomAcoustics = NULL; +#endif } ELSE { set32_fx( hDiracDecBin->earlyPartEneCorrection_fx, ONE_IN_Q28, CLDFB_NO_CHANNELS_MAX ); +#ifdef FIX_587_DEFAULT_REVERB + pRoomAcoustics = &( hRendCfg->roomAcoustics ); +#endif } #else Copy32( ( *phHrtfParambin )->parametricEarlyPartEneCorrection_fx, hDiracDecBin->earlyPartEneCorrection_fx, nBins ); @@ -9801,7 +9816,11 @@ static ivas_error ivas_masa_ext_rend_parambin_init( IF( hDiracDecBin->hReverb == NULL && pos_idx == 0 ) /* open reverb only for the main direction */ { #ifdef NONBE_FIX_991_PARAMBIN_BINARY_HRTF +#ifdef FIX_587_DEFAULT_REVERB + if ( NE_32( ( error = ivas_binaural_reverb_init( &hDiracDecBin->hReverb, hHrtfStatistics, nBins, CLDFB_NO_COL_MAX / MAX_PARAM_SPATIAL_SUBFRAMES, pRoomAcoustics, output_Fs, ( *phHrtfParambin )->parametricReverberationTimes_fx, ( *phHrtfParambin )->parametricReverberationEneCorrections_fx ) ), IVAS_ERR_OK ) ) +#else if ( NE_32( ( error = ivas_binaural_reverb_init( &hDiracDecBin->hReverb, hHrtfStatistics, nBins, CLDFB_NO_COL_MAX / MAX_PARAM_SPATIAL_SUBFRAMES, &( hRendCfg->roomAcoustics ), output_Fs, ( *phHrtfParambin )->parametricReverberationTimes_fx, ( *phHrtfParambin )->parametricReverberationEneCorrections_fx ) ), IVAS_ERR_OK ) ) +#endif #else IF( NE_32( ( error = ivas_binaural_reverb_init( &hDiracDecBin->hReverb, hHrtfStatistics, nBins, CLDFB_NO_COL_MAX / MAX_PARAM_SPATIAL_SUBFRAMES, &( hRendCfg->roomAcoustics ), output_Fs, hHrtfParambin->parametricReverberationTimes_fx, hHrtfParambin->parametricReverberationEneCorrections_fx ) ), IVAS_ERR_OK ) ) #endif -- GitLab From 8d8223b12c1c029c478ef8ce05e43cbfa1170169 Mon Sep 17 00:00:00 2001 From: Devansh Kandpal <43807487+mrkandpal@users.noreply.github.com> Date: Wed, 20 Aug 2025 15:37:25 +0200 Subject: [PATCH 2/3] Fixed porting after merge - missing #endif and possible code duplication --- lib_dec/ivas_binRenderer_internal_fx.c | 33 +++++++++++++++++--------- 1 file changed, 22 insertions(+), 11 deletions(-) diff --git a/lib_dec/ivas_binRenderer_internal_fx.c b/lib_dec/ivas_binRenderer_internal_fx.c index f484f8e4c..fa9d35cf5 100644 --- a/lib_dec/ivas_binRenderer_internal_fx.c +++ b/lib_dec/ivas_binRenderer_internal_fx.c @@ -1353,16 +1353,7 @@ ivas_error ivas_binRenderer_open_fx( /* Allocate memories needed for reverb module */ test(); - IF( EQ_32( st_ivas->renderer_type, RENDERER_BINAURAL_FASTCONV_ROOM ) || ( EQ_32( st_ivas->renderer_type, RENDERER_BINAURAL_FASTCONV ) && EQ_32( st_ivas->hOutSetup.output_config, IVAS_AUDIO_CONFIG_BINAURAL_ROOM_REVERB ) ) ){ - IF( NE_32( ( error = ivas_binaural_reverb_init( &( hBinRenderer->hReverb ), st_ivas->hHrtfStatistics, hBinRenderer->conv_band, hBinRenderer->timeSlots, &( st_ivas->hRenderConfig->roomAcoustics ), st_ivas->hDecoderConfig->output_Fs, st_ivas->hHrtfFastConv->fastconvReverberationTimes_fx, st_ivas->hHrtfFastConv->fastconvReverberationEneCorrections_fx ) ), IVAS_ERR_OK ) ){ - return error; -} - -/* initialize the dmx matrix */ -#ifndef FIX_1053_REVERB_RECONFIGURATION -IF( NE_16( hBinRenderer->nInChannels, HOA3_CHANNELS ) ) -{ - FOR( chIdx = 0; chIdx < BINAURAL_CHANNELS; chIdx++ ) + IF( EQ_32( st_ivas->renderer_type, RENDERER_BINAURAL_FASTCONV_ROOM ) || ( EQ_32( st_ivas->renderer_type, RENDERER_BINAURAL_FASTCONV ) && EQ_32( st_ivas->hOutSetup.output_config, IVAS_AUDIO_CONFIG_BINAURAL_ROOM_REVERB ) ) ) { #ifdef FIX_587_DEFAULT_REVERB pRoomAcoustics = NULL; @@ -1370,7 +1361,6 @@ IF( NE_16( hBinRenderer->nInChannels, HOA3_CHANNELS ) ) { pRoomAcoustics = &( st_ivas->hRenderConfig->roomAcoustics ); } - IF( NE_32( ( error = ivas_binaural_reverb_init( &( hBinRenderer->hReverb ), st_ivas->hHrtfStatistics, hBinRenderer->conv_band, hBinRenderer->timeSlots, pRoomAcoustics, st_ivas->hDecoderConfig->output_Fs, st_ivas->hHrtfFastConv->fastconvReverberationTimes_fx, st_ivas->hHrtfFastConv->fastconvReverberationEneCorrections_fx ) ), IVAS_ERR_OK ) ) #else IF( NE_32( ( error = ivas_binaural_reverb_init( &( hBinRenderer->hReverb ), st_ivas->hHrtfStatistics, hBinRenderer->conv_band, hBinRenderer->timeSlots, &( st_ivas->hRenderConfig->roomAcoustics ), st_ivas->hDecoderConfig->output_Fs, st_ivas->hHrtfFastConv->fastconvReverberationTimes_fx, st_ivas->hHrtfFastConv->fastconvReverberationEneCorrections_fx ) ), IVAS_ERR_OK ) ) @@ -1379,6 +1369,27 @@ IF( NE_16( hBinRenderer->nInChannels, HOA3_CHANNELS ) ) return error; } +/* initialize the dmx matrix */ +//#ifndef FIX_1053_REVERB_RECONFIGURATION +//IF( NE_16( hBinRenderer->nInChannels, HOA3_CHANNELS ) ) +//{ +// FOR( chIdx = 0; chIdx < BINAURAL_CHANNELS; chIdx++ ) +// { +//#ifdef FIX_587_DEFAULT_REVERB +// pRoomAcoustics = NULL; +// IF( EQ_32( st_ivas->hOutSetup.output_config, IVAS_AUDIO_CONFIG_BINAURAL_ROOM_REVERB ) ) +// { +// pRoomAcoustics = &( st_ivas->hRenderConfig->roomAcoustics ); +// } +// +// IF( NE_32( ( error = ivas_binaural_reverb_init( &( hBinRenderer->hReverb ), st_ivas->hHrtfStatistics, hBinRenderer->conv_band, hBinRenderer->timeSlots, pRoomAcoustics, st_ivas->hDecoderConfig->output_Fs, st_ivas->hHrtfFastConv->fastconvReverberationTimes_fx, st_ivas->hHrtfFastConv->fastconvReverberationEneCorrections_fx ) ), IVAS_ERR_OK ) ) +//#else +// IF( NE_32( ( error = ivas_binaural_reverb_init( &( hBinRenderer->hReverb ), st_ivas->hHrtfStatistics, hBinRenderer->conv_band, hBinRenderer->timeSlots, &( st_ivas->hRenderConfig->roomAcoustics ), st_ivas->hDecoderConfig->output_Fs, st_ivas->hHrtfFastConv->fastconvReverberationTimes_fx, st_ivas->hHrtfFastConv->fastconvReverberationEneCorrections_fx ) ), IVAS_ERR_OK ) ) +//#endif +// { +// return error; +// } + /* initialize the dmx matrix */ #ifndef FIX_1053_REVERB_RECONFIGURATION IF( NE_16( hBinRenderer->nInChannels, HOA3_CHANNELS ) ) -- GitLab From d9f1a6c84b87f41be9cba3adc74a31068d88d7ae Mon Sep 17 00:00:00 2001 From: Devansh Kandpal <43807487+mrkandpal@users.noreply.github.com> Date: Wed, 20 Aug 2025 16:27:04 +0200 Subject: [PATCH 3/3] clang fix + removed comments --- lib_dec/ivas_binRenderer_internal_fx.c | 21 --------------------- 1 file changed, 21 deletions(-) diff --git a/lib_dec/ivas_binRenderer_internal_fx.c b/lib_dec/ivas_binRenderer_internal_fx.c index fa9d35cf5..64a30a468 100644 --- a/lib_dec/ivas_binRenderer_internal_fx.c +++ b/lib_dec/ivas_binRenderer_internal_fx.c @@ -1369,27 +1369,6 @@ ivas_error ivas_binRenderer_open_fx( return error; } -/* initialize the dmx matrix */ -//#ifndef FIX_1053_REVERB_RECONFIGURATION -//IF( NE_16( hBinRenderer->nInChannels, HOA3_CHANNELS ) ) -//{ -// FOR( chIdx = 0; chIdx < BINAURAL_CHANNELS; chIdx++ ) -// { -//#ifdef FIX_587_DEFAULT_REVERB -// pRoomAcoustics = NULL; -// IF( EQ_32( st_ivas->hOutSetup.output_config, IVAS_AUDIO_CONFIG_BINAURAL_ROOM_REVERB ) ) -// { -// pRoomAcoustics = &( st_ivas->hRenderConfig->roomAcoustics ); -// } -// -// IF( NE_32( ( error = ivas_binaural_reverb_init( &( hBinRenderer->hReverb ), st_ivas->hHrtfStatistics, hBinRenderer->conv_band, hBinRenderer->timeSlots, pRoomAcoustics, st_ivas->hDecoderConfig->output_Fs, st_ivas->hHrtfFastConv->fastconvReverberationTimes_fx, st_ivas->hHrtfFastConv->fastconvReverberationEneCorrections_fx ) ), IVAS_ERR_OK ) ) -//#else -// IF( NE_32( ( error = ivas_binaural_reverb_init( &( hBinRenderer->hReverb ), st_ivas->hHrtfStatistics, hBinRenderer->conv_band, hBinRenderer->timeSlots, &( st_ivas->hRenderConfig->roomAcoustics ), st_ivas->hDecoderConfig->output_Fs, st_ivas->hHrtfFastConv->fastconvReverberationTimes_fx, st_ivas->hHrtfFastConv->fastconvReverberationEneCorrections_fx ) ), IVAS_ERR_OK ) ) -//#endif -// { -// return error; -// } - /* initialize the dmx matrix */ #ifndef FIX_1053_REVERB_RECONFIGURATION IF( NE_16( hBinRenderer->nInChannels, HOA3_CHANNELS ) ) -- GitLab