diff --git a/lib_dec/TonalComponentDetection_fx.c b/lib_dec/TonalComponentDetection_fx.c index dab3cd3598c9dd385b2c2af5d16ef7c82b27486a..21d0442a5e849808fb30ae36699b413ea3b91348 100644 --- a/lib_dec/TonalComponentDetection_fx.c +++ b/lib_dec/TonalComponentDetection_fx.c @@ -105,13 +105,13 @@ void ivas_DetectTonalComponents_fx( // till nSamplesCore different Q and nSamples - nSamplesCore in different Q Scale_sig32( pScaledMdctSpectrum + nSamplesCore, sub( nSamples, nSamplesCore ), sub( lastMDCTSpectrum_exp, tmp_e ) ); /*q_pScaledMdctSpectrum+lastMDCTSpectrum_exp-tmp_e*/ lastMDCTSpect_exp = sub( 31, q_pScaledMdctSpectrum ); - } - FOR( Word16 i = nSamplesCore; i < nSamples; ++i ) - { - Word64 tmp = W_mult_32_32( pScaledMdctSpectrum[i], sns_int_scf_fx[nBands - 1] ); /*q_pScaledMdctSpectrum+16+1*/ - pScaledMdctSpectrum[i] = W_extract_h( W_shl( tmp, Q15 ) ); /*q_pScaledMdctSpectrum*/ - move32(); + FOR( Word16 i = nSamplesCore; i < nSamples; ++i ) + { + Word64 tmp = W_mult_32_32( pScaledMdctSpectrum[i], sns_int_scf_fx[nBands - 1] ); /*q_pScaledMdctSpectrum+16+1*/ + pScaledMdctSpectrum[i] = W_extract_h( W_shl( tmp, Q15 ) ); /*q_pScaledMdctSpectrum*/ + move32(); + } } /* Guard bit */ diff --git a/lib_dec/tonalMDCTconcealment_fx.c b/lib_dec/tonalMDCTconcealment_fx.c index a94f65309f3cfe35b03183e35948504e27173ed7..0d967abe8b2cd4a413f7bdbacc2a08c9b5a855eb 100644 --- a/lib_dec/tonalMDCTconcealment_fx.c +++ b/lib_dec/tonalMDCTconcealment_fx.c @@ -811,7 +811,7 @@ static void ivas_CalcPowerSpecAndDetectTonalComponents_fx( hTonalMDCTConc->lastPitchLag, pitchLag, hTonalMDCTConc->lastBlockData.spectralData, - add( hTonalMDCTConc->lastBlockData.spectralData_exp, hTonalMDCTConc->lastBlockData.gain_tcx_exp ), + hTonalMDCTConc->lastBlockData.spectralData_exp, hTonalMDCTConc->lastBlockData.scaleFactors, hTonalMDCTConc->lastBlockData.scaleFactors_exp, hTonalMDCTConc->lastBlockData.scaleFactors_max_e,