Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(148)

Unified Diff: gpu/command_buffer/service/in_process_command_buffer.cc

Issue 1168993002: Update the native_viewport interface to allow specification of the surface configuration, currently… (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Requested fixes and a few other minor corrections Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: gpu/command_buffer/service/in_process_command_buffer.cc
diff --git a/gpu/command_buffer/service/in_process_command_buffer.cc b/gpu/command_buffer/service/in_process_command_buffer.cc
index 65986f82540b9945fb79f2d626b319bbe4b5dbfb..16a6f1441e29af2c03a59fdcfe7f94595efa61f9 100644
--- a/gpu/command_buffer/service/in_process_command_buffer.cc
+++ b/gpu/command_buffer/service/in_process_command_buffer.cc
@@ -343,7 +343,8 @@ bool InProcessCommandBuffer::Initialize(
const base::Closure& context_lost_callback,
InProcessCommandBuffer* share_group,
GpuMemoryBufferManager* gpu_memory_buffer_manager,
- ImageFactory* image_factory) {
+ ImageFactory* image_factory,
+ const gfx::SurfaceConfiguration requested_configuration) {
qsr 2015/06/09 11:02:52 Same here.
iansf 2015/06/09 17:23:24 Done.
DCHECK(!share_group || service_.get() == share_group->service_.get());
context_lost_callback_ = WrapCallback(context_lost_callback);
@@ -362,7 +363,8 @@ bool InProcessCommandBuffer::Initialize(
gpu_preference,
&capabilities,
share_group,
- image_factory);
+ image_factory,
+ requested_configuration);
base::Callback<bool(void)> init_task =
base::Bind(&InProcessCommandBuffer::InitializeOnGpuThread,
@@ -439,9 +441,11 @@ bool InProcessCommandBuffer::InitializeOnGpuThread(
if (!surface_.get()) {
if (params.is_offscreen)
- surface_ = gfx::GLSurface::CreateOffscreenGLSurface(params.size);
+ surface_ = gfx::GLSurface::CreateOffscreenGLSurface(
+ params.size, params.requested_configuration);
else
- surface_ = gfx::GLSurface::CreateViewGLSurface(params.window);
+ surface_ = gfx::GLSurface::CreateViewGLSurface(
+ params.window, params.requested_configuration);
}
if (!surface_.get()) {

Powered by Google App Engine
This is Rietveld 408576698