Loading lib_com/enhancer_fx.c +2 −2 Original line number Diff line number Diff line Loading @@ -443,7 +443,7 @@ void enhancer_ivas_fx( sc = 6; move16(); gain_code_hi = extract_h(L_shl_sat(L_tmp, add(Q_exc, 3))); /* in Q_exc */ gain_code_hi = round_fx(L_shl(L_tmp, add(Q_exc, 3))); /* in Q_exc */ /*------------------------------------------------------------* * pitch enhancer Loading @@ -458,7 +458,7 @@ void enhancer_ivas_fx( /* Copy(code, exc2, L_SUBFR) */ FOR(i = 0; i < L_SUBFR; i++) { pt_exc2[i] = extract_h(L_shl_sat(L_mult(gain_code_hi, code[i]), sc)); /*Q0 */ /* code in Q12 (Q9 for encoder) */ pt_exc2[i] = round_fx(L_shl(L_mult(gain_code_hi, code[i]), sc)); /*Q0 */ /* code in Q12 (Q9 for encoder) */ } } ELSE Loading lib_com/prot_fx2.h +0 −1 Original line number Diff line number Diff line Loading @@ -7992,7 +7992,6 @@ void generate_comfort_noise_dec_hf_ivas_fx( Word16 *exc_fx, /* Q_X o : adapt. excitation exc */ Word16 *exc2_fx, /* Q_X o : adapt. excitation/total exc */ Word16 *bwe_exc_fx, /* Q_X i/o: excitation for SWB TBE */ Word16 Q_exc, Word16 *gain_buf ); Loading lib_dec/acelp_core_dec_ivas_fx.c +1 −1 Original line number Diff line number Diff line Loading @@ -1156,7 +1156,7 @@ ivas_error acelp_core_dec_ivas_fx( /* UNVOICED frames */ //decod_unvoiced( st, Aq, Es_pred, uc_two_stage_flag, &tmp_noise, pitch_buf, voice_factors, exc, exc2, bwe_exc, gain_buf ); //decod_unvoiced_fx( st, Aq_fx, st->coder_type, &tmp_noise_fx, pitch_buf_out_fx, voice_factors_fx, exc_fx, exc2_fx, bwe_exc_fx, gain_buf_fx); decod_unvoiced_ivas_fx( st, Aq_fx, Es_pred_fx, uc_two_stage_flag, st->coder_type, &tmp_noise_fx, pitch_buf_fx, voice_factors_fx, exc_fx, exc2_fx, bwe_exc_fx, st->Q_exc, gain_buf_fx); decod_unvoiced_ivas_fx( st, Aq_fx, Es_pred_fx, uc_two_stage_flag, st->coder_type, &tmp_noise_fx, pitch_buf_fx, voice_factors_fx, exc_fx, exc2_fx, bwe_exc_fx, gain_buf_fx); tmp_noise_fx = shr_r(st->lp_gainc_fx, 3); /*Q0*/ } else if ( st->ppp_mode_dec) Loading lib_dec/bass_psfilter_fx.c +5 −5 Original line number Diff line number Diff line Loading @@ -323,10 +323,10 @@ void bass_psfilter_fx( { Lcorr0 = L_mult0( syn_fx[j], syn2_fx[j]); Lener0 = L_mult0(syn2_fx[j], syn2_fx[j]); Lcorr0 = L_mac0_sat(Lcorr0, syn_fx[j+1], syn2_fx[j+1]); Lener0 = L_mac0_sat(Lener0, syn2_fx[j+1], syn2_fx[j+1]); Lcorr0 = L_mac0(Lcorr0, syn_fx[j+1], syn2_fx[j+1]); Lener0 = L_mac0(Lener0, syn2_fx[j+1], syn2_fx[j+1]); Lcorr = L_add_sat(Lcorr, L_shr(Lcorr0, 4)); Lcorr = L_add(Lcorr, L_shr(Lcorr0, 4)); Lener = L_add(Lener, L_shr(Lener0, 4)); /* this loop is not efficient but it provide a respectable precision while avoiding overflow. */ Loading Loading @@ -403,7 +403,7 @@ void bass_psfilter_fx( exp2 = sub(exp, exp2); /* exponent num - exponent denom */ /* alpha = corr / ener */ #ifdef BASOP_NOGLOB alpha = shr_sat(div_s(round_fx_sat(L_shl(Ltmp, exp)), tmp2), exp2); /*Q15 */ alpha = shr_sat(div_s(round_fx(L_shl(Ltmp, exp)), tmp2), exp2); /*Q15 */ #else alpha = shr(div_s(round_fx(L_shl(Ltmp, exp)), tmp2), exp2); /*Q15 */ #endif Loading Loading @@ -452,7 +452,7 @@ void bass_psfilter_fx( FOR (i=0; i< subfr_len; i++) { /*syn2_fx[i] = alpha*(syn_fx[i]-syn2_fx[i]); */ tmp = sub_sat(syn_fx[i],syn2_fx[i]); tmp = sub(syn_fx[i],syn2_fx[i]); #ifdef BASOP_NOGLOB syn2_fx[i] = mult_sat(alpha, shl_sat(tmp, 1)); #else Loading lib_dec/dec_gen_voic_fx.c +2 −2 Original line number Diff line number Diff line Loading @@ -692,7 +692,7 @@ ivas_error decod_gen_voic_ivas_fx( { L_tmp_GC = L_max(gain_code_fx, L_shl(gain_preQ_fx,16)); /* Chose the maximum of gain_code or the prequantizer excitation x4 to keep some room*/ Rescale_exc(hMusicPF->dct_post_old_exc_fx, &exc_fx[i_subfr_fx], &bwe_exc_fx[i_subfr_fx * 2], hGSCDec->last_exc_dct_in_fx, Rescale_exc(hMusicPF->dct_post_old_exc_fx, &exc_fx[i_subfr_fx], (bwe_exc_fx != NULL) ? &bwe_exc_fx[i_subfr_fx * 2] : NULL, hGSCDec->last_exc_dct_in_fx, L_SUBFR, L_SUBFR * 2, L_tmp_GC, &(st_fx->Q_exc), st_fx->Q_subfr, exc2_fx, i_subfr_fx, st_fx->coder_type); } Loading Loading
lib_com/enhancer_fx.c +2 −2 Original line number Diff line number Diff line Loading @@ -443,7 +443,7 @@ void enhancer_ivas_fx( sc = 6; move16(); gain_code_hi = extract_h(L_shl_sat(L_tmp, add(Q_exc, 3))); /* in Q_exc */ gain_code_hi = round_fx(L_shl(L_tmp, add(Q_exc, 3))); /* in Q_exc */ /*------------------------------------------------------------* * pitch enhancer Loading @@ -458,7 +458,7 @@ void enhancer_ivas_fx( /* Copy(code, exc2, L_SUBFR) */ FOR(i = 0; i < L_SUBFR; i++) { pt_exc2[i] = extract_h(L_shl_sat(L_mult(gain_code_hi, code[i]), sc)); /*Q0 */ /* code in Q12 (Q9 for encoder) */ pt_exc2[i] = round_fx(L_shl(L_mult(gain_code_hi, code[i]), sc)); /*Q0 */ /* code in Q12 (Q9 for encoder) */ } } ELSE Loading
lib_com/prot_fx2.h +0 −1 Original line number Diff line number Diff line Loading @@ -7992,7 +7992,6 @@ void generate_comfort_noise_dec_hf_ivas_fx( Word16 *exc_fx, /* Q_X o : adapt. excitation exc */ Word16 *exc2_fx, /* Q_X o : adapt. excitation/total exc */ Word16 *bwe_exc_fx, /* Q_X i/o: excitation for SWB TBE */ Word16 Q_exc, Word16 *gain_buf ); Loading
lib_dec/acelp_core_dec_ivas_fx.c +1 −1 Original line number Diff line number Diff line Loading @@ -1156,7 +1156,7 @@ ivas_error acelp_core_dec_ivas_fx( /* UNVOICED frames */ //decod_unvoiced( st, Aq, Es_pred, uc_two_stage_flag, &tmp_noise, pitch_buf, voice_factors, exc, exc2, bwe_exc, gain_buf ); //decod_unvoiced_fx( st, Aq_fx, st->coder_type, &tmp_noise_fx, pitch_buf_out_fx, voice_factors_fx, exc_fx, exc2_fx, bwe_exc_fx, gain_buf_fx); decod_unvoiced_ivas_fx( st, Aq_fx, Es_pred_fx, uc_two_stage_flag, st->coder_type, &tmp_noise_fx, pitch_buf_fx, voice_factors_fx, exc_fx, exc2_fx, bwe_exc_fx, st->Q_exc, gain_buf_fx); decod_unvoiced_ivas_fx( st, Aq_fx, Es_pred_fx, uc_two_stage_flag, st->coder_type, &tmp_noise_fx, pitch_buf_fx, voice_factors_fx, exc_fx, exc2_fx, bwe_exc_fx, gain_buf_fx); tmp_noise_fx = shr_r(st->lp_gainc_fx, 3); /*Q0*/ } else if ( st->ppp_mode_dec) Loading
lib_dec/bass_psfilter_fx.c +5 −5 Original line number Diff line number Diff line Loading @@ -323,10 +323,10 @@ void bass_psfilter_fx( { Lcorr0 = L_mult0( syn_fx[j], syn2_fx[j]); Lener0 = L_mult0(syn2_fx[j], syn2_fx[j]); Lcorr0 = L_mac0_sat(Lcorr0, syn_fx[j+1], syn2_fx[j+1]); Lener0 = L_mac0_sat(Lener0, syn2_fx[j+1], syn2_fx[j+1]); Lcorr0 = L_mac0(Lcorr0, syn_fx[j+1], syn2_fx[j+1]); Lener0 = L_mac0(Lener0, syn2_fx[j+1], syn2_fx[j+1]); Lcorr = L_add_sat(Lcorr, L_shr(Lcorr0, 4)); Lcorr = L_add(Lcorr, L_shr(Lcorr0, 4)); Lener = L_add(Lener, L_shr(Lener0, 4)); /* this loop is not efficient but it provide a respectable precision while avoiding overflow. */ Loading Loading @@ -403,7 +403,7 @@ void bass_psfilter_fx( exp2 = sub(exp, exp2); /* exponent num - exponent denom */ /* alpha = corr / ener */ #ifdef BASOP_NOGLOB alpha = shr_sat(div_s(round_fx_sat(L_shl(Ltmp, exp)), tmp2), exp2); /*Q15 */ alpha = shr_sat(div_s(round_fx(L_shl(Ltmp, exp)), tmp2), exp2); /*Q15 */ #else alpha = shr(div_s(round_fx(L_shl(Ltmp, exp)), tmp2), exp2); /*Q15 */ #endif Loading Loading @@ -452,7 +452,7 @@ void bass_psfilter_fx( FOR (i=0; i< subfr_len; i++) { /*syn2_fx[i] = alpha*(syn_fx[i]-syn2_fx[i]); */ tmp = sub_sat(syn_fx[i],syn2_fx[i]); tmp = sub(syn_fx[i],syn2_fx[i]); #ifdef BASOP_NOGLOB syn2_fx[i] = mult_sat(alpha, shl_sat(tmp, 1)); #else Loading
lib_dec/dec_gen_voic_fx.c +2 −2 Original line number Diff line number Diff line Loading @@ -692,7 +692,7 @@ ivas_error decod_gen_voic_ivas_fx( { L_tmp_GC = L_max(gain_code_fx, L_shl(gain_preQ_fx,16)); /* Chose the maximum of gain_code or the prequantizer excitation x4 to keep some room*/ Rescale_exc(hMusicPF->dct_post_old_exc_fx, &exc_fx[i_subfr_fx], &bwe_exc_fx[i_subfr_fx * 2], hGSCDec->last_exc_dct_in_fx, Rescale_exc(hMusicPF->dct_post_old_exc_fx, &exc_fx[i_subfr_fx], (bwe_exc_fx != NULL) ? &bwe_exc_fx[i_subfr_fx * 2] : NULL, hGSCDec->last_exc_dct_in_fx, L_SUBFR, L_SUBFR * 2, L_tmp_GC, &(st_fx->Q_exc), st_fx->Q_subfr, exc2_fx, i_subfr_fx, st_fx->coder_type); } Loading