aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/aac.c
diff options
context:
space:
mode:
authorAlex Converse <alex.converse@gmail.com>2010-04-30 21:43:23 +0000
committerAlex Converse <alex.converse@gmail.com>2010-04-30 21:43:23 +0000
commitca6d3f234cd68690100714abff958a9304a095ff (patch)
tree237cbdbc53f5cea51d2c77cd4698f0dba2897e83 /libavcodec/aac.c
parentbd744c4fd03cc3e5262f0f04ad955df6575b71f2 (diff)
downloadffmpeg-ca6d3f234cd68690100714abff958a9304a095ff.tar.gz
Rewrite ff_sbr_apply in a manner more friendly to PS.
This includes merging ff_sbr_dequant into ff_sbr_apply. Originally committed as revision 22995 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/aac.c')
-rw-r--r--libavcodec/aac.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/libavcodec/aac.c b/libavcodec/aac.c
index a43d1f6367..eba0c72670 100644
--- a/libavcodec/aac.c
+++ b/libavcodec/aac.c
@@ -1892,15 +1892,12 @@ static void spectral_to_sample(AACContext *ac)
apply_channel_coupling(ac, che, type, i, BETWEEN_TNS_AND_IMDCT, apply_dependent_coupling);
if (type != TYPE_CCE || che->coup.coupling_point == AFTER_IMDCT) {
imdct_and_windowing(ac, &che->ch[0], imdct_bias);
- if (ac->m4ac.sbr > 0) {
- ff_sbr_dequant(ac, &che->sbr, type == TYPE_CPE ? TYPE_CPE : TYPE_SCE);
- ff_sbr_apply(ac, &che->sbr, 0, che->ch[0].ret, che->ch[0].ret);
- }
- }
if (type == TYPE_CPE) {
imdct_and_windowing(ac, &che->ch[1], imdct_bias);
- if (ac->m4ac.sbr > 0)
- ff_sbr_apply(ac, &che->sbr, 1, che->ch[1].ret, che->ch[1].ret);
+ }
+ if (ac->m4ac.sbr > 0) {
+ ff_sbr_apply(ac, &che->sbr, type, che->ch[0].ret, che->ch[1].ret);
+ }
}
if (type <= TYPE_CCE)
apply_channel_coupling(ac, che, type, i, AFTER_IMDCT, apply_independent_coupling);