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

Side by Side Diff: src/gpu/GrContextFactory.cpp

Issue 1158433006: Store context options on caps. (Closed) Base URL: https://skia.googlesource.com/skia.git@onecaps
Patch Set: remove case statement accidentally checked in Created 5 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 | « src/gpu/GrContextFactory.h ('k') | src/gpu/GrDrawTarget.cpp » ('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 2014 Google Inc. 3 * Copyright 2014 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 "GrContextFactory.h" 9 #include "GrContextFactory.h"
10 10
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 } 68 }
69 } else { 69 } else {
70 glInterface.reset(GrGLInterfaceRemoveNVPR(glInterface)); 70 glInterface.reset(GrGLInterfaceRemoveNVPR(glInterface));
71 if (!glInterface) { 71 if (!glInterface) {
72 return NULL; 72 return NULL;
73 } 73 }
74 } 74 }
75 75
76 glCtx->makeCurrent(); 76 glCtx->makeCurrent();
77 GrBackendContext p3dctx = reinterpret_cast<GrBackendContext>(glInterface.get ()); 77 GrBackendContext p3dctx = reinterpret_cast<GrBackendContext>(glInterface.get ());
78 grCtx.reset(GrContext::Create(kOpenGL_GrBackend, p3dctx, &fGlobalOptions)); 78 grCtx.reset(GrContext::Create(kOpenGL_GrBackend, p3dctx, fGlobalOptions));
79 if (!grCtx.get()) { 79 if (!grCtx.get()) {
80 return NULL; 80 return NULL;
81 } 81 }
82 GPUContext& ctx = fContexts.push_back(); 82 GPUContext& ctx = fContexts.push_back();
83 ctx.fGLContext = glCtx.get(); 83 ctx.fGLContext = glCtx.get();
84 ctx.fGLContext->ref(); 84 ctx.fGLContext->ref();
85 ctx.fGrContext = grCtx.get(); 85 ctx.fGrContext = grCtx.get();
86 ctx.fGrContext->ref(); 86 ctx.fGrContext->ref();
87 ctx.fType = type; 87 ctx.fType = type;
88 return ctx.fGrContext; 88 return ctx.fGrContext;
89 } 89 }
OLDNEW
« no previous file with comments | « src/gpu/GrContextFactory.h ('k') | src/gpu/GrDrawTarget.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698