Loading .gitlab-ci.yml +3 −5 Original line number Diff line number Diff line Loading @@ -49,10 +49,10 @@ variables: FAILED_TESTCASES_LIST: "failed-testcases.txt" ERRORS_TESTCASES_LIST: "errors-testcases.txt" PYTEST_CACHE_ARTIFACT: "pytest_cache.zip" FLOAT_REF_COMMIT_FILE: "float-ref-git-sha" CUT_COMMIT_FILE: "CuT-git-sha" MERGE_TARGET_COMMIT_FILE: "merge-target-git-sha" MEASURES_FOR_REPORT: "MLD MAX_ABS_DIFF MIN_SSNR MIN_ODG" FLOAT_REF_COMMIT_FILE: "float-ref-git-sha.txt" CUT_COMMIT_FILE: "CuT-git-sha.txt" MERGE_TARGET_COMMIT_FILE: "merge-target-git-sha.txt" MANUAL_PIPELINE_TYPE: description: "Type for the manual pipeline run. Use 'pytest-compare' to run comparison test against reference float codec." value: 'default' Loading Loading @@ -400,8 +400,6 @@ stages: - BUILD_WITH_DEBUG_MODE_INFO="true" - fi - comp_args="--mld --ssnr --odg" - INV_LEVEL_SCALING=$(awk "BEGIN {print 1.0 / $LEVEL_SCALING}") - comp_args="--mld --ssnr --odg --scalefac $INV_LEVEL_SCALING" - if [ "$ENCODER_TEST" = "true" ]; then comp_args="${comp_args} --enc_stats"; fi Loading lib_com/ivas_prot_fx.h +0 −6 Original line number Diff line number Diff line Loading @@ -2730,14 +2730,8 @@ void stereo_coder_tcx_fx( Word32 *inv_spectrum_fx[CPE_CHANNELS][NB_DIV], /* i/o: inverse spectrum */ Word32 *inv_mdst_spectrum_fx[CPE_CHANNELS][NB_DIV], /* i/o: inverse MDST spectrum */ const Word16 mct_on, /* i : flag mct block (1) or stereo (0) */ #ifdef FIX_1464_NO_SINGLE_SPEC_Q Word16 mdst_spectrum_e[CPE_CHANNELS][NB_DIV], Word16 inv_spectrum_e[CPE_CHANNELS][NB_DIV], Word16 inv_mdst_spectrum_e[CPE_CHANNELS][NB_DIV] ); #else Word16 exp_spec, Word16 exp_mdst_spec ); #endif // bw_detect_fx.c Word16 set_bw_mct_fx( Loading lib_enc/ivas_mct_enc_mct_fx.c +1 −23 Original line number Diff line number Diff line Loading @@ -391,11 +391,7 @@ static void getBlockValues_fx( p_st[0] = sts[ch1]; p_st[1] = sts[ch2]; #ifdef FIX_1464_NO_SINGLE_SPEC_Q stereo_coder_tcx_fx( hBlock->hStereoMdct, p_st, hBlock->mask, p_mdst_spectrum, p_inv_spectrum, p_inv_mdst_spectrum, 1, mdst_spectrum_e, inv_spectrum_e, inv_mdst_spectrum_e ); #else stereo_coder_tcx_fx( hBlock->hStereoMdct, p_st, hBlock->mask, p_mdst_spectrum, p_inv_spectrum, p_inv_mdst_spectrum, 1, q_spec ); #endif stereo_coder_tcx_fx( hBlock->hStereoMdct, p_st, hBlock->mask, p_mdst_spectrum, p_inv_spectrum, p_inv_mdst_spectrum, 1, sub( 31, q_spec ), sub( 31, q_spec ) ); test(); test(); Loading Loading @@ -1018,11 +1014,7 @@ void mctStereoIGF_enc_fx( Word32 *p_powerSpec_fx[NB_DIV]; Word16 b, nSubframes, L_subframeTCX; #ifdef FIX_1464_NO_SINGLE_SPEC_Q Word16 p_ch[2], n, ch, ch1, ch2; #else Word16 p_ch[2], n, ch, ch1, ch2, s = 31; #endif Word16 q_pSI_ch[2]; Word16 q_pS_ch[2]; Encoder_State *p_st[NB_DIV]; Loading Loading @@ -1097,19 +1089,6 @@ void mctStereoIGF_enc_fx( IF( NE_16( hMCT->hBlockData[b]->hStereoMdct->mdct_stereo_mode[n], hMCT->hBlockData[b]->hStereoMdct->IGFStereoMode[n] ) || EQ_16( hMCT->hBlockData[b]->hStereoMdct->mdct_stereo_mode[n], SMDCT_BW_MS ) ) { #ifdef FIX_1464_NO_SINGLE_SPEC_Q Word16 exp_SI_ch[CPE_CHANNELS], exp_pS_ch[CPE_CHANNELS], exp_pSI_ch[CPE_CHANNELS]; exp_SI_ch[0] = sub( 31, q_inv_spectrum[ch1][n] ); exp_SI_ch[1] = sub( 31, q_inv_spectrum[ch2][n] ); exp_pSI_ch[0] = sub( 31, q_pSI_ch[0] ); exp_pSI_ch[1] = sub( 31, q_pSI_ch[1] ); exp_pS_ch[0] = sub( 31, q_pS_ch[0] ); exp_pS_ch[1] = sub( 31, q_pS_ch[1] ); ProcessStereoIGF_fx( hMCT->hBlockData[b]->hStereoMdct, p_st, hMCT->hBlockData[b]->mask, p_orig_spectrum_fx, q_origSpec, q_origSpec, p_powerSpec_fx, exp_pS_ch, p_powerSpecMsInv_fx, exp_pSI_ch, p_inv_spectrum_fx, exp_SI_ch, n, sp_aud_decision0[ch1], p_st[0]->total_brate, 1 ); #else Word16 exp_powerSpec_fx[CPE_CHANNELS], exp_powerSpecMsInv_fx[CPE_CHANNELS], exp_inv_spectrum_fx[CPE_CHANNELS]; FOR( ch = 0; ch < CPE_CHANNELS; ch++ ) Loading @@ -1124,7 +1103,6 @@ void mctStereoIGF_enc_fx( ProcessStereoIGF_fx( hMCT->hBlockData[b]->hStereoMdct, p_st, hMCT->hBlockData[b]->mask, p_orig_spectrum_fx, q_origSpec, q_origSpec, p_powerSpec_fx, exp_powerSpec_fx, p_powerSpecMsInv_fx, exp_powerSpecMsInv_fx, p_inv_spectrum_fx, exp_inv_spectrum_fx, n, sp_aud_decision0[ch1], p_st[0]->total_brate, 1 ); #endif } ELSE { Loading lib_enc/ivas_stereo_mdct_core_enc_fx.c +0 −11 Original line number Diff line number Diff line Loading @@ -158,12 +158,6 @@ void stereo_mdct_core_enc_fx( Word32 *p_mdst_spectrum_long_fx[CPE_CHANNELS]; Word32 mdst_spectrum_long_fx[CPE_CHANNELS][N_MAX]; Word32 *mdst_spectrum_fx[CPE_CHANNELS][NB_DIV]; #ifdef FIX_1464_NO_SINGLE_SPEC_Q /* ToDo: exchange dimensions of 3 arrays below for more efficiency */ Word16 pwrMdstMdct_e[CPE_CHANNELS][NB_DIV]; Word16 pwrMdstMdctInv_e[CPE_CHANNELS][NB_DIV]; Word16 inv_spectrum_e[CPE_CHANNELS][NB_DIV]; #else Word16 exp_powSpecMsInv[MCT_MAX_CHANNELS]; Word16 tmp_q_powSpecInv[N_MAX], *exp_powSpecInv[2]; Word64 W_tmp; Loading Loading @@ -206,7 +200,6 @@ void stereo_mdct_core_enc_fx( exp_powSpecInv[0] = tmp_q_powSpecInv; exp_powSpecInv[1] = &tmp_q_powSpecInv[N_TCX10_MAX]; #endif sts = hCPE->hCoreCoder; hStereoMdct = hCPE->hStereoMdct; Loading Loading @@ -433,7 +426,6 @@ void stereo_mdct_core_enc_fx( #ifndef FIX_1464_NO_SINGLE_SPEC_Q Word16 length, exp, shift1, shift2, norm; Word32 mdct, mdst, imdct, imdst; #endif FOR( ch = 0; ch < CPE_CHANNELS; ch++ ) { Loading @@ -457,8 +449,6 @@ void stereo_mdct_core_enc_fx( #ifdef FIX_1464_NO_SINGLE_SPEC_Q FOR( n = 0; n < nSubframes; n++ ) { Word16 shift0, shift1, shift0i, shift1i; IF( sts[ch]->hTcxEnc->tns_ms_flag[n] ) { #if 0 Loading Loading @@ -643,7 +633,6 @@ void stereo_mdct_core_enc_fx( } exp_powSpecMsInv[ch] = exp; move16(); #endif } FOR( ch = 0; ch < CPE_CHANNELS; ch++ ) Loading lib_enc/ivas_stereo_mdct_stereo_enc_fx.c +4 −33 Original line number Diff line number Diff line Loading @@ -197,14 +197,8 @@ void stereo_coder_tcx_fx( Word32 *inv_mdst_spectrum_fx[CPE_CHANNELS][NB_DIV], /* i/o: inverse MDST spectrum */ // Q( q_spec ) (same as spectrum buffer in hTcxEnc) const Word16 mct_on, /* i : flag mct block (1) or stereo (0) Q0*/ #ifdef FIX_1464_NO_SINGLE_SPEC_Q Word16 mdst_spectrum_e[CPE_CHANNELS][NB_DIV], Word16 inv_spectrum_e[CPE_CHANNELS][NB_DIV], Word16 inv_mdst_spectrum_e[CPE_CHANNELS][NB_DIV] ) #else Word16 exp_spec, Word16 exp_mdct_spec ) #endif { STEREO_MDCT_BAND_PARAMETERS *sfbConf = NULL; Word32 nrgRatio_fx[CPE_CHANNELS]; Loading Loading @@ -288,7 +282,6 @@ void stereo_coder_tcx_fx( /* This operation is resulting in some high MLDs in fixed point. */ v_multc_fixed_16( sts[0]->hTcxEnc->spectrum_fx[k], extract_l( L_shr( nrgRatio_fx[k], 16 - nrgRatio_e[k] ) ), sts[0]->hTcxEnc->spectrum_fx[k], L_frameTCX ); /* exp: exp_spec */ v_multc_fixed_16( mdst_spectrum_fx[0][k], extract_l( L_shr( nrgRatio_fx[k], 16 - nrgRatio_e[k] ) ), mdst_spectrum_fx[0][k], L_frameTCX ); /* exp: exp_mdct_spec */ #endif } } } Loading Loading @@ -397,12 +390,7 @@ void stereo_coder_tcx_fx( move16(); const Word16 sfbWidth = sub( endLine, startLine ); #ifdef FIX_1464_NO_SINGLE_SPEC_Q nrgRatio_e[0] = sts[0]->hTcxEnc->spectrum_e[k]; nrgRatio_e[1] = sts[1]->hTcxEnc->spectrum_e[k]; #else nrgRatio_e[0] = nrgRatio_e[1] = exp_spec; #endif move16(); move16(); Loading @@ -416,20 +404,12 @@ void stereo_coder_tcx_fx( { Word32 tmp_fx; Word16 tmp_e; #ifdef FIX_1464_NO_SINGLE_SPEC_Q tmp_e = mdst_spectrum_e[0][k]; move16(); #else tmp_e = exp_mdct_spec; #endif move16(); tmp_fx = sum2_32_fx( &mdst_spectrum_fx[0][k][startLine], sfbWidth, &tmp_e ); /* Q31-tmp_e */ nrgRatio_fx[0] = BASOP_Util_Add_Mant32Exp( nrgRatio_fx[0], nrgRatio_e[0], tmp_fx, tmp_e, &nrgRatio_e[0] ); /* Q31-nrgRatio_e[0] */ #ifdef FIX_1464_NO_SINGLE_SPEC_Q tmp_e = mdst_spectrum_e[1][k]; move16(); #else tmp_e = exp_mdct_spec; #endif move16(); tmp_fx = sum2_32_fx( &mdst_spectrum_fx[1][k][startLine], sfbWidth, &tmp_e ); /* Q31-tmp_e */ nrgRatio_fx[1] = BASOP_Util_Add_Mant32Exp( nrgRatio_fx[1], nrgRatio_e[1], tmp_fx, tmp_e, &nrgRatio_e[1] ); /* Q31-nrgRatio_e[1] */ } Loading Loading @@ -484,17 +464,13 @@ void stereo_coder_tcx_fx( v_multc_fixed( &sts[0]->hTcxEnc->spectrum_fx[k][startLine], nrgRatio_fx[0], &sts[0]->hTcxEnc->spectrum_fx[k][startLine], sfbWidth ); /* exp: exp_spec+1 */ v_multc_fixed( &mdst_spectrum_fx[0][k][startLine], nrgRatio_fx[0], &mdst_spectrum_fx[0][k][startLine], sfbWidth ); /* exp: exp_mdct_spec+1 */ #ifndef FIX_1464_NO_SINGLE_SPEC_Q scale_sig32( &sts[0]->hTcxEnc->spectrum_fx[k][startLine], sfbWidth, Q1 ); // exp: exp_spec scale_sig32( &mdst_spectrum_fx[0][k][startLine], sfbWidth, Q1 ); // exp: exp_mdct_spec #endif v_multc_fixed( &sts[1]->hTcxEnc->spectrum_fx[k][startLine], nrgRatio_fx[1], &sts[1]->hTcxEnc->spectrum_fx[k][startLine], sfbWidth ); /* exp: exp_spec+1 */ v_multc_fixed( &mdst_spectrum_fx[1][k][startLine], nrgRatio_fx[1], &mdst_spectrum_fx[1][k][startLine], sfbWidth ); /* exp: exp_mdct_spec+1 */ #ifndef FIX_1464_NO_SINGLE_SPEC_Q scale_sig32( &sts[1]->hTcxEnc->spectrum_fx[k][startLine], sfbWidth, Q1 ); // exp: exp_spec scale_sig32( &mdst_spectrum_fx[1][k][startLine], sfbWidth, Q1 ); // exp: exp_mdct_spec #endif } #ifdef FIX_1464_NO_SINGLE_SPEC_Q ELSE Loading Loading @@ -547,16 +523,11 @@ void stereo_coder_tcx_fx( nAvailBitsMS[k] = idiv1616( nAvailBitsMS[k], nSubframes ); /* Q0 */ move16(); #ifdef FIX_1464_NO_SINGLE_SPEC_Q MsStereoDecision_fx( sfbConf, sts[0]->hTcxEnc->spectrum_fx[k], sts[1]->hTcxEnc->spectrum_fx[k], inv_spectrum_fx[0][k], inv_spectrum_fx[1][k], sts[0]->hTcxEnc->spectrum_e[k], sts[1]->hTcxEnc->spectrum_e[k], &inv_spectrum_e[0][k], &inv_spectrum_e[1][k], &hStereoMdct->mdct_stereo_mode[k], &ms_mask[k][0], nAvailBitsMS[k] ); #else MsStereoDecision_fx( sfbConf, sts[0]->hTcxEnc->spectrum_fx[k], sts[1]->hTcxEnc->spectrum_fx[k], inv_spectrum_fx[0][k], inv_spectrum_fx[1][k], sub( Q31, exp_spec ), &hStereoMdct->mdct_stereo_mode[k], &ms_mask[k][0], nAvailBitsMS[k] ); #endif IF( sts[0]->igf ) { #ifdef FIX_1464_NO_SINGLE_SPEC_Q IGFEncStereoEncoder_fx( sfbConf, sts[0]->hIGFEnc, sts[0]->hTcxEnc->spectrum_fx[k], sts[1]->hTcxEnc->spectrum_fx[k], sts[0]->hTcxEnc->spectrum_e[k], sts[1]->hTcxEnc->spectrum_e[k], &ms_mask[k][0], IGFEncStereoEncoder_fx( sfbConf, sts[0]->hIGFEnc, sts[0]->hTcxEnc->spectrum_fx[k], sts[1]->hTcxEnc->spectrum_fx[k], sub( Q31, exp_spec ), &ms_mask[k][0], &hStereoMdct->IGFStereoMode[k], hStereoMdct->mdct_stereo_mode[k], (Word16) EQ_16( sts[0]->core, TCX_20_CORE ), (Word16) EQ_16( sts[0]->last_core, ACELP_CORE ) ); #else IGFEncStereoEncoder_fx( sfbConf, sts[0]->hIGFEnc, sts[0]->hTcxEnc->spectrum_fx[k], sts[1]->hTcxEnc->spectrum_fx[k], sub( Q31, exp_spec ), &ms_mask[k][0], Loading Loading
.gitlab-ci.yml +3 −5 Original line number Diff line number Diff line Loading @@ -49,10 +49,10 @@ variables: FAILED_TESTCASES_LIST: "failed-testcases.txt" ERRORS_TESTCASES_LIST: "errors-testcases.txt" PYTEST_CACHE_ARTIFACT: "pytest_cache.zip" FLOAT_REF_COMMIT_FILE: "float-ref-git-sha" CUT_COMMIT_FILE: "CuT-git-sha" MERGE_TARGET_COMMIT_FILE: "merge-target-git-sha" MEASURES_FOR_REPORT: "MLD MAX_ABS_DIFF MIN_SSNR MIN_ODG" FLOAT_REF_COMMIT_FILE: "float-ref-git-sha.txt" CUT_COMMIT_FILE: "CuT-git-sha.txt" MERGE_TARGET_COMMIT_FILE: "merge-target-git-sha.txt" MANUAL_PIPELINE_TYPE: description: "Type for the manual pipeline run. Use 'pytest-compare' to run comparison test against reference float codec." value: 'default' Loading Loading @@ -400,8 +400,6 @@ stages: - BUILD_WITH_DEBUG_MODE_INFO="true" - fi - comp_args="--mld --ssnr --odg" - INV_LEVEL_SCALING=$(awk "BEGIN {print 1.0 / $LEVEL_SCALING}") - comp_args="--mld --ssnr --odg --scalefac $INV_LEVEL_SCALING" - if [ "$ENCODER_TEST" = "true" ]; then comp_args="${comp_args} --enc_stats"; fi Loading
lib_com/ivas_prot_fx.h +0 −6 Original line number Diff line number Diff line Loading @@ -2730,14 +2730,8 @@ void stereo_coder_tcx_fx( Word32 *inv_spectrum_fx[CPE_CHANNELS][NB_DIV], /* i/o: inverse spectrum */ Word32 *inv_mdst_spectrum_fx[CPE_CHANNELS][NB_DIV], /* i/o: inverse MDST spectrum */ const Word16 mct_on, /* i : flag mct block (1) or stereo (0) */ #ifdef FIX_1464_NO_SINGLE_SPEC_Q Word16 mdst_spectrum_e[CPE_CHANNELS][NB_DIV], Word16 inv_spectrum_e[CPE_CHANNELS][NB_DIV], Word16 inv_mdst_spectrum_e[CPE_CHANNELS][NB_DIV] ); #else Word16 exp_spec, Word16 exp_mdst_spec ); #endif // bw_detect_fx.c Word16 set_bw_mct_fx( Loading
lib_enc/ivas_mct_enc_mct_fx.c +1 −23 Original line number Diff line number Diff line Loading @@ -391,11 +391,7 @@ static void getBlockValues_fx( p_st[0] = sts[ch1]; p_st[1] = sts[ch2]; #ifdef FIX_1464_NO_SINGLE_SPEC_Q stereo_coder_tcx_fx( hBlock->hStereoMdct, p_st, hBlock->mask, p_mdst_spectrum, p_inv_spectrum, p_inv_mdst_spectrum, 1, mdst_spectrum_e, inv_spectrum_e, inv_mdst_spectrum_e ); #else stereo_coder_tcx_fx( hBlock->hStereoMdct, p_st, hBlock->mask, p_mdst_spectrum, p_inv_spectrum, p_inv_mdst_spectrum, 1, q_spec ); #endif stereo_coder_tcx_fx( hBlock->hStereoMdct, p_st, hBlock->mask, p_mdst_spectrum, p_inv_spectrum, p_inv_mdst_spectrum, 1, sub( 31, q_spec ), sub( 31, q_spec ) ); test(); test(); Loading Loading @@ -1018,11 +1014,7 @@ void mctStereoIGF_enc_fx( Word32 *p_powerSpec_fx[NB_DIV]; Word16 b, nSubframes, L_subframeTCX; #ifdef FIX_1464_NO_SINGLE_SPEC_Q Word16 p_ch[2], n, ch, ch1, ch2; #else Word16 p_ch[2], n, ch, ch1, ch2, s = 31; #endif Word16 q_pSI_ch[2]; Word16 q_pS_ch[2]; Encoder_State *p_st[NB_DIV]; Loading Loading @@ -1097,19 +1089,6 @@ void mctStereoIGF_enc_fx( IF( NE_16( hMCT->hBlockData[b]->hStereoMdct->mdct_stereo_mode[n], hMCT->hBlockData[b]->hStereoMdct->IGFStereoMode[n] ) || EQ_16( hMCT->hBlockData[b]->hStereoMdct->mdct_stereo_mode[n], SMDCT_BW_MS ) ) { #ifdef FIX_1464_NO_SINGLE_SPEC_Q Word16 exp_SI_ch[CPE_CHANNELS], exp_pS_ch[CPE_CHANNELS], exp_pSI_ch[CPE_CHANNELS]; exp_SI_ch[0] = sub( 31, q_inv_spectrum[ch1][n] ); exp_SI_ch[1] = sub( 31, q_inv_spectrum[ch2][n] ); exp_pSI_ch[0] = sub( 31, q_pSI_ch[0] ); exp_pSI_ch[1] = sub( 31, q_pSI_ch[1] ); exp_pS_ch[0] = sub( 31, q_pS_ch[0] ); exp_pS_ch[1] = sub( 31, q_pS_ch[1] ); ProcessStereoIGF_fx( hMCT->hBlockData[b]->hStereoMdct, p_st, hMCT->hBlockData[b]->mask, p_orig_spectrum_fx, q_origSpec, q_origSpec, p_powerSpec_fx, exp_pS_ch, p_powerSpecMsInv_fx, exp_pSI_ch, p_inv_spectrum_fx, exp_SI_ch, n, sp_aud_decision0[ch1], p_st[0]->total_brate, 1 ); #else Word16 exp_powerSpec_fx[CPE_CHANNELS], exp_powerSpecMsInv_fx[CPE_CHANNELS], exp_inv_spectrum_fx[CPE_CHANNELS]; FOR( ch = 0; ch < CPE_CHANNELS; ch++ ) Loading @@ -1124,7 +1103,6 @@ void mctStereoIGF_enc_fx( ProcessStereoIGF_fx( hMCT->hBlockData[b]->hStereoMdct, p_st, hMCT->hBlockData[b]->mask, p_orig_spectrum_fx, q_origSpec, q_origSpec, p_powerSpec_fx, exp_powerSpec_fx, p_powerSpecMsInv_fx, exp_powerSpecMsInv_fx, p_inv_spectrum_fx, exp_inv_spectrum_fx, n, sp_aud_decision0[ch1], p_st[0]->total_brate, 1 ); #endif } ELSE { Loading
lib_enc/ivas_stereo_mdct_core_enc_fx.c +0 −11 Original line number Diff line number Diff line Loading @@ -158,12 +158,6 @@ void stereo_mdct_core_enc_fx( Word32 *p_mdst_spectrum_long_fx[CPE_CHANNELS]; Word32 mdst_spectrum_long_fx[CPE_CHANNELS][N_MAX]; Word32 *mdst_spectrum_fx[CPE_CHANNELS][NB_DIV]; #ifdef FIX_1464_NO_SINGLE_SPEC_Q /* ToDo: exchange dimensions of 3 arrays below for more efficiency */ Word16 pwrMdstMdct_e[CPE_CHANNELS][NB_DIV]; Word16 pwrMdstMdctInv_e[CPE_CHANNELS][NB_DIV]; Word16 inv_spectrum_e[CPE_CHANNELS][NB_DIV]; #else Word16 exp_powSpecMsInv[MCT_MAX_CHANNELS]; Word16 tmp_q_powSpecInv[N_MAX], *exp_powSpecInv[2]; Word64 W_tmp; Loading Loading @@ -206,7 +200,6 @@ void stereo_mdct_core_enc_fx( exp_powSpecInv[0] = tmp_q_powSpecInv; exp_powSpecInv[1] = &tmp_q_powSpecInv[N_TCX10_MAX]; #endif sts = hCPE->hCoreCoder; hStereoMdct = hCPE->hStereoMdct; Loading Loading @@ -433,7 +426,6 @@ void stereo_mdct_core_enc_fx( #ifndef FIX_1464_NO_SINGLE_SPEC_Q Word16 length, exp, shift1, shift2, norm; Word32 mdct, mdst, imdct, imdst; #endif FOR( ch = 0; ch < CPE_CHANNELS; ch++ ) { Loading @@ -457,8 +449,6 @@ void stereo_mdct_core_enc_fx( #ifdef FIX_1464_NO_SINGLE_SPEC_Q FOR( n = 0; n < nSubframes; n++ ) { Word16 shift0, shift1, shift0i, shift1i; IF( sts[ch]->hTcxEnc->tns_ms_flag[n] ) { #if 0 Loading Loading @@ -643,7 +633,6 @@ void stereo_mdct_core_enc_fx( } exp_powSpecMsInv[ch] = exp; move16(); #endif } FOR( ch = 0; ch < CPE_CHANNELS; ch++ ) Loading
lib_enc/ivas_stereo_mdct_stereo_enc_fx.c +4 −33 Original line number Diff line number Diff line Loading @@ -197,14 +197,8 @@ void stereo_coder_tcx_fx( Word32 *inv_mdst_spectrum_fx[CPE_CHANNELS][NB_DIV], /* i/o: inverse MDST spectrum */ // Q( q_spec ) (same as spectrum buffer in hTcxEnc) const Word16 mct_on, /* i : flag mct block (1) or stereo (0) Q0*/ #ifdef FIX_1464_NO_SINGLE_SPEC_Q Word16 mdst_spectrum_e[CPE_CHANNELS][NB_DIV], Word16 inv_spectrum_e[CPE_CHANNELS][NB_DIV], Word16 inv_mdst_spectrum_e[CPE_CHANNELS][NB_DIV] ) #else Word16 exp_spec, Word16 exp_mdct_spec ) #endif { STEREO_MDCT_BAND_PARAMETERS *sfbConf = NULL; Word32 nrgRatio_fx[CPE_CHANNELS]; Loading Loading @@ -288,7 +282,6 @@ void stereo_coder_tcx_fx( /* This operation is resulting in some high MLDs in fixed point. */ v_multc_fixed_16( sts[0]->hTcxEnc->spectrum_fx[k], extract_l( L_shr( nrgRatio_fx[k], 16 - nrgRatio_e[k] ) ), sts[0]->hTcxEnc->spectrum_fx[k], L_frameTCX ); /* exp: exp_spec */ v_multc_fixed_16( mdst_spectrum_fx[0][k], extract_l( L_shr( nrgRatio_fx[k], 16 - nrgRatio_e[k] ) ), mdst_spectrum_fx[0][k], L_frameTCX ); /* exp: exp_mdct_spec */ #endif } } } Loading Loading @@ -397,12 +390,7 @@ void stereo_coder_tcx_fx( move16(); const Word16 sfbWidth = sub( endLine, startLine ); #ifdef FIX_1464_NO_SINGLE_SPEC_Q nrgRatio_e[0] = sts[0]->hTcxEnc->spectrum_e[k]; nrgRatio_e[1] = sts[1]->hTcxEnc->spectrum_e[k]; #else nrgRatio_e[0] = nrgRatio_e[1] = exp_spec; #endif move16(); move16(); Loading @@ -416,20 +404,12 @@ void stereo_coder_tcx_fx( { Word32 tmp_fx; Word16 tmp_e; #ifdef FIX_1464_NO_SINGLE_SPEC_Q tmp_e = mdst_spectrum_e[0][k]; move16(); #else tmp_e = exp_mdct_spec; #endif move16(); tmp_fx = sum2_32_fx( &mdst_spectrum_fx[0][k][startLine], sfbWidth, &tmp_e ); /* Q31-tmp_e */ nrgRatio_fx[0] = BASOP_Util_Add_Mant32Exp( nrgRatio_fx[0], nrgRatio_e[0], tmp_fx, tmp_e, &nrgRatio_e[0] ); /* Q31-nrgRatio_e[0] */ #ifdef FIX_1464_NO_SINGLE_SPEC_Q tmp_e = mdst_spectrum_e[1][k]; move16(); #else tmp_e = exp_mdct_spec; #endif move16(); tmp_fx = sum2_32_fx( &mdst_spectrum_fx[1][k][startLine], sfbWidth, &tmp_e ); /* Q31-tmp_e */ nrgRatio_fx[1] = BASOP_Util_Add_Mant32Exp( nrgRatio_fx[1], nrgRatio_e[1], tmp_fx, tmp_e, &nrgRatio_e[1] ); /* Q31-nrgRatio_e[1] */ } Loading Loading @@ -484,17 +464,13 @@ void stereo_coder_tcx_fx( v_multc_fixed( &sts[0]->hTcxEnc->spectrum_fx[k][startLine], nrgRatio_fx[0], &sts[0]->hTcxEnc->spectrum_fx[k][startLine], sfbWidth ); /* exp: exp_spec+1 */ v_multc_fixed( &mdst_spectrum_fx[0][k][startLine], nrgRatio_fx[0], &mdst_spectrum_fx[0][k][startLine], sfbWidth ); /* exp: exp_mdct_spec+1 */ #ifndef FIX_1464_NO_SINGLE_SPEC_Q scale_sig32( &sts[0]->hTcxEnc->spectrum_fx[k][startLine], sfbWidth, Q1 ); // exp: exp_spec scale_sig32( &mdst_spectrum_fx[0][k][startLine], sfbWidth, Q1 ); // exp: exp_mdct_spec #endif v_multc_fixed( &sts[1]->hTcxEnc->spectrum_fx[k][startLine], nrgRatio_fx[1], &sts[1]->hTcxEnc->spectrum_fx[k][startLine], sfbWidth ); /* exp: exp_spec+1 */ v_multc_fixed( &mdst_spectrum_fx[1][k][startLine], nrgRatio_fx[1], &mdst_spectrum_fx[1][k][startLine], sfbWidth ); /* exp: exp_mdct_spec+1 */ #ifndef FIX_1464_NO_SINGLE_SPEC_Q scale_sig32( &sts[1]->hTcxEnc->spectrum_fx[k][startLine], sfbWidth, Q1 ); // exp: exp_spec scale_sig32( &mdst_spectrum_fx[1][k][startLine], sfbWidth, Q1 ); // exp: exp_mdct_spec #endif } #ifdef FIX_1464_NO_SINGLE_SPEC_Q ELSE Loading Loading @@ -547,16 +523,11 @@ void stereo_coder_tcx_fx( nAvailBitsMS[k] = idiv1616( nAvailBitsMS[k], nSubframes ); /* Q0 */ move16(); #ifdef FIX_1464_NO_SINGLE_SPEC_Q MsStereoDecision_fx( sfbConf, sts[0]->hTcxEnc->spectrum_fx[k], sts[1]->hTcxEnc->spectrum_fx[k], inv_spectrum_fx[0][k], inv_spectrum_fx[1][k], sts[0]->hTcxEnc->spectrum_e[k], sts[1]->hTcxEnc->spectrum_e[k], &inv_spectrum_e[0][k], &inv_spectrum_e[1][k], &hStereoMdct->mdct_stereo_mode[k], &ms_mask[k][0], nAvailBitsMS[k] ); #else MsStereoDecision_fx( sfbConf, sts[0]->hTcxEnc->spectrum_fx[k], sts[1]->hTcxEnc->spectrum_fx[k], inv_spectrum_fx[0][k], inv_spectrum_fx[1][k], sub( Q31, exp_spec ), &hStereoMdct->mdct_stereo_mode[k], &ms_mask[k][0], nAvailBitsMS[k] ); #endif IF( sts[0]->igf ) { #ifdef FIX_1464_NO_SINGLE_SPEC_Q IGFEncStereoEncoder_fx( sfbConf, sts[0]->hIGFEnc, sts[0]->hTcxEnc->spectrum_fx[k], sts[1]->hTcxEnc->spectrum_fx[k], sts[0]->hTcxEnc->spectrum_e[k], sts[1]->hTcxEnc->spectrum_e[k], &ms_mask[k][0], IGFEncStereoEncoder_fx( sfbConf, sts[0]->hIGFEnc, sts[0]->hTcxEnc->spectrum_fx[k], sts[1]->hTcxEnc->spectrum_fx[k], sub( Q31, exp_spec ), &ms_mask[k][0], &hStereoMdct->IGFStereoMode[k], hStereoMdct->mdct_stereo_mode[k], (Word16) EQ_16( sts[0]->core, TCX_20_CORE ), (Word16) EQ_16( sts[0]->last_core, ACELP_CORE ) ); #else IGFEncStereoEncoder_fx( sfbConf, sts[0]->hIGFEnc, sts[0]->hTcxEnc->spectrum_fx[k], sts[1]->hTcxEnc->spectrum_fx[k], sub( Q31, exp_spec ), &ms_mask[k][0], Loading