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

Side by Side Diff: tools/gpu/gl/win/CreatePlatformGLTestContext_win.cpp

Issue 1919993002: Added --deepColor option to SampleApp, triggers creation of a ten-bit/channel buffer on Windows. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Rebase 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 | « tools/VisualBench/VisualBench.cpp ('k') | tools/viewer/android/Window_android.h » ('j') | 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 2011 Google Inc. 3 * Copyright 2011 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 "gl/GLTestContext.h" 9 #include "gl/GLTestContext.h"
10 10
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
85 SkWGLContextRequest contextType = 85 SkWGLContextRequest contextType =
86 kGLES_GrGLStandard == forcedGpuAPI ? 86 kGLES_GrGLStandard == forcedGpuAPI ?
87 kGLES_SkWGLContextRequest : kGLPreferCompatibilityProfile_SkWGLContextRe quest; 87 kGLES_SkWGLContextRequest : kGLPreferCompatibilityProfile_SkWGLContextRe quest;
88 88
89 fPbufferContext = SkWGLPbufferContext::Create(fDeviceContext, 0, contextType ); 89 fPbufferContext = SkWGLPbufferContext::Create(fDeviceContext, 0, contextType );
90 90
91 HDC dc; 91 HDC dc;
92 HGLRC glrc; 92 HGLRC glrc;
93 93
94 if (nullptr == fPbufferContext) { 94 if (nullptr == fPbufferContext) {
95 if (!(fGlRenderContext = SkCreateWGLContext(fDeviceContext, 0, contextTy pe))) { 95 if (!(fGlRenderContext = SkCreateWGLContext(fDeviceContext, 0, false, co ntextType))) {
96 SkDebugf("Could not create rendering context.\n"); 96 SkDebugf("Could not create rendering context.\n");
97 this->destroyGLContext(); 97 this->destroyGLContext();
98 return; 98 return;
99 } 99 }
100 dc = fDeviceContext; 100 dc = fDeviceContext;
101 glrc = fGlRenderContext; 101 glrc = fGlRenderContext;
102 } else { 102 } else {
103 ReleaseDC(fWindow, fDeviceContext); 103 ReleaseDC(fWindow, fDeviceContext);
104 fDeviceContext = 0; 104 fDeviceContext = 0;
105 DestroyWindow(fWindow); 105 DestroyWindow(fWindow);
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
196 } 196 }
197 WinGLTestContext *ctx = new WinGLTestContext(forcedGpuAPI); 197 WinGLTestContext *ctx = new WinGLTestContext(forcedGpuAPI);
198 if (!ctx->isValid()) { 198 if (!ctx->isValid()) {
199 delete ctx; 199 delete ctx;
200 return nullptr; 200 return nullptr;
201 } 201 }
202 return ctx; 202 return ctx;
203 } 203 }
204 } // namespace sk_gpu_test 204 } // namespace sk_gpu_test
205 205
OLDNEW
« no previous file with comments | « tools/VisualBench/VisualBench.cpp ('k') | tools/viewer/android/Window_android.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698