Loading apps/decoder.c +11 −11 Original line number Diff line number Diff line Loading @@ -427,6 +427,7 @@ int main( /*------------------------------------------------------------------------------------------* * Configure the decoder *------------------------------------------------------------------------------------------*/ #ifdef SPLIT_REND_WITH_HEAD_ROT if ( arg.outputFormat == IVAS_DEC_OUTPUT_SPLIT_BINAURAL_CODED || arg.outputFormat == IVAS_DEC_OUTPUT_SPLIT_BINAURAL_PCM ) { Loading Loading @@ -582,8 +583,7 @@ int main( /* sanity check */ #ifdef SPLIT_REND_WITH_HEAD_ROT if ( arg.outputFormat != IVAS_DEC_OUTPUT_BINAURAL && arg.outputFormat != IVAS_DEC_OUTPUT_BINAURAL_ROOM_IR && arg.outputFormat != IVAS_DEC_OUTPUT_BINAURAL_ROOM_REVERB && arg.outputFormat != IVAS_DEC_OUTPUT_SPLIT_BINAURAL_CODED && arg.outputFormat != IVAS_DEC_OUTPUT_SPLIT_BINAURAL_PCM ) arg.outputFormat != IVAS_DEC_OUTPUT_SPLIT_BINAURAL_CODED && arg.outputFormat != IVAS_DEC_OUTPUT_SPLIT_BINAURAL_PCM ) { fprintf( stderr, "\nExternal Renderer Config is supported only when binaural output configurations is used as output OR when Split rendering mode is enabled. Exiting. \n" ); exit( -1 ); Loading Loading @@ -1561,9 +1561,9 @@ static ivas_error initOnFirstGoodFrame( fprintf( stderr, "\nUnable to get delay of decoder: %s\n", ivas_error_to_string( error ) ); return error; } #ifdef SPLIT_REND_WITH_HEAD_ROT if ( ( arg.outputFormat == IVAS_DEC_OUTPUT_SPLIT_BINAURAL_PCM ) || ( arg.outputFormat == IVAS_DEC_OUTPUT_SPLIT_BINAURAL_CODED ) ) if ( arg.outputFormat == IVAS_DEC_OUTPUT_SPLIT_BINAURAL_PCM || arg.outputFormat == IVAS_DEC_OUTPUT_SPLIT_BINAURAL_CODED ) { pFullDelayNumSamples[0] = 0; } Loading Loading @@ -1642,8 +1642,8 @@ static ivas_error initOnFirstGoodFrame( IVAS_SPLIT_REND_BITS splitRendBitsZero; splitRendBitsZero.bits_written = 0; splitRendBitsZero.bits_read = 0; if ( split_rend_write_bitstream_to_file( *hSplitRendFileReadWrite, splitRendBitsZero.bits_buf, &splitRendBitsZero.bits_read, &splitRendBitsZero.bits_written, -1, IVAS_SPLIT_REND_POSE_CORRECTION_MODE_NONE ) != IVAS_ERR_OK ) if ( split_rend_write_bitstream_to_file( *hSplitRendFileReadWrite, splitRendBitsZero.bits_buf, &splitRendBitsZero.bits_read, &splitRendBitsZero.bits_written, -1, IVAS_SPLIT_REND_POSE_CORRECTION_MODE_NONE ) != IVAS_ERR_OK ) { fprintf( stderr, "\nUnable to write to bitstream file!\n" ); exit( -1 ); Loading Loading @@ -1825,6 +1825,7 @@ static ivas_error decodeG192( #endif #ifdef SPLIT_REND_WITH_HEAD_ROT // TODO: move the init into IVAS_DEC_Configure() splitRendBits.bits_buf = splitRendBitsBuf; splitRendBits.bits_read = 0; splitRendBits.bits_written = 0; Loading Loading @@ -2038,8 +2039,7 @@ static ivas_error decodeG192( #ifdef SPLIT_REND_WITH_HEAD_ROT if ( ( hSplitRendFileReadWrite != NULL ) && ( arg.outputFormat == IVAS_DEC_OUTPUT_SPLIT_BINAURAL_CODED ) ) { if ( split_rend_write_bitstream_to_file( hSplitRendFileReadWrite, splitRendBits.bits_buf, &splitRendBits.bits_read, &splitRendBits.bits_written, splitRendBits.codec, splitRendBits.pose_correction ) != IVAS_ERR_OK ) if ( split_rend_write_bitstream_to_file( hSplitRendFileReadWrite, splitRendBits.bits_buf, &splitRendBits.bits_read, &splitRendBits.bits_written, splitRendBits.codec, splitRendBits.pose_correction ) != IVAS_ERR_OK ) { fprintf( stderr, "\nUnable to write to bitstream file!\n" ); exit( -1 ); Loading @@ -2049,14 +2049,14 @@ static ivas_error decodeG192( { if ( ( hSplitRendFileReadWrite != NULL ) && ( arg.outputFormat == IVAS_DEC_OUTPUT_SPLIT_BINAURAL_PCM ) ) { if ( split_rend_write_bitstream_to_file( hSplitRendFileReadWrite, splitRendBits.bits_buf, &splitRendBits.bits_read, &splitRendBits.bits_written, splitRendBits.codec, splitRendBits.pose_correction ) != IVAS_ERR_OK ) if ( split_rend_write_bitstream_to_file( hSplitRendFileReadWrite, splitRendBits.bits_buf, &splitRendBits.bits_read, &splitRendBits.bits_written, splitRendBits.codec, splitRendBits.pose_correction ) != IVAS_ERR_OK ) { fprintf( stderr, "\nUnable to write to bitstream file!\n" ); exit( -1 ); } } #endif if ( delayNumSamples < nOutSamples ) { if ( ( error = AudioFileWriter_write( afWriter, &pcmBuf[delayNumSamples * nOutChannels], nOutSamples * nOutChannels - ( delayNumSamples * nOutChannels ) ) ) != IVAS_ERR_OK ) Loading Loading @@ -2211,6 +2211,7 @@ cleanup: #ifdef SPLIT_REND_WITH_HEAD_ROT } #endif MasaFileWriter_close( &masaWriter ); for ( i = 0; i < IVAS_MAX_NUM_OBJECTS; i++ ) { Loading Loading @@ -3030,7 +3031,6 @@ static ivas_error decodeVariableSpeed( if ( decodedGoodFrame ) { #ifdef SPLIT_REND_WITH_HEAD_ROT SplitFileReadWrite *hSplitRendFileReadWrite = NULL; #endif error = initOnFirstGoodFrame( Loading lib_dec/ivas_binRenderer_internal.c +36 −38 Original line number Diff line number Diff line Loading @@ -153,7 +153,6 @@ static ivas_error ivas_binRenderer_convModuleOpen( int16_t pos_idx; #endif /*-----------------------------------------------------------------* * prepare library opening *-----------------------------------------------------------------*/ Loading Loading @@ -708,6 +707,7 @@ static void ivas_binaural_obtain_DMX( return; } #ifdef SPLIT_REND_WITH_HEAD_ROT /*------------------------------------------------------------------------- * ivas_rend_openCldfbRend() Loading Loading @@ -761,6 +761,7 @@ ivas_error ivas_rend_openCldfbRend( { hBinRenderer->conv_band = convBand; } hBinRenderer->hInputSetup->is_loudspeaker_setup = 0; getAudioConfigNumChannels( inConfig, &hBinRenderer->hInputSetup->nchan_out_woLFE ); Loading @@ -776,15 +777,19 @@ ivas_error ivas_rend_openCldfbRend( { hBinRenderer->numPoses = 1; } /* Load HRTF tables */ ivas_binaural_hrtf_open( &pCldfbRend->hHrtfFastConv ); if ( ( error = ivas_binaural_hrtf_open( &pCldfbRend->hHrtfFastConv ) ) != IVAS_ERR_OK ) { return error; } /* Allocate memories and buffers needed for convolutional module */ if ( ( error = ivas_binRenderer_convModuleOpen( hBinRenderer, RENDERER_BINAURAL_FASTCONV, hBinRenderer->hInputSetup->is_loudspeaker_setup, in_config, pCldfbRend->hHrtfFastConv, hBinRenderer->numPoses ) ) != IVAS_ERR_OK ) if ( ( error = ivas_binRenderer_convModuleOpen( hBinRenderer, RENDERER_BINAURAL_FASTCONV, hBinRenderer->hInputSetup->is_loudspeaker_setup, in_config, pCldfbRend->hHrtfFastConv, hBinRenderer->numPoses ) ) != IVAS_ERR_OK ) { return error; } pCldfbRend->binaural_latency_ns = (int32_t) ( FASTCONV_HOA3_latency_s * 1000000000.f ); hBinRenderer->hReverb = NULL; hBinRenderer->hEFAPdata = NULL; Loading @@ -793,7 +798,7 @@ ivas_error ivas_rend_openCldfbRend( return error; } #endif /* SPLIT_REND_WITH_HEAD_ROT */ #endif /*------------------------------------------------------------------------- Loading Loading @@ -831,8 +836,7 @@ ivas_error ivas_binRenderer_open( } #ifdef SPLIT_REND_WITH_HEAD_ROT if ( ( st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL_SPLIT_CODED ) || ( st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) ) if ( st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL_SPLIT_CODED || st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) { #ifdef SPLIT_REND_WITH_HEAD_ROT_DEBUG hBinRenderer->numPoses = st_ivas->hsplitBinRend.splitrend.multiBinPoseData.num_poses + 1; Loading Loading @@ -886,11 +890,7 @@ ivas_error ivas_binRenderer_open( IVAS_OUTPUT_SETUP out_setup; /* Allocate memories and buffers needed for convolutional module in CICP19 */ if ( ( error = ivas_binRenderer_convModuleOpen( hBinRenderer, st_ivas->renderer_type, 1, AUDIO_CONFIG_7_1_4, st_ivas->hHrtfFastConv if ( ( error = ivas_binRenderer_convModuleOpen( hBinRenderer, st_ivas->renderer_type, 1, AUDIO_CONFIG_7_1_4, st_ivas->hHrtfFastConv #ifdef SPLIT_REND_WITH_HEAD_ROT , hBinRenderer->numPoses Loading @@ -916,11 +916,7 @@ ivas_error ivas_binRenderer_open( else { /* Allocate memories and buffers needed for convolutional module */ if ( ( error = ivas_binRenderer_convModuleOpen( hBinRenderer, st_ivas->renderer_type, st_ivas->hIntSetup.is_loudspeaker_setup, st_ivas->hIntSetup.output_config, st_ivas->hHrtfFastConv if ( ( error = ivas_binRenderer_convModuleOpen( hBinRenderer, st_ivas->renderer_type, st_ivas->hIntSetup.is_loudspeaker_setup, st_ivas->hIntSetup.output_config, st_ivas->hHrtfFastConv #ifdef SPLIT_REND_WITH_HEAD_ROT , hBinRenderer->numPoses Loading Loading @@ -970,19 +966,13 @@ ivas_error ivas_binRenderer_open( if ( st_ivas->renderer_type == RENDERER_BINAURAL_FASTCONV_ROOM && st_ivas->hIntSetup.output_config == AUDIO_CONFIG_BINAURAL_ROOM_REVERB ) #endif { if ( ( error = ivas_binaural_reverb_open( &( hBinRenderer->hReverb ), hBinRenderer->conv_band, hBinRenderer->timeSlots, &( st_ivas->hRenderConfig->roomAcoustics ), st_ivas->hIntSetup.output_config, st_ivas->hDecoderConfig->output_Fs, if ( ( error = ivas_binaural_reverb_open( &( hBinRenderer->hReverb ), hBinRenderer->conv_band, hBinRenderer->timeSlots, &( st_ivas->hRenderConfig->roomAcoustics ), st_ivas->hIntSetup.output_config, st_ivas->hDecoderConfig->output_Fs, #ifdef FIX_571_REVERB_NOT_ACTIVATED_ISM RENDERER_BINAURAL_FASTCONV, #else RENDERER_BINAURAL_FASTCONV_ROOM, #endif st_ivas->hHrtfFastConv, st_ivas->hHrtfParambin ) ) != IVAS_ERR_OK ) st_ivas->hHrtfFastConv, st_ivas->hHrtfParambin ) ) != IVAS_ERR_OK ) { return error; } Loading Loading @@ -1041,7 +1031,7 @@ static void ivas_binRenderer_convModuleClose( BINAURAL_RENDERER_HANDLE *hBinRenderer /* i/o: fastconv binaural renderer handle */ #ifdef SPLIT_REND_WITH_HEAD_ROT , int16_t num_poses const int16_t num_poses #endif ) { Loading Loading @@ -1118,8 +1108,7 @@ static void ivas_binRenderer_convModuleClose( free( hBinRenConvModule->filterStatesLeftImag ); hBinRenConvModule->filterStatesLeftImag = NULL; #else /* SPLIT_REND_WITH_HEAD_ROT */ #else for ( bandIdx = 0; bandIdx < ( *hBinRenderer )->conv_band; bandIdx++ ) { for ( chIdx = 0; chIdx < ( *hBinRenderer )->nInChannels; chIdx++ ) Loading @@ -1143,8 +1132,7 @@ static void ivas_binRenderer_convModuleClose( free( hBinRenConvModule->filterStatesLeftImag ); hBinRenConvModule->filterStatesLeftImag = NULL; #endif /* SPLIT_REND_WITH_HEAD_ROT */ #endif free( ( *hBinRenderer )->hBinRenConvModule ); ( *hBinRenderer )->hBinRenConvModule = NULL; Loading @@ -1152,12 +1140,14 @@ static void ivas_binRenderer_convModuleClose( return; } #ifdef SPLIT_REND_WITH_HEAD_ROT /*------------------------------------------------------------------------- * ivas_rend_openCldfbRend() * * Close CLDFB based fastconv binaural renderer memories *------------------------------------------------------------------------*/ void ivas_rend_closeCldfbRend( CLDFB_REND_WRAPPER *pCldfbRend ) { if ( pCldfbRend->hCldfbRend->hInputSetup != NULL ) Loading @@ -1165,13 +1155,16 @@ void ivas_rend_closeCldfbRend( CLDFB_REND_WRAPPER *pCldfbRend ) free( pCldfbRend->hCldfbRend->hInputSetup ); pCldfbRend->hCldfbRend->hInputSetup = NULL; } ivas_binRenderer_close( &pCldfbRend->hCldfbRend ); ivas_HRTF_fastconv_binary_close( &pCldfbRend->hHrtfFastConv ); return; } #endif /*------------------------------------------------------------------------- * ivas_binRenderer_close() * Loading Loading @@ -1244,6 +1237,7 @@ void ivas_binaural_add_LFE( { gain = ( ( st_ivas->hCrendWrapper != NULL ) && ( st_ivas->hCrendWrapper->hHrtfCrend != NULL ) ) ? st_ivas->hCrendWrapper->hHrtfCrend->gain_lfe : GAIN_LFE; } for ( idx_lfe = 0; idx_lfe < st_ivas->hIntSetup.num_lfe; idx_lfe++ ) { v_multc( input_f[st_ivas->hIntSetup.index_lfe[idx_lfe]], gain, input_f[st_ivas->hIntSetup.index_lfe[idx_lfe]], output_frame ); Loading Loading @@ -1323,8 +1317,7 @@ void ivas_binaural_cldfb( NULL, #endif Cldfb_RealBuffer_Binaural, Cldfb_ImagBuffer_Binaural, Cldfb_RealBuffer, Cldfb_ImagBuffer ); Cldfb_RealBuffer, Cldfb_ImagBuffer ); /* Implement CLDFB synthesis */ for ( ch = 0; ch < BINAURAL_CHANNELS; ch++ ) Loading Loading @@ -1670,7 +1663,14 @@ void ivas_binRenderer( return; } #ifdef SPLIT_REND_WITH_HEAD_ROT /*------------------------------------------------------------------------- * ivas_rend_CldfbMultiBinRendProcess() * * *-------------------------------------------------------------------------*/ void ivas_rend_CldfbMultiBinRendProcess( const BINAURAL_RENDERER_HANDLE hCldfbRend, const COMBINED_ORIENTATION_HANDLE *pCombinedOrientationData, Loading @@ -1693,7 +1693,6 @@ void ivas_rend_CldfbMultiBinRendProcess( float Cldfb_ImagBuffer_Binaural[MAX_HEAD_ROT_POSES][BINAURAL_CHANNELS][MAX_PARAM_SPATIAL_SUBFRAMES][CLDFB_NO_CHANNELS_MAX]; #endif for ( sf_idx = 0; sf_idx < MAX_PARAM_SPATIAL_SUBFRAMES; sf_idx++ ) { for ( slot_idx = 0; slot_idx < MAX_PARAM_SPATIAL_SUBFRAMES; slot_idx++ ) Loading Loading @@ -1721,15 +1720,14 @@ void ivas_rend_CldfbMultiBinRendProcess( } ( *pCombinedOrientationData )->shd_rot_max_order = -1; } #ifdef SPLIT_REND_WITH_HEAD_ROT_DEBUG head_track_post.num_quaternions = 0; head_track_post.shd_rot_max_order = -1; head_track_post.Quaternions[0] = ivas_split_rend_get_sf_rot_data( pHeadRotData->headPositionsPostRend, sf_idx ); #endif ivas_binRenderer( hCldfbRend, pMultiBinPoseData, *pCombinedOrientationData, sf_idx, MAX_PARAM_SPATIAL_SUBFRAMES, ivas_binRenderer( hCldfbRend, pMultiBinPoseData, *pCombinedOrientationData, sf_idx, MAX_PARAM_SPATIAL_SUBFRAMES, #ifdef SPLIT_REND_WITH_HEAD_ROT_DEBUG &head_track_post, #endif Loading lib_dec/ivas_dec.c +21 −17 Original line number Diff line number Diff line Loading @@ -121,6 +121,10 @@ ivas_error ivas_dec( } #ifdef SPLIT_REND_WITH_HEAD_ROT /*----------------------------------------------------------------* * Split rendering setup *----------------------------------------------------------------*/ if ( output_config == AUDIO_CONFIG_BINAURAL_SPLIT_CODED || output_config == AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) { assert( ( st_ivas->ivas_format == SBA_FORMAT || Loading Loading @@ -274,7 +278,10 @@ ivas_error ivas_dec( #ifdef SPLIT_REND_WITH_HEAD_ROT if ( output_config == AUDIO_CONFIG_BINAURAL_SPLIT_CODED || output_config == AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) { ObjRenderIvasFrame_splitBinaural( st_ivas, output, output_frame ); if ( ( error = ObjRenderIvasFrame_splitBinaural( st_ivas, output, output_frame ) ) != IVAS_ERR_OK ) { return error; } } else { Loading Loading @@ -567,7 +574,10 @@ ivas_error ivas_dec( #ifdef SPLIT_REND_WITH_HEAD_ROT if ( output_config == AUDIO_CONFIG_BINAURAL_SPLIT_CODED || output_config == AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) { ObjRenderIvasFrame_splitBinaural( st_ivas, output, output_frame ); if ( ( error = ObjRenderIvasFrame_splitBinaural( st_ivas, output, output_frame ) ) != IVAS_ERR_OK ) { return error; } } else { Loading Loading @@ -621,20 +631,9 @@ ivas_error ivas_dec( if ( st_ivas->renderer_type == RENDERER_BINAURAL_MIXER_CONV || st_ivas->renderer_type == RENDERER_BINAURAL_MIXER_CONV_ROOM ) { #ifdef SPLIT_REND_WITH_HEAD_ROT if ( ( output_config == AUDIO_CONFIG_BINAURAL_SPLIT_CODED ) || ( output_config == AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) ) { ivas_rend_crendProcessSplitBin( st_ivas->hCrendWrapper, st_ivas->intern_config, st_ivas->hOutSetup.output_config, &st_ivas->hsplitBinRend.splitrend.multiBinPoseData, st_ivas->hDecoderConfig, st_ivas->hCombinedOrientationData, &st_ivas->hIntSetup, st_ivas->hEFAPdata, p_output, output_Fs ); if ( output_config == AUDIO_CONFIG_BINAURAL_SPLIT_CODED || output_config == AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) { ivas_rend_crendProcessSplitBin( st_ivas->hCrendWrapper, st_ivas->intern_config, st_ivas->hOutSetup.output_config, &st_ivas->hsplitBinRend.splitrend.multiBinPoseData, st_ivas->hDecoderConfig, st_ivas->hCombinedOrientationData, &st_ivas->hIntSetup, st_ivas->hEFAPdata, p_output, output_Fs ); } else { Loading @@ -649,6 +648,7 @@ ivas_error ivas_dec( { return error; } #ifdef SPLIT_REND_WITH_HEAD_ROT ivas_binaural_add_LFE( st_ivas, output_frame, p_output, p_output ); } Loading @@ -675,12 +675,15 @@ ivas_error ivas_dec( #ifdef SPLIT_REND_WITH_HEAD_ROT if ( output_config == AUDIO_CONFIG_BINAURAL_SPLIT_CODED || output_config == AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) { ObjRenderIvasFrame_splitBinaural( st_ivas, output, output_frame ); if ( ( error = ObjRenderIvasFrame_splitBinaural( st_ivas, output, output_frame ) ) != IVAS_ERR_OK ) { return error; } } else { #endif if ( ( ivas_td_binaural_renderer( st_ivas, p_output, output_frame ) ) != IVAS_ERR_OK ) if ( ( error = ivas_td_binaural_renderer( st_ivas, p_output, output_frame ) ) != IVAS_ERR_OK ) { return error; } Loading Loading @@ -838,6 +841,7 @@ ivas_error ivas_dec( IVAS_DEC_SPLIT_REND_WRAPPER *hSplitBinRend; int16_t max_band; int16_t pcm_out; hSplitBinRend = &st_ivas->hsplitBinRend; max_band = (int16_t) ( ( BINAURAL_MAXBANDS * output_Fs ) / 48000 ); pcm_out = ( output_config == AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) ? 1 : 0; Loading lib_dec/ivas_dirac_dec.c +4 −9 Original line number Diff line number Diff line Loading @@ -1729,7 +1729,6 @@ void ivas_dirac_dec_render_sf( float Cldfb_RealBuffer_Binaural[BINAURAL_CHANNELS][MAX_PARAM_SPATIAL_SUBFRAMES][CLDFB_NO_CHANNELS_MAX]; float Cldfb_ImagBuffer_Binaural[BINAURAL_CHANNELS][MAX_PARAM_SPATIAL_SUBFRAMES][CLDFB_NO_CHANNELS_MAX]; #endif int16_t index, num_freq_bands; /* local copies of azi, ele, diffuseness */ Loading Loading @@ -2295,7 +2294,6 @@ void ivas_dirac_dec_render_sf( qualityBasedSmFactor *= qualityBasedSmFactor; } ivas_dirac_dec_output_synthesis_process_subframe_psd_ls( Cldfb_RealBuffer, Cldfb_ImagBuffer, hSpatParamRendCom, Loading Loading @@ -2329,10 +2327,10 @@ void ivas_dirac_dec_render_sf( Cldfb_ImagBuffer ); #ifdef SPLIT_REND_WITH_HEAD_ROT if ( ( st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL_SPLIT_CODED ) || ( st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) ) if ( st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL_SPLIT_CODED || st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) { int16_t pos_idx; #ifdef SPLIT_REND_WITH_HEAD_ROT_DEBUG for ( pos_idx = 0; pos_idx < st_ivas->hBinRenderer->numPoses; pos_idx++ ) #else Loading @@ -2350,6 +2348,7 @@ void ivas_dirac_dec_render_sf( } } #endif /* Inverse CLDFB*/ for ( ch = 0; ch < st_ivas->hDecoderConfig->nchan_out; ch++ ) { Loading @@ -2368,11 +2367,7 @@ void ivas_dirac_dec_render_sf( #endif } cldfbSynthesis( RealBuffer, ImagBuffer, &( output_f[ch][index_slot * hSpatParamRendCom->num_freq_bands] ), hSpatParamRendCom->num_freq_bands * hSpatParamRendCom->subframe_nbslots[subframe_idx], st_ivas->cldfbSynDec[ch] ); cldfbSynthesis( RealBuffer, ImagBuffer, &( output_f[ch][index_slot * hSpatParamRendCom->num_freq_bands] ), hSpatParamRendCom->num_freq_bands * hSpatParamRendCom->subframe_nbslots[subframe_idx], st_ivas->cldfbSynDec[ch] ); } } else if ( st_ivas->ivas_format == SBA_FORMAT ) Loading lib_dec/ivas_init_dec.c +8 −5 Original line number Diff line number Diff line Loading @@ -1791,11 +1791,6 @@ void ivas_initialize_handles_dec( /* rendering handles */ st_ivas->hBinRenderer = NULL; #ifdef SPLIT_REND_WITH_HEAD_ROT st_ivas->hsplitBinRend.hMultiBinCldfbData = NULL; st_ivas->hsplitBinRend.hSplitRendBits = NULL; ivas_init_split_rend_handles( &st_ivas->hsplitBinRend.splitrend ); #endif st_ivas->hDiracDecBin = NULL; st_ivas->hDirACRend = NULL; st_ivas->hSpatParamRendCom = NULL; Loading @@ -1819,6 +1814,14 @@ void ivas_initialize_handles_dec( st_ivas->hExtOrientationData = NULL; st_ivas->hCombinedOrientationData = NULL; #ifdef SPLIT_REND_WITH_HEAD_ROT /* split binaural rendering handles */ st_ivas->hsplitBinRend.hMultiBinCldfbData = NULL; st_ivas->hsplitBinRend.hSplitRendBits = NULL; ivas_init_split_rend_handles( &st_ivas->hsplitBinRend.splitrend ); #endif /* JBM handles */ st_ivas->hTcBuffer = NULL; #ifdef FIX_470_MASA_JBM_EXT st_ivas->hJbmMetadata = NULL; Loading Loading
apps/decoder.c +11 −11 Original line number Diff line number Diff line Loading @@ -427,6 +427,7 @@ int main( /*------------------------------------------------------------------------------------------* * Configure the decoder *------------------------------------------------------------------------------------------*/ #ifdef SPLIT_REND_WITH_HEAD_ROT if ( arg.outputFormat == IVAS_DEC_OUTPUT_SPLIT_BINAURAL_CODED || arg.outputFormat == IVAS_DEC_OUTPUT_SPLIT_BINAURAL_PCM ) { Loading Loading @@ -582,8 +583,7 @@ int main( /* sanity check */ #ifdef SPLIT_REND_WITH_HEAD_ROT if ( arg.outputFormat != IVAS_DEC_OUTPUT_BINAURAL && arg.outputFormat != IVAS_DEC_OUTPUT_BINAURAL_ROOM_IR && arg.outputFormat != IVAS_DEC_OUTPUT_BINAURAL_ROOM_REVERB && arg.outputFormat != IVAS_DEC_OUTPUT_SPLIT_BINAURAL_CODED && arg.outputFormat != IVAS_DEC_OUTPUT_SPLIT_BINAURAL_PCM ) arg.outputFormat != IVAS_DEC_OUTPUT_SPLIT_BINAURAL_CODED && arg.outputFormat != IVAS_DEC_OUTPUT_SPLIT_BINAURAL_PCM ) { fprintf( stderr, "\nExternal Renderer Config is supported only when binaural output configurations is used as output OR when Split rendering mode is enabled. Exiting. \n" ); exit( -1 ); Loading Loading @@ -1561,9 +1561,9 @@ static ivas_error initOnFirstGoodFrame( fprintf( stderr, "\nUnable to get delay of decoder: %s\n", ivas_error_to_string( error ) ); return error; } #ifdef SPLIT_REND_WITH_HEAD_ROT if ( ( arg.outputFormat == IVAS_DEC_OUTPUT_SPLIT_BINAURAL_PCM ) || ( arg.outputFormat == IVAS_DEC_OUTPUT_SPLIT_BINAURAL_CODED ) ) if ( arg.outputFormat == IVAS_DEC_OUTPUT_SPLIT_BINAURAL_PCM || arg.outputFormat == IVAS_DEC_OUTPUT_SPLIT_BINAURAL_CODED ) { pFullDelayNumSamples[0] = 0; } Loading Loading @@ -1642,8 +1642,8 @@ static ivas_error initOnFirstGoodFrame( IVAS_SPLIT_REND_BITS splitRendBitsZero; splitRendBitsZero.bits_written = 0; splitRendBitsZero.bits_read = 0; if ( split_rend_write_bitstream_to_file( *hSplitRendFileReadWrite, splitRendBitsZero.bits_buf, &splitRendBitsZero.bits_read, &splitRendBitsZero.bits_written, -1, IVAS_SPLIT_REND_POSE_CORRECTION_MODE_NONE ) != IVAS_ERR_OK ) if ( split_rend_write_bitstream_to_file( *hSplitRendFileReadWrite, splitRendBitsZero.bits_buf, &splitRendBitsZero.bits_read, &splitRendBitsZero.bits_written, -1, IVAS_SPLIT_REND_POSE_CORRECTION_MODE_NONE ) != IVAS_ERR_OK ) { fprintf( stderr, "\nUnable to write to bitstream file!\n" ); exit( -1 ); Loading Loading @@ -1825,6 +1825,7 @@ static ivas_error decodeG192( #endif #ifdef SPLIT_REND_WITH_HEAD_ROT // TODO: move the init into IVAS_DEC_Configure() splitRendBits.bits_buf = splitRendBitsBuf; splitRendBits.bits_read = 0; splitRendBits.bits_written = 0; Loading Loading @@ -2038,8 +2039,7 @@ static ivas_error decodeG192( #ifdef SPLIT_REND_WITH_HEAD_ROT if ( ( hSplitRendFileReadWrite != NULL ) && ( arg.outputFormat == IVAS_DEC_OUTPUT_SPLIT_BINAURAL_CODED ) ) { if ( split_rend_write_bitstream_to_file( hSplitRendFileReadWrite, splitRendBits.bits_buf, &splitRendBits.bits_read, &splitRendBits.bits_written, splitRendBits.codec, splitRendBits.pose_correction ) != IVAS_ERR_OK ) if ( split_rend_write_bitstream_to_file( hSplitRendFileReadWrite, splitRendBits.bits_buf, &splitRendBits.bits_read, &splitRendBits.bits_written, splitRendBits.codec, splitRendBits.pose_correction ) != IVAS_ERR_OK ) { fprintf( stderr, "\nUnable to write to bitstream file!\n" ); exit( -1 ); Loading @@ -2049,14 +2049,14 @@ static ivas_error decodeG192( { if ( ( hSplitRendFileReadWrite != NULL ) && ( arg.outputFormat == IVAS_DEC_OUTPUT_SPLIT_BINAURAL_PCM ) ) { if ( split_rend_write_bitstream_to_file( hSplitRendFileReadWrite, splitRendBits.bits_buf, &splitRendBits.bits_read, &splitRendBits.bits_written, splitRendBits.codec, splitRendBits.pose_correction ) != IVAS_ERR_OK ) if ( split_rend_write_bitstream_to_file( hSplitRendFileReadWrite, splitRendBits.bits_buf, &splitRendBits.bits_read, &splitRendBits.bits_written, splitRendBits.codec, splitRendBits.pose_correction ) != IVAS_ERR_OK ) { fprintf( stderr, "\nUnable to write to bitstream file!\n" ); exit( -1 ); } } #endif if ( delayNumSamples < nOutSamples ) { if ( ( error = AudioFileWriter_write( afWriter, &pcmBuf[delayNumSamples * nOutChannels], nOutSamples * nOutChannels - ( delayNumSamples * nOutChannels ) ) ) != IVAS_ERR_OK ) Loading Loading @@ -2211,6 +2211,7 @@ cleanup: #ifdef SPLIT_REND_WITH_HEAD_ROT } #endif MasaFileWriter_close( &masaWriter ); for ( i = 0; i < IVAS_MAX_NUM_OBJECTS; i++ ) { Loading Loading @@ -3030,7 +3031,6 @@ static ivas_error decodeVariableSpeed( if ( decodedGoodFrame ) { #ifdef SPLIT_REND_WITH_HEAD_ROT SplitFileReadWrite *hSplitRendFileReadWrite = NULL; #endif error = initOnFirstGoodFrame( Loading
lib_dec/ivas_binRenderer_internal.c +36 −38 Original line number Diff line number Diff line Loading @@ -153,7 +153,6 @@ static ivas_error ivas_binRenderer_convModuleOpen( int16_t pos_idx; #endif /*-----------------------------------------------------------------* * prepare library opening *-----------------------------------------------------------------*/ Loading Loading @@ -708,6 +707,7 @@ static void ivas_binaural_obtain_DMX( return; } #ifdef SPLIT_REND_WITH_HEAD_ROT /*------------------------------------------------------------------------- * ivas_rend_openCldfbRend() Loading Loading @@ -761,6 +761,7 @@ ivas_error ivas_rend_openCldfbRend( { hBinRenderer->conv_band = convBand; } hBinRenderer->hInputSetup->is_loudspeaker_setup = 0; getAudioConfigNumChannels( inConfig, &hBinRenderer->hInputSetup->nchan_out_woLFE ); Loading @@ -776,15 +777,19 @@ ivas_error ivas_rend_openCldfbRend( { hBinRenderer->numPoses = 1; } /* Load HRTF tables */ ivas_binaural_hrtf_open( &pCldfbRend->hHrtfFastConv ); if ( ( error = ivas_binaural_hrtf_open( &pCldfbRend->hHrtfFastConv ) ) != IVAS_ERR_OK ) { return error; } /* Allocate memories and buffers needed for convolutional module */ if ( ( error = ivas_binRenderer_convModuleOpen( hBinRenderer, RENDERER_BINAURAL_FASTCONV, hBinRenderer->hInputSetup->is_loudspeaker_setup, in_config, pCldfbRend->hHrtfFastConv, hBinRenderer->numPoses ) ) != IVAS_ERR_OK ) if ( ( error = ivas_binRenderer_convModuleOpen( hBinRenderer, RENDERER_BINAURAL_FASTCONV, hBinRenderer->hInputSetup->is_loudspeaker_setup, in_config, pCldfbRend->hHrtfFastConv, hBinRenderer->numPoses ) ) != IVAS_ERR_OK ) { return error; } pCldfbRend->binaural_latency_ns = (int32_t) ( FASTCONV_HOA3_latency_s * 1000000000.f ); hBinRenderer->hReverb = NULL; hBinRenderer->hEFAPdata = NULL; Loading @@ -793,7 +798,7 @@ ivas_error ivas_rend_openCldfbRend( return error; } #endif /* SPLIT_REND_WITH_HEAD_ROT */ #endif /*------------------------------------------------------------------------- Loading Loading @@ -831,8 +836,7 @@ ivas_error ivas_binRenderer_open( } #ifdef SPLIT_REND_WITH_HEAD_ROT if ( ( st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL_SPLIT_CODED ) || ( st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) ) if ( st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL_SPLIT_CODED || st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) { #ifdef SPLIT_REND_WITH_HEAD_ROT_DEBUG hBinRenderer->numPoses = st_ivas->hsplitBinRend.splitrend.multiBinPoseData.num_poses + 1; Loading Loading @@ -886,11 +890,7 @@ ivas_error ivas_binRenderer_open( IVAS_OUTPUT_SETUP out_setup; /* Allocate memories and buffers needed for convolutional module in CICP19 */ if ( ( error = ivas_binRenderer_convModuleOpen( hBinRenderer, st_ivas->renderer_type, 1, AUDIO_CONFIG_7_1_4, st_ivas->hHrtfFastConv if ( ( error = ivas_binRenderer_convModuleOpen( hBinRenderer, st_ivas->renderer_type, 1, AUDIO_CONFIG_7_1_4, st_ivas->hHrtfFastConv #ifdef SPLIT_REND_WITH_HEAD_ROT , hBinRenderer->numPoses Loading @@ -916,11 +916,7 @@ ivas_error ivas_binRenderer_open( else { /* Allocate memories and buffers needed for convolutional module */ if ( ( error = ivas_binRenderer_convModuleOpen( hBinRenderer, st_ivas->renderer_type, st_ivas->hIntSetup.is_loudspeaker_setup, st_ivas->hIntSetup.output_config, st_ivas->hHrtfFastConv if ( ( error = ivas_binRenderer_convModuleOpen( hBinRenderer, st_ivas->renderer_type, st_ivas->hIntSetup.is_loudspeaker_setup, st_ivas->hIntSetup.output_config, st_ivas->hHrtfFastConv #ifdef SPLIT_REND_WITH_HEAD_ROT , hBinRenderer->numPoses Loading Loading @@ -970,19 +966,13 @@ ivas_error ivas_binRenderer_open( if ( st_ivas->renderer_type == RENDERER_BINAURAL_FASTCONV_ROOM && st_ivas->hIntSetup.output_config == AUDIO_CONFIG_BINAURAL_ROOM_REVERB ) #endif { if ( ( error = ivas_binaural_reverb_open( &( hBinRenderer->hReverb ), hBinRenderer->conv_band, hBinRenderer->timeSlots, &( st_ivas->hRenderConfig->roomAcoustics ), st_ivas->hIntSetup.output_config, st_ivas->hDecoderConfig->output_Fs, if ( ( error = ivas_binaural_reverb_open( &( hBinRenderer->hReverb ), hBinRenderer->conv_band, hBinRenderer->timeSlots, &( st_ivas->hRenderConfig->roomAcoustics ), st_ivas->hIntSetup.output_config, st_ivas->hDecoderConfig->output_Fs, #ifdef FIX_571_REVERB_NOT_ACTIVATED_ISM RENDERER_BINAURAL_FASTCONV, #else RENDERER_BINAURAL_FASTCONV_ROOM, #endif st_ivas->hHrtfFastConv, st_ivas->hHrtfParambin ) ) != IVAS_ERR_OK ) st_ivas->hHrtfFastConv, st_ivas->hHrtfParambin ) ) != IVAS_ERR_OK ) { return error; } Loading Loading @@ -1041,7 +1031,7 @@ static void ivas_binRenderer_convModuleClose( BINAURAL_RENDERER_HANDLE *hBinRenderer /* i/o: fastconv binaural renderer handle */ #ifdef SPLIT_REND_WITH_HEAD_ROT , int16_t num_poses const int16_t num_poses #endif ) { Loading Loading @@ -1118,8 +1108,7 @@ static void ivas_binRenderer_convModuleClose( free( hBinRenConvModule->filterStatesLeftImag ); hBinRenConvModule->filterStatesLeftImag = NULL; #else /* SPLIT_REND_WITH_HEAD_ROT */ #else for ( bandIdx = 0; bandIdx < ( *hBinRenderer )->conv_band; bandIdx++ ) { for ( chIdx = 0; chIdx < ( *hBinRenderer )->nInChannels; chIdx++ ) Loading @@ -1143,8 +1132,7 @@ static void ivas_binRenderer_convModuleClose( free( hBinRenConvModule->filterStatesLeftImag ); hBinRenConvModule->filterStatesLeftImag = NULL; #endif /* SPLIT_REND_WITH_HEAD_ROT */ #endif free( ( *hBinRenderer )->hBinRenConvModule ); ( *hBinRenderer )->hBinRenConvModule = NULL; Loading @@ -1152,12 +1140,14 @@ static void ivas_binRenderer_convModuleClose( return; } #ifdef SPLIT_REND_WITH_HEAD_ROT /*------------------------------------------------------------------------- * ivas_rend_openCldfbRend() * * Close CLDFB based fastconv binaural renderer memories *------------------------------------------------------------------------*/ void ivas_rend_closeCldfbRend( CLDFB_REND_WRAPPER *pCldfbRend ) { if ( pCldfbRend->hCldfbRend->hInputSetup != NULL ) Loading @@ -1165,13 +1155,16 @@ void ivas_rend_closeCldfbRend( CLDFB_REND_WRAPPER *pCldfbRend ) free( pCldfbRend->hCldfbRend->hInputSetup ); pCldfbRend->hCldfbRend->hInputSetup = NULL; } ivas_binRenderer_close( &pCldfbRend->hCldfbRend ); ivas_HRTF_fastconv_binary_close( &pCldfbRend->hHrtfFastConv ); return; } #endif /*------------------------------------------------------------------------- * ivas_binRenderer_close() * Loading Loading @@ -1244,6 +1237,7 @@ void ivas_binaural_add_LFE( { gain = ( ( st_ivas->hCrendWrapper != NULL ) && ( st_ivas->hCrendWrapper->hHrtfCrend != NULL ) ) ? st_ivas->hCrendWrapper->hHrtfCrend->gain_lfe : GAIN_LFE; } for ( idx_lfe = 0; idx_lfe < st_ivas->hIntSetup.num_lfe; idx_lfe++ ) { v_multc( input_f[st_ivas->hIntSetup.index_lfe[idx_lfe]], gain, input_f[st_ivas->hIntSetup.index_lfe[idx_lfe]], output_frame ); Loading Loading @@ -1323,8 +1317,7 @@ void ivas_binaural_cldfb( NULL, #endif Cldfb_RealBuffer_Binaural, Cldfb_ImagBuffer_Binaural, Cldfb_RealBuffer, Cldfb_ImagBuffer ); Cldfb_RealBuffer, Cldfb_ImagBuffer ); /* Implement CLDFB synthesis */ for ( ch = 0; ch < BINAURAL_CHANNELS; ch++ ) Loading Loading @@ -1670,7 +1663,14 @@ void ivas_binRenderer( return; } #ifdef SPLIT_REND_WITH_HEAD_ROT /*------------------------------------------------------------------------- * ivas_rend_CldfbMultiBinRendProcess() * * *-------------------------------------------------------------------------*/ void ivas_rend_CldfbMultiBinRendProcess( const BINAURAL_RENDERER_HANDLE hCldfbRend, const COMBINED_ORIENTATION_HANDLE *pCombinedOrientationData, Loading @@ -1693,7 +1693,6 @@ void ivas_rend_CldfbMultiBinRendProcess( float Cldfb_ImagBuffer_Binaural[MAX_HEAD_ROT_POSES][BINAURAL_CHANNELS][MAX_PARAM_SPATIAL_SUBFRAMES][CLDFB_NO_CHANNELS_MAX]; #endif for ( sf_idx = 0; sf_idx < MAX_PARAM_SPATIAL_SUBFRAMES; sf_idx++ ) { for ( slot_idx = 0; slot_idx < MAX_PARAM_SPATIAL_SUBFRAMES; slot_idx++ ) Loading Loading @@ -1721,15 +1720,14 @@ void ivas_rend_CldfbMultiBinRendProcess( } ( *pCombinedOrientationData )->shd_rot_max_order = -1; } #ifdef SPLIT_REND_WITH_HEAD_ROT_DEBUG head_track_post.num_quaternions = 0; head_track_post.shd_rot_max_order = -1; head_track_post.Quaternions[0] = ivas_split_rend_get_sf_rot_data( pHeadRotData->headPositionsPostRend, sf_idx ); #endif ivas_binRenderer( hCldfbRend, pMultiBinPoseData, *pCombinedOrientationData, sf_idx, MAX_PARAM_SPATIAL_SUBFRAMES, ivas_binRenderer( hCldfbRend, pMultiBinPoseData, *pCombinedOrientationData, sf_idx, MAX_PARAM_SPATIAL_SUBFRAMES, #ifdef SPLIT_REND_WITH_HEAD_ROT_DEBUG &head_track_post, #endif Loading
lib_dec/ivas_dec.c +21 −17 Original line number Diff line number Diff line Loading @@ -121,6 +121,10 @@ ivas_error ivas_dec( } #ifdef SPLIT_REND_WITH_HEAD_ROT /*----------------------------------------------------------------* * Split rendering setup *----------------------------------------------------------------*/ if ( output_config == AUDIO_CONFIG_BINAURAL_SPLIT_CODED || output_config == AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) { assert( ( st_ivas->ivas_format == SBA_FORMAT || Loading Loading @@ -274,7 +278,10 @@ ivas_error ivas_dec( #ifdef SPLIT_REND_WITH_HEAD_ROT if ( output_config == AUDIO_CONFIG_BINAURAL_SPLIT_CODED || output_config == AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) { ObjRenderIvasFrame_splitBinaural( st_ivas, output, output_frame ); if ( ( error = ObjRenderIvasFrame_splitBinaural( st_ivas, output, output_frame ) ) != IVAS_ERR_OK ) { return error; } } else { Loading Loading @@ -567,7 +574,10 @@ ivas_error ivas_dec( #ifdef SPLIT_REND_WITH_HEAD_ROT if ( output_config == AUDIO_CONFIG_BINAURAL_SPLIT_CODED || output_config == AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) { ObjRenderIvasFrame_splitBinaural( st_ivas, output, output_frame ); if ( ( error = ObjRenderIvasFrame_splitBinaural( st_ivas, output, output_frame ) ) != IVAS_ERR_OK ) { return error; } } else { Loading Loading @@ -621,20 +631,9 @@ ivas_error ivas_dec( if ( st_ivas->renderer_type == RENDERER_BINAURAL_MIXER_CONV || st_ivas->renderer_type == RENDERER_BINAURAL_MIXER_CONV_ROOM ) { #ifdef SPLIT_REND_WITH_HEAD_ROT if ( ( output_config == AUDIO_CONFIG_BINAURAL_SPLIT_CODED ) || ( output_config == AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) ) { ivas_rend_crendProcessSplitBin( st_ivas->hCrendWrapper, st_ivas->intern_config, st_ivas->hOutSetup.output_config, &st_ivas->hsplitBinRend.splitrend.multiBinPoseData, st_ivas->hDecoderConfig, st_ivas->hCombinedOrientationData, &st_ivas->hIntSetup, st_ivas->hEFAPdata, p_output, output_Fs ); if ( output_config == AUDIO_CONFIG_BINAURAL_SPLIT_CODED || output_config == AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) { ivas_rend_crendProcessSplitBin( st_ivas->hCrendWrapper, st_ivas->intern_config, st_ivas->hOutSetup.output_config, &st_ivas->hsplitBinRend.splitrend.multiBinPoseData, st_ivas->hDecoderConfig, st_ivas->hCombinedOrientationData, &st_ivas->hIntSetup, st_ivas->hEFAPdata, p_output, output_Fs ); } else { Loading @@ -649,6 +648,7 @@ ivas_error ivas_dec( { return error; } #ifdef SPLIT_REND_WITH_HEAD_ROT ivas_binaural_add_LFE( st_ivas, output_frame, p_output, p_output ); } Loading @@ -675,12 +675,15 @@ ivas_error ivas_dec( #ifdef SPLIT_REND_WITH_HEAD_ROT if ( output_config == AUDIO_CONFIG_BINAURAL_SPLIT_CODED || output_config == AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) { ObjRenderIvasFrame_splitBinaural( st_ivas, output, output_frame ); if ( ( error = ObjRenderIvasFrame_splitBinaural( st_ivas, output, output_frame ) ) != IVAS_ERR_OK ) { return error; } } else { #endif if ( ( ivas_td_binaural_renderer( st_ivas, p_output, output_frame ) ) != IVAS_ERR_OK ) if ( ( error = ivas_td_binaural_renderer( st_ivas, p_output, output_frame ) ) != IVAS_ERR_OK ) { return error; } Loading Loading @@ -838,6 +841,7 @@ ivas_error ivas_dec( IVAS_DEC_SPLIT_REND_WRAPPER *hSplitBinRend; int16_t max_band; int16_t pcm_out; hSplitBinRend = &st_ivas->hsplitBinRend; max_band = (int16_t) ( ( BINAURAL_MAXBANDS * output_Fs ) / 48000 ); pcm_out = ( output_config == AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) ? 1 : 0; Loading
lib_dec/ivas_dirac_dec.c +4 −9 Original line number Diff line number Diff line Loading @@ -1729,7 +1729,6 @@ void ivas_dirac_dec_render_sf( float Cldfb_RealBuffer_Binaural[BINAURAL_CHANNELS][MAX_PARAM_SPATIAL_SUBFRAMES][CLDFB_NO_CHANNELS_MAX]; float Cldfb_ImagBuffer_Binaural[BINAURAL_CHANNELS][MAX_PARAM_SPATIAL_SUBFRAMES][CLDFB_NO_CHANNELS_MAX]; #endif int16_t index, num_freq_bands; /* local copies of azi, ele, diffuseness */ Loading Loading @@ -2295,7 +2294,6 @@ void ivas_dirac_dec_render_sf( qualityBasedSmFactor *= qualityBasedSmFactor; } ivas_dirac_dec_output_synthesis_process_subframe_psd_ls( Cldfb_RealBuffer, Cldfb_ImagBuffer, hSpatParamRendCom, Loading Loading @@ -2329,10 +2327,10 @@ void ivas_dirac_dec_render_sf( Cldfb_ImagBuffer ); #ifdef SPLIT_REND_WITH_HEAD_ROT if ( ( st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL_SPLIT_CODED ) || ( st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) ) if ( st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL_SPLIT_CODED || st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) { int16_t pos_idx; #ifdef SPLIT_REND_WITH_HEAD_ROT_DEBUG for ( pos_idx = 0; pos_idx < st_ivas->hBinRenderer->numPoses; pos_idx++ ) #else Loading @@ -2350,6 +2348,7 @@ void ivas_dirac_dec_render_sf( } } #endif /* Inverse CLDFB*/ for ( ch = 0; ch < st_ivas->hDecoderConfig->nchan_out; ch++ ) { Loading @@ -2368,11 +2367,7 @@ void ivas_dirac_dec_render_sf( #endif } cldfbSynthesis( RealBuffer, ImagBuffer, &( output_f[ch][index_slot * hSpatParamRendCom->num_freq_bands] ), hSpatParamRendCom->num_freq_bands * hSpatParamRendCom->subframe_nbslots[subframe_idx], st_ivas->cldfbSynDec[ch] ); cldfbSynthesis( RealBuffer, ImagBuffer, &( output_f[ch][index_slot * hSpatParamRendCom->num_freq_bands] ), hSpatParamRendCom->num_freq_bands * hSpatParamRendCom->subframe_nbslots[subframe_idx], st_ivas->cldfbSynDec[ch] ); } } else if ( st_ivas->ivas_format == SBA_FORMAT ) Loading
lib_dec/ivas_init_dec.c +8 −5 Original line number Diff line number Diff line Loading @@ -1791,11 +1791,6 @@ void ivas_initialize_handles_dec( /* rendering handles */ st_ivas->hBinRenderer = NULL; #ifdef SPLIT_REND_WITH_HEAD_ROT st_ivas->hsplitBinRend.hMultiBinCldfbData = NULL; st_ivas->hsplitBinRend.hSplitRendBits = NULL; ivas_init_split_rend_handles( &st_ivas->hsplitBinRend.splitrend ); #endif st_ivas->hDiracDecBin = NULL; st_ivas->hDirACRend = NULL; st_ivas->hSpatParamRendCom = NULL; Loading @@ -1819,6 +1814,14 @@ void ivas_initialize_handles_dec( st_ivas->hExtOrientationData = NULL; st_ivas->hCombinedOrientationData = NULL; #ifdef SPLIT_REND_WITH_HEAD_ROT /* split binaural rendering handles */ st_ivas->hsplitBinRend.hMultiBinCldfbData = NULL; st_ivas->hsplitBinRend.hSplitRendBits = NULL; ivas_init_split_rend_handles( &st_ivas->hsplitBinRend.splitrend ); #endif /* JBM handles */ st_ivas->hTcBuffer = NULL; #ifdef FIX_470_MASA_JBM_EXT st_ivas->hJbmMetadata = NULL; Loading