Mercurial > mplayer.hg
annotate libmpeg2/libmpeg2_changes.diff @ 28147:ba2cf9827d09
Define HAVE_FAST_64BIT if appropriate
author | reimar |
---|---|
date | Tue, 23 Dec 2008 11:42:11 +0000 |
parents | 5c4dbd36c0cf |
children | 31287e75b5d8 |
rev | line source |
---|---|
27569
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
1 --- libmpeg2/cpu_accel.c 2006-06-16 20:12:26.000000000 +0200 |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
2 +++ libmpeg2/cpu_accel.c 2006-06-16 20:12:50.000000000 +0200 |
27573 | 3 @@ -29,9 +33,13 @@ |
4 #include "attributes.h" | |
27569
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
5 #include "mpeg2_internal.h" |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
6 |
27573 | 7 +#include "cpudetect.h" |
27569
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
8 + |
27573 | 9 #if defined(ARCH_X86) || defined(ARCH_X86_64) |
10 static inline uint32_t arch_accel (uint32_t accel) | |
27569
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
11 { |
27573 | 12 +/* Use MPlayer CPU detection instead of libmpeg2 variant. */ |
13 +#if 0 | |
14 if (accel & (MPEG2_ACCEL_X86_3DNOW | MPEG2_ACCEL_X86_MMXEXT)) | |
15 accel |= MPEG2_ACCEL_X86_MMX; | |
16 | |
17 @@ -124,6 +132,21 @@ | |
18 #endif /* ACCEL_DETECT */ | |
27569
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
19 |
27573 | 20 return accel; |
21 + | |
22 +#else /* 0 */ | |
23 + accel = 0; | |
24 + if (gCpuCaps.hasMMX) | |
25 + accel |= MPEG2_ACCEL_X86_MMX; | |
26 + if (gCpuCaps.hasSSE2) | |
27 + accel |= MPEG2_ACCEL_X86_SSE2; | |
28 + if (gCpuCaps.hasMMX2) | |
29 + accel |= MPEG2_ACCEL_X86_MMXEXT; | |
30 + if (gCpuCaps.has3DNow) | |
31 + accel |= MPEG2_ACCEL_X86_3DNOW; | |
32 + | |
33 + return accel; | |
34 + | |
35 +#endif /* 0 */ | |
36 } | |
37 #endif /* ARCH_X86 || ARCH_X86_64 */ | |
27569
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
38 |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
39 --- libmpeg2/decode.c 2006-06-16 20:12:26.000000000 +0200 |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
40 +++ libmpeg2/decode.c 2006-06-16 20:12:50.000000000 +0200 |
27573 | 41 @@ -345,6 +349,15 @@ |
27569
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
42 fbuf->buf[1] = buf[1]; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
43 fbuf->buf[2] = buf[2]; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
44 fbuf->id = id; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
45 + // HACK! FIXME! At first I frame, copy pointers to prediction frame too! |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
46 + if (mpeg2dec->custom_fbuf && !mpeg2dec->fbuf[1]->buf[0]){ |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
47 + mpeg2dec->fbuf[1]->buf[0]=buf[0]; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
48 + mpeg2dec->fbuf[1]->buf[1]=buf[1]; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
49 + mpeg2dec->fbuf[1]->buf[2]=buf[2]; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
50 + mpeg2dec->fbuf[1]->id=NULL; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
51 + } |
27573 | 52 +// printf("libmpeg2: FBUF 0:%p 1:%p 2:%p\n", |
53 +// mpeg2dec->fbuf[0]->buf[0],mpeg2dec->fbuf[1]->buf[0],mpeg2dec->fbuf[2]->buf[0]); | |
27569
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
54 } |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
55 |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
56 void mpeg2_custom_fbuf (mpeg2dec_t * mpeg2dec, int custom_fbuf) |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
57 --- libmpeg2/header.c 2006-06-16 20:12:26.000000000 +0200 |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
58 +++ libmpeg2/header.c 2006-06-16 20:12:50.000000000 +0200 |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
59 @@ -100,6 +104,9 @@ |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
60 mpeg2dec->decoder.convert = NULL; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
61 mpeg2dec->decoder.convert_id = NULL; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
62 mpeg2dec->picture = mpeg2dec->pictures; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
63 + memset(&mpeg2dec->fbuf_alloc[0].fbuf, 0, sizeof(mpeg2_fbuf_t)); |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
64 + memset(&mpeg2dec->fbuf_alloc[1].fbuf, 0, sizeof(mpeg2_fbuf_t)); |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
65 + memset(&mpeg2dec->fbuf_alloc[2].fbuf, 0, sizeof(mpeg2_fbuf_t)); |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
66 mpeg2dec->fbuf[0] = &mpeg2dec->fbuf_alloc[0].fbuf; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
67 mpeg2dec->fbuf[1] = &mpeg2dec->fbuf_alloc[1].fbuf; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
68 mpeg2dec->fbuf[2] = &mpeg2dec->fbuf_alloc[2].fbuf; |
27573 | 69 @@ -872,6 +879,7 @@ |
70 mpeg2dec->scaled[idx] = decoder->q_scale_type; | |
27569
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
71 for (i = 0; i < 32; i++) { |
27573 | 72 k = decoder->q_scale_type ? non_linear_scale[i] : (i << 1); |
27569
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
73 + decoder->quantizer_scales[i] = k; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
74 for (j = 0; j < 64; j++) |
27573 | 75 decoder->quantizer_prescale[idx][i][j] = |
76 k * mpeg2dec->quantizer_matrix[idx][j]; | |
27569
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
77 --- libmpeg2/idct.c (revision 26652) |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
78 +++ libmpeg2/idct.c (working copy) |
27573 | 79 @@ -235,34 +239,40 @@ |
27569
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
80 |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
81 void mpeg2_idct_init (uint32_t accel) |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
82 { |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
83 -#ifdef ARCH_X86 |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
84 +#ifdef HAVE_SSE2 |
27573 | 85 if (accel & MPEG2_ACCEL_X86_SSE2) { |
86 mpeg2_idct_copy = mpeg2_idct_copy_sse2; | |
87 mpeg2_idct_add = mpeg2_idct_add_sse2; | |
88 mpeg2_idct_mmx_init (); | |
89 - } else if (accel & MPEG2_ACCEL_X86_MMXEXT) { | |
27569
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
90 + } else |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
91 +#elif HAVE_MMX2 |
27573 | 92 + if (accel & MPEG2_ACCEL_X86_MMXEXT) { |
27569
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
93 mpeg2_idct_copy = mpeg2_idct_copy_mmxext; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
94 mpeg2_idct_add = mpeg2_idct_add_mmxext; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
95 mpeg2_idct_mmx_init (); |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
96 - } else if (accel & MPEG2_ACCEL_X86_MMX) { |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
97 + } else |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
98 +#elif HAVE_MMX |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
99 + if (accel & MPEG2_ACCEL_X86_MMX) { |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
100 mpeg2_idct_copy = mpeg2_idct_copy_mmx; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
101 mpeg2_idct_add = mpeg2_idct_add_mmx; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
102 mpeg2_idct_mmx_init (); |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
103 } else |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
104 #endif |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
105 -#ifdef ARCH_PPC |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
106 +#ifdef HAVE_ALTIVEC |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
107 if (accel & MPEG2_ACCEL_PPC_ALTIVEC) { |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
108 mpeg2_idct_copy = mpeg2_idct_copy_altivec; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
109 mpeg2_idct_add = mpeg2_idct_add_altivec; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
110 mpeg2_idct_altivec_init (); |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
111 } else |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
112 #endif |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
113 -#ifdef ARCH_ALPHA |
27979
5c4dbd36c0cf
Fix HAVE_VIS vs. HAVE_MVI typo, SPARC has MVI, not VIS.
diego
parents:
27645
diff
changeset
|
114 +#ifdef HAVE_MVI |
27569
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
115 if (accel & MPEG2_ACCEL_ALPHA_MVI) { |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
116 mpeg2_idct_copy = mpeg2_idct_copy_mvi; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
117 mpeg2_idct_add = mpeg2_idct_add_mvi; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
118 mpeg2_idct_alpha_init (); |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
119 - } else if (accel & MPEG2_ACCEL_ALPHA) { |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
120 + } else |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
121 +#elif ARCH_ALPHA |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
122 + if (accel & MPEG2_ACCEL_ALPHA) { |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
123 int i; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
124 |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
125 mpeg2_idct_copy = mpeg2_idct_copy_alpha; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
126 --- libmpeg2/motion_comp.c 2006-06-16 20:12:26.000000000 +0200 |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
127 +++ libmpeg2/motion_comp.c 2006-06-16 20:12:50.000000000 +0200 |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
128 @@ -33,16 +37,22 @@ |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
129 |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
130 void mpeg2_mc_init (uint32_t accel) |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
131 { |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
132 -#ifdef ARCH_X86 |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
133 +#ifdef HAVE_MMX2 |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
134 if (accel & MPEG2_ACCEL_X86_MMXEXT) |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
135 mpeg2_mc = mpeg2_mc_mmxext; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
136 - else if (accel & MPEG2_ACCEL_X86_3DNOW) |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
137 + else |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
138 +#endif |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
139 +#ifdef HAVE_3DNOW |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
140 + if (accel & MPEG2_ACCEL_X86_3DNOW) |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
141 mpeg2_mc = mpeg2_mc_3dnow; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
142 - else if (accel & MPEG2_ACCEL_X86_MMX) |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
143 + else |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
144 +#endif |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
145 +#ifdef HAVE_MMX |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
146 + if (accel & MPEG2_ACCEL_X86_MMX) |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
147 mpeg2_mc = mpeg2_mc_mmx; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
148 else |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
149 #endif |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
150 -#ifdef ARCH_PPC |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
151 +#ifdef HAVE_ALTIVEC |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
152 if (accel & MPEG2_ACCEL_PPC_ALTIVEC) |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
153 mpeg2_mc = mpeg2_mc_altivec; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
154 else |
27645
83d915449a10
Remove IWMMXT optimizations through libavcodec from libmpeg2.
diego
parents:
27573
diff
changeset
|
155 @@ -52,15 +62,15 @@ |
27569
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
156 mpeg2_mc = mpeg2_mc_alpha; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
157 else |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
158 #endif |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
159 -#ifdef ARCH_SPARC |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
160 +#ifdef HAVE_VIS |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
161 if (accel & MPEG2_ACCEL_SPARC_VIS) |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
162 mpeg2_mc = mpeg2_mc_vis; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
163 else |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
164 #endif |
27573 | 165 #ifdef ARCH_ARM |
166 - if (accel & MPEG2_ACCEL_ARM) { | |
27569
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
167 + if (accel & MPEG2_ACCEL_ARM) |
27573 | 168 mpeg2_mc = mpeg2_mc_arm; |
169 - } else | |
27569
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
170 + else |
27573 | 171 #endif |
27569
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
172 mpeg2_mc = mpeg2_mc_c; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
173 } |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
174 --- libmpeg2/mpeg2_internal.h 2006-06-16 20:12:26.000000000 +0200 |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
175 +++ libmpeg2/mpeg2_internal.h 2006-06-16 20:12:50.000000000 +0200 |
27573 | 176 @@ -152,6 +156,11 @@ |
27569
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
177 |
27573 | 178 /* XXX: stuff due to xine shit */ |
179 int8_t q_scale_type; | |
27569
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
180 + |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
181 + int quantizer_scales[32]; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
182 + int quantizer_scale; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
183 + char* quant_store; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
184 + int quant_stride; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
185 }; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
186 |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
187 typedef struct { |
27573 | 188 @@ -223,6 +232,9 @@ |
189 //int8_t q_scale_type, scaled[4]; | |
27569
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
190 uint8_t quantizer_matrix[4][64]; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
191 uint8_t new_quantizer_matrix[4][64]; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
192 + |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
193 + unsigned char *pending_buffer; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
194 + int pending_length; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
195 }; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
196 |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
197 typedef struct { |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
198 --- libmpeg2/slice.c 2006-06-16 20:12:26.000000000 +0200 |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
199 +++ libmpeg2/slice.c 2006-06-16 20:12:50.000000000 +0200 |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
200 @@ -142,6 +146,7 @@ |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
201 |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
202 quantizer_scale_code = UBITS (bit_buf, 5); |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
203 DUMPBITS (bit_buf, bits, 5); |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
204 + decoder->quantizer_scale = decoder->quantizer_scales[quantizer_scale_code]; |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
205 |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
206 decoder->quantizer_matrix[0] = |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
207 decoder->quantizer_prescale[0][quantizer_scale_code]; |
27573 | 208 @@ -1564,6 +1569,24 @@ |
27569
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
209 |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
210 #define NEXT_MACROBLOCK \ |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
211 do { \ |
27573 | 212 + if(decoder->quant_store) { \ |
213 + if (decoder->picture_structure == TOP_FIELD) \ | |
214 + decoder->quant_store[2 * decoder->quant_stride \ | |
215 + * (decoder->v_offset >> 4) \ | |
216 + + (decoder->offset >> 4)] \ | |
217 + = decoder->quantizer_scale; \ | |
218 + else if (decoder->picture_structure == BOTTOM_FIELD) \ | |
219 + decoder->quant_store[2 * decoder->quant_stride \ | |
220 + * (decoder->v_offset >> 4) \ | |
221 + + decoder->quant_stride \ | |
222 + + (decoder->offset >> 4)] \ | |
223 + = decoder->quantizer_scale; \ | |
224 + else \ | |
225 + decoder->quant_store[decoder->quant_stride \ | |
226 + * (decoder->v_offset >> 4) \ | |
227 + + (decoder->offset >> 4)] \ | |
228 + = decoder->quantizer_scale; \ | |
229 + } \ | |
27569
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
230 decoder->offset += 16; \ |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
231 if (decoder->offset == decoder->width) { \ |
7c3d535aba22
Remove version string from name of local changes diff file.
diego
parents:
diff
changeset
|
232 do { /* just so we can use the break statement */ \ |