diff options
author | android-build-team Robot <android-build-team-robot@google.com> | 2020-01-18 04:29:58 +0000 |
---|---|---|
committer | android-build-team Robot <android-build-team-robot@google.com> | 2020-01-18 04:29:58 +0000 |
commit | 7d1449b89a620a476a47ba3edf140dc9c66115b1 (patch) | |
tree | b3e70f7d8522d66bf0720b4111d9debcbfdd6e7c /libSBRdec/src | |
parent | 2dc3e5c1f26f578d4c09590cf3f1e01ec8c68105 (diff) | |
parent | cee316ab3ebde92047b5e76d15c00768b92cb890 (diff) | |
download | fdk-aac-7d1449b89a620a476a47ba3edf140dc9c66115b1.tar.gz fdk-aac-7d1449b89a620a476a47ba3edf140dc9c66115b1.tar.bz2 fdk-aac-7d1449b89a620a476a47ba3edf140dc9c66115b1.zip |
Snap for 6145313 from cee316ab3ebde92047b5e76d15c00768b92cb890 to rvc-release
Change-Id: I642e8bbffa03f9c9e718eb115125c1e0fa852556
Diffstat (limited to 'libSBRdec/src')
-rw-r--r-- | libSBRdec/src/env_calc.cpp | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/libSBRdec/src/env_calc.cpp b/libSBRdec/src/env_calc.cpp index 81f03f3..0b2f651 100644 --- a/libSBRdec/src/env_calc.cpp +++ b/libSBRdec/src/env_calc.cpp @@ -702,20 +702,11 @@ static void apply_inter_tes(FIXP_DBL **qmfReal, FIXP_DBL **qmfImag, gain_sf[i] += gamma_sf + 1; /* +1 because of fMultDiv2() */ /* set gain to at least 0.2f */ - FIXP_DBL point_two = FL2FXCONST_DBL(0.8f); /* scaled up by 2 */ - int point_two_sf = -2; - - FIXP_DBL tmp = gain[i]; - if (point_two_sf < gain_sf[i]) { - point_two >>= gain_sf[i] - point_two_sf; - } else { - tmp >>= point_two_sf - gain_sf[i]; - } - /* limit and calculate gain[i]^2 too */ FIXP_DBL gain_pow2; int gain_pow2_sf; - if (tmp < point_two) { + + if (fIsLessThan(gain[i], gain_sf[i], FL2FXCONST_DBL(0.2f), 0)) { gain[i] = FL2FXCONST_DBL(0.8f); gain_sf[i] = -2; gain_pow2 = FL2FXCONST_DBL(0.64f); |