Lines Matching refs:deUint32
44 static inline deUint8 getChannel (deUint32 color) in getChannel()
50 inline deUint32 readRGBA8Raw (const ConstPixelBufferAccess& src, deUint32 x, deUint32 y) in readRGBA8Raw()
52 return *(const deUint32*)((const deUint8*)src.getDataPtr() + y*src.getRowPitch() + x*4); in readRGBA8Raw()
55 inline deUint32 readRGBA8Raw (const ConstPixelBufferAccess& src, deUint32 x, deUint32 y) in readRGBA8Raw()
57 …return deReverseBytes32(*(const deUint32*)((const deUint8*)src.getDataPtr() + y*src.getRowPitch() … in readRGBA8Raw()
61 inline RGBA readRGBA8 (const ConstPixelBufferAccess& src, deUint32 x, deUint32 y) in readRGBA8()
63 deUint32 raw = readRGBA8Raw(src, x, y); in readRGBA8()
64 deUint32 res = 0; in readRGBA8()
74 inline deUint8 interpolateChannel (deUint32 fx1, deUint32 fy1, deUint8 p00, deUint8 p01, deUint8 p1… in interpolateChannel()
76 const deUint32 fx0 = (1u<<NUM_SUBPIXEL_BITS) - fx1; in interpolateChannel()
77 const deUint32 fy0 = (1u<<NUM_SUBPIXEL_BITS) - fy1; in interpolateChannel()
78 const deUint32 half = 1u<<(NUM_SUBPIXEL_BITS*2 - 1); in interpolateChannel()
79 const deUint32 sum = fx0*fy0*p00 + fx1*fy0*p10 + fx0*fy1*p01 + fx1*fy1*p11; in interpolateChannel()
80 const deUint32 rounded = (sum + half) >> (NUM_SUBPIXEL_BITS*2); in interpolateChannel()
82 DE_ASSERT(de::inRange<deUint32>(rounded, 0, 0xff)); in interpolateChannel()
86 RGBA bilinearSampleRGBA8 (const ConstPixelBufferAccess& access, deUint32 u, deUint32 v) in bilinearSampleRGBA8()
88 deUint32 x0 = u>>NUM_SUBPIXEL_BITS; in bilinearSampleRGBA8()
89 deUint32 y0 = v>>NUM_SUBPIXEL_BITS; in bilinearSampleRGBA8()
90 deUint32 x1 = x0+1; //de::min(x0+1, (deUint32)(access.getWidth()-1)); in bilinearSampleRGBA8()
91 deUint32 y1 = y0+1; //de::min(y0+1, (deUint32)(access.getHeight()-1)); in bilinearSampleRGBA8()
93 DE_ASSERT(x1 < (deUint32)access.getWidth()); in bilinearSampleRGBA8()
94 DE_ASSERT(y1 < (deUint32)access.getHeight()); in bilinearSampleRGBA8()
96 deUint32 fx1 = u-(x0<<NUM_SUBPIXEL_BITS); in bilinearSampleRGBA8()
97 deUint32 fy1 = v-(y0<<NUM_SUBPIXEL_BITS); in bilinearSampleRGBA8()
99 deUint32 p00 = readRGBA8Raw(access, x0, y0); in bilinearSampleRGBA8()
100 deUint32 p10 = readRGBA8Raw(access, x1, y0); in bilinearSampleRGBA8()
101 deUint32 p01 = readRGBA8Raw(access, x0, y1); in bilinearSampleRGBA8()
102 deUint32 p11 = readRGBA8Raw(access, x1, y1); in bilinearSampleRGBA8()
104 deUint32 res = 0; in bilinearSampleRGBA8()
116 const RGBA resPix = readRGBA8(result, (deUint32)x, (deUint32)y); in comparePixelRGBA8()
120 const deUint32 x0 = (deUint32)de::max(x-1, 0); in comparePixelRGBA8()
121 const deUint32 x1 = (deUint32)x; in comparePixelRGBA8()
122 const deUint32 x2 = (deUint32)de::min(x+1, reference.getWidth()-1); in comparePixelRGBA8()
123 const deUint32 y0 = (deUint32)de::max(y-1, 0); in comparePixelRGBA8()
124 const deUint32 y1 = (deUint32)y; in comparePixelRGBA8()
125 const deUint32 y2 = (deUint32)de::min(y+1, reference.getHeight()-1); in comparePixelRGBA8()
142 static const deUint32 s_offsets[][2] = in comparePixelRGBA8()
183 … if (compareThreshold(resPix, bilinearSampleRGBA8(reference, (deUint32)u, (deUint32)v), threshold)) in comparePixelRGBA8()