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

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

Issue 1684413003: Implement support for using GL ES 3.0 with command buffer (Closed) Base URL: https://skia.googlesource.com/skia.git@no-texture-rectangle-gles
Patch Set: Created 4 years, 10 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
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 80 matching lines...) Expand 10 before | Expand all | Expand 10 after
91 break; 91 break;
92 #endif 92 #endif
93 case kANGLE_GL_GLContextType: 93 case kANGLE_GL_GLContextType:
94 glCtx.reset(SkANGLEGLContext::CreateOpenGL()); 94 glCtx.reset(SkANGLEGLContext::CreateOpenGL());
95 break; 95 break;
96 #endif 96 #endif
97 #if SK_COMMAND_BUFFER 97 #if SK_COMMAND_BUFFER
98 case kCommandBuffer_GLContextType: 98 case kCommandBuffer_GLContextType:
99 glCtx.reset(SkCommandBufferGLContext::Create()); 99 glCtx.reset(SkCommandBufferGLContext::Create());
100 break; 100 break;
101 case kCommandBufferES3_GLContextType:
102 glCtx.reset(SkCommandBufferGLContext::CreateES3());
103 break;
101 #endif 104 #endif
102 #if SK_MESA 105 #if SK_MESA
103 case kMESA_GLContextType: 106 case kMESA_GLContextType:
104 glCtx.reset(SkMesaGLContext::Create()); 107 glCtx.reset(SkMesaGLContext::Create());
105 break; 108 break;
106 #endif 109 #endif
107 case kNull_GLContextType: 110 case kNull_GLContextType:
108 glCtx.reset(SkNullGLContext::Create()); 111 glCtx.reset(SkNullGLContext::Create());
109 break; 112 break;
110 case kDebug_GLContextType: 113 case kDebug_GLContextType:
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
142 } 145 }
143 } 146 }
144 147
145 Context& context = fContexts.push_back(); 148 Context& context = fContexts.push_back();
146 context.fGLContext = glCtx.detach(); 149 context.fGLContext = glCtx.detach();
147 context.fGrContext = SkRef(grCtx.get()); 150 context.fGrContext = SkRef(grCtx.get());
148 context.fType = type; 151 context.fType = type;
149 context.fOptions = options; 152 context.fOptions = options;
150 return ContextInfo(context.fGrContext, context.fGLContext); 153 return ContextInfo(context.fGrContext, context.fGLContext);
151 } 154 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698