| Index: cc/scoped_texture_unittest.cc
|
| diff --git a/cc/scoped_texture_unittest.cc b/cc/scoped_texture_unittest.cc
|
| index b707a7fcb153878a422444a39696627f0e56a810..f0447c493e45d35e6e46d669ab523dd428ad3a2e 100644
|
| --- a/cc/scoped_texture_unittest.cc
|
| +++ b/cc/scoped_texture_unittest.cc
|
| @@ -6,12 +6,12 @@
|
|
|
| #include "CCScopedTexture.h"
|
|
|
| +#include "testing/gtest/include/gtest/gtest.h"
|
| +#include "third_party/khronos/GLES2/gl2.h"
|
| #include "CCRenderer.h"
|
| #include "CCSingleThreadProxy.h" // For DebugScopedSetImplThread
|
| #include "CCTiledLayerTestCommon.h"
|
| #include "FakeCCGraphicsContext.h"
|
| -#include "GraphicsContext3D.h"
|
| -#include "testing/gtest/include/gtest/gtest.h"
|
|
|
| using namespace cc;
|
| using namespace WebKit;
|
| @@ -40,14 +40,14 @@ TEST(CCScopedTextureTest, CreateScopedTexture)
|
| DebugScopedSetImplThread implThread;
|
| OwnPtr<CCResourceProvider> resourceProvider(CCResourceProvider::create(context.get()));
|
| OwnPtr<CCScopedTexture> texture = CCScopedTexture::create(resourceProvider.get());
|
| - texture->allocate(CCRenderer::ImplPool, IntSize(30, 30), GraphicsContext3D::RGBA, CCResourceProvider::TextureUsageAny);
|
| + texture->allocate(CCRenderer::ImplPool, IntSize(30, 30), GL_RGBA, CCResourceProvider::TextureUsageAny);
|
|
|
| // The texture has an allocated byte-size now.
|
| size_t expectedBytes = 30 * 30 * 4;
|
| EXPECT_EQ(expectedBytes, texture->bytes());
|
|
|
| EXPECT_LT(0u, texture->id());
|
| - EXPECT_EQ(GraphicsContext3D::RGBA, texture->format());
|
| + EXPECT_EQ(GL_RGBA, texture->format());
|
| EXPECT_EQ(IntSize(30, 30), texture->size());
|
| }
|
|
|
| @@ -61,7 +61,7 @@ TEST(CCScopedTextureTest, ScopedTextureIsDeleted)
|
| OwnPtr<CCScopedTexture> texture = CCScopedTexture::create(resourceProvider.get());
|
|
|
| EXPECT_EQ(0u, resourceProvider->numResources());
|
| - texture->allocate(CCRenderer::ImplPool, IntSize(30, 30), GraphicsContext3D::RGBA, CCResourceProvider::TextureUsageAny);
|
| + texture->allocate(CCRenderer::ImplPool, IntSize(30, 30), GL_RGBA, CCResourceProvider::TextureUsageAny);
|
| EXPECT_LT(0u, texture->id());
|
| EXPECT_EQ(1u, resourceProvider->numResources());
|
| }
|
| @@ -71,7 +71,7 @@ TEST(CCScopedTextureTest, ScopedTextureIsDeleted)
|
| {
|
| OwnPtr<CCScopedTexture> texture = CCScopedTexture::create(resourceProvider.get());
|
| EXPECT_EQ(0u, resourceProvider->numResources());
|
| - texture->allocate(CCRenderer::ImplPool, IntSize(30, 30), GraphicsContext3D::RGBA, CCResourceProvider::TextureUsageAny);
|
| + texture->allocate(CCRenderer::ImplPool, IntSize(30, 30), GL_RGBA, CCResourceProvider::TextureUsageAny);
|
| EXPECT_LT(0u, texture->id());
|
| EXPECT_EQ(1u, resourceProvider->numResources());
|
| texture->free();
|
| @@ -89,7 +89,7 @@ TEST(CCScopedTextureTest, LeakScopedTexture)
|
| OwnPtr<CCScopedTexture> texture = CCScopedTexture::create(resourceProvider.get());
|
|
|
| EXPECT_EQ(0u, resourceProvider->numResources());
|
| - texture->allocate(CCRenderer::ImplPool, IntSize(30, 30), GraphicsContext3D::RGBA, CCResourceProvider::TextureUsageAny);
|
| + texture->allocate(CCRenderer::ImplPool, IntSize(30, 30), GL_RGBA, CCResourceProvider::TextureUsageAny);
|
| EXPECT_LT(0u, texture->id());
|
| EXPECT_EQ(1u, resourceProvider->numResources());
|
|
|
|
|