summaryrefslogtreecommitdiff
path: root/libavcodec/aactab.c
diff options
context:
space:
mode:
authorAndreas Rheinhardt <andreas.rheinhardt@gmail.com>2020-11-22 23:33:03 +0100
committerAndreas Rheinhardt <andreas.rheinhardt@gmail.com>2020-12-08 17:51:48 +0100
commit86b8c25455d8dfa752e1f2000c775e547b9fa433 (patch)
tree983817846c40574865fc5f7608809692f178d9f5 /libavcodec/aactab.c
parentfc5d22abe40e0ab5b603b69752288565c92de670 (diff)
avcodec/aac: Share common init code of float decoder and encoder
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Diffstat (limited to 'libavcodec/aactab.c')
-rw-r--r--libavcodec/aactab.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/libavcodec/aactab.c b/libavcodec/aactab.c
index e886642e66..b9d1336d97 100644
--- a/libavcodec/aactab.c
+++ b/libavcodec/aactab.c
@@ -27,6 +27,7 @@
* @author Maxim Gavrilov ( maxim.gavrilov gmail com )
*/
+#include "config.h"
#include "libavutil/mem.h"
#include "libavutil/thread.h"
#include "aac.h"
@@ -37,9 +38,22 @@
float ff_aac_pow2sf_tab[428];
float ff_aac_pow34sf_tab[428];
+#if CONFIG_AAC_ENCODER || CONFIG_AAC_DECODER
+#include "kbdwin.h"
+#include "sinewin.h"
+
DECLARE_ALIGNED(32, float, ff_aac_kbd_long_1024)[1024];
DECLARE_ALIGNED(32, float, ff_aac_kbd_short_128)[128];
+av_cold void ff_aac_float_common_init(void)
+{
+ ff_kbd_window_init(ff_aac_kbd_long_1024, 4.0, 1024);
+ ff_kbd_window_init(ff_aac_kbd_short_128, 6.0, 128);
+ ff_init_ff_sine_windows(10);
+ ff_init_ff_sine_windows(7);
+}
+#endif
+
const uint8_t ff_aac_num_swb_1024[] = {
41, 41, 47, 49, 49, 51, 47, 47, 43, 43, 43, 40, 40
};