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

Side by Side Diff: tools/gpu/gl/command_buffer/GLTestContext_command_buffer.cpp

Issue 1975753005: Remove NVPR related env var from command buffer GL context creation (Closed) Base URL: https://skia.googlesource.com/skia.git@command-buffer-egl-display
Patch Set: Created 4 years, 7 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 | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 1
2 /* 2 /*
3 * Copyright 2015 Google Inc. 3 * Copyright 2015 Google Inc.
4 * 4 *
5 * Use of this source code is governed by a BSD-style license that can be 5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file. 6 * found in the LICENSE file.
7 */ 7 */
8 8
9 #include "SkMutex.h" 9 #include "SkMutex.h"
10 #include "SkOnce.h" 10 #include "SkOnce.h"
(...skipping 177 matching lines...) Expand 10 before | Expand all | Expand 10 after
188 } 188 }
189 189
190 void CommandBufferGLTestContext::initializeGLContext(void *nativeWindow, const i nt *configAttribs, 190 void CommandBufferGLTestContext::initializeGLContext(void *nativeWindow, const i nt *configAttribs,
191 const int *surfaceAttribs) { 191 const int *surfaceAttribs) {
192 load_command_buffer_once(); 192 load_command_buffer_once();
193 if (!gfFunctionsLoadedSuccessfully) { 193 if (!gfFunctionsLoadedSuccessfully) {
194 SkDebugf("Command Buffer: Could not load EGL functions.\n"); 194 SkDebugf("Command Buffer: Could not load EGL functions.\n");
195 return; 195 return;
196 } 196 }
197 197
198 // Make sure CHROMIUM_path_rendering is enabled for NVPR support.
199 sk_setenv("CHROME_COMMAND_BUFFER_GLES2_ARGS", "--enable-gl-path-rendering");
200 fDisplay = gfGetDisplay(EGL_DEFAULT_DISPLAY); 198 fDisplay = gfGetDisplay(EGL_DEFAULT_DISPLAY);
201 if (EGL_NO_DISPLAY == fDisplay) { 199 if (EGL_NO_DISPLAY == fDisplay) {
202 SkDebugf("Command Buffer: Could not create EGL display.\n"); 200 SkDebugf("Command Buffer: Could not create EGL display.\n");
203 return; 201 return;
204 } 202 }
205 if (!gfInitialize(fDisplay, nullptr, nullptr)) { 203 if (!gfInitialize(fDisplay, nullptr, nullptr)) {
206 SkDebugf("Command Buffer: Could not initialize EGL display.\n"); 204 SkDebugf("Command Buffer: Could not initialize EGL display.\n");
207 this->destroyGLContext(); 205 this->destroyGLContext();
208 return; 206 return;
209 } 207 }
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after
335 return result; 333 return result;
336 } 334 }
337 335
338 int CommandBufferGLTestContext::getSampleCount() { 336 int CommandBufferGLTestContext::getSampleCount() {
339 EGLint result = 0; 337 EGLint result = 0;
340 gfGetConfigAttrib(fDisplay, static_cast<EGLConfig>(fConfig), EGL_SAMPLES, &r esult); 338 gfGetConfigAttrib(fDisplay, static_cast<EGLConfig>(fConfig), EGL_SAMPLES, &r esult);
341 return result; 339 return result;
342 } 340 }
343 341
344 } // namespace sk_gpu_test 342 } // namespace sk_gpu_test
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698