r955: Fix the Diffkey icon.
[cinelerra_cv.git] / quicktime / encore50 / vlc.h
blob94668d2ba5cea54883fc8882f66e3d90d15789df
3 #ifndef _VLC_H_
4 #define _VLC_H_
6 /* type definitions for variable length code table entries */
8 typedef struct
10 U_Int code; /* right justified */
11 Int len;
12 } VLCtable;
15 /* DC prediction sizes */
17 static VLCtable DCtab_lum[13] =
19 {3,3}, {3,2}, {2,2}, {2,3}, {1,3}, {1,4}, {1,5}, {1,6}, {1,7},
20 {1,8}, {1,9}, {1,10}, {1,11}
21 };
23 static VLCtable DCtab_chrom[13] =
25 {3,2}, {2,2}, {1,2}, {1,3}, {1,4}, {1,5}, {1,6}, {1,7}, {1,8},
26 {1,9}, {1,10}, {1,11}, {1,12}
27 };
30 /* Motion vectors */
32 static VLCtable mvtab[33] =
34 {1,1}, {1,2}, {1,3}, {1,4}, {3,6}, {5,7}, {4,7}, {3,7},
35 {11,9}, {10,9}, {9,9}, {17,10}, {16,10}, {15,10}, {14,10}, {13,10},
36 {12,10}, {11,10}, {10,10}, {9,10}, {8,10}, {7,10}, {6,10}, {5,10},
37 {4,10}, {7,11}, {6,11}, {5,11}, {4,11}, {3,11}, {2,11}, {3,12},
38 {2,12}
42 /* MCBPC Indexing by cbpc in first two bits, mode in last two.
43 CBPC as in table 4/H.263, MB type (mode): 3 = 01, 4 = 10.
44 Example: cbpc = 01 and mode = 4 gives index = 0110 = 6. */
46 static VLCtable mcbpc_intra_tab[15] =
48 {0x01,9}, {0x01,1}, {0x01,4}, {0x00,0},
49 {0x00,0}, {0x01,3}, {0x01,6}, {0x00,0},
50 {0x00,0}, {0x02,3}, {0x02,6}, {0x00,0},
51 {0x00,0}, {0x03,3}, {0x03,6}
55 /* MCBPC inter.
56 Addressing: 5 bit ccmmm (cc = CBPC, mmm = mode (1-4 binary)) */
58 static VLCtable mcbpc_inter_tab[29] =
60 {1,1}, {3,3}, {2,3}, {3,5}, {4,6}, {1,9}, {0,0}, {0,0},
61 {3,4}, {7,7}, {5,7}, {4,8}, {4,9}, {0,0}, {0,0}, {0,0},
62 {2,4}, {6,7}, {4,7}, {3,8}, {3,9}, {0,0}, {0,0}, {0,0},
63 {5,6}, {5,9}, {5,8}, {3,7}, {2,9}
66 static VLCtable mcbpc_sprite_tab[31] =
68 {1,1}, {0,12}, {2,3}, {3,5}, {4,6}, {3,3}, {12,4}, {1,9},
69 {3,4}, {1,12}, {5,7}, {4,8}, {4,9}, {7,7}, {12,5}, {0,0},
70 {2,4}, {2,12}, {4,7}, {3,8}, {3,9}, {6,7}, {12,6}, {0,0},
71 {5,6}, {3,12}, {5,8}, {3,7}, {2,9}, {5,9}, {12,7}
74 /* MODB table, MW 18-MAY-1998 */
76 static VLCtable modb_tab[3] =
78 {1,1}, {1,2}, {0,2}
79 };
81 #if 0
82 /* MCBPC for separate mode */
84 static VLCtable mcbpc_sep_tab[9] =
86 {1,1}, {1,3}, {2,3}, {3,3}, {1,4}, {1,6}, {2,6}, {3,6}, {1,9}
88 #endif
90 /* CBPY. Straightforward indexing */
92 static VLCtable cbpy_tab[16] =
94 {3,4}, {5,5}, {4,5}, {9,4}, {3,5}, {7,4}, {2,6}, {11,4},
95 {2,5}, {3,6}, {5,4}, {10,4}, {4,4}, {8,4}, {6,4}, {3,2}
98 static VLCtable cbpy_tab3[8] =
100 {3,3},{1,6},{1,5},{2,3},{2,5},{3,5},{1,3},{1,1}
102 static VLCtable cbpy_tab2[4] =
104 {1,4},{1,3},{1,2},{1,1}
108 /* DCT coefficients. Four tables, two for last = 0, two for last = 1.
109 the sign bit must be added afterwards. */
111 /* first part of coeffs for last = 0. Indexed by [run][level-1] */
113 static VLCtable coeff_tab0[2][12] =
115 /* run = 0 */
117 {0x02, 2}, {0x0f, 4}, {0x15, 6}, {0x17, 7},
118 {0x1f, 8}, {0x25, 9}, {0x24, 9}, {0x21,10},
119 {0x20,10}, {0x07,11}, {0x06,11}, {0x20,11}
121 /* run = 1 */
123 {0x06, 3}, {0x14, 6}, {0x1e, 8}, {0x0f,10},
124 {0x21,11}, {0x50,12}, {0x00, 0}, {0x00, 0},
125 {0x00, 0}, {0x00, 0}, {0x00, 0}, {0x00, 0}
129 /* rest of coeffs for last = 0. indexing by [run-2][level-1] */
131 static VLCtable coeff_tab1[25][4] =
133 /* run = 2 */
135 {0x0e, 4}, {0x1d, 8}, {0x0e,10}, {0x51,12}
137 /* run = 3 */
139 {0x0d, 5}, {0x23, 9}, {0x0d,10}, {0x00, 0}
141 /* run = 4-26 */
143 {0x0c, 5}, {0x22, 9}, {0x52,12}, {0x00, 0}
146 {0x0b, 5}, {0x0c,10}, {0x53,12}, {0x00, 0}
149 {0x13, 6}, {0x0b,10}, {0x54,12}, {0x00, 0}
152 {0x12, 6}, {0x0a,10}, {0x00, 0}, {0x00, 0}
155 {0x11, 6}, {0x09,10}, {0x00, 0}, {0x00, 0}
158 {0x10, 6}, {0x08,10}, {0x00, 0}, {0x00, 0}
161 {0x16, 7}, {0x55,12}, {0x00, 0}, {0x00, 0}
164 {0x15, 7}, {0x00, 0}, {0x00, 0}, {0x00, 0}
167 {0x14, 7}, {0x00, 0}, {0x00, 0}, {0x00, 0}
170 {0x1c, 8}, {0x00, 0}, {0x00, 0}, {0x00, 0}
173 {0x1b, 8}, {0x00, 0}, {0x00, 0}, {0x00, 0}
176 {0x21, 9}, {0x00, 0}, {0x00, 0}, {0x00, 0}
179 {0x20, 9}, {0x00, 0}, {0x00, 0}, {0x00, 0}
182 {0x1f, 9}, {0x00, 0}, {0x00, 0}, {0x00, 0}
185 {0x1e, 9}, {0x00, 0}, {0x00, 0}, {0x00, 0}
188 {0x1d, 9}, {0x00, 0}, {0x00, 0}, {0x00, 0}
191 {0x1c, 9}, {0x00, 0}, {0x00, 0}, {0x00, 0}
194 {0x1b, 9}, {0x00, 0}, {0x00, 0}, {0x00, 0}
197 {0x1a, 9}, {0x00, 0}, {0x00, 0}, {0x00, 0}
200 {0x22,11}, {0x00, 0}, {0x00, 0}, {0x00, 0}
203 {0x23,11}, {0x00, 0}, {0x00, 0}, {0x00, 0}
206 {0x56,12}, {0x00, 0}, {0x00, 0}, {0x00, 0}
209 {0x57,12}, {0x00, 0}, {0x00, 0}, {0x00, 0}
213 /* first coeffs of last = 1. indexing by [run][level-1] */
215 static VLCtable coeff_tab2[2][3] =
217 /* run = 0 */
219 {0x07, 4}, {0x19, 9}, {0x05,11}
221 /* run = 1 */
223 {0x0f, 6}, {0x04,11}, {0x00, 0}
227 /* rest of coeffs for last = 1. indexing by [run-2] */
229 static VLCtable coeff_tab3[40] =
231 {0x0e, 6}, {0x0d, 6}, {0x0c, 6},
232 {0x13, 7}, {0x12, 7}, {0x11, 7}, {0x10, 7},
233 {0x1a, 8}, {0x19, 8}, {0x18, 8}, {0x17, 8},
234 {0x16, 8}, {0x15, 8}, {0x14, 8}, {0x13, 8},
235 {0x18, 9}, {0x17, 9}, {0x16, 9}, {0x15, 9},
236 {0x14, 9}, {0x13, 9}, {0x12, 9}, {0x11, 9},
237 {0x07,10}, {0x06,10}, {0x05,10}, {0x04,10},
238 {0x24,11}, {0x25,11}, {0x26,11}, {0x27,11},
239 {0x58,12}, {0x59,12}, {0x5a,12}, {0x5b,12},
240 {0x5c,12}, {0x5d,12}, {0x5e,12}, {0x5f,12},
241 {0x00, 0}
244 /* New tables for Intra luminance coefficients. Same codewords,
245 different meaning */
247 /* Coeffs for last = 0, run = 0. Indexed by [level-1] */
249 static VLCtable coeff_tab4[27] =
251 /* run = 0 */
252 {0x02, 2}, {0x06, 3}, {0x0f, 4}, {0x0d, 5},
253 {0x0c, 5}, {0x15, 6}, {0x13, 6}, {0x12, 6},
254 {0x17, 7}, {0x1f, 8}, {0x1e, 8}, {0x1d, 8},
255 {0x25, 9}, {0x24, 9}, {0x23, 9}, {0x21, 9},
256 {0x21,10}, {0x20,10}, {0x0f,10}, {0x0e,10},
257 {0x07,11}, {0x06,11}, {0x20,11}, {0x21,11},
258 {0x50,12}, {0x51,12}, {0x52,12}
261 /* Coeffs for last = 0, run = 1. Indexed by [level-1] */
263 static VLCtable coeff_tab5[10] =
265 {0x0e, 4}, {0x14, 6}, {0x16, 7}, {0x1c, 8},
266 {0x20, 9}, {0x1f, 9}, {0x0d,10}, {0x22,11},
267 {0x53,12}, {0x55,12}
270 /* Coeffs for last = 0, run = 2 -> 9. Indexed by [run-2][level-1] */
272 static VLCtable coeff_tab6[8][5] =
274 /* run = 2 */
276 {0x0b, 5}, {0x15, 7}, {0x1e, 9}, {0x0c,10},
277 {0x56,12}
279 /* run = 3 */
281 {0x11, 6}, {0x1b, 8}, {0x1d, 9}, {0x0b,10},
282 {0x00, 0}
284 /* run = 4 */
286 {0x10, 6}, {0x22, 9}, {0x0a,10}, {0x00, 0},
287 {0x00, 0}
289 /* run = 5 */
291 {0x0d, 6}, {0x1c, 9}, {0x08,10}, {0x00, 0},
292 {0x00, 0}
294 /* run = 6 */
296 {0x12, 7}, {0x1b, 9}, {0x54,12}, {0x00, 0},
297 {0x00, 0}
299 /* run = 7 */
301 {0x14, 7}, {0x1a, 9}, {0x57,12}, {0x00, 0},
302 {0x00, 0}
304 /* run = 8 */
306 {0x19, 8}, {0x09,10}, {0x00, 0}, {0x00, 0},
307 {0x00, 0}
309 /* run = 9 */
311 {0x18, 8}, {0x23,11}, {0x00, 0}, {0x00, 0},
312 {0x00, 0}
316 /* Coeffs for last = 0, run = 10 -> 14. Indexed by [run-10] */
318 static VLCtable coeff_tab7[5] =
320 {0x17, 8}, {0x19, 9}, {0x18, 9}, {0x07,10},
321 {0x58,12}
324 /* Coeffs for last = 1, run = 0. Indexed by [level-1] */
326 static VLCtable coeff_tab8[8] =
328 {0x07, 4}, {0x0c, 6}, {0x16, 8}, {0x17, 9},
329 {0x06,10}, {0x05,11}, {0x04,11}, {0x59,12}
332 /* Coeffs for last = 1, run = 1 -> 6. Indexed by [run-1][level-1] */
334 static VLCtable coeff_tab9[6][3] =
336 /* run = 1 */
338 {0x0f, 6}, {0x16, 9}, {0x05,10}
340 /* run = 2 */
342 {0x0e, 6}, {0x04,10}, {0x00, 0}
344 /* run = 3 */
346 {0x11, 7}, {0x24,11}, {0x00, 0}
348 /* run = 4 */
350 {0x10, 7}, {0x25,11}, {0x00, 0}
352 /* run = 5 */
354 {0x13, 7}, {0x5a,12}, {0x00, 0}
356 /* run = 6 */
358 {0x15, 8}, {0x5b,12}, {0x00, 0}
362 /* Coeffs for last = 1, run = 7 -> 20. Indexed by [run-7] */
364 static VLCtable coeff_tab10[14] =
366 {0x14, 8}, {0x13, 8}, {0x1a, 8}, {0x15, 9},
367 {0x14, 9}, {0x13, 9}, {0x12, 9}, {0x11, 9},
368 {0x26,11}, {0x27,11}, {0x5c,12}, {0x5d,12},
369 {0x5e,12}, {0x5f,12}
374 /* RVLC tables */
375 /* DCT coefficients. Four tables, two for last = 0, two for last = 1.
376 the sign bit must be added afterwards. */
378 /* DCT coeffs (intra) for last = 0. */
380 /* Indexed by [level-1] */
382 static VLCtable coeff_RVLCtab1[27] =
384 /* run = 0 */
385 { 0x6, 3},
386 { 0x7, 3},
387 { 0xa, 4},
388 { 0x9, 5},
389 { 0x14, 6},
390 { 0x15, 6},
391 { 0x34, 7},
392 { 0x74, 8},
393 { 0x75, 8},
394 { 0xdd, 9},
395 { 0xec, 9},
396 { 0x1ec, 10},
397 { 0x1ed, 10},
398 { 0x1f4, 10},
399 { 0x3ec, 11},
400 { 0x3ed, 11},
401 { 0x3f4, 11},
402 { 0x77d, 12},
403 { 0x7bc, 12},
404 { 0xfbd, 13},
405 { 0xfdc, 13},
406 { 0x7bd, 12},
407 { 0xfdd, 13},
408 { 0x1fbd, 14},
409 { 0x1fdc, 14},
410 { 0x1fdd, 14},
411 { 0x1ffc, 15}
415 /* Indexed by [level-1] */
417 static VLCtable coeff_RVLCtab2[13] =
419 /* run = 1 */
420 { 0x1, 4},
421 { 0x8, 5},
422 { 0x2d, 7},
423 { 0x6c, 8},
424 { 0x6d, 8},
425 { 0xdc, 9},
426 { 0x1dd, 10},
427 { 0x3dc, 11},
428 { 0x3dd, 11},
429 { 0x77c, 12},
430 { 0xfbc, 13},
431 { 0x1f7d, 14},
432 { 0x1fbc, 14}
436 /* Indexed by [level-1] */
438 static VLCtable coeff_RVLCtab3[11] =
440 /* run = 2 */
441 { 0x4, 5},
442 { 0x2c, 7},
443 { 0xbc, 9},
444 { 0x1dc, 10},
445 { 0x3bc, 11},
446 { 0x3bd, 11},
447 { 0xefd, 13},
448 { 0xf7c, 13},
449 { 0xf7d, 13},
450 { 0x1efd, 14},
451 { 0x1f7c, 14}
455 /* Indexed by [level-1] */
457 static VLCtable coeff_RVLCtab4[9] =
459 /* run = 3 */
460 { 0x5, 5},
461 { 0x5c, 8},
462 { 0xbd, 9},
463 { 0x37d, 11},
464 { 0x6fc, 12},
465 { 0xefc, 13},
466 { 0x1dfd, 14},
467 { 0x1efc, 14},
468 { 0x1ffd, 15}
472 /* Indexed by [run-4][level-1] */
474 static VLCtable coeff_RVLCtab5[2][6] =
476 /* run = 4 */
478 { 0xc, 6},
479 { 0x5d, 8},
480 { 0x1bd, 10},
481 { 0x3fd, 12},
482 { 0x6fd, 12},
483 { 0x1bfd, 14}
485 /* run = 5 */
487 { 0xd, 6},
488 { 0x7d, 9},
489 { 0x2fc, 11},
490 { 0x5fc, 12},
491 { 0x1bfc, 14},
492 { 0x1dfc, 14}
497 /* Indexed by [run-6][level-1] */
499 static VLCtable coeff_RVLCtab6[2][5] =
501 /* run = 6 */
503 { 0x1c, 7},
504 { 0x17c, 10},
505 { 0x2fd, 11},
506 { 0x5fd, 12},
507 { 0x2ffc, 15}
509 /* run = 7 */
511 { 0x1d, 7},
512 { 0x17d, 10},
513 { 0x37c, 11},
514 { 0xdfd, 13},
515 { 0x2ffd, 15}
520 /* Indexed by [run-8][level-1] */
522 static VLCtable coeff_RVLCtab7[2][4] =
524 /* run = 8 */
526 { 0x3c, 8},
527 { 0x1bc, 10},
528 { 0xbfd, 13},
529 { 0x17fd, 14}
531 /* run = 9 */
533 { 0x3d, 8},
534 { 0x1fd, 11},
535 { 0xdfc, 13},
536 { 0x37fc, 15},
541 /* Indexed by [run-10][level-1] */
543 static VLCtable coeff_RVLCtab8[3][2] =
545 /* run = 10 */
547 { 0x7c, 9},
548 { 0x3fc, 12}
550 /* run = 11 */
552 { 0xfc, 10},
553 { 0xbfc, 13}
555 /* run = 12 */
557 { 0xfd, 10},
558 { 0x37fd, 15}
563 /* Indexed by [level-1] */
565 static VLCtable coeff_RVLCtab9[7] =
567 /* run = 13 -> 19 */
568 { 0x1fc, 11},
569 { 0x7fc, 13},
570 { 0x7fd, 13},
571 { 0xffc, 14},
572 { 0xffd, 14},
573 { 0x17fc, 14},
574 { 0x3bfc, 15}
578 /* first coeffs of last = 1. indexing by [run][level-1] */
580 static VLCtable coeff_RVLCtab10[2][5] =
582 /* run = 0 */
584 { 0xb, 4},
585 { 0x78, 8},
586 { 0x3f5, 11},
587 { 0xfec, 13},
588 { 0x1fec, 14}
590 /* run = 1 */
592 { 0x12, 5},
593 { 0xed, 9},
594 { 0x7dc, 12},
595 { 0x1fed, 14},
596 { 0x3bfd, 15}
601 static VLCtable coeff_RVLCtab11[3] =
603 /* run = 2 */
604 { 0x13, 5},
605 { 0x3f8, 11},
606 { 0x3dfc, 15}
610 static VLCtable coeff_RVLCtab12[11][2] =
612 /* run = 3 */
614 { 0x18, 6},
615 { 0x7dd, 12}
617 /* run = 4 */
619 { 0x19, 6},
620 { 0x7ec, 12}
622 /* run = 5 */
624 { 0x22, 6},
625 { 0xfed, 13}
627 /* run = 6 */
629 { 0x23, 6},
630 { 0xff4, 13}
632 /* run = 7 */
634 { 0x35, 7},
635 { 0xff5, 13}
637 /* run = 8 */
639 { 0x38, 7},
640 { 0xff8, 13}
642 /* run = 9 */
644 { 0x39, 7},
645 { 0xff9, 13}
647 /* run = 10 */
649 { 0x42, 7},
650 { 0x1ff4, 14}
652 /* run = 11 */
654 { 0x43, 7},
655 { 0x1ff5, 14}
657 /* run = 12 */
659 { 0x79, 8},
660 { 0x1ff8, 14}
662 /* run = 13 */
664 { 0x82, 8},
665 { 0x3dfd, 15}
670 static VLCtable coeff_RVLCtab13[32] =
672 /* run = 14 -> 45 */
673 { 0x83, 8},
674 { 0xf4, 9},
675 { 0xf5, 9},
676 { 0xf8, 9},
677 { 0xf9, 9},
678 { 0x102, 9},
679 { 0x103, 9},
680 { 0x1f5, 10},
681 { 0x1f8, 10},
682 { 0x1f9, 10},
683 { 0x202, 10},
684 { 0x203, 10},
685 { 0x3f9, 11},
686 { 0x402, 11},
687 { 0x403, 11},
688 { 0x7ed, 12},
689 { 0x7f4, 12},
690 { 0x7f5, 12},
691 { 0x7f8, 12},
692 { 0x7f9, 12},
693 { 0x802, 12},
694 { 0x803, 12},
695 { 0x1002, 13},
696 { 0x1003, 13},
697 { 0x1ff9, 14},
698 { 0x2002, 14},
699 { 0x2003, 14},
700 { 0x3efc, 15},
701 { 0x3efd, 15},
702 { 0x3f7c, 15},
703 { 0x3f7d, 15}
707 /* Coeffs for last = 0, run = 0. Indexed by [level-1] */
709 static VLCtable coeff_RVLCtab14[19] =
711 /* run = 0 */
712 { 0x6, 3},
713 { 0x1, 4},
714 { 0x4, 5},
715 { 0x1c, 7},
716 { 0x3c, 8},
717 { 0x3d, 8},
718 { 0x7c, 9},
719 { 0xfc, 10},
720 { 0xfd, 10},
721 { 0x1fc, 11},
722 { 0x1fd, 11},
723 { 0x3fc, 12},
724 { 0x7fc, 13},
725 { 0x7fd, 13},
726 { 0xbfc, 13},
727 { 0xbfd, 13},
728 { 0xffc, 14},
729 { 0xffd, 14},
730 { 0x1ffc, 15}
733 static VLCtable coeff_RVLCtab15[10] =
735 /* run = 1 */
736 { 0x7, 3},
737 { 0xc, 6},
738 { 0x5c, 8},
739 { 0x7d, 9},
740 { 0x17c, 10},
741 { 0x2fc, 11},
742 { 0x3fd, 12},
743 { 0xdfc, 13},
744 { 0x17fc, 14},
745 { 0x17fd, 14}
748 static VLCtable coeff_RVLCtab16[2][7] =
750 /* run = 2 */
752 { 0xa, 4},
753 { 0x1d, 7},
754 { 0xbc, 9},
755 { 0x2fd, 11},
756 { 0x5fc, 12},
757 { 0x1bfc, 14},
758 { 0x1bfd, 14}
760 /* run = 3 */
762 { 0x5, 5},
763 { 0x5d, 8},
764 { 0x17d, 10},
765 { 0x5fd, 12},
766 { 0xdfd, 13},
767 { 0x1dfc, 14},
768 { 0x1ffd, 15}
772 static VLCtable coeff_RVLCtab17[5] =
774 /* run = 4 */
775 { 0x8, 5},
776 { 0x6c, 8},
777 { 0x37c, 11},
778 { 0xefc, 13},
779 { 0x2ffc, 15}
782 static VLCtable coeff_RVLCtab18[3][4] =
784 /* run = 5 */
786 { 0x9, 5},
787 { 0xbd, 9},
788 { 0x37d, 11},
789 { 0xefd, 13}
791 /* run = 6 */
793 { 0xd, 6},
794 { 0x1bc, 10},
795 { 0x6fc, 12},
796 { 0x1dfd, 14}
798 /* run = 7 */
800 { 0x14, 6},
801 { 0x1bd, 10},
802 { 0x6fd, 12},
803 { 0x2ffd, 15}
807 static VLCtable coeff_RVLCtab19[2][3] =
809 /* run = 8 */
811 { 0x15, 6},
812 { 0x1dc, 10},
813 { 0xf7c, 13}
815 /* run = 9 */
817 { 0x2c, 7},
818 { 0x1dd, 10},
819 { 0x1efc, 14}
823 static VLCtable coeff_RVLCtab20[8][2] =
825 /* run = 10 */
827 { 0x2d, 7},
828 { 0x3bc, 11}
830 /* run = 11 */
832 { 0x34, 7},
833 { 0x77c, 12}
835 /* run = 12 */
837 { 0x6d, 8},
838 { 0xf7d, 13}
840 /* run = 13 */
842 { 0x74, 8},
843 { 0x1efd, 14}
845 /* run = 14 */
847 { 0x75, 8},
848 { 0x1f7c, 14}
850 /* run = 15 */
852 { 0xdc, 9},
853 { 0x1f7d, 14}
855 /* run = 16 */
857 { 0xdd, 9},
858 { 0x1fbc, 14}
860 /* run = 17 */
862 { 0xec, 9},
863 { 0x37fc, 15}
867 static VLCtable coeff_RVLCtab21[21] =
869 /* run = 18 -> 38 */
870 { 0x1ec, 10},
871 { 0x1ed, 10},
872 { 0x1f4, 10},
873 { 0x3bd, 11},
874 { 0x3dc, 11},
875 { 0x3dd, 11},
876 { 0x3ec, 11},
877 { 0x3ed, 11},
878 { 0x3f4, 11},
879 { 0x77d, 12},
880 { 0x7bc, 12},
881 { 0x7bd, 12},
882 { 0xfbc, 13},
883 { 0xfbd, 13},
884 { 0xfdc, 13},
885 { 0xfdd, 13},
886 { 0x1fbd, 14},
887 { 0x1fdc, 14},
888 { 0x1fdd, 14},
889 { 0x37fd, 15},
890 { 0x3bfc, 15}
894 /* first coeffs of last = 1. indexing by [run][level-1] */
896 static VLCtable coeff_RVLCtab22[2][5] =
898 /* run = 0 */
900 { 0xb, 4},
901 { 0x78, 8},
902 { 0x3f5, 11},
903 { 0xfec, 13},
904 { 0x1fec, 14}
906 /* run = 1 */
908 { 0x12, 5},
909 { 0xed, 9},
910 { 0x7dc, 12},
911 { 0x1fed, 14},
912 { 0x3bfd, 15}
916 static VLCtable coeff_RVLCtab23[3] =
918 /* run = 2 */
919 { 0x13, 5},
920 { 0x3f8, 11},
921 { 0x3dfc, 15}
924 static VLCtable coeff_RVLCtab24[11][2] =
926 /* run = 3 */
928 { 0x18, 6},
929 { 0x7dd, 12}
931 /* run = 4 */
933 { 0x19, 6},
934 { 0x7ec, 12}
936 /* run = 5 */
938 { 0x22, 6},
939 { 0xfed, 13}
941 /* run = 6 */
943 { 0x23, 6},
944 { 0xff4, 13}
946 /* run = 7 */
948 { 0x35, 7},
949 { 0xff5, 13}
951 /* run = 8 */
953 { 0x38, 7},
954 { 0xff8, 13}
956 /* run = 9 */
958 { 0x39, 7},
959 { 0xff9, 13}
961 /* run = 10 */
963 { 0x42, 7},
964 { 0x1ff4, 14}
966 /* run = 11 */
968 { 0x43, 7},
969 { 0x1ff5, 14}
971 /* run = 12 */
973 { 0x79, 8},
974 { 0x1ff8, 14}
976 /* run = 13 */
978 { 0x82, 8},
979 { 0x3dfd, 15}
984 static VLCtable coeff_RVLCtab25[32] =
986 /* run = 14 -> 45 */
987 { 0x83, 8},
988 { 0xf4, 9},
989 { 0xf5, 9},
990 { 0xf8, 9},
991 { 0xf9, 9},
992 { 0x102, 9},
993 { 0x103, 9},
994 { 0x1f5, 10},
995 { 0x1f8, 10},
996 { 0x1f9, 10},
997 { 0x202, 10},
998 { 0x203, 10},
999 { 0x3f9, 11},
1000 { 0x402, 11},
1001 { 0x403, 11},
1002 { 0x7ed, 12},
1003 { 0x7f4, 12},
1004 { 0x7f5, 12},
1005 { 0x7f8, 12},
1006 { 0x7f9, 12},
1007 { 0x802, 12},
1008 { 0x803, 12},
1009 { 0x1002, 13},
1010 { 0x1003, 13},
1011 { 0x1ff9, 14},
1012 { 0x2002, 14},
1013 { 0x2003, 14},
1014 { 0x3efc, 15},
1015 { 0x3efd, 15},
1016 { 0x3f7c, 15},
1017 { 0x3f7d, 15}
1020 #endif /* _VLC_H */