Lines Matching refs:DCTSIZE
53 * This module is specialized to the case DCTSIZE = 8.
56 #if DCTSIZE != 8
173 for (ctr = 0; ctr < DCTSIZE; ctr++) {
241 dataptr += DCTSIZE; /* advance pointer to next row */
250 for (ctr = DCTSIZE-1; ctr >= 0; ctr--) {
255 tmp0 = dataptr[DCTSIZE*0] + dataptr[DCTSIZE*7];
256 tmp1 = dataptr[DCTSIZE*1] + dataptr[DCTSIZE*6];
257 tmp2 = dataptr[DCTSIZE*2] + dataptr[DCTSIZE*5];
258 tmp3 = dataptr[DCTSIZE*3] + dataptr[DCTSIZE*4];
266 tmp0 = dataptr[DCTSIZE*0] - dataptr[DCTSIZE*7];
267 tmp1 = dataptr[DCTSIZE*1] - dataptr[DCTSIZE*6];
268 tmp2 = dataptr[DCTSIZE*2] - dataptr[DCTSIZE*5];
269 tmp3 = dataptr[DCTSIZE*3] - dataptr[DCTSIZE*4];
271 dataptr[DCTSIZE*0] = (DCTELEM) RIGHT_SHIFT(tmp10 + tmp11, PASS1_BITS);
272 dataptr[DCTSIZE*4] = (DCTELEM) RIGHT_SHIFT(tmp10 - tmp11, PASS1_BITS);
277 dataptr[DCTSIZE*2] = (DCTELEM)
279 dataptr[DCTSIZE*6] = (DCTELEM)
307 dataptr[DCTSIZE*1] = (DCTELEM)
309 dataptr[DCTSIZE*3] = (DCTELEM)
311 dataptr[DCTSIZE*5] = (DCTELEM)
313 dataptr[DCTSIZE*7] = (DCTELEM)
395 dataptr += DCTSIZE; /* advance pointer to next row */
410 tmp0 = dataptr[DCTSIZE*0] + dataptr[DCTSIZE*6];
411 tmp1 = dataptr[DCTSIZE*1] + dataptr[DCTSIZE*5];
412 tmp2 = dataptr[DCTSIZE*2] + dataptr[DCTSIZE*4];
413 tmp3 = dataptr[DCTSIZE*3];
415 tmp10 = dataptr[DCTSIZE*0] - dataptr[DCTSIZE*6];
416 tmp11 = dataptr[DCTSIZE*1] - dataptr[DCTSIZE*5];
417 tmp12 = dataptr[DCTSIZE*2] - dataptr[DCTSIZE*4];
420 dataptr[DCTSIZE*0] = (DCTELEM)
429 dataptr[DCTSIZE*2] = (DCTELEM) DESCALE(z1 + z2 + z3, CONST_BITS+PASS1_BITS);
432 dataptr[DCTSIZE*4] = (DCTELEM)
435 dataptr[DCTSIZE*6] = (DCTELEM) DESCALE(z1 + z2, CONST_BITS+PASS1_BITS);
449 dataptr[DCTSIZE*1] = (DCTELEM) DESCALE(tmp0, CONST_BITS+PASS1_BITS);
450 dataptr[DCTSIZE*3] = (DCTELEM) DESCALE(tmp1, CONST_BITS+PASS1_BITS);
451 dataptr[DCTSIZE*5] = (DCTELEM) DESCALE(tmp2, CONST_BITS+PASS1_BITS);
516 dataptr += DCTSIZE; /* advance pointer to next row */
531 tmp0 = dataptr[DCTSIZE*0] + dataptr[DCTSIZE*5];
532 tmp11 = dataptr[DCTSIZE*1] + dataptr[DCTSIZE*4];
533 tmp2 = dataptr[DCTSIZE*2] + dataptr[DCTSIZE*3];
538 tmp0 = dataptr[DCTSIZE*0] - dataptr[DCTSIZE*5];
539 tmp1 = dataptr[DCTSIZE*1] - dataptr[DCTSIZE*4];
540 tmp2 = dataptr[DCTSIZE*2] - dataptr[DCTSIZE*3];
542 dataptr[DCTSIZE*0] = (DCTELEM)
545 dataptr[DCTSIZE*2] = (DCTELEM)
548 dataptr[DCTSIZE*4] = (DCTELEM)
556 dataptr[DCTSIZE*1] = (DCTELEM)
559 dataptr[DCTSIZE*3] = (DCTELEM)
562 dataptr[DCTSIZE*5] = (DCTELEM)
631 dataptr += DCTSIZE; /* advance pointer to next row */
646 tmp0 = dataptr[DCTSIZE*0] + dataptr[DCTSIZE*4];
647 tmp1 = dataptr[DCTSIZE*1] + dataptr[DCTSIZE*3];
648 tmp2 = dataptr[DCTSIZE*2];
653 tmp0 = dataptr[DCTSIZE*0] - dataptr[DCTSIZE*4];
654 tmp1 = dataptr[DCTSIZE*1] - dataptr[DCTSIZE*3];
656 dataptr[DCTSIZE*0] = (DCTELEM)
662 dataptr[DCTSIZE*2] = (DCTELEM) DESCALE(tmp11 + tmp10, CONST_BITS+PASS1_BITS);
663 dataptr[DCTSIZE*4] = (DCTELEM) DESCALE(tmp11 - tmp10, CONST_BITS+PASS1_BITS);
669 dataptr[DCTSIZE*1] = (DCTELEM)
672 dataptr[DCTSIZE*3] = (DCTELEM)
734 dataptr += DCTSIZE; /* advance pointer to next row */
747 tmp0 = dataptr[DCTSIZE*0] + dataptr[DCTSIZE*3] + (ONE << (PASS1_BITS-1));
748 tmp1 = dataptr[DCTSIZE*1] + dataptr[DCTSIZE*2];
750 tmp10 = dataptr[DCTSIZE*0] - dataptr[DCTSIZE*3];
751 tmp11 = dataptr[DCTSIZE*1] - dataptr[DCTSIZE*2];
753 dataptr[DCTSIZE*0] = (DCTELEM) RIGHT_SHIFT(tmp0 + tmp1, PASS1_BITS);
754 dataptr[DCTSIZE*2] = (DCTELEM) RIGHT_SHIFT(tmp0 - tmp1, PASS1_BITS);
762 dataptr[DCTSIZE*1] = (DCTELEM)
765 dataptr[DCTSIZE*3] = (DCTELEM)
821 dataptr += DCTSIZE; /* advance pointer to next row */
836 tmp0 = dataptr[DCTSIZE*0] + dataptr[DCTSIZE*2];
837 tmp1 = dataptr[DCTSIZE*1];
839 tmp2 = dataptr[DCTSIZE*0] - dataptr[DCTSIZE*2];
841 dataptr[DCTSIZE*0] = (DCTELEM)
844 dataptr[DCTSIZE*2] = (DCTELEM)
850 dataptr[DCTSIZE*1] = (DCTELEM)
894 data[DCTSIZE*0] = (DCTELEM) ((tmp0 + tmp2 - 4 * CENTERJSAMPLE) << 4);
895 data[DCTSIZE*1] = (DCTELEM) ((tmp0 - tmp2) << 4);
898 data[DCTSIZE*0+1] = (DCTELEM) ((tmp1 + tmp3) << 4);
899 data[DCTSIZE*1+1] = (DCTELEM) ((tmp1 - tmp3) << 4);
997 if (ctr != DCTSIZE) {
1000 dataptr += DCTSIZE; /* advance pointer to next row */
1014 for (ctr = DCTSIZE-1; ctr >= 0; ctr--) {
1017 tmp0 = dataptr[DCTSIZE*0] + wsptr[DCTSIZE*0];
1018 tmp1 = dataptr[DCTSIZE*1] + dataptr[DCTSIZE*7];
1019 tmp2 = dataptr[DCTSIZE*2] + dataptr[DCTSIZE*6];
1020 tmp3 = dataptr[DCTSIZE*3] + dataptr[DCTSIZE*5];
1021 tmp4 = dataptr[DCTSIZE*4];
1023 tmp10 = dataptr[DCTSIZE*0] - wsptr[DCTSIZE*0];
1024 tmp11 = dataptr[DCTSIZE*1] - dataptr[DCTSIZE*7];
1025 tmp12 = dataptr[DCTSIZE*2] - dataptr[DCTSIZE*6];
1026 tmp13 = dataptr[DCTSIZE*3] - dataptr[DCTSIZE*5];
1030 dataptr[DCTSIZE*0] = (DCTELEM)
1033 dataptr[DCTSIZE*6] = (DCTELEM)
1038 dataptr[DCTSIZE*2] = (DCTELEM)
1041 dataptr[DCTSIZE*4] = (DCTELEM)
1047 dataptr[DCTSIZE*3] = (DCTELEM)
1055 dataptr[DCTSIZE*1] = (DCTELEM)
1060 dataptr[DCTSIZE*5] = (DCTELEM)
1062 dataptr[DCTSIZE*7] = (DCTELEM)
1154 if (ctr != DCTSIZE) {
1157 dataptr += DCTSIZE; /* advance pointer to next row */
1171 for (ctr = DCTSIZE-1; ctr >= 0; ctr--) {
1174 tmp0 = dataptr[DCTSIZE*0] + wsptr[DCTSIZE*1];
1175 tmp1 = dataptr[DCTSIZE*1] + wsptr[DCTSIZE*0];
1176 tmp12 = dataptr[DCTSIZE*2] + dataptr[DCTSIZE*7];
1177 tmp3 = dataptr[DCTSIZE*3] + dataptr[DCTSIZE*6];
1178 tmp4 = dataptr[DCTSIZE*4] + dataptr[DCTSIZE*5];
1185 tmp0 = dataptr[DCTSIZE*0] - wsptr[DCTSIZE*1];
1186 tmp1 = dataptr[DCTSIZE*1] - wsptr[DCTSIZE*0];
1187 tmp2 = dataptr[DCTSIZE*2] - dataptr[DCTSIZE*7];
1188 tmp3 = dataptr[DCTSIZE*3] - dataptr[DCTSIZE*6];
1189 tmp4 = dataptr[DCTSIZE*4] - dataptr[DCTSIZE*5];
1191 dataptr[DCTSIZE*0] = (DCTELEM)
1195 dataptr[DCTSIZE*4] = (DCTELEM)
1200 dataptr[DCTSIZE*2] = (DCTELEM)
1203 dataptr[DCTSIZE*6] = (DCTELEM)
1211 dataptr[DCTSIZE*5] = (DCTELEM)
1215 dataptr[DCTSIZE*1] = (DCTELEM)
1225 dataptr[DCTSIZE*3] = (DCTELEM) DESCALE(tmp12 + tmp13, CONST_BITS+2);
1226 dataptr[DCTSIZE*7] = (DCTELEM) DESCALE(tmp12 - tmp13, CONST_BITS+2);
1328 if (ctr != DCTSIZE) {
1331 dataptr += DCTSIZE; /* advance pointer to next row */
1345 for (ctr = DCTSIZE-1; ctr >= 0; ctr--) {
1348 tmp0 = dataptr[DCTSIZE*0] + wsptr[DCTSIZE*2];
1349 tmp1 = dataptr[DCTSIZE*1] + wsptr[DCTSIZE*1];
1350 tmp2 = dataptr[DCTSIZE*2] + wsptr[DCTSIZE*0];
1351 tmp3 = dataptr[DCTSIZE*3] + dataptr[DCTSIZE*7];
1352 tmp4 = dataptr[DCTSIZE*4] + dataptr[DCTSIZE*6];
1353 tmp5 = dataptr[DCTSIZE*5];
1355 tmp10 = dataptr[DCTSIZE*0] - wsptr[DCTSIZE*2];
1356 tmp11 = dataptr[DCTSIZE*1] - wsptr[DCTSIZE*1];
1357 tmp12 = dataptr[DCTSIZE*2] - wsptr[DCTSIZE*0];
1358 tmp13 = dataptr[DCTSIZE*3] - dataptr[DCTSIZE*7];
1359 tmp14 = dataptr[DCTSIZE*4] - dataptr[DCTSIZE*6];
1361 dataptr[DCTSIZE*0] = (DCTELEM)
1375 dataptr[DCTSIZE*2] = (DCTELEM)
1379 DCTSIZE*4] = (DCTELEM)
1384 dataptr[DCTSIZE*6] = (DCTELEM)
1406 dataptr[DCTSIZE*1] = (DCTELEM) DESCALE(tmp0, CONST_BITS+2);
1407 dataptr[DCTSIZE*3] = (DCTELEM) DESCALE(tmp1, CONST_BITS+2);
1408 dataptr[DCTSIZE*5] = (DCTELEM) DESCALE(tmp2, CONST_BITS+2);
1409 dataptr[DCTSIZE*7] = (DCTELEM) DESCALE(tmp3, CONST_BITS+2);
1499 if (ctr != DCTSIZE) {
1502 dataptr += DCTSIZE; /* advance pointer to next row */
1516 for (ctr = DCTSIZE-1; ctr >= 0; ctr--) {
1519 tmp0 = dataptr[DCTSIZE*0] + wsptr[DCTSIZE*3];
1520 tmp1 = dataptr[DCTSIZE*1] + wsptr[DCTSIZE*2];
1521 tmp2 = dataptr[DCTSIZE*2] + wsptr[DCTSIZE*1];
1522 tmp3 = dataptr[DCTSIZE*3] + wsptr[DCTSIZE*0];
1523 tmp4 = dataptr[DCTSIZE*4] + dataptr[DCTSIZE*7];
1524 tmp5 = dataptr[DCTSIZE*5] + dataptr[DCTSIZE*6];
1533 tmp0 = dataptr[DCTSIZE*0] - wsptr[DCTSIZE*3];
1534 tmp1 = dataptr[DCTSIZE*1] - wsptr[DCTSIZE*2];
1535 tmp2 = dataptr[DCTSIZE*2] - wsptr[DCTSIZE*1];
1536 tmp3 = dataptr[DCTSIZE*3] - wsptr[DCTSIZE*0];
1537 tmp4 = dataptr[DCTSIZE*4] - dataptr[DCTSIZE*7];
1538 tmp5 = dataptr[DCTSIZE*5] - dataptr[DCTSIZE*6];
1540 dataptr[DCTSIZE*0] = (DCTELEM)
1543 dataptr[DCTSIZE*6] = (DCTELEM)
1546 dataptr[DCTSIZE*4] = (DCTELEM)
1549 dataptr[DCTSIZE*2] = (DCTELEM)
1571 dataptr[DCTSIZE*1] = (DCTELEM) DESCALE(tmp10, CONST_BITS+1);
1572 dataptr[DCTSIZE*3] = (DCTELEM) DESCALE(tmp11, CONST_BITS+1);
1573 dataptr[DCTSIZE*5] = (DCTELEM) DESCALE(tmp12, CONST_BITS+1);
1574 dataptr[DCTSIZE*7] = (DCTELEM) DESCALE(tmp13, CONST_BITS+1);
1683 if (ctr != DCTSIZE) {
1686 dataptr += DCTSIZE; /* advance pointer to next row */
1700 for (ctr = DCTSIZE-1; ctr >= 0; ctr--) {
1703 tmp0 = dataptr[DCTSIZE*0] + wsptr[DCTSIZE*4];
1704 tmp1 = dataptr[DCTSIZE*1] + wsptr[DCTSIZE*3];
1705 tmp2 = dataptr[DCTSIZE*2] + wsptr[DCTSIZE*2];
1706 tmp3 = dataptr[DCTSIZE*3] + wsptr[DCTSIZE*1];
1707 tmp4 = dataptr[DCTSIZE*4] + wsptr[DCTSIZE*0];
1708 tmp5 = dataptr[DCTSIZE*5] + dataptr[DCTSIZE*7];
1709 tmp6 = dataptr[DCTSIZE*6];
1711 tmp10 = dataptr[DCTSIZE*0] - wsptr[DCTSIZE*4];
1712 tmp11 = dataptr[DCTSIZE*1] - wsptr[DCTSIZE*3];
1713 tmp12 = dataptr[DCTSIZE*2] - wsptr[DCTSIZE*2];
1714 tmp13 = dataptr[DCTSIZE*3] - wsptr[DCTSIZE*1];
1715 tmp14 = dataptr[DCTSIZE*4] - wsptr[DCTSIZE*0];
1716 tmp15 = dataptr[DCTSIZE*5] - dataptr[DCTSIZE*7];
1718 dataptr[DCTSIZE*0] = (DCTELEM)
1729 dataptr[DCTSIZE*2] = (DCTELEM)
1744 dataptr[DCTSIZE*4] = (DCTELEM) DESCALE(z1 + z2, CONST_BITS+1);
1745 dataptr[DCTSIZE*6] = (DCTELEM) DESCALE(z1 - z2, CONST_BITS+1);
1770 dataptr[DCTSIZE*1] = (DCTELEM) DESCALE(tmp0, CONST_BITS+1);
1771 dataptr[DCTSIZE*3] = (DCTELEM) DESCALE(tmp1, CONST_BITS+1);
1772 dataptr[DCTSIZE*5] = (DCTELEM) DESCALE(tmp2, CONST_BITS+1);
1773 DCTSIZE*7] = (DCTELEM) DESCALE(tmp3, CONST_BITS+1);
1880 if (ctr != DCTSIZE) {
1883 dataptr += DCTSIZE; /* advance pointer to next row */
1897 for (ctr = DCTSIZE-1; ctr >= 0; ctr--) {
1900 tmp0 = dataptr[DCTSIZE*0] + wsptr[DCTSIZE*5];
1901 tmp1 = dataptr[DCTSIZE*1] + wsptr[DCTSIZE*4];
1902 tmp2 = dataptr[DCTSIZE*2] + wsptr[DCTSIZE*3];
1903 tmp13 = dataptr[DCTSIZE*3] + wsptr[DCTSIZE*2];
1904 tmp4 = dataptr[DCTSIZE*4] + wsptr[DCTSIZE*1];
1905 tmp5 = dataptr[DCTSIZE*5] + wsptr[DCTSIZE*0];
1906 tmp6 = dataptr[DCTSIZE*6] + dataptr[DCTSIZE*7];
1915 tmp0 = dataptr[DCTSIZE*0] - wsptr[DCTSIZE*5];
1916 tmp1 = dataptr[DCTSIZE*1] - wsptr[DCTSIZE*4];
1917 tmp2 = dataptr[DCTSIZE*2] - wsptr[DCTSIZE*3];
1918 tmp3 = dataptr[DCTSIZE*3] - wsptr[DCTSIZE*2];
1919 tmp4 = dataptr[DCTSIZE*4] - wsptr[DCTSIZE*1];
1920 tmp5 = dataptr[DCTSIZE*5] - wsptr[DCTSIZE*0];
1921 tmp6 = dataptr[DCTSIZE*6] - dataptr[DCTSIZE*7];
1923 dataptr[DCTSIZE*0] = (DCTELEM)
1928 dataptr[DCTSIZE*4] = (DCTELEM)
1936 dataptr[DCTSIZE*2] = (DCTELEM)
1940 dataptr[DCTSIZE*6] = (DCTELEM)
1949 dataptr[DCTSIZE*7] = (DCTELEM)
1959 dataptr[DCTSIZE*5] = (DCTELEM)
1965 dataptr[DCTSIZE*3] = (DCTELEM)
1969 dataptr[DCTSIZE*1] = (DCTELEM)
2072 if (ctr != DCTSIZE) {
2075 dataptr += DCTSIZE; /* advance pointer to next row */
2089 for (ctr = DCTSIZE-1; ctr >= 0; ctr--) {
2092 tmp0 = dataptr[DCTSIZE*0] + wsptr[DCTSIZE*6];
2093 tmp1 = dataptr[DCTSIZE*1] + wsptr[DCTSIZE*5];
2094 tmp2 = dataptr[DCTSIZE*2] + wsptr[DCTSIZE*4];
2095 tmp3 = dataptr[DCTSIZE*3] + wsptr[DCTSIZE*3];
2096 tmp4 = dataptr[DCTSIZE*4] + wsptr[DCTSIZE*2];
2097 tmp5 = dataptr[DCTSIZE*5] + wsptr[DCTSIZE*1];
2098 tmp6 = dataptr[DCTSIZE*6] + wsptr[DCTSIZE*0];
2099 tmp7 = dataptr[DCTSIZE*7];
2101 tmp10 = dataptr[DCTSIZE*0] - wsptr[DCTSIZE*6];
2102 tmp11 = dataptr[DCTSIZE*1] - wsptr[DCTSIZE*5];
2103 tmp12 = dataptr[DCTSIZE*2] - wsptr[DCTSIZE*4];
2104 tmp13 = dataptr[DCTSIZE*3] - wsptr[DCTSIZE*3];
2105 tmp14 = dataptr[DCTSIZE*4] - wsptr[DCTSIZE*2];
2106 tmp15 = dataptr[DCTSIZE*5] - wsptr[DCTSIZE*1];
2107 tmp16 = dataptr[DCTSIZE*6] - wsptr[DCTSIZE*0];
2112 dataptr[DCTSIZE*0] = (DCTELEM)
2116 dataptr[DCTSIZE*6] = (DCTELEM)
2129 dataptr[DCTSIZE*2] = (DCTELEM) DESCALE(z1 + z3, CONST_BITS+2);
2130 dataptr[DCTSIZE*4] = (DCTELEM) DESCALE(z2 + z3, CONST_BITS+2);
2149 dataptr[DCTSIZE*1] = (DCTELEM) DESCALE(tmp0, CONST_BITS+2);
2150 dataptr[DCTSIZE*3] = (DCTELEM) DESCALE(tmp1, CONST_BITS+2);
2151 dataptr[DCTSIZE*5] = (DCTELEM) DESCALE(tmp2, CONST_BITS+2);
2152 dataptr[DCTSIZE*7] = (DCTELEM) DESCALE(tmp3, CONST_BITS+2);
2266 if (ctr != DCTSIZE) {
2267 if (ctr == DCTSIZE * 2)
2269 dataptr += DCTSIZE; /* advance pointer to next row */
2282 for (ctr = DCTSIZE-1; ctr >= 0; ctr--) {
2285 tmp0 = dataptr[DCTSIZE*0] + wsptr[DCTSIZE*7];
2286 tmp1 = dataptr[DCTSIZE*1] + wsptr[DCTSIZE*6];
2287 tmp2 = dataptr[DCTSIZE*2] + wsptr[DCTSIZE*5];
2288 tmp3 = dataptr[DCTSIZE*3] + wsptr[DCTSIZE*4];
2289 tmp4 = dataptr[DCTSIZE*4] + wsptr[DCTSIZE*3];
2290 tmp5 = dataptr[DCTSIZE*5] + wsptr[DCTSIZE*2];
2291 tmp6 = dataptr[DCTSIZE*6] + wsptr[DCTSIZE*1];
2292 tmp7 = dataptr[DCTSIZE*7] + wsptr[DCTSIZE*0];
2303 tmp0 = dataptr[DCTSIZE*0] - wsptr[DCTSIZE*7];
2304 tmp1 = dataptr[DCTSIZE*1] - wsptr[DCTSIZE*6];
2305 tmp2 = dataptr[DCTSIZE*2] - wsptr[DCTSIZE*5];
2306 tmp3 = dataptr[DCTSIZE*3] - wsptr[DCTSIZE*4];
2307 tmp4 = dataptr[DCTSIZE*4] - wsptr[DCTSIZE*3];
2308 tmp5 = dataptr[DCTSIZE*5] - wsptr[DCTSIZE*2];
2309 tmp6 = dataptr[DCTSIZE*6] - wsptr[DCTSIZE*1];
2310 tmp7 = dataptr[DCTSIZE*7] - wsptr[DCTSIZE*0];
2312 dataptr[DCTSIZE*0] = (DCTELEM)
2314 dataptr[DCTSIZE*4] = (DCTELEM)
2322 dataptr[DCTSIZE*2] = (DCTELEM)
2326 dataptr[DCTSIZE*6] = (DCTELEM)
2355 dataptr[DCTSIZE*1] = (DCTELEM) DESCALE(tmp10, CONST_BITS+PASS1_BITS+2);
2356 dataptr[DCTSIZE*3] = (DCTELEM) DESCALE(tmp11, CONST_BITS+PASS1_BITS+2);
2357 dataptr[DCTSIZE*5] = (DCTELEM) DESCALE(tmp12, CONST_BITS+PASS1_BITS+2);
2358 dataptr[DCTSIZE*7] = (DCTELEM) DESCALE(tmp13, CONST_BITS+PASS1_BITS+2);
2390 for (ctr = 0; ctr < DCTSIZE; ctr++) {
2471 dataptr += DCTSIZE; /* advance pointer to next row */
2481 for (ctr = DCTSIZE-1; ctr >= 0; ctr--) {
2486 tmp0 = dataptr[DCTSIZE*0] + dataptr[DCTSIZE*7];
2487 tmp1 = dataptr[DCTSIZE*1] + dataptr[DCTSIZE*6];
2488 tmp2 = dataptr[DCTSIZE*2] + dataptr[DCTSIZE*5];
2489 tmp3 = dataptr[DCTSIZE*3] + dataptr[DCTSIZE*4];
2496 tmp0 = dataptr[DCTSIZE*0] - dataptr[DCTSIZE*7];
2497 tmp1 = dataptr[DCTSIZE*1] - dataptr[DCTSIZE*6];
2498 tmp2 = dataptr[DCTSIZE*2] - dataptr[DCTSIZE*5];
2499 tmp3 = dataptr[DCTSIZE*3] - dataptr[DCTSIZE*4];
2501 dataptr[DCTSIZE*0] = (DCTELEM) DESCALE(tmp10 + tmp11, PASS1_BITS+1);
2502 dataptr[DCTSIZE*4] = (DCTELEM) DESCALE(tmp10 - tmp11, PASS1_BITS+1);
2505 dataptr[DCTSIZE*2] = (DCTELEM) DESCALE(z1 + MULTIPLY(tmp12, FIX_0_765366865),
2507 dataptr[DCTSIZE*6] = (DCTELEM) DESCALE(z1 - MULTIPLY(tmp13, FIX_1_847759065),
2533 dataptr[DCTSIZE*1] = (DCTELEM) DESCALE(tmp0 + tmp10 + tmp12,
2535 dataptr[DCTSIZE*3] = (DCTELEM) DESCALE(tmp1 + tmp11 + tmp13,
2537 dataptr[DCTSIZE*5] = (DCTELEM) DESCALE(tmp2 + tmp11 + tmp12,
2539 dataptr[DCTSIZE*7] = (DCTELEM) DESCALE(tmp3 + tmp10 + tmp13,
2565 MEMZERO(&data[DCTSIZE*7], SIZEOF(DCTELEM) * DCTSIZE);
2648 dataptr += DCTSIZE; /* advance pointer to next row */
2660 for (ctr = DCTSIZE-1; ctr >= 0; ctr--) {
2663 tmp0 = dataptr[DCTSIZE*0] + dataptr[DCTSIZE*6];
2664 tmp1 = dataptr[DCTSIZE*1] + dataptr[DCTSIZE*5];
2665 tmp2 = dataptr[DCTSIZE*2] + dataptr[DCTSIZE*4];
2666 tmp3 = dataptr[DCTSIZE*3];
2668 tmp10 = dataptr[DCTSIZE*0] - dataptr[DCTSIZE*6];
2669 tmp11 = dataptr[DCTSIZE*1] - dataptr[DCTSIZE*5];
2670 tmp12 = dataptr[DCTSIZE*2] - dataptr[DCTSIZE*4];
2673 dataptr[DCTSIZE*0] = (DCTELEM)
2682 dataptr[DCTSIZE*2] = (DCTELEM) DESCALE(z1 + z2 + z3, CONST_BITS+PASS1_BITS+1);
2685 dataptr[DCTSIZE*4] = (DCTELEM)
2688 dataptr[DCTSIZE*6] = (DCTELEM) DESCALE(z1 + z2, CONST_BITS+PASS1_BITS+1);
2702 dataptr[DCTSIZE*1] = (DCTELEM) DESCALE(tmp0, CONST_BITS+PASS1_BITS+1);
2703 dataptr[DCTSIZE*3] = (DCTELEM) DESCALE(tmp1, CONST_BITS+PASS1_BITS+1);
2704 dataptr[DCTSIZE*5] = (DCTELEM) DESCALE(tmp2, CONST_BITS+PASS1_BITS+1);
2728 MEMZERO(&data[DCTSIZE*6], SIZEOF(DCTELEM) * DCTSIZE * 2);
2795 dataptr += DCTSIZE; /* advance pointer to next row */
2807 for (ctr = DCTSIZE-1; ctr >= 0; ctr--) {
2810 tmp0 = dataptr[DCTSIZE*0] + dataptr[DCTSIZE*5];
2811 tmp11 = dataptr[DCTSIZE*1] + dataptr[DCTSIZE*4];
2812 tmp2 = dataptr[DCTSIZE*2] + dataptr[DCTSIZE*3];
2817 tmp0 = dataptr[DCTSIZE*0] - dataptr[DCTSIZE*5];
2818 tmp1 = dataptr[DCTSIZE*1] - dataptr[DCTSIZE*4];
2819 tmp2 = dataptr[DCTSIZE*2] - dataptr[DCTSIZE*3];
2821 dataptr[DCTSIZE*0] = (DCTELEM)
2824 dataptr[DCTSIZE*2] = (DCTELEM)
2827 dataptr[DCTSIZE*4] = (DCTELEM)
2835 dataptr[DCTSIZE*1] = (DCTELEM)
2838 dataptr[DCTSIZE*3] = (DCTELEM)
2841 dataptr[DCTSIZE*5] = (DCTELEM)
2867 MEMZERO(&data[DCTSIZE*5], SIZEOF(DCTELEM) * DCTSIZE * 3);
2932 dataptr += DCTSIZE; /* advance pointer to next row */
2944 for (ctr = DCTSIZE-1; ctr >= 0; ctr--) {
2947 tmp0 = dataptr[DCTSIZE*0] + dataptr[DCTSIZE*4];
2948 tmp1 = dataptr[DCTSIZE*1] + dataptr[DCTSIZE*3];
2949 tmp2 = dataptr[DCTSIZE*2];
2954 tmp0 = dataptr[DCTSIZE*0] - dataptr[DCTSIZE*4];
2955 tmp1 = dataptr[DCTSIZE*1] - dataptr[DCTSIZE*3];
2957 dataptr[DCTSIZE*0] = (DCTELEM)
2963 dataptr[DCTSIZE*2] = (DCTELEM) DESCALE(tmp11 + tmp10, CONST_BITS+PASS1_BITS);
2964 dataptr[DCTSIZE*4] = (DCTELEM) DESCALE(tmp11 - tmp10, CONST_BITS+PASS1_BITS);
2970 dataptr[DCTSIZE*1] = (DCTELEM)
2973 dataptr[DCTSIZE*3] = (DCTELEM)
3000 MEMZERO(&data[DCTSIZE*4], SIZEOF(DCTELEM) * DCTSIZE * 4);
3077 dataptr += DCTSIZE; /* advance pointer to next row */
3087 for (ctr = DCTSIZE-1; ctr >= 0; ctr--) {
3091 tmp0 = dataptr[DCTSIZE*0] + dataptr[DCTSIZE*3] + (ONE << (PASS1_BITS-1));
3092 tmp1 = dataptr[DCTSIZE*1] + dataptr[DCTSIZE*2];
3094 tmp10 = dataptr[DCTSIZE*0] - dataptr[DCTSIZE*3];
3095 tmp11 = dataptr[DCTSIZE*1] - dataptr[DCTSIZE*2];
3097 dataptr[DCTSIZE*0] = (DCTELEM) RIGHT_SHIFT(tmp0 + tmp1, PASS1_BITS);
3098 dataptr[DCTSIZE*2] = (DCTELEM) RIGHT_SHIFT(tmp0 - tmp1, PASS1_BITS);
3106 dataptr[DCTSIZE*1] = (DCTELEM)
3109 dataptr[DCTSIZE*3] = (DCTELEM)
3180 dataptr += DCTSIZE; /* advance pointer to next row */
3195 tmp0 = dataptr[DCTSIZE*0] + dataptr[DCTSIZE*2];
3196 tmp1 = dataptr[DCTSIZE*1];
3198 tmp2 = dataptr[DCTSIZE*0] - dataptr[DCTSIZE*2];
3200 dataptr[DCTSIZE*0] = (DCTELEM)
3203 dataptr[DCTSIZE*2] = (DCTELEM)
3209 dataptr[DCTSIZE*1] = (DCTELEM)
3274 dataptr += DCTSIZE; /* advance pointer to next row */
3287 tmp0 = dataptr[DCTSIZE*0] + (ONE << (PASS1_BITS-1));
3288 tmp1 = dataptr[DCTSIZE*1];
3290 dataptr[DCTSIZE*0] = (DCTELEM) RIGHT_SHIFT(tmp0 + tmp1, PASS1_BITS);
3294 dataptr[DCTSIZE*1] = (DCTELEM) RIGHT_SHIFT(tmp0 - tmp1, PASS1_BITS);
3421 if (ctr != DCTSIZE) {
3422 if (ctr == DCTSIZE * 2)
3424 dataptr += DCTSIZE; /* advance pointer to next row */
3438 for (ctr = DCTSIZE-1; ctr >= 0; ctr--) {
3441 tmp0 = dataptr[DCTSIZE*0] + wsptr[DCTSIZE*7];
3442 tmp1 = dataptr[DCTSIZE*1] + wsptr[DCTSIZE*6];
3443 tmp2 = dataptr[DCTSIZE*2] + wsptr[DCTSIZE*5];
3444 tmp3 = dataptr[DCTSIZE*3] + wsptr[DCTSIZE*4];
3445 tmp4 = dataptr[DCTSIZE*4] + wsptr[DCTSIZE*3];
3446 tmp5 = dataptr[DCTSIZE*5] + wsptr[DCTSIZE*2];
3447 tmp6 = dataptr[DCTSIZE*6] + wsptr[DCTSIZE*1];
3448 tmp7 = dataptr[DCTSIZE*7] + wsptr[DCTSIZE*0];
3459 tmp0 = dataptr[DCTSIZE*0] - wsptr[DCTSIZE*7];
3460 tmp1 = dataptr[DCTSIZE*1] - wsptr[DCTSIZE*6];
3461 tmp2 = dataptr[DCTSIZE*2] - wsptr[DCTSIZE*5];
3462 tmp3 = dataptr[DCTSIZE*3] - wsptr[DCTSIZE*4];
3463 tmp4 = dataptr[DCTSIZE*4] - wsptr[DCTSIZE*3];
3464 tmp5 = dataptr[DCTSIZE*5] - wsptr[DCTSIZE*2];
3465 tmp6 = dataptr[DCTSIZE*6] - wsptr[DCTSIZE*1];
3466 tmp7 = dataptr[DCTSIZE*7] - wsptr[DCTSIZE*0];
3468 dataptr[DCTSIZE*0] = (DCTELEM)
3470 dataptr[DCTSIZE*4] = (DCTELEM)
3478 DCTSIZE*2] = (DCTELEM)
3482 dataptr[DCTSIZE*6] = (DCTELEM)
3511 dataptr[DCTSIZE*1] = (DCTELEM) DESCALE(tmp10, CONST_BITS+PASS1_BITS+1);
3512 dataptr[DCTSIZE*3] = (DCTELEM) DESCALE(tmp11, CONST_BITS+PASS1_BITS+1);
3513 dataptr[DCTSIZE*5] = (DCTELEM) DESCALE(tmp12, CONST_BITS+PASS1_BITS+1);
3514 dataptr[DCTSIZE*7] = (DCTELEM) DESCALE(tmp13, CONST_BITS+PASS1_BITS+1);
3601 if (ctr != DCTSIZE) {
3604 dataptr += DCTSIZE; /* advance pointer to next row */
3622 tmp0 = dataptr[DCTSIZE*0] + wsptr[DCTSIZE*5];
3623 tmp1 = dataptr[DCTSIZE*1] + wsptr[DCTSIZE*4];
3624 tmp2 = dataptr[DCTSIZE*2] + wsptr[DCTSIZE*3];
3625 tmp13 = dataptr[DCTSIZE*3] + wsptr[DCTSIZE*2];
3626 tmp4 = dataptr[DCTSIZE*4] + wsptr[DCTSIZE*1];
3627 tmp5 = dataptr[DCTSIZE*5] + wsptr[DCTSIZE*0];
3628 tmp6 = dataptr[DCTSIZE*6] + dataptr[DCTSIZE*7];
3637 tmp0 = dataptr[DCTSIZE*0] - wsptr[DCTSIZE*5];
3638 tmp1 = dataptr[DCTSIZE*1] - wsptr[DCTSIZE*4];
3639 tmp2 = dataptr[DCTSIZE*2] - wsptr[DCTSIZE*3];
3640 tmp3 = dataptr[DCTSIZE*3] - wsptr[DCTSIZE*2];
3641 tmp4 = dataptr[DCTSIZE*4] - wsptr[DCTSIZE*1];
3642 tmp5 = dataptr[DCTSIZE*5] - wsptr[DCTSIZE*0];
3643 tmp6 = dataptr[DCTSIZE*6] - dataptr[DCTSIZE*7];
3645 dataptr[DCTSIZE*0] = (DCTELEM)
3650 dataptr[DCTSIZE*4] = (DCTELEM)
3658 dataptr[DCTSIZE*2] = (DCTELEM)
3662 dataptr[DCTSIZE*6] = (DCTELEM)
3671 dataptr[DCTSIZE*7] = (DCTELEM)
3681 dataptr[DCTSIZE*5] = (DCTELEM)
3687 dataptr[DCTSIZE*3] = (DCTELEM)
3691 dataptr[DCTSIZE*1] = (DCTELEM)
3768 if (ctr != DCTSIZE) {
3771 dataptr += DCTSIZE; /* advance pointer to next row */
3789 tmp0 = dataptr[DCTSIZE*0] + wsptr[DCTSIZE*3];
3790 tmp1 = dataptr[DCTSIZE*1] + wsptr[DCTSIZE*2];
3791 tmp2 = dataptr[DCTSIZE*2] + wsptr[DCTSIZE*1];
3792 tmp3 = dataptr[DCTSIZE*3] + wsptr[DCTSIZE*0];
3793 tmp4 = dataptr[DCTSIZE*4] + dataptr[DCTSIZE*7];
3794 tmp5 = dataptr[DCTSIZE*5] + dataptr[DCTSIZE*6];
3803 tmp0 = dataptr[DCTSIZE*0] - wsptr[DCTSIZE*3];
3804 tmp1 = dataptr[DCTSIZE*1] - wsptr[DCTSIZE*2];
3805 tmp2 = dataptr[DCTSIZE*2] - wsptr[DCTSIZE*1];
3806 tmp3 = dataptr[DCTSIZE*3] - wsptr[DCTSIZE*0];
3807 tmp4 = dataptr[DCTSIZE*4] - dataptr[DCTSIZE*7];
3808 tmp5 = dataptr[DCTSIZE*5] - dataptr[DCTSIZE*6];
3810 dataptr[DCTSIZE*0] = (DCTELEM)
3813 dataptr[DCTSIZE*6] = (DCTELEM)
3816 dataptr[DCTSIZE*4] = (DCTELEM)
3819 dataptr[DCTSIZE*2] = (DCTELEM)
3841 dataptr[DCTSIZE*1] = (DCTELEM) DESCALE(tmp10, CONST_BITS+PASS1_BITS);
3842 dataptr[DCTSIZE*3] = (DCTELEM) DESCALE(tmp11, CONST_BITS+PASS1_BITS);
3843 dataptr[DCTSIZE*5] = (DCTELEM) DESCALE(tmp12, CONST_BITS+PASS1_BITS);
3844 dataptr[DCTSIZE*7] = (DCTELEM) DESCALE(tmp13, CONST_BITS+PASS1_BITS);
3917 if (ctr != DCTSIZE) {
3920 dataptr += DCTSIZE; /* advance pointer to next row */
3938 tmp0 = dataptr[DCTSIZE*0] + wsptr[DCTSIZE*1];
3939 tmp1 = dataptr[DCTSIZE*1] + wsptr[DCTSIZE*0];
3940 tmp12 = dataptr[DCTSIZE*2] + dataptr[DCTSIZE*7];
3941 tmp3 = dataptr[DCTSIZE*3] + dataptr[DCTSIZE*6];
3942 tmp4 = dataptr[DCTSIZE*4] + dataptr[DCTSIZE*5];
3949 tmp0 = dataptr[DCTSIZE*0] - wsptr[DCTSIZE*1];
3950 tmp1 = dataptr[DCTSIZE*1] - wsptr[DCTSIZE*0];
3951 tmp2 = dataptr[DCTSIZE*2] - dataptr[DCTSIZE*7];
3952 tmp3 = dataptr[DCTSIZE*3] - dataptr[DCTSIZE*6];
3953 tmp4 = dataptr[DCTSIZE*4] - dataptr[DCTSIZE*5];
3955 dataptr[DCTSIZE*0] = (DCTELEM)
3959 dataptr[DCTSIZE*4] = (DCTELEM)
3964 dataptr[DCTSIZE*2] = (DCTELEM)
3967 dataptr[DCTSIZE*6] = (DCTELEM)
3975 dataptr[DCTSIZE*5] = (DCTELEM)
3979 dataptr[DCTSIZE*1] = (DCTELEM)
3989 dataptr[DCTSIZE*3] = (DCTELEM) DESCALE(tmp12 + tmp13, CONST_BITS+PASS1_BITS);
3990 dataptr[DCTSIZE*7] = (DCTELEM) DESCALE(tmp12 - tmp13, CONST_BITS+PASS1_BITS);
4025 for (ctr = 0; ctr < DCTSIZE; ctr++) {
4054 dataptr += DCTSIZE; /* advance pointer to next row */
4068 tmp0 = dataptr[DCTSIZE*0] + dataptr[DCTSIZE*7];
4069 tmp1 = dataptr[DCTSIZE*1] + dataptr[DCTSIZE*6];
4070 tmp2 = dataptr[DCTSIZE*2] + dataptr[DCTSIZE*5];
4071 tmp3 = dataptr[DCTSIZE*3] + dataptr[DCTSIZE*4];
4079 tmp0 = dataptr[DCTSIZE*0] - dataptr[DCTSIZE*7];
4080 tmp1 = dataptr[DCTSIZE*1] - dataptr[DCTSIZE*6];
4081 tmp2 = dataptr[DCTSIZE*2] - dataptr[DCTSIZE*5];
4082 tmp3 = dataptr[DCTSIZE*3] - dataptr[DCTSIZE*4];
4084 dataptr[DCTSIZE*0] = (DCTELEM) RIGHT_SHIFT(tmp10 + tmp11, PASS1_BITS);
4085 dataptr[DCTSIZE*4] = (DCTELEM) RIGHT_SHIFT(tmp10 - tmp11, PASS1_BITS);
4090 dataptr[DCTSIZE*2] = (DCTELEM)
4092 dataptr[DCTSIZE*6] = (DCTELEM)
4120 dataptr[DCTSIZE*1] = (DCTELEM)
4122 dataptr[DCTSIZE*3] = (DCTELEM)
4124 dataptr[DCTSIZE*5] = (DCTELEM)
4126 dataptr[DCTSIZE*7] = (DCTELEM)
4184 dataptr += DCTSIZE; /* advance pointer to next row */
4199 tmp0 = dataptr[DCTSIZE*0] + dataptr[DCTSIZE*5];
4200 tmp11 = dataptr[DCTSIZE*1] + dataptr[DCTSIZE*4];
4201 tmp2 = dataptr[DCTSIZE*2] + dataptr[DCTSIZE*3];
4206 tmp0 = dataptr[DCTSIZE*0] - dataptr[DCTSIZE*5];
4207 tmp1 = dataptr[DCTSIZE*1] - dataptr[DCTSIZE*4];
4208 tmp2 = dataptr[DCTSIZE*2] - dataptr[DCTSIZE*3];
4210 dataptr[DCTSIZE*0] = (DCTELEM)
4213 dataptr[DCTSIZE*2] = (DCTELEM)
4216 dataptr[DCTSIZE*4] = (DCTELEM)
4224 dataptr[DCTSIZE*1] = (DCTELEM)
4227 dataptr[DCTSIZE*3] = (DCTELEM)
4230 dataptr[DCTSIZE*5] = (DCTELEM)
4278 dataptr += DCTSIZE; /* advance pointer to next row */
4291 tmp0 = dataptr[DCTSIZE*0] + dataptr[DCTSIZE*3];
4292 tmp1 = dataptr[DCTSIZE*1] + dataptr[DCTSIZE*2];
4294 tmp10 = dataptr[DCTSIZE*0] - dataptr[DCTSIZE*3];
4295 tmp11 = dataptr[DCTSIZE*1] - dataptr[DCTSIZE*2];
4297 dataptr[DCTSIZE*0] = (DCTELEM) (tmp0 + tmp1);
4298 dataptr[DCTSIZE*2] = (DCTELEM) (tmp0 - tmp1);
4306 dataptr[DCTSIZE*1] = (DCTELEM)
4309 dataptr[DCTSIZE*3] = (DCTELEM)
4341 data[DCTSIZE*0] = (DCTELEM) ((tmp0 + tmp1 - 2 * CENTERJSAMPLE) << 5);
4344 data[DCTSIZE*1] = (DCTELEM) ((tmp0 - tmp1) << 5);