1*dfc6aa5cSAndroid Build Coastguard Worker /* 2*dfc6aa5cSAndroid Build Coastguard Worker * jidctflt.c 3*dfc6aa5cSAndroid Build Coastguard Worker * 4*dfc6aa5cSAndroid Build Coastguard Worker * This file was part of the Independent JPEG Group's software: 5*dfc6aa5cSAndroid Build Coastguard Worker * Copyright (C) 1994-1998, Thomas G. Lane. 6*dfc6aa5cSAndroid Build Coastguard Worker * Modified 2010 by Guido Vollbeding. 7*dfc6aa5cSAndroid Build Coastguard Worker * libjpeg-turbo Modifications: 8*dfc6aa5cSAndroid Build Coastguard Worker * Copyright (C) 2014, D. R. Commander. 9*dfc6aa5cSAndroid Build Coastguard Worker * For conditions of distribution and use, see the accompanying README.ijg 10*dfc6aa5cSAndroid Build Coastguard Worker * file. 11*dfc6aa5cSAndroid Build Coastguard Worker * 12*dfc6aa5cSAndroid Build Coastguard Worker * This file contains a floating-point implementation of the 13*dfc6aa5cSAndroid Build Coastguard Worker * inverse DCT (Discrete Cosine Transform). In the IJG code, this routine 14*dfc6aa5cSAndroid Build Coastguard Worker * must also perform dequantization of the input coefficients. 15*dfc6aa5cSAndroid Build Coastguard Worker * 16*dfc6aa5cSAndroid Build Coastguard Worker * This implementation should be more accurate than either of the integer 17*dfc6aa5cSAndroid Build Coastguard Worker * IDCT implementations. However, it may not give the same results on all 18*dfc6aa5cSAndroid Build Coastguard Worker * machines because of differences in roundoff behavior. Speed will depend 19*dfc6aa5cSAndroid Build Coastguard Worker * on the hardware's floating point capacity. 20*dfc6aa5cSAndroid Build Coastguard Worker * 21*dfc6aa5cSAndroid Build Coastguard Worker * A 2-D IDCT can be done by 1-D IDCT on each column followed by 1-D IDCT 22*dfc6aa5cSAndroid Build Coastguard Worker * on each row (or vice versa, but it's more convenient to emit a row at 23*dfc6aa5cSAndroid Build Coastguard Worker * a time). Direct algorithms are also available, but they are much more 24*dfc6aa5cSAndroid Build Coastguard Worker * complex and seem not to be any faster when reduced to code. 25*dfc6aa5cSAndroid Build Coastguard Worker * 26*dfc6aa5cSAndroid Build Coastguard Worker * This implementation is based on Arai, Agui, and Nakajima's algorithm for 27*dfc6aa5cSAndroid Build Coastguard Worker * scaled DCT. Their original paper (Trans. IEICE E-71(11):1095) is in 28*dfc6aa5cSAndroid Build Coastguard Worker * Japanese, but the algorithm is described in the Pennebaker & Mitchell 29*dfc6aa5cSAndroid Build Coastguard Worker * JPEG textbook (see REFERENCES section in file README.ijg). The following 30*dfc6aa5cSAndroid Build Coastguard Worker * code is based directly on figure 4-8 in P&M. 31*dfc6aa5cSAndroid Build Coastguard Worker * While an 8-point DCT cannot be done in less than 11 multiplies, it is 32*dfc6aa5cSAndroid Build Coastguard Worker * possible to arrange the computation so that many of the multiplies are 33*dfc6aa5cSAndroid Build Coastguard Worker * simple scalings of the final outputs. These multiplies can then be 34*dfc6aa5cSAndroid Build Coastguard Worker * folded into the multiplications or divisions by the JPEG quantization 35*dfc6aa5cSAndroid Build Coastguard Worker * table entries. The AA&N method leaves only 5 multiplies and 29 adds 36*dfc6aa5cSAndroid Build Coastguard Worker * to be done in the DCT itself. 37*dfc6aa5cSAndroid Build Coastguard Worker * The primary disadvantage of this method is that with a fixed-point 38*dfc6aa5cSAndroid Build Coastguard Worker * implementation, accuracy is lost due to imprecise representation of the 39*dfc6aa5cSAndroid Build Coastguard Worker * scaled quantization values. However, that problem does not arise if 40*dfc6aa5cSAndroid Build Coastguard Worker * we use floating point arithmetic. 41*dfc6aa5cSAndroid Build Coastguard Worker */ 42*dfc6aa5cSAndroid Build Coastguard Worker 43*dfc6aa5cSAndroid Build Coastguard Worker #define JPEG_INTERNALS 44*dfc6aa5cSAndroid Build Coastguard Worker #include "jinclude.h" 45*dfc6aa5cSAndroid Build Coastguard Worker #include "jpeglib.h" 46*dfc6aa5cSAndroid Build Coastguard Worker #include "jdct.h" /* Private declarations for DCT subsystem */ 47*dfc6aa5cSAndroid Build Coastguard Worker 48*dfc6aa5cSAndroid Build Coastguard Worker #ifdef DCT_FLOAT_SUPPORTED 49*dfc6aa5cSAndroid Build Coastguard Worker 50*dfc6aa5cSAndroid Build Coastguard Worker 51*dfc6aa5cSAndroid Build Coastguard Worker /* 52*dfc6aa5cSAndroid Build Coastguard Worker * This module is specialized to the case DCTSIZE = 8. 53*dfc6aa5cSAndroid Build Coastguard Worker */ 54*dfc6aa5cSAndroid Build Coastguard Worker 55*dfc6aa5cSAndroid Build Coastguard Worker #if DCTSIZE != 8 56*dfc6aa5cSAndroid Build Coastguard Worker Sorry, this code only copes with 8x8 DCTs. /* deliberate syntax err */ 57*dfc6aa5cSAndroid Build Coastguard Worker #endif 58*dfc6aa5cSAndroid Build Coastguard Worker 59*dfc6aa5cSAndroid Build Coastguard Worker 60*dfc6aa5cSAndroid Build Coastguard Worker /* Dequantize a coefficient by multiplying it by the multiplier-table 61*dfc6aa5cSAndroid Build Coastguard Worker * entry; produce a float result. 62*dfc6aa5cSAndroid Build Coastguard Worker */ 63*dfc6aa5cSAndroid Build Coastguard Worker 64*dfc6aa5cSAndroid Build Coastguard Worker #define DEQUANTIZE(coef, quantval) (((FAST_FLOAT)(coef)) * (quantval)) 65*dfc6aa5cSAndroid Build Coastguard Worker 66*dfc6aa5cSAndroid Build Coastguard Worker 67*dfc6aa5cSAndroid Build Coastguard Worker /* 68*dfc6aa5cSAndroid Build Coastguard Worker * Perform dequantization and inverse DCT on one block of coefficients. 69*dfc6aa5cSAndroid Build Coastguard Worker */ 70*dfc6aa5cSAndroid Build Coastguard Worker 71*dfc6aa5cSAndroid Build Coastguard Worker GLOBAL(void) 72*dfc6aa5cSAndroid Build Coastguard Worker jpeg_idct_float(j_decompress_ptr cinfo, jpeg_component_info *compptr, 73*dfc6aa5cSAndroid Build Coastguard Worker JCOEFPTR coef_block, JSAMPARRAY output_buf, 74*dfc6aa5cSAndroid Build Coastguard Worker JDIMENSION output_col) 75*dfc6aa5cSAndroid Build Coastguard Worker { 76*dfc6aa5cSAndroid Build Coastguard Worker FAST_FLOAT tmp0, tmp1, tmp2, tmp3, tmp4, tmp5, tmp6, tmp7; 77*dfc6aa5cSAndroid Build Coastguard Worker FAST_FLOAT tmp10, tmp11, tmp12, tmp13; 78*dfc6aa5cSAndroid Build Coastguard Worker FAST_FLOAT z5, z10, z11, z12, z13; 79*dfc6aa5cSAndroid Build Coastguard Worker JCOEFPTR inptr; 80*dfc6aa5cSAndroid Build Coastguard Worker FLOAT_MULT_TYPE *quantptr; 81*dfc6aa5cSAndroid Build Coastguard Worker FAST_FLOAT *wsptr; 82*dfc6aa5cSAndroid Build Coastguard Worker JSAMPROW outptr; 83*dfc6aa5cSAndroid Build Coastguard Worker JSAMPLE *range_limit = cinfo->sample_range_limit; 84*dfc6aa5cSAndroid Build Coastguard Worker int ctr; 85*dfc6aa5cSAndroid Build Coastguard Worker FAST_FLOAT workspace[DCTSIZE2]; /* buffers data between passes */ 86*dfc6aa5cSAndroid Build Coastguard Worker #define _0_125 ((FLOAT_MULT_TYPE)0.125) 87*dfc6aa5cSAndroid Build Coastguard Worker 88*dfc6aa5cSAndroid Build Coastguard Worker /* Pass 1: process columns from input, store into work array. */ 89*dfc6aa5cSAndroid Build Coastguard Worker 90*dfc6aa5cSAndroid Build Coastguard Worker inptr = coef_block; 91*dfc6aa5cSAndroid Build Coastguard Worker quantptr = (FLOAT_MULT_TYPE *)compptr->dct_table; 92*dfc6aa5cSAndroid Build Coastguard Worker wsptr = workspace; 93*dfc6aa5cSAndroid Build Coastguard Worker for (ctr = DCTSIZE; ctr > 0; ctr--) { 94*dfc6aa5cSAndroid Build Coastguard Worker /* Due to quantization, we will usually find that many of the input 95*dfc6aa5cSAndroid Build Coastguard Worker * coefficients are zero, especially the AC terms. We can exploit this 96*dfc6aa5cSAndroid Build Coastguard Worker * by short-circuiting the IDCT calculation for any column in which all 97*dfc6aa5cSAndroid Build Coastguard Worker * the AC terms are zero. In that case each output is equal to the 98*dfc6aa5cSAndroid Build Coastguard Worker * DC coefficient (with scale factor as needed). 99*dfc6aa5cSAndroid Build Coastguard Worker * With typical images and quantization tables, half or more of the 100*dfc6aa5cSAndroid Build Coastguard Worker * column DCT calculations can be simplified this way. 101*dfc6aa5cSAndroid Build Coastguard Worker */ 102*dfc6aa5cSAndroid Build Coastguard Worker 103*dfc6aa5cSAndroid Build Coastguard Worker if (inptr[DCTSIZE * 1] == 0 && inptr[DCTSIZE * 2] == 0 && 104*dfc6aa5cSAndroid Build Coastguard Worker inptr[DCTSIZE * 3] == 0 && inptr[DCTSIZE * 4] == 0 && 105*dfc6aa5cSAndroid Build Coastguard Worker inptr[DCTSIZE * 5] == 0 && inptr[DCTSIZE * 6] == 0 && 106*dfc6aa5cSAndroid Build Coastguard Worker inptr[DCTSIZE * 7] == 0) { 107*dfc6aa5cSAndroid Build Coastguard Worker /* AC terms all zero */ 108*dfc6aa5cSAndroid Build Coastguard Worker FAST_FLOAT dcval = DEQUANTIZE(inptr[DCTSIZE * 0], 109*dfc6aa5cSAndroid Build Coastguard Worker quantptr[DCTSIZE * 0] * _0_125); 110*dfc6aa5cSAndroid Build Coastguard Worker 111*dfc6aa5cSAndroid Build Coastguard Worker wsptr[DCTSIZE * 0] = dcval; 112*dfc6aa5cSAndroid Build Coastguard Worker wsptr[DCTSIZE * 1] = dcval; 113*dfc6aa5cSAndroid Build Coastguard Worker wsptr[DCTSIZE * 2] = dcval; 114*dfc6aa5cSAndroid Build Coastguard Worker wsptr[DCTSIZE * 3] = dcval; 115*dfc6aa5cSAndroid Build Coastguard Worker wsptr[DCTSIZE * 4] = dcval; 116*dfc6aa5cSAndroid Build Coastguard Worker wsptr[DCTSIZE * 5] = dcval; 117*dfc6aa5cSAndroid Build Coastguard Worker wsptr[DCTSIZE * 6] = dcval; 118*dfc6aa5cSAndroid Build Coastguard Worker wsptr[DCTSIZE * 7] = dcval; 119*dfc6aa5cSAndroid Build Coastguard Worker 120*dfc6aa5cSAndroid Build Coastguard Worker inptr++; /* advance pointers to next column */ 121*dfc6aa5cSAndroid Build Coastguard Worker quantptr++; 122*dfc6aa5cSAndroid Build Coastguard Worker wsptr++; 123*dfc6aa5cSAndroid Build Coastguard Worker continue; 124*dfc6aa5cSAndroid Build Coastguard Worker } 125*dfc6aa5cSAndroid Build Coastguard Worker 126*dfc6aa5cSAndroid Build Coastguard Worker /* Even part */ 127*dfc6aa5cSAndroid Build Coastguard Worker 128*dfc6aa5cSAndroid Build Coastguard Worker tmp0 = DEQUANTIZE(inptr[DCTSIZE * 0], quantptr[DCTSIZE * 0] * _0_125); 129*dfc6aa5cSAndroid Build Coastguard Worker tmp1 = DEQUANTIZE(inptr[DCTSIZE * 2], quantptr[DCTSIZE * 2] * _0_125); 130*dfc6aa5cSAndroid Build Coastguard Worker tmp2 = DEQUANTIZE(inptr[DCTSIZE * 4], quantptr[DCTSIZE * 4] * _0_125); 131*dfc6aa5cSAndroid Build Coastguard Worker tmp3 = DEQUANTIZE(inptr[DCTSIZE * 6], quantptr[DCTSIZE * 6] * _0_125); 132*dfc6aa5cSAndroid Build Coastguard Worker 133*dfc6aa5cSAndroid Build Coastguard Worker tmp10 = tmp0 + tmp2; /* phase 3 */ 134*dfc6aa5cSAndroid Build Coastguard Worker tmp11 = tmp0 - tmp2; 135*dfc6aa5cSAndroid Build Coastguard Worker 136*dfc6aa5cSAndroid Build Coastguard Worker tmp13 = tmp1 + tmp3; /* phases 5-3 */ 137*dfc6aa5cSAndroid Build Coastguard Worker tmp12 = (tmp1 - tmp3) * ((FAST_FLOAT)1.414213562) - tmp13; /* 2*c4 */ 138*dfc6aa5cSAndroid Build Coastguard Worker 139*dfc6aa5cSAndroid Build Coastguard Worker tmp0 = tmp10 + tmp13; /* phase 2 */ 140*dfc6aa5cSAndroid Build Coastguard Worker tmp3 = tmp10 - tmp13; 141*dfc6aa5cSAndroid Build Coastguard Worker tmp1 = tmp11 + tmp12; 142*dfc6aa5cSAndroid Build Coastguard Worker tmp2 = tmp11 - tmp12; 143*dfc6aa5cSAndroid Build Coastguard Worker 144*dfc6aa5cSAndroid Build Coastguard Worker /* Odd part */ 145*dfc6aa5cSAndroid Build Coastguard Worker 146*dfc6aa5cSAndroid Build Coastguard Worker tmp4 = DEQUANTIZE(inptr[DCTSIZE * 1], quantptr[DCTSIZE * 1] * _0_125); 147*dfc6aa5cSAndroid Build Coastguard Worker tmp5 = DEQUANTIZE(inptr[DCTSIZE * 3], quantptr[DCTSIZE * 3] * _0_125); 148*dfc6aa5cSAndroid Build Coastguard Worker tmp6 = DEQUANTIZE(inptr[DCTSIZE * 5], quantptr[DCTSIZE * 5] * _0_125); 149*dfc6aa5cSAndroid Build Coastguard Worker tmp7 = DEQUANTIZE(inptr[DCTSIZE * 7], quantptr[DCTSIZE * 7] * _0_125); 150*dfc6aa5cSAndroid Build Coastguard Worker 151*dfc6aa5cSAndroid Build Coastguard Worker z13 = tmp6 + tmp5; /* phase 6 */ 152*dfc6aa5cSAndroid Build Coastguard Worker z10 = tmp6 - tmp5; 153*dfc6aa5cSAndroid Build Coastguard Worker z11 = tmp4 + tmp7; 154*dfc6aa5cSAndroid Build Coastguard Worker z12 = tmp4 - tmp7; 155*dfc6aa5cSAndroid Build Coastguard Worker 156*dfc6aa5cSAndroid Build Coastguard Worker tmp7 = z11 + z13; /* phase 5 */ 157*dfc6aa5cSAndroid Build Coastguard Worker tmp11 = (z11 - z13) * ((FAST_FLOAT)1.414213562); /* 2*c4 */ 158*dfc6aa5cSAndroid Build Coastguard Worker 159*dfc6aa5cSAndroid Build Coastguard Worker z5 = (z10 + z12) * ((FAST_FLOAT)1.847759065); /* 2*c2 */ 160*dfc6aa5cSAndroid Build Coastguard Worker tmp10 = z5 - z12 * ((FAST_FLOAT)1.082392200); /* 2*(c2-c6) */ 161*dfc6aa5cSAndroid Build Coastguard Worker tmp12 = z5 - z10 * ((FAST_FLOAT)2.613125930); /* 2*(c2+c6) */ 162*dfc6aa5cSAndroid Build Coastguard Worker 163*dfc6aa5cSAndroid Build Coastguard Worker tmp6 = tmp12 - tmp7; /* phase 2 */ 164*dfc6aa5cSAndroid Build Coastguard Worker tmp5 = tmp11 - tmp6; 165*dfc6aa5cSAndroid Build Coastguard Worker tmp4 = tmp10 - tmp5; 166*dfc6aa5cSAndroid Build Coastguard Worker 167*dfc6aa5cSAndroid Build Coastguard Worker wsptr[DCTSIZE * 0] = tmp0 + tmp7; 168*dfc6aa5cSAndroid Build Coastguard Worker wsptr[DCTSIZE * 7] = tmp0 - tmp7; 169*dfc6aa5cSAndroid Build Coastguard Worker wsptr[DCTSIZE * 1] = tmp1 + tmp6; 170*dfc6aa5cSAndroid Build Coastguard Worker wsptr[DCTSIZE * 6] = tmp1 - tmp6; 171*dfc6aa5cSAndroid Build Coastguard Worker wsptr[DCTSIZE * 2] = tmp2 + tmp5; 172*dfc6aa5cSAndroid Build Coastguard Worker wsptr[DCTSIZE * 5] = tmp2 - tmp5; 173*dfc6aa5cSAndroid Build Coastguard Worker wsptr[DCTSIZE * 3] = tmp3 + tmp4; 174*dfc6aa5cSAndroid Build Coastguard Worker wsptr[DCTSIZE * 4] = tmp3 - tmp4; 175*dfc6aa5cSAndroid Build Coastguard Worker 176*dfc6aa5cSAndroid Build Coastguard Worker inptr++; /* advance pointers to next column */ 177*dfc6aa5cSAndroid Build Coastguard Worker quantptr++; 178*dfc6aa5cSAndroid Build Coastguard Worker wsptr++; 179*dfc6aa5cSAndroid Build Coastguard Worker } 180*dfc6aa5cSAndroid Build Coastguard Worker 181*dfc6aa5cSAndroid Build Coastguard Worker /* Pass 2: process rows from work array, store into output array. */ 182*dfc6aa5cSAndroid Build Coastguard Worker 183*dfc6aa5cSAndroid Build Coastguard Worker wsptr = workspace; 184*dfc6aa5cSAndroid Build Coastguard Worker for (ctr = 0; ctr < DCTSIZE; ctr++) { 185*dfc6aa5cSAndroid Build Coastguard Worker outptr = output_buf[ctr] + output_col; 186*dfc6aa5cSAndroid Build Coastguard Worker /* Rows of zeroes can be exploited in the same way as we did with columns. 187*dfc6aa5cSAndroid Build Coastguard Worker * However, the column calculation has created many nonzero AC terms, so 188*dfc6aa5cSAndroid Build Coastguard Worker * the simplification applies less often (typically 5% to 10% of the time). 189*dfc6aa5cSAndroid Build Coastguard Worker * And testing floats for zero is relatively expensive, so we don't bother. 190*dfc6aa5cSAndroid Build Coastguard Worker */ 191*dfc6aa5cSAndroid Build Coastguard Worker 192*dfc6aa5cSAndroid Build Coastguard Worker /* Even part */ 193*dfc6aa5cSAndroid Build Coastguard Worker 194*dfc6aa5cSAndroid Build Coastguard Worker /* Apply signed->unsigned and prepare float->int conversion */ 195*dfc6aa5cSAndroid Build Coastguard Worker z5 = wsptr[0] + ((FAST_FLOAT)CENTERJSAMPLE + (FAST_FLOAT)0.5); 196*dfc6aa5cSAndroid Build Coastguard Worker tmp10 = z5 + wsptr[4]; 197*dfc6aa5cSAndroid Build Coastguard Worker tmp11 = z5 - wsptr[4]; 198*dfc6aa5cSAndroid Build Coastguard Worker 199*dfc6aa5cSAndroid Build Coastguard Worker tmp13 = wsptr[2] + wsptr[6]; 200*dfc6aa5cSAndroid Build Coastguard Worker tmp12 = (wsptr[2] - wsptr[6]) * ((FAST_FLOAT)1.414213562) - tmp13; 201*dfc6aa5cSAndroid Build Coastguard Worker 202*dfc6aa5cSAndroid Build Coastguard Worker tmp0 = tmp10 + tmp13; 203*dfc6aa5cSAndroid Build Coastguard Worker tmp3 = tmp10 - tmp13; 204*dfc6aa5cSAndroid Build Coastguard Worker tmp1 = tmp11 + tmp12; 205*dfc6aa5cSAndroid Build Coastguard Worker tmp2 = tmp11 - tmp12; 206*dfc6aa5cSAndroid Build Coastguard Worker 207*dfc6aa5cSAndroid Build Coastguard Worker /* Odd part */ 208*dfc6aa5cSAndroid Build Coastguard Worker 209*dfc6aa5cSAndroid Build Coastguard Worker z13 = wsptr[5] + wsptr[3]; 210*dfc6aa5cSAndroid Build Coastguard Worker z10 = wsptr[5] - wsptr[3]; 211*dfc6aa5cSAndroid Build Coastguard Worker z11 = wsptr[1] + wsptr[7]; 212*dfc6aa5cSAndroid Build Coastguard Worker z12 = wsptr[1] - wsptr[7]; 213*dfc6aa5cSAndroid Build Coastguard Worker 214*dfc6aa5cSAndroid Build Coastguard Worker tmp7 = z11 + z13; 215*dfc6aa5cSAndroid Build Coastguard Worker tmp11 = (z11 - z13) * ((FAST_FLOAT)1.414213562); 216*dfc6aa5cSAndroid Build Coastguard Worker 217*dfc6aa5cSAndroid Build Coastguard Worker z5 = (z10 + z12) * ((FAST_FLOAT)1.847759065); /* 2*c2 */ 218*dfc6aa5cSAndroid Build Coastguard Worker tmp10 = z5 - z12 * ((FAST_FLOAT)1.082392200); /* 2*(c2-c6) */ 219*dfc6aa5cSAndroid Build Coastguard Worker tmp12 = z5 - z10 * ((FAST_FLOAT)2.613125930); /* 2*(c2+c6) */ 220*dfc6aa5cSAndroid Build Coastguard Worker 221*dfc6aa5cSAndroid Build Coastguard Worker tmp6 = tmp12 - tmp7; 222*dfc6aa5cSAndroid Build Coastguard Worker tmp5 = tmp11 - tmp6; 223*dfc6aa5cSAndroid Build Coastguard Worker tmp4 = tmp10 - tmp5; 224*dfc6aa5cSAndroid Build Coastguard Worker 225*dfc6aa5cSAndroid Build Coastguard Worker /* Final output stage: float->int conversion and range-limit */ 226*dfc6aa5cSAndroid Build Coastguard Worker 227*dfc6aa5cSAndroid Build Coastguard Worker outptr[0] = range_limit[((int)(tmp0 + tmp7)) & RANGE_MASK]; 228*dfc6aa5cSAndroid Build Coastguard Worker outptr[7] = range_limit[((int)(tmp0 - tmp7)) & RANGE_MASK]; 229*dfc6aa5cSAndroid Build Coastguard Worker outptr[1] = range_limit[((int)(tmp1 + tmp6)) & RANGE_MASK]; 230*dfc6aa5cSAndroid Build Coastguard Worker outptr[6] = range_limit[((int)(tmp1 - tmp6)) & RANGE_MASK]; 231*dfc6aa5cSAndroid Build Coastguard Worker outptr[2] = range_limit[((int)(tmp2 + tmp5)) & RANGE_MASK]; 232*dfc6aa5cSAndroid Build Coastguard Worker outptr[5] = range_limit[((int)(tmp2 - tmp5)) & RANGE_MASK]; 233*dfc6aa5cSAndroid Build Coastguard Worker outptr[3] = range_limit[((int)(tmp3 + tmp4)) & RANGE_MASK]; 234*dfc6aa5cSAndroid Build Coastguard Worker outptr[4] = range_limit[((int)(tmp3 - tmp4)) & RANGE_MASK]; 235*dfc6aa5cSAndroid Build Coastguard Worker 236*dfc6aa5cSAndroid Build Coastguard Worker wsptr += DCTSIZE; /* advance pointer to next row */ 237*dfc6aa5cSAndroid Build Coastguard Worker } 238*dfc6aa5cSAndroid Build Coastguard Worker } 239*dfc6aa5cSAndroid Build Coastguard Worker 240*dfc6aa5cSAndroid Build Coastguard Worker #endif /* DCT_FLOAT_SUPPORTED */ 241