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

Unified Diff: gpu/ipc/service/gpu_command_buffer_stub.cc

Issue 2497503004: Revert of Refactor context creation parameters into a struct. (Closed)
Patch Set: Created 4 years, 1 month 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 | « gpu/gles2_conform_support/egl/context.cc ('k') | gpu/perftests/texture_upload_perftest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gpu/ipc/service/gpu_command_buffer_stub.cc
diff --git a/gpu/ipc/service/gpu_command_buffer_stub.cc b/gpu/ipc/service/gpu_command_buffer_stub.cc
index 964cc2f49154cc17edd9113ca499aede0e708af7..74b419744071f3172560048b503086c3ec6600b4 100644
--- a/gpu/ipc/service/gpu_command_buffer_stub.cc
+++ b/gpu/ipc/service/gpu_command_buffer_stub.cc
@@ -27,7 +27,6 @@
#include "gpu/command_buffer/service/mailbox_manager.h"
#include "gpu/command_buffer/service/memory_tracking.h"
#include "gpu/command_buffer/service/query_manager.h"
-#include "gpu/command_buffer/service/service_utils.h"
#include "gpu/command_buffer/service/sync_point_manager.h"
#include "gpu/command_buffer/service/transfer_buffer_manager.h"
#include "gpu/ipc/common/gpu_messages.h"
@@ -538,10 +537,8 @@
if (use_virtualized_gl_context_ && gl_share_group) {
context = gl_share_group->GetSharedContext(surface_.get());
if (!context.get()) {
- context = gl::init::CreateGLContext(
- gl_share_group, surface_.get(),
- GenerateGLContextAttribs(init_params.attribs,
- context_group_->gpu_preferences()));
+ context = gl::init::CreateGLContext(gl_share_group, surface_.get(),
+ init_params.attribs.gpu_preference);
if (!context.get()) {
DLOG(ERROR) << "Failed to create shared context for virtualization.";
return false;
@@ -558,10 +555,8 @@
gl::GetGLImplementation() == gl::kGLImplementationMockGL);
context = new GLContextVirtual(
gl_share_group, context.get(), decoder_->AsWeakPtr());
- if (!context->Initialize(
- surface_.get(),
- GenerateGLContextAttribs(init_params.attribs,
- context_group_->gpu_preferences()))) {
+ if (!context->Initialize(surface_.get(),
+ init_params.attribs.gpu_preference)) {
// The real context created above for the default offscreen surface
// might not be compatible with this surface.
context = NULL;
@@ -570,10 +565,8 @@
}
}
if (!context.get()) {
- context = gl::init::CreateGLContext(
- gl_share_group, surface_.get(),
- GenerateGLContextAttribs(init_params.attribs,
- context_group_->gpu_preferences()));
+ context = gl::init::CreateGLContext(gl_share_group, surface_.get(),
+ init_params.attribs.gpu_preference);
}
if (!context.get()) {
DLOG(ERROR) << "Failed to create context.";
« no previous file with comments | « gpu/gles2_conform_support/egl/context.cc ('k') | gpu/perftests/texture_upload_perftest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698