Commit 1d1b53a5 authored by Manuel Jander's avatar Manuel Jander
Browse files

Avoid rescale of Q_syn_Overl_TDACFB in TCX PLC, just copy it with current Q...

Avoid rescale of Q_syn_Overl_TDACFB in TCX PLC, just copy it with current Q value. Also add comment on Q value asignment so it is clear where it comes from after lerp().
parent 9545634a
Loading
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -1860,9 +1860,14 @@ void con_tcx_ivas_fx(
    move16();

    /* create aliasing and windowing need for transition to TCX10/5 */
#ifdef FIX_1348_BIT_PRECISION_IMPROVEMENT
    Copy( syn + L_frame, hTcxDec->syn_Overl_TDACFB, shr( L_frame, 1 ) );
    hTcxDec->Q_syn_Overl_TDACFB = Q_syn;
#else
    // bufferCopyFx( syn + L_frame, hTcxDec->syn_Overl_TDACFB, shr( L_frame, 1 ), Q_syn, 0, -1, 0 );
    Copy_Scale_sig( syn + L_frame, hTcxDec->syn_Overl_TDACFB, shr( L_frame, 1 ), sub( Q_syn, 1 ) );
    hTcxDec->Q_syn_Overl_TDACFB = sub( Q_syn, 1 );
#endif
    move16();

    FOR( i = 0; i < W12; i++ )
@@ -1922,7 +1927,7 @@ void con_tcx_ivas_fx(
    hTcxDec->Q_syn_Overl_TDAC = hTcxDec->Q_syn_Overl_TDACFB;
    move16();
    lerp( st->hHQ_core->old_out_fx, st->hHQ_core->old_out_LB_fx, st->L_frame, L_frame );
    st->hHQ_core->Q_old_wtda_LB = Q_syn;
    st->hHQ_core->Q_old_wtda_LB = Q_syn; // st->hHQ_core->Q_old_wtda
    st->old_enr_LP = Enr_1_Az_fx( A_local, L_SUBFR ); /*Q3*/
    move16();