Commit 63651f47 authored by fotopoulou's avatar fotopoulou
Browse files

port fix for issue 1283 in BASOP

parent 187213dc
Loading
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -119,6 +119,7 @@
#define FIX_1500_ISM_MD_DTX                             /* VA: float issue 1500: fix ISM elevation metadata smoothing in DTX */
#define FIX_2348_REPLACE_FEC_ENC                        /* VA: basop issue 2348: replace FEC_encode_ivas_fx with FEC_encode_fx  */
#define FIX_2338_HARM_GSC_GAIN_COMP                     /* VA: basop issue 2338: harmonization of band gain computation for both EVS and IVAS */
#define FIX_1283_STEREO_DFT_COLLAPSE                    /* FhG: float issue 1283: fix for critical issue with DFT stereo core coder */

/* ##################### End NON-BE switches ########################### */

+12 −0
Original line number Diff line number Diff line
@@ -621,7 +621,13 @@ void ShapeSpectrum_ivas_fx(
    }

    test();
    test();
    test();
#ifndef FIX_1283_STEREO_DFT_COLLAPSE
    IF( LE_32( total_brate, ACELP_13k20 ) && EQ_16( st->bwidth, SWB ) )
#else
    IF( ( LE_32( total_brate, ACELP_13k20 ) || ( LE_32( st->element_brate, IVAS_16k4 ) && EQ_16( st->element_mode, IVAS_CPE_DFT ) ) ) && EQ_16( st->bwidth, SWB ) )
#endif
    {
        max_low_pre = 0;
        move32();
@@ -697,7 +703,13 @@ void ShapeSpectrum_ivas_fx(

    /* reduce the peaks in the IGF region, to make life of the core-coder easier... */
    test();
    test();
    test();
#ifndef FIX_1283_STEREO_DFT_COLLAPSE
    IF( LE_32( total_brate, ACELP_13k20 ) && EQ_16( st->bwidth, SWB ) )
#else
    IF( ( LE_32( total_brate, ACELP_13k20 ) || ( LE_32( st->element_brate, IVAS_16k4 ) && EQ_16( st->element_mode, IVAS_CPE_DFT ) ) ) && EQ_16( st->bwidth, SWB ) )
#endif
    {
        Word16 sf_width;
        Word16 dist_low, dist_high;
+4 −0
Original line number Diff line number Diff line
@@ -1475,6 +1475,10 @@ ivas_error IVAS_ENC_EncodeFrameToSerial(
    {
        hCoreCoder->total_brate = hEncoderConfig->ivas_total_brate; /* needed in case of bitrate switching */
        move32();
#ifdef FIX_1283_STEREO_DFT_COLLAPSE
        hCoreCoder->element_brate = hEncoderConfig->ivas_total_brate; /* needed in checks in core-coder functions other than mono*/
        move32();
#endif

        IF( EQ_16( hEncoderConfig->stereo_dmx_evs, 1 ) )
        {