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

Unified Diff: services/gles2/command_buffer_driver.cc

Issue 940293003: Add a Display and ContextProvider concept to mojom, use to recreate (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 10 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
« no previous file with comments | « services/gles2/command_buffer_driver.h ('k') | services/gles2/gpu_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: services/gles2/command_buffer_driver.cc
diff --git a/services/gles2/command_buffer_driver.cc b/services/gles2/command_buffer_driver.cc
index 98b85780de92d3314d364c4d8539aee8a59c3444..50d1b9761837b103cfde6748cbd3cd0053a4f050 100644
--- a/services/gles2/command_buffer_driver.cc
+++ b/services/gles2/command_buffer_driver.cc
@@ -55,7 +55,6 @@ CommandBufferDriver::CommandBufferDriver(
gpu::gles2::MailboxManager* mailbox_manager,
gpu::SyncPointManager* sync_point_manager)
: CommandBufferDriver(gfx::kNullAcceleratedWidget,
- gfx::Size(1, 1),
share_group,
mailbox_manager,
sync_point_manager) {
@@ -63,13 +62,11 @@ CommandBufferDriver::CommandBufferDriver(
CommandBufferDriver::CommandBufferDriver(
gfx::AcceleratedWidget widget,
- const gfx::Size& size,
gfx::GLShareGroup* share_group,
gpu::gles2::MailboxManager* mailbox_manager,
gpu::SyncPointManager* sync_point_manager)
: client_(nullptr),
widget_(widget),
- size_(size),
share_group_(share_group),
mailbox_manager_(mailbox_manager),
sync_point_manager_(sync_point_manager),
@@ -99,7 +96,7 @@ void CommandBufferDriver::Initialize(
bool CommandBufferDriver::DoInitialize(
mojo::ScopedSharedBufferHandle shared_state) {
if (widget_ == gfx::kNullAcceleratedWidget)
- surface_ = gfx::GLSurface::CreateOffscreenGLSurface(size_);
+ surface_ = gfx::GLSurface::CreateOffscreenGLSurface(gfx::Size(1, 1));
else {
surface_ = gfx::GLSurface::CreateViewGLSurface(widget_);
if (auto vsync_provider = surface_->GetVSyncProvider()) {
@@ -148,8 +145,9 @@ bool CommandBufferDriver::DoInitialize(
// TODO(piman): attributes.
std::vector<int32> attrib_vector;
- if (!decoder_->Initialize(surface_, context_, false /* offscreen */, size_,
- disallowed_features, attrib_vector))
+ if (!decoder_->Initialize(surface_, context_, false /* offscreen */,
+ gfx::Size(1, 1), disallowed_features,
+ attrib_vector))
return false;
command_buffer_->SetPutOffsetChangeCallback(base::Bind(
« no previous file with comments | « services/gles2/command_buffer_driver.h ('k') | services/gles2/gpu_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698