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

Side by Side Diff: src/gpu/gl/angle/GrGLCreateANGLEInterface.cpp

Issue 243413002: Add support for glMapBufferRange. Use glMapBufferRange and glMapBufferSubData. (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: rebase to tot Created 6 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 | Annotate | Revision Log
OLDNEW
1 1
2 /* 2 /*
3 * Copyright 2012 Google Inc. 3 * Copyright 2012 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 9
10 #include "gl/GrGLInterface.h" 10 #include "gl/GrGLInterface.h"
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after
147 GET_PROC(FramebufferTexture2D); 147 GET_PROC(FramebufferTexture2D);
148 GET_PROC(GenFramebuffers); 148 GET_PROC(GenFramebuffers);
149 GET_PROC(GenRenderbuffers); 149 GET_PROC(GenRenderbuffers);
150 GET_PROC(GetFramebufferAttachmentParameteriv); 150 GET_PROC(GetFramebufferAttachmentParameteriv);
151 GET_PROC(GetRenderbufferParameteriv); 151 GET_PROC(GetRenderbufferParameteriv);
152 GET_PROC(RenderbufferStorage); 152 GET_PROC(RenderbufferStorage);
153 153
154 functions->fMapBuffer = (GrGLMapBufferProc) eglGetProcAddress("glMapBufferOE S"); 154 functions->fMapBuffer = (GrGLMapBufferProc) eglGetProcAddress("glMapBufferOE S");
155 functions->fUnmapBuffer = (GrGLUnmapBufferProc) eglGetProcAddress("glUnmapBu fferOES"); 155 functions->fUnmapBuffer = (GrGLUnmapBufferProc) eglGetProcAddress("glUnmapBu fferOES");
156 156
157 #if GL_ES_VERSION_3_0
158 functions->fMapBufferRange = GET_PROC(glMapBufferRange);
159 functions->fFlushMappedBufferRange = GET_PROC(glFlushMappedBufferRange);
160 #else
161 functions->fMapBufferRange = (GrGLMapBufferRangeProc) eglGetProcAddress("glM apBufferRange");
162 functions->fFlushMappedBufferRange = (GrGLFlushMappedBufferRangeProc) eglGet ProcAddress("glFlushMappedBufferRange");
163 #endif
164
157 functions->fInsertEventMarker = (GrGLInsertEventMarkerProc) eglGetProcAddres s("glInsertEventMarkerEXT"); 165 functions->fInsertEventMarker = (GrGLInsertEventMarkerProc) eglGetProcAddres s("glInsertEventMarkerEXT");
158 functions->fPushGroupMarker = (GrGLInsertEventMarkerProc) eglGetProcAddress( "glPushGroupMarkerEXT"); 166 functions->fPushGroupMarker = (GrGLInsertEventMarkerProc) eglGetProcAddress( "glPushGroupMarkerEXT");
159 functions->fPopGroupMarker = (GrGLPopGroupMarkerProc) eglGetProcAddress("glP opGroupMarkerEXT"); 167 functions->fPopGroupMarker = (GrGLPopGroupMarkerProc) eglGetProcAddress("glP opGroupMarkerEXT");
160 168
161 #if GL_ES_VERSION_3_0 169 #if GL_ES_VERSION_3_0
162 GET_PROC(InvalidateFramebuffer); 170 GET_PROC(InvalidateFramebuffer);
163 GET_PROC(InvalidateSubFramebuffer); 171 GET_PROC(InvalidateSubFramebuffer);
164 #else 172 #else
165 functions->fInvalidateFramebuffer = (GrGLInvalidateFramebufferProc) eglGetPr ocAddress("glInvalidateFramebuffer"); 173 functions->fInvalidateFramebuffer = (GrGLInvalidateFramebufferProc) eglGetPr ocAddress("glInvalidateFramebuffer");
166 functions->fInvalidateSubFramebuffer = (GrGLInvalidateSubFramebufferProc) eg lGetProcAddress("glInvalidateSubFramebuffer"); 174 functions->fInvalidateSubFramebuffer = (GrGLInvalidateSubFramebufferProc) eg lGetProcAddress("glInvalidateSubFramebuffer");
167 #endif 175 #endif
168 functions->fInvalidateBufferData = (GrGLInvalidateBufferDataProc) eglGetProc Address("glInvalidateBufferData"); 176 functions->fInvalidateBufferData = (GrGLInvalidateBufferDataProc) eglGetProc Address("glInvalidateBufferData");
169 functions->fInvalidateBufferSubData = (GrGLInvalidateBufferSubDataProc) eglG etProcAddress("glInvalidateBufferSubData"); 177 functions->fInvalidateBufferSubData = (GrGLInvalidateBufferSubDataProc) eglG etProcAddress("glInvalidateBufferSubData");
170 functions->fInvalidateTexImage = (GrGLInvalidateTexImageProc) eglGetProcAddr ess("glInvalidateTexImage"); 178 functions->fInvalidateTexImage = (GrGLInvalidateTexImageProc) eglGetProcAddr ess("glInvalidateTexImage");
171 functions->fInvalidateTexSubImage = (GrGLInvalidateTexSubImageProc) eglGetPr ocAddress("glInvalidateTexSubImage"); 179 functions->fInvalidateTexSubImage = (GrGLInvalidateTexSubImageProc) eglGetPr ocAddress("glInvalidateTexSubImage");
172 180
173 interface->fExtensions.init(kGLES_GrGLStandard, 181 interface->fExtensions.init(kGLES_GrGLStandard,
174 functions->fGetString, 182 functions->fGetString,
175 functions->fGetStringi, 183 functions->fGetStringi,
176 functions->fGetIntegerv); 184 functions->fGetIntegerv);
177 return interface; 185 return interface;
178 } 186 }
OLDNEW
« no previous file with comments | « src/gpu/gl/android/GrGLCreateNativeInterface_android.cpp ('k') | src/gpu/gl/debug/GrBufferObj.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698