blob: 7bee11191b74d00ea7291cbc52061e5f73495add [file] [log] [blame]
twiz@google.com59a190b2011-03-14 21:23:01 +00001/*
2 Copyright 2011 Google Inc.
3
4 Licensed under the Apache License, Version 2.0 (the "License");
5 you may not use this file except in compliance with the License.
6 You may obtain a copy of the License at
7
8 http://www.apache.org/licenses/LICENSE-2.0
9
10 Unless required by applicable law or agreed to in writing, software
11 distributed under the License is distributed on an "AS IS" BASIS,
12 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 See the License for the specific language governing permissions and
14 limitations under the License.
15 */
16
17
18#ifndef GrGLInterface_DEFINED
19#define GrGLInterface_DEFINED
20
21#include "GrGLPlatformIncludes.h"
22
23#if !defined(GR_GL_FUNCTION_TYPE)
24 #define GR_GL_FUNCTION_TYPE
25#endif
26
27////////////////////////////////////////////////////////////////////////////////
28
29/**
30 * Helpers for glGetString()
31 */
32bool has_gl_extension(const char* ext);
33void gl_version(int* major, int* minor);
34
35////////////////////////////////////////////////////////////////////////////////
36
37/*
38 * Routines managing the global interface used to invoke OpenGL calls.
39 */
40struct GrGLInterface;
41extern GrGLInterface* GrGLGetGLInterface();
42extern void GrGLSetGLInterface(GrGLInterface* gl_interface);
43
44/*
45 * Populates the global GrGLInterface pointer with an instance pointing to the
46 * GL implementation linked with the executable.
47 */
48extern void GrGLSetDefaultGLInterface();
49
twiz@google.com0f31ca72011-03-18 17:38:11 +000050typedef unsigned int GrGLenum;
51typedef unsigned char GrGLboolean;
52typedef unsigned int GrGLbitfield;
53typedef signed char GrGLbyte;
54typedef short GrGLshort;
55typedef int GrGLint;
56typedef int GrGLsizei;
57typedef unsigned char GrGLubyte;
58typedef unsigned short GrGLushort;
59typedef unsigned int GrGLuint;
60typedef float GrGLfloat;
61typedef float GrGLclampf;
62typedef double GrGLdouble;
63typedef double GrGLclampd;
64typedef void GrGLvoid;
65
twiz@google.com59a190b2011-03-14 21:23:01 +000066extern "C" {
67/*
68 * The following interface exports the OpenGL entry points used by the system.
69 * Use of OpenGL calls is disallowed. All calls should be invoked through
70 * the global instance of this struct, defined above.
71 *
72 * IMPORTANT NOTE: The OpenGL entry points exposed here include both core GL
73 * functions, and extensions. The system assumes that the address of the
74 * extension pointer will be valid across contexts.
75 */
76struct GrGLInterface {
twiz@google.com0f31ca72011-03-18 17:38:11 +000077 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLActiveTextureProc)(GrGLenum texture);
78 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLAttachShaderProc)(GrGLuint program, GrGLuint shader);
79 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLBindAttribLocationProc)(GrGLuint program, GrGLuint index, const char* name);
80 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLBindBufferProc)(GrGLenum target, GrGLuint buffer);
81 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLBindTextureProc)(GrGLenum target, GrGLuint texture);
82 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLBlendColorProc)(GrGLclampf red, GrGLclampf green, GrGLclampf blue, GrGLclampf alpha);
83 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLBlendFuncProc)(GrGLenum sfactor, GrGLenum dfactor);
84 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLBufferDataProc)(GrGLenum target, GrGLsizei size, const GrGLvoid* data, GrGLenum usage);
85 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLBufferSubDataProc)(GrGLenum target, GrGLint offset, GrGLsizei size, const GrGLvoid* data);
86 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLClearProc)(GrGLbitfield mask);
87 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLClearColorProc)(GrGLclampf red, GrGLclampf green, GrGLclampf blue, GrGLclampf alpha);
88 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLClearStencilProc)(GrGLint s);
89 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLClientActiveTextureProc)(GrGLenum texture);
90 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLColor4ubProc)(GrGLubyte red, GrGLubyte green, GrGLubyte blue, GrGLubyte alpha);
91 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLColorMaskProc)(GrGLboolean red, GrGLboolean green, GrGLboolean blue, GrGLboolean alpha);
92 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLColorPointerProc)(GrGLint size, GrGLenum type, GrGLsizei stride, const GrGLvoid* pointer);
93 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLCompileShaderProc)(GrGLuint shader);
94 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLCompressedTexImage2DProc)(GrGLenum target, GrGLint level, GrGLenum internalformat, GrGLsizei width, GrGLsizei height, GrGLint border, GrGLsizei imageSize, const GrGLvoid* data);
95 typedef GrGLuint (GR_GL_FUNCTION_TYPE *GrGLCreateProgramProc)(void);
96 typedef GrGLuint (GR_GL_FUNCTION_TYPE *GrGLCreateShaderProc)(GrGLenum type);
97 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLCullFaceProc)(GrGLenum mode);
98 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLDeleteBuffersProc)(GrGLsizei n, const GrGLuint* buffers);
99 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLDeleteProgramProc)(GrGLuint program);
100 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLDeleteShaderProc)(GrGLuint shader);
101 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLDeleteTexturesProc)(GrGLsizei n, const GrGLuint* textures);
102 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLDepthMaskProc)(GrGLboolean flag);
103 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLDisableProc)(GrGLenum cap);
104 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLDisableClientStateProc)(GrGLenum array);
105 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLDisableVertexAttribArrayProc)(GrGLuint index);
106 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLDrawArraysProc)(GrGLenum mode, GrGLint first, GrGLsizei count);
107 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLDrawElementsProc)(GrGLenum mode, GrGLsizei count, GrGLenum type, const GrGLvoid* indices);
108 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLEnableProc)(GrGLenum cap);
109 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLEnableClientStateProc)(GrGLenum cap);
110 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLEnableVertexAttribArrayProc)(GrGLuint index);
111 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLFrontFaceProc)(GrGLenum mode);
112 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLGenBuffersProc)(GrGLsizei n, GrGLuint* buffers);
113 typedef GrGLenum (GR_GL_FUNCTION_TYPE *GrGLGetErrorProc)(void);
114 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLGenTexturesProc)(GrGLsizei n, GrGLuint* textures);
115 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLGetBufferParameterivProc)(GrGLenum target, GrGLenum pname, GrGLint* params);
116 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLGetIntegervProc)(GrGLenum pname, GrGLint* params);
117 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLGetProgramInfoLogProc)(GrGLuint program, GrGLsizei bufsize, GrGLsizei* length, char* infolog);
118 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLGetProgramivProc)(GrGLuint program, GrGLenum pname, GrGLint* params);
119 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLGetShaderInfoLogProc)(GrGLuint shader, GrGLsizei bufsize, GrGLsizei* length, char* infolog);
120 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLGetShaderivProc)(GrGLuint shader, GrGLenum pname, GrGLint* params);
121 typedef const GrGLubyte* (GR_GL_FUNCTION_TYPE *GrGLGetStringProc)(GrGLenum name);
122 typedef GrGLint (GR_GL_FUNCTION_TYPE *GrGLGetUniformLocationProc)(GrGLuint program, const char* name);
123 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLLineWidthProc)(GrGLfloat width);
124 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLLinkProgramProc)(GrGLuint program);
125 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLLoadMatrixfProc)(const GrGLfloat* m);
126 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLMatrixModeProc)(GrGLenum mode);
127 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLPixelStoreiProc)(GrGLenum pname, GrGLint param);
128 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLPointSizeProc)(GrGLfloat size);
129 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLReadPixelsProc)(GrGLint x, GrGLint y, GrGLsizei width, GrGLsizei height, GrGLenum format, GrGLenum type, GrGLvoid* pixels);
130 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLScissorProc)(GrGLint x, GrGLint y, GrGLsizei width, GrGLsizei height);
131 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLShadeModelProc)(GrGLenum mode);
132 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLShaderSourceProc)(GrGLuint shader, GrGLsizei count, const char** str, const GrGLint* length);
133 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLStencilFuncProc)(GrGLenum func, GrGLint ref, GrGLuint mask);
134 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLStencilFuncSeparateProc)(GrGLenum face, GrGLenum func, GrGLint ref, GrGLuint mask);
135 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLStencilMaskProc)(GrGLuint mask);
136 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLStencilMaskSeparateProc)(GrGLenum face, GrGLuint mask);
137 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLStencilOpProc)(GrGLenum fail, GrGLenum zfail, GrGLenum zpass);
138 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLStencilOpSeparateProc)(GrGLenum face, GrGLenum fail, GrGLenum zfail, GrGLenum zpass);
139 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLTexCoordPointerProc)(GrGLint size, GrGLenum type, GrGLsizei stride, const GrGLvoid* pointer);
140 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLTexEnviProc)(GrGLenum target, GrGLenum pname, GrGLint param);
141 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLTexImage2DProc)(GrGLenum target, GrGLint level, GrGLint internalformat, GrGLsizei width, GrGLsizei height, GrGLint border, GrGLenum format, GrGLenum type, const GrGLvoid* pixels);
142 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLTexParameteriProc)(GrGLenum target, GrGLenum pname, GrGLint param);
143 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLTexSubImage2DProc)(GrGLenum target, GrGLint level, GrGLint xoffset, GrGLint yoffset, GrGLsizei width, GrGLsizei height, GrGLenum format, GrGLenum type, const GrGLvoid* pixels);
144 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLUniform1fvProc)(GrGLint location, GrGLsizei count, const GrGLfloat* v);
145 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLUniform1iProc)(GrGLint location, GrGLint x);
146 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLUniform4fvProc)(GrGLint location, GrGLsizei count, const GrGLfloat* v);
147 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLUniformMatrix3fvProc)(GrGLint location, GrGLsizei count, GrGLboolean transpose, const GrGLfloat* value);
148 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLUseProgramProc)(GrGLuint program);
149 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLVertexAttrib4fvProc)(GrGLuint indx, const GrGLfloat* values);
150 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLVertexAttribPointerProc)(GrGLuint indx, GrGLint size, GrGLenum type, GrGLboolean normalized, GrGLsizei stride, const GrGLvoid* ptr);
151 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLVertexPointerProc)(GrGLint size, GrGLenum type, GrGLsizei stride, const GrGLvoid* pointer);
152 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLViewportProc)(GrGLint x, GrGLint y, GrGLsizei width, GrGLsizei height);
twiz@google.com59a190b2011-03-14 21:23:01 +0000153
154 // FBO Extension Functions
twiz@google.com0f31ca72011-03-18 17:38:11 +0000155 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLBindFramebufferProc)(GrGLenum target, GrGLuint framebuffer);
156 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLBindRenderbufferProc)(GrGLenum target, GrGLuint renderbuffer);
157 typedef GrGLenum (GR_GL_FUNCTION_TYPE *GrGLCheckFramebufferStatusProc)(GrGLenum target);
158 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLDeleteFramebuffersProc)(GrGLsizei n, const GrGLuint *framebuffers);
159 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLDeleteRenderbuffersProc)(GrGLsizei n, const GrGLuint *renderbuffers);
160 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLFramebufferRenderbufferProc)(GrGLenum target, GrGLenum attachment, GrGLenum renderbuffertarget, GrGLuint renderbuffer);
161 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLFramebufferTexture2DProc)(GrGLenum target, GrGLenum attachment, GrGLenum textarget, GrGLuint texture, GrGLint level);
162 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLGenFramebuffersProc)(GrGLsizei n, GrGLuint *framebuffers);
163 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLGenRenderbuffersProc)(GrGLsizei n, GrGLuint *renderbuffers);
164 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLRenderbufferStorageProc)(GrGLenum target, GrGLenum internalformat, GrGLsizei width, GrGLsizei height);
twiz@google.com59a190b2011-03-14 21:23:01 +0000165
166 // Multisampling Extension Functions
167 // same prototype for ARB_FBO, EXT_FBO, GL 3.0, & Apple ES extension
twiz@google.com0f31ca72011-03-18 17:38:11 +0000168 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLRenderbufferStorageMultisampleProc)(GrGLenum target, GrGLsizei samples, GrGLenum internalformat, GrGLsizei width, GrGLsizei height);
twiz@google.com59a190b2011-03-14 21:23:01 +0000169 // desktop: ext_fbo_blit, arb_fbo, gl 3.0
twiz@google.com0f31ca72011-03-18 17:38:11 +0000170 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLBlitFramebufferProc)(GrGLint srcX0, GrGLint srcY0, GrGLint srcX1, GrGLint srcY1, GrGLint dstX0, GrGLint dstY0, GrGLint dstX1, GrGLint dstY1, GrGLbitfield mask, GrGLenum filter);
twiz@google.com59a190b2011-03-14 21:23:01 +0000171 // apple's es extension
twiz@google.com0f31ca72011-03-18 17:38:11 +0000172 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLResolveMultisampleFramebufferProc)();
twiz@google.com59a190b2011-03-14 21:23:01 +0000173
174 // IMG'e es extension
twiz@google.com0f31ca72011-03-18 17:38:11 +0000175 typedef GrGLvoid (GR_GL_FUNCTION_TYPE *GrGLFramebufferTexture2DMultisampleProc)(GrGLenum target, GrGLenum attachment, GrGLenum textarget, GrGLuint texture, GrGLint level, GrGLsizei samples);
twiz@google.com59a190b2011-03-14 21:23:01 +0000176
177 // Buffer mapping (extension in ES).
twiz@google.com0f31ca72011-03-18 17:38:11 +0000178 typedef GrGLvoid* (GR_GL_FUNCTION_TYPE *GrGLMapBufferProc)(GrGLenum target, GrGLenum access);
179 typedef GrGLboolean (GR_GL_FUNCTION_TYPE *GrGLUnmapBufferProc)(GrGLenum target);
twiz@google.com59a190b2011-03-14 21:23:01 +0000180
181 GrGLActiveTextureProc fActiveTexture;
182 GrGLAttachShaderProc fAttachShader;
183 GrGLBindAttribLocationProc fBindAttribLocation;
184 GrGLBindBufferProc fBindBuffer;
185 GrGLBindTextureProc fBindTexture;
186 GrGLBlendFuncProc fBlendFunc;
bsalomon@google.com080773c2011-03-15 19:09:25 +0000187 GrGLBlendColorProc fBlendColor;
twiz@google.com59a190b2011-03-14 21:23:01 +0000188 GrGLBufferDataProc fBufferData;
189 GrGLBufferSubDataProc fBufferSubData;
190 GrGLClearProc fClear;
191 GrGLClearColorProc fClearColor;
192 GrGLClearStencilProc fClearStencil;
193 GrGLClientActiveTextureProc fClientActiveTexture;
194 GrGLColor4ubProc fColor4ub;
195 GrGLColorMaskProc fColorMask;
196 GrGLColorPointerProc fColorPointer;
197 GrGLCompileShaderProc fCompileShader;
198 GrGLCompressedTexImage2DProc fCompressedTexImage2D;
199 GrGLCreateProgramProc fCreateProgram;
200 GrGLCreateShaderProc fCreateShader;
201 GrGLCullFaceProc fCullFace;
202 GrGLDeleteBuffersProc fDeleteBuffers;
203 GrGLDeleteProgramProc fDeleteProgram;
204 GrGLDeleteShaderProc fDeleteShader;
205 GrGLDeleteTexturesProc fDeleteTextures;
206 GrGLDepthMaskProc fDepthMask;
207 GrGLDisableProc fDisable;
208 GrGLDisableClientStateProc fDisableClientState;
209 GrGLDisableVertexAttribArrayProc fDisableVertexAttribArray;
210 GrGLDrawArraysProc fDrawArrays;
211 GrGLDrawElementsProc fDrawElements;
212 GrGLEnableProc fEnable;
213 GrGLEnableClientStateProc fEnableClientState;
214 GrGLEnableVertexAttribArrayProc fEnableVertexAttribArray;
215 GrGLFrontFaceProc fFrontFace;
216 GrGLGenBuffersProc fGenBuffers;
217 GrGLGenTexturesProc fGenTextures;
218 GrGLGetBufferParameterivProc fGetBufferParameteriv;
219 GrGLGetErrorProc fGetError;
220 GrGLGetIntegervProc fGetIntegerv;
221 GrGLGetProgramInfoLogProc fGetProgramInfoLog;
222 GrGLGetProgramivProc fGetProgramiv;
223 GrGLGetShaderInfoLogProc fGetShaderInfoLog;
224 GrGLGetShaderivProc fGetShaderiv;
225 GrGLGetStringProc fGetString;
226 GrGLGetUniformLocationProc fGetUniformLocation;
227 GrGLLineWidthProc fLineWidth;
228 GrGLLinkProgramProc fLinkProgram;
229 GrGLLoadMatrixfProc fLoadMatrixf;
230 GrGLMatrixModeProc fMatrixMode;
231 GrGLPixelStoreiProc fPixelStorei;
232 GrGLPointSizeProc fPointSize;
233 GrGLReadPixelsProc fReadPixels;
234 GrGLScissorProc fScissor;
235 GrGLShadeModelProc fShadeModel;
236 GrGLShaderSourceProc fShaderSource;
237 GrGLStencilFuncProc fStencilFunc;
238 GrGLStencilFuncSeparateProc fStencilFuncSeparate;
239 GrGLStencilMaskProc fStencilMask;
240 GrGLStencilMaskSeparateProc fStencilMaskSeparate;
241 GrGLStencilOpProc fStencilOp;
242 GrGLStencilOpSeparateProc fStencilOpSeparate;
243 GrGLTexCoordPointerProc fTexCoordPointer;
244 GrGLTexEnviProc fTexEnvi;
245 GrGLTexImage2DProc fTexImage2D;
246 GrGLTexParameteriProc fTexParameteri;
247 GrGLTexSubImage2DProc fTexSubImage2D;
248 GrGLUniform1fvProc fUniform1fv;
249 GrGLUniform1iProc fUniform1i;
250 GrGLUniform4fvProc fUniform4fv;
251 GrGLUniformMatrix3fvProc fUniformMatrix3fv;
252 GrGLUseProgramProc fUseProgram;
253 GrGLVertexAttrib4fvProc fVertexAttrib4fv;
254 GrGLVertexAttribPointerProc fVertexAttribPointer;
255 GrGLVertexPointerProc fVertexPointer;
256 GrGLViewportProc fViewport;
257
258 // FBO Extension Functions
259 GrGLBindFramebufferProc fBindFramebuffer;
260 GrGLBindRenderbufferProc fBindRenderbuffer;
261 GrGLCheckFramebufferStatusProc fCheckFramebufferStatus;
262 GrGLDeleteFramebuffersProc fDeleteFramebuffers;
263 GrGLDeleteRenderbuffersProc fDeleteRenderbuffers;
264 GrGLFramebufferRenderbufferProc fFramebufferRenderbuffer;
265 GrGLFramebufferTexture2DProc fFramebufferTexture2D;
266 GrGLGenFramebuffersProc fGenFramebuffers;
267 GrGLGenRenderbuffersProc fGenRenderbuffers;
268 GrGLRenderbufferStorageProc fRenderbufferStorage;
269
270 // Multisampling Extension Functions
271 // same prototype for ARB_FBO, EXT_FBO, GL 3.0, & Apple ES extension
272 GrGLRenderbufferStorageMultisampleProc fRenderbufferStorageMultisample;
273 // desktop: ext_fbo_blit, arb_fbo, gl 3.0
274 GrGLBlitFramebufferProc fBlitFramebuffer;
275 // apple's es extension
276 GrGLResolveMultisampleFramebufferProc fResolveMultisampleFramebuffer;
277
278 // IMG'e es extension
279 GrGLFramebufferTexture2DMultisampleProc fFramebufferTexture2DMultisample;
280
281 // Buffer mapping (extension in ES).
282 GrGLMapBufferProc fMapBuffer;
283 GrGLUnmapBufferProc fUnmapBuffer;
284};
285
286} // extern "C"
287
288#endif