Commit 1840b79a authored by fotopoulou's avatar fotopoulou
Browse files

reintroduce code deleted by porting MR!1504 (BASOP issue 1564). Fixes #2008 as...

reintroduce code deleted by porting MR!1504 (BASOP issue 1564). Fixes #2008 as float and BASOP are now in sync
parent a6dfe7ea
Loading
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -169,7 +169,7 @@
#define NONBE_FIX_1220_OMASA_JBM_EXT_USAN               /* Nokia: fix issue 1220 OMASA EXT JBM USAN, also fix similar cases of free to avoid future problems */
#define NONBE_FIX_1376_MDCT_CONCEALMENT                 /* FhG: fix concealment artifact in MDCT Stereo with DTX, in case transition frame gets lost */
#define NONBE_1377_REND_DIRATT_CONF                     /* Eri: Issue 1377: Error in directivity attenuation configuration for both IVAS_dec and IVAS_rend */

#define FIX_ISSUE_2008_MISSING_CODE_FROM_PORTING        /* FhG: Issue 2008: Code deleted while porting float-main MR !1504 (BASOP issue 1565)*/
/* #################### End BASOP porting switches ############################ */

/* clang-format on */
+6 −0
Original line number Diff line number Diff line
@@ -729,6 +729,12 @@ void stereo_dft_enc_compute_itd(
        grand_dot_prod_img += xcorr[2 * i + 1];
        xcorr_abs[i] = sqrtf( xcorr[2 * i] * xcorr[2 * i] + xcorr[2 * i + 1] * xcorr[2 * i + 1] );

#ifdef FIX_ISSUE_2008_MISSING_CODE_FROM_PORTING
        /* VM: prod_LL tends to overflow, better to replace with sum(log(prod_L)) and retrain the classifier */
        prod_LL = prod_L;
        prod_RR = prod_R;
#endif

        if ( j == SFM_PROD_GRP || i == NFFT_mid - 1 )
        {
            prod_L = max( FLT_MIN, prod_L );