Loading lib_dec/ivas_dirac_output_synthesis_dec.c +33 −10 Original line number Diff line number Diff line Loading @@ -1503,6 +1503,27 @@ void ivas_dirac_dec_output_synthesis_process_subframe_psd_ls( *-----------------------------------------------------------------*/ /* store estimates for next synthesis block */ #ifdef JBM_TSM_ON_TCS if ( hDirAC->voip_active == 1 ) { mvr2r( gains_dir, h_dirac_output_synthesis_state->gains_dir_prev, num_freq_bands * hDirAC->num_outputs_dir ); mvr2r( gains_diff, h_dirac_output_synthesis_state->gains_diff_prev, num_freq_bands * hDirAC->num_outputs_dir ); /* reset values */ set_zero( h_dirac_output_synthesis_state->proto_power_smooth, num_freq_bands * hDirAC->num_outputs_dir ); if ( h_dirac_output_synthesis_state->proto_power_diff_smooth != NULL ) { set_zero( h_dirac_output_synthesis_state->proto_power_diff_smooth, h_dirac_output_synthesis_params->max_band_decorr * hDirAC->num_outputs_dir ); } set_zero( h_dirac_output_synthesis_state->cy_auto_dir_smooth, num_freq_bands * hDirAC->num_outputs_dir ); set_zero( h_dirac_output_synthesis_state->cy_cross_dir_smooth, num_freq_bands * hDirAC->num_outputs_dir ); set_zero( h_dirac_output_synthesis_state->cy_auto_diff_smooth, num_freq_bands * hDirAC->num_outputs_dir ); } else { #endif mvr2r( gains_dir, h_dirac_output_synthesis_state->gains_dir_prev, num_freq_bands * nchan_out_woLFE ); mvr2r( gains_diff, h_dirac_output_synthesis_state->gains_diff_prev, num_freq_bands * nchan_out_woLFE ); Loading @@ -1517,7 +1538,9 @@ void ivas_dirac_dec_output_synthesis_process_subframe_psd_ls( set_zero( h_dirac_output_synthesis_state->cy_auto_dir_smooth, num_freq_bands * nchan_out_woLFE ); set_zero( h_dirac_output_synthesis_state->cy_cross_dir_smooth, num_freq_bands * nchan_out_woLFE ); set_zero( h_dirac_output_synthesis_state->cy_auto_diff_smooth, num_freq_bands * nchan_out_woLFE ); #ifdef JBM_TSM_ON_TCS } #endif pop_wmops(); return; Loading lib_dec/ivas_masa_dec.c +14 −5 Original line number Diff line number Diff line Loading @@ -378,7 +378,7 @@ ivas_error ivas_masa_dec_open( int16_t nchan_to_allocate; TC_BUFFER_MODE buffer_mode; buffer_mode = TC_BUFFER_MODE_RENDERER; if ( st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_STEREO || st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_MONO ) if ( st_ivas->mc_mode == MC_MODE_MCMASA && (st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_STEREO || st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_MONO) ) { buffer_mode = TC_BUFFER_MODE_BUFFER; } Loading Loading @@ -1162,13 +1162,22 @@ ivas_error ivas_masa_dec_reconfigure( ivas_masa_set_elements( ivas_total_brate, st_ivas->mc_mode, st_ivas->nchan_transport, st_ivas->hQMetaData, &tmp, &tmp, &tmp ); if ( st_ivas->hDecoderConfig->voip_active == 1 && st_ivas->renderer_type != RENDERER_BINAURAL_PARAMETRIC && st_ivas->renderer_type != RENDERER_BINAURAL_PARAMETRIC_ROOM && st_ivas->renderer_type != RENDERER_STEREO_PARAMETRIC ) if ( st_ivas->hDecoderConfig->voip_active == 1 && st_ivas->renderer_type != RENDERER_DISABLE ) { int16_t nchan_to_allocate = ivas_jbm_dec_get_num_tc_channels( st_ivas ); if ( nchan_to_allocate != st_ivas->hTcBuffer->nchan_transport_jbm ) int16_t tc_nchan_to_allocate; int16_t tc_nchan_transport; tc_nchan_transport = ivas_jbm_dec_get_num_tc_channels( st_ivas ); tc_nchan_to_allocate = tc_nchan_transport; if ( st_ivas->renderer_type == RENDERER_BINAURAL_PARAMETRIC || st_ivas->renderer_type == RENDERER_BINAURAL_PARAMETRIC_ROOM || st_ivas->renderer_type == RENDERER_STEREO_PARAMETRIC ) { tc_nchan_to_allocate = 2 * BINAURAL_CHANNELS; } if ( tc_nchan_transport != st_ivas->hTcBuffer->nchan_transport_jbm || tc_nchan_to_allocate != st_ivas->hTcBuffer->nchan_transport_internal ) { if ( ( error = ivas_jbm_dec_tc_buffer_reconfigure( st_ivas, TC_BUFFER_MODE_RENDERER, nchan_to_allocate, nchan_to_allocate, nchan_to_allocate, NS2SA( st_ivas->hDecoderConfig->output_Fs, CLDFB_SLOT_NS ) ) ) != IVAS_ERR_OK ) if ( ( error = ivas_jbm_dec_tc_buffer_reconfigure( st_ivas, TC_BUFFER_MODE_RENDERER, tc_nchan_transport, tc_nchan_to_allocate, tc_nchan_to_allocate, NS2SA( st_ivas->hDecoderConfig->output_Fs, CLDFB_SLOT_NS ) ) ) != IVAS_ERR_OK ) { return error; } } } Loading lib_dec/ivas_mc_param_dec.c +8 −1 Original line number Diff line number Diff line Loading @@ -440,6 +440,9 @@ ivas_error ivas_param_mc_dec_open( return error; } #ifdef JBM_TSM_ON_TCS ivas_param_mc_dec_compute_interpolator( 0, 0, DEFAULT_JBM_CLDFB_TIMESLOTS, hParamMC->h_output_synthesis_params.interpolator ); #endif /* Head rotation */ if ( ( st_ivas->renderer_type == RENDERER_BINAURAL_FASTCONV || st_ivas->renderer_type == RENDERER_BINAURAL_FASTCONV_ROOM ) && st_ivas->hDecoderConfig->Opt_Headrotation ) Loading Loading @@ -960,6 +963,10 @@ ivas_error ivas_param_mc_dec_reconfig( return error; } #ifdef JBM_TSM_ON_TCS ivas_param_mc_dec_compute_interpolator( 0, 0, DEFAULT_JBM_CLDFB_TIMESLOTS, hParamMC->h_output_synthesis_params.interpolator ); #endif ivas_dirac_dec_output_synthesis_cov_init( &( hParamMC->h_output_synthesis_cov_state ), nchan_transport, nchan_out_cov, hParamMC->hMetadataPMC->num_parameter_bands, max_param_band_residual ); Loading Loading @@ -1465,7 +1472,7 @@ void ivas_param_mc_dec_digest_tc( ivas_jbm_dec_get_adapted_subframes( nCldfbSlots, hParamMC->subframe_nbslots, &hParamMC->nb_subframes ); /* BE Workaround */ if ( !st_ivas->bfi && st_ivas->hDecoderConfig->voip_active == 0 ) if ( !st_ivas->bfi && st_ivas->hDecoderConfig->voip_active == 1 ) { ivas_param_mc_dec_compute_interpolator( hParamMC->hMetadataPMC->bAttackPresent, hParamMC->hMetadataPMC->attackIndex, nCldfbSlots, hParamMC->h_output_synthesis_params.interpolator ); } Loading lib_dec/ivas_mct_dec.c +2 −1 Original line number Diff line number Diff line Loading @@ -1243,7 +1243,8 @@ static ivas_error ivas_mc_dec_reconfig( } /* reconfigure buffer */ if ( hTcBuffer->tc_buffer_mode != tc_buffer_mode_new || hTcBuffer->nchan_transport_jbm != tc_nchan_tc_new || hTcBuffer->nchan_buffer_full != tc_nchan_full_new || hTcBuffer->nchan_transport_internal != tc_nchan_allocate_new ) hTcBuffer->nchan_buffer_full != tc_nchan_full_new || hTcBuffer->nchan_transport_internal != tc_nchan_allocate_new || tc_granularity_new != hTcBuffer->n_samples_granularity ) { if ( ( error = ivas_jbm_dec_tc_buffer_reconfigure( st_ivas, tc_buffer_mode_new, tc_nchan_tc_new, tc_nchan_allocate_new, tc_nchan_full_new, tc_granularity_new ) ) != IVAS_ERR_OK ) { Loading lib_dec/ivas_sba_dec.c +5 −1 Original line number Diff line number Diff line Loading @@ -376,7 +376,7 @@ ivas_error ivas_sba_dec_reconfigure( /*-----------------------------------------------------------------* * TC buffer *-----------------------------------------------------------------*/ if ( st_ivas->hDecoderConfig->voip_active == 1 && st_ivas->renderer_type != RENDERER_BINAURAL_PARAMETRIC && st_ivas->renderer_type != RENDERER_BINAURAL_PARAMETRIC_ROOM && st_ivas->renderer_type != RENDERER_STEREO_PARAMETRIC ) if ( st_ivas->hDecoderConfig->voip_active == 1 ) { int16_t tc_nchan_to_allocate; int16_t tc_nchan_tc; Loading @@ -392,6 +392,10 @@ ivas_error ivas_sba_dec_reconfigure( tc_nchan_tc = st_ivas->hDecoderConfig->nchan_out; tc_nchan_to_allocate = tc_nchan_tc; } else if ( st_ivas->renderer_type == RENDERER_BINAURAL_PARAMETRIC || st_ivas->renderer_type == RENDERER_BINAURAL_PARAMETRIC_ROOM || st_ivas->renderer_type == RENDERER_STEREO_PARAMETRIC ) { tc_nchan_to_allocate = 2 * BINAURAL_CHANNELS; } else if ( st_ivas->sba_mode == SBA_MODE_SPAR ) { sba_order_internal = min( st_ivas->sba_analysis_order, IVAS_MAX_SBA_ORDER ); Loading Loading
lib_dec/ivas_dirac_output_synthesis_dec.c +33 −10 Original line number Diff line number Diff line Loading @@ -1503,6 +1503,27 @@ void ivas_dirac_dec_output_synthesis_process_subframe_psd_ls( *-----------------------------------------------------------------*/ /* store estimates for next synthesis block */ #ifdef JBM_TSM_ON_TCS if ( hDirAC->voip_active == 1 ) { mvr2r( gains_dir, h_dirac_output_synthesis_state->gains_dir_prev, num_freq_bands * hDirAC->num_outputs_dir ); mvr2r( gains_diff, h_dirac_output_synthesis_state->gains_diff_prev, num_freq_bands * hDirAC->num_outputs_dir ); /* reset values */ set_zero( h_dirac_output_synthesis_state->proto_power_smooth, num_freq_bands * hDirAC->num_outputs_dir ); if ( h_dirac_output_synthesis_state->proto_power_diff_smooth != NULL ) { set_zero( h_dirac_output_synthesis_state->proto_power_diff_smooth, h_dirac_output_synthesis_params->max_band_decorr * hDirAC->num_outputs_dir ); } set_zero( h_dirac_output_synthesis_state->cy_auto_dir_smooth, num_freq_bands * hDirAC->num_outputs_dir ); set_zero( h_dirac_output_synthesis_state->cy_cross_dir_smooth, num_freq_bands * hDirAC->num_outputs_dir ); set_zero( h_dirac_output_synthesis_state->cy_auto_diff_smooth, num_freq_bands * hDirAC->num_outputs_dir ); } else { #endif mvr2r( gains_dir, h_dirac_output_synthesis_state->gains_dir_prev, num_freq_bands * nchan_out_woLFE ); mvr2r( gains_diff, h_dirac_output_synthesis_state->gains_diff_prev, num_freq_bands * nchan_out_woLFE ); Loading @@ -1517,7 +1538,9 @@ void ivas_dirac_dec_output_synthesis_process_subframe_psd_ls( set_zero( h_dirac_output_synthesis_state->cy_auto_dir_smooth, num_freq_bands * nchan_out_woLFE ); set_zero( h_dirac_output_synthesis_state->cy_cross_dir_smooth, num_freq_bands * nchan_out_woLFE ); set_zero( h_dirac_output_synthesis_state->cy_auto_diff_smooth, num_freq_bands * nchan_out_woLFE ); #ifdef JBM_TSM_ON_TCS } #endif pop_wmops(); return; Loading
lib_dec/ivas_masa_dec.c +14 −5 Original line number Diff line number Diff line Loading @@ -378,7 +378,7 @@ ivas_error ivas_masa_dec_open( int16_t nchan_to_allocate; TC_BUFFER_MODE buffer_mode; buffer_mode = TC_BUFFER_MODE_RENDERER; if ( st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_STEREO || st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_MONO ) if ( st_ivas->mc_mode == MC_MODE_MCMASA && (st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_STEREO || st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_MONO) ) { buffer_mode = TC_BUFFER_MODE_BUFFER; } Loading Loading @@ -1162,13 +1162,22 @@ ivas_error ivas_masa_dec_reconfigure( ivas_masa_set_elements( ivas_total_brate, st_ivas->mc_mode, st_ivas->nchan_transport, st_ivas->hQMetaData, &tmp, &tmp, &tmp ); if ( st_ivas->hDecoderConfig->voip_active == 1 && st_ivas->renderer_type != RENDERER_BINAURAL_PARAMETRIC && st_ivas->renderer_type != RENDERER_BINAURAL_PARAMETRIC_ROOM && st_ivas->renderer_type != RENDERER_STEREO_PARAMETRIC ) if ( st_ivas->hDecoderConfig->voip_active == 1 && st_ivas->renderer_type != RENDERER_DISABLE ) { int16_t nchan_to_allocate = ivas_jbm_dec_get_num_tc_channels( st_ivas ); if ( nchan_to_allocate != st_ivas->hTcBuffer->nchan_transport_jbm ) int16_t tc_nchan_to_allocate; int16_t tc_nchan_transport; tc_nchan_transport = ivas_jbm_dec_get_num_tc_channels( st_ivas ); tc_nchan_to_allocate = tc_nchan_transport; if ( st_ivas->renderer_type == RENDERER_BINAURAL_PARAMETRIC || st_ivas->renderer_type == RENDERER_BINAURAL_PARAMETRIC_ROOM || st_ivas->renderer_type == RENDERER_STEREO_PARAMETRIC ) { tc_nchan_to_allocate = 2 * BINAURAL_CHANNELS; } if ( tc_nchan_transport != st_ivas->hTcBuffer->nchan_transport_jbm || tc_nchan_to_allocate != st_ivas->hTcBuffer->nchan_transport_internal ) { if ( ( error = ivas_jbm_dec_tc_buffer_reconfigure( st_ivas, TC_BUFFER_MODE_RENDERER, nchan_to_allocate, nchan_to_allocate, nchan_to_allocate, NS2SA( st_ivas->hDecoderConfig->output_Fs, CLDFB_SLOT_NS ) ) ) != IVAS_ERR_OK ) if ( ( error = ivas_jbm_dec_tc_buffer_reconfigure( st_ivas, TC_BUFFER_MODE_RENDERER, tc_nchan_transport, tc_nchan_to_allocate, tc_nchan_to_allocate, NS2SA( st_ivas->hDecoderConfig->output_Fs, CLDFB_SLOT_NS ) ) ) != IVAS_ERR_OK ) { return error; } } } Loading
lib_dec/ivas_mc_param_dec.c +8 −1 Original line number Diff line number Diff line Loading @@ -440,6 +440,9 @@ ivas_error ivas_param_mc_dec_open( return error; } #ifdef JBM_TSM_ON_TCS ivas_param_mc_dec_compute_interpolator( 0, 0, DEFAULT_JBM_CLDFB_TIMESLOTS, hParamMC->h_output_synthesis_params.interpolator ); #endif /* Head rotation */ if ( ( st_ivas->renderer_type == RENDERER_BINAURAL_FASTCONV || st_ivas->renderer_type == RENDERER_BINAURAL_FASTCONV_ROOM ) && st_ivas->hDecoderConfig->Opt_Headrotation ) Loading Loading @@ -960,6 +963,10 @@ ivas_error ivas_param_mc_dec_reconfig( return error; } #ifdef JBM_TSM_ON_TCS ivas_param_mc_dec_compute_interpolator( 0, 0, DEFAULT_JBM_CLDFB_TIMESLOTS, hParamMC->h_output_synthesis_params.interpolator ); #endif ivas_dirac_dec_output_synthesis_cov_init( &( hParamMC->h_output_synthesis_cov_state ), nchan_transport, nchan_out_cov, hParamMC->hMetadataPMC->num_parameter_bands, max_param_band_residual ); Loading Loading @@ -1465,7 +1472,7 @@ void ivas_param_mc_dec_digest_tc( ivas_jbm_dec_get_adapted_subframes( nCldfbSlots, hParamMC->subframe_nbslots, &hParamMC->nb_subframes ); /* BE Workaround */ if ( !st_ivas->bfi && st_ivas->hDecoderConfig->voip_active == 0 ) if ( !st_ivas->bfi && st_ivas->hDecoderConfig->voip_active == 1 ) { ivas_param_mc_dec_compute_interpolator( hParamMC->hMetadataPMC->bAttackPresent, hParamMC->hMetadataPMC->attackIndex, nCldfbSlots, hParamMC->h_output_synthesis_params.interpolator ); } Loading
lib_dec/ivas_mct_dec.c +2 −1 Original line number Diff line number Diff line Loading @@ -1243,7 +1243,8 @@ static ivas_error ivas_mc_dec_reconfig( } /* reconfigure buffer */ if ( hTcBuffer->tc_buffer_mode != tc_buffer_mode_new || hTcBuffer->nchan_transport_jbm != tc_nchan_tc_new || hTcBuffer->nchan_buffer_full != tc_nchan_full_new || hTcBuffer->nchan_transport_internal != tc_nchan_allocate_new ) hTcBuffer->nchan_buffer_full != tc_nchan_full_new || hTcBuffer->nchan_transport_internal != tc_nchan_allocate_new || tc_granularity_new != hTcBuffer->n_samples_granularity ) { if ( ( error = ivas_jbm_dec_tc_buffer_reconfigure( st_ivas, tc_buffer_mode_new, tc_nchan_tc_new, tc_nchan_allocate_new, tc_nchan_full_new, tc_granularity_new ) ) != IVAS_ERR_OK ) { Loading
lib_dec/ivas_sba_dec.c +5 −1 Original line number Diff line number Diff line Loading @@ -376,7 +376,7 @@ ivas_error ivas_sba_dec_reconfigure( /*-----------------------------------------------------------------* * TC buffer *-----------------------------------------------------------------*/ if ( st_ivas->hDecoderConfig->voip_active == 1 && st_ivas->renderer_type != RENDERER_BINAURAL_PARAMETRIC && st_ivas->renderer_type != RENDERER_BINAURAL_PARAMETRIC_ROOM && st_ivas->renderer_type != RENDERER_STEREO_PARAMETRIC ) if ( st_ivas->hDecoderConfig->voip_active == 1 ) { int16_t tc_nchan_to_allocate; int16_t tc_nchan_tc; Loading @@ -392,6 +392,10 @@ ivas_error ivas_sba_dec_reconfigure( tc_nchan_tc = st_ivas->hDecoderConfig->nchan_out; tc_nchan_to_allocate = tc_nchan_tc; } else if ( st_ivas->renderer_type == RENDERER_BINAURAL_PARAMETRIC || st_ivas->renderer_type == RENDERER_BINAURAL_PARAMETRIC_ROOM || st_ivas->renderer_type == RENDERER_STEREO_PARAMETRIC ) { tc_nchan_to_allocate = 2 * BINAURAL_CHANNELS; } else if ( st_ivas->sba_mode == SBA_MODE_SPAR ) { sba_order_internal = min( st_ivas->sba_analysis_order, IVAS_MAX_SBA_ORDER ); Loading