Lines Matching defs:pixel
280 GLubyte pixel[4];
282 glReadPixels(x, y, 1, 1, GL_RGBA, GL_UNSIGNED_BYTE, pixel);
285 msg += String8::format("error reading pixel: %#x", err);
289 fprintf(stderr, "pixel check failure: %s\n", msg.string());
293 if (r >= 0 && abs(r - int(pixel[0])) > tolerance) {
294 msg += String8::format("r(%d isn't %d)", pixel[0], r);
296 if (g >= 0 && abs(g - int(pixel[1])) > tolerance) {
300 msg += String8::format("g(%d isn't %d)", pixel[1], g);
302 if (b >= 0 && abs(b - int(pixel[2])) > tolerance) {
306 msg += String8::format("b(%d isn't %d)", pixel[2], b);
308 if (a >= 0 && abs(a - int(pixel[3])) > tolerance) {
312 msg += String8::format("a(%d isn't %d)", pixel[3], a);
315 fprintf(stderr, "pixel check failure: %s\n", msg.string());