Commit 8bd18a61 authored by Archit Tamarapu's avatar Archit Tamarapu
Browse files

port FIX_1038_OFFSET_TO_NULL_PTR_IN_EVS_TCX_BFI

parent d8da034f
Loading
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -135,6 +135,7 @@
#define FIX_1003_PARAMISM_BINAURAL_RECONFIG_USAN        /* FhG: fix for #1003: fix USAN caused by ParamISM reconfig                    */
#define FIX_1001_ARI_HM_OVERFLOW                        /* FhG: (no changes needed in BASOP) fix for undef behaviour in in the harmonic TCX model arithmetic coder */
#define NONBE_FIX_1005_MC_RS_TCBUFFER_UPDATE                  /* FhG: issue #1005: fix TC Buffer update at a MC rate switch */
#define FIX_1038_OFFSET_TO_NULL_PTR_IN_EVS_TCX_BFI      /* FhG: move setting of pointers for parameter decoding so they are skipped in lost frames when they are not needed */

/* #################### End BASOP porting switches ############################ */

+8 −0
Original line number Diff line number Diff line
@@ -721,12 +721,20 @@ void decoder_LPD_fx(
        FOR( k = 0; k < 2; k++ )
        {

#ifndef FIX_1038_OFFSET_TO_NULL_PTR_IN_EVS_TCX_BFI
            /* Set pointer to parameters */
            prm = param + ( k * DEC_NPRM_DIV );

            /* Stability Factor */
#endif
            IF( bfi == 0 )
            {
#ifdef FIX_1038_OFFSET_TO_NULL_PTR_IN_EVS_TCX_BFI
                /* Set pointer to parameters */
                prm = param + ( k * DEC_NPRM_DIV );

                /* Stability Factor */
#endif
                st->stab_fac_fx = lsf_stab_fx( &lsf[( ( k + 1 ) ) * M], &lsf[k * M], 0, L_FRAME );
                move16();
            }
+21 −0
Original line number Diff line number Diff line
@@ -3693,7 +3693,15 @@ void decoder_tcx_invQ_fx(

    tnsSize = 0;
    move16();
#ifndef FIX_1038_OFFSET_TO_NULL_PTR_IN_EVS_TCX_BFI
    prm_target = NULL; /* just to suppress MSVC warnigs */
#else
    /* just to suppress MSVC warnigs */
    prm_target = NULL;
    prm_ltp = NULL;
    prm_tns = NULL;
    prm_sqQ = NULL;
#endif

    /*-----------------------------------------------------------------*
     * Initializations
@@ -3717,8 +3725,10 @@ void decoder_tcx_invQ_fx(
        move16();
    }

#ifndef FIX_1038_OFFSET_TO_NULL_PTR_IN_EVS_TCX_BFI
    prm_ltp = &prm[1 + NOISE_FILL_RANGES];
    prm_tns = prm_ltp + LTPSIZE;
#endif

    gainCompensate = ONE_IN_Q14;
    move16();
@@ -3734,6 +3744,10 @@ void decoder_tcx_invQ_fx(

    IF( !bfi )
    {
#ifdef FIX_1038_OFFSET_TO_NULL_PTR_IN_EVS_TCX_BFI
        prm_ltp = &prm[1 + NOISE_FILL_RANGES];
        prm_tns = prm_ltp + LTPSIZE;
#endif
        index = prm[0];
        move16();

@@ -3755,9 +3769,11 @@ void decoder_tcx_invQ_fx(
        move16();
    }

#ifndef FIX_1038_OFFSET_TO_NULL_PTR_IN_EVS_TCX_BFI
    prm_hm = prm_tns + tnsSize;
    prm_sqQ = prm_hm + NPRM_CTX_HM;
    *prm_sqQ1 = prm_sqQ;
#endif

    /*-----------------------------------------------------------*
     * Spectrum data                                             *
@@ -3765,6 +3781,11 @@ void decoder_tcx_invQ_fx(

    IF( !bfi )
    {
#ifdef FIX_1038_OFFSET_TO_NULL_PTR_IN_EVS_TCX_BFI
        prm_hm = prm_tns + tnsSize;
        prm_sqQ = prm_hm + NPRM_CTX_HM;
        *prm_sqQ1 = prm_sqQ;
#endif
        /*-----------------------------------------------------------*
         * Context HM                                                *
         *-----------------------------------------------------------*/