Commit 96113d71 authored by JÜRGEN Gerstacker's avatar JÜRGEN Gerstacker
Browse files

FIX 2387, MR 2800, harmonize AnalyzePowerSpectrum_fx() and AnalyzePowerSpectrum_ivas_fx()

parent 7dcf3817
Loading
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -86,6 +86,7 @@
#define FIX_1904_HARM_GSC_ENC                           /* VA: #1904 Harmonization of EVS and IVAS GSC code */
#define FIX_2397_COPY_AQ_MDCT_CORE_BFI                  /* FhG: prevent copying of uninit memory in MDCT stereo core if bfi is set */
#define HARMONIZE_TBE                                   /* VA: harmonize core-coder TBE function duplications */
#define FIX_2387_ANALYZEPOWERSPECTRUM                   /* FhG: harmonize AnalyzePowerSpectrum_fx() and AnalyzePowerSpectrum_ivas_fx() */

/* #################### End BE switches ################################## */

+2 −1
Original line number Diff line number Diff line
@@ -3834,7 +3834,7 @@ void coder_tcx_fx(
        move16();
    }

    AnalyzePowerSpectrum_fx( st,
    AnalyzePowerSpectrum_ivas_fx( st,
                             round_fx( L_shl( Mpy_32_16_1( L_mult0( L_frame, st->L_frame ) /*Q0*/,
                                                           getInvFrameLen( hTcxEnc->L_frameTCX ) /*Q21*/ ) /*Q6*/,
                                              16 - 6 ) ),
@@ -3842,6 +3842,7 @@ void coder_tcx_fx(
                             left_overlap, right_overlap,
                             spectrum, *spectrum_e,
                             pWinMDST,
                             0,
                             powerSpec, &powerSpec_e );
    IF( hTcxCfg->fIsTNSAllowed != 0 )
    {
+2 −2
Original line number Diff line number Diff line
@@ -395,9 +395,9 @@ void core_signal_analysis_high_bitrate_fx(
                    }

                    /* Compute noise-measure flags for spectrum filling and quantization */
                    AnalyzePowerSpectrum_fx( st, div_l( L_mult( L_subframe, st->L_frame ), hTcxEnc->L_frameTCX ),
                    AnalyzePowerSpectrum_ivas_fx( st, div_l( L_mult( L_subframe, st->L_frame ), hTcxEnc->L_frameTCX ),
                                             L_subframe, left_overlap, right_overlap, spectrum[frameno], spectrum_e[frameno],
                                             pMdstWin, powerSpec, &powerSpec_e );
                                             pMdstWin,   0,   powerSpec, &powerSpec_e );
                }
            }
        }
+2 −0
Original line number Diff line number Diff line
@@ -316,6 +316,7 @@ static void detectLowpassFac( const Word32 *powerSpec, Word16 powerSpec_e, Word1
    move16();
}

#ifndef FIX_2387_ANALYZEPOWERSPECTRUM
/*-----------------------------------------------------------*
 * Compute noise-measure flags for spectrum filling          *
 * and quantization (0: tonal, 1: noise-like).               *
@@ -426,6 +427,7 @@ void AnalyzePowerSpectrum_fx(
        move16();
    }
}
#endif /* FIX_2387_ANALYZEPOWERSPECTRUM */

void AnalyzePowerSpectrum_ivas_fx(
    Encoder_State *st,           /* i/o: encoder states                                  */