1#!/usr/bin/env python
2
3# Mesa 3-D graphics library
4# Version:  7.12
5#
6# Copyright (C) 2011 LunarG Inc.
7#
8# Permission is hereby granted, free of charge, to any person obtaining a
9# copy of this software and associated documentation files (the "Software"),
10# to deal in the Software without restriction, including without limitation
11# the rights to use, copy, modify, merge, publish, distribute, sublicense,
12# and/or sell copies of the Software, and to permit persons to whom the
13# Software is furnished to do so, subject to the following conditions:
14#
15# The above copyright notice and this permission notice shall be included
16# in all copies or substantial portions of the Software.
17#
18# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
19# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
20# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
21# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
22# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
23# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
24# DEALINGS IN THE SOFTWARE.
25#
26# Authors:
27#    Chia-I Wu <olv@lunarg.com>
28
29# These info should be part of GLAPI XML.  Until that is possible, scripts have
30# to use tables here to filter gl_api.
31
32es1_core = (
33        # OpenGL ES 1.1
34        'ActiveTexture',
35        'AlphaFunc',
36        'AlphaFuncx',
37        'BindBuffer',
38        'BindTexture',
39        'BlendFunc',
40        'BufferData',
41        'BufferSubData',
42        'Clear',
43        'ClearColor',
44        'ClearColorx',
45        'ClearDepthf',
46        'ClearDepthx',
47        'ClearStencil',
48        'ClientActiveTexture',
49        'ClipPlanef',
50        'ClipPlanex',
51        'Color4f',
52        'Color4ub',
53        'Color4x',
54        'ColorMask',
55        'ColorPointer',
56        'CompressedTexImage2D',
57        'CompressedTexSubImage2D',
58        'CopyTexImage2D',
59        'CopyTexSubImage2D',
60        'CullFace',
61        'DeleteBuffers',
62        'DeleteTextures',
63        'DepthFunc',
64        'DepthMask',
65        'DepthRangef',
66        'DepthRangex',
67        'Disable',
68        'DisableClientState',
69        'DrawArrays',
70        'DrawElements',
71        'Enable',
72        'EnableClientState',
73        'Finish',
74        'Flush',
75        'Fogf',
76        'Fogfv',
77        'Fogx',
78        'Fogxv',
79        'FrontFace',
80        'Frustumf',
81        'Frustumx',
82        'GenBuffers',
83        'GenTextures',
84        'GetBooleanv',
85        'GetBufferParameteriv',
86        'GetClipPlanef',
87        'GetClipPlanex',
88        'GetError',
89        'GetFixedv',
90        'GetFloatv',
91        'GetIntegerv',
92        'GetLightfv',
93        'GetLightxv',
94        'GetMaterialfv',
95        'GetMaterialxv',
96        'GetPointerv',
97        'GetString',
98        'GetTexEnvfv',
99        'GetTexEnviv',
100        'GetTexEnvxv',
101        'GetTexParameterfv',
102        'GetTexParameteriv',
103        'GetTexParameterxv',
104        'Hint',
105        'IsBuffer',
106        'IsEnabled',
107        'IsTexture',
108        'Lightf',
109        'Lightfv',
110        'LightModelf',
111        'LightModelfv',
112        'LightModelx',
113        'LightModelxv',
114        'Lightx',
115        'Lightxv',
116        'LineWidth',
117        'LineWidthx',
118        'LoadIdentity',
119        'LoadMatrixf',
120        'LoadMatrixx',
121        'LogicOp',
122        'Materialf',
123        'Materialfv',
124        'Materialx',
125        'Materialxv',
126        'MatrixMode',
127        'MultiTexCoord4f',
128        'MultiTexCoord4x',
129        'MultMatrixf',
130        'MultMatrixx',
131        'Normal3f',
132        'Normal3x',
133        'NormalPointer',
134        'Orthof',
135        'Orthox',
136        'PixelStorei',
137        'PointParameterf',
138        'PointParameterfv',
139        'PointParameterx',
140        'PointParameterxv',
141        'PointSize',
142        'PointSizex',
143        'PolygonOffset',
144        'PolygonOffsetx',
145        'PopMatrix',
146        'PushMatrix',
147        'ReadPixels',
148        'Rotatef',
149        'Rotatex',
150        'SampleCoverage',
151        'SampleCoveragex',
152        'Scalef',
153        'Scalex',
154        'Scissor',
155        'ShadeModel',
156        'StencilFunc',
157        'StencilMask',
158        'StencilOp',
159        'TexCoordPointer',
160        'TexEnvf',
161        'TexEnvfv',
162        'TexEnvi',
163        'TexEnviv',
164        'TexEnvx',
165        'TexEnvxv',
166        'TexImage2D',
167        'TexParameterf',
168        'TexParameterfv',
169        'TexParameteri',
170        'TexParameteriv',
171        'TexParameterx',
172        'TexParameterxv',
173        'TexSubImage2D',
174        'Translatef',
175        'Translatex',
176        'VertexPointer',
177        'Viewport',
178)
179
180es1_api = es1_core + (
181        # GL_OES_EGL_image
182        'EGLImageTargetTexture2DOES',
183        'EGLImageTargetRenderbufferStorageOES',
184        # GL_OES_mapbuffer
185        'GetBufferPointervOES',
186        'MapBufferOES',
187        'UnmapBufferOES',
188        # GL_EXT_multi_draw_arrays
189        'MultiDrawArraysEXT',
190        'MultiDrawElementsEXT',
191        # GL_OES_blend_equation_separate
192        'BlendEquationSeparateOES',
193        # GL_OES_blend_func_separate
194        'BlendFuncSeparateOES',
195        # GL_OES_blend_subtract
196        'BlendEquationOES',
197        # GL_OES_draw_texture
198        'DrawTexiOES',
199        'DrawTexivOES',
200        'DrawTexfOES',
201        'DrawTexfvOES',
202        'DrawTexsOES',
203        'DrawTexsvOES',
204        'DrawTexxOES',
205        'DrawTexxvOES',
206        # GL_OES_fixed_point
207        'AlphaFuncxOES',
208        'ClearColorxOES',
209        'ClearDepthxOES',
210        'Color4xOES',
211        'DepthRangexOES',
212        'FogxOES',
213        'FogxvOES',
214        'FrustumxOES',
215        'LightModelxOES',
216        'LightModelxvOES',
217        'LightxOES',
218        'LightxvOES',
219        'LineWidthxOES',
220        'LoadMatrixxOES',
221        'MaterialxOES',
222        'MaterialxvOES',
223        'MultiTexCoord4xOES',
224        'MultMatrixxOES',
225        'Normal3xOES',
226        'OrthoxOES',
227        'PointSizexOES',
228        'PolygonOffsetxOES',
229        'RotatexOES',
230        'SampleCoveragexOES',
231        'ScalexOES',
232        'TexEnvxOES',
233        'TexEnvxvOES',
234        'TexParameterxOES',
235        'TranslatexOES',
236        'ClipPlanexOES',
237        'GetClipPlanexOES',
238        'GetFixedvOES',
239        'GetLightxvOES',
240        'GetMaterialxvOES',
241        'GetTexEnvxvOES',
242        'GetTexParameterxvOES',
243        'PointParameterxOES',
244        'PointParameterxvOES',
245        'TexParameterxvOES',
246        # GL_OES_framebuffer_object
247        'BindFramebufferOES',
248        'BindRenderbufferOES',
249        'CheckFramebufferStatusOES',
250        'DeleteFramebuffersOES',
251        'DeleteRenderbuffersOES',
252        'FramebufferRenderbufferOES',
253        'FramebufferTexture2DOES',
254        'GenerateMipmapOES',
255        'GenFramebuffersOES',
256        'GenRenderbuffersOES',
257        'GetFramebufferAttachmentParameterivOES',
258        'GetRenderbufferParameterivOES',
259        'IsFramebufferOES',
260        'IsRenderbufferOES',
261        'RenderbufferStorageOES',
262        # GL_OES_point_size_array
263        'PointSizePointerOES',
264        # GL_OES_query_matrix
265        'QueryMatrixxOES',
266        # GL_OES_single_precision
267        'ClearDepthfOES',
268        'DepthRangefOES',
269        'FrustumfOES',
270        'OrthofOES',
271        'ClipPlanefOES',
272        'GetClipPlanefOES',
273        # GL_OES_texture_cube_map
274        'GetTexGenfvOES',
275        'GetTexGenivOES',
276        'GetTexGenxvOES',
277        'TexGenfOES',
278        'TexGenfvOES',
279        'TexGeniOES',
280        'TexGenivOES',
281        'TexGenxOES',
282        'TexGenxvOES',
283)
284
285es2_core = (
286        # OpenGL ES 2.0
287        "ActiveTexture",
288        "AttachShader",
289        "BindAttribLocation",
290        "BindBuffer",
291        "BindFramebuffer",
292        "BindRenderbuffer",
293        "BindTexture",
294        "BlendColor",
295        "BlendEquation",
296        "BlendEquationSeparate",
297        "BlendFunc",
298        "BlendFuncSeparate",
299        "BufferData",
300        "BufferSubData",
301        "CheckFramebufferStatus",
302        "Clear",
303        "ClearColor",
304        "ClearDepthf",
305        "ClearStencil",
306        "ColorMask",
307        "CompileShader",
308        "CompressedTexImage2D",
309        "CompressedTexSubImage2D",
310        "CopyTexImage2D",
311        "CopyTexSubImage2D",
312        "CreateProgram",
313        "CreateShader",
314        "CullFace",
315        "DeleteBuffers",
316        "DeleteFramebuffers",
317        "DeleteProgram",
318        "DeleteRenderbuffers",
319        "DeleteShader",
320        "DeleteTextures",
321        "DepthFunc",
322        "DepthMask",
323        "DepthRangef",
324        "DetachShader",
325        "Disable",
326        "DisableVertexAttribArray",
327        "DrawArrays",
328        "DrawElements",
329        "Enable",
330        "EnableVertexAttribArray",
331        "Finish",
332        "Flush",
333        "FramebufferRenderbuffer",
334        "FramebufferTexture2D",
335        "FrontFace",
336        "GenBuffers",
337        "GenerateMipmap",
338        "GenFramebuffers",
339        "GenRenderbuffers",
340        "GenTextures",
341        "GetActiveAttrib",
342        "GetActiveUniform",
343        "GetAttachedShaders",
344        "GetAttribLocation",
345        "GetBooleanv",
346        "GetBufferParameteriv",
347        "GetError",
348        "GetFloatv",
349        "GetFramebufferAttachmentParameteriv",
350        "GetIntegerv",
351        "GetProgramInfoLog",
352        "GetProgramiv",
353        "GetRenderbufferParameteriv",
354        "GetShaderInfoLog",
355        "GetShaderiv",
356        "GetShaderPrecisionFormat",
357        "GetShaderSource",
358        "GetString",
359        "GetTexParameterfv",
360        "GetTexParameteriv",
361        "GetUniformfv",
362        "GetUniformiv",
363        "GetUniformLocation",
364        "GetVertexAttribfv",
365        "GetVertexAttribiv",
366        "GetVertexAttribPointerv",
367        "Hint",
368        "IsBuffer",
369        "IsEnabled",
370        "IsFramebuffer",
371        "IsProgram",
372        "IsRenderbuffer",
373        "IsShader",
374        "IsTexture",
375        "LineWidth",
376        "LinkProgram",
377        "PixelStorei",
378        "PolygonOffset",
379        "ReadPixels",
380        "ReleaseShaderCompiler",
381        "RenderbufferStorage",
382        "SampleCoverage",
383        "Scissor",
384        "ShaderBinary",
385        "ShaderSource",
386        "StencilFunc",
387        "StencilFuncSeparate",
388        "StencilMask",
389        "StencilMaskSeparate",
390        "StencilOp",
391        "StencilOpSeparate",
392        "TexImage2D",
393        "TexParameterf",
394        "TexParameterfv",
395        "TexParameteri",
396        "TexParameteriv",
397        "TexSubImage2D",
398        "Uniform1f",
399        "Uniform1fv",
400        "Uniform1i",
401        "Uniform1iv",
402        "Uniform2f",
403        "Uniform2fv",
404        "Uniform2i",
405        "Uniform2iv",
406        "Uniform3f",
407        "Uniform3fv",
408        "Uniform3i",
409        "Uniform3iv",
410        "Uniform4f",
411        "Uniform4fv",
412        "Uniform4i",
413        "Uniform4iv",
414        "UniformMatrix2fv",
415        "UniformMatrix3fv",
416        "UniformMatrix4fv",
417        "UseProgram",
418        "ValidateProgram",
419        "VertexAttrib1f",
420        "VertexAttrib1fv",
421        "VertexAttrib2f",
422        "VertexAttrib2fv",
423        "VertexAttrib3f",
424        "VertexAttrib3fv",
425        "VertexAttrib4f",
426        "VertexAttrib4fv",
427        "VertexAttribPointer",
428        "Viewport",
429)
430
431es2_api = es2_core + (
432        # GL_OES_EGL_image
433        'EGLImageTargetTexture2DOES',
434        'EGLImageTargetRenderbufferStorageOES',
435        # GL_OES_mapbuffer
436        'GetBufferPointervOES',
437        'MapBufferOES',
438        'UnmapBufferOES',
439        # GL_EXT_multi_draw_arrays
440        'MultiDrawArraysEXT',
441        'MultiDrawElementsEXT',
442        # GL_OES_texture_3D
443        'CompressedTexImage3DOES',
444        'CompressedTexSubImage3DOES',
445        'CopyTexSubImage3DOES',
446        'FramebufferTexture3DOES',
447        'TexImage3DOES',
448        'TexSubImage3DOES',
449        # GL_OES_get_program_binary
450        'GetProgramBinaryOES',
451        'ProgramBinaryOES',
452        # GL_OES_vertex_array_object
453        'BindVertexArrayOES',
454        'DeleteVertexArraysOES',
455        'GenVertexArraysOES',
456        'IsVertexArrayOES',
457        # GL_NV_draw_buffers
458        'DrawBuffersNV',
459        # GL_NV_read_buffer
460        'ReadBufferNV',
461)
462