Index: cc/output/gl_renderer.cc |
diff --git a/cc/output/gl_renderer.cc b/cc/output/gl_renderer.cc |
index 92af7bc34dc09ca578c4ed4067b9c3943ecf8ecf..783fb2a945cef10ddd1e7560a665a4e416ff4b59 100644 |
--- a/cc/output/gl_renderer.cc |
+++ b/cc/output/gl_renderer.cc |
@@ -899,11 +899,9 @@ scoped_ptr<ScopedResource> GLRenderer::GetBackgroundWithFilters( |
scoped_ptr<ScopedResource> device_background_texture = |
ScopedResource::Create(resource_provider_); |
- // The TextureUsageFramebuffer hint makes ResourceProvider avoid immutable |
- // storage allocation (texStorage2DEXT) for this texture. copyTexImage2D fails |
- // when called on a texture having immutable storage. |
+ // CopyTexImage2D fails when called on a texture having immutable storage. |
device_background_texture->Allocate( |
- window_rect.size(), ResourceProvider::TextureUsageFramebuffer, RGBA_8888); |
+ window_rect.size(), ResourceProvider::TextureHintDefault, RGBA_8888); |
dshwang
2014/08/18 19:28:08
Here is only one logic change. Other changes are j
danakj
2014/08/20 14:46:17
Why not just use TextureUsageAny here, why do we n
dshwang
2014/08/20 15:08:35
That's good question.
Currently, This line wants t
|
{ |
ResourceProvider::ScopedWriteLockGL lock(resource_provider_, |
device_background_texture->id()); |
@@ -941,7 +939,7 @@ scoped_ptr<ScopedResource> GLRenderer::GetBackgroundWithFilters( |
scoped_ptr<ScopedResource> background_texture = |
ScopedResource::Create(resource_provider_); |
background_texture->Allocate( |
- quad->rect.size(), ResourceProvider::TextureUsageFramebuffer, RGBA_8888); |
+ quad->rect.size(), ResourceProvider::TextureHintFramebuffer, RGBA_8888); |
const RenderPass* target_render_pass = frame->current_render_pass; |
bool using_background_texture = |
@@ -1929,13 +1927,13 @@ void GLRenderer::DrawPictureQuad(const DrawingFrame* frame, |
if (on_demand_tile_raster_resource_id_) |
resource_provider_->DeleteResource(on_demand_tile_raster_resource_id_); |
- on_demand_tile_raster_resource_id_ = |
- resource_provider_->CreateGLTexture(quad->texture_size, |
- GL_TEXTURE_2D, |
- GL_TEXTURE_POOL_UNMANAGED_CHROMIUM, |
- GL_CLAMP_TO_EDGE, |
- ResourceProvider::TextureUsageAny, |
- quad->texture_format); |
+ on_demand_tile_raster_resource_id_ = resource_provider_->CreateGLTexture( |
+ quad->texture_size, |
+ GL_TEXTURE_2D, |
+ GL_TEXTURE_POOL_UNMANAGED_CHROMIUM, |
+ GL_CLAMP_TO_EDGE, |
+ ResourceProvider::TextureHintImmutable, |
+ quad->texture_format); |
} |
// Create and run on-demand raster task for tile. |