summaryrefslogtreecommitdiffstats
path: root/content/common/gpu/gpu_channel.cc
diff options
context:
space:
mode:
Diffstat (limited to 'content/common/gpu/gpu_channel.cc')
-rw-r--r--content/common/gpu/gpu_channel.cc13
1 files changed, 8 insertions, 5 deletions
diff --git a/content/common/gpu/gpu_channel.cc b/content/common/gpu/gpu_channel.cc
index e69d197..e83320d 100644
--- a/content/common/gpu/gpu_channel.cc
+++ b/content/common/gpu/gpu_channel.cc
@@ -27,13 +27,15 @@
GpuChannel::GpuChannel(GpuChannelManager* gpu_channel_manager,
GpuWatchdog* watchdog,
- int renderer_id)
+ int renderer_id,
+ bool software)
: gpu_channel_manager_(gpu_channel_manager),
renderer_id_(renderer_id),
renderer_process_(base::kNullProcessHandle),
renderer_pid_(base::kNullProcessId),
share_group_(new gfx::GLShareGroup),
- watchdog_(watchdog) {
+ watchdog_(watchdog),
+ software_(software) {
DCHECK(gpu_channel_manager);
DCHECK(renderer_id);
const CommandLine* command_line = CommandLine::ForCurrentProcess();
@@ -164,7 +166,7 @@ void GpuChannel::CreateViewCommandBuffer(
this, window, gfx::Size(), disallowed_extensions_,
init_params.allowed_extensions,
init_params.attribs, *route_id, renderer_id_, render_view_id,
- watchdog_));
+ watchdog_, software_));
router_.AddRoute(*route_id, stub.get());
stubs_.AddWithID(stub.release(), *route_id);
#endif // ENABLE_GPU
@@ -274,7 +276,8 @@ void GpuChannel::OnCreateOffscreenCommandBuffer(
init_params.allowed_extensions,
init_params.attribs,
*route_id,
- 0, 0, watchdog_));
+ 0, 0, watchdog_,
+ software_));
router_.AddRoute(*route_id, stub.get());
stubs_.AddWithID(stub.release(), *route_id);
TRACE_EVENT1("gpu", "GpuChannel::OnCreateOffscreenCommandBuffer",
@@ -306,7 +309,7 @@ void GpuChannel::OnCreateOffscreenSurface(const gfx::Size& size,
#if defined(ENABLE_GPU)
scoped_refptr<gfx::GLSurface> surface(
- gfx::GLSurface::CreateOffscreenGLSurface(size));
+ gfx::GLSurface::CreateOffscreenGLSurface(software_, size));
if (!surface.get())
return;