Mercurial > mplayer.hg
annotate libfaad2/codebook/hcb_2.h @ 25014:f97c1739522b
The FFmpeg WMV2 decoder is no longer buggy now that J-frames are supported.
This change makes it the preferred decoder.
author | diego |
---|---|
date | Tue, 13 Nov 2007 23:47:15 +0000 |
parents | 1d5a49e6d9db |
children | e83eef58b30a |
rev | line source |
---|---|
10725 | 1 /* |
2 ** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding | |
3 ** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com | |
4 ** | |
5 ** This program is free software; you can redistribute it and/or modify | |
6 ** it under the terms of the GNU General Public License as published by | |
7 ** the Free Software Foundation; either version 2 of the License, or | |
8 ** (at your option) any later version. | |
9 ** | |
10 ** This program is distributed in the hope that it will be useful, | |
11 ** but WITHOUT ANY WARRANTY; without even the implied warranty of | |
12 ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
13 ** GNU General Public License for more details. | |
14 ** | |
15 ** You should have received a copy of the GNU General Public License | |
16 ** along with this program; if not, write to the Free Software | |
17 ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | |
18 ** | |
19 ** Any non-GPL usage of this software or parts of this software is strictly | |
20 ** forbidden. | |
21 ** | |
22 ** Commercial non-GPL licensing of this software is possible. | |
23 ** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. | |
24 ** | |
14726
1d5a49e6d9db
Remove modification notice from files that have not been locally modified.
diego
parents:
12625
diff
changeset
|
25 ** $Id: hcb_2.h,v 1.3 2003/09/09 18:12:01 menno Exp $ |
10725 | 26 **/ |
27 | |
28 /* 2-step huffman table HCB_2 */ | |
29 | |
30 | |
31 /* 1st step: 5 bits | |
32 * 2^5 = 32 entries | |
33 * | |
34 * Used to find offset into 2nd step table and number of extra bits to get | |
35 */ | |
36 static hcb hcb2_1[] = { | |
37 { /* 00000 */ 0, 0 }, | |
38 { /* */ 0, 0 }, | |
39 { /* */ 0, 0 }, | |
40 { /* */ 0, 0 }, | |
41 { /* 00100 */ 1, 0 }, | |
42 { /* */ 1, 0 }, | |
43 { /* 00110 */ 2, 0 }, | |
44 { /* 00111 */ 3, 0 }, | |
45 { /* 01000 */ 4, 0 }, | |
46 { /* 01001 */ 5, 0 }, | |
47 { /* 01010 */ 6, 0 }, | |
48 { /* 01011 */ 7, 0 }, | |
49 { /* 01100 */ 8, 0 }, | |
50 | |
51 /* 6 bit codewords */ | |
52 { /* 01101 */ 9, 1 }, | |
53 { /* 01110 */ 11, 1 }, | |
54 { /* 01111 */ 13, 1 }, | |
55 { /* 10000 */ 15, 1 }, | |
56 { /* 10001 */ 17, 1 }, | |
57 { /* 10010 */ 19, 1 }, | |
58 { /* 10011 */ 21, 1 }, | |
59 { /* 10100 */ 23, 1 }, | |
60 { /* 10101 */ 25, 1 }, | |
61 { /* 10110 */ 27, 1 }, | |
62 { /* 10111 */ 29, 1 }, | |
63 { /* 11000 */ 31, 1 }, | |
64 | |
65 /* 7 bit codewords */ | |
66 { /* 11001 */ 33, 2 }, | |
67 { /* 11010 */ 37, 2 }, | |
68 { /* 11011 */ 41, 2 }, | |
69 | |
70 /* 7/8 bit codewords */ | |
71 { /* 11100 */ 45, 3 }, | |
72 | |
73 /* 8 bit codewords */ | |
74 { /* 11101 */ 53, 3 }, | |
75 { /* 11110 */ 61, 3 }, | |
76 | |
77 /* 8/9 bit codewords */ | |
78 { /* 11111 */ 69, 4 } | |
79 }; | |
80 | |
81 /* 2nd step table | |
82 * | |
83 * Gives size of codeword and actual data (x,y,v,w) | |
84 */ | |
85 static hcb_2_quad hcb2_2[] = { | |
86 /* 3 bit codeword */ | |
87 { 3, 0, 0, 0, 0 }, | |
88 | |
89 /* 4 bit codeword */ | |
90 { 4, 1, 0, 0, 0 }, | |
91 | |
92 /* 5 bit codewords */ | |
93 { 5, -1, 0, 0, 0 }, | |
94 { 5, 0, 0, 0, 1 }, | |
95 { 5, 0, 0, -1, 0 }, | |
96 { 5, 0, 0, 0, -1 }, | |
97 { 5, 0, -1, 0, 0 }, | |
98 { 5, 0, 0, 1, 0 }, | |
99 { 5, 0, 1, 0, 0 }, | |
100 | |
101 /* 6 bit codewords */ | |
102 { 6, 0, -1, 1, 0 }, | |
103 { 6, -1, 1, 0, 0 }, | |
104 { 6, 0, 1, -1, 0 }, | |
105 { 6, 0, 0, 1, -1 }, | |
106 { 6, 0, 1, 0, -1 }, | |
107 { 6, 0, 0, -1, 1 }, | |
108 { 6, -1, 0, 0, -1 }, | |
109 { 6, 1, -1, 0, 0 }, | |
110 { 6, 1, 0, -1, 0 }, | |
111 { 6, -1, -1, 0, 0 }, | |
112 { 6, 0, 0, -1, -1 }, | |
113 { 6, 1, 0, 1, 0 }, | |
114 { 6, 1, 0, 0, 1 }, | |
115 { 6, 0, -1, 0, 1 }, | |
116 { 6, -1, 0, 1, 0 }, | |
117 { 6, 0, 1, 0, 1 }, | |
118 { 6, 0, -1, -1, 0 }, | |
119 { 6, -1, 0, 0, 1 }, | |
120 { 6, 0, -1, 0, -1 }, | |
121 { 6, -1, 0, -1, 0 }, | |
122 { 6, 1, 1, 0, 0 }, | |
123 { 6, 0, 1, 1, 0 }, | |
124 { 6, 0, 0, 1, 1 }, | |
125 { 6, 1, 0, 0, -1 }, | |
126 | |
127 /* 7 bit codewords */ | |
128 { 7, 0, 1, -1, 1 }, | |
129 { 7, 1, 0, -1, 1 }, | |
130 { 7, -1, 1, -1, 0 }, | |
131 { 7, 0, -1, 1, -1 }, | |
132 { 7, 1, -1, 1, 0 }, | |
133 { 7, 1, 1, 0, -1 }, | |
134 { 7, 1, 0, 1, 1 }, | |
135 { 7, -1, 1, 1, 0 }, | |
136 { 7, 0, -1, -1, 1 }, | |
137 { 7, 1, 1, 1, 0 }, | |
138 { 7, -1, 0, 1, -1 }, | |
139 { 7, -1, -1, -1, 0 }, | |
140 | |
141 /* 7/8 bit codewords */ | |
142 { 7, -1, 0, -1, 1 }, { 7, -1, 0, -1, 1 }, | |
143 { 7, 1, -1, -1, 0 }, { 7, 1, -1, -1, 0 }, | |
144 { 7, 1, 1, -1, 0 }, { 7, 1, 1, -1, 0 }, | |
145 { 8, 1, -1, 0, 1 }, | |
146 { 8, -1, 1, 0, -1 }, | |
147 | |
148 /* 8 bit codewords */ | |
149 { 8, -1, -1, 1, 0 }, | |
150 { 8, -1, 0, 1, 1 }, | |
151 { 8, -1, -1, 0, 1 }, | |
152 { 8, -1, -1, 0, -1 }, | |
153 { 8, 0, -1, -1, -1 }, | |
154 { 8, 1, 0, 1, -1 }, | |
155 { 8, 1, 0, -1, -1 }, | |
156 { 8, 0, 1, -1, -1 }, | |
157 { 8, 0, 1, 1, 1 }, | |
158 { 8, -1, 1, 0, 1 }, | |
159 { 8, -1, 0, -1, -1 }, | |
160 { 8, 0, 1, 1, -1 }, | |
161 { 8, 1, -1, 0, -1 }, | |
162 { 8, 0, -1, 1, 1 }, | |
163 { 8, 1, 1, 0, 1 }, | |
164 { 8, 1, -1, 1, -1 }, | |
165 | |
166 /* 8/9 bit codewords */ | |
167 { 8, -1, 1, -1, 1 }, { 8, -1, 1, -1, 1 }, | |
168 { 9, 1, -1, -1, 1 }, | |
169 { 9, -1, -1, -1, -1 }, | |
170 { 9, -1, 1, 1, -1 }, | |
171 { 9, -1, 1, 1, 1 }, | |
172 { 9, 1, 1, 1, 1 }, | |
173 { 9, -1, -1, 1, -1 }, | |
174 { 9, 1, -1, 1, 1 }, | |
175 { 9, -1, 1, -1, -1 }, | |
176 { 9, -1, -1, 1, 1 }, | |
177 { 9, 1, 1, -1, -1 }, | |
178 { 9, 1, -1, -1, -1 }, | |
179 { 9, -1, -1, -1, 1 }, | |
180 { 9, 1, 1, -1, 1 }, | |
181 { 9, 1, 1, 1, -1 } | |
182 }; |