| OLD | NEW |
| 1 // Copyright (c) 2016 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2016 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef GL_GLEXT_PROTOTYPES | 5 #ifndef GL_GLEXT_PROTOTYPES |
| 6 #define GL_GLEXT_PROTOTYPES | 6 #define GL_GLEXT_PROTOTYPES |
| 7 #endif | 7 #endif |
| 8 | 8 |
| 9 #include <GLES2/gl2.h> | 9 #include <GLES2/gl2.h> |
| 10 #include <GLES2/gl2ext.h> | 10 #include <GLES2/gl2ext.h> |
| (...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 87 glDeleteTextures(1, &textures_); | 87 glDeleteTextures(1, &textures_); |
| 88 glDeleteFramebuffers(1, &framebuffer_id_); | 88 glDeleteFramebuffers(1, &framebuffer_id_); |
| 89 } | 89 } |
| 90 | 90 |
| 91 GLManager gl_; | 91 GLManager gl_; |
| 92 GLuint textures_ = 0; | 92 GLuint textures_ = 0; |
| 93 GLuint framebuffer_id_ = 0; | 93 GLuint framebuffer_id_ = 0; |
| 94 bool available_ = false; | 94 bool available_ = false; |
| 95 }; | 95 }; |
| 96 | 96 |
| 97 // TODO(dongseong.hwang): This test fails on the Nexus 9 GPU fyi bot. |
| 98 // crbug.com/659638 |
| 99 #if defined(OS_ANDROID) |
| 100 #define MAYBE_Basic DISABLED_Basic |
| 101 #else |
| 102 #define MAYBE_Basic Basic |
| 103 #endif |
| 97 // Test to ensure that the basic functionality of the extension works. | 104 // Test to ensure that the basic functionality of the extension works. |
| 98 TEST_F(GLApplyScreenSpaceAntialiasingCHROMIUMTest, Basic) { | 105 TEST_F(GLApplyScreenSpaceAntialiasingCHROMIUMTest, MAYBE_Basic) { |
| 99 if (!available_) | 106 if (!available_) |
| 100 return; | 107 return; |
| 101 | 108 |
| 102 glApplyScreenSpaceAntialiasingCHROMIUM(); | 109 glApplyScreenSpaceAntialiasingCHROMIUM(); |
| 103 EXPECT_EQ(static_cast<GLenum>(GL_NO_ERROR), glGetError()); | 110 EXPECT_EQ(static_cast<GLenum>(GL_NO_ERROR), glGetError()); |
| 104 | 111 |
| 105 // Check the FB is still bound. | 112 // Check the FB is still bound. |
| 106 GLint value = 0; | 113 GLint value = 0; |
| 107 glGetIntegerv(GL_FRAMEBUFFER_BINDING, &value); | 114 glGetIntegerv(GL_FRAMEBUFFER_BINDING, &value); |
| 108 GLuint fb_id = value; | 115 GLuint fb_id = value; |
| (...skipping 315 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 424 EXPECT_TRUE(GLTestHelper::CheckPixels(0, 0, 1, 1, 0, expected)); | 431 EXPECT_TRUE(GLTestHelper::CheckPixels(0, 0, 1, 1, 0, expected)); |
| 425 | 432 |
| 426 EXPECT_EQ(static_cast<GLenum>(GL_NO_ERROR), glGetError()); | 433 EXPECT_EQ(static_cast<GLenum>(GL_NO_ERROR), glGetError()); |
| 427 | 434 |
| 428 gl2.MakeCurrent(); | 435 gl2.MakeCurrent(); |
| 429 gl2.Destroy(); | 436 gl2.Destroy(); |
| 430 gl_.MakeCurrent(); | 437 gl_.MakeCurrent(); |
| 431 } | 438 } |
| 432 | 439 |
| 433 } // namespace gpu | 440 } // namespace gpu |
| OLD | NEW |