diff options
author | jbauman <jbauman@chromium.org> | 2015-12-02 15:15:40 -0800 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-12-02 23:18:18 +0000 |
commit | 8046f1cbb18126cd9ea1a405c93e545f2c377978 (patch) | |
tree | d7882c1c67e7b472945270b9942931db114ffc8f | |
parent | 139d1058893d281aa122b41910c9dc243dfb94d7 (diff) | |
download | chromium_src-8046f1cbb18126cd9ea1a405c93e545f2c377978.zip chromium_src-8046f1cbb18126cd9ea1a405c93e545f2c377978.tar.gz chromium_src-8046f1cbb18126cd9ea1a405c93e545f2c377978.tar.bz2 |
Add alpha argument to glResizeCHROMIUM
This lets the compositor specify whether the backbuffer will need to be blended with the contents behind it, and if not it can use a method that uses less power.
BUG=561185
CQ_INCLUDE_TRYBOTS=tryserver.blink:linux_blink_rel
Review URL: https://codereview.chromium.org/1474873003
Cr-Commit-Position: refs/heads/master@{#362817}
23 files changed, 87 insertions, 43 deletions
diff --git a/cc/output/output_surface.cc b/cc/output/output_surface.cc index 3430d18..d8b7962 100644 --- a/cc/output/output_surface.cc +++ b/cc/output/output_surface.cc @@ -257,8 +257,8 @@ void OutputSurface::Reshape(const gfx::Size& size, float scale_factor) { surface_size_ = size; device_scale_factor_ = scale_factor; if (context_provider_.get()) { - context_provider_->ContextGL()->ResizeCHROMIUM( - size.width(), size.height(), scale_factor); + context_provider_->ContextGL()->ResizeCHROMIUM(size.width(), size.height(), + scale_factor, GL_TRUE); } if (software_device_) software_device_->Resize(size, scale_factor); diff --git a/cc/test/test_gles2_interface.cc b/cc/test/test_gles2_interface.cc index 4ebdfd3..2781712 100644 --- a/cc/test/test_gles2_interface.cc +++ b/cc/test/test_gles2_interface.cc @@ -379,7 +379,8 @@ GLuint TestGLES2Interface::CreateAndConsumeTextureCHROMIUM( void TestGLES2Interface::ResizeCHROMIUM(GLuint width, GLuint height, - float device_scale) { + float device_scale, + GLboolean has_alpha) { test_context_->reshapeWithScaleFactor(width, height, device_scale); } diff --git a/cc/test/test_gles2_interface.h b/cc/test/test_gles2_interface.h index 20ab007..0914810 100644 --- a/cc/test/test_gles2_interface.h +++ b/cc/test/test_gles2_interface.h @@ -157,7 +157,10 @@ class TestGLES2Interface : public gpu::gles2::GLES2InterfaceStub { GLuint CreateAndConsumeTextureCHROMIUM(GLenum target, const GLbyte* mailbox) override; - void ResizeCHROMIUM(GLuint width, GLuint height, float device_scale) override; + void ResizeCHROMIUM(GLuint width, + GLuint height, + float device_scale, + GLboolean has_alpha) override; void LoseContextCHROMIUM(GLenum current, GLenum other) override; GLenum GetGraphicsResetStatusKHR() override; diff --git a/gpu/GLES2/gl2extchromium.h b/gpu/GLES2/gl2extchromium.h index 64147b4..f3c787f 100644 --- a/gpu/GLES2/gl2extchromium.h +++ b/gpu/GLES2/gl2extchromium.h @@ -653,8 +653,10 @@ typedef void (GL_APIENTRYP PFNGLDRAWBUFFERSEXTPROC) ( #ifndef GL_CHROMIUM_resize #define GL_CHROMIUM_resize 1 #ifdef GL_GLEXT_PROTOTYPES -GL_APICALL void GL_APIENTRY glResizeCHROMIUM( - GLuint width, GLuint height, GLfloat scale_factor); +GL_APICALL void GL_APIENTRY glResizeCHROMIUM(GLuint width, + GLuint height, + GLfloat scale_factor, + GLboolean alpha); #endif typedef void (GL_APIENTRYP PFNGLRESIZECHROMIUMPROC) ( GLuint width, GLuint height); diff --git a/gpu/blink/webgraphicscontext3d_impl.cc b/gpu/blink/webgraphicscontext3d_impl.cc index 0ef42a2..a3fc0ed 100644 --- a/gpu/blink/webgraphicscontext3d_impl.cc +++ b/gpu/blink/webgraphicscontext3d_impl.cc @@ -223,7 +223,11 @@ bool WebGraphicsContext3DImpl::insertSyncPoint(WGC3Dbyte* sync_token) { return true; } -DELEGATE_TO_GL_3(reshapeWithScaleFactor, ResizeCHROMIUM, int, int, float) +void WebGraphicsContext3DImpl::reshapeWithScaleFactor(int width, + int height, + float scale) { + gl_->ResizeCHROMIUM(width, height, scale, true); +} DELEGATE_TO_GL_4R(mapBufferSubDataCHROMIUM, MapBufferSubDataCHROMIUM, WGC3Denum, WGC3Dintptr, WGC3Dsizeiptr, WGC3Denum, void*) diff --git a/gpu/command_buffer/client/gles2_c_lib_autogen.h b/gpu/command_buffer/client/gles2_c_lib_autogen.h index 7003cbc..b274a6b 100644 --- a/gpu/command_buffer/client/gles2_c_lib_autogen.h +++ b/gpu/command_buffer/client/gles2_c_lib_autogen.h @@ -1260,8 +1260,9 @@ void GL_APIENTRY GLES2UnmapTexSubImage2DCHROMIUM(const void* mem) { } void GL_APIENTRY GLES2ResizeCHROMIUM(GLuint width, GLuint height, - GLfloat scale_factor) { - gles2::GetGLContext()->ResizeCHROMIUM(width, height, scale_factor); + GLfloat scale_factor, + GLboolean alpha) { + gles2::GetGLContext()->ResizeCHROMIUM(width, height, scale_factor, alpha); } const GLchar* GL_APIENTRY GLES2GetRequestableExtensionsCHROMIUM() { return gles2::GetGLContext()->GetRequestableExtensionsCHROMIUM(); diff --git a/gpu/command_buffer/client/gles2_cmd_helper_autogen.h b/gpu/command_buffer/client/gles2_cmd_helper_autogen.h index e2123f5..b5cf24c 100644 --- a/gpu/command_buffer/client/gles2_cmd_helper_autogen.h +++ b/gpu/command_buffer/client/gles2_cmd_helper_autogen.h @@ -2410,10 +2410,13 @@ void UnmapBuffer(GLenum target) { } } -void ResizeCHROMIUM(GLuint width, GLuint height, GLfloat scale_factor) { +void ResizeCHROMIUM(GLuint width, + GLuint height, + GLfloat scale_factor, + GLboolean alpha) { gles2::cmds::ResizeCHROMIUM* c = GetCmdSpace<gles2::cmds::ResizeCHROMIUM>(); if (c) { - c->Init(width, height, scale_factor); + c->Init(width, height, scale_factor, alpha); } } diff --git a/gpu/command_buffer/client/gles2_implementation.cc b/gpu/command_buffer/client/gles2_implementation.cc index 208a08b..9b52768 100644 --- a/gpu/command_buffer/client/gles2_implementation.cc +++ b/gpu/command_buffer/client/gles2_implementation.cc @@ -4692,12 +4692,14 @@ void GLES2Implementation::UnmapTexSubImage2DCHROMIUM(const void* mem) { CheckGLError(); } -void GLES2Implementation::ResizeCHROMIUM(GLuint width, GLuint height, - float scale_factor) { +void GLES2Implementation::ResizeCHROMIUM(GLuint width, + GLuint height, + float scale_factor, + GLboolean alpha) { GPU_CLIENT_SINGLE_THREAD_CHECK(); - GPU_CLIENT_LOG("[" << GetLogPrefix() << "] glResizeCHROMIUM(" - << width << ", " << height << ", " << scale_factor << ")"); - helper_->ResizeCHROMIUM(width, height, scale_factor); + GPU_CLIENT_LOG("[" << GetLogPrefix() << "] glResizeCHROMIUM(" << width << ", " + << height << ", " << scale_factor << ", " << alpha << ")"); + helper_->ResizeCHROMIUM(width, height, scale_factor, alpha); CheckGLError(); } diff --git a/gpu/command_buffer/client/gles2_implementation_autogen.h b/gpu/command_buffer/client/gles2_implementation_autogen.h index fc99066..0a4f886 100644 --- a/gpu/command_buffer/client/gles2_implementation_autogen.h +++ b/gpu/command_buffer/client/gles2_implementation_autogen.h @@ -870,7 +870,10 @@ void* MapTexSubImage2DCHROMIUM(GLenum target, void UnmapTexSubImage2DCHROMIUM(const void* mem) override; -void ResizeCHROMIUM(GLuint width, GLuint height, GLfloat scale_factor) override; +void ResizeCHROMIUM(GLuint width, + GLuint height, + GLfloat scale_factor, + GLboolean alpha) override; const GLchar* GetRequestableExtensionsCHROMIUM() override; diff --git a/gpu/command_buffer/client/gles2_implementation_unittest_autogen.h b/gpu/command_buffer/client/gles2_implementation_unittest_autogen.h index 23f6541..e8efce0 100644 --- a/gpu/command_buffer/client/gles2_implementation_unittest_autogen.h +++ b/gpu/command_buffer/client/gles2_implementation_unittest_autogen.h @@ -2792,9 +2792,9 @@ TEST_F(GLES2ImplementationTest, ResizeCHROMIUM) { cmds::ResizeCHROMIUM cmd; }; Cmds expected; - expected.cmd.Init(1, 2, 3); + expected.cmd.Init(1, 2, 3, true); - gl_->ResizeCHROMIUM(1, 2, 3); + gl_->ResizeCHROMIUM(1, 2, 3, true); EXPECT_EQ(0, memcmp(&expected, commands_, sizeof(expected))); } diff --git a/gpu/command_buffer/client/gles2_interface_autogen.h b/gpu/command_buffer/client/gles2_interface_autogen.h index 9edbc49..77872e7 100644 --- a/gpu/command_buffer/client/gles2_interface_autogen.h +++ b/gpu/command_buffer/client/gles2_interface_autogen.h @@ -646,7 +646,8 @@ virtual void* MapTexSubImage2DCHROMIUM(GLenum target, virtual void UnmapTexSubImage2DCHROMIUM(const void* mem) = 0; virtual void ResizeCHROMIUM(GLuint width, GLuint height, - GLfloat scale_factor) = 0; + GLfloat scale_factor, + GLboolean alpha) = 0; virtual const GLchar* GetRequestableExtensionsCHROMIUM() = 0; virtual void RequestExtensionCHROMIUM(const char* extension) = 0; virtual void GetProgramInfoCHROMIUM(GLuint program, diff --git a/gpu/command_buffer/client/gles2_interface_stub_autogen.h b/gpu/command_buffer/client/gles2_interface_stub_autogen.h index bc478cb..5469525 100644 --- a/gpu/command_buffer/client/gles2_interface_stub_autogen.h +++ b/gpu/command_buffer/client/gles2_interface_stub_autogen.h @@ -623,7 +623,10 @@ void* MapTexSubImage2DCHROMIUM(GLenum target, GLenum type, GLenum access) override; void UnmapTexSubImage2DCHROMIUM(const void* mem) override; -void ResizeCHROMIUM(GLuint width, GLuint height, GLfloat scale_factor) override; +void ResizeCHROMIUM(GLuint width, + GLuint height, + GLfloat scale_factor, + GLboolean alpha) override; const GLchar* GetRequestableExtensionsCHROMIUM() override; void RequestExtensionCHROMIUM(const char* extension) override; void GetProgramInfoCHROMIUM(GLuint program, diff --git a/gpu/command_buffer/client/gles2_interface_stub_impl_autogen.h b/gpu/command_buffer/client/gles2_interface_stub_impl_autogen.h index 4e3a712..867652f 100644 --- a/gpu/command_buffer/client/gles2_interface_stub_impl_autogen.h +++ b/gpu/command_buffer/client/gles2_interface_stub_impl_autogen.h @@ -860,7 +860,8 @@ void* GLES2InterfaceStub::MapTexSubImage2DCHROMIUM(GLenum /* target */, void GLES2InterfaceStub::UnmapTexSubImage2DCHROMIUM(const void* /* mem */) {} void GLES2InterfaceStub::ResizeCHROMIUM(GLuint /* width */, GLuint /* height */, - GLfloat /* scale_factor */) {} + GLfloat /* scale_factor */, + GLboolean /* alpha */) {} const GLchar* GLES2InterfaceStub::GetRequestableExtensionsCHROMIUM() { return 0; } diff --git a/gpu/command_buffer/client/gles2_trace_implementation_autogen.h b/gpu/command_buffer/client/gles2_trace_implementation_autogen.h index 27923ea..209215e 100644 --- a/gpu/command_buffer/client/gles2_trace_implementation_autogen.h +++ b/gpu/command_buffer/client/gles2_trace_implementation_autogen.h @@ -623,7 +623,10 @@ void* MapTexSubImage2DCHROMIUM(GLenum target, GLenum type, GLenum access) override; void UnmapTexSubImage2DCHROMIUM(const void* mem) override; -void ResizeCHROMIUM(GLuint width, GLuint height, GLfloat scale_factor) override; +void ResizeCHROMIUM(GLuint width, + GLuint height, + GLfloat scale_factor, + GLboolean alpha) override; const GLchar* GetRequestableExtensionsCHROMIUM() override; void RequestExtensionCHROMIUM(const char* extension) override; void GetProgramInfoCHROMIUM(GLuint program, diff --git a/gpu/command_buffer/client/gles2_trace_implementation_impl_autogen.h b/gpu/command_buffer/client/gles2_trace_implementation_impl_autogen.h index 1fc343f..77c6ab6 100644 --- a/gpu/command_buffer/client/gles2_trace_implementation_impl_autogen.h +++ b/gpu/command_buffer/client/gles2_trace_implementation_impl_autogen.h @@ -1837,9 +1837,10 @@ void GLES2TraceImplementation::UnmapTexSubImage2DCHROMIUM(const void* mem) { void GLES2TraceImplementation::ResizeCHROMIUM(GLuint width, GLuint height, - GLfloat scale_factor) { + GLfloat scale_factor, + GLboolean alpha) { TRACE_EVENT_BINARY_EFFICIENT0("gpu", "GLES2Trace::ResizeCHROMIUM"); - gl_->ResizeCHROMIUM(width, height, scale_factor); + gl_->ResizeCHROMIUM(width, height, scale_factor, alpha); } const GLchar* GLES2TraceImplementation::GetRequestableExtensionsCHROMIUM() { diff --git a/gpu/command_buffer/cmd_buffer_functions.txt b/gpu/command_buffer/cmd_buffer_functions.txt index fe6e9e9..42ed5f5 100644 --- a/gpu/command_buffer/cmd_buffer_functions.txt +++ b/gpu/command_buffer/cmd_buffer_functions.txt @@ -265,7 +265,7 @@ GL_APICALL void* GL_APIENTRY glMapBufferRange (GLenumBufferTarget target, GL_APICALL GLboolean GL_APIENTRY glUnmapBuffer (GLenumBufferTarget target); GL_APICALL void* GL_APIENTRY glMapTexSubImage2DCHROMIUM (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, GLenum access); GL_APICALL void GL_APIENTRY glUnmapTexSubImage2DCHROMIUM (const void* mem); -GL_APICALL void GL_APIENTRY glResizeCHROMIUM (GLuint width, GLuint height, GLfloat scale_factor); +GL_APICALL void GL_APIENTRY glResizeCHROMIUM (GLuint width, GLuint height, GLfloat scale_factor, GLboolean alpha); GL_APICALL const GLchar* GL_APIENTRY glGetRequestableExtensionsCHROMIUM (void); GL_APICALL void GL_APIENTRY glRequestExtensionCHROMIUM (const char* extension); GL_APICALL void GL_APIENTRY glGetProgramInfoCHROMIUM (GLidProgram program, GLsizeiNotNegative bufsize, GLsizei* size, void* info); diff --git a/gpu/command_buffer/common/gles2_cmd_format_autogen.h b/gpu/command_buffer/common/gles2_cmd_format_autogen.h index 95bf3a8..b26cea0 100644 --- a/gpu/command_buffer/common/gles2_cmd_format_autogen.h +++ b/gpu/command_buffer/common/gles2_cmd_format_autogen.h @@ -11899,15 +11899,23 @@ struct ResizeCHROMIUM { void SetHeader() { header.SetCmd<ValueType>(); } - void Init(GLuint _width, GLuint _height, GLfloat _scale_factor) { + void Init(GLuint _width, + GLuint _height, + GLfloat _scale_factor, + GLboolean _alpha) { SetHeader(); width = _width; height = _height; scale_factor = _scale_factor; + alpha = _alpha; } - void* Set(void* cmd, GLuint _width, GLuint _height, GLfloat _scale_factor) { - static_cast<ValueType*>(cmd)->Init(_width, _height, _scale_factor); + void* Set(void* cmd, + GLuint _width, + GLuint _height, + GLfloat _scale_factor, + GLboolean _alpha) { + static_cast<ValueType*>(cmd)->Init(_width, _height, _scale_factor, _alpha); return NextCmdAddress<ValueType>(cmd); } @@ -11915,10 +11923,11 @@ struct ResizeCHROMIUM { uint32_t width; uint32_t height; float scale_factor; + uint32_t alpha; }; -static_assert(sizeof(ResizeCHROMIUM) == 16, - "size of ResizeCHROMIUM should be 16"); +static_assert(sizeof(ResizeCHROMIUM) == 20, + "size of ResizeCHROMIUM should be 20"); static_assert(offsetof(ResizeCHROMIUM, header) == 0, "offset of ResizeCHROMIUM header should be 0"); static_assert(offsetof(ResizeCHROMIUM, width) == 4, @@ -11927,6 +11936,8 @@ static_assert(offsetof(ResizeCHROMIUM, height) == 8, "offset of ResizeCHROMIUM height should be 8"); static_assert(offsetof(ResizeCHROMIUM, scale_factor) == 12, "offset of ResizeCHROMIUM scale_factor should be 12"); +static_assert(offsetof(ResizeCHROMIUM, alpha) == 16, + "offset of ResizeCHROMIUM alpha should be 16"); struct GetRequestableExtensionsCHROMIUM { typedef GetRequestableExtensionsCHROMIUM ValueType; diff --git a/gpu/command_buffer/common/gles2_cmd_format_test_autogen.h b/gpu/command_buffer/common/gles2_cmd_format_test_autogen.h index b165447..95a8ab8 100644 --- a/gpu/command_buffer/common/gles2_cmd_format_test_autogen.h +++ b/gpu/command_buffer/common/gles2_cmd_format_test_autogen.h @@ -4007,14 +4007,16 @@ TEST_F(GLES2FormatTest, UnmapBuffer) { TEST_F(GLES2FormatTest, ResizeCHROMIUM) { cmds::ResizeCHROMIUM& cmd = *GetBufferAs<cmds::ResizeCHROMIUM>(); - void* next_cmd = cmd.Set(&cmd, static_cast<GLuint>(11), - static_cast<GLuint>(12), static_cast<GLfloat>(13)); + void* next_cmd = + cmd.Set(&cmd, static_cast<GLuint>(11), static_cast<GLuint>(12), + static_cast<GLfloat>(13), static_cast<GLboolean>(14)); EXPECT_EQ(static_cast<uint32_t>(cmds::ResizeCHROMIUM::kCmdId), cmd.header.command); EXPECT_EQ(sizeof(cmd), cmd.header.size * 4u); EXPECT_EQ(static_cast<GLuint>(11), cmd.width); EXPECT_EQ(static_cast<GLuint>(12), cmd.height); EXPECT_EQ(static_cast<GLfloat>(13), cmd.scale_factor); + EXPECT_EQ(static_cast<GLboolean>(14), cmd.alpha); CheckBytesWrittenMatchesExpectedSize(next_cmd, sizeof(cmd)); } diff --git a/gpu/command_buffer/tests/gl_texture_mailbox_unittest.cc b/gpu/command_buffer/tests/gl_texture_mailbox_unittest.cc index 3ceb5ff..6025427 100644 --- a/gpu/command_buffer/tests/gl_texture_mailbox_unittest.cc +++ b/gpu/command_buffer/tests/gl_texture_mailbox_unittest.cc @@ -341,7 +341,7 @@ TEST_F(GLTextureMailboxTest, ProduceFrontBuffer) { EXPECT_EQ(static_cast<GLenum>(GL_NO_ERROR), glGetError()); gl2_.MakeCurrent(); - glResizeCHROMIUM(10, 10, 1); + glResizeCHROMIUM(10, 10, 1, true); glClearColor(1, 0, 0, 1); glClear(GL_COLOR_BUFFER_BIT); ::gles2::GetGLContext()->SwapBuffers(); @@ -430,7 +430,7 @@ TEST_F(GLTextureMailboxTest, ProduceFrontBufferMultipleContexts) { for (size_t i = 0; i < 2; ++i) { other_gl[i].MakeCurrent(); - glResizeCHROMIUM(10, 10, 1); + glResizeCHROMIUM(10, 10, 1, true); glClearColor(1-i%2, i%2, 0, 1); glClear(GL_COLOR_BUFFER_BIT); ::gles2::GetGLContext()->SwapBuffers(); diff --git a/mojo/gpu/mojo_gles2_impl_autogen.cc b/mojo/gpu/mojo_gles2_impl_autogen.cc index 8b57228..8f817e3 100644 --- a/mojo/gpu/mojo_gles2_impl_autogen.cc +++ b/mojo/gpu/mojo_gles2_impl_autogen.cc @@ -1410,9 +1410,10 @@ void MojoGLES2Impl::UnmapTexSubImage2DCHROMIUM(const void* mem) { } void MojoGLES2Impl::ResizeCHROMIUM(GLuint width, GLuint height, - GLfloat scale_factor) { + GLfloat scale_factor, + GLboolean alpha) { MojoGLES2MakeCurrent(context_); - glResizeCHROMIUM(width, height, scale_factor); + glResizeCHROMIUM(width, height, scale_factor, alpha); } const GLchar* MojoGLES2Impl::GetRequestableExtensionsCHROMIUM() { MojoGLES2MakeCurrent(context_); diff --git a/mojo/gpu/mojo_gles2_impl_autogen.h b/mojo/gpu/mojo_gles2_impl_autogen.h index 4b43bb97..e207ca4 100644 --- a/mojo/gpu/mojo_gles2_impl_autogen.h +++ b/mojo/gpu/mojo_gles2_impl_autogen.h @@ -649,7 +649,8 @@ class MojoGLES2Impl : public gpu::gles2::GLES2Interface { void UnmapTexSubImage2DCHROMIUM(const void* mem) override; void ResizeCHROMIUM(GLuint width, GLuint height, - GLfloat scale_factor) override; + GLfloat scale_factor, + GLboolean alpha) override; const GLchar* GetRequestableExtensionsCHROMIUM() override; void RequestExtensionCHROMIUM(const char* extension) override; void GetProgramInfoCHROMIUM(GLuint program, diff --git a/mojo/public/c/gles2/gles2_call_visitor_chromium_extension_autogen.h b/mojo/public/c/gles2/gles2_call_visitor_chromium_extension_autogen.h index c9b1c0a..a6c8585 100644 --- a/mojo/public/c/gles2/gles2_call_visitor_chromium_extension_autogen.h +++ b/mojo/public/c/gles2/gles2_call_visitor_chromium_extension_autogen.h @@ -140,10 +140,11 @@ VISIT_GL_CALL( GLenum access), (target, level, xoffset, yoffset, width, height, format, type, access)) VISIT_GL_CALL(UnmapTexSubImage2DCHROMIUM, void, (const void* mem), (mem)) -VISIT_GL_CALL(ResizeCHROMIUM, - void, - (GLuint width, GLuint height, GLfloat scale_factor), - (width, height, scale_factor)) +VISIT_GL_CALL( + ResizeCHROMIUM, + void, + (GLuint width, GLuint height, GLfloat scale_factor, GLboolean alpha), + (width, height, scale_factor, alpha)) VISIT_GL_CALL(GetRequestableExtensionsCHROMIUM, const GLchar*, (), ()) VISIT_GL_CALL(RequestExtensionCHROMIUM, void, diff --git a/ppapi/shared_impl/ppb_graphics_3d_shared.cc b/ppapi/shared_impl/ppb_graphics_3d_shared.cc index 854bf51..3dadacb 100644 --- a/ppapi/shared_impl/ppb_graphics_3d_shared.cc +++ b/ppapi/shared_impl/ppb_graphics_3d_shared.cc @@ -48,7 +48,7 @@ int32_t PPB_Graphics3D_Shared::ResizeBuffers(int32_t width, int32_t height) { if ((width < 0) || (height < 0)) return PP_ERROR_BADARGUMENT; - gles2_impl()->ResizeCHROMIUM(width, height, 1.f); + gles2_impl()->ResizeCHROMIUM(width, height, 1.f, true); // TODO(alokp): Check if resize succeeded and return appropriate error code. return PP_OK; } |