2 * Copyright (C) 2010 Tieto Corporation.
3 * Copyright (C) 2011 Igalia S.L.
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
15 * You should have received a copy of the GNU Lesser General Public
16 * License along with this library; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
25 #include <qopenglfunctions.h>
26 #include <QOpenGLContext>
32 #if defined(GL_ES_VERSION_2_0)
33 // Some openGL ES systems miss this typedef.
37 typedef struct _OpenGLFunctionTable OpenGLFunctionTable;
40 bool initializeOpenGLShims();
41 OpenGLFunctionTable* openGLFunctionTable();
45 #define GLAPIENTRY __stdcall
50 typedef void (GLAPIENTRY *glActiveTextureType) (GLenum);
51 typedef void (GLAPIENTRY *glAttachShaderType) (GLuint, GLuint);
52 typedef void (GLAPIENTRY *glBindAttribLocationType) (GLuint, GLuint, const char*);
53 typedef void (GLAPIENTRY *glBindBufferType) (GLenum, GLuint);
54 typedef void (GLAPIENTRY *glBindFramebufferType) (GLenum, GLuint);
55 typedef void (GLAPIENTRY *glBindRenderbufferType) (GLenum, GLuint);
56 typedef void (GLAPIENTRY *glBlendColorType) (GLclampf, GLclampf, GLclampf, GLclampf);
57 typedef void (GLAPIENTRY *glBlendEquationType) (GLenum);
58 typedef void (GLAPIENTRY *glBlendEquationSeparateType)(GLenum, GLenum);
59 typedef void (GLAPIENTRY *glBlendFuncSeparateType)(GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha);
60 typedef void (GLAPIENTRY *glBlitFramebufferType) (GLint, GLint, GLint, GLint, GLint, GLint, GLint, GLint, GLbitfield, GLenum);
61 typedef void (GLAPIENTRY *glBufferDataType) (GLenum, GLsizeiptr, const GLvoid*, GLenum);
62 typedef void (GLAPIENTRY *glBufferSubDataType) (GLenum, GLintptr, GLsizeiptr, const GLvoid*);
63 typedef GLenum (GLAPIENTRY *glCheckFramebufferStatusType) (GLenum);
64 typedef void (GLAPIENTRY *glCompileShaderType) (GLuint);
65 typedef GLuint (GLAPIENTRY *glCreateProgramType) ();
66 typedef GLuint (GLAPIENTRY *glCreateShaderType) (GLenum);
67 typedef void (GLAPIENTRY *glDeleteBuffersType) (GLsizei, const GLuint*);
68 typedef void (GLAPIENTRY *glDeleteFramebuffersType) (GLsizei n, const GLuint*);
69 typedef void (GLAPIENTRY *glDeleteProgramType) (GLuint);
70 typedef void (GLAPIENTRY *glDeleteRenderbuffersType) (GLsizei n, const GLuint*);
71 typedef void (GLAPIENTRY *glDeleteShaderType) (GLuint);
72 typedef void (GLAPIENTRY *glDetachShaderType) (GLuint, GLuint);
73 typedef void (GLAPIENTRY *glDisableVertexAttribArrayType) (GLuint);
74 typedef void (GLAPIENTRY *glEnableVertexAttribArrayType) (GLuint);
75 typedef void (GLAPIENTRY *glFramebufferRenderbufferType) (GLenum, GLenum, GLenum, GLuint);
76 typedef void (GLAPIENTRY *glFramebufferTexture2DType) (GLenum, GLenum, GLenum, GLuint, GLint);
77 typedef void (GLAPIENTRY *glGenBuffersType) (GLsizei, GLuint*);
78 typedef void (GLAPIENTRY *glGenerateMipmapType) (GLenum target);
79 typedef void (GLAPIENTRY *glGenFramebuffersType) (GLsizei, GLuint*);
80 typedef void (GLAPIENTRY *glGenRenderbuffersType) (GLsizei, GLuint*);
81 typedef void (GLAPIENTRY *glGetActiveAttribType) (GLuint, GLuint, GLsizei, GLsizei*, GLint*, GLenum*, GLchar*);
82 typedef void (GLAPIENTRY *glGetActiveUniformType) (GLuint, GLuint, GLsizei, GLsizei*, GLint*, GLenum*, GLchar*);
83 typedef void (GLAPIENTRY *glGetAttachedShadersType) (GLuint, GLsizei, GLsizei*, GLuint*);
84 typedef GLint (GLAPIENTRY *glGetAttribLocationType) (GLuint, const char*);
85 typedef void (GLAPIENTRY *glGetBufferParameterivType) (GLenum, GLenum, GLint*);
86 typedef void (GLAPIENTRY *glGetFramebufferAttachmentParameterivType) (GLenum, GLenum, GLenum, GLint* params);
87 typedef void (GLAPIENTRY *glGetProgramInfoLogType) (GLuint, GLsizei, GLsizei*, char*);
88 typedef void (GLAPIENTRY *glGetProgramivType) (GLuint, GLenum, GLint*);
89 typedef void (GLAPIENTRY *glGetRenderbufferParameterivType) (GLenum, GLenum, GLint*);
90 typedef void (GLAPIENTRY *glGetShaderInfoLogType) (GLuint, GLsizei, GLsizei*, char*);
91 typedef void (GLAPIENTRY *glGetShaderivType) (GLuint, GLenum, GLint*);
92 typedef void (GLAPIENTRY *glGetShaderSourceType) (GLuint, GLsizei, GLsizei*, char*);
93 typedef GLint (GLAPIENTRY *glGetUniformLocationType) (GLuint, const char*);
94 typedef void (GLAPIENTRY *glGetUniformfvType) (GLuint, GLint, GLfloat*);
95 typedef void (GLAPIENTRY *glGetUniformivType) (GLuint, GLint, GLint*);
96 typedef void (GLAPIENTRY *glGetVertexAttribfvType) (GLuint, GLenum, GLfloat*);
97 typedef void (GLAPIENTRY *glGetVertexAttribivType) (GLuint, GLenum, GLint*);
98 typedef void (GLAPIENTRY *glGetVertexAttribPointervType) (GLuint, GLenum, GLvoid**);
99 typedef GLboolean (GLAPIENTRY *glIsBufferType) (GLuint);
100 typedef GLboolean (GLAPIENTRY *glIsFramebufferType) (GLuint);
101 typedef GLboolean (GLAPIENTRY *glIsProgramType) (GLuint);
102 typedef GLboolean (GLAPIENTRY *glIsRenderbufferType) (GLuint);
103 typedef GLboolean (GLAPIENTRY *glIsShaderType) (GLuint);
104 typedef void (GLAPIENTRY *glLinkProgramType) (GLuint);
105 typedef void (GLAPIENTRY *glRenderbufferStorageType) (GLenum, GLenum, GLsizei, GLsizei);
106 typedef void (GLAPIENTRY *glRenderbufferStorageMultisampleType) (GLenum, GLsizei, GLenum, GLsizei, GLsizei);
107 typedef void (GLAPIENTRY *glSampleCoverageType) (GLclampf, GLboolean);
108 typedef void (GLAPIENTRY *glShaderSourceType) (GLuint, GLsizei, const char**, const GLint*);
109 typedef void (GLAPIENTRY *glStencilFuncSeparateType) (GLenum, GLenum, GLint, GLuint);
110 typedef void (GLAPIENTRY *glStencilMaskSeparateType) (GLenum, GLuint);
111 typedef void (GLAPIENTRY *glStencilOpSeparateType) (GLenum, GLenum, GLenum, GLenum);
112 typedef void (GLAPIENTRY *glUniform1fType) (GLint, GLfloat);
113 typedef void (GLAPIENTRY *glUniform1fvType) (GLint, GLsizei, const GLfloat*);
114 typedef void (GLAPIENTRY *glUniform1iType) (GLint, GLint);
115 typedef void (GLAPIENTRY *glUniform1ivType) (GLint, GLsizei, const GLint*);
116 typedef void (GLAPIENTRY *glUniform2fType) (GLint, GLfloat, GLfloat);
117 typedef void (GLAPIENTRY *glUniform2fvType) (GLint, GLsizei, const GLfloat*);
118 typedef void (GLAPIENTRY *glUniform2iType) (GLint, GLint, GLint);
119 typedef void (GLAPIENTRY *glUniform2ivType) (GLint, GLsizei, const GLint*);
120 typedef void (GLAPIENTRY *glUniform3fType) (GLint, GLfloat, GLfloat, GLfloat);
121 typedef void (GLAPIENTRY *glUniform3fvType) (GLint, GLsizei, const GLfloat*);
122 typedef void (GLAPIENTRY *glUniform3iType) (GLint, GLint, GLint, GLint);
123 typedef void (GLAPIENTRY *glUniform3ivType) (GLint, GLsizei, const GLint*);
124 typedef void (GLAPIENTRY *glUniform4fType) (GLint, GLfloat, GLfloat, GLfloat, GLfloat);
125 typedef void (GLAPIENTRY *glUniform4fvType) (GLint, GLsizei, const GLfloat*);
126 typedef void (GLAPIENTRY *glUniform4iType) (GLint, GLint, GLint, GLint, GLint);
127 typedef void (GLAPIENTRY *glUniform4ivType) (GLint, GLsizei, const GLint*);
128 typedef void (GLAPIENTRY *glUniformMatrix2fvType) (GLint, GLsizei, GLboolean, const GLfloat*);
129 typedef void (GLAPIENTRY *glUniformMatrix3fvType) (GLint, GLsizei, GLboolean, const GLfloat*);
130 typedef void (GLAPIENTRY *glUniformMatrix4fvType) (GLint, GLsizei, GLboolean, const GLfloat*);
131 typedef void (GLAPIENTRY *glUseProgramType) (GLuint);
132 typedef void (GLAPIENTRY *glValidateProgramType) (GLuint);
133 typedef void (GLAPIENTRY *glVertexAttrib1fType) (GLuint, const GLfloat);
134 typedef void (GLAPIENTRY *glVertexAttrib1fvType) (GLuint, const GLfloat*);
135 typedef void (GLAPIENTRY *glVertexAttrib2fType) (GLuint, const GLfloat, const GLfloat);
136 typedef void (GLAPIENTRY *glVertexAttrib2fvType) (GLuint, const GLfloat*);
137 typedef void (GLAPIENTRY *glVertexAttrib3fType) (GLuint, const GLfloat, const GLfloat, const GLfloat);
138 typedef void (GLAPIENTRY *glVertexAttrib3fvType) (GLuint, const GLfloat*);
139 typedef void (GLAPIENTRY *glVertexAttrib4fType) (GLuint, const GLfloat, const GLfloat, const GLfloat, const GLfloat);
140 typedef void (GLAPIENTRY *glVertexAttrib4fvType) (GLuint, const GLfloat*);
141 typedef void (GLAPIENTRY *glVertexAttribPointerType) (GLuint, GLint, GLenum, GLboolean, GLsizei, const GLvoid*);
143 #define FUNCTION_TABLE_ENTRY(FunctionName) FunctionName##Type FunctionName
145 typedef struct _OpenGLFunctionTable {
146 FUNCTION_TABLE_ENTRY(glActiveTexture);
147 FUNCTION_TABLE_ENTRY(glAttachShader);
148 FUNCTION_TABLE_ENTRY(glBindAttribLocation);
149 FUNCTION_TABLE_ENTRY(glBindBuffer);
150 FUNCTION_TABLE_ENTRY(glBindFramebuffer);
151 FUNCTION_TABLE_ENTRY(glBindRenderbuffer);
152 FUNCTION_TABLE_ENTRY(glBlendColor);
153 FUNCTION_TABLE_ENTRY(glBlendEquation);
154 FUNCTION_TABLE_ENTRY(glBlendEquationSeparate);
155 FUNCTION_TABLE_ENTRY(glBlendFuncSeparate);
156 FUNCTION_TABLE_ENTRY(glBlitFramebuffer);
157 FUNCTION_TABLE_ENTRY(glBufferData);
158 FUNCTION_TABLE_ENTRY(glBufferSubData);
159 FUNCTION_TABLE_ENTRY(glCheckFramebufferStatus);
160 FUNCTION_TABLE_ENTRY(glCompileShader);
161 FUNCTION_TABLE_ENTRY(glCreateProgram);
162 FUNCTION_TABLE_ENTRY(glCreateShader);
163 FUNCTION_TABLE_ENTRY(glDeleteBuffers);
164 FUNCTION_TABLE_ENTRY(glDeleteFramebuffers);
165 FUNCTION_TABLE_ENTRY(glDeleteProgram);
166 FUNCTION_TABLE_ENTRY(glDeleteRenderbuffers);
167 FUNCTION_TABLE_ENTRY(glDeleteShader);
168 FUNCTION_TABLE_ENTRY(glDetachShader);
169 FUNCTION_TABLE_ENTRY(glDisableVertexAttribArray);
170 FUNCTION_TABLE_ENTRY(glEnableVertexAttribArray);
171 FUNCTION_TABLE_ENTRY(glFramebufferRenderbuffer);
172 FUNCTION_TABLE_ENTRY(glFramebufferTexture2D);
173 FUNCTION_TABLE_ENTRY(glGenBuffers);
174 FUNCTION_TABLE_ENTRY(glGenerateMipmap);
175 FUNCTION_TABLE_ENTRY(glGenFramebuffers);
176 FUNCTION_TABLE_ENTRY(glGenRenderbuffers);
177 FUNCTION_TABLE_ENTRY(glGetActiveAttrib);
178 FUNCTION_TABLE_ENTRY(glGetActiveUniform);
179 FUNCTION_TABLE_ENTRY(glGetAttachedShaders);
180 FUNCTION_TABLE_ENTRY(glGetAttribLocation);
181 FUNCTION_TABLE_ENTRY(glGetBufferParameteriv);
182 FUNCTION_TABLE_ENTRY(glGetFramebufferAttachmentParameteriv);
183 FUNCTION_TABLE_ENTRY(glGetProgramInfoLog);
184 FUNCTION_TABLE_ENTRY(glGetProgramiv);
185 FUNCTION_TABLE_ENTRY(glGetRenderbufferParameteriv);
186 FUNCTION_TABLE_ENTRY(glGetShaderInfoLog);
187 FUNCTION_TABLE_ENTRY(glGetShaderiv);
188 FUNCTION_TABLE_ENTRY(glGetShaderSource);
189 FUNCTION_TABLE_ENTRY(glGetUniformfv);
190 FUNCTION_TABLE_ENTRY(glGetUniformiv);
191 FUNCTION_TABLE_ENTRY(glGetUniformLocation);
192 FUNCTION_TABLE_ENTRY(glGetVertexAttribfv);
193 FUNCTION_TABLE_ENTRY(glGetVertexAttribiv);
194 FUNCTION_TABLE_ENTRY(glGetVertexAttribPointerv);
195 FUNCTION_TABLE_ENTRY(glIsBuffer);
196 FUNCTION_TABLE_ENTRY(glIsFramebuffer);
197 FUNCTION_TABLE_ENTRY(glIsProgram);
198 FUNCTION_TABLE_ENTRY(glIsRenderbuffer);
199 FUNCTION_TABLE_ENTRY(glIsShader);
200 FUNCTION_TABLE_ENTRY(glLinkProgram);
201 FUNCTION_TABLE_ENTRY(glRenderbufferStorage);
202 FUNCTION_TABLE_ENTRY(glRenderbufferStorageMultisample);
203 FUNCTION_TABLE_ENTRY(glSampleCoverage);
204 FUNCTION_TABLE_ENTRY(glShaderSource);
205 FUNCTION_TABLE_ENTRY(glStencilFuncSeparate);
206 FUNCTION_TABLE_ENTRY(glStencilMaskSeparate);
207 FUNCTION_TABLE_ENTRY(glStencilOpSeparate);
208 FUNCTION_TABLE_ENTRY(glUniform1f);
209 FUNCTION_TABLE_ENTRY(glUniform1fv);
210 FUNCTION_TABLE_ENTRY(glUniform1i);
211 FUNCTION_TABLE_ENTRY(glUniform1iv);
212 FUNCTION_TABLE_ENTRY(glUniform2f);
213 FUNCTION_TABLE_ENTRY(glUniform2fv);
214 FUNCTION_TABLE_ENTRY(glUniform2i);
215 FUNCTION_TABLE_ENTRY(glUniform2iv);
216 FUNCTION_TABLE_ENTRY(glUniform3f);
217 FUNCTION_TABLE_ENTRY(glUniform3fv);
218 FUNCTION_TABLE_ENTRY(glUniform3i);
219 FUNCTION_TABLE_ENTRY(glUniform3iv);
220 FUNCTION_TABLE_ENTRY(glUniform4f);
221 FUNCTION_TABLE_ENTRY(glUniform4fv);
222 FUNCTION_TABLE_ENTRY(glUniform4i);
223 FUNCTION_TABLE_ENTRY(glUniform4iv);
224 FUNCTION_TABLE_ENTRY(glUniformMatrix2fv);
225 FUNCTION_TABLE_ENTRY(glUniformMatrix3fv);
226 FUNCTION_TABLE_ENTRY(glUniformMatrix4fv);
227 FUNCTION_TABLE_ENTRY(glUseProgram);
228 FUNCTION_TABLE_ENTRY(glValidateProgram);
229 FUNCTION_TABLE_ENTRY(glVertexAttrib1f);
230 FUNCTION_TABLE_ENTRY(glVertexAttrib1fv);
231 FUNCTION_TABLE_ENTRY(glVertexAttrib2f);
232 FUNCTION_TABLE_ENTRY(glVertexAttrib2fv);
233 FUNCTION_TABLE_ENTRY(glVertexAttrib3f);
234 FUNCTION_TABLE_ENTRY(glVertexAttrib3fv);
235 FUNCTION_TABLE_ENTRY(glVertexAttrib4f);
236 FUNCTION_TABLE_ENTRY(glVertexAttrib4fv);
237 FUNCTION_TABLE_ENTRY(glVertexAttribPointer);
238 } OpenGLFunctionTable;
240 // We disable the shims for OpenGLShims.cpp, so that we can set them.
241 #ifndef DISABLE_SHIMS
242 #define LOOKUP_GL_FUNCTION(Function) WebCore::openGLFunctionTable()->Function
243 #define glActiveTexture LOOKUP_GL_FUNCTION(glActiveTexture)
244 #define glAttachShader LOOKUP_GL_FUNCTION(glAttachShader)
245 #define glBindAttribLocation LOOKUP_GL_FUNCTION(glBindAttribLocation)
246 #define glBindBuffer LOOKUP_GL_FUNCTION(glBindBuffer)
247 #define glBindFramebufferEXT glBindFramebuffer
248 #define glBindFramebuffer LOOKUP_GL_FUNCTION(glBindFramebuffer)
249 #define glBindRenderbufferEXT glBindRenderbuffer
250 #define glBindRenderbuffer LOOKUP_GL_FUNCTION(glBindRenderbuffer)
251 #define glBlendColor LOOKUP_GL_FUNCTION(glBlendColor)
252 #define glBlendEquation LOOKUP_GL_FUNCTION(glBlendEquation)
253 #define glBlendEquationSeparate LOOKUP_GL_FUNCTION(glBlendEquationSeparate)
254 #define glBlendFuncSeparate LOOKUP_GL_FUNCTION(glBlendFuncSeparate)
255 #define glBlitFramebufferEXT glBlitFramebuffer
256 #define glBlitFramebuffer LOOKUP_GL_FUNCTION(glBlitFramebuffer)
257 #define glBufferData LOOKUP_GL_FUNCTION(glBufferData)
258 #define glBufferSubData LOOKUP_GL_FUNCTION(glBufferSubData)
259 #define glCheckFramebufferStatusEXT glCheckFramebufferStatus
260 #define glCheckFramebufferStatus LOOKUP_GL_FUNCTION(glCheckFramebufferStatus)
261 #define glCompileShader LOOKUP_GL_FUNCTION(glCompileShader)
262 #define glCreateProgram LOOKUP_GL_FUNCTION(glCreateProgram)
263 #define glCreateShader LOOKUP_GL_FUNCTION(glCreateShader)
264 #define glDeleteBuffers LOOKUP_GL_FUNCTION(glDeleteBuffers)
265 #define glDeleteFramebuffersEXT glDeleteFramebuffers
266 #define glDeleteFramebuffers LOOKUP_GL_FUNCTION(glDeleteFramebuffers)
267 #define glDeleteProgram LOOKUP_GL_FUNCTION(glDeleteProgram)
268 #define glDeleteRenderbuffersEXT glDeleteRenderbuffers
269 #define glDeleteRenderbuffers LOOKUP_GL_FUNCTION(glDeleteRenderbuffers)
270 #define glDeleteShader LOOKUP_GL_FUNCTION(glDeleteShader)
271 #define glDetachShader LOOKUP_GL_FUNCTION(glDetachShader)
272 #define glDisableVertexAttribArray LOOKUP_GL_FUNCTION(glDisableVertexAttribArray)
273 #define glEnableVertexAttribArray LOOKUP_GL_FUNCTION(glEnableVertexAttribArray)
274 #define glFramebufferRenderbufferEXT glFramebufferRenderbuffer
275 #define glFramebufferRenderbuffer LOOKUP_GL_FUNCTION(glFramebufferRenderbuffer)
276 #define glFramebufferTexture2DEXT glFramebufferTexture2D
277 #define glFramebufferTexture2D LOOKUP_GL_FUNCTION(glFramebufferTexture2D)
278 #define glGenBuffers LOOKUP_GL_FUNCTION(glGenBuffers)
279 #define glGenerateMipmapEXT glGenerateMipmap
280 #define glGenerateMipmap LOOKUP_GL_FUNCTION(glGenerateMipmap)
281 #define glGenFramebuffersEXT glGenFramebuffers
282 #define glGenFramebuffers LOOKUP_GL_FUNCTION(glGenFramebuffers)
283 #define glGenRenderbuffersEXT glGenRenderbuffers
284 #define glGenRenderbuffers LOOKUP_GL_FUNCTION(glGenRenderbuffers)
285 #define glGetActiveAttrib LOOKUP_GL_FUNCTION(glGetActiveAttrib)
286 #define glGetActiveUniform LOOKUP_GL_FUNCTION(glGetActiveUniform)
287 #define glGetAttachedShaders LOOKUP_GL_FUNCTION(glGetAttachedShaders)
288 #define glGetAttribLocation LOOKUP_GL_FUNCTION(glGetAttribLocation)
289 #define glGetBufferParameterivEXT glGetBufferParameteriv
290 #define glGetBufferParameteriv LOOKUP_GL_FUNCTION(glGetBufferParameteriv)
291 #define glGetFramebufferAttachmentParameterivEXT glGetFramebufferAttachmentParameteriv
292 #define glGetFramebufferAttachmentParameteriv LOOKUP_GL_FUNCTION(glGetFramebufferAttachmentParameteriv)
293 #define glGetProgramInfoLog LOOKUP_GL_FUNCTION(glGetProgramInfoLog)
294 #define glGetProgramiv LOOKUP_GL_FUNCTION(glGetProgramiv)
295 #define glGetRenderbufferParameterivEXT glGetRenderbufferParameteriv
296 #define glGetRenderbufferParameteriv LOOKUP_GL_FUNCTION(glGetRenderbufferParameteriv)
297 #define glGetShaderInfoLog LOOKUP_GL_FUNCTION(glGetShaderInfoLog)
298 #define glGetShaderiv LOOKUP_GL_FUNCTION(glGetShaderiv)
299 #define glGetShaderSource LOOKUP_GL_FUNCTION(glGetShaderSource)
300 #define glGetUniformfv LOOKUP_GL_FUNCTION(glGetUniformfv)
301 #define glGetUniformiv LOOKUP_GL_FUNCTION(glGetUniformiv)
302 #define glGetUniformLocation LOOKUP_GL_FUNCTION(glGetUniformLocation)
303 #define glGetVertexAttribfv LOOKUP_GL_FUNCTION(glGetVertexAttribfv)
304 #define glGetVertexAttribiv LOOKUP_GL_FUNCTION(glGetVertexAttribiv)
305 #define glGetVertexAttribPointerv LOOKUP_GL_FUNCTION(glGetVertexAttribPointerv)
306 #define glIsBuffer LOOKUP_GL_FUNCTION(glIsBuffer)
307 #define glIsFramebufferEXT glIsFramebuffer
308 #define glIsFramebuffer LOOKUP_GL_FUNCTION(glIsFramebuffer)
309 #define glIsProgram LOOKUP_GL_FUNCTION(glIsProgram)
310 #define glIsRenderbufferEXT glIsRenderbuffer
311 #define glIsRenderbuffer LOOKUP_GL_FUNCTION(glIsRenderbuffer)
312 #define glIsShader LOOKUP_GL_FUNCTION(glIsShader)
313 #define glLinkProgram LOOKUP_GL_FUNCTION(glLinkProgram)
314 #define glRenderbufferStorageEXT glRenderbufferStorage
315 #define glRenderbufferStorage LOOKUP_GL_FUNCTION(glRenderbufferStorage)
316 #define glRenderbufferStorageMultisampleEXT glRenderbufferStorageMultisample
317 #define glRenderbufferStorageMultisample LOOKUP_GL_FUNCTION(glRenderbufferStorageMultisample)
318 #define glSampleCoverage LOOKUP_GL_FUNCTION(glSampleCoverage)
319 #define glShaderSource LOOKUP_GL_FUNCTION(glShaderSource)
320 #define glStencilFuncSeparate LOOKUP_GL_FUNCTION(glStencilFuncSeparate)
321 #define glStencilMaskSeparate LOOKUP_GL_FUNCTION(glStencilMaskSeparate)
322 #define glStencilOpSeparate LOOKUP_GL_FUNCTION(glStencilOpSeparate)
323 #define glUniform1f LOOKUP_GL_FUNCTION(glUniform1f)
324 #define glUniform1fv LOOKUP_GL_FUNCTION(glUniform1fv)
325 #define glUniform1i LOOKUP_GL_FUNCTION(glUniform1i)
326 #define glUniform1iv LOOKUP_GL_FUNCTION(glUniform1iv)
327 #define glUniform2f LOOKUP_GL_FUNCTION(glUniform2f)
328 #define glUniform2fv LOOKUP_GL_FUNCTION(glUniform2fv)
329 #define glUniform2i LOOKUP_GL_FUNCTION(glUniform2i)
330 #define glUniform2iv LOOKUP_GL_FUNCTION(glUniform2iv)
331 #define glUniform3f LOOKUP_GL_FUNCTION(glUniform3f)
332 #define glUniform3fv LOOKUP_GL_FUNCTION(glUniform3fv)
333 #define glUniform3i LOOKUP_GL_FUNCTION(glUniform3i)
334 #define glUniform3iv LOOKUP_GL_FUNCTION(glUniform3iv)
335 #define glUniform4f LOOKUP_GL_FUNCTION(glUniform4f)
336 #define glUniform4fv LOOKUP_GL_FUNCTION(glUniform4fv)
337 #define glUniform4i LOOKUP_GL_FUNCTION(glUniform4i)
338 #define glUniform4iv LOOKUP_GL_FUNCTION(glUniform4iv)
339 #define glUniformMatrix2fv LOOKUP_GL_FUNCTION(glUniformMatrix2fv)
340 #define glUniformMatrix3fv LOOKUP_GL_FUNCTION(glUniformMatrix3fv)
341 #define glUniformMatrix4fv LOOKUP_GL_FUNCTION(glUniformMatrix4fv)
342 #define glUseProgram LOOKUP_GL_FUNCTION(glUseProgram)
343 #define glValidateProgram LOOKUP_GL_FUNCTION(glValidateProgram)
344 #define glVertexAttrib1f LOOKUP_GL_FUNCTION(glVertexAttrib1f)
345 #define glVertexAttrib1fv LOOKUP_GL_FUNCTION(glVertexAttrib1fv)
346 #define glVertexAttrib2f LOOKUP_GL_FUNCTION(glVertexAttrib2f)
347 #define glVertexAttrib2fv LOOKUP_GL_FUNCTION(glVertexAttrib2fv)
348 #define glVertexAttrib3f LOOKUP_GL_FUNCTION(glVertexAttrib3f)
349 #define glVertexAttrib3fv LOOKUP_GL_FUNCTION(glVertexAttrib3fv)
350 #define glVertexAttrib4f LOOKUP_GL_FUNCTION(glVertexAttrib4f)
351 #define glVertexAttrib4fv LOOKUP_GL_FUNCTION(glVertexAttrib4fv)
352 #define glVertexAttribPointer LOOKUP_GL_FUNCTION(glVertexAttribPointer)