Commit c106e9d7 authored by Tapani Pihlajakuja's avatar Tapani Pihlajakuja
Browse files

Merge remote-tracking branch 'origin/main' into...

Merge remote-tracking branch 'origin/main' into 2053-basop-PortMr2078-from-float-unnecessary-allocation-of-memories-for-channels-in-the-jbm-decoder
parents 5850090b 417b23a6
Loading
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -80,6 +80,8 @@
#define FIX_2084_FLOATING_POINT_LEFTOVERS                    /* FhG: convert floating-point leftovers in IVAS_ENC_FeedObjectMetadata() */
#define FIX_2141_ASSERT_IN_OMASA_BITRATE_SWITSCHING          /* FhG: Replace L_shl with L_shl_sat to prevent overflow when calculating scale factors for very small numbers in the logarithmic domain */
#define FIX_APA_EXECS_SCALING                                /* VA: fix scaling of JBM APA buffer */
#define FIX_2164_ASSERT_IN_OMASA_PREPROC_FOR_EDIT            /* Nokia: Issue 2164: Prevent overflow when calculating equalization coefficient for editing before clamping to safe range */
#define FIX_BASOP_ASSERT_IN_TONAL_MDCT_PLC                   /* FhG: fix for issue 2165 - using saturating addition in tonal MDCT PLC function */

/* ################### End FIXES switches ########################### */

+4 −0
Original line number Diff line number Diff line
@@ -454,7 +454,11 @@ static void getEnvelope(

    FOR( i = 0; i < n2; i++ )
    {
#ifdef FIX_BASOP_ASSERT_IN_TONAL_MDCT_PLC
        sum = L_add_sat( sum, powerSpec[i] ); /*powerSpec_exp*/
#else
        sum = L_add( sum, powerSpec[i] ); /*powerSpec_exp*/
#endif
    }
    /* No need for PTR_INIT for powerSpec[i+n2] as we continue from the previous loop */
    FOR( i = 0; i < n1; i++ )
+5 −1
Original line number Diff line number Diff line
@@ -6382,7 +6382,11 @@ void ivas_omasa_preProcessStereoTransportsForEditedObjects_fx(
                temp = BASOP_Util_Divide3232_Scale_newton( hMasaIsmData->preprocEneTarget_fx[band_idx], L_max( 1, hMasaIsmData->preprocEneRealized_fx[band_idx] ), &temp_q );
                temp_q = sub( Q31, sub( sub( Q31, temp_q ), sub( hMasaIsmData->preprocEneTarget_e[band_idx], hMasaIsmData->preprocEneRealized_e[band_idx] ) ) );
                temp = Sqrt32( temp, &temp_q ); // Q: 31-temp_q
#ifdef FIX_2164_ASSERT_IN_OMASA_PREPROC_FOR_EDIT
                temp = L_shl_sat( temp, sub( temp_q, 3 ) ); // Q28
#else
                temp = L_shl( temp, sub( temp_q, 3 ) ); // Q28
#endif
                temp_q = Q28;
                move16();
            }