From e6a0f5028b3ef81916e7fd58a64f76861bfa78e0 Mon Sep 17 00:00:00 2001 From: Jamie Gennis Date: Fri, 5 Apr 2013 17:37:32 -0700 Subject: [PATCH] libgui_test: increase the tolerance for a YUV test This change increases the pixel difference tolerance of the SurfaceTextureGLTest.TexturingFromCpuFilledYV12BufferNpot test from 2 to 3. Bug: 8349135 Change-Id: I82e361a689335f49065cacd8a3fc145d67b125f1 --- libs/gui/tests/SurfaceTexture_test.cpp | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/libs/gui/tests/SurfaceTexture_test.cpp b/libs/gui/tests/SurfaceTexture_test.cpp index 2d3030598..84ec7f230 100644 --- a/libs/gui/tests/SurfaceTexture_test.cpp +++ b/libs/gui/tests/SurfaceTexture_test.cpp @@ -716,18 +716,18 @@ TEST_F(SurfaceTextureGLTest, TexturingFromCpuFilledYV12BufferNpot) { glViewport(0, 0, texWidth, texHeight); drawTexture(); - EXPECT_TRUE(checkPixel( 0, 0, 255, 127, 255, 255)); - EXPECT_TRUE(checkPixel(63, 0, 0, 133, 0, 255)); - EXPECT_TRUE(checkPixel(63, 65, 0, 133, 0, 255)); - EXPECT_TRUE(checkPixel( 0, 65, 255, 127, 255, 255)); + EXPECT_TRUE(checkPixel( 0, 0, 255, 127, 255, 255, 3)); + EXPECT_TRUE(checkPixel(63, 0, 0, 133, 0, 255, 3)); + EXPECT_TRUE(checkPixel(63, 65, 0, 133, 0, 255, 3)); + EXPECT_TRUE(checkPixel( 0, 65, 255, 127, 255, 255, 3)); - EXPECT_TRUE(checkPixel(22, 44, 255, 127, 255, 255)); - EXPECT_TRUE(checkPixel(45, 52, 255, 127, 255, 255)); - EXPECT_TRUE(checkPixel(52, 51, 98, 255, 73, 255)); - EXPECT_TRUE(checkPixel( 7, 31, 155, 0, 118, 255)); - EXPECT_TRUE(checkPixel(31, 9, 107, 24, 87, 255)); - EXPECT_TRUE(checkPixel(29, 35, 255, 127, 255, 255)); - EXPECT_TRUE(checkPixel(36, 22, 155, 29, 0, 255)); + EXPECT_TRUE(checkPixel(22, 44, 255, 127, 255, 255, 3)); + EXPECT_TRUE(checkPixel(45, 52, 255, 127, 255, 255, 3)); + EXPECT_TRUE(checkPixel(52, 51, 98, 255, 73, 255, 3)); + EXPECT_TRUE(checkPixel( 7, 31, 155, 0, 118, 255, 3)); + EXPECT_TRUE(checkPixel(31, 9, 107, 24, 87, 255, 3)); + EXPECT_TRUE(checkPixel(29, 35, 255, 127, 255, 255, 3)); + EXPECT_TRUE(checkPixel(36, 22, 155, 29, 0, 255, 3)); } TEST_F(SurfaceTextureGLTest, TexturingFromCpuFilledYV12BufferPow2) {