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

Side by Side Diff: gpu/gles2_conform_support/egl/display.cc

Issue 1902453002: Revert of Compute GpuDriverBugWorkarounds only one time in the GPU process (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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 unified diff | Download patch
« no previous file with comments | « gpu/gles2_conform_support/egl/display.h ('k') | gpu/gpu_config.gypi » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "gpu/gles2_conform_support/egl/display.h" 5 #include "gpu/gles2_conform_support/egl/display.h"
6 6
7 #include "base/command_line.h"
8 #include "gpu/gles2_conform_support/egl/config.h" 7 #include "gpu/gles2_conform_support/egl/config.h"
9 #include "gpu/gles2_conform_support/egl/context.h" 8 #include "gpu/gles2_conform_support/egl/context.h"
10 #include "gpu/gles2_conform_support/egl/surface.h" 9 #include "gpu/gles2_conform_support/egl/surface.h"
11 #include "gpu/gles2_conform_support/egl/thread_state.h" 10 #include "gpu/gles2_conform_support/egl/thread_state.h"
12 11
13 namespace egl { 12 namespace egl {
14 13
15 Display::Display() 14 Display::Display()
16 : is_initialized_(false), 15 : is_initialized_(false),
17 next_create_window_surface_creates_pbuffer_(false), 16 next_create_window_surface_creates_pbuffer_(false),
18 window_surface_pbuffer_width_(0), 17 window_surface_pbuffer_width_(0),
19 window_surface_pbuffer_height_(0), 18 window_surface_pbuffer_height_(0) {}
20 gpu_driver_bug_workarounds_(base::CommandLine::ForCurrentProcess()) {}
21 19
22 Display::~Display() { 20 Display::~Display() {
23 surfaces_.clear(); 21 surfaces_.clear();
24 contexts_.clear(); 22 contexts_.clear();
25 } 23 }
26 void Display::SetNextCreateWindowSurfaceCreatesPBuffer(EGLint width, 24 void Display::SetNextCreateWindowSurfaceCreatesPBuffer(EGLint width,
27 EGLint height) { 25 EGLint height) {
28 next_create_window_surface_creates_pbuffer_ = true; 26 next_create_window_surface_creates_pbuffer_ = true;
29 window_surface_pbuffer_width_ = width; 27 window_surface_pbuffer_width_ = width;
30 window_surface_pbuffer_height_ = height; 28 window_surface_pbuffer_height_ = height;
(...skipping 359 matching lines...) Expand 10 before | Expand all | Expand 10 after
390 388
391 Context* Display::GetContext(EGLContext context) { 389 Context* Display::GetContext(EGLContext context) {
392 lock_.AssertAcquired(); 390 lock_.AssertAcquired();
393 auto it = std::find(contexts_.begin(), contexts_.end(), context); 391 auto it = std::find(contexts_.begin(), contexts_.end(), context);
394 if (it == contexts_.end()) 392 if (it == contexts_.end())
395 return nullptr; 393 return nullptr;
396 return it->get(); 394 return it->get();
397 } 395 }
398 396
399 } // namespace egl 397 } // namespace egl
OLDNEW
« no previous file with comments | « gpu/gles2_conform_support/egl/display.h ('k') | gpu/gpu_config.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698