comparison dsputil.c @ 2979:bfabfdf9ce55 libavcodec

COSMETICS: tabs --> spaces, some prettyprinting
author diego
date Thu, 22 Dec 2005 01:10:11 +0000
parents ef2149182f1c
children 533c6386eca9
comparison
equal deleted inserted replaced
2978:403183bbb505 2979:bfabfdf9ce55
122 17318417, 17248865, 17179870, 17111424, 17043522, 16976156, 16909321, 16843010, 122 17318417, 17248865, 17179870, 17111424, 17043522, 16976156, 16909321, 16843010,
123 }; 123 };
124 124
125 /* Input permutation for the simple_idct_mmx */ 125 /* Input permutation for the simple_idct_mmx */
126 static const uint8_t simple_mmx_permutation[64]={ 126 static const uint8_t simple_mmx_permutation[64]={
127 0x00, 0x08, 0x04, 0x09, 0x01, 0x0C, 0x05, 0x0D, 127 0x00, 0x08, 0x04, 0x09, 0x01, 0x0C, 0x05, 0x0D,
128 0x10, 0x18, 0x14, 0x19, 0x11, 0x1C, 0x15, 0x1D, 128 0x10, 0x18, 0x14, 0x19, 0x11, 0x1C, 0x15, 0x1D,
129 0x20, 0x28, 0x24, 0x29, 0x21, 0x2C, 0x25, 0x2D, 129 0x20, 0x28, 0x24, 0x29, 0x21, 0x2C, 0x25, 0x2D,
130 0x12, 0x1A, 0x16, 0x1B, 0x13, 0x1E, 0x17, 0x1F, 130 0x12, 0x1A, 0x16, 0x1B, 0x13, 0x1E, 0x17, 0x1F,
131 0x02, 0x0A, 0x06, 0x0B, 0x03, 0x0E, 0x07, 0x0F, 131 0x02, 0x0A, 0x06, 0x0B, 0x03, 0x0E, 0x07, 0x0F,
132 0x30, 0x38, 0x34, 0x39, 0x31, 0x3C, 0x35, 0x3D, 132 0x30, 0x38, 0x34, 0x39, 0x31, 0x3C, 0x35, 0x3D,
133 0x22, 0x2A, 0x26, 0x2B, 0x23, 0x2E, 0x27, 0x2F, 133 0x22, 0x2A, 0x26, 0x2B, 0x23, 0x2E, 0x27, 0x2F,
134 0x32, 0x3A, 0x36, 0x3B, 0x33, 0x3E, 0x37, 0x3F, 134 0x32, 0x3A, 0x36, 0x3B, 0x33, 0x3E, 0x37, 0x3F,
135 }; 135 };
136 136
137 static int pix_sum_c(uint8_t * pix, int line_size) 137 static int pix_sum_c(uint8_t * pix, int line_size)
138 { 138 {
139 int s, i, j; 139 int s, i, j;
140 140
141 s = 0; 141 s = 0;
142 for (i = 0; i < 16; i++) { 142 for (i = 0; i < 16; i++) {
143 for (j = 0; j < 16; j += 8) { 143 for (j = 0; j < 16; j += 8) {
144 s += pix[0]; 144 s += pix[0];
145 s += pix[1]; 145 s += pix[1];
146 s += pix[2]; 146 s += pix[2];
147 s += pix[3]; 147 s += pix[3];
148 s += pix[4]; 148 s += pix[4];
149 s += pix[5]; 149 s += pix[5];
150 s += pix[6]; 150 s += pix[6];
151 s += pix[7]; 151 s += pix[7];
152 pix += 8; 152 pix += 8;
153 } 153 }
154 pix += line_size - 16; 154 pix += line_size - 16;
155 } 155 }
156 return s; 156 return s;
157 } 157 }
158 158
159 static int pix_norm1_c(uint8_t * pix, int line_size) 159 static int pix_norm1_c(uint8_t * pix, int line_size)
161 int s, i, j; 161 int s, i, j;
162 uint32_t *sq = squareTbl + 256; 162 uint32_t *sq = squareTbl + 256;
163 163
164 s = 0; 164 s = 0;
165 for (i = 0; i < 16; i++) { 165 for (i = 0; i < 16; i++) {
166 for (j = 0; j < 16; j += 8) { 166 for (j = 0; j < 16; j += 8) {
167 #if 0 167 #if 0
168 s += sq[pix[0]]; 168 s += sq[pix[0]];
169 s += sq[pix[1]]; 169 s += sq[pix[1]];
170 s += sq[pix[2]]; 170 s += sq[pix[2]];
171 s += sq[pix[3]]; 171 s += sq[pix[3]];
172 s += sq[pix[4]]; 172 s += sq[pix[4]];
173 s += sq[pix[5]]; 173 s += sq[pix[5]];
174 s += sq[pix[6]]; 174 s += sq[pix[6]];
175 s += sq[pix[7]]; 175 s += sq[pix[7]];
176 #else 176 #else
177 #if LONG_MAX > 2147483647 177 #if LONG_MAX > 2147483647
178 register uint64_t x=*(uint64_t*)pix; 178 register uint64_t x=*(uint64_t*)pix;
179 s += sq[x&0xff]; 179 s += sq[x&0xff];
180 s += sq[(x>>8)&0xff]; 180 s += sq[(x>>8)&0xff];
181 s += sq[(x>>16)&0xff]; 181 s += sq[(x>>16)&0xff];
182 s += sq[(x>>24)&0xff]; 182 s += sq[(x>>24)&0xff];
183 s += sq[(x>>32)&0xff]; 183 s += sq[(x>>32)&0xff];
184 s += sq[(x>>40)&0xff]; 184 s += sq[(x>>40)&0xff];
185 s += sq[(x>>48)&0xff]; 185 s += sq[(x>>48)&0xff];
186 s += sq[(x>>56)&0xff]; 186 s += sq[(x>>56)&0xff];
187 #else 187 #else
188 register uint32_t x=*(uint32_t*)pix; 188 register uint32_t x=*(uint32_t*)pix;
189 s += sq[x&0xff]; 189 s += sq[x&0xff];
190 s += sq[(x>>8)&0xff]; 190 s += sq[(x>>8)&0xff];
191 s += sq[(x>>16)&0xff]; 191 s += sq[(x>>16)&0xff];
192 s += sq[(x>>24)&0xff]; 192 s += sq[(x>>24)&0xff];
193 x=*(uint32_t*)(pix+4); 193 x=*(uint32_t*)(pix+4);
194 s += sq[x&0xff]; 194 s += sq[x&0xff];
195 s += sq[(x>>8)&0xff]; 195 s += sq[(x>>8)&0xff];
196 s += sq[(x>>16)&0xff]; 196 s += sq[(x>>16)&0xff];
197 s += sq[(x>>24)&0xff]; 197 s += sq[(x>>24)&0xff];
198 #endif 198 #endif
199 #endif 199 #endif
200 pix += 8; 200 pix += 8;
201 } 201 }
202 pix += line_size - 16; 202 pix += line_size - 16;
203 } 203 }
204 return s; 204 return s;
205 } 205 }
206 206
207 static void bswap_buf(uint32_t *dst, uint32_t *src, int w){ 207 static void bswap_buf(uint32_t *dst, uint32_t *src, int w){
408 block += 8; 408 block += 8;
409 } 409 }
410 } 410 }
411 411
412 static void diff_pixels_c(DCTELEM *restrict block, const uint8_t *s1, 412 static void diff_pixels_c(DCTELEM *restrict block, const uint8_t *s1,
413 const uint8_t *s2, int stride){ 413 const uint8_t *s2, int stride){
414 int i; 414 int i;
415 415
416 /* read the pixels */ 416 /* read the pixels */
417 for(i=0;i<8;i++) { 417 for(i=0;i<8;i++) {
418 block[0] = s1[0] - s2[0]; 418 block[0] = s1[0] - s2[0];
429 } 429 }
430 } 430 }
431 431
432 432
433 static void put_pixels_clamped_c(const DCTELEM *block, uint8_t *restrict pixels, 433 static void put_pixels_clamped_c(const DCTELEM *block, uint8_t *restrict pixels,
434 int line_size) 434 int line_size)
435 { 435 {
436 int i; 436 int i;
437 uint8_t *cm = cropTbl + MAX_NEG_CROP; 437 uint8_t *cm = cropTbl + MAX_NEG_CROP;
438 438
439 /* read the pixels */ 439 /* read the pixels */
451 block += 8; 451 block += 8;
452 } 452 }
453 } 453 }
454 454
455 static void put_pixels_clamped4_c(const DCTELEM *block, uint8_t *restrict pixels, 455 static void put_pixels_clamped4_c(const DCTELEM *block, uint8_t *restrict pixels,
456 int line_size) 456 int line_size)
457 { 457 {
458 int i; 458 int i;
459 uint8_t *cm = cropTbl + MAX_NEG_CROP; 459 uint8_t *cm = cropTbl + MAX_NEG_CROP;
460 460
461 /* read the pixels */ 461 /* read the pixels */
469 block += 8; 469 block += 8;
470 } 470 }
471 } 471 }
472 472
473 static void put_pixels_clamped2_c(const DCTELEM *block, uint8_t *restrict pixels, 473 static void put_pixels_clamped2_c(const DCTELEM *block, uint8_t *restrict pixels,
474 int line_size) 474 int line_size)
475 { 475 {
476 int i; 476 int i;
477 uint8_t *cm = cropTbl + MAX_NEG_CROP; 477 uint8_t *cm = cropTbl + MAX_NEG_CROP;
478 478
479 /* read the pixels */ 479 /* read the pixels */
1212 1212
1213 static inline void put_tpel_pixels_mc10_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){ 1213 static inline void put_tpel_pixels_mc10_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){
1214 int i,j; 1214 int i,j;
1215 for (i=0; i < height; i++) { 1215 for (i=0; i < height; i++) {
1216 for (j=0; j < width; j++) { 1216 for (j=0; j < width; j++) {
1217 dst[j] = (683*(2*src[j] + src[j+1] + 1)) >> 11; 1217 dst[j] = (683*(2*src[j] + src[j+1] + 1)) >> 11;
1218 } 1218 }
1219 src += stride; 1219 src += stride;
1220 dst += stride; 1220 dst += stride;
1221 } 1221 }
1222 } 1222 }
1223 1223
1224 static inline void put_tpel_pixels_mc20_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){ 1224 static inline void put_tpel_pixels_mc20_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){
1225 int i,j; 1225 int i,j;
1226 for (i=0; i < height; i++) { 1226 for (i=0; i < height; i++) {
1227 for (j=0; j < width; j++) { 1227 for (j=0; j < width; j++) {
1228 dst[j] = (683*(src[j] + 2*src[j+1] + 1)) >> 11; 1228 dst[j] = (683*(src[j] + 2*src[j+1] + 1)) >> 11;
1229 } 1229 }
1230 src += stride; 1230 src += stride;
1231 dst += stride; 1231 dst += stride;
1232 } 1232 }
1233 } 1233 }
1234 1234
1235 static inline void put_tpel_pixels_mc01_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){ 1235 static inline void put_tpel_pixels_mc01_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){
1236 int i,j; 1236 int i,j;
1237 for (i=0; i < height; i++) { 1237 for (i=0; i < height; i++) {
1238 for (j=0; j < width; j++) { 1238 for (j=0; j < width; j++) {
1239 dst[j] = (683*(2*src[j] + src[j+stride] + 1)) >> 11; 1239 dst[j] = (683*(2*src[j] + src[j+stride] + 1)) >> 11;
1240 } 1240 }
1241 src += stride; 1241 src += stride;
1242 dst += stride; 1242 dst += stride;
1243 } 1243 }
1244 } 1244 }
1245 1245
1246 static inline void put_tpel_pixels_mc11_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){ 1246 static inline void put_tpel_pixels_mc11_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){
1247 int i,j; 1247 int i,j;
1248 for (i=0; i < height; i++) { 1248 for (i=0; i < height; i++) {
1249 for (j=0; j < width; j++) { 1249 for (j=0; j < width; j++) {
1250 dst[j] = (2731*(4*src[j] + 3*src[j+1] + 3*src[j+stride] + 2*src[j+stride+1] + 6)) >> 15; 1250 dst[j] = (2731*(4*src[j] + 3*src[j+1] + 3*src[j+stride] + 2*src[j+stride+1] + 6)) >> 15;
1251 } 1251 }
1252 src += stride; 1252 src += stride;
1253 dst += stride; 1253 dst += stride;
1254 } 1254 }
1255 } 1255 }
1256 1256
1257 static inline void put_tpel_pixels_mc12_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){ 1257 static inline void put_tpel_pixels_mc12_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){
1258 int i,j; 1258 int i,j;
1259 for (i=0; i < height; i++) { 1259 for (i=0; i < height; i++) {
1260 for (j=0; j < width; j++) { 1260 for (j=0; j < width; j++) {
1261 dst[j] = (2731*(3*src[j] + 2*src[j+1] + 4*src[j+stride] + 3*src[j+stride+1] + 6)) >> 15; 1261 dst[j] = (2731*(3*src[j] + 2*src[j+1] + 4*src[j+stride] + 3*src[j+stride+1] + 6)) >> 15;
1262 } 1262 }
1263 src += stride; 1263 src += stride;
1264 dst += stride; 1264 dst += stride;
1265 } 1265 }
1266 } 1266 }
1267 1267
1268 static inline void put_tpel_pixels_mc02_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){ 1268 static inline void put_tpel_pixels_mc02_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){
1269 int i,j; 1269 int i,j;
1270 for (i=0; i < height; i++) { 1270 for (i=0; i < height; i++) {
1271 for (j=0; j < width; j++) { 1271 for (j=0; j < width; j++) {
1272 dst[j] = (683*(src[j] + 2*src[j+stride] + 1)) >> 11; 1272 dst[j] = (683*(src[j] + 2*src[j+stride] + 1)) >> 11;
1273 } 1273 }
1274 src += stride; 1274 src += stride;
1275 dst += stride; 1275 dst += stride;
1276 } 1276 }
1277 } 1277 }
1278 1278
1279 static inline void put_tpel_pixels_mc21_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){ 1279 static inline void put_tpel_pixels_mc21_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){
1280 int i,j; 1280 int i,j;
1281 for (i=0; i < height; i++) { 1281 for (i=0; i < height; i++) {
1282 for (j=0; j < width; j++) { 1282 for (j=0; j < width; j++) {
1283 dst[j] = (2731*(3*src[j] + 4*src[j+1] + 2*src[j+stride] + 3*src[j+stride+1] + 6)) >> 15; 1283 dst[j] = (2731*(3*src[j] + 4*src[j+1] + 2*src[j+stride] + 3*src[j+stride+1] + 6)) >> 15;
1284 } 1284 }
1285 src += stride; 1285 src += stride;
1286 dst += stride; 1286 dst += stride;
1287 } 1287 }
1288 } 1288 }
1289 1289
1290 static inline void put_tpel_pixels_mc22_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){ 1290 static inline void put_tpel_pixels_mc22_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){
1291 int i,j; 1291 int i,j;
1292 for (i=0; i < height; i++) { 1292 for (i=0; i < height; i++) {
1293 for (j=0; j < width; j++) { 1293 for (j=0; j < width; j++) {
1294 dst[j] = (2731*(2*src[j] + 3*src[j+1] + 3*src[j+stride] + 4*src[j+stride+1] + 6)) >> 15; 1294 dst[j] = (2731*(2*src[j] + 3*src[j+1] + 3*src[j+stride] + 4*src[j+stride+1] + 6)) >> 15;
1295 } 1295 }
1296 src += stride; 1296 src += stride;
1297 dst += stride; 1297 dst += stride;
1298 } 1298 }
1299 } 1299 }
1309 1309
1310 static inline void avg_tpel_pixels_mc10_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){ 1310 static inline void avg_tpel_pixels_mc10_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){
1311 int i,j; 1311 int i,j;
1312 for (i=0; i < height; i++) { 1312 for (i=0; i < height; i++) {
1313 for (j=0; j < width; j++) { 1313 for (j=0; j < width; j++) {
1314 dst[j] = (dst[j] + ((683*(2*src[j] + src[j+1] + 1)) >> 11) + 1) >> 1; 1314 dst[j] = (dst[j] + ((683*(2*src[j] + src[j+1] + 1)) >> 11) + 1) >> 1;
1315 } 1315 }
1316 src += stride; 1316 src += stride;
1317 dst += stride; 1317 dst += stride;
1318 } 1318 }
1319 } 1319 }
1320 1320
1321 static inline void avg_tpel_pixels_mc20_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){ 1321 static inline void avg_tpel_pixels_mc20_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){
1322 int i,j; 1322 int i,j;
1323 for (i=0; i < height; i++) { 1323 for (i=0; i < height; i++) {
1324 for (j=0; j < width; j++) { 1324 for (j=0; j < width; j++) {
1325 dst[j] = (dst[j] + ((683*(src[j] + 2*src[j+1] + 1)) >> 11) + 1) >> 1; 1325 dst[j] = (dst[j] + ((683*(src[j] + 2*src[j+1] + 1)) >> 11) + 1) >> 1;
1326 } 1326 }
1327 src += stride; 1327 src += stride;
1328 dst += stride; 1328 dst += stride;
1329 } 1329 }
1330 } 1330 }
1331 1331
1332 static inline void avg_tpel_pixels_mc01_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){ 1332 static inline void avg_tpel_pixels_mc01_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){
1333 int i,j; 1333 int i,j;
1334 for (i=0; i < height; i++) { 1334 for (i=0; i < height; i++) {
1335 for (j=0; j < width; j++) { 1335 for (j=0; j < width; j++) {
1336 dst[j] = (dst[j] + ((683*(2*src[j] + src[j+stride] + 1)) >> 11) + 1) >> 1; 1336 dst[j] = (dst[j] + ((683*(2*src[j] + src[j+stride] + 1)) >> 11) + 1) >> 1;
1337 } 1337 }
1338 src += stride; 1338 src += stride;
1339 dst += stride; 1339 dst += stride;
1340 } 1340 }
1341 } 1341 }
1342 1342
1343 static inline void avg_tpel_pixels_mc11_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){ 1343 static inline void avg_tpel_pixels_mc11_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){
1344 int i,j; 1344 int i,j;
1345 for (i=0; i < height; i++) { 1345 for (i=0; i < height; i++) {
1346 for (j=0; j < width; j++) { 1346 for (j=0; j < width; j++) {
1347 dst[j] = (dst[j] + ((2731*(4*src[j] + 3*src[j+1] + 3*src[j+stride] + 2*src[j+stride+1] + 6)) >> 15) + 1) >> 1; 1347 dst[j] = (dst[j] + ((2731*(4*src[j] + 3*src[j+1] + 3*src[j+stride] + 2*src[j+stride+1] + 6)) >> 15) + 1) >> 1;
1348 } 1348 }
1349 src += stride; 1349 src += stride;
1350 dst += stride; 1350 dst += stride;
1351 } 1351 }
1352 } 1352 }
1353 1353
1354 static inline void avg_tpel_pixels_mc12_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){ 1354 static inline void avg_tpel_pixels_mc12_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){
1355 int i,j; 1355 int i,j;
1356 for (i=0; i < height; i++) { 1356 for (i=0; i < height; i++) {
1357 for (j=0; j < width; j++) { 1357 for (j=0; j < width; j++) {
1358 dst[j] = (dst[j] + ((2731*(3*src[j] + 2*src[j+1] + 4*src[j+stride] + 3*src[j+stride+1] + 6)) >> 15) + 1) >> 1; 1358 dst[j] = (dst[j] + ((2731*(3*src[j] + 2*src[j+1] + 4*src[j+stride] + 3*src[j+stride+1] + 6)) >> 15) + 1) >> 1;
1359 } 1359 }
1360 src += stride; 1360 src += stride;
1361 dst += stride; 1361 dst += stride;
1362 } 1362 }
1363 } 1363 }
1364 1364
1365 static inline void avg_tpel_pixels_mc02_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){ 1365 static inline void avg_tpel_pixels_mc02_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){
1366 int i,j; 1366 int i,j;
1367 for (i=0; i < height; i++) { 1367 for (i=0; i < height; i++) {
1368 for (j=0; j < width; j++) { 1368 for (j=0; j < width; j++) {
1369 dst[j] = (dst[j] + ((683*(src[j] + 2*src[j+stride] + 1)) >> 11) + 1) >> 1; 1369 dst[j] = (dst[j] + ((683*(src[j] + 2*src[j+stride] + 1)) >> 11) + 1) >> 1;
1370 } 1370 }
1371 src += stride; 1371 src += stride;
1372 dst += stride; 1372 dst += stride;
1373 } 1373 }
1374 } 1374 }
1375 1375
1376 static inline void avg_tpel_pixels_mc21_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){ 1376 static inline void avg_tpel_pixels_mc21_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){
1377 int i,j; 1377 int i,j;
1378 for (i=0; i < height; i++) { 1378 for (i=0; i < height; i++) {
1379 for (j=0; j < width; j++) { 1379 for (j=0; j < width; j++) {
1380 dst[j] = (dst[j] + ((2731*(3*src[j] + 4*src[j+1] + 2*src[j+stride] + 3*src[j+stride+1] + 6)) >> 15) + 1) >> 1; 1380 dst[j] = (dst[j] + ((2731*(3*src[j] + 4*src[j+1] + 2*src[j+stride] + 3*src[j+stride+1] + 6)) >> 15) + 1) >> 1;
1381 } 1381 }
1382 src += stride; 1382 src += stride;
1383 dst += stride; 1383 dst += stride;
1384 } 1384 }
1385 } 1385 }
1386 1386
1387 static inline void avg_tpel_pixels_mc22_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){ 1387 static inline void avg_tpel_pixels_mc22_c(uint8_t *dst, const uint8_t *src, int stride, int width, int height){
1388 int i,j; 1388 int i,j;
1389 for (i=0; i < height; i++) { 1389 for (i=0; i < height; i++) {
1390 for (j=0; j < width; j++) { 1390 for (j=0; j < width; j++) {
1391 dst[j] = (dst[j] + ((2731*(2*src[j] + 3*src[j+1] + 3*src[j+stride] + 4*src[j+stride+1] + 6)) >> 15) + 1) >> 1; 1391 dst[j] = (dst[j] + ((2731*(2*src[j] + 3*src[j+1] + 3*src[j+stride] + 4*src[j+stride+1] + 6)) >> 15) + 1) >> 1;
1392 } 1392 }
1393 src += stride; 1393 src += stride;
1394 dst += stride; 1394 dst += stride;
1395 } 1395 }
1396 } 1396 }
3664 int i; 3664 int i;
3665 3665
3666 #ifdef CONFIG_ENCODERS 3666 #ifdef CONFIG_ENCODERS
3667 if(avctx->dct_algo==FF_DCT_FASTINT) { 3667 if(avctx->dct_algo==FF_DCT_FASTINT) {
3668 c->fdct = fdct_ifast; 3668 c->fdct = fdct_ifast;
3669 c->fdct248 = fdct_ifast248; 3669 c->fdct248 = fdct_ifast248;
3670 } 3670 }
3671 else if(avctx->dct_algo==FF_DCT_FAAN) { 3671 else if(avctx->dct_algo==FF_DCT_FAAN) {
3672 c->fdct = ff_faandct; 3672 c->fdct = ff_faandct;
3673 c->fdct248 = ff_faandct248; 3673 c->fdct248 = ff_faandct248;
3674 } 3674 }
3675 else { 3675 else {
3676 c->fdct = ff_jpeg_fdct_islow; //slow/accurate/default 3676 c->fdct = ff_jpeg_fdct_islow; //slow/accurate/default
3677 c->fdct248 = ff_fdct248_islow; 3677 c->fdct248 = ff_fdct248_islow;
3678 } 3678 }
3679 #endif //CONFIG_ENCODERS 3679 #endif //CONFIG_ENCODERS
3680 3680
3681 if(avctx->lowres==1){ 3681 if(avctx->lowres==1){
3682 if(avctx->idct_algo==FF_IDCT_INT || avctx->idct_algo==FF_IDCT_AUTO){ 3682 if(avctx->idct_algo==FF_IDCT_INT || avctx->idct_algo==FF_IDCT_AUTO){