Add Russian translation provided by Валерий Крувялис <valkru@mail.ru>
[xiph-mirror.git] / theora-old / lib / hufftables.h
blob8052f9f741dfdc86a930fb9b0c09eba10dc62cf8
1 /********************************************************************
2 * *
3 * THIS FILE IS PART OF THE OggTheora SOFTWARE CODEC SOURCE CODE. *
4 * USE, DISTRIBUTION AND REPRODUCTION OF THIS LIBRARY SOURCE IS *
5 * GOVERNED BY A BSD-STYLE SOURCE LICENSE INCLUDED WITH THIS SOURCE *
6 * IN 'COPYING'. PLEASE READ THESE TERMS BEFORE DISTRIBUTING. *
7 * *
8 * THE Theora SOURCE CODE IS COPYRIGHT (C) 2002-2003 *
9 * by the Xiph.Org Foundation http://www.xiph.org/ *
10 * *
11 ********************************************************************
13 function:
14 last mod: $Id$
16 ********************************************************************/
18 #include "huffman.h"
19 #include "codec_internal.h"
21 const unsigned char ExtraBitLengths_VP31[MAX_ENTROPY_TOKENS] = {
22 0, 0, 0, 2, 3, 4, 12,3, 6, /* EOB and Zero-run tokens. */
23 0, 0, 0, 0, /* Very low value tokens. */
24 1, 1, 1, 1, 2, 3, 4, 5, 6, 10, /* Other value tokens */
25 1, 1, 1, 1, 1, 3, 4, /* Category 1 runs. */
26 2, 3, /* Category 2 runs. */
29 #define NEW_FREQS 0 /* dbm - test new frequency tables */
31 #if NEW_FREQS
32 /* New baseline frequency tables for encoder version >= 2 */
33 const ogg_uint32_t FrequencyCounts_VP3[NUM_HUFF_TABLES][MAX_ENTROPY_TOKENS] = {
34 /* DC Intra bias */
35 { 272, 84, 31, 36, 10, 2, 1, 92, 1,
36 701, 872, 410, 478,
37 630, 502, 417, 356, 582, 824, 985, 965, 697, 606,
38 125, 119, 40, 3, 9, 15, 10,
39 73, 37,
41 { 311, 107, 41, 51, 18, 4, 2, 120, 1,
42 824, 1037, 468, 541,
43 714, 555, 451, 374, 595, 819, 929, 817, 474, 220,
44 172, 142, 27, 4, 9, 10, 2,
45 98, 48,
47 { 353, 125, 49, 66, 24, 6, 2, 124, 1,
48 926, 1172, 512, 594,
49 766, 581, 458, 379, 590, 789, 849, 665, 306, 80,
50 204, 147, 25, 5, 12, 9, 2,
51 108, 54,
53 { 392, 141, 57, 75, 31, 7, 4, 138, 1,
54 1050, 1321, 559, 649,
55 806, 594, 460, 372, 568, 727, 710, 475, 155, 19,
56 251, 174, 27, 7, 16, 8, 2,
57 126, 62,
59 { 455, 168, 66, 87, 39, 10, 6, 124, 2,
60 1143, 1455, 592, 692,
61 824, 596, 453, 361, 542, 657, 592, 329, 78, 5,
62 269, 184, 27, 9, 19, 7, 2,
63 127, 66,
65 { 544, 201, 80, 102, 45, 11, 6, 99, 1,
66 1236, 1587, 610, 720,
67 833, 590, 444, 348, 506, 588, 487, 226, 39, 2,
68 253, 178, 27, 10, 20, 7, 2,
69 118, 65,
71 { 649, 241, 98, 121, 54, 14, 8, 84, 1,
72 1349, 1719, 634, 763,
73 847, 583, 428, 323, 456, 492, 349, 120, 13, 1,
74 231, 170, 24, 8, 19, 7, 1,
75 109, 67,
77 { 824, 304, 129, 158, 66, 19, 10, 44, 2,
78 1476, 1925, 644, 794,
79 838, 559, 396, 289, 392, 384, 223, 53, 3, 1,
80 159, 121, 17, 6, 16, 6, 2,
81 69, 53,
84 /* DC Inter Bias */
85 { 534, 174, 71, 68, 10, 1, 1, 68, 119,
86 1674, 1526, 560, 536,
87 539, 331, 229, 168, 233, 262, 231, 149, 71, 51,
88 629, 530, 284, 126, 182, 208, 184,
89 148, 87,
91 { 594, 195, 77, 71, 9, 1, 1, 47, 89,
92 1723, 1592, 595, 570,
93 574, 351, 241, 176, 243, 271, 234, 144, 65, 37,
94 534, 449, 240, 117, 167, 277, 153,
95 96, 54,
97 { 642, 213, 88, 83, 12, 1, 1, 40, 80,
98 1751, 1630, 621, 600,
99 598, 367, 250, 183, 251, 276, 235, 143, 62, 28,
100 485, 397, 212, 110, 161, 193, 141,
101 84, 48,
103 { 693, 258, 114, 131, 27, 3, 1, 44, 79,
104 1794, 1644, 550, 533,
105 518, 314, 213, 154, 209, 223, 174, 97, 40, 14,
106 584, 463, 236, 138, 196, 249, 143,
107 94, 54,
109 { 758, 303, 144, 189, 53, 8, 1, 37, 69,
110 1842, 1732, 513, 504,
111 478, 287, 191, 137, 182, 186, 137, 72, 31, 6,
112 589, 469, 199, 128, 177, 264, 161,
113 89, 49,
115 { 817, 344, 170, 243, 84, 18, 2, 30, 65,
116 1836, 1733, 518, 511,
117 477, 281, 185, 130, 169, 166, 117, 59, 25, 3,
118 572, 450, 185, 121, 173, 232, 146,
119 80, 43,
121 { 865, 389, 204, 322, 139, 42, 9, 26, 51,
122 1848, 1766, 531, 522,
123 477, 275, 177, 122, 153, 144, 97, 50, 16, 1,
124 485, 378, 167, 115, 164, 203, 128,
125 74, 42,
127 { 961, 447, 243, 407, 196, 74, 26, 12, 34,
128 2003, 1942, 571, 565,
129 494, 278, 173, 116, 141, 129, 85, 44, 8, 1,
130 285, 223, 101, 66, 104, 120, 74,
131 35, 22,
134 /* AC INTRA Tables */
135 /* AC Intra bias group 1 tables */
136 { 245, 68, 25, 28, 5, 1, 1, 359, 4,
137 910, 904, 570, 571,
138 766, 620, 478, 375, 554, 684, 652, 441, 182, 30,
139 535, 206, 118, 77, 69, 90, 16,
140 299, 100,
142 { 302, 86, 32, 36, 8, 1, 1, 362, 3,
143 974, 968, 599, 599,
144 774, 635, 469, 365, 528, 628, 557, 337, 118, 14,
145 577, 219, 136, 82, 69, 65, 13,
146 317, 112,
148 { 348, 102, 39, 44, 9, 2, 1, 363, 3,
149 1062, 1055, 607, 609,
150 787, 626, 457, 348, 494, 550, 452, 233, 60, 2,
151 636, 244, 159, 92, 74, 68, 12,
152 327, 119,
154 { 400, 121, 47, 51, 11, 2, 1, 366, 3,
155 1109, 1102, 620, 622,
156 786, 624, 450, 331, 459, 490, 366, 163, 29, 1,
157 673, 257, 175, 98, 77, 63, 14,
158 344, 131,
160 { 470, 151, 59, 67, 15, 3, 1, 354, 4,
161 1198, 1189, 640, 643,
162 769, 603, 410, 294, 386, 381, 240, 78, 5, 1,
163 746, 282, 205, 113, 87, 64, 15,
164 368, 145,
166 { 553, 189, 77, 94, 24, 6, 1, 347, 4,
167 1244, 1232, 650, 653,
168 739, 551, 360, 249, 303, 261, 129, 24, 1, 1,
169 828, 313, 245, 135, 108, 77, 17,
170 403, 169,
172 { 701, 253, 109, 140, 42, 12, 2, 350, 6,
173 1210, 1197, 652, 647,
174 673, 495, 299, 189, 211, 151, 50, 2, 1, 1,
175 892, 336, 284, 162, 134, 101, 25,
176 455, 205,
178 { 924, 390, 180, 248, 85, 31, 13, 286, 14,
179 1242, 1206, 601, 577,
180 519, 342, 175, 100, 85, 36, 1, 1, 1, 1,
181 1031, 348, 346, 204, 166, 131, 34,
182 473, 197,
184 /* AC Inter bias group 1 tables */
185 { 459, 128, 50, 48, 8, 1, 1, 224, 69,
186 1285, 1227, 587, 565,
187 573, 406, 261, 180, 228, 213, 130, 47, 11, 3,
188 1069, 540, 309, 231, 147, 279, 157,
189 383, 165,
191 { 524, 155, 62, 64, 14, 2, 1, 209, 63,
192 1345, 1288, 523, 507,
193 515, 358, 225, 153, 183, 160, 87, 29, 7, 2,
194 1151, 591, 365, 282, 179, 308, 133,
195 344, 157,
197 { 588, 181, 75, 81, 19, 3, 1, 204, 68,
198 1344, 1288, 517, 503,
199 505, 346, 216, 141, 169, 139, 71, 21, 5, 1,
200 1146, 584, 366, 286, 170, 298, 153,
201 342, 157,
203 { 634, 196, 82, 89, 22, 4, 1, 194, 60,
204 1356, 1312, 515, 502,
205 489, 331, 199, 127, 145, 111, 51, 14, 3, 1,
206 1156, 589, 393, 300, 182, 285, 144,
207 340, 159,
209 { 715, 231, 98, 113, 31, 7, 1, 181, 57,
210 1345, 1303, 498, 490,
211 448, 291, 166, 101, 106, 75, 30, 9, 1, 1,
212 1175, 584, 416, 321, 209, 333, 164,
213 330, 159,
215 { 825, 283, 125, 149, 44, 11, 2, 160, 59,
216 1343, 1308, 476, 469,
217 405, 247, 131, 75, 76, 47, 18, 5, 1, 1,
218 1192, 579, 432, 332, 217, 327, 176,
219 320, 154,
221 { 961, 361, 170, 215, 70, 20, 5, 161, 55,
222 1250, 1218, 463, 460,
223 354, 204, 101, 52, 48, 28, 11, 1, 1, 1,
224 1172, 570, 449, 350, 222, 332, 169,
225 338, 174,
227 { 1139, 506, 266, 387, 156, 57, 26, 114, 48,
228 1192, 1170, 366, 366,
229 226, 113, 47, 22, 22, 12, 1, 1, 1, 1,
230 1222, 551, 462, 391, 220, 322, 156,
231 290, 136,
234 /* AC Intra bias group 2 tables */
235 { 245, 49, 15, 11, 1, 1, 1, 332, 38,
236 1163, 1162, 685, 683,
237 813, 623, 437, 318, 421, 424, 288, 109, 14, 1,
238 729, 303, 179, 112, 87, 199, 46,
239 364, 135,
241 { 305, 67, 22, 17, 2, 1, 1, 329, 39,
242 1250, 1245, 706, 705,
243 801, 584, 385, 267, 330, 296, 165, 40, 3, 1,
244 798, 340, 206, 131, 108, 258, 52,
245 382, 154,
247 { 356, 82, 28, 23, 3, 1, 1, 312, 42,
248 1340, 1334, 701, 703,
249 770, 545, 346, 227, 269, 223, 100, 17, 1, 1,
250 846, 359, 222, 142, 120, 284, 55,
251 379, 157,
253 { 402, 95, 33, 30, 4, 1, 1, 300, 43,
254 1379, 1371, 710, 714,
255 724, 486, 289, 182, 202, 144, 47, 5, 1, 1,
256 908, 394, 250, 161, 141, 350, 60,
257 391, 171,
259 { 499, 122, 44, 42, 7, 1, 1, 267, 45,
260 1439, 1436, 690, 694,
261 628, 385, 213, 122, 117, 62, 14, 1, 1, 1,
262 992, 441, 288, 187, 167, 446, 82,
263 378, 176,
265 { 641, 168, 62, 60, 12, 1, 1, 247, 49,
266 1435, 1436, 662, 669,
267 527, 298, 142, 71, 55, 22, 3, 1, 1, 1,
268 1036, 470, 319, 208, 193, 548, 106,
269 362, 184,
271 { 860, 274, 111, 113, 23, 4, 1, 229, 59,
272 1331, 1323, 629, 645,
273 419, 192, 72, 30, 19, 6, 1, 1, 1, 1,
274 1022, 478, 339, 225, 213, 690, 142,
275 342, 198,
277 { 1059, 437, 218, 285, 84, 17, 2, 152, 44,
278 1284, 1313, 530, 561,
279 212, 66, 17, 6, 3, 1, 1, 1, 1, 1,
280 1034, 485, 346, 226, 207, 819, 185,
281 248, 145,
283 /* AC Inter bias group 2 tables */
284 { 407, 93, 31, 24, 2, 1, 1, 232, 108,
285 1365, 1349, 581, 578,
286 498, 305, 170, 100, 103, 67, 24, 5, 1, 1,
287 1175, 604, 393, 268, 209, 506, 217,
288 379, 193,
290 { 521, 129, 46, 39, 4, 1, 1, 199, 116,
291 1419, 1403, 543, 540,
292 446, 263, 138, 78, 75, 44, 13, 2, 1, 1,
293 1201, 605, 392, 267, 214, 533, 252,
294 334, 167,
296 { 575, 144, 52, 46, 6, 1, 1, 193, 124,
297 1394, 1384, 528, 528,
298 406, 227, 112, 59, 54, 28, 7, 1, 1, 1,
299 1210, 621, 412, 284, 235, 604, 265,
300 320, 167,
302 { 673, 174, 64, 59, 9, 1, 1, 177, 128,
303 1392, 1385, 499, 499,
304 352, 183, 85, 42, 35, 16, 3, 1, 1, 1,
305 1210, 626, 418, 289, 246, 675, 297,
306 292, 158,
308 { 804, 225, 85, 77, 12, 1, 1, 150, 129,
309 1387, 1384, 455, 455,
310 277, 129, 53, 23, 17, 7, 1, 1, 1, 1,
311 1212, 635, 433, 306, 268, 760, 313,
312 249, 137,
314 { 975, 305, 123, 117, 20, 2, 1, 135, 140,
315 1312, 1310, 401, 399,
316 201, 80, 28, 11, 8, 2, 1, 1, 1, 1,
317 1162, 623, 439, 314, 283, 906, 368,
318 203, 121,
320 { 1205, 452, 208, 231, 50, 6, 1, 123, 149,
321 1161, 1164, 370, 370,
322 137, 45, 14, 4, 2, 1, 1, 1, 1, 1,
323 1047, 562, 413, 300, 277, 1020, 404,
324 168, 105,
326 { 1297, 662, 389, 574, 200, 39, 4, 55, 120,
327 1069, 1076, 273, 265,
328 66, 14, 2, 1, 1, 1, 1, 1, 1, 1,
329 930, 475, 345, 249, 236, 1124, 376,
330 91, 56,
333 /* AC Intra bias group 3 tables */
334 { 278, 55, 17, 12, 1, 1, 1, 288, 71,
335 1315, 1304, 725, 724,
336 733, 506, 307, 195, 225, 175, 77, 12, 1, 1,
337 904, 414, 246, 170, 126, 290, 205,
338 423, 185,
340 { 382, 80, 26, 21, 2, 1, 1, 239, 64,
341 1442, 1429, 706, 701,
342 664, 420, 239, 146, 152, 105, 34, 2, 1, 1,
343 975, 440, 263, 185, 140, 332, 229,
344 397, 169,
346 { 451, 97, 32, 27, 4, 1, 1, 223, 75,
347 1462, 1454, 682, 680,
348 574, 343, 179, 101, 98, 54, 9, 1, 1, 1,
349 1031, 482, 293, 210, 163, 400, 297,
350 384, 181,
352 { 551, 128, 43, 37, 5, 1, 1, 201, 78,
353 1497, 1487, 642, 651,
354 493, 269, 133, 70, 60, 24, 2, 1, 1, 1,
355 1065, 504, 312, 228, 178, 451, 352,
356 351, 174,
358 { 693, 179, 63, 54, 8, 1, 1, 169, 78,
359 1502, 1497, 580, 591,
360 375, 186, 77, 35, 21, 4, 1, 1, 1, 1,
361 1099, 533, 341, 253, 206, 542, 432,
362 306, 164,
364 { 867, 263, 105, 96, 16, 2, 1, 152, 81,
365 1435, 1439, 521, 525,
366 270, 107, 32, 8, 3, 1, 1, 1, 1, 1,
367 1085, 537, 361, 277, 223, 616, 549,
368 258, 156,
370 { 1022, 385, 182, 207, 46, 7, 1, 158, 88,
371 1290, 1318, 501, 502,
372 184, 38, 6, 1, 1, 1, 1, 1, 1, 1,
373 1023, 480, 345, 301, 232, 665, 661,
374 210, 133,
376 { 1184, 555, 307, 457, 185, 44, 6, 115, 41,
377 1236, 1253, 329, 340,
378 32, 1, 1, 1, 1, 1, 1, 1, 1, 1,
379 1017, 385, 316, 370, 246, 672, 788,
380 85, 23,
382 /* AC Inter bias group 3 tables */
383 { 502, 106, 33, 22, 1, 1, 1, 151, 132,
384 1446, 1451, 502, 499,
385 343, 181, 84, 42, 36, 16, 3, 1, 1, 1,
386 1211, 661, 429, 312, 242, 637, 498,
387 288, 156,
389 { 651, 147, 48, 35, 3, 1, 1, 145, 140,
390 1419, 1420, 469, 466,
391 281, 132, 56, 25, 18, 6, 1, 1, 1, 1,
392 1175, 656, 435, 328, 260, 715, 556,
393 252, 147,
395 { 749, 179, 59, 43, 4, 1, 1, 123, 135,
396 1423, 1431, 413, 409,
397 221, 95, 36, 15, 9, 2, 1, 1, 1, 1,
398 1159, 658, 444, 340, 272, 782, 656,
399 205, 124,
401 { 902, 243, 86, 67, 7, 1, 1, 114, 141,
402 1385, 1385, 387, 383,
403 178, 67, 22, 7, 4, 1, 1, 1, 1, 1,
404 1096, 632, 434, 339, 277, 813, 735,
405 171, 109,
407 { 1081, 337, 133, 112, 15, 1, 1, 92, 137,
408 1350, 1349, 311, 309,
409 115, 34, 8, 2, 1, 1, 1, 1, 1, 1,
410 1016, 595, 418, 342, 283, 870, 883,
411 114, 78,
413 { 1253, 467, 210, 205, 34, 3, 1, 80, 130,
414 1318, 1313, 258, 260,
415 68, 12, 2, 1, 1, 1, 1, 1, 1, 1,
416 874, 516, 378, 330, 273, 877, 1000,
417 72, 53,
419 { 1362, 626, 333, 423, 100, 10, 1, 73, 106,
420 1311, 1313, 241, 231,
421 31, 3, 1, 1, 1, 1, 1, 1, 1, 1,
422 620, 368, 286, 302, 245, 814, 1127,
423 34, 28,
425 { 1203, 743, 460, 774, 284, 36, 1, 13, 25,
426 1956, 1961, 103, 106,
427 3, 1, 1, 1, 1, 1, 1, 1, 1, 1,
428 248, 131, 149, 272, 165, 535, 813,
429 3, 3,
432 /* AC Intra bias group 4 tables */
433 { 599, 150, 55, 50, 9, 1, 1, 181, 19,
434 1487, 1487, 625, 625,
435 473, 271, 138, 74, 71, 42, 11, 1, 1, 1,
436 1187, 591, 356, 239, 170, 351, 137,
437 395, 194,
439 { 758, 209, 79, 74, 15, 2, 1, 147, 25,
440 1514, 1514, 521, 520,
441 334, 165, 74, 36, 30, 11, 1, 1, 1, 1,
442 1252, 644, 409, 279, 211, 472, 203,
443 318, 171,
445 { 852, 252, 100, 98, 20, 3, 1, 130, 26,
446 1493, 1498, 481, 473,
447 268, 123, 51, 23, 15, 3, 1, 1, 1, 1,
448 1256, 652, 426, 294, 231, 543, 242,
449 278, 156,
451 { 971, 309, 130, 136, 30, 5, 1, 113, 28,
452 1458, 1467, 443, 435,
453 215, 90, 31, 12, 5, 1, 1, 1, 1, 1,
454 1232, 643, 426, 303, 243, 590, 300,
455 235, 136,
457 { 1100, 399, 180, 206, 53, 9, 1, 101, 29,
458 1419, 1425, 375, 374,
459 158, 47, 10, 1, 1, 1, 1, 1, 1, 1,
460 1193, 609, 426, 319, 256, 643, 383,
461 166, 103,
463 { 1195, 505, 249, 326, 98, 20, 3, 102, 25,
464 1370, 1356, 355, 347,
465 104, 11, 1, 1, 1, 1, 1, 1, 1, 1,
466 1100, 568, 381, 330, 261, 642, 466,
467 105, 69,
469 { 1176, 608, 345, 559, 244, 57, 6, 110, 9,
470 1370, 1332, 372, 367,
471 29, 1, 1, 1, 1, 1, 1, 1, 1, 1,
472 859, 427, 269, 359, 375, 608, 451,
473 35, 20,
475 { 1140, 613, 391, 797, 458, 180, 37, 2, 1,
476 2037, 1697, 95, 31,
477 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
478 360, 49, 23, 198, 1001, 719, 160,
479 1, 1,
481 /* AC Inter bias group 4 tables */
482 { 931, 272, 105, 96, 16, 1, 1, 91, 52,
483 1481, 1489, 347, 349,
484 174, 74, 28, 12, 8, 3, 1, 1, 1, 1,
485 1247, 719, 490, 356, 279, 706, 363,
486 187, 110,
488 { 1095, 358, 148, 143, 25, 3, 1, 74, 61,
489 1439, 1457, 304, 302,
490 127, 46, 15, 5, 3, 1, 1, 1, 1, 1,
491 1138, 664, 469, 347, 282, 768, 487,
492 139, 87,
494 { 1192, 423, 188, 189, 36, 4, 1, 64, 61,
495 1457, 1475, 284, 282,
496 106, 35, 10, 3, 1, 1, 1, 1, 1, 1,
497 1078, 624, 440, 329, 264, 744, 507,
498 117, 73,
500 { 1275, 496, 231, 258, 52, 6, 1, 53, 55,
501 1458, 1470, 248, 245,
502 77, 20, 5, 1, 1, 1, 1, 1, 1, 1,
503 984, 576, 414, 323, 260, 771, 569,
504 84, 54,
506 { 1377, 603, 302, 367, 87, 11, 1, 37, 52,
507 1522, 1532, 207, 204,
508 47, 8, 1, 1, 1, 1, 1, 1, 1, 1,
509 840, 493, 366, 291, 231, 690, 636,
510 52, 32,
512 { 1409, 708, 385, 529, 148, 24, 1, 23, 37,
513 1672, 1670, 163, 162,
514 22, 2, 1, 1, 1, 1, 1, 1, 1, 1,
515 647, 364, 291, 262, 210, 574, 643,
516 26, 14,
518 { 1348, 778, 481, 755, 245, 53, 4, 13, 19,
519 2114, 2089, 141, 139,
520 7, 1, 1, 1, 1, 1, 1, 1, 1, 1,
521 302, 183, 162, 181, 182, 344, 437,
522 8, 3,
524 { 1560, 769, 410, 664, 243, 58, 1, 1, 1,
525 3017, 2788, 17, 24,
526 3, 1, 1, 1, 1, 1, 1, 1, 1, 1,
527 34, 16, 8, 55, 134, 105, 86,
528 1, 1,
532 #else /* Frequency tables for encoder version < 2 */
534 const ogg_uint32_t FrequencyCounts_VP3[NUM_HUFF_TABLES][MAX_ENTROPY_TOKENS] = {
535 /* DC Intra bias */
536 { 198, 62, 22, 31, 14, 6, 6, 205, 3,
537 843, 843, 415, 516,
538 660, 509, 412, 347, 560, 779, 941, 930, 661, 377,
539 170, 155, 39, 2, 9, 15, 11,
540 128, 86,
542 { 299, 92, 34, 39, 15, 6, 6, 132, 1,
543 851, 851, 484, 485,
544 666, 514, 416, 351, 567, 788, 953, 943, 670, 383,
545 117, 119, 26, 4, 17, 7, 1,
546 93, 56,
548 { 367, 115, 42, 47, 16, 6, 6, 105, 1,
549 896, 896, 492, 493,
550 667, 510, 408, 342, 547, 760, 932, 927, 656, 379,
551 114, 103, 10, 3, 6, 2, 1,
552 88, 49,
554 { 462, 158, 63, 76, 28, 9, 8, 145, 1,
555 1140, 1140, 573, 574,
556 754, 562, 435, 357, 555, 742, 793, 588, 274, 81,
557 154, 117, 13, 6, 12, 2, 1,
558 104, 62,
560 { 558, 196, 81, 99, 36, 11, 9, 135, 1,
561 1300, 1301, 606, 607,
562 779, 560, 429, 349, 536, 680, 644, 405, 153, 30,
563 171, 120, 12, 5, 14, 3, 1,
564 104, 53,
566 { 635, 233, 100, 122, 46, 14, 12, 113, 1,
567 1414, 1415, 631, 631,
568 785, 555, 432, 335, 513, 611, 521, 284, 89, 13,
569 170, 113, 10, 5, 14, 3, 1,
570 102, 62,
572 { 720, 276, 119, 154, 62, 20, 16, 101, 1,
573 1583, 1583, 661, 661,
574 794, 556, 407, 318, 447, 472, 343, 153, 35, 1,
575 172, 115, 11, 7, 14, 3, 1,
576 112, 70,
578 { 853, 326, 144, 184, 80, 27, 19, 52, 1,
579 1739, 1740, 684, 685,
580 800, 540, 381, 277, 364, 352, 218, 78, 13, 1,
581 139, 109, 9, 6, 20, 2, 1,
582 94, 50,
585 /* DC Inter Bias */
586 { 490, 154, 57, 53, 10, 2, 1, 238, 160,
587 1391, 1390, 579, 578,
588 491, 273, 172, 118, 152, 156, 127, 79, 41, 39,
589 712, 547, 316, 125, 183, 306, 237,
590 451, 358,
592 { 566, 184, 70, 65, 11, 2, 1, 235, 51,
593 1414, 1414, 599, 598,
594 510, 285, 180, 124, 157, 161, 131, 82, 42, 40,
595 738, 551, 322, 138, 195, 188, 93,
596 473, 365,
598 { 711, 261, 111, 126, 27, 4, 1, 137, 52,
599 1506, 1505, 645, 645,
600 567, 316, 199, 136, 172, 175, 142, 88, 45, 48,
601 548, 449, 255, 145, 184, 174, 121,
602 260, 227,
604 { 823, 319, 144, 175, 43, 7, 1, 53, 42,
605 1648, 1648, 653, 652,
606 583, 329, 205, 139, 175, 176, 139, 84, 44, 34,
607 467, 389, 211, 137, 181, 186, 107,
608 106, 85,
610 { 948, 411, 201, 276, 85, 16, 2, 39, 33,
611 1778, 1777, 584, 583,
612 489, 265, 162, 111, 140, 140, 108, 64, 38, 23,
613 428, 356, 201, 139, 186, 165, 94,
614 78, 63,
616 { 1002, 470, 248, 386, 153, 39, 6, 23, 23,
617 1866, 1866, 573, 573,
618 467, 249, 155, 103, 130, 128, 94, 60, 38, 14,
619 323, 263, 159, 111, 156, 153, 74,
620 46, 34,
622 { 1020, 518, 291, 504, 242, 78, 18, 14, 14,
623 1980, 1979, 527, 526,
624 408, 219, 132, 87, 110, 104, 79, 55, 31, 7,
625 265, 213, 129, 91, 131, 111, 50,
626 31, 20,
628 { 1018, 544, 320, 591, 338, 139, 47, 5, 2,
629 2123, 2123, 548, 547,
630 414, 212, 126, 83, 101, 96, 79, 60, 23, 1,
631 120, 97, 55, 39, 60, 38, 15,
632 11, 8,
635 /* AC INTRA Tables */
636 /* AC Intra bias group 1 tables */
637 { 242, 62, 22, 20, 4, 1, 1, 438, 1,
638 593, 593, 489, 490,
639 657, 580, 471, 374, 599, 783, 869, 770, 491, 279,
640 358, 144, 82, 54, 49, 70, 5,
641 289, 107,
643 { 317, 95, 38, 41, 8, 1, 1, 479, 1,
644 653, 654, 500, 501,
645 682, 611, 473, 376, 582, 762, 806, 656, 358, 155,
646 419, 162, 86, 58, 36, 34, 1,
647 315, 126,
649 { 382, 121, 49, 59, 15, 3, 1, 496, 1,
650 674, 674, 553, 554,
651 755, 636, 487, 391, 576, 718, 701, 488, 221, 72,
652 448, 161, 107, 56, 37, 29, 1,
653 362, 156,
655 { 415, 138, 57, 73, 21, 5, 1, 528, 1,
656 742, 741, 562, 563,
657 753, 669, 492, 388, 563, 664, 589, 340, 129, 26,
658 496, 184, 139, 71, 48, 33, 2,
659 387, 166,
661 { 496, 170, 73, 94, 31, 8, 2, 513, 1,
662 855, 855, 604, 604,
663 769, 662, 477, 356, 486, 526, 381, 183, 51, 5,
664 590, 214, 160, 85, 60, 39, 3,
665 427, 203,
667 { 589, 207, 89, 116, 40, 13, 3, 491, 1,
668 919, 919, 631, 631,
669 769, 633, 432, 308, 408, 378, 247, 94, 17, 1,
670 659, 247, 201, 105, 73, 51, 3,
671 466, 242,
673 { 727, 266, 115, 151, 49, 17, 6, 439, 1,
674 977, 977, 642, 642,
675 718, 572, 379, 243, 285, 251, 133, 40, 1, 1,
676 756, 287, 253, 126, 94, 66, 4,
677 492, 280,
679 { 940, 392, 180, 247, 82, 30, 14, 343, 1,
680 1064, 1064, 615, 616,
681 596, 414, 235, 146, 149, 108, 41, 1, 1, 1,
682 882, 314, 346, 172, 125, 83, 6,
683 489, 291,
685 /* AC Inter bias group 1 tables */
686 { 440, 102, 33, 23, 2, 1, 1, 465, 85,
687 852, 852, 744, 743,
688 701, 496, 297, 193, 225, 200, 129, 58, 18, 2,
689 798, 450, 269, 202, 145, 308, 154,
690 646, 389,
692 { 592, 151, 53, 43, 6, 1, 1, 409, 34,
693 875, 875, 748, 747,
694 723, 510, 305, 196, 229, 201, 130, 59, 18, 2,
695 800, 436, 253, 185, 115, 194, 88,
696 642, 368,
698 { 759, 222, 86, 85, 17, 2, 1, 376, 46,
699 888, 888, 689, 688,
700 578, 408, 228, 143, 165, 141, 84, 35, 7, 1,
701 878, 488, 321, 244, 147, 266, 124,
702 612, 367,
704 { 912, 298, 122, 133, 34, 7, 1, 261, 44,
705 1092, 1091, 496, 496,
706 409, 269, 150, 95, 106, 87, 49, 16, 1, 1,
707 1102, 602, 428, 335, 193, 323, 157,
708 423, 253,
710 { 1072, 400, 180, 210, 60, 16, 3, 210, 40,
711 1063, 1063, 451, 451,
712 345, 221, 121, 73, 79, 64, 31, 6, 1, 1,
713 1105, 608, 462, 358, 202, 330, 155,
714 377, 228,
716 { 1164, 503, 254, 330, 109, 34, 9, 167, 35,
717 1038, 1037, 390, 390,
718 278, 170, 89, 54, 56, 40, 13, 1, 1, 1,
719 1110, 607, 492, 401, 218, 343, 141,
720 323, 192,
722 { 1173, 583, 321, 486, 196, 68, 23, 124, 23,
723 1037, 1037, 347, 346,
724 232, 139, 69, 40, 37, 20, 2, 1, 1, 1,
725 1128, 584, 506, 410, 199, 301, 113,
726 283, 159,
728 { 1023, 591, 366, 699, 441, 228, 113, 79, 5,
729 1056, 1056, 291, 291,
730 173, 96, 38, 19, 8, 1, 1, 1, 1, 1,
731 1187, 527, 498, 409, 147, 210, 56,
732 263, 117,
735 /* AC Intra bias group 2 tables */
736 { 311, 74, 27, 27, 5, 1, 1, 470, 24,
737 665, 667, 637, 638,
738 806, 687, 524, 402, 585, 679, 609, 364, 127, 20,
739 448, 210, 131, 76, 52, 111, 19,
740 393, 195,
742 { 416, 104, 39, 38, 8, 1, 1, 545, 33,
743 730, 731, 692, 692,
744 866, 705, 501, 365, 495, 512, 387, 168, 39, 2,
745 517, 240, 154, 86, 64, 127, 19,
746 461, 247,
748 { 474, 117, 43, 42, 9, 1, 1, 560, 40,
749 783, 783, 759, 760,
750 883, 698, 466, 318, 404, 377, 215, 66, 7, 1,
751 559, 259, 176, 110, 87, 170, 22,
752 520, 278,
754 { 582, 149, 53, 53, 12, 2, 1, 473, 39,
755 992, 993, 712, 713,
756 792, 593, 373, 257, 299, 237, 114, 25, 1, 1,
757 710, 329, 221, 143, 116, 226, 26,
758 490, 259,
760 { 744, 210, 78, 77, 16, 2, 1, 417, 37,
761 1034, 1035, 728, 728,
762 718, 509, 296, 175, 184, 122, 42, 3, 1, 1,
763 791, 363, 255, 168, 145, 311, 35,
764 492, 272,
766 { 913, 291, 121, 128, 28, 4, 1, 334, 40,
767 1083, 1084, 711, 712,
768 624, 378, 191, 107, 95, 50, 7, 1, 1, 1,
769 876, 414, 288, 180, 164, 382, 39,
770 469, 275,
772 { 1065, 405, 184, 216, 53, 8, 1, 236, 36,
773 1134, 1134, 685, 686,
774 465, 253, 113, 48, 41, 9, 1, 1, 1, 1,
775 965, 451, 309, 179, 166, 429, 53,
776 414, 249,
778 { 1148, 548, 301, 438, 160, 42, 6, 84, 17,
779 1222, 1223, 574, 575,
780 272, 111, 23, 6, 2, 1, 1, 1, 1, 1,
781 1060, 502, 328, 159, 144, 501, 54,
782 302, 183,
784 /* AC Inter bias group 2 tables */
785 { 403, 80, 24, 17, 1, 1, 1, 480, 90,
786 899, 899, 820, 819,
787 667, 413, 228, 133, 139, 98, 42, 10, 1, 1,
788 865, 470, 316, 222, 171, 419, 213,
789 645, 400,
791 { 698, 169, 59, 49, 6, 1, 1, 414, 101,
792 894, 893, 761, 761,
793 561, 338, 171, 96, 97, 64, 26, 6, 1, 1,
794 896, 494, 343, 239, 192, 493, 215,
795 583, 366,
797 { 914, 255, 94, 80, 10, 1, 1, 345, 128,
798 935, 935, 670, 671,
799 415, 222, 105, 55, 51, 30, 10, 1, 1, 1,
800 954, 530, 377, 274, 232, 641, 295,
801 456, 298,
803 { 1103, 359, 146, 135, 20, 1, 1, 235, 119,
804 1042, 1042, 508, 507,
805 293, 146, 65, 33, 30, 16, 4, 1, 1, 1,
806 1031, 561, 407, 296, 265, 813, 317,
807 301, 192,
809 { 1255, 504, 238, 265, 51, 5, 1, 185, 113,
810 1013, 1013, 437, 438,
811 212, 92, 41, 18, 15, 6, 1, 1, 1, 1,
812 976, 530, 386, 276, 260, 927, 357,
813 224, 148,
815 { 1292, 610, 332, 460, 127, 16, 1, 136, 99,
816 1014, 1015, 384, 384,
817 153, 65, 25, 11, 6, 1, 1, 1, 1, 1,
818 942, 487, 343, 241, 238, 970, 358,
819 174, 103,
821 { 1219, 655, 407, 700, 280, 55, 2, 100, 60,
822 1029, 1029, 337, 336,
823 119, 43, 11, 3, 2, 1, 1, 1, 1, 1,
824 894, 448, 305, 199, 213, 1005, 320,
825 136, 77,
827 { 1099, 675, 435, 971, 581, 168, 12, 37, 16,
828 1181, 1081, 319, 318,
829 66, 11, 6, 1, 1, 1, 1, 1, 1, 1,
830 914, 370, 235, 138, 145, 949, 128,
831 94, 41,
834 /* AC Intra bias group 3 tables */
835 { 486, 112, 39, 34, 6, 1, 1, 541, 67,
836 819, 818, 762, 763,
837 813, 643, 403, 280, 332, 295, 164, 53, 6, 1,
838 632, 294, 180, 131, 105, 208, 109,
839 594, 295,
841 { 723, 191, 69, 65, 12, 1, 1, 445, 79,
842 865, 865, 816, 816,
843 750, 515, 290, 172, 184, 122, 46, 5, 1, 1,
844 740, 340, 213, 165, 129, 270, 168,
845 603, 326,
847 { 884, 264, 102, 103, 21, 3, 1, 382, 68,
848 897, 897, 836, 836,
849 684, 427, 227, 119, 119, 70, 16, 1, 1, 1,
850 771, 367, 234, 184, 143, 272, 178,
851 555, 326,
853 { 1028, 347, 153, 161, 36, 8, 1, 251, 44,
854 1083, 1084, 735, 735,
855 541, 289, 144, 77, 57, 23, 3, 1, 1, 1,
856 926, 422, 270, 215, 176, 301, 183,
857 443, 248,
859 { 1155, 465, 224, 264, 71, 14, 3, 174, 27,
860 1110, 1111, 730, 731,
861 429, 206, 79, 30, 19, 4, 1, 1, 1, 1,
862 929, 443, 279, 225, 194, 298, 196,
863 354, 223,
865 { 1191, 576, 296, 415, 144, 36, 8, 114, 16,
866 1162, 1162, 749, 749,
867 338, 108, 29, 8, 5, 1, 1, 1, 1, 1,
868 947, 458, 273, 207, 194, 248, 145,
869 258, 152,
871 { 1169, 619, 366, 603, 247, 92, 23, 46, 1,
872 1236, 1236, 774, 775,
873 191, 35, 14, 1, 1, 1, 1, 1, 1, 1,
874 913, 449, 260, 214, 194, 180, 82,
875 174, 98,
877 { 1006, 537, 381, 897, 504, 266, 101, 39, 1,
878 1307, 1307, 668, 667,
879 116, 3, 1, 1, 1, 1, 1, 1, 1, 1,
880 1175, 261, 295, 70, 164, 107, 31,
881 10, 76,
883 /* AC Inter bias group 3 tables */
884 { 652, 156, 53, 43, 5, 1, 1, 368, 128,
885 983, 984, 825, 825,
886 583, 331, 163, 88, 84, 48, 15, 1, 1, 1,
887 870, 480, 316, 228, 179, 421, 244,
888 562, 349,
890 { 988, 280, 104, 87, 12, 1, 1, 282, 194,
891 980, 981, 738, 739,
892 395, 189, 80, 37, 31, 12, 2, 1, 1, 1,
893 862, 489, 333, 262, 214, 600, 446,
894 390, 260,
896 { 1176, 399, 165, 154, 24, 2, 1, 218, 224,
897 1017, 1018, 651, 651,
898 280, 111, 42, 16, 9, 3, 1, 1, 1, 1,
899 787, 469, 324, 269, 229, 686, 603,
900 267, 194,
902 { 1319, 530, 255, 268, 47, 4, 1, 113, 183,
903 1149, 1150, 461, 461,
904 173, 58, 17, 5, 3, 1, 1, 1, 1, 1,
905 768, 450, 305, 261, 221, 716, 835,
906 136, 97,
908 { 1362, 669, 355, 465, 104, 9, 1, 76, 153,
909 1253, 1253, 398, 397,
910 102, 21, 5, 1, 1, 1, 1, 1, 1, 1,
911 596, 371, 238, 228, 196, 660, 954,
912 68, 53,
914 { 1354, 741, 446, 702, 174, 15, 1, 38, 87,
915 1498, 1498, 294, 294,
916 43, 7, 1, 1, 1, 1, 1, 1, 1, 1,
917 381, 283, 165, 181, 155, 544, 1039,
918 25, 21,
920 { 1262, 885, 546, 947, 263, 18, 1, 18, 27,
921 1908, 1908, 163, 162,
922 14, 1, 1, 1, 1, 1, 1, 1, 1, 1,
923 195, 152, 83, 125, 109, 361, 827,
924 7, 5,
926 { 2539, 951, 369, 554, 212, 18, 1, 1, 1,
927 2290, 2289, 64, 64,
928 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
929 18, 18, 9, 55, 36, 184, 323,
930 1, 1,
934 /* AC Intra bias group 4 tables */
935 { 921, 264, 101, 100, 19, 2, 1, 331, 98,
936 1015, 1016, 799, 799,
937 512, 269, 119, 60, 50, 17, 1, 1, 1, 1,
938 841, 442, 307, 222, 182, 493, 256,
939 438, 310,
941 { 1147, 412, 184, 206, 50, 6, 1, 242, 141,
942 977, 976, 808, 807,
943 377, 135, 40, 10, 7, 1, 1, 1, 1, 1,
944 788, 402, 308, 223, 205, 584, 406,
945 316, 227,
947 { 1243, 504, 238, 310, 79, 11, 1, 184, 150,
948 983, 984, 814, 813,
949 285, 56, 10, 1, 1, 1, 1, 1, 1, 1,
950 713, 377, 287, 217, 180, 615, 558,
951 208, 164,
953 { 1266, 606, 329, 484, 161, 27, 1, 79, 92,
954 1187, 1188, 589, 588,
955 103, 10, 1, 1, 1, 1, 1, 1, 1, 1,
956 680, 371, 278, 221, 244, 614, 728,
957 80, 62,
959 { 1126, 828, 435, 705, 443, 90, 8, 10, 55,
960 1220, 1219, 350, 350,
961 28, 1, 1, 1, 1, 1, 1, 1, 1, 1,
962 602, 330, 222, 168, 158, 612, 919,
963 104, 5,
965 { 1210, 506, 1014, 926, 474, 240, 4, 1, 44,
966 1801, 1801, 171, 171,
967 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
968 900, 132, 36, 11, 47, 191, 316,
969 2, 1,
971 { 1210, 506, 1014, 926, 474, 240, 4, 1, 44,
972 1801, 1801, 171, 171,
973 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
974 900, 132, 36, 11, 47, 191, 316,
975 2, 1,
977 { 1210, 506, 1014, 926, 474, 240, 4, 1, 44,
978 1801, 1801, 171, 171,
979 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
980 900, 132, 36, 11, 47, 191, 316,
981 2, 1,
983 /* AC Inter bias group 4 tables */
984 { 1064, 325, 129, 117, 20, 2, 1, 266, 121,
985 1000, 1000, 706, 706,
986 348, 162, 67, 32, 25, 11, 1, 1, 1, 1,
987 876, 513, 363, 274, 225, 627, 384,
988 370, 251,
990 { 1311, 517, 238, 254, 45, 3, 1, 188, 160,
991 1070, 1070, 635, 635,
992 239, 85, 30, 11, 6, 1, 1, 1, 1, 1,
993 744, 420, 313, 239, 206, 649, 541,
994 221, 155,
996 { 1394, 632, 322, 385, 78, 7, 1, 134, 152,
997 1163, 1164, 607, 607,
998 185, 51, 12, 3, 1, 1, 1, 1, 1, 1,
999 631, 331, 275, 203, 182, 604, 620,
1000 146, 98,
1002 { 1410, 727, 407, 546, 146, 19, 1, 67, 88,
1003 1485, 1486, 419, 418,
1004 103, 18, 3, 1, 1, 1, 1, 1, 1, 1,
1005 555, 261, 234, 164, 148, 522, 654,
1006 67, 39,
1008 { 1423, 822, 492, 719, 216, 22, 1, 28, 59,
1009 1793, 1793, 323, 324,
1010 37, 2, 1, 1, 1, 1, 1, 1, 1, 1,
1011 376, 138, 158, 102, 119, 400, 604,
1012 28, 9,
1014 { 1585, 923, 563, 918, 207, 25, 1, 5, 20,
1015 2229, 2230, 172, 172,
1016 7, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1017 191, 40, 56, 22, 65, 243, 312,
1018 2, 1,
1020 { 2225, 1100, 408, 608, 133, 8, 1, 1, 1,
1021 2658, 2658, 25, 24,
1022 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1023 8, 1, 1, 1, 1, 125, 16,
1024 1, 1,
1026 { 2539, 951, 369, 554, 212, 18, 1, 1, 1,
1027 2290, 2289, 64, 64,
1028 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1029 18, 18, 9, 55, 36, 184, 323,
1030 1, 1,
1034 #endif /* NEW_FREQS */