Commit 860ae283 authored by norvell's avatar norvell
Browse files

Merge branch 'ivas-float-update' into ci/use-ci-from-main

parents aaf226e1 05925728
Loading
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -164,6 +164,9 @@
#define FIX_828_PORT_1152_FROM_FLT_REPO                  /* FhG: fix for issue 828 - fix uninitialized value used in BASOP */
#define NONE_BE_FIX_816_LFE_PLC_FLOAT                   /* DLB: issue 816: reduce required precision to float for LFE-PLC*/
#define FIX_835_PARAMMC_BUFFER_VALUES                   /* FhG: issue 835: wide range of buffer values for cx in ParamMC */
#define NONBE_FIX_943_PORT_1208_DFT_STEREO_PLC_BURST    /* Ericsson: BASOP Issue 943, Float Issue 1208, fix for overflow of sample offset counter for burst error in DFT Stereo PLC. */
#define FIX_903_ZERO_OUT_IMDCT_BUFFERS_FOR_MCT_IGNORE   /* FhG: zero out all relevant imdct buffers in MCT decoding of channels with mct_chan_mode == MCT_CHAN_MODE_IGNORE */
#define FIX_853_DECODE_MASA_ISM_AZIMUTH_PREC_FP        /* Nokia: Fixes ivas_decode_masaism_metadata decision logic change due to precision difference; this is the fix in floating point */
/* #################### End FIXES switches ############################ */

#define BASOP_NOGLOB                                    /* Disable global symbols in BASOPs, Overflow/Carry in BASOPs disabled, additional BASOPs in case of Overflow */
+16 −8
Original line number Diff line number Diff line
@@ -2347,13 +2347,21 @@ static int16_t ivas_decode_masaism_metadata(
                if ( azimuth * hMasaIsmData->q_azimuth_old[obj] > 0 )
                {
                    delta_phi = 180.0f / (float) ( no_phi_masa[bits_ism[obj] - 1][idx_el] ); /* 360/2*/
#ifdef FIX_853_DECODE_MASA_ISM_AZIMUTH_PREC_FP
                    if ( roundf( 100 * ( no_phi_masa[bits_ism[obj] - 1][idx_el] ) * ( azimuth - hMasaIsmData->q_azimuth_old[obj] ) ) / (float) 100.0f > 180.0f )
#else
                    if ( azimuth - hMasaIsmData->q_azimuth_old[obj] > delta_phi )
#endif
                    {
                        azimuth -= delta_phi;
                    }
                    else
                    {
#ifdef FIX_853_DECODE_MASA_ISM_AZIMUTH_PREC_FP
                        if ( roundf( 100 * ( no_phi_masa[bits_ism[obj] - 1][idx_el] ) * ( hMasaIsmData->q_azimuth_old[obj] - azimuth ) ) / 100.0f > 180.0f )
#else
                        if ( hMasaIsmData->q_azimuth_old[obj] - azimuth > delta_phi )
#endif
                        {
                            azimuth += delta_phi;
                        }
+179 −75
Original line number Diff line number Diff line
@@ -1505,23 +1505,14 @@ void ivas_param_mc_dec_digest_tc(
        set_zero( cx_imag, PARAM_MC_MAX_TRANSPORT_CHANS * PARAM_MC_MAX_TRANSPORT_CHANS );
        set_zero( cx_next_band, PARAM_MC_MAX_TRANSPORT_CHANS * PARAM_MC_MAX_TRANSPORT_CHANS );
        set_zero( cx_imag_next_band, PARAM_MC_MAX_TRANSPORT_CHANS * PARAM_MC_MAX_TRANSPORT_CHANS );
#else
    for ( param_band_idx = 0; param_band_idx < PARAM_MC_MAX_PARAMETER_BANDS; param_band_idx++ )
    {
        set_zero( cx[param_band_idx], PARAM_MC_MAX_TRANSPORT_CHANS * PARAM_MC_MAX_TRANSPORT_CHANS );
        set_zero( cx_imag[param_band_idx], PARAM_MC_MAX_TRANSPORT_CHANS * PARAM_MC_MAX_TRANSPORT_CHANS );
    }
#endif

        /* slot loop for gathering the input data */
        for ( slot_idx = 0; slot_idx < nCldfbSlots; slot_idx++ )
        {
            if ( st_ivas->hDecoderConfig->Opt_tsm )
            {
#ifdef FIX_835_PARAMMC_BUFFER_VALUES
                if ( param_band_idx == 0 ) /* only run cldfbAna once */
                {
#endif
                    float RealBuffer[CLDFB_NO_CHANNELS_MAX];
                    float ImagBuffer[CLDFB_NO_CHANNELS_MAX];

@@ -1533,81 +1524,53 @@ void ivas_param_mc_dec_digest_tc(
                        mvr2r( RealBuffer, &hParamMC->Cldfb_RealBuffer_tc[slot_idx * hParamMC->num_freq_bands * nchan_transport + ch * hParamMC->num_freq_bands], hParamMC->num_freq_bands );
                        mvr2r( ImagBuffer, &hParamMC->Cldfb_ImagBuffer_tc[slot_idx * hParamMC->num_freq_bands * nchan_transport + ch * hParamMC->num_freq_bands], hParamMC->num_freq_bands );
                    }
#ifdef FIX_835_PARAMMC_BUFFER_VALUES
                }
#endif
            }

            if ( slot_idx >= 2 * hParamMC->hMetadataPMC->attackIndex )
            {
#ifdef FIX_835_PARAMMC_BUFFER_VALUES
                for ( is_next_band = 0; is_next_band < 2; is_next_band++ )
                {
                    if ( is_next_band && skip_next_band )
                    {
                        continue;
                    }
#endif

                    ivas_dirac_dec_output_synthesis_cov_param_mc_collect_slot( &hParamMC->Cldfb_RealBuffer_tc[slot_idx * hParamMC->num_freq_bands * nchan_transport],
                                                                               &hParamMC->Cldfb_ImagBuffer_tc[slot_idx * hParamMC->num_freq_bands * nchan_transport],
#ifdef FIX_835_PARAMMC_BUFFER_VALUES
                                                                               is_next_band ? cx_next_band : cx,
                                                                               is_next_band ? cx_imag_next_band : cx_imag,
                                                                               param_band_idx + is_next_band,
#else
                                                                       cx,
                                                                       cx_imag,
#endif
                                                                               hParamMC,
                                                                               nchan_transport );
#ifdef FIX_835_PARAMMC_BUFFER_VALUES
                }
#endif
            }
        }

        /* map from complex input covariance to real values */
#ifdef FIX_835_PARAMMC_BUFFER_VALUES
        for ( is_next_band = 0; is_next_band < 2; is_next_band++ )
        {
            if ( is_next_band && skip_next_band )
            {
                continue;
            }
#else
    for ( param_band_idx = 0; param_band_idx < hParamMC->num_param_bands_synth; param_band_idx++ )
    {
#endif

            /* Cx for transport channels */
#ifdef FIX_835_PARAMMC_BUFFER_VALUES
            pCx = is_next_band ? &cx_next_band[0] : &cx[0];
            pCx_imag = is_next_band ? &cx_imag_next_band[0] : &cx_imag[0];
#endif
            for ( i = 0; i < nchan_transport * nchan_transport; i++ )
            {
#ifdef FIX_835_PARAMMC_BUFFER_VALUES
                real_part = pCx[i];
                imag_part = pCx_imag[i];
#else
            real_part = cx[param_band_idx][i];
            imag_part = cx_imag[param_band_idx][i];
#endif

                /* (a-ib)(c+id) = ac + bd + i(ad-bc) */
                if ( param_band_idx < hParamMC->max_param_band_abs_cov )
                {
#ifdef FIX_835_PARAMMC_BUFFER_VALUES
                    pCx[i] = sqrtf( real_part * real_part + imag_part * imag_part );
#else
                cx[param_band_idx][i] = sqrtf( real_part * real_part + imag_part * imag_part );
#endif
                }
                else
                {
#ifdef FIX_835_PARAMMC_BUFFER_VALUES
                    pCx[i] = real_part;
#else
                cx[param_band_idx][i] = real_part;
#endif
                }
            }
        }
@@ -1615,37 +1578,23 @@ void ivas_param_mc_dec_digest_tc(
        /* we have to do it similar to the encoder in case of attacks (i.e. accumulate two bands) to ensure correct DMX of the target covariance*/
        if ( hParamMC->hMetadataPMC->bAttackPresent && ( hParamMC->synthesis_conf == PARAM_MC_SYNTH_LS_CONV_COV || hParamMC->synthesis_conf == PARAM_MC_SYNTH_MONO_STEREO ) )
        {
#ifdef FIX_835_PARAMMC_BUFFER_VALUES
            v_add( cx, cx_next_band, cx, nchan_transport * nchan_transport );
            mvr2r( cx, cx_next_band, nchan_transport * nchan_transport );
#else
        for ( param_band_idx = 0; param_band_idx < hParamMC->num_param_bands_synth; param_band_idx += 2 )
        {
            v_add( cx[param_band_idx], cx[param_band_idx + 1], cx[param_band_idx], nchan_transport * nchan_transport );
            mvr2r( cx[param_band_idx], cx[param_band_idx + 1], nchan_transport * nchan_transport );
        }
#endif
        }


#ifdef FIX_835_PARAMMC_BUFFER_VALUES
        for ( is_next_band = 0; is_next_band < 2; is_next_band++ )
        {
            if ( is_next_band && skip_next_band )
            {
                continue;
            }
#endif

            if ( hParamMC->synthesis_conf == PARAM_MC_SYNTH_MONO_STEREO )
            {
                ivas_param_mc_get_mono_stereo_mixing_matrices( hParamMC,
#ifdef FIX_835_PARAMMC_BUFFER_VALUES
                                                               is_next_band ? cx_next_band : cx,
                                                               param_band_idx + is_next_band,
#else
                                                       cx,
#endif
                                                               hParamMC->h_output_synthesis_cov_state.mixing_matrix,
                                                               hParamMC->h_output_synthesis_cov_state.mixing_matrix_res,
                                                               nchan_out_transport,
@@ -1657,12 +1606,8 @@ void ivas_param_mc_dec_digest_tc(
                /* generate mixing matrices */
                ivas_param_mc_get_mixing_matrices( hParamMC,
                                                   hSynthesisOutputSetup,
#ifdef FIX_835_PARAMMC_BUFFER_VALUES
                                                   is_next_band ? cx_next_band : cx,
                                                   param_band_idx + is_next_band,
#else
                                           cx,
#endif
                                                   hParamMC->h_output_synthesis_cov_state.mixing_matrix,
                                                   hParamMC->h_output_synthesis_cov_state.mixing_matrix_res,
                                                   nchan_out_transport,
@@ -1670,9 +1615,99 @@ void ivas_param_mc_dec_digest_tc(
                                                   nchan_transport,
                                                   nchan_out_cov );
            }
#ifdef FIX_835_PARAMMC_BUFFER_VALUES
        }
    }

#else
    for ( param_band_idx = 0; param_band_idx < PARAM_MC_MAX_PARAMETER_BANDS; param_band_idx++ )
    {
        set_zero( cx[param_band_idx], PARAM_MC_MAX_TRANSPORT_CHANS * PARAM_MC_MAX_TRANSPORT_CHANS );
        set_zero( cx_imag[param_band_idx], PARAM_MC_MAX_TRANSPORT_CHANS * PARAM_MC_MAX_TRANSPORT_CHANS );
    }

    /* slot loop for gathering the input data */
    for ( slot_idx = 0; slot_idx < nCldfbSlots; slot_idx++ )
    {
        if ( st_ivas->hDecoderConfig->Opt_tsm )
        {
            float RealBuffer[CLDFB_NO_CHANNELS_MAX];
            float ImagBuffer[CLDFB_NO_CHANNELS_MAX];

            /* CLDFB Analysis*/
            for ( ch = 0; ch < nchan_transport; ch++ )
            {
                cldfbAnalysis_ts( &( transport_channels_f[ch][hParamMC->num_freq_bands * slot_idx] ), RealBuffer, ImagBuffer, hParamMC->num_freq_bands, st_ivas->cldfbAnaDec[ch] );

                mvr2r( RealBuffer, &hParamMC->Cldfb_RealBuffer_tc[slot_idx * hParamMC->num_freq_bands * nchan_transport + ch * hParamMC->num_freq_bands], hParamMC->num_freq_bands );
                mvr2r( ImagBuffer, &hParamMC->Cldfb_ImagBuffer_tc[slot_idx * hParamMC->num_freq_bands * nchan_transport + ch * hParamMC->num_freq_bands], hParamMC->num_freq_bands );
            }
        }

        if ( slot_idx >= 2 * hParamMC->hMetadataPMC->attackIndex )
        {
            ivas_dirac_dec_output_synthesis_cov_param_mc_collect_slot( &hParamMC->Cldfb_RealBuffer_tc[slot_idx * hParamMC->num_freq_bands * nchan_transport],
                                                                       &hParamMC->Cldfb_ImagBuffer_tc[slot_idx * hParamMC->num_freq_bands * nchan_transport],
                                                                       cx,
                                                                       cx_imag,
                                                                       hParamMC,
                                                                       nchan_transport );
        }
    }

    /* map from complex input covariance to real values */
    for ( param_band_idx = 0; param_band_idx < hParamMC->num_param_bands_synth; param_band_idx++ )
    {
        /* Cx for transport channels */
        for ( i = 0; i < nchan_transport * nchan_transport; i++ )
        {
            real_part = cx[param_band_idx][i];
            imag_part = cx_imag[param_band_idx][i];

            /* (a-ib)(c+id) = ac + bd + i(ad-bc) */
            if ( param_band_idx < hParamMC->max_param_band_abs_cov )
            {
                cx[param_band_idx][i] = sqrtf( real_part * real_part + imag_part * imag_part );
            }
            else
            {
                cx[param_band_idx][i] = real_part;
            }
        }
    }

    /* we have to do it similar to the encoder in case of attacks (i.e. accumulate two bands) to ensure correct DMX of the target covariance*/
    if ( hParamMC->hMetadataPMC->bAttackPresent && ( hParamMC->synthesis_conf == PARAM_MC_SYNTH_LS_CONV_COV || hParamMC->synthesis_conf == PARAM_MC_SYNTH_MONO_STEREO ) )
    {
        for ( param_band_idx = 0; param_band_idx < hParamMC->num_param_bands_synth; param_band_idx += 2 )
        {
            v_add( cx[param_band_idx], cx[param_band_idx + 1], cx[param_band_idx], nchan_transport * nchan_transport );
            mvr2r( cx[param_band_idx], cx[param_band_idx + 1], nchan_transport * nchan_transport );
        }
    }

    if ( hParamMC->synthesis_conf == PARAM_MC_SYNTH_MONO_STEREO )
    {
        ivas_param_mc_get_mono_stereo_mixing_matrices( hParamMC,
                                                       cx,
                                                       hParamMC->h_output_synthesis_cov_state.mixing_matrix,
                                                       hParamMC->h_output_synthesis_cov_state.mixing_matrix_res,
                                                       nchan_out_transport,
                                                       nchan_transport,
                                                       nchan_out_cov );
    }
    else
    {
        /* generate mixing matrices */
        ivas_param_mc_get_mixing_matrices( hParamMC,
                                           hSynthesisOutputSetup,
                                           cx,
                                           hParamMC->h_output_synthesis_cov_state.mixing_matrix,
                                           hParamMC->h_output_synthesis_cov_state.mixing_matrix_res,
                                           nchan_out_transport,
                                           hParamMC->synthesis_conf,
                                           nchan_transport,
                                           nchan_out_cov );
    }
#endif

    pop_wmops();
@@ -2648,7 +2683,7 @@ static void ivas_param_mc_get_mono_stereo_mixing_matrices(
    float *mixing_matrix_res[],                                               /* o  : residual mixing matrices for all parameter bands      */
    const int16_t nY_intern,                                                  /* i  : number of channels of the transport format            */
    const int16_t nX,                                                         /* i  : number of transport channels                          */
    const int16_t nY_cov )                                                    /* i  : number of output channels                             */
    const int16_t nY_cov                                                      /* i  : number of output channels                             */
#else
    PARAM_MC_DEC_HANDLE hParamMC,                                                                           /* i  : Parametric MC handle                                  */
    float Cx_in[PARAM_MC_MAX_PARAMETER_BANDS][PARAM_MC_MAX_TRANSPORT_CHANS * PARAM_MC_MAX_TRANSPORT_CHANS], /* i  : transport channel covariance for all parameter bands  */
@@ -2656,12 +2691,20 @@ static void ivas_param_mc_get_mono_stereo_mixing_matrices(
    float *mixing_matrix_res[],                                                                             /* o  : residual mixing matrices for all parameter bands */
    const int16_t nY_intern,                                                                                /* i  : number of channels of the transport format            */
    const int16_t nX,                                                                                       /* i  : number of transport channels                          */
    const int16_t nY_cov )                                                                                  /* i  : number of output channels                             */
    const int16_t nY_cov                                                                                    /* i  : number of output channels                             */
#endif
)
{
#ifndef FIX_835_PARAMMC_BUFFER_VALUES
    int16_t param_band_idx;
#endif
    float Cy_full[MAX_CICP_CHANNELS * MAX_CICP_CHANNELS];
    float mixing_matrix_woLFE[MAX_CICP_CHANNELS * PARAM_MC_MAX_TRANSPORT_CHANS];
    float Nrqq[MAX_OUTPUT_CHANNELS];
    float target_ch_ener[MAX_OUTPUT_CHANNELS];
    int16_t k, l;
    float *ild_q;

    float Cx[PARAM_MC_MAX_TRANSPORT_CHANS * PARAM_MC_MAX_TRANSPORT_CHANS];
    float Cy_diag[MAX_CICP_CHANNELS];
    float Cproto_diag[MAX_CICP_CHANNELS];
@@ -2685,21 +2728,10 @@ static void ivas_param_mc_get_mono_stereo_mixing_matrices(
#ifndef FIX_835_PARAMMC_BUFFER_VALUES
    for ( param_band_idx = 0; param_band_idx < hParamMC->num_param_bands_synth; param_band_idx++ )
    {
#endif
        float Cy_full[MAX_CICP_CHANNELS * MAX_CICP_CHANNELS];
        float mixing_matrix_woLFE[MAX_CICP_CHANNELS * PARAM_MC_MAX_TRANSPORT_CHANS];
        float Nrqq[MAX_OUTPUT_CHANNELS];
        float target_ch_ener[MAX_OUTPUT_CHANNELS];
        int16_t k, l;
        float *ild_q;

#ifdef FIX_835_PARAMMC_BUFFER_VALUES
        Cx_state = Cx_in;
#else
        Cx_state = Cx_in[param_band_idx];
#endif
        Cx_old_state = hParamMC->h_output_synthesis_cov_state.cx_old[param_band_idx];
        Cy_old_state = hParamMC->h_output_synthesis_cov_state.cy_old[param_band_idx];

        set_zero( Nrqq, MAX_OUTPUT_CHANNELS );
        set_zero( target_ch_ener, MAX_OUTPUT_CHANNELS );
        set_zero( Cy_full, MAX_CICP_CHANNELS * MAX_CICP_CHANNELS );
@@ -2767,7 +2799,79 @@ static void ivas_param_mc_get_mono_stereo_mixing_matrices(
        {
            set_zero( mixing_matrix_res[param_band_idx], nY_cov * nY_cov );
        }
#ifndef FIX_835_PARAMMC_BUFFER_VALUES
    }

#else

    Cx_state = Cx_in;
    Cx_old_state = hParamMC->h_output_synthesis_cov_state.cx_old[param_band_idx];
    Cy_old_state = hParamMC->h_output_synthesis_cov_state.cy_old[param_band_idx];
    set_zero( Nrqq, MAX_OUTPUT_CHANNELS );
    set_zero( target_ch_ener, MAX_OUTPUT_CHANNELS );
    set_zero( Cy_full, MAX_CICP_CHANNELS * MAX_CICP_CHANNELS );
    set_zero( Cy_state, MAX_CICP_CHANNELS * MAX_CICP_CHANNELS );
    set_zero( Cproto_diag, MAX_CICP_CHANNELS );
    ild_q = hParamMC->icld_q + param_band_idx * hParamMC->hMetadataPMC->ild_mapping_conf->ild_map_size_lfe;

    /*get back Nrg*/
    for ( k = 0; k < nY_intern; k++ )
    {
        float ref_ener = 0.0f;
        int16_t ref_channel_cnt;
        int16_t ref_channel_idx;

        for ( ref_channel_cnt = 0; ref_channel_cnt < hParamMC->hMetadataPMC->ild_mapping_conf->num_ref_channels[k]; ref_channel_cnt++ )
        {
            ref_channel_idx = hParamMC->hMetadataPMC->ild_mapping_conf->ref_channel_idx[k][ref_channel_cnt];
            ref_ener += Cx_state[ref_channel_idx + ref_channel_idx * nX];
        }
        Nrqq[hParamMC->hMetadataPMC->ild_mapping_conf->ild_index[k]] = powf( 10.0f, ild_q[k] / 10.0f ) * hParamMC->hMetadataPMC->ild_factors[k] * ref_ener;
    }
    for ( k = 0; k < nY_cov; k++ )
    {
        for ( l = 0; l < nY_intern; l++ )
        {
            target_ch_ener[k] += hParamMC->ls_conv_dmx_matrix[k + l * nY_cov] * Nrqq[l];
        }
        Cy_state[k + nY_cov * k] = target_ch_ener[k];
    }

    /* Smoothing: Sum over two buffers */
    if ( hParamMC->hMetadataPMC->bAttackPresent )
    {
        /* no smoothing on attacks */
        mvr2r( Cx_state, Cx, nX * nX );
        mvr2r( Cy_state, Cy_full, nY_cov * nY_cov );
    }
    else
    {
        /* smoothing gains are now identical to one, simply add up */
        v_add( Cx_state, Cx_old_state, Cx, nX * nX );
        v_add( Cy_state, Cy_old_state, Cy_full, nY_cov * nY_cov );
    }

    /* cov buffer update */
    mvr2r( Cx_state, Cx_old_state, nX * nX );
    mvr2r( Cy_state, Cy_old_state, nY_cov * nY_cov );


    matrix_product( proto_matrix, nY_band, nX, 0, Cx, nX, nX, 0, mat_mult_buffer1 );

    matrix_product_diag( mat_mult_buffer1, nY_band, nX, 0, proto_matrix, nY_band, nX, 1, Cproto_diag );

    /* Computing the mixing matrices */
    for ( i = 0; i < nY_band; i++ )
    {
        Cy_diag[i] = Cy_full[i + nY_band * i];
        Cy_diag[i] = sqrtf( Cy_diag[i] / ( Cproto_diag[i] + EPSILON ) );
    }

    diag_matrix_product( Cy_diag, nY_band, proto_matrix, nY_band, nX, 0, mixing_matrix_woLFE );

    mvr2r( mixing_matrix_woLFE, mixing_matrix[param_band_idx], nY_cov * nX );
    if ( hParamMC->band_grouping[param_band_idx] < hParamMC->h_output_synthesis_params.max_band_decorr )
    {
        set_zero( mixing_matrix_res[param_band_idx], nY_cov * nY_cov );
    }
#endif

+10 −0
Original line number Diff line number Diff line
@@ -865,6 +865,16 @@ void ivas_mdct_core_reconstruct(
                {
                    set_f( &synth[k * L_frame[ch]], 0.f, L_frame[ch] );
                    set_f( &synthFB[k * L_frame[ch]], 0.f, L_frameTCX[ch] );
#ifdef FIX_903_ZERO_OUT_IMDCT_BUFFERS_FOR_MCT_IGNORE
                    /* Note: these buffers are not subframe-based, hence no indexing with k */
                    set_f( &st->hHQ_core->old_outLB[0], 0.f, L_frame[ch] );
                    set_f( &st->hHQ_core->old_out[0], 0.f, L_frameTCX[ch] );
                    set_f( &st->hTcxDec->syn_Overl[0], 0.f, L_frame[ch] / 2 );
                    set_f( &st->hTcxDec->syn_OverlFB[0], 0.f, L_frameTCX[ch] / 2 );
                    set_f( &st->hTcxDec->syn_Overl_TDAC[0], 0.f, L_frame[ch] / 2 );
                    set_f( &st->hTcxDec->syn_Overl_TDACFB[0], 0.f, L_frameTCX[ch] / 2 );
#endif

                }
            }

+12 −0
Original line number Diff line number Diff line
@@ -80,6 +80,9 @@ void stereo_dft_res_ecu(
    float fac;
    float trigo_dec[STEREO_DFT32MS_N_8k / 2 + 1];
    int16_t trigo_step;
#ifdef NONBE_FIX_943_PORT_1208_DFT_STEREO_PLC_BURST
    int16_t time_offs;
#endif

    set_zero( pDFT_RES, L_FRAME8k );

@@ -106,7 +109,12 @@ void stereo_dft_res_ecu(
    if ( k == 0 )
    {
        mvr2r( pDFT_RES, res_buf, L_FRAME8k );
#ifdef NONBE_FIX_943_PORT_1208_DFT_STEREO_PLC_BURST
        time_offs = min( MAX16B, hStereoDft->time_offs + output_frame );
        stereo_dft_res_subst_spec( hStereoDft, res_buf, DFT_PRED_RES, time_offs, L_res, L_FRAME8k, k, num_plocs, plocs, plocsi, FALSE );
#else
        stereo_dft_res_subst_spec( hStereoDft, res_buf, DFT_PRED_RES, hStereoDft->time_offs + output_frame, L_res, L_FRAME8k, k, num_plocs, plocs, plocsi, FALSE );
#endif

        rfft( res_buf, trigo_dec, L_FRAME8k, +1 );

@@ -133,7 +141,11 @@ void stereo_dft_res_ecu(
        }

        /*in case of burst error*/
#ifdef NONBE_FIX_943_PORT_1208_DFT_STEREO_PLC_BURST
        hStereoDft->time_offs = min( MAX16B, hStereoDft->time_offs + L_FRAME8k );
#else
        hStereoDft->time_offs += L_FRAME8k;
#endif
    }

    set_zero( DFT_PRED_RES, 2 * L_res );
Loading