Loading lib_com/cng_exc_fx.c +4 −0 Original line number Diff line number Diff line Loading @@ -872,7 +872,11 @@ void cng_params_upd_fx( Word16 index = 0; move32(); move16(); #ifdef HARM_2456_APPLY_SCALE index = apply_scale_ind( &att_fx, bwidth, last_active_brate, scaleTableStereo, SIZE_SCALE_TABLE_STEREO ); #else apply_scale_ivas_fx( &att_fx, bwidth, last_active_brate, scaleTableStereo, SIZE_SCALE_TABLE_STEREO, &index ); #endif att_fx = pow_10_q23[index]; // Q23 move32(); tmp = extract_h( att_fx ); // Q7 Loading lib_com/fd_cng_com_fx.c +3 −0 Original line number Diff line number Diff line Loading @@ -1751,9 +1751,11 @@ Word16 apply_scale_ind( *scale = L_add( *scale, L_deposit_h( scaleTable[i].scale ) ); move32(); } return i; } #ifndef HARM_2456_APPLY_SCALE void apply_scale_ivas_fx( Word32 *scale, /* o : scalefactor */ const Word16 bwmode, /* i : audio bandwidth */ Loading @@ -1780,6 +1782,7 @@ void apply_scale_ivas_fx( *index = i; move16(); } #endif /*------------------------------------------------------------------- * bandcombinepow() * Loading lib_com/options.h +5 −0 Original line number Diff line number Diff line Loading @@ -98,6 +98,10 @@ #define FIX_2431_AVOID_CALLOC /* VA: basp issue 2431: avoid use of calloc() */ #define FIX_2424_REMOVE_GAUSS_L2_ENC /* VA: basop issue 2424: Remove duplicated code in gauss_L2_ivas_fx() */ #define FIX_MDCT_STEREO_ENC_STACK /* VA: basop issue 2428: Move IGF temporary buffers out of the highest stack */ #define HARMONIZE_TBE3 /* VA: basop issue 2399: Remove duplicated code: TBE, step 3 */ #define FIX_2459_USAN_AMR_SIDSTART /* FhG: basop issue 2459: fix msan complaint */ #define FIX_2458_USAN_NULLPTR_WITH_ZERO_OFFSET /* FhG: basop issue 2458: avoid indexing into null pointer */ #define HARM_2456_APPLY_SCALE /* FhG basop issue 2456: Harmonize apply_scale_ind(), apply_scale_ivas_fx() */ #define HARM_2454_TCX_RES_Q_SPEC /* FhG: harmonization of tcx_res_Q_spec_fx() and tcx_res_Q_spec_ivas_fx() */ /* #################### End BE switches ################################## */ Loading @@ -111,6 +115,7 @@ #define FIX_2283_ISM_MD_DELAY /* Dolby: Fix ISM metadata delay round-off */ #define FIX_2283_Q_CLDFB /* FhG: Fix Q format issue in CLDFB */ #define FIX_2283_ACCU_CLDFB /* FhG: Fix to consider Q-format differences in accumulateCLDFBArrayToBuffer_fx() */ #define FIX_1530_Codec_Level_Harmonization_Non_diegetic_panning /* FhG: Adjust non-diegetic panning law to harmonize codec levels with 3GPP reference software */ #define FIX_FLOAT_1518 /* FhG: fix issue 1518: loudness differences in OSBA decoding to mono or stereo output */ #define FIX_FLOAT_1533_BLEND_SUBFR2 /* FhG: float issue 1533: correct blending in blend_subfr2() */ Loading lib_com/prot_fx.h +50 −20 Original line number Diff line number Diff line Loading @@ -2669,11 +2669,19 @@ void flip_and_downmix_generic_fx( ); void Calc_rc0_h( #ifdef HARMONIZE_TBE3 const Word16 element_mode, /* i : element mode */ const Word16 enc_dec, /* i : encoder/decoder flag */ #endif Word16 *h, /* i : impulse response of composed filter */ Word16 *rc0 /* o : 1st parcor */ ); void PostShortTerm_fx( #ifdef HARMONIZE_TBE3 const Word16 element_mode, /* i : element mode */ const Word16 enc_dec, /* i : encoder/decoder flag */ #endif Word16 *sig_in, /* i : i signal (pointer to current subframe */ Word16 *lpccoeff, /* i : LPC coefficients for current subframe */ Word16 *sig_out, /* o : postfiltered output */ Loading @@ -2684,6 +2692,7 @@ void PostShortTerm_fx( const Word16 formant_fac_fx /* i : Strength of post-filter*/ ); #ifndef HARMONIZE_TBE3 void PostShortTerm_ivas_enc_fx( Word16 *sig_in, /* i : i signal (pointer to current subframe */ Word16 *lpccoeff, /* i : LPC coefficients for current subframe */ Loading @@ -2705,7 +2714,7 @@ void PostShortTerm_ivas_dec_fx( Word16 *mem_zero, /* i/o: null memory to compute h_st*/ const Word16 formant_fac_fx /* i : Strength of post-filter*/ ); #endif void flip_spectrum_and_decimby4_fx( const Word16 i[], /* i : i spectrum */ Word16 output[], /* o : output spectrum */ Loading Loading @@ -4875,6 +4884,7 @@ Word16 apply_scale_ind( const SCALE_SETUP *scaleTable, /* i : Scale table */ const Word16 scaleTableSize /* i : Size of scale table */ ); #ifndef HARM_2456_APPLY_SCALE void apply_scale_ivas_fx( Word32 *scale, /* o : scalefactor */ const Word16 bwmode, /* i : audio bandwidth */ Loading @@ -4882,6 +4892,7 @@ void apply_scale_ivas_fx( const SCALE_SETUP *scaleTable, /* i : Scale table */ const Word16 scaleTableSize, /* i : Size of scale table */ Word16 *index ); #endif /* Compute the power for each partition */ void bandcombinepow( Loading Loading @@ -5516,6 +5527,21 @@ void wb_tbe_dec_fx( Word16 *synth, /* i/o: ACELP core synthesis/final synthesis */ Word16 *Q_synth ); #ifdef HARMONIZE_TBE3 void swb_tbe_dec_fx( Decoder_State *st, /* i/o: decoder state structure */ STEREO_ICBWE_DEC_HANDLE hStereoICBWE, /* i/o: IC-BWE state structure */ const Word32 *bwe_exc_extended_fx, /* i : bandwidth extended excitation : Q_exc */ const Word16 voice_factors_fx[], /* i : voicing factors : Q15 */ const Word16 old_syn_12k8_16k_fx16[], /* i : low band synthesis : old_syn_fx */ Word16 *White_exc16k_fx, /* o : shaped white excitation for the FB TBE : Q_white_exc*/ Word16 *Q_white_exc, /* o : Q-factor of White_exc16k_fx */ Word16 *synth_fx16, /* o : SHB synthesis/final synthesis 16-bit : Qx */ Word32 *synth_fx, /* o : SHB synthesis/final synthesis 32-bit : Qx */ Word16 *Q_synth, /* o : Q-factor of synth_fx16[]/synth_fx[] */ Word16 *pitch_buf_fx /* i : Q6 */ ); #else void swb_tbe_dec_fx( Decoder_State *st_fx, /* i/o: decoder state structure */ const Word16 coder_type, /* i : coding type */ Loading @@ -5528,17 +5554,19 @@ void swb_tbe_dec_fx( Word16 *synth, /* o : SHB synthesis/final synthesis */ Word16 *Q_synth, Word16 *pitch_buf ); #endif void fb_tbe_dec_fx( Decoder_State *st, /* i/o: encoder state structure */ const Word16 fb_exc[], /* i : FB excitation from the SWB part */ Word16 Q_fb_exc, const Word16 fb_exc[], /* i : FB excitation from the SWB part Q_fb_exc */ const Word16 Q_fb_exc, /* i : Q-factor of fb_exc[] */ Word16 *hb_synth16, /* o : high-band synthesis Q(15 - hb_synth_exp) */ Word32 *hb_synth, /* o : high-band synthesis */ Word16 hb_synth_exp, Word16 *fb_synth_ref, Word16 Q_fb_synth_ref, Word16 output_frame ); Word32 *hb_synth, /* o : high-band synthesis Q(15 - hb_synth_exp) */ const Word16 hb_synth_exp, /* i : Q-factor of hb_synth[] */ Word16 *fb_synth_ref, /* o : Q_fb_synth_ref */ Word16 Q_fb_synth_ref, /* i : Q-factor of fb_synth_ref[] */ const Word16 output_frame /* i : output frame length */ ); void tbe_read_bitstream_fx( Decoder_State *st_fx /* i/o: encoder state structure */ Loading @@ -5548,8 +5576,8 @@ void GenTransition_fx( TD_BWE_DEC_HANDLE hBWE_TD, /* i/o: TD BWE data handle */ Word16 *output_HB, /* o : synthesized HB transitions signal st_fx->prev_Q_bwe_syn2 */ const Word32 output_Fs, /* i : output sampling rate */ Word16 rf_flag, /* i : RF flag */ Word32 total_bitrate /* i : total bitrate */ const Word16 rf_flag, /* i : RF flag */ const Word32 total_bitrate /* i : total bitrate */ ); void GenTransition_fx32( Loading Loading @@ -9818,6 +9846,7 @@ void v_sub32_fx( const Word16 N /* i : Vector length */ ); #ifndef HARMONIZE_TBE3 void swb_tbe_dec_ivas_fx( Decoder_State *st, /* i/o: decoder state structure */ STEREO_ICBWE_DEC_HANDLE hStereoICBWE, /* i/o: IC-BWE state structure */ Loading @@ -9826,10 +9855,11 @@ void swb_tbe_dec_ivas_fx( const Word16 voice_factors_fx[], /* i : voicing factors : Q15 */ const Word16 old_syn_12k8_16k_fx16[], /* i : low band synthesis : old_syn_fx */ Word16 *White_exc16k_fx, /* o : shaped white excitation for the FB TBE : Q_white_exc*/ Word32 *synth_fx, /* o : SHB synthesis/final synthesis : Qx */ Word32 *synth_fx, /* o : SHB synthesis/final synthesis 32-bit : Qx */ Word16 *pitch_buf_fx, /* i : Q6 */ Word16 *Q_white_exc ); Word16 *Q_white_exc /* o : Q-factor of White_exc16k_fx */ ); #endif Word16 swb_bwe_dec_fx32( Decoder_State *st_fx, /* i/o: decoder state structure */ Word32 output_fx[], /* i : synthesis @internal Fs : Q11 */ Loading lib_com/swb_tbe_com_fx.c +391 −315 Original line number Diff line number Diff line Loading @@ -26,7 +26,11 @@ static void create_random_vector_fx( Word16 output[], const Word16 length, Word16 seed[], Word16 element_mode ); static void flip_spectrum_fx( const Word16 input[], Word16 output[], const Word16 length ); #ifdef HARMONIZE_TBE3 static void Calc_st_filt_tbe_fx( const Word16 element_mode, const Word16 enc_dec, Word16 *apond2, Word16 *apond1, Word16 *parcor0, Word16 *sig_ltp_ptr, Word16 *mem_zero ); #else static void Calc_st_filt_tbe_fx( Word16 *apond2, Word16 *apond1, Word16 *parcor0, Word16 *sig_ltp_ptr, Word16 *mem_zero ); #endif static void Hilbert_transform_fx( Word32 tmp_R[], Word32 tmp_I[], Word32 *tmpi_R, Word32 *tmpi_I, const Word16 length, const Word16 HB_stage_id ); static void Hilbert_transform_sp_fx( Word16 tmp_R[], Word16 tmp_I[], Word32 *tmpi_R, Word32 *tmpi_I, const Word16 length, const Word16 HB_stage_id ); static void Estimate_mix_factors_fx( const Word16 *shb_res, const Word16 Q_shb, const Word16 *exc16kWhtnd, const Word16 Q_bwe_exc, const Word16 *White_exc16k_frac, const Word16 Q_frac, const Word32 pow1, const Word16 Q_pow1, const Word32 pow22, const Word16 Q_pow22, Word16 *vf_modified, Word16 *vf_ind ); Loading Loading @@ -431,7 +435,6 @@ void flip_and_downmix_generic_fx32( /* Hilber transform stage - 0 - single precision */ Hilbert_transform_fx( tmp, tmp, tmpi_R, tmpi_I, length, 0 ); Copy32( mem2_ext, tmpi2_R, HILBERT_ORDER2 ); Copy32( mem3_ext, tmpi2_I, HILBERT_ORDER2 ); Loading Loading @@ -605,6 +608,7 @@ static void Hilbert_transform_sp_fx( /*---------------------------------------------- * flip_spectrum_fx *----------------------------------------------*/ void flip_spectrum_fx( const Word16 input[], /* i : input spectrum */ Word16 output[], /* o : output spectrum */ Loading @@ -630,7 +634,12 @@ void flip_spectrum_fx( * * computes 1st parcor from composed filter impulse response *---------------------------------------------------------------------------*/ void Calc_rc0_h( #ifdef HARMONIZE_TBE3 const Word16 element_mode, /* i : element mode */ const Word16 enc_dec, /* i : encoder/decoder flag */ #endif Word16 *h, /* i : impulse response of composed filter */ Word16 *rc0 /* o : 1st parcor */ ) Loading @@ -638,10 +647,41 @@ void Calc_rc0_h( Word32 L_acc; Word16 *ptrs; Word16 acf0, acf1; #ifdef HARMONIZE_TBE3 Word16 tmp2; #endif Word16 temp, sh_acf; Word16 i; /* computation of the autocorrelation function acf */ #ifdef HARMONIZE_TBE3 IF( element_mode != EVS_MONO && enc_dec == ENC ) { L_acc = L_mult( h[0], h[0] ); // TBV: shouldn't it be "shr( h[0], 2 )" ? FOR( i = 1; i < LONG_H_ST; i++ ) { tmp2 = shr( h[i], 2 ); L_acc = L_mac( L_acc, tmp2, tmp2 ); } sh_acf = norm_l( L_acc ); L_acc = L_shl( L_acc, sh_acf ); acf0 = extract_h( L_acc ); ptrs = h; temp = *ptrs++; move16(); L_acc = L_mult( temp, *ptrs ); FOR( i = 1; i < LONG_H_ST - 1; i++ ) { temp = shr( *ptrs++, 2 ); move16(); L_acc = L_mac( L_acc, temp, shr( *ptrs, 2 ) ); } } ELSE #endif { L_acc = L_mult( h[0], h[0] ); FOR( i = 1; i < LONG_H_ST; i++ ) { Loading @@ -662,6 +702,7 @@ void Calc_rc0_h( move16(); L_acc = L_mac( L_acc, temp, *ptrs ); } } L_acc = L_shl( L_acc, sh_acf ); acf1 = extract_h( L_acc ); Loading Loading @@ -690,6 +731,7 @@ void Calc_rc0_h( return; } #ifndef HARMONIZE_TBE3 static void Calc_rc0_h_ivas_enc_fx( Word16 *h, /* i : impulse response of composed filter */ Word16 *rc0 /* o : 1st parcor */ Loading Loading @@ -748,8 +790,13 @@ static void Calc_rc0_h_ivas_enc_fx( move16(); } } #endif static void Calc_st_filt_tbe_fx( #ifdef HARMONIZE_TBE3 const Word16 element_mode, /* i : element mode */ const Word16 enc_dec, /* i : encoder/decoder flag */ #endif Word16 *apond2, /* i : coefficients of numerator */ Word16 *apond1, /* i : coefficients of denominator */ Word16 *parcor0, /* o : 1st parcor calcul. on composed filter */ Loading @@ -764,10 +811,27 @@ static void Calc_st_filt_tbe_fx( Word16 g0, temp; Word16 i; temp = sub( 2, norm_s( apond2[0] ) ); #ifdef HARMONIZE_TBE3 IF( element_mode != EVS_MONO && enc_dec == ENC ) { /* compute i.r. of composed filter apond2 / apond1 */ syn_filt_fx( temp, apond1, LPC_SHB_ORDER, apond2, h, LONG_H_ST, mem_zero, 0 ); } ELSE #endif { /* compute i.r. of composed filter apond2 / apond1 */ Syn_filt_s( temp, apond1, LPC_SHB_ORDER, apond2, h, LONG_H_ST, mem_zero, 0 ); } /* compute 1st parcor */ #ifdef HARMONIZE_TBE3 Calc_rc0_h( element_mode, enc_dec, h, parcor0 ); #else Calc_rc0_h( h, parcor0 ); #endif /* compute g0 */ L_g0 = L_mult0( 1, abs_s( h[0] ) ); Loading @@ -791,6 +855,7 @@ static void Calc_st_filt_tbe_fx( return; } #ifndef HARMONIZE_TBE3 static void Calc_st_filt_tbe_ivas_enc_fx( Word16 *apond2, /* i : coefficients of numerator */ Word16 *apond1, /* i : coefficients of denominator */ Loading Loading @@ -832,6 +897,7 @@ static void Calc_st_filt_tbe_ivas_enc_fx( return; } #endif static void filt_mu_fx( const Word16 *sig_in, /* i : signal (beginning at sample -1) */ Loading Loading @@ -874,9 +940,7 @@ static void filt_mu_fx( tmp = div_s( shl( 1, sub( 14, exp ) ), tmp ); /*(14 - exp) */ ga = shl_sat( tmp, exp ); /*Q14 */ /* ga = (float) 1. / ((float) 1. - (float) fabs (mu)); */ ptrs = sig_in; /* points on sig_in(-1) */ FOR( n = 0; n < SubFrameLength; n++ ) Loading Loading @@ -992,7 +1056,18 @@ static void scale_st_swb( return; } /*-------------------------------------------------------------------* * PostShortTerm() * * Short term processing *-------------------------------------------------------------------*/ void PostShortTerm_fx( #ifdef HARMONIZE_TBE3 const Word16 element_mode, /* i : element mode */ const Word16 enc_dec, /* i : encoder/decoder flag */ #endif Word16 *sig_in, /* i : input signal (pointer to current subframe */ Word16 *lpccoeff, /* i : LPC coefficients for current subframe */ Word16 *sig_out, /* o : postfiltered output */ Loading @@ -1006,7 +1081,6 @@ void PostShortTerm_fx( Word16 apond1_fx[LPC_SHB_ORDER + 1]; /* denominator coeff.*/ Word16 apond2_fx[LONG_H_ST]; /* numerator coeff. */ Word16 sig_ltp_fx[L_SUBFR16k + 1]; /* residual signal */ /*Word16 lpccoeff_fx[LPC_SHB_ORDER+1];//Q12 */ Word16 g1_fx, g2_fx, parcor0_fx; /*Q15 */ Word16 tmp; Loading @@ -1023,28 +1097,37 @@ void PostShortTerm_fx( /* Compute weighted LPC coefficients */ weight_a_fx( lpccoeff, apond1_fx, g1_fx, LPC_SHB_ORDER ); weight_a_fx( lpccoeff, apond2_fx, g2_fx, LPC_SHB_ORDER ); /* o: apond1_fx, apond2_fx in Q12 */ weight_a_fx( lpccoeff, apond2_fx, g2_fx, LPC_SHB_ORDER ); /* apond1_fx, apond2_fx in Q12 */ /* Compute A(gamma2) residual */ Residu3_10_fx( apond2_fx, sig_in, sig_ltp_fx + 1, L_SUBFR16k, 0 ); /* o: sig_ltp_fx in Q_bwe_exc */ Residu3_10_fx( apond2_fx, sig_in, sig_ltp_fx + 1, L_SUBFR16k, 0 ); /* sig_ltp_fx in Q_bwe_exc */ /* Save last output of 1/A(gamma1) */ sig_ltp_fx[0] = *ptr_mem_stp; move16(); /* Control short term pst filter gain and compute parcor0 */ #ifdef HARMONIZE_TBE3 Calc_st_filt_tbe_fx( element_mode, enc_dec, apond2_fx, apond1_fx, &parcor0_fx, sig_ltp_fx + 1, mem_zero ); /* parcor0 in Q15, sig_ltp_fx in Q_bwe_exc */ #else Calc_st_filt_tbe_fx( apond2_fx, apond1_fx, &parcor0_fx, sig_ltp_fx + 1, mem_zero ); /* o: parcor0 in Q15 */ /* i/o: sig_ltp_fx in Q_bwe_exc */ /* i: parcor0 in Q15, o: sig_ltp_fx in Q_bwe_exc */ #endif /* 1/A(gamma1) filtering, mem_stp is updated */ #ifdef HARMONIZE_TBE3 IF( element_mode != EVS_MONO && enc_dec == ENC ) { syn_filt_fx( 0, apond1_fx, LPC_SHB_ORDER, sig_ltp_fx + 1, sig_ltp_fx + 1, L_SUBFR16k, mem_stp, 1 ); } ELSE #endif { Syn_filt_s( 0, apond1_fx, LPC_SHB_ORDER, sig_ltp_fx + 1, sig_ltp_fx + 1, L_SUBFR16k, mem_stp, 1 ); } /* (1 + mu z-1) tilt filtering */ filt_mu_fx( sig_ltp_fx, sig_out, parcor0_fx, L_SUBFR16k ); /* o: sig_out in Q_bwe_exc */ filt_mu_fx( sig_ltp_fx, sig_out, parcor0_fx, L_SUBFR16k ); /* sig_out in Q_bwe_exc */ /* gain control */ scale_st_swb( sig_in, sig_out, ptr_gain_prec, L_SUBFR16k ); Loading @@ -1052,6 +1135,7 @@ void PostShortTerm_fx( return; } #ifndef HARMONIZE_TBE3 void PostShortTerm_ivas_enc_fx( Word16 *sig_in, /* i : input signal (pointer to current subframe */ Word16 *lpccoeff, /* i : LPC coefficients for current subframe */ Loading Loading @@ -1171,7 +1255,7 @@ void PostShortTerm_ivas_dec_fx( return; } #endif /*-------------------------------------------------------------------* * flip_spectrum_and_decimby4() Loading Loading @@ -2180,7 +2264,7 @@ void GenShapedSHBExcitation_fx( *mem_csfilt = Mult_32_16( L_tmp, varEnvShape ); move32(); } { /* Track the low band envelope */ L_tmp = *mem_csfilt; move32(); Loading @@ -2194,8 +2278,7 @@ void GenShapedSHBExcitation_fx( } *mem_csfilt = L_tmp; move32(); } { /* create a random excitation - Reuse exc16k memory */ White_exc16k = exc16k; create_random_vector_fx( White_exc16k, L_FRAME, bwe_seed, element_mode ); Loading Loading @@ -2241,12 +2324,10 @@ void GenShapedSHBExcitation_fx( } /*Q_pow22 = sub( shl(*Q_bwe_exc,1), 18 );*/ Q_pow22 = shl( sub( *Q_bwe_exc, NOISE_QADJ ), 1 ); } IF( GE_32( bitrate, ACELP_24k40 ) ) { IF( EQ_16( *vf_ind, 20 ) ) /* encoder side */ { { Estimate_mix_factors_fx( shb_res, Q_shb, exc16kWhtnd, *Q_bwe_exc, White_exc16k, ( *Q_bwe_exc - NOISE_QADJ ), pow1, Q_pow1, pow22, Q_pow22, voiceFacEst, vf_ind ); Loading @@ -2260,10 +2341,9 @@ void GenShapedSHBExcitation_fx( move16(); } } } ELSE /* decoder side */ { { /* *vf_ind is an integer scale by 0.125f*/ /* *vf_ind is an integer scale by 0.125f*/ tmp = shl( *vf_ind, ( 15 - 3 ) ); tmp2 = MAX_16; move16(); Loading @@ -2273,7 +2353,6 @@ void GenShapedSHBExcitation_fx( move16(); } } } { voice_factors[0] = mult_r( voice_factors[0], tmp2 ); move16(); Loading Loading @@ -6218,7 +6297,6 @@ void create_random_vector_fx( /* INPUT/OUTPUT ARGUMENTS : */ /* _ None */ /*--------------------------------------------------------------------------------------*/ /* _ None */ /*--------------------------------------------------------------------------------------*/ /* RETURN ARGUMENTS : */ Loading @@ -6233,14 +6311,14 @@ void interp_code_5over2_fx( { Word16 i, kk, kkp1, i_len2; Word32 Ltemp; Word16 factor_i_fx[5] = { 6554, 19661, 32767, 19661, 6554 }; const Word16 factor_i_fx[5] = { 6554, 19661, 32767, 19661, 6554 }; move16(); move16(); move16(); move16(); move16(); move16(); Word16 factor_j_fx[5] = { 26214, 13107, 0, 13107, 26214 }; const Word16 factor_j_fx[5] = { 26214, 13107, 0, 13107, 26214 }; move16(); move16(); move16(); Loading Loading @@ -6323,7 +6401,6 @@ void interp_code_5over2_fx( /* INPUT/OUTPUT ARGUMENTS : */ /* _ None */ /*--------------------------------------------------------------------------------------*/ /* _ None */ /*--------------------------------------------------------------------------------------*/ /* RETURN ARGUMENTS : */ Loading Loading @@ -6873,7 +6950,6 @@ static void Estimate_mix_factors_fx( /* temp_p1_p3 = (float)sqrt(pow1/pow3); */ temp_p1_p3 = root_a_over_b_fx( pow1, Q_pow1, pow3, ( 2 * Q_shb + 1 ), &exp2 ); /* temp_p1_p3 in (Q31+exp2) */ sc1 = sub( Q_bwe_exc, sub( Q_frac, exp1 ) ); sc2 = sub( Q_bwe_exc, sub( Q_shb, exp2 ) ); FOR( i = 0; i < L_FRAME16k; i++ ) Loading Loading
lib_com/cng_exc_fx.c +4 −0 Original line number Diff line number Diff line Loading @@ -872,7 +872,11 @@ void cng_params_upd_fx( Word16 index = 0; move32(); move16(); #ifdef HARM_2456_APPLY_SCALE index = apply_scale_ind( &att_fx, bwidth, last_active_brate, scaleTableStereo, SIZE_SCALE_TABLE_STEREO ); #else apply_scale_ivas_fx( &att_fx, bwidth, last_active_brate, scaleTableStereo, SIZE_SCALE_TABLE_STEREO, &index ); #endif att_fx = pow_10_q23[index]; // Q23 move32(); tmp = extract_h( att_fx ); // Q7 Loading
lib_com/fd_cng_com_fx.c +3 −0 Original line number Diff line number Diff line Loading @@ -1751,9 +1751,11 @@ Word16 apply_scale_ind( *scale = L_add( *scale, L_deposit_h( scaleTable[i].scale ) ); move32(); } return i; } #ifndef HARM_2456_APPLY_SCALE void apply_scale_ivas_fx( Word32 *scale, /* o : scalefactor */ const Word16 bwmode, /* i : audio bandwidth */ Loading @@ -1780,6 +1782,7 @@ void apply_scale_ivas_fx( *index = i; move16(); } #endif /*------------------------------------------------------------------- * bandcombinepow() * Loading
lib_com/options.h +5 −0 Original line number Diff line number Diff line Loading @@ -98,6 +98,10 @@ #define FIX_2431_AVOID_CALLOC /* VA: basp issue 2431: avoid use of calloc() */ #define FIX_2424_REMOVE_GAUSS_L2_ENC /* VA: basop issue 2424: Remove duplicated code in gauss_L2_ivas_fx() */ #define FIX_MDCT_STEREO_ENC_STACK /* VA: basop issue 2428: Move IGF temporary buffers out of the highest stack */ #define HARMONIZE_TBE3 /* VA: basop issue 2399: Remove duplicated code: TBE, step 3 */ #define FIX_2459_USAN_AMR_SIDSTART /* FhG: basop issue 2459: fix msan complaint */ #define FIX_2458_USAN_NULLPTR_WITH_ZERO_OFFSET /* FhG: basop issue 2458: avoid indexing into null pointer */ #define HARM_2456_APPLY_SCALE /* FhG basop issue 2456: Harmonize apply_scale_ind(), apply_scale_ivas_fx() */ #define HARM_2454_TCX_RES_Q_SPEC /* FhG: harmonization of tcx_res_Q_spec_fx() and tcx_res_Q_spec_ivas_fx() */ /* #################### End BE switches ################################## */ Loading @@ -111,6 +115,7 @@ #define FIX_2283_ISM_MD_DELAY /* Dolby: Fix ISM metadata delay round-off */ #define FIX_2283_Q_CLDFB /* FhG: Fix Q format issue in CLDFB */ #define FIX_2283_ACCU_CLDFB /* FhG: Fix to consider Q-format differences in accumulateCLDFBArrayToBuffer_fx() */ #define FIX_1530_Codec_Level_Harmonization_Non_diegetic_panning /* FhG: Adjust non-diegetic panning law to harmonize codec levels with 3GPP reference software */ #define FIX_FLOAT_1518 /* FhG: fix issue 1518: loudness differences in OSBA decoding to mono or stereo output */ #define FIX_FLOAT_1533_BLEND_SUBFR2 /* FhG: float issue 1533: correct blending in blend_subfr2() */ Loading
lib_com/prot_fx.h +50 −20 Original line number Diff line number Diff line Loading @@ -2669,11 +2669,19 @@ void flip_and_downmix_generic_fx( ); void Calc_rc0_h( #ifdef HARMONIZE_TBE3 const Word16 element_mode, /* i : element mode */ const Word16 enc_dec, /* i : encoder/decoder flag */ #endif Word16 *h, /* i : impulse response of composed filter */ Word16 *rc0 /* o : 1st parcor */ ); void PostShortTerm_fx( #ifdef HARMONIZE_TBE3 const Word16 element_mode, /* i : element mode */ const Word16 enc_dec, /* i : encoder/decoder flag */ #endif Word16 *sig_in, /* i : i signal (pointer to current subframe */ Word16 *lpccoeff, /* i : LPC coefficients for current subframe */ Word16 *sig_out, /* o : postfiltered output */ Loading @@ -2684,6 +2692,7 @@ void PostShortTerm_fx( const Word16 formant_fac_fx /* i : Strength of post-filter*/ ); #ifndef HARMONIZE_TBE3 void PostShortTerm_ivas_enc_fx( Word16 *sig_in, /* i : i signal (pointer to current subframe */ Word16 *lpccoeff, /* i : LPC coefficients for current subframe */ Loading @@ -2705,7 +2714,7 @@ void PostShortTerm_ivas_dec_fx( Word16 *mem_zero, /* i/o: null memory to compute h_st*/ const Word16 formant_fac_fx /* i : Strength of post-filter*/ ); #endif void flip_spectrum_and_decimby4_fx( const Word16 i[], /* i : i spectrum */ Word16 output[], /* o : output spectrum */ Loading Loading @@ -4875,6 +4884,7 @@ Word16 apply_scale_ind( const SCALE_SETUP *scaleTable, /* i : Scale table */ const Word16 scaleTableSize /* i : Size of scale table */ ); #ifndef HARM_2456_APPLY_SCALE void apply_scale_ivas_fx( Word32 *scale, /* o : scalefactor */ const Word16 bwmode, /* i : audio bandwidth */ Loading @@ -4882,6 +4892,7 @@ void apply_scale_ivas_fx( const SCALE_SETUP *scaleTable, /* i : Scale table */ const Word16 scaleTableSize, /* i : Size of scale table */ Word16 *index ); #endif /* Compute the power for each partition */ void bandcombinepow( Loading Loading @@ -5516,6 +5527,21 @@ void wb_tbe_dec_fx( Word16 *synth, /* i/o: ACELP core synthesis/final synthesis */ Word16 *Q_synth ); #ifdef HARMONIZE_TBE3 void swb_tbe_dec_fx( Decoder_State *st, /* i/o: decoder state structure */ STEREO_ICBWE_DEC_HANDLE hStereoICBWE, /* i/o: IC-BWE state structure */ const Word32 *bwe_exc_extended_fx, /* i : bandwidth extended excitation : Q_exc */ const Word16 voice_factors_fx[], /* i : voicing factors : Q15 */ const Word16 old_syn_12k8_16k_fx16[], /* i : low band synthesis : old_syn_fx */ Word16 *White_exc16k_fx, /* o : shaped white excitation for the FB TBE : Q_white_exc*/ Word16 *Q_white_exc, /* o : Q-factor of White_exc16k_fx */ Word16 *synth_fx16, /* o : SHB synthesis/final synthesis 16-bit : Qx */ Word32 *synth_fx, /* o : SHB synthesis/final synthesis 32-bit : Qx */ Word16 *Q_synth, /* o : Q-factor of synth_fx16[]/synth_fx[] */ Word16 *pitch_buf_fx /* i : Q6 */ ); #else void swb_tbe_dec_fx( Decoder_State *st_fx, /* i/o: decoder state structure */ const Word16 coder_type, /* i : coding type */ Loading @@ -5528,17 +5554,19 @@ void swb_tbe_dec_fx( Word16 *synth, /* o : SHB synthesis/final synthesis */ Word16 *Q_synth, Word16 *pitch_buf ); #endif void fb_tbe_dec_fx( Decoder_State *st, /* i/o: encoder state structure */ const Word16 fb_exc[], /* i : FB excitation from the SWB part */ Word16 Q_fb_exc, const Word16 fb_exc[], /* i : FB excitation from the SWB part Q_fb_exc */ const Word16 Q_fb_exc, /* i : Q-factor of fb_exc[] */ Word16 *hb_synth16, /* o : high-band synthesis Q(15 - hb_synth_exp) */ Word32 *hb_synth, /* o : high-band synthesis */ Word16 hb_synth_exp, Word16 *fb_synth_ref, Word16 Q_fb_synth_ref, Word16 output_frame ); Word32 *hb_synth, /* o : high-band synthesis Q(15 - hb_synth_exp) */ const Word16 hb_synth_exp, /* i : Q-factor of hb_synth[] */ Word16 *fb_synth_ref, /* o : Q_fb_synth_ref */ Word16 Q_fb_synth_ref, /* i : Q-factor of fb_synth_ref[] */ const Word16 output_frame /* i : output frame length */ ); void tbe_read_bitstream_fx( Decoder_State *st_fx /* i/o: encoder state structure */ Loading @@ -5548,8 +5576,8 @@ void GenTransition_fx( TD_BWE_DEC_HANDLE hBWE_TD, /* i/o: TD BWE data handle */ Word16 *output_HB, /* o : synthesized HB transitions signal st_fx->prev_Q_bwe_syn2 */ const Word32 output_Fs, /* i : output sampling rate */ Word16 rf_flag, /* i : RF flag */ Word32 total_bitrate /* i : total bitrate */ const Word16 rf_flag, /* i : RF flag */ const Word32 total_bitrate /* i : total bitrate */ ); void GenTransition_fx32( Loading Loading @@ -9818,6 +9846,7 @@ void v_sub32_fx( const Word16 N /* i : Vector length */ ); #ifndef HARMONIZE_TBE3 void swb_tbe_dec_ivas_fx( Decoder_State *st, /* i/o: decoder state structure */ STEREO_ICBWE_DEC_HANDLE hStereoICBWE, /* i/o: IC-BWE state structure */ Loading @@ -9826,10 +9855,11 @@ void swb_tbe_dec_ivas_fx( const Word16 voice_factors_fx[], /* i : voicing factors : Q15 */ const Word16 old_syn_12k8_16k_fx16[], /* i : low band synthesis : old_syn_fx */ Word16 *White_exc16k_fx, /* o : shaped white excitation for the FB TBE : Q_white_exc*/ Word32 *synth_fx, /* o : SHB synthesis/final synthesis : Qx */ Word32 *synth_fx, /* o : SHB synthesis/final synthesis 32-bit : Qx */ Word16 *pitch_buf_fx, /* i : Q6 */ Word16 *Q_white_exc ); Word16 *Q_white_exc /* o : Q-factor of White_exc16k_fx */ ); #endif Word16 swb_bwe_dec_fx32( Decoder_State *st_fx, /* i/o: decoder state structure */ Word32 output_fx[], /* i : synthesis @internal Fs : Q11 */ Loading
lib_com/swb_tbe_com_fx.c +391 −315 Original line number Diff line number Diff line Loading @@ -26,7 +26,11 @@ static void create_random_vector_fx( Word16 output[], const Word16 length, Word16 seed[], Word16 element_mode ); static void flip_spectrum_fx( const Word16 input[], Word16 output[], const Word16 length ); #ifdef HARMONIZE_TBE3 static void Calc_st_filt_tbe_fx( const Word16 element_mode, const Word16 enc_dec, Word16 *apond2, Word16 *apond1, Word16 *parcor0, Word16 *sig_ltp_ptr, Word16 *mem_zero ); #else static void Calc_st_filt_tbe_fx( Word16 *apond2, Word16 *apond1, Word16 *parcor0, Word16 *sig_ltp_ptr, Word16 *mem_zero ); #endif static void Hilbert_transform_fx( Word32 tmp_R[], Word32 tmp_I[], Word32 *tmpi_R, Word32 *tmpi_I, const Word16 length, const Word16 HB_stage_id ); static void Hilbert_transform_sp_fx( Word16 tmp_R[], Word16 tmp_I[], Word32 *tmpi_R, Word32 *tmpi_I, const Word16 length, const Word16 HB_stage_id ); static void Estimate_mix_factors_fx( const Word16 *shb_res, const Word16 Q_shb, const Word16 *exc16kWhtnd, const Word16 Q_bwe_exc, const Word16 *White_exc16k_frac, const Word16 Q_frac, const Word32 pow1, const Word16 Q_pow1, const Word32 pow22, const Word16 Q_pow22, Word16 *vf_modified, Word16 *vf_ind ); Loading Loading @@ -431,7 +435,6 @@ void flip_and_downmix_generic_fx32( /* Hilber transform stage - 0 - single precision */ Hilbert_transform_fx( tmp, tmp, tmpi_R, tmpi_I, length, 0 ); Copy32( mem2_ext, tmpi2_R, HILBERT_ORDER2 ); Copy32( mem3_ext, tmpi2_I, HILBERT_ORDER2 ); Loading Loading @@ -605,6 +608,7 @@ static void Hilbert_transform_sp_fx( /*---------------------------------------------- * flip_spectrum_fx *----------------------------------------------*/ void flip_spectrum_fx( const Word16 input[], /* i : input spectrum */ Word16 output[], /* o : output spectrum */ Loading @@ -630,7 +634,12 @@ void flip_spectrum_fx( * * computes 1st parcor from composed filter impulse response *---------------------------------------------------------------------------*/ void Calc_rc0_h( #ifdef HARMONIZE_TBE3 const Word16 element_mode, /* i : element mode */ const Word16 enc_dec, /* i : encoder/decoder flag */ #endif Word16 *h, /* i : impulse response of composed filter */ Word16 *rc0 /* o : 1st parcor */ ) Loading @@ -638,10 +647,41 @@ void Calc_rc0_h( Word32 L_acc; Word16 *ptrs; Word16 acf0, acf1; #ifdef HARMONIZE_TBE3 Word16 tmp2; #endif Word16 temp, sh_acf; Word16 i; /* computation of the autocorrelation function acf */ #ifdef HARMONIZE_TBE3 IF( element_mode != EVS_MONO && enc_dec == ENC ) { L_acc = L_mult( h[0], h[0] ); // TBV: shouldn't it be "shr( h[0], 2 )" ? FOR( i = 1; i < LONG_H_ST; i++ ) { tmp2 = shr( h[i], 2 ); L_acc = L_mac( L_acc, tmp2, tmp2 ); } sh_acf = norm_l( L_acc ); L_acc = L_shl( L_acc, sh_acf ); acf0 = extract_h( L_acc ); ptrs = h; temp = *ptrs++; move16(); L_acc = L_mult( temp, *ptrs ); FOR( i = 1; i < LONG_H_ST - 1; i++ ) { temp = shr( *ptrs++, 2 ); move16(); L_acc = L_mac( L_acc, temp, shr( *ptrs, 2 ) ); } } ELSE #endif { L_acc = L_mult( h[0], h[0] ); FOR( i = 1; i < LONG_H_ST; i++ ) { Loading @@ -662,6 +702,7 @@ void Calc_rc0_h( move16(); L_acc = L_mac( L_acc, temp, *ptrs ); } } L_acc = L_shl( L_acc, sh_acf ); acf1 = extract_h( L_acc ); Loading Loading @@ -690,6 +731,7 @@ void Calc_rc0_h( return; } #ifndef HARMONIZE_TBE3 static void Calc_rc0_h_ivas_enc_fx( Word16 *h, /* i : impulse response of composed filter */ Word16 *rc0 /* o : 1st parcor */ Loading Loading @@ -748,8 +790,13 @@ static void Calc_rc0_h_ivas_enc_fx( move16(); } } #endif static void Calc_st_filt_tbe_fx( #ifdef HARMONIZE_TBE3 const Word16 element_mode, /* i : element mode */ const Word16 enc_dec, /* i : encoder/decoder flag */ #endif Word16 *apond2, /* i : coefficients of numerator */ Word16 *apond1, /* i : coefficients of denominator */ Word16 *parcor0, /* o : 1st parcor calcul. on composed filter */ Loading @@ -764,10 +811,27 @@ static void Calc_st_filt_tbe_fx( Word16 g0, temp; Word16 i; temp = sub( 2, norm_s( apond2[0] ) ); #ifdef HARMONIZE_TBE3 IF( element_mode != EVS_MONO && enc_dec == ENC ) { /* compute i.r. of composed filter apond2 / apond1 */ syn_filt_fx( temp, apond1, LPC_SHB_ORDER, apond2, h, LONG_H_ST, mem_zero, 0 ); } ELSE #endif { /* compute i.r. of composed filter apond2 / apond1 */ Syn_filt_s( temp, apond1, LPC_SHB_ORDER, apond2, h, LONG_H_ST, mem_zero, 0 ); } /* compute 1st parcor */ #ifdef HARMONIZE_TBE3 Calc_rc0_h( element_mode, enc_dec, h, parcor0 ); #else Calc_rc0_h( h, parcor0 ); #endif /* compute g0 */ L_g0 = L_mult0( 1, abs_s( h[0] ) ); Loading @@ -791,6 +855,7 @@ static void Calc_st_filt_tbe_fx( return; } #ifndef HARMONIZE_TBE3 static void Calc_st_filt_tbe_ivas_enc_fx( Word16 *apond2, /* i : coefficients of numerator */ Word16 *apond1, /* i : coefficients of denominator */ Loading Loading @@ -832,6 +897,7 @@ static void Calc_st_filt_tbe_ivas_enc_fx( return; } #endif static void filt_mu_fx( const Word16 *sig_in, /* i : signal (beginning at sample -1) */ Loading Loading @@ -874,9 +940,7 @@ static void filt_mu_fx( tmp = div_s( shl( 1, sub( 14, exp ) ), tmp ); /*(14 - exp) */ ga = shl_sat( tmp, exp ); /*Q14 */ /* ga = (float) 1. / ((float) 1. - (float) fabs (mu)); */ ptrs = sig_in; /* points on sig_in(-1) */ FOR( n = 0; n < SubFrameLength; n++ ) Loading Loading @@ -992,7 +1056,18 @@ static void scale_st_swb( return; } /*-------------------------------------------------------------------* * PostShortTerm() * * Short term processing *-------------------------------------------------------------------*/ void PostShortTerm_fx( #ifdef HARMONIZE_TBE3 const Word16 element_mode, /* i : element mode */ const Word16 enc_dec, /* i : encoder/decoder flag */ #endif Word16 *sig_in, /* i : input signal (pointer to current subframe */ Word16 *lpccoeff, /* i : LPC coefficients for current subframe */ Word16 *sig_out, /* o : postfiltered output */ Loading @@ -1006,7 +1081,6 @@ void PostShortTerm_fx( Word16 apond1_fx[LPC_SHB_ORDER + 1]; /* denominator coeff.*/ Word16 apond2_fx[LONG_H_ST]; /* numerator coeff. */ Word16 sig_ltp_fx[L_SUBFR16k + 1]; /* residual signal */ /*Word16 lpccoeff_fx[LPC_SHB_ORDER+1];//Q12 */ Word16 g1_fx, g2_fx, parcor0_fx; /*Q15 */ Word16 tmp; Loading @@ -1023,28 +1097,37 @@ void PostShortTerm_fx( /* Compute weighted LPC coefficients */ weight_a_fx( lpccoeff, apond1_fx, g1_fx, LPC_SHB_ORDER ); weight_a_fx( lpccoeff, apond2_fx, g2_fx, LPC_SHB_ORDER ); /* o: apond1_fx, apond2_fx in Q12 */ weight_a_fx( lpccoeff, apond2_fx, g2_fx, LPC_SHB_ORDER ); /* apond1_fx, apond2_fx in Q12 */ /* Compute A(gamma2) residual */ Residu3_10_fx( apond2_fx, sig_in, sig_ltp_fx + 1, L_SUBFR16k, 0 ); /* o: sig_ltp_fx in Q_bwe_exc */ Residu3_10_fx( apond2_fx, sig_in, sig_ltp_fx + 1, L_SUBFR16k, 0 ); /* sig_ltp_fx in Q_bwe_exc */ /* Save last output of 1/A(gamma1) */ sig_ltp_fx[0] = *ptr_mem_stp; move16(); /* Control short term pst filter gain and compute parcor0 */ #ifdef HARMONIZE_TBE3 Calc_st_filt_tbe_fx( element_mode, enc_dec, apond2_fx, apond1_fx, &parcor0_fx, sig_ltp_fx + 1, mem_zero ); /* parcor0 in Q15, sig_ltp_fx in Q_bwe_exc */ #else Calc_st_filt_tbe_fx( apond2_fx, apond1_fx, &parcor0_fx, sig_ltp_fx + 1, mem_zero ); /* o: parcor0 in Q15 */ /* i/o: sig_ltp_fx in Q_bwe_exc */ /* i: parcor0 in Q15, o: sig_ltp_fx in Q_bwe_exc */ #endif /* 1/A(gamma1) filtering, mem_stp is updated */ #ifdef HARMONIZE_TBE3 IF( element_mode != EVS_MONO && enc_dec == ENC ) { syn_filt_fx( 0, apond1_fx, LPC_SHB_ORDER, sig_ltp_fx + 1, sig_ltp_fx + 1, L_SUBFR16k, mem_stp, 1 ); } ELSE #endif { Syn_filt_s( 0, apond1_fx, LPC_SHB_ORDER, sig_ltp_fx + 1, sig_ltp_fx + 1, L_SUBFR16k, mem_stp, 1 ); } /* (1 + mu z-1) tilt filtering */ filt_mu_fx( sig_ltp_fx, sig_out, parcor0_fx, L_SUBFR16k ); /* o: sig_out in Q_bwe_exc */ filt_mu_fx( sig_ltp_fx, sig_out, parcor0_fx, L_SUBFR16k ); /* sig_out in Q_bwe_exc */ /* gain control */ scale_st_swb( sig_in, sig_out, ptr_gain_prec, L_SUBFR16k ); Loading @@ -1052,6 +1135,7 @@ void PostShortTerm_fx( return; } #ifndef HARMONIZE_TBE3 void PostShortTerm_ivas_enc_fx( Word16 *sig_in, /* i : input signal (pointer to current subframe */ Word16 *lpccoeff, /* i : LPC coefficients for current subframe */ Loading Loading @@ -1171,7 +1255,7 @@ void PostShortTerm_ivas_dec_fx( return; } #endif /*-------------------------------------------------------------------* * flip_spectrum_and_decimby4() Loading Loading @@ -2180,7 +2264,7 @@ void GenShapedSHBExcitation_fx( *mem_csfilt = Mult_32_16( L_tmp, varEnvShape ); move32(); } { /* Track the low band envelope */ L_tmp = *mem_csfilt; move32(); Loading @@ -2194,8 +2278,7 @@ void GenShapedSHBExcitation_fx( } *mem_csfilt = L_tmp; move32(); } { /* create a random excitation - Reuse exc16k memory */ White_exc16k = exc16k; create_random_vector_fx( White_exc16k, L_FRAME, bwe_seed, element_mode ); Loading Loading @@ -2241,12 +2324,10 @@ void GenShapedSHBExcitation_fx( } /*Q_pow22 = sub( shl(*Q_bwe_exc,1), 18 );*/ Q_pow22 = shl( sub( *Q_bwe_exc, NOISE_QADJ ), 1 ); } IF( GE_32( bitrate, ACELP_24k40 ) ) { IF( EQ_16( *vf_ind, 20 ) ) /* encoder side */ { { Estimate_mix_factors_fx( shb_res, Q_shb, exc16kWhtnd, *Q_bwe_exc, White_exc16k, ( *Q_bwe_exc - NOISE_QADJ ), pow1, Q_pow1, pow22, Q_pow22, voiceFacEst, vf_ind ); Loading @@ -2260,10 +2341,9 @@ void GenShapedSHBExcitation_fx( move16(); } } } ELSE /* decoder side */ { { /* *vf_ind is an integer scale by 0.125f*/ /* *vf_ind is an integer scale by 0.125f*/ tmp = shl( *vf_ind, ( 15 - 3 ) ); tmp2 = MAX_16; move16(); Loading @@ -2273,7 +2353,6 @@ void GenShapedSHBExcitation_fx( move16(); } } } { voice_factors[0] = mult_r( voice_factors[0], tmp2 ); move16(); Loading Loading @@ -6218,7 +6297,6 @@ void create_random_vector_fx( /* INPUT/OUTPUT ARGUMENTS : */ /* _ None */ /*--------------------------------------------------------------------------------------*/ /* _ None */ /*--------------------------------------------------------------------------------------*/ /* RETURN ARGUMENTS : */ Loading @@ -6233,14 +6311,14 @@ void interp_code_5over2_fx( { Word16 i, kk, kkp1, i_len2; Word32 Ltemp; Word16 factor_i_fx[5] = { 6554, 19661, 32767, 19661, 6554 }; const Word16 factor_i_fx[5] = { 6554, 19661, 32767, 19661, 6554 }; move16(); move16(); move16(); move16(); move16(); move16(); Word16 factor_j_fx[5] = { 26214, 13107, 0, 13107, 26214 }; const Word16 factor_j_fx[5] = { 26214, 13107, 0, 13107, 26214 }; move16(); move16(); move16(); Loading Loading @@ -6323,7 +6401,6 @@ void interp_code_5over2_fx( /* INPUT/OUTPUT ARGUMENTS : */ /* _ None */ /*--------------------------------------------------------------------------------------*/ /* _ None */ /*--------------------------------------------------------------------------------------*/ /* RETURN ARGUMENTS : */ Loading Loading @@ -6873,7 +6950,6 @@ static void Estimate_mix_factors_fx( /* temp_p1_p3 = (float)sqrt(pow1/pow3); */ temp_p1_p3 = root_a_over_b_fx( pow1, Q_pow1, pow3, ( 2 * Q_shb + 1 ), &exp2 ); /* temp_p1_p3 in (Q31+exp2) */ sc1 = sub( Q_bwe_exc, sub( Q_frac, exp1 ) ); sc2 = sub( Q_bwe_exc, sub( Q_shb, exp2 ) ); FOR( i = 0; i < L_FRAME16k; i++ ) Loading