Commit ff67fea7 authored by Archit Tamarapu's avatar Archit Tamarapu
Browse files

[cleanup] accept NONBE_FIX_986_MC_BW_SWITCHING

parent 402227e7
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -211,7 +211,6 @@
#define NONBE_FIX_975_JBM_USAN                          /* FhG: Fix issue #975, USAN in JBM decoding ad 13.2kbps */
#define FIX_944_REMOVE_LS_RENDERER_CALL_IN_STEREO       /* VA: issue 994: remove an obsolete call of function ivas_ls_setup_conversion() in stereo */

#define NONBE_FIX_986_MC_BW_SWITCHING                   /* FhG: fix crash in bw and br switching with MC */
#define NONBE_FIX_999_JBM_MCT_FLUSH                     /* FhG: issue #999: fix wrong flushing for MCT at a JBM rate switch */
#define NONBE_FIX_1000_G1_G2_SWB_TBE                    /* VA: issue 1000: avoid div by zero due to g1 + g2 being zero in SWB TBE */

+0 −16
Original line number Diff line number Diff line
@@ -713,7 +713,6 @@ int16_t set_bw_mct(
    }

    bw_changed = 0;
#ifdef NONBE_FIX_986_MC_BW_SWITCHING
    if ( mct_bwidth != last_mct_bwidth )
    {
        bw_changed = 1;
@@ -732,21 +731,6 @@ int16_t set_bw_mct(
            st->bwidth = mct_bwidth;
        }
    }
#else
    if ( mct_bwidth != last_mct_bwidth )
    {
        bw_changed = 1;

        for ( cpe_id = 0; cpe_id < nCPE; cpe_id++ )
        {
            for ( ch = 0; ch < CPE_CHANNELS; ch++ )
            {
                st = hCPE[cpe_id]->hCoreCoder[ch];
                st->bwidth = mct_bwidth;
            }
        }
    }
#endif

    return bw_changed;
}
+0 −4
Original line number Diff line number Diff line
@@ -579,14 +579,10 @@ ivas_error ivas_cpe_enc(
        {
            int16_t igf;

#ifdef NONBE_FIX_986_MC_BW_SWITCHING
            int16_t bw;

            bw = ( hCPE->element_mode == IVAS_CPE_MDCT ) ? sts[n]->bwidth : sts[n]->max_bwidth;
            igf = getIgfPresent( sts[n]->element_mode, sts[n]->bits_frame_nominal * FRAMES_PER_SEC, bw, sts[n]->rf_mode );
#else
            igf = getIgfPresent( sts[n]->element_mode, sts[n]->bits_frame_nominal * FRAMES_PER_SEC, sts[n]->max_bwidth, sts[n]->rf_mode );
#endif
            if ( ( error = IGF_Reconfig( &sts[n]->hIGFEnc, igf, 0, sts[n]->bits_frame_nominal * FRAMES_PER_SEC, sts[n]->max_bwidth, sts[n]->element_mode, sts[n]->rf_mode ) ) != IVAS_ERR_OK )
            {
                return error;
+0 −10
Original line number Diff line number Diff line
@@ -172,9 +172,6 @@ ivas_error ivas_mct_enc(
    float orig_spectrum_long[MCT_MAX_BLOCKS][CPE_CHANNELS][L_FRAME48k];
    int16_t switch_bw;
    IVAS_FORMAT ivas_format;
#ifndef NONBE_FIX_986_MC_BW_SWITCHING
    int16_t max_bwidth;
#endif
    int32_t ivas_total_brate;
    ivas_error error;
    float *pdata[MAX_INPUT_CHANNELS];
@@ -188,9 +185,6 @@ ivas_error ivas_mct_enc(
    hMCT->hBstr = st_ivas->hCPE[0]->hCoreCoder[0]->hBstr; /* pointer to write MCT side bits */

    ivas_format = st_ivas->hEncoderConfig->ivas_format;
#ifndef NONBE_FIX_986_MC_BW_SWITCHING
    max_bwidth = st_ivas->hEncoderConfig->max_bwidth;
#endif
    ivas_total_brate = st_ivas->hEncoderConfig->ivas_total_brate;

#ifdef DEBUG_FORCE_MCT_CP
@@ -234,11 +228,7 @@ ivas_error ivas_mct_enc(

        for ( n = 0; n < (int16_t) ( hMCT->nchan_out_woLFE * 0.5 ); n++ )
        {
#ifdef NONBE_FIX_986_MC_BW_SWITCHING
            initMdctStereoEncData( hMCT->hBlockData[n]->hStereoMdct, ivas_format, IVAS_CPE_MDCT, cp_bitrate, st_ivas->hCPE[0]->hCoreCoder[0]->bwidth, st_ivas->hCPE[0]->hCoreCoder[0]->igf, st_ivas->hCPE[0]->hCoreCoder[0]->igf ? st_ivas->hCPE[0]->hCoreCoder[0]->hIGFEnc->igfData.igfInfo.grid : NULL, 0 );
#else
            initMdctStereoEncData( hMCT->hBlockData[n]->hStereoMdct, ivas_format, IVAS_CPE_MDCT, cp_bitrate, max_bwidth, st_ivas->hCPE[0]->hCoreCoder[0]->igf, st_ivas->hCPE[0]->hCoreCoder[0]->igf ? st_ivas->hCPE[0]->hCoreCoder[0]->hIGFEnc->igfData.igfInfo.grid : NULL, 0 );
#endif
        }
    }