Commit 06e649d7 authored by multrus's avatar multrus
Browse files

[cleanup] accept FIX_2041_SPECTRAL_GAPS_FOR_INACTIVE_FRAMES

parent a616f1e5
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -103,7 +103,6 @@
/* #################### Start NON-BE switches ############################ */
/* any switch which is non-be wrt. TS 26.251 V3.0 */

#define FIX_2041_SPECTRAL_GAPS_FOR_INACTIVE_FRAMES      /* FhG: Using rounding in multiplication to improve precision in cngNoiseLevel[] */
#define FIX_2264_OUT_OF_BOUND_READING_IN_LOG2_NORM_LC   /* VA: Fix issue 2264 by adding a proper safeguard in log2 and by adding a missing normalization in swb_pre_proc_ivas_fx()*/
#define FIX_2250_LARGE_DIFFERENCES_BETWEEN_BASOP_AND_FLOAT  /* Dolby: Issue 2250:  random vector generation in GenShapedSHBExcitation() */
#define FIX_2254_IMPROV_PRECISION_OR_COMPLEXITY_NON_BE  /* VA: Precision improvement without increasing complexity, or complexity reduction that might be not BE on the LSB */
+0 −16
Original line number Diff line number Diff line
@@ -1095,11 +1095,7 @@ Word16 ApplyFdCng_fx(
                        s = s_max( s_min( s, sub( WORD32_BITS, 1 ) ), negate( sub( WORD32_BITS, 1 ) ) );
                        FOR( ; j <= hFdCngCom->part[k]; j++ )
                        {
#ifdef FIX_2041_SPECTRAL_GAPS_FOR_INACTIVE_FRAMES
                            cngNoiseLevel[j] = L_shl_r( Mpy_32_16_r( hFdCngDec->bandNoiseShape[j], facTab[k] ), s ); /*Q31 - hFdCngDec->bandNoiseShape_exp*/
#else
                            cngNoiseLevel[j] = L_shl( Mpy_32_16_1( hFdCngDec->bandNoiseShape[j], facTab[k] ), s );                                            /*Q31 - hFdCngDec->bandNoiseShape_exp*/
#endif
                            move32();
                        }
                    }
@@ -1710,11 +1706,7 @@ void perform_noise_estimation_dec_ivas_fx(
                    FOR( p = 0; p < npart; p++ )
                    {
                        temp = L_shl( msPeriodog[p], q_shift );
#ifdef FIX_2041_SPECTRAL_GAPS_FOR_INACTIVE_FRAMES
                        msNoiseEst[p] = Madd_32_16( Mpy_32_16_r( msNoiseEst[p], sub( MAX_16, alpha ) ), temp, alpha ); /*Q31 - hFdCngDec->msNoiseEst_exp*/
#else
                        msNoiseEst[p] = Madd_32_16( Mpy_32_16_1( msNoiseEst[p], sub( MAX_16, alpha ) ), temp, alpha );                                        /*Q31 - hFdCngDec->msNoiseEst_exp*/
#endif
                        move32();
                    }
                }
@@ -1792,11 +1784,7 @@ void perform_noise_estimation_dec_ivas_fx(
                        L_tmp = L_shr( msPeriodog[p], sub( sub( 31, hFdCngDec->hFdCngCom->periodog_exp ), 4 ) );
                        IF( LT_32( L_tmp, msNoiseEst[p] ) )
                        {
#ifdef FIX_2041_SPECTRAL_GAPS_FOR_INACTIVE_FRAMES
                            msNoiseEst[p] = Madd_32_16( Mpy_32_16_r( msNoiseEst[p], wght ), L_tmp, (Word16) L_sub( shr( MAX_16, sub( 15, scale ) ), wght ) ); /*temp_q_msNoiseEst[p]*/
#else
                            msNoiseEst[p] = Madd_32_16( Mpy_32_16_1( msNoiseEst[p], wght ), L_tmp, (Word16) L_sub( shr( MAX_16, sub( 15, scale ) ), wght ) ); /*temp_q_msNoiseEst[p]*/
#endif
                            move32();
                            temp_q_msNoiseEst[p] = sub( add( hFdCngDec->msNoiseEst_exp, scale ), 15 );
                            move16();
@@ -1819,11 +1807,7 @@ void perform_noise_estimation_dec_ivas_fx(
                        L_tmp = L_shr_sat( hFdCngDec->msPeriodog_ST_fx[p], sub( hFdCngDec->msNoiseEst_exp, hFdCngDec->msPeriodog_ST_exp ) ); /*Q31 - hFdCngDec->msPeriodog_ST_exp*/
                        IF( LT_32( L_tmp, msNoiseEst[p] ) )
                        {
#ifdef FIX_2041_SPECTRAL_GAPS_FOR_INACTIVE_FRAMES
                            msNoiseEst[p] = Madd_32_16( Mpy_32_16_r( msNoiseEst[p], CNA_ACT_DN_FACT_Q15 ), L_tmp, ONE_IN_Q15 - CNA_ACT_DN_FACT_Q15 ); /*Q31 - hFdCngDec->msNoiseEst_exp*/
#else
                            msNoiseEst[p] = Madd_32_16( Mpy_32_16_1( msNoiseEst[p], CNA_ACT_DN_FACT_Q15 ), L_tmp, ONE_IN_Q15 - CNA_ACT_DN_FACT_Q15 );         /*Q31 - hFdCngDec->msNoiseEst_exp*/
#endif
                            move32();
                        }
                    }