summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Jamie Gennis <jgennis@google.com> 2011-06-17 10:45:01 -0700
committer Android (Google) Code Review <android-gerrit@google.com> 2011-06-17 10:45:01 -0700
commit4661a501217695ca8ac8c8a9c20e74b8f6fac0cf (patch)
treec2a4dbe7b7541cfdcca730ed52b1180486b9dca8
parenta5d569451e8d2afa99c9d67a2726df30725bffde (diff)
parentd05bb2ed4c99894965134994cf23c9e47274f56e (diff)
Merge "SurfaceTexture: enable a test that is now passing."
-rw-r--r--libs/gui/tests/SurfaceTexture_test.cpp24
1 files changed, 10 insertions, 14 deletions
diff --git a/libs/gui/tests/SurfaceTexture_test.cpp b/libs/gui/tests/SurfaceTexture_test.cpp
index 50af3bbbac..f6cefa66c3 100644
--- a/libs/gui/tests/SurfaceTexture_test.cpp
+++ b/libs/gui/tests/SurfaceTexture_test.cpp
@@ -542,11 +542,7 @@ TEST_F(SurfaceTextureGLTest, TexturingFromCpuFilledYV12BufferNpot) {
EXPECT_TRUE(checkPixel(36, 22, 155, 29, 0, 255));
}
-// XXX: This test is disabled because it it currently broken on all devices to
-// which I have access. Some of the checkPixel calls are not correct because
-// I just copied them from the npot test above and haven't bothered to figure
-// out the correct values.
-TEST_F(SurfaceTextureGLTest, DISABLED_TexturingFromCpuFilledYV12BufferPow2) {
+TEST_F(SurfaceTextureGLTest, TexturingFromCpuFilledYV12BufferPow2) {
const int texWidth = 64;
const int texHeight = 64;
@@ -576,18 +572,18 @@ TEST_F(SurfaceTextureGLTest, DISABLED_TexturingFromCpuFilledYV12BufferPow2) {
drawTexture();
- EXPECT_TRUE(checkPixel( 0, 0, 255, 127, 255, 255));
- EXPECT_TRUE(checkPixel(63, 0, 0, 133, 0, 255));
+ EXPECT_TRUE(checkPixel( 0, 0, 0, 133, 0, 255));
+ EXPECT_TRUE(checkPixel(63, 0, 255, 127, 255, 255));
EXPECT_TRUE(checkPixel(63, 63, 0, 133, 0, 255));
EXPECT_TRUE(checkPixel( 0, 63, 255, 127, 255, 255));
- EXPECT_TRUE(checkPixel(22, 19, 247, 70, 255, 255));
- EXPECT_TRUE(checkPixel(45, 11, 209, 32, 235, 255));
- EXPECT_TRUE(checkPixel(52, 12, 100, 255, 73, 255));
- EXPECT_TRUE(checkPixel( 7, 32, 155, 0, 118, 255));
- EXPECT_TRUE(checkPixel(31, 54, 148, 71, 110, 255));
- EXPECT_TRUE(checkPixel(29, 28, 255, 127, 255, 255));
- EXPECT_TRUE(checkPixel(36, 41, 155, 29, 0, 255));
+ EXPECT_TRUE(checkPixel(22, 19, 100, 255, 74, 255));
+ EXPECT_TRUE(checkPixel(45, 11, 100, 255, 74, 255));
+ EXPECT_TRUE(checkPixel(52, 12, 155, 0, 181, 255));
+ EXPECT_TRUE(checkPixel( 7, 32, 150, 237, 170, 255));
+ EXPECT_TRUE(checkPixel(31, 54, 0, 71, 117, 255));
+ EXPECT_TRUE(checkPixel(29, 28, 0, 133, 0, 255));
+ EXPECT_TRUE(checkPixel(36, 41, 100, 232, 255, 255));
}
TEST_F(SurfaceTextureGLTest, TexturingFromCpuFilledYV12BufferWithCrop) {