Fixed initialisation of tf in file_open(). Without setting the memory to 0,
[cinelerra_cv/mob.git] / libmpeg3 / video / vlc.h
blob9af49858a7bea8b27f36056259eb6e7757460e0f
1 #ifndef VLC_H
2 #define VLC_H
4 /* variable length code tables */
6 typedef struct {
7 char val, len;
8 } mpeg3_VLCtab_t;
10 typedef struct {
11 char run, level, len;
12 } mpeg3_DCTtab_t;
14 /* Added 03/38/96 by Alex de Jong : avoid IRIX GNU warning */
15 #ifdef ERROR
16 #undef ERROR
17 #define ERROR 99
18 #endif
20 /* Table B-3, mb_type in P-pictures, codes 001..1xx */
21 extern mpeg3_VLCtab_t mpeg3_PMBtab0[8];
23 /* Table B-3, mb_type in P-pictures, codes 000001..00011x */
24 extern mpeg3_VLCtab_t mpeg3_PMBtab1[8];
26 /* Table B-4, mb_type in B-pictures, codes 0010..11xx */
27 extern mpeg3_VLCtab_t mpeg3_BMBtab0[16];
29 /* Table B-4, mb_type in B-pictures, codes 000001..00011x */
30 extern mpeg3_VLCtab_t mpeg3_BMBtab1[8];
32 /* Table B-5, mb_type in spat. scal. I-pictures, codes 0001..1xxx */
33 extern mpeg3_VLCtab_t mpeg3_spIMBtab[16];
35 /* Table B-6, mb_type in spat. scal. P-pictures, codes 0010..11xx */
36 extern mpeg3_VLCtab_t mpeg3_spPMBtab0[16];
38 /* Table B-6, mb_type in spat. scal. P-pictures, codes 0000010..000111x */
39 extern mpeg3_VLCtab_t mpeg3_spPMBtab1[16];
41 /* Table B-7, mb_type in spat. scal. B-pictures, codes 0010..11xx */
42 extern mpeg3_VLCtab_t mpeg3_spBMBtab0[14];
44 /* Table B-7, mb_type in spat. scal. B-pictures, codes 0000100..000111x */
45 extern mpeg3_VLCtab_t mpeg3_spBMBtab1[12];
47 /* Table B-7, mb_type in spat. scal. B-pictures, codes 00000100x..000001111 */
48 extern mpeg3_VLCtab_t mpeg3_spBMBtab2[8];
50 /* Table B-8, mb_type in spat. scal. B-pictures, codes 001..1xx */
51 extern mpeg3_VLCtab_t mpeg3_SNRMBtab[8];
53 /* Table B-10, motion_code, codes 0001 ... 01xx */
54 extern mpeg3_VLCtab_t mpeg3_MVtab0[8];
56 /* Table B-10, motion_code, codes 0000011 ... 000011x */
57 extern mpeg3_VLCtab_t mpeg3_MVtab1[8];
59 /* Table B-10, motion_code, codes 0000001100 ... 000001011x */
60 extern mpeg3_VLCtab_t mpeg3_MVtab2[12];
62 /* Table B-9, coded_block_pattern, codes 01000 ... 111xx */
63 extern mpeg3_VLCtab_t mpeg3_CBPtab0[32];
65 /* Table B-9, coded_block_pattern, codes 00000100 ... 001111xx */
66 extern mpeg3_VLCtab_t mpeg3_CBPtab1[64];
68 /* Table B-9, coded_block_pattern, codes 000000001 ... 000000111 */
69 extern mpeg3_VLCtab_t mpeg3_CBPtab2[8];
71 /* Table B-1, macroblock_address_increment, codes 00010 ... 011xx */
72 extern mpeg3_VLCtab_t mpeg3_MBAtab1[16];
74 /* Table B-1, macroblock_address_increment, codes 00000011000 ... 0000111xxxx */
75 extern mpeg3_VLCtab_t mpeg3_MBAtab2[104];
77 /* Table B-12, dct_dc_size_luminance, codes 00xxx ... 11110 */
78 extern mpeg3_VLCtab_t mpeg3_DClumtab0[32];
80 /* Table B-12, dct_dc_size_luminance, codes 111110xxx ... 111111111 */
81 extern mpeg3_VLCtab_t mpeg3_DClumtab1[16];
83 /* Table B-13, dct_dc_size_chrominance, codes 00xxx ... 11110 */
84 extern mpeg3_VLCtab_t mpeg3_DCchromtab0[32];
86 /* Table B-13, dct_dc_size_chrominance, codes 111110xxxx ... 1111111111 */
87 extern mpeg3_VLCtab_t mpeg3_DCchromtab1[32];
89 /* Table B-14, DCT coefficients table zero,
90 * codes 0100 ... 1xxx (used for first (DC) coefficient)
92 extern mpeg3_DCTtab_t mpeg3_DCTtabfirst[12];
94 /* Table B-14, DCT coefficients table zero,
95 * codes 0100 ... 1xxx (used for all other coefficients)
97 extern mpeg3_DCTtab_t mpeg3_DCTtabnext[12];
99 /* Table B-14, DCT coefficients table zero,
100 * codes 000001xx ... 00111xxx
102 extern mpeg3_DCTtab_t mpeg3_DCTtab0[60];
104 /* Table B-15, DCT coefficients table one,
105 * codes 000001xx ... 11111111
107 extern mpeg3_DCTtab_t mpeg3_DCTtab0a[252];
109 /* Table B-14, DCT coefficients table zero,
110 * codes 0000001000 ... 0000001111
112 extern mpeg3_DCTtab_t mpeg3_DCTtab1[8];
114 /* Table B-15, DCT coefficients table one,
115 * codes 000000100x ... 000000111x
117 extern mpeg3_DCTtab_t mpeg3_DCTtab1a[8];
119 /* Table B-14/15, DCT coefficients table zero / one,
120 * codes 000000010000 ... 000000011111
122 extern mpeg3_DCTtab_t mpeg3_DCTtab2[16];
124 /* Table B-14/15, DCT coefficients table zero / one,
125 * codes 0000000010000 ... 0000000011111
127 extern mpeg3_DCTtab_t mpeg3_DCTtab3[16];
129 /* Table B-14/15, DCT coefficients table zero / one,
130 * codes 00000000010000 ... 00000000011111
132 extern mpeg3_DCTtab_t mpeg3_DCTtab4[16];
134 /* Table B-14/15, DCT coefficients table zero / one,
135 * codes 000000000010000 ... 000000000011111
137 extern mpeg3_DCTtab_t mpeg3_DCTtab5[16];
139 /* Table B-14/15, DCT coefficients table zero / one,
140 * codes 0000000000010000 ... 0000000000011111
142 extern mpeg3_DCTtab_t mpeg3_DCTtab6[16];
145 #endif