Commit 8d8223b1 authored by Devansh Kandpal's avatar Devansh Kandpal
Browse files

Fixed porting after merge - missing #endif and possible code duplication

parent 1fdaddc2
Loading
Loading
Loading
Loading
Loading
+22 −11
Original line number Diff line number Diff line
@@ -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 ) )