diff options
author | epenner@chromium.org <epenner@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-01-09 21:06:11 +0000 |
---|---|---|
committer | epenner@chromium.org <epenner@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-01-09 21:06:11 +0000 |
commit | 0b2958b6b67aa40efff7227776e67ec44cc337c7 (patch) | |
tree | 9c82bc633dcd41ba2e2e0d93086bc14e65cf8fa9 /cc/test/render_pass_test_common.cc | |
parent | ddf288e2619b3834f9ac3ecc763b536440981cda (diff) | |
download | chromium_src-0b2958b6b67aa40efff7227776e67ec44cc337c7.zip chromium_src-0b2958b6b67aa40efff7227776e67ec44cc337c7.tar.gz chromium_src-0b2958b6b67aa40efff7227776e67ec44cc337c7.tar.bz2 |
cc: Defer texture allocation (to allow async allocations).
For textures, delay allocating until the first setPixels
or beginSetPixels. This allows us to do a combined async
allocation/upload in beginSetPixels.
BUG=161337
Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=173875
Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=174035
Review URL: https://chromiumcodereview.appspot.com/11622008
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@175884 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'cc/test/render_pass_test_common.cc')
-rw-r--r-- | cc/test/render_pass_test_common.cc | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/cc/test/render_pass_test_common.cc b/cc/test/render_pass_test_common.cc index b66ca4f..065f593 100644 --- a/cc/test/render_pass_test_common.cc +++ b/cc/test/render_pass_test_common.cc @@ -29,6 +29,7 @@ void TestRenderPass::AppendOneOfEveryQuadType( gfx::Size(20, 12), resourceProvider->bestTextureFormat(), ResourceProvider::TextureUsageAny); + resourceProvider->allocateForTesting(texture_resource); unsigned texture_id = ResourceProvider::ScopedReadLockGL( resourceProvider, texture_resource).textureId(); @@ -163,6 +164,7 @@ void TestRenderPass::AppendOneOfEveryQuadType( gfx::Size(20, 12), resourceProvider->bestTextureFormat(), ResourceProvider::TextureUsageAny); + resourceProvider->allocateForTesting(planes[i].resourceId); planes[i].size = gfx::Size(100, 100); planes[i].format = GL_LUMINANCE; } |