From 6271794041abbf79098b6c01b27f1539b3a4af5e Mon Sep 17 00:00:00 2001 From: Justin Ruggles Date: Tue, 26 Apr 2011 15:30:19 -0400 Subject: [PATCH] aacdec: use a scale of 2 in the LTP MDCT rather than doubling the coefficient table values from the spec. --- libavcodec/aacdec.c | 2 +- libavcodec/aacdectab.h | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/libavcodec/aacdec.c b/libavcodec/aacdec.c index bcc277c3c0..cbaecf9e2f 100644 --- a/libavcodec/aacdec.c +++ b/libavcodec/aacdec.c @@ -593,7 +593,7 @@ static av_cold int aac_decode_init(AVCodecContext *avctx) ff_mdct_init(&ac->mdct, 11, 1, 1.0); ff_mdct_init(&ac->mdct_small, 8, 1, 1.0); - ff_mdct_init(&ac->mdct_ltp, 11, 0, 1.0); + ff_mdct_init(&ac->mdct_ltp, 11, 0, 2.0); // window initialization ff_kbd_window_init(ff_aac_kbd_long_1024, 4.0, 1024); ff_kbd_window_init(ff_aac_kbd_short_128, 6.0, 128); diff --git a/libavcodec/aacdectab.h b/libavcodec/aacdectab.h index 64c2a1c395..23a7868ab2 100644 --- a/libavcodec/aacdectab.h +++ b/libavcodec/aacdectab.h @@ -36,11 +36,11 @@ #include /* @name ltp_coef - * Table of the LTP coefficient (multiplied by 2) + * Table of the LTP coefficients */ static const float ltp_coef[8] = { - 1.141658, 1.393232, 1.626008, 1.822608, - 1.969800, 2.135788, 2.2389202, 2.739066, + 0.570829, 0.696616, 0.813004, 0.911304, + 0.984900, 1.067894, 1.194601, 1.369533, }; /* @name tns_tmp2_map