aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec
diff options
context:
space:
mode:
authorRostislav Pehlivanov <atomnuker@gmail.com>2015-08-29 06:07:12 +0100
committerRostislav Pehlivanov <atomnuker@gmail.com>2015-08-29 06:07:12 +0100
commitf55cc579115e4bcfe26eb05ecaa1c823343e9e1e (patch)
treec2bc04b477c2aa405f3f832e036d4e0f1dee2469 /libavcodec
parent91f1115a0e027074c90bac6e57c2d0f4fe9efe8c (diff)
downloadffmpeg-f55cc579115e4bcfe26eb05ecaa1c823343e9e1e.tar.gz
aac: move the TNS tables from aacdectab to the shared aactab
This commit simply moves the TNS tables to a more appropriate aactab.h since then they can be accessed by both the decoder and encoder. The encoder _shouldn't_ normally need the tables since the specs describe a specific quantization process, but the exact reason for this can be seen in the TNS commit following. Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
Diffstat (limited to 'libavcodec')
-rw-r--r--libavcodec/aacdectab.h35
-rw-r--r--libavcodec/aactab.h35
2 files changed, 35 insertions, 35 deletions
diff --git a/libavcodec/aacdectab.h b/libavcodec/aacdectab.h
index 62c7f8742d..5c89a93d5d 100644
--- a/libavcodec/aacdectab.h
+++ b/libavcodec/aacdectab.h
@@ -43,41 +43,6 @@ static const INTFLOAT ltp_coef[8] = {
Q30(0.984900f), Q30(1.067894f), Q30(1.194601f), Q30(1.369533f),
};
-/* @name tns_tmp2_map
- * Tables of the tmp2[] arrays of LPC coefficients used for TNS.
- * The suffix _M_N[] indicate the values of coef_compress and coef_res
- * respectively.
- * @{
- */
-static const INTFLOAT tns_tmp2_map_1_3[4] = {
- Q31(0.00000000f), Q31(-0.43388373f), Q31(0.64278758f), Q31(0.34202015f),
-};
-
-static const INTFLOAT tns_tmp2_map_0_3[8] = {
- Q31(0.00000000f), Q31(-0.43388373f), Q31(-0.78183150f), Q31(-0.97492790f),
- Q31(0.98480773f), Q31( 0.86602539f), Q31( 0.64278758f), Q31( 0.34202015f),
-};
-
-static const INTFLOAT tns_tmp2_map_1_4[8] = {
- Q31(0.00000000f), Q31(-0.20791170f), Q31(-0.40673664f), Q31(-0.58778524f),
- Q31(0.67369562f), Q31( 0.52643216f), Q31( 0.36124167f), Q31( 0.18374951f),
-};
-
-static const INTFLOAT tns_tmp2_map_0_4[16] = {
- Q31( 0.00000000f), Q31(-0.20791170f), Q31(-0.40673664f), Q31(-0.58778524f),
- Q31(-0.74314481f), Q31(-0.86602539f), Q31(-0.95105654f), Q31(-0.99452192f),
- Q31( 0.99573416f), Q31( 0.96182561f), Q31( 0.89516330f), Q31( 0.79801720f),
- Q31( 0.67369562f), Q31( 0.52643216f), Q31( 0.36124167f), Q31( 0.18374951f),
-};
-
-static const INTFLOAT * const tns_tmp2_map[4] = {
- tns_tmp2_map_0_3,
- tns_tmp2_map_0_4,
- tns_tmp2_map_1_3,
- tns_tmp2_map_1_4
-};
-// @}
-
static const int8_t tags_per_config[16] = { 0, 1, 1, 2, 3, 3, 4, 5, 0, 0, 0, 4, 5, 0, 5, 0 };
static const uint8_t aac_channel_layout_map[16][5][3] = {
diff --git a/libavcodec/aactab.h b/libavcodec/aactab.h
index c115b05d65..9f333801e9 100644
--- a/libavcodec/aactab.h
+++ b/libavcodec/aactab.h
@@ -41,6 +41,41 @@
* encoder.
*/
+/* @name tns_tmp2_map
+ * Tables of the tmp2[] arrays of LPC coefficients used for TNS.
+ * The suffix _M_N[] indicate the values of coef_compress and coef_res
+ * respectively.
+ * @{
+ */
+static const INTFLOAT tns_tmp2_map_1_3[4] = {
+ Q31(0.00000000f), Q31(-0.43388373f), Q31(0.64278758f), Q31(0.34202015f),
+};
+
+static const INTFLOAT tns_tmp2_map_0_3[8] = {
+ Q31(0.00000000f), Q31(-0.43388373f), Q31(-0.78183150f), Q31(-0.97492790f),
+ Q31(0.98480773f), Q31( 0.86602539f), Q31( 0.64278758f), Q31( 0.34202015f),
+};
+
+static const INTFLOAT tns_tmp2_map_1_4[8] = {
+ Q31(0.00000000f), Q31(-0.20791170f), Q31(-0.40673664f), Q31(-0.58778524f),
+ Q31(0.67369562f), Q31( 0.52643216f), Q31( 0.36124167f), Q31( 0.18374951f),
+};
+
+static const INTFLOAT tns_tmp2_map_0_4[16] = {
+ Q31( 0.00000000f), Q31(-0.20791170f), Q31(-0.40673664f), Q31(-0.58778524f),
+ Q31(-0.74314481f), Q31(-0.86602539f), Q31(-0.95105654f), Q31(-0.99452192f),
+ Q31( 0.99573416f), Q31( 0.96182561f), Q31( 0.89516330f), Q31( 0.79801720f),
+ Q31( 0.67369562f), Q31( 0.52643216f), Q31( 0.36124167f), Q31( 0.18374951f),
+};
+
+static const INTFLOAT * const tns_tmp2_map[4] = {
+ tns_tmp2_map_0_3,
+ tns_tmp2_map_0_4,
+ tns_tmp2_map_1_3,
+ tns_tmp2_map_1_4
+};
+// @}
+
/* @name window coefficients
* @{
*/