aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/dcadata.h
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2015-02-14 22:40:35 +0100
committerMichael Niedermayer <michaelni@gmx.at>2015-02-14 22:40:35 +0100
commitd2223ec2bd36aae6a48c90bec3ebe4d0dc2eb421 (patch)
treea622de19247e24df3ecf9147bd0070733c2d258b /libavcodec/dcadata.h
parent6c44dd6c6ee60aaa706cb4b58db79a8857cda648 (diff)
parent2a9c6fae927964b5dd0b5d3d9292f5621bd21664 (diff)
downloadffmpeg-d2223ec2bd36aae6a48c90bec3ebe4d0dc2eb421.tar.gz
Merge commit '2a9c6fae927964b5dd0b5d3d9292f5621bd21664'
* commit '2a9c6fae927964b5dd0b5d3d9292f5621bd21664': dca: Move all tables into dcadata.h Conflicts: libavcodec/dcadec.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/dcadata.h')
-rw-r--r--libavcodec/dcadata.h89
1 files changed, 89 insertions, 0 deletions
diff --git a/libavcodec/dcadata.h b/libavcodec/dcadata.h
index 582f14d532..979b6dffbd 100644
--- a/libavcodec/dcadata.h
+++ b/libavcodec/dcadata.h
@@ -7663,4 +7663,93 @@ static const float dca_default_coeffs[10][6][2] = {
* where Ch(n) represents the subband samples in the (n)th audio channel.
*/
+static const int8_t dca_lfe_index[] = {
+ 1, 2, 2, 2, 2, 3, 2, 3, 2, 3, 2, 3, 1, 3, 2, 3
+};
+
+static const int8_t dca_channel_reorder_lfe[][9] = {
+ { 0, -1, -1, -1, -1, -1, -1, -1, -1 },
+ { 0, 1, -1, -1, -1, -1, -1, -1, -1 },
+ { 0, 1, -1, -1, -1, -1, -1, -1, -1 },
+ { 0, 1, -1, -1, -1, -1, -1, -1, -1 },
+ { 0, 1, -1, -1, -1, -1, -1, -1, -1 },
+ { 2, 0, 1, -1, -1, -1, -1, -1, -1 },
+ { 0, 1, 3, -1, -1, -1, -1, -1, -1 },
+ { 2, 0, 1, 4, -1, -1, -1, -1, -1 },
+ { 0, 1, 3, 4, -1, -1, -1, -1, -1 },
+ { 2, 0, 1, 4, 5, -1, -1, -1, -1 },
+ { 3, 4, 0, 1, 5, 6, -1, -1, -1 },
+ { 2, 0, 1, 4, 5, 6, -1, -1, -1 },
+ { 0, 6, 4, 5, 2, 3, -1, -1, -1 },
+ { 4, 2, 5, 0, 1, 6, 7, -1, -1 },
+ { 5, 6, 0, 1, 7, 3, 8, 4, -1 },
+ { 4, 2, 5, 0, 1, 6, 8, 7, -1 },
+};
+
+static const int8_t dca_channel_reorder_lfe_xch[][9] = {
+ { 0, 2, -1, -1, -1, -1, -1, -1, -1 },
+ { 0, 1, 3, -1, -1, -1, -1, -1, -1 },
+ { 0, 1, 3, -1, -1, -1, -1, -1, -1 },
+ { 0, 1, 3, -1, -1, -1, -1, -1, -1 },
+ { 0, 1, 3, -1, -1, -1, -1, -1, -1 },
+ { 2, 0, 1, 4, -1, -1, -1, -1, -1 },
+ { 0, 1, 3, 4, -1, -1, -1, -1, -1 },
+ { 2, 0, 1, 4, 5, -1, -1, -1, -1 },
+ { 0, 1, 4, 5, 3, -1, -1, -1, -1 },
+ { 2, 0, 1, 5, 6, 4, -1, -1, -1 },
+ { 3, 4, 0, 1, 6, 7, 5, -1, -1 },
+ { 2, 0, 1, 4, 5, 6, 7, -1, -1 },
+ { 0, 6, 4, 5, 2, 3, 7, -1, -1 },
+ { 4, 2, 5, 0, 1, 7, 8, 6, -1 },
+ { 5, 6, 0, 1, 8, 3, 9, 4, 7 },
+ { 4, 2, 5, 0, 1, 6, 9, 8, 7 },
+};
+
+static const int8_t dca_channel_reorder_nolfe[][9] = {
+ { 0, -1, -1, -1, -1, -1, -1, -1, -1 },
+ { 0, 1, -1, -1, -1, -1, -1, -1, -1 },
+ { 0, 1, -1, -1, -1, -1, -1, -1, -1 },
+ { 0, 1, -1, -1, -1, -1, -1, -1, -1 },
+ { 0, 1, -1, -1, -1, -1, -1, -1, -1 },
+ { 2, 0, 1, -1, -1, -1, -1, -1, -1 },
+ { 0, 1, 2, -1, -1, -1, -1, -1, -1 },
+ { 2, 0, 1, 3, -1, -1, -1, -1, -1 },
+ { 0, 1, 2, 3, -1, -1, -1, -1, -1 },
+ { 2, 0, 1, 3, 4, -1, -1, -1, -1 },
+ { 2, 3, 0, 1, 4, 5, -1, -1, -1 },
+ { 2, 0, 1, 3, 4, 5, -1, -1, -1 },
+ { 0, 5, 3, 4, 1, 2, -1, -1, -1 },
+ { 3, 2, 4, 0, 1, 5, 6, -1, -1 },
+ { 4, 5, 0, 1, 6, 2, 7, 3, -1 },
+ { 3, 2, 4, 0, 1, 5, 7, 6, -1 },
+};
+
+static const int8_t dca_channel_reorder_nolfe_xch[][9] = {
+ { 0, 1, -1, -1, -1, -1, -1, -1, -1 },
+ { 0, 1, 2, -1, -1, -1, -1, -1, -1 },
+ { 0, 1, 2, -1, -1, -1, -1, -1, -1 },
+ { 0, 1, 2, -1, -1, -1, -1, -1, -1 },
+ { 0, 1, 2, -1, -1, -1, -1, -1, -1 },
+ { 2, 0, 1, 3, -1, -1, -1, -1, -1 },
+ { 0, 1, 2, 3, -1, -1, -1, -1, -1 },
+ { 2, 0, 1, 3, 4, -1, -1, -1, -1 },
+ { 0, 1, 3, 4, 2, -1, -1, -1, -1 },
+ { 2, 0, 1, 4, 5, 3, -1, -1, -1 },
+ { 2, 3, 0, 1, 5, 6, 4, -1, -1 },
+ { 2, 0, 1, 3, 4, 5, 6, -1, -1 },
+ { 0, 5, 3, 4, 1, 2, 6, -1, -1 },
+ { 3, 2, 4, 0, 1, 6, 7, 5, -1 },
+ { 4, 5, 0, 1, 7, 2, 8, 3, 6 },
+ { 3, 2, 4, 0, 1, 5, 8, 7, 6 },
+};
+
+static const uint16_t dca_vlc_offs[] = {
+ 0, 512, 640, 768, 1282, 1794, 2436, 3080, 3770, 4454, 5364,
+ 5372, 5380, 5388, 5392, 5396, 5412, 5420, 5428, 5460, 5492, 5508,
+ 5572, 5604, 5668, 5796, 5860, 5892, 6412, 6668, 6796, 7308, 7564,
+ 7820, 8076, 8620, 9132, 9388, 9910, 10166, 10680, 11196, 11726, 12240,
+ 12752, 13298, 13810, 14326, 14840, 15500, 16022, 16540, 17158, 17678, 18264,
+ 18796, 19352, 19926, 20468, 21472, 22398, 23014, 23622,
+};
+
#endif /* AVCODEC_DCADATA_H */