1 #############################################################################
3 # Copyright 2009 VMware, Inc.
5 # This program is free software: you can redistribute it and/or modify it
6 # under the terms of the GNU Lesser General Public License as published
7 # by the Free Software Foundation, either version 3 of the License, or
8 # (at your option) any later version.
10 # This program 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
13 # GNU Lesser General Public License for more details.
15 # You should have received a copy of the GNU Lesser General Public License
16 # along with this program. If not, see <http://www.gnu.org/licenses/>.
18 #############################################################################
23 opengl32 = Dll("opengl32")
24 opengl32.functions += [
25 DllFunction(Void, "glNewList", [(GLuint, "list"), (GLenum, "mode")]),
26 DllFunction(Void, "glEndList", []),
27 DllFunction(Void, "glCallList", [(GLuint, "list")]),
28 DllFunction(Void, "glCallLists", [(GLsizei, "n"), (GLenum, "type"), (Pointer(Const(GLvoid)), "lists")]),
29 DllFunction(Void, "glDeleteLists", [(GLuint, "list"), (GLsizei, "range")]),
30 DllFunction(GLuint, "glGenLists", [(GLsizei, "range")]),
31 DllFunction(Void, "glListBase", [(GLuint, "base")]),
32 DllFunction(Void, "glBegin", [(GLprimenum, "mode")]),
33 DllFunction(Void, "glBitmap", [(GLsizei, "width"), (GLsizei, "height"), (GLfloat, "xorig"), (GLfloat, "yorig"), (GLfloat, "xmove"), (GLfloat, "ymove"), (Pointer(Const(GLubyte)), "bitmap")]),
34 DllFunction(Void, "glColor3b", [(GLbyte, "red"), (GLbyte, "green"), (GLbyte, "blue")]),
35 DllFunction(Void, "glColor3bv", [(Pointer(Const(GLbyte)), "v")]),
36 DllFunction(Void, "glColor3d", [(GLdouble, "red"), (GLdouble, "green"), (GLdouble, "blue")]),
37 DllFunction(Void, "glColor3dv", [(Pointer(Const(GLdouble)), "v")]),
38 DllFunction(Void, "glColor3f", [(GLfloat, "red"), (GLfloat, "green"), (GLfloat, "blue")]),
39 DllFunction(Void, "glColor3fv", [(Pointer(Const(GLfloat)), "v")]),
40 DllFunction(Void, "glColor3i", [(GLint, "red"), (GLint, "green"), (GLint, "blue")]),
41 DllFunction(Void, "glColor3iv", [(Pointer(Const(GLint)), "v")]),
42 DllFunction(Void, "glColor3s", [(GLshort, "red"), (GLshort, "green"), (GLshort, "blue")]),
43 DllFunction(Void, "glColor3sv", [(Pointer(Const(GLshort)), "v")]),
44 DllFunction(Void, "glColor3ub", [(GLubyte, "red"), (GLubyte, "green"), (GLubyte, "blue")]),
45 DllFunction(Void, "glColor3ubv", [(Pointer(Const(GLubyte)), "v")]),
46 DllFunction(Void, "glColor3ui", [(GLuint, "red"), (GLuint, "green"), (GLuint, "blue")]),
47 DllFunction(Void, "glColor3uiv", [(Pointer(Const(GLuint)), "v")]),
48 DllFunction(Void, "glColor3us", [(GLushort, "red"), (GLushort, "green"), (GLushort, "blue")]),
49 DllFunction(Void, "glColor3usv", [(Pointer(Const(GLushort)), "v")]),
50 DllFunction(Void, "glColor4b", [(GLbyte, "red"), (GLbyte, "green"), (GLbyte, "blue"), (GLbyte, "alpha")]),
51 DllFunction(Void, "glColor4bv", [(Pointer(Const(GLbyte)), "v")]),
52 DllFunction(Void, "glColor4d", [(GLdouble, "red"), (GLdouble, "green"), (GLdouble, "blue"), (GLdouble, "alpha")]),
53 DllFunction(Void, "glColor4dv", [(Pointer(Const(GLdouble)), "v")]),
54 DllFunction(Void, "glColor4f", [(GLfloat, "red"), (GLfloat, "green"), (GLfloat, "blue"), (GLfloat, "alpha")]),
55 DllFunction(Void, "glColor4fv", [(Pointer(Const(GLfloat)), "v")]),
56 DllFunction(Void, "glColor4i", [(GLint, "red"), (GLint, "green"), (GLint, "blue"), (GLint, "alpha")]),
57 DllFunction(Void, "glColor4iv", [(Pointer(Const(GLint)), "v")]),
58 DllFunction(Void, "glColor4s", [(GLshort, "red"), (GLshort, "green"), (GLshort, "blue"), (GLshort, "alpha")]),
59 DllFunction(Void, "glColor4sv", [(Pointer(Const(GLshort)), "v")]),
60 DllFunction(Void, "glColor4ub", [(GLubyte, "red"), (GLubyte, "green"), (GLubyte, "blue"), (GLubyte, "alpha")]),
61 DllFunction(Void, "glColor4ubv", [(Pointer(Const(GLubyte)), "v")]),
62 DllFunction(Void, "glColor4ui", [(GLuint, "red"), (GLuint, "green"), (GLuint, "blue"), (GLuint, "alpha")]),
63 DllFunction(Void, "glColor4uiv", [(Pointer(Const(GLuint)), "v")]),
64 DllFunction(Void, "glColor4us", [(GLushort, "red"), (GLushort, "green"), (GLushort, "blue"), (GLushort, "alpha")]),
65 DllFunction(Void, "glColor4usv", [(Pointer(Const(GLushort)), "v")]),
66 DllFunction(Void, "glEdgeFlag", [(GLboolean, "flag")]),
67 DllFunction(Void, "glEdgeFlagv", [(Pointer(Const(GLboolean)), "flag")]),
68 DllFunction(Void, "glEnd", []),
69 DllFunction(Void, "glIndexd", [(GLdouble, "c")]),
70 DllFunction(Void, "glIndexdv", [(Pointer(Const(GLdouble)), "c")]),
71 DllFunction(Void, "glIndexf", [(GLfloat, "c")]),
72 DllFunction(Void, "glIndexfv", [(Pointer(Const(GLfloat)), "c")]),
73 DllFunction(Void, "glIndexi", [(GLint, "c")]),
74 DllFunction(Void, "glIndexiv", [(Pointer(Const(GLint)), "c")]),
75 DllFunction(Void, "glIndexs", [(GLshort, "c")]),
76 DllFunction(Void, "glIndexsv", [(Pointer(Const(GLshort)), "c")]),
77 DllFunction(Void, "glNormal3b", [(GLbyte, "nx"), (GLbyte, "ny"), (GLbyte, "nz")]),
78 DllFunction(Void, "glNormal3bv", [(Pointer(Const(GLbyte)), "v")]),
79 DllFunction(Void, "glNormal3d", [(GLdouble, "nx"), (GLdouble, "ny"), (GLdouble, "nz")]),
80 DllFunction(Void, "glNormal3dv", [(Pointer(Const(GLdouble)), "v")]),
81 DllFunction(Void, "glNormal3f", [(GLfloat, "nx"), (GLfloat, "ny"), (GLfloat, "nz")]),
82 DllFunction(Void, "glNormal3fv", [(Pointer(Const(GLfloat)), "v")]),
83 DllFunction(Void, "glNormal3i", [(GLint, "nx"), (GLint, "ny"), (GLint, "nz")]),
84 DllFunction(Void, "glNormal3iv", [(Pointer(Const(GLint)), "v")]),
85 DllFunction(Void, "glNormal3s", [(GLshort, "nx"), (GLshort, "ny"), (GLshort, "nz")]),
86 DllFunction(Void, "glNormal3sv", [(Pointer(Const(GLshort)), "v")]),
87 DllFunction(Void, "glRasterPos2d", [(GLdouble, "x"), (GLdouble, "y")]),
88 DllFunction(Void, "glRasterPos2dv", [(Pointer(Const(GLdouble)), "v")]),
89 DllFunction(Void, "glRasterPos2f", [(GLfloat, "x"), (GLfloat, "y")]),
90 DllFunction(Void, "glRasterPos2fv", [(Pointer(Const(GLfloat)), "v")]),
91 DllFunction(Void, "glRasterPos2i", [(GLint, "x"), (GLint, "y")]),
92 DllFunction(Void, "glRasterPos2iv", [(Pointer(Const(GLint)), "v")]),
93 DllFunction(Void, "glRasterPos2s", [(GLshort, "x"), (GLshort, "y")]),
94 DllFunction(Void, "glRasterPos2sv", [(Pointer(Const(GLshort)), "v")]),
95 DllFunction(Void, "glRasterPos3d", [(GLdouble, "x"), (GLdouble, "y"), (GLdouble, "z")]),
96 DllFunction(Void, "glRasterPos3dv", [(Pointer(Const(GLdouble)), "v")]),
97 DllFunction(Void, "glRasterPos3f", [(GLfloat, "x"), (GLfloat, "y"), (GLfloat, "z")]),
98 DllFunction(Void, "glRasterPos3fv", [(Pointer(Const(GLfloat)), "v")]),
99 DllFunction(Void, "glRasterPos3i", [(GLint, "x"), (GLint, "y"), (GLint, "z")]),
100 DllFunction(Void, "glRasterPos3iv", [(Pointer(Const(GLint)), "v")]),
101 DllFunction(Void, "glRasterPos3s", [(GLshort, "x"), (GLshort, "y"), (GLshort, "z")]),
102 DllFunction(Void, "glRasterPos3sv", [(Pointer(Const(GLshort)), "v")]),
103 DllFunction(Void, "glRasterPos4d", [(GLdouble, "x"), (GLdouble, "y"), (GLdouble, "z"), (GLdouble, "w")]),
104 DllFunction(Void, "glRasterPos4dv", [(Pointer(Const(GLdouble)), "v")]),
105 DllFunction(Void, "glRasterPos4f", [(GLfloat, "x"), (GLfloat, "y"), (GLfloat, "z"), (GLfloat, "w")]),
106 DllFunction(Void, "glRasterPos4fv", [(Pointer(Const(GLfloat)), "v")]),
107 DllFunction(Void, "glRasterPos4i", [(GLint, "x"), (GLint, "y"), (GLint, "z"), (GLint, "w")]),
108 DllFunction(Void, "glRasterPos4iv", [(Pointer(Const(GLint)), "v")]),
109 DllFunction(Void, "glRasterPos4s", [(GLshort, "x"), (GLshort, "y"), (GLshort, "z"), (GLshort, "w")]),
110 DllFunction(Void, "glRasterPos4sv", [(Pointer(Const(GLshort)), "v")]),
111 DllFunction(Void, "glRectd", [(GLdouble, "x1"), (GLdouble, "y1"), (GLdouble, "x2"), (GLdouble, "y2")]),
112 DllFunction(Void, "glRectdv", [(Pointer(Const(GLdouble)), "v1"), (Pointer(Const(GLdouble)), "v2")]),
113 DllFunction(Void, "glRectf", [(GLfloat, "x1"), (GLfloat, "y1"), (GLfloat, "x2"), (GLfloat, "y2")]),
114 DllFunction(Void, "glRectfv", [(Pointer(Const(GLfloat)), "v1"), (Pointer(Const(GLfloat)), "v2")]),
115 DllFunction(Void, "glRecti", [(GLint, "x1"), (GLint, "y1"), (GLint, "x2"), (GLint, "y2")]),
116 DllFunction(Void, "glRectiv", [(Pointer(Const(GLint)), "v1"), (Pointer(Const(GLint)), "v2")]),
117 DllFunction(Void, "glRects", [(GLshort, "x1"), (GLshort, "y1"), (GLshort, "x2"), (GLshort, "y2")]),
118 DllFunction(Void, "glRectsv", [(Pointer(Const(GLshort)), "v1"), (Pointer(Const(GLshort)), "v2")]),
119 DllFunction(Void, "glTexCoord1d", [(GLdouble, "s")]),
120 DllFunction(Void, "glTexCoord1dv", [(Pointer(Const(GLdouble)), "v")]),
121 DllFunction(Void, "glTexCoord1f", [(GLfloat, "s")]),
122 DllFunction(Void, "glTexCoord1fv", [(Pointer(Const(GLfloat)), "v")]),
123 DllFunction(Void, "glTexCoord1i", [(GLint, "s")]),
124 DllFunction(Void, "glTexCoord1iv", [(Pointer(Const(GLint)), "v")]),
125 DllFunction(Void, "glTexCoord1s", [(GLshort, "s")]),
126 DllFunction(Void, "glTexCoord1sv", [(Pointer(Const(GLshort)), "v")]),
127 DllFunction(Void, "glTexCoord2d", [(GLdouble, "s"), (GLdouble, "t")]),
128 DllFunction(Void, "glTexCoord2dv", [(Pointer(Const(GLdouble)), "v")]),
129 DllFunction(Void, "glTexCoord2f", [(GLfloat, "s"), (GLfloat, "t")]),
130 DllFunction(Void, "glTexCoord2fv", [(Pointer(Const(GLfloat)), "v")]),
131 DllFunction(Void, "glTexCoord2i", [(GLint, "s"), (GLint, "t")]),
132 DllFunction(Void, "glTexCoord2iv", [(Pointer(Const(GLint)), "v")]),
133 DllFunction(Void, "glTexCoord2s", [(GLshort, "s"), (GLshort, "t")]),
134 DllFunction(Void, "glTexCoord2sv", [(Pointer(Const(GLshort)), "v")]),
135 DllFunction(Void, "glTexCoord3d", [(GLdouble, "s"), (GLdouble, "t"), (GLdouble, "r")]),
136 DllFunction(Void, "glTexCoord3dv", [(Pointer(Const(GLdouble)), "v")]),
137 DllFunction(Void, "glTexCoord3f", [(GLfloat, "s"), (GLfloat, "t"), (GLfloat, "r")]),
138 DllFunction(Void, "glTexCoord3fv", [(Pointer(Const(GLfloat)), "v")]),
139 DllFunction(Void, "glTexCoord3i", [(GLint, "s"), (GLint, "t"), (GLint, "r")]),
140 DllFunction(Void, "glTexCoord3iv", [(Pointer(Const(GLint)), "v")]),
141 DllFunction(Void, "glTexCoord3s", [(GLshort, "s"), (GLshort, "t"), (GLshort, "r")]),
142 DllFunction(Void, "glTexCoord3sv", [(Pointer(Const(GLshort)), "v")]),
143 DllFunction(Void, "glTexCoord4d", [(GLdouble, "s"), (GLdouble, "t"), (GLdouble, "r"), (GLdouble, "q")]),
144 DllFunction(Void, "glTexCoord4dv", [(Pointer(Const(GLdouble)), "v")]),
145 DllFunction(Void, "glTexCoord4f", [(GLfloat, "s"), (GLfloat, "t"), (GLfloat, "r"), (GLfloat, "q")]),
146 DllFunction(Void, "glTexCoord4fv", [(Pointer(Const(GLfloat)), "v")]),
147 DllFunction(Void, "glTexCoord4i", [(GLint, "s"), (GLint, "t"), (GLint, "r"), (GLint, "q")]),
148 DllFunction(Void, "glTexCoord4iv", [(Pointer(Const(GLint)), "v")]),
149 DllFunction(Void, "glTexCoord4s", [(GLshort, "s"), (GLshort, "t"), (GLshort, "r"), (GLshort, "q")]),
150 DllFunction(Void, "glTexCoord4sv", [(Pointer(Const(GLshort)), "v")]),
151 DllFunction(Void, "glVertex2d", [(GLdouble, "x"), (GLdouble, "y")]),
152 DllFunction(Void, "glVertex2dv", [(Pointer(Const(GLdouble)), "v")]),
153 DllFunction(Void, "glVertex2f", [(GLfloat, "x"), (GLfloat, "y")]),
154 DllFunction(Void, "glVertex2fv", [(Pointer(Const(GLfloat)), "v")]),
155 DllFunction(Void, "glVertex2i", [(GLint, "x"), (GLint, "y")]),
156 DllFunction(Void, "glVertex2iv", [(Pointer(Const(GLint)), "v")]),
157 DllFunction(Void, "glVertex2s", [(GLshort, "x"), (GLshort, "y")]),
158 DllFunction(Void, "glVertex2sv", [(Pointer(Const(GLshort)), "v")]),
159 DllFunction(Void, "glVertex3d", [(GLdouble, "x"), (GLdouble, "y"), (GLdouble, "z")]),
160 DllFunction(Void, "glVertex3dv", [(Pointer(Const(GLdouble)), "v")]),
161 DllFunction(Void, "glVertex3f", [(GLfloat, "x"), (GLfloat, "y"), (GLfloat, "z")]),
162 DllFunction(Void, "glVertex3fv", [(Pointer(Const(GLfloat)), "v")]),
163 DllFunction(Void, "glVertex3i", [(GLint, "x"), (GLint, "y"), (GLint, "z")]),
164 DllFunction(Void, "glVertex3iv", [(Pointer(Const(GLint)), "v")]),
165 DllFunction(Void, "glVertex3s", [(GLshort, "x"), (GLshort, "y"), (GLshort, "z")]),
166 DllFunction(Void, "glVertex3sv", [(Pointer(Const(GLshort)), "v")]),
167 DllFunction(Void, "glVertex4d", [(GLdouble, "x"), (GLdouble, "y"), (GLdouble, "z"), (GLdouble, "w")]),
168 DllFunction(Void, "glVertex4dv", [(Pointer(Const(GLdouble)), "v")]),
169 DllFunction(Void, "glVertex4f", [(GLfloat, "x"), (GLfloat, "y"), (GLfloat, "z"), (GLfloat, "w")]),
170 DllFunction(Void, "glVertex4fv", [(Pointer(Const(GLfloat)), "v")]),
171 DllFunction(Void, "glVertex4i", [(GLint, "x"), (GLint, "y"), (GLint, "z"), (GLint, "w")]),
172 DllFunction(Void, "glVertex4iv", [(Pointer(Const(GLint)), "v")]),
173 DllFunction(Void, "glVertex4s", [(GLshort, "x"), (GLshort, "y"), (GLshort, "z"), (GLshort, "w")]),
174 DllFunction(Void, "glVertex4sv", [(Pointer(Const(GLshort)), "v")]),
175 DllFunction(Void, "glClipPlane", [(GLenum, "plane"), (Pointer(Const(GLdouble)), "equation")]),
176 DllFunction(Void, "glColorMaterial", [(GLenum, "face"), (GLenum, "mode")]),
177 DllFunction(Void, "glCullFace", [(GLenum, "mode")]),
178 DllFunction(Void, "glFogf", [(GLenum, "pname"), (GLfloat, "param")]),
179 DllFunction(Void, "glFogfv", [(GLenum, "pname"), (Pointer(Const(GLfloat)), "params")]),
180 DllFunction(Void, "glFogi", [(GLenum, "pname"), (GLint, "param")]),
181 DllFunction(Void, "glFogiv", [(GLenum, "pname"), (Pointer(Const(GLint)), "params")]),
182 DllFunction(Void, "glFrontFace", [(GLenum, "mode")]),
183 DllFunction(Void, "glHint", [(GLenum, "target"), (GLenum, "mode")]),
184 DllFunction(Void, "glLightf", [(GLenum, "light"), (GLenum, "pname"), (GLfloat, "param")]),
185 DllFunction(Void, "glLightfv", [(GLenum, "light"), (GLenum, "pname"), (Pointer(Const(GLfloat)), "params")]),
186 DllFunction(Void, "glLighti", [(GLenum, "light"), (GLenum, "pname"), (GLint, "param")]),
187 DllFunction(Void, "glLightiv", [(GLenum, "light"), (GLenum, "pname"), (Pointer(Const(GLint)), "params")]),
188 DllFunction(Void, "glLightModelf", [(GLenum, "pname"), (GLfloat, "param")]),
189 DllFunction(Void, "glLightModelfv", [(GLenum, "pname"), (Pointer(Const(GLfloat)), "params")]),
190 DllFunction(Void, "glLightModeli", [(GLenum, "pname"), (GLint, "param")]),
191 DllFunction(Void, "glLightModeliv", [(GLenum, "pname"), (Pointer(Const(GLint)), "params")]),
192 DllFunction(Void, "glLineStipple", [(GLint, "factor"), (GLushort, "pattern")]),
193 DllFunction(Void, "glLineWidth", [(GLfloat, "width")]),
194 DllFunction(Void, "glMaterialf", [(GLenum, "face"), (GLenum, "pname"), (GLfloat, "param")]),
195 DllFunction(Void, "glMaterialfv", [(GLenum, "face"), (GLenum, "pname"), (Pointer(Const(GLfloat)), "params")]),
196 DllFunction(Void, "glMateriali", [(GLenum, "face"), (GLenum, "pname"), (GLint, "param")]),
197 DllFunction(Void, "glMaterialiv", [(GLenum, "face"), (GLenum, "pname"), (Pointer(Const(GLint)), "params")]),
198 DllFunction(Void, "glPointSize", [(GLfloat, "size")]),
199 DllFunction(Void, "glPolygonMode", [(GLenum, "face"), (GLenum, "mode")]),
200 DllFunction(Void, "glPolygonStipple", [(Pointer(Const(GLubyte)), "mask")]),
201 DllFunction(Void, "glScissor", [(GLint, "x"), (GLint, "y"), (GLsizei, "width"), (GLsizei, "height")]),
202 DllFunction(Void, "glShadeModel", [(GLenum, "mode")]),
203 DllFunction(Void, "glTexParameterf", [(GLenum, "target"), (GLenum, "pname"), (GLfloat, "param")]),
204 DllFunction(Void, "glTexParameterfv", [(GLenum, "target"), (GLenum, "pname"), (Pointer(Const(GLfloat)), "params")]),
205 DllFunction(Void, "glTexParameteri", [(GLenum, "target"), (GLenum, "pname"), (GLint, "param")]),
206 DllFunction(Void, "glTexParameteriv", [(GLenum, "target"), (GLenum, "pname"), (Pointer(Const(GLint)), "params")]),
207 DllFunction(Void, "glTexImage1D", [(GLenum, "target"), (GLint, "level"), (GLint, "internalformat"), (GLsizei, "width"), (GLint, "border"), (GLenum, "format"), (GLenum, "type"), (Pointer(Const(GLvoid)), "pixels")]),
208 DllFunction(Void, "glTexImage2D", [(GLenum, "target"), (GLint, "level"), (GLint, "internalformat"), (GLsizei, "width"), (GLsizei, "height"), (GLint, "border"), (GLenum, "format"), (GLenum, "type"), (Pointer(Const(GLvoid)), "pixels")]),
209 DllFunction(Void, "glTexEnvf", [(GLenum, "target"), (GLenum, "pname"), (GLfloat, "param")]),
210 DllFunction(Void, "glTexEnvfv", [(GLenum, "target"), (GLenum, "pname"), (Pointer(Const(GLfloat)), "params")]),
211 DllFunction(Void, "glTexEnvi", [(GLenum, "target"), (GLenum, "pname"), (GLint, "param")]),
212 DllFunction(Void, "glTexEnviv", [(GLenum, "target"), (GLenum, "pname"), (Pointer(Const(GLint)), "params")]),
213 DllFunction(Void, "glTexGend", [(GLenum, "coord"), (GLenum, "pname"), (GLdouble, "param")]),
214 DllFunction(Void, "glTexGendv", [(GLenum, "coord"), (GLenum, "pname"), (Pointer(Const(GLdouble)), "params")]),
215 DllFunction(Void, "glTexGenf", [(GLenum, "coord"), (GLenum, "pname"), (GLfloat, "param")]),
216 DllFunction(Void, "glTexGenfv", [(GLenum, "coord"), (GLenum, "pname"), (Pointer(Const(GLfloat)), "params")]),
217 DllFunction(Void, "glTexGeni", [(GLenum, "coord"), (GLenum, "pname"), (GLint, "param")]),
218 DllFunction(Void, "glTexGeniv", [(GLenum, "coord"), (GLenum, "pname"), (Pointer(Const(GLint)), "params")]),
219 DllFunction(Void, "glFeedbackBuffer", [(GLsizei, "size"), (GLenum, "type"), (OutPointer(GLfloat), "buffer")]),
220 DllFunction(Void, "glSelectBuffer", [(GLsizei, "size"), (OutPointer(GLuint), "buffer")]),
221 DllFunction(GLint, "glRenderMode", [(GLenum, "mode")]),
222 DllFunction(Void, "glInitNames", []),
223 DllFunction(Void, "glLoadName", [(GLuint, "name")]),
224 DllFunction(Void, "glPassThrough", [(GLfloat, "token")]),
225 DllFunction(Void, "glPopName", []),
226 DllFunction(Void, "glPushName", [(GLuint, "name")]),
227 DllFunction(Void, "glDrawBuffer", [(GLenum, "mode")]),
228 DllFunction(Void, "glClear", [(GLbufferbitfield, "mask")]),
229 DllFunction(Void, "glClearAccum", [(GLfloat, "red"), (GLfloat, "green"), (GLfloat, "blue"), (GLfloat, "alpha")]),
230 DllFunction(Void, "glClearIndex", [(GLfloat, "c")]),
231 DllFunction(Void, "glClearColor", [(GLclampf, "red"), (GLclampf, "green"), (GLclampf, "blue"), (GLclampf, "alpha")]),
232 DllFunction(Void, "glClearStencil", [(GLint, "s")]),
233 DllFunction(Void, "glClearDepth", [(GLclampd, "depth")]),
234 DllFunction(Void, "glStencilMask", [(GLuint, "mask")]),
235 DllFunction(Void, "glColorMask", [(GLboolean, "red"), (GLboolean, "green"), (GLboolean, "blue"), (GLboolean, "alpha")]),
236 DllFunction(Void, "glDepthMask", [(GLboolean, "flag")]),
237 DllFunction(Void, "glIndexMask", [(GLuint, "mask")]),
238 DllFunction(Void, "glAccum", [(GLenum, "op"), (GLfloat, "value")]),
239 DllFunction(Void, "glDisable", [(GLenum, "cap")]),
240 DllFunction(Void, "glEnable", [(GLenum, "cap")]),
241 DllFunction(Void, "glFinish", []),
242 DllFunction(Void, "glFlush", []),
243 DllFunction(Void, "glPopAttrib", []),
244 DllFunction(Void, "glPushAttrib", [(GLbitfield, "mask")]),
245 DllFunction(Void, "glMap1d", [(GLenum, "target"), (GLdouble, "u1"), (GLdouble, "u2"), (GLint, "stride"), (GLint, "order"), (Pointer(Const(GLdouble)), "points")]),
246 DllFunction(Void, "glMap1f", [(GLenum, "target"), (GLfloat, "u1"), (GLfloat, "u2"), (GLint, "stride"), (GLint, "order"), (Pointer(Const(GLfloat)), "points")]),
247 DllFunction(Void, "glMap2d", [(GLenum, "target"), (GLdouble, "u1"), (GLdouble, "u2"), (GLint, "ustride"), (GLint, "uorder"), (GLdouble, "v1"), (GLdouble, "v2"), (GLint, "vstride"), (GLint, "vorder"), (Pointer(Const(GLdouble)), "points")]),
248 DllFunction(Void, "glMap2f", [(GLenum, "target"), (GLfloat, "u1"), (GLfloat, "u2"), (GLint, "ustride"), (GLint, "uorder"), (GLfloat, "v1"), (GLfloat, "v2"), (GLint, "vstride"), (GLint, "vorder"), (Pointer(Const(GLfloat)), "points")]),
249 DllFunction(Void, "glMapGrid1d", [(GLint, "un"), (GLdouble, "u1"), (GLdouble, "u2")]),
250 DllFunction(Void, "glMapGrid1f", [(GLint, "un"), (GLfloat, "u1"), (GLfloat, "u2")]),
251 DllFunction(Void, "glMapGrid2d", [(GLint, "un"), (GLdouble, "u1"), (GLdouble, "u2"), (GLint, "vn"), (GLdouble, "v1"), (GLdouble, "v2")]),
252 DllFunction(Void, "glMapGrid2f", [(GLint, "un"), (GLfloat, "u1"), (GLfloat, "u2"), (GLint, "vn"), (GLfloat, "v1"), (GLfloat, "v2")]),
253 DllFunction(Void, "glEvalCoord1d", [(GLdouble, "u")]),
254 DllFunction(Void, "glEvalCoord1dv", [(Pointer(Const(GLdouble)), "u")]),
255 DllFunction(Void, "glEvalCoord1f", [(GLfloat, "u")]),
256 DllFunction(Void, "glEvalCoord1fv", [(Pointer(Const(GLfloat)), "u")]),
257 DllFunction(Void, "glEvalCoord2d", [(GLdouble, "u"), (GLdouble, "v")]),
258 DllFunction(Void, "glEvalCoord2dv", [(Pointer(Const(GLdouble)), "u")]),
259 DllFunction(Void, "glEvalCoord2f", [(GLfloat, "u"), (GLfloat, "v")]),
260 DllFunction(Void, "glEvalCoord2fv", [(Pointer(Const(GLfloat)), "u")]),
261 DllFunction(Void, "glEvalMesh1", [(GLenum, "mode"), (GLint, "i1"), (GLint, "i2")]),
262 DllFunction(Void, "glEvalPoint1", [(GLint, "i")]),
263 DllFunction(Void, "glEvalMesh2", [(GLenum, "mode"), (GLint, "i1"), (GLint, "i2"), (GLint, "j1"), (GLint, "j2")]),
264 DllFunction(Void, "glEvalPoint2", [(GLint, "i"), (GLint, "j")]),
265 DllFunction(Void, "glAlphaFunc", [(GLenum, "func"), (GLclampf, "ref")]),
266 DllFunction(Void, "glBlendFunc", [(GLenum, "sfactor"), (GLenum, "dfactor")]),
267 DllFunction(Void, "glLogicOp", [(GLenum, "opcode")]),
268 DllFunction(Void, "glStencilFunc", [(GLenum, "func"), (GLint, "ref"), (GLuint, "mask")]),
269 DllFunction(Void, "glStencilOp", [(GLenum, "fail"), (GLenum, "zfail"), (GLenum, "zpass")]),
270 DllFunction(Void, "glDepthFunc", [(GLenum, "func")]),
271 DllFunction(Void, "glPixelZoom", [(GLfloat, "xfactor"), (GLfloat, "yfactor")]),
272 DllFunction(Void, "glPixelTransferf", [(GLenum, "pname"), (GLfloat, "param")]),
273 DllFunction(Void, "glPixelTransferi", [(GLenum, "pname"), (GLint, "param")]),
274 DllFunction(Void, "glPixelStoref", [(GLenum, "pname"), (GLfloat, "param")]),
275 DllFunction(Void, "glPixelStorei", [(GLenum, "pname"), (GLint, "param")]),
276 DllFunction(Void, "glPixelMapfv", [(GLenum, "map"), (GLsizei, "mapsize"), (Pointer(Const(GLfloat)), "values")]),
277 DllFunction(Void, "glPixelMapuiv", [(GLenum, "map"), (GLsizei, "mapsize"), (Pointer(Const(GLuint)), "values")]),
278 DllFunction(Void, "glPixelMapusv", [(GLenum, "map"), (GLsizei, "mapsize"), (Pointer(Const(GLushort)), "values")]),
279 DllFunction(Void, "glReadBuffer", [(GLenum, "mode")]),
280 DllFunction(Void, "glCopyPixels", [(GLint, "x"), (GLint, "y"), (GLsizei, "width"), (GLsizei, "height"), (GLenum, "type")]),
281 DllFunction(Void, "glReadPixels", [(GLint, "x"), (GLint, "y"), (GLsizei, "width"), (GLsizei, "height"), (GLenum, "format"), (GLenum, "type"), (OutPointer(GLvoid), "pixels")]),
282 DllFunction(Void, "glDrawPixels", [(GLsizei, "width"), (GLsizei, "height"), (GLenum, "format"), (GLenum, "type"), (Pointer(Const(GLvoid)), "pixels")]),
283 DllFunction(Void, "glGetBooleanv", [(GLenum, "pname"), (OutPointer(GLboolean), "params")]),
284 DllFunction(Void, "glGetClipPlane", [(GLenum, "plane"), (OutPointer(GLdouble), "equation")]),
285 DllFunction(Void, "glGetDoublev", [(GLenum, "pname"), (OutPointer(GLdouble), "params")]),
286 DllFunction(GLenum, "glGetError", []),
287 DllFunction(Void, "glGetFloatv", [(GLenum, "pname"), (OutPointer(GLfloat), "params")]),
288 DllFunction(Void, "glGetIntegerv", [(GLenum, "pname"), (OutPointer(GLint), "params")]),
289 DllFunction(Void, "glGetLightfv", [(GLenum, "light"), (GLenum, "pname"), (OutPointer(GLfloat), "params")]),
290 DllFunction(Void, "glGetLightiv", [(GLenum, "light"), (GLenum, "pname"), (OutPointer(GLint), "params")]),
291 DllFunction(Void, "glGetMapdv", [(GLenum, "target"), (GLenum, "query"), (OutPointer(GLdouble), "v")]),
292 DllFunction(Void, "glGetMapfv", [(GLenum, "target"), (GLenum, "query"), (OutPointer(GLfloat), "v")]),
293 DllFunction(Void, "glGetMapiv", [(GLenum, "target"), (GLenum, "query"), (OutPointer(GLint), "v")]),
294 DllFunction(Void, "glGetMaterialfv", [(GLenum, "face"), (GLenum, "pname"), (OutPointer(GLfloat), "params")]),
295 DllFunction(Void, "glGetMaterialiv", [(GLenum, "face"), (GLenum, "pname"), (OutPointer(GLint), "params")]),
296 DllFunction(Void, "glGetPixelMapfv", [(GLenum, "map"), (OutPointer(GLfloat), "values")]),
297 DllFunction(Void, "glGetPixelMapuiv", [(GLenum, "map"), (OutPointer(GLuint), "values")]),
298 DllFunction(Void, "glGetPixelMapusv", [(GLenum, "map"), (OutPointer(GLushort), "values")]),
299 DllFunction(Void, "glGetPolygonStipple", [(OutPointer(GLubyte), "mask")]),
300 DllFunction(Alias("const GLubyte *", String), "glGetString", [(GLenum, "name")]),
301 DllFunction(Void, "glGetTexEnvfv", [(GLenum, "target"), (GLenum, "pname"), (OutPointer(GLfloat), "params")]),
302 DllFunction(Void, "glGetTexEnviv", [(GLenum, "target"), (GLenum, "pname"), (OutPointer(GLint), "params")]),
303 DllFunction(Void, "glGetTexGendv", [(GLenum, "coord"), (GLenum, "pname"), (OutPointer(GLdouble), "params")]),
304 DllFunction(Void, "glGetTexGenfv", [(GLenum, "coord"), (GLenum, "pname"), (OutPointer(GLfloat), "params")]),
305 DllFunction(Void, "glGetTexGeniv", [(GLenum, "coord"), (GLenum, "pname"), (OutPointer(GLint), "params")]),
306 DllFunction(Void, "glGetTexImage", [(GLenum, "target"), (GLint, "level"), (GLenum, "format"), (GLenum, "type"), (OutPointer(GLvoid), "pixels")]),
307 DllFunction(Void, "glGetTexParameterfv", [(GLenum, "target"), (GLenum, "pname"), (OutPointer(GLfloat), "params")]),
308 DllFunction(Void, "glGetTexParameteriv", [(GLenum, "target"), (GLenum, "pname"), (OutPointer(GLint), "params")]),
309 DllFunction(Void, "glGetTexLevelParameterfv", [(GLenum, "target"), (GLint, "level"), (GLenum, "pname"), (OutPointer(GLfloat), "params")]),
310 DllFunction(Void, "glGetTexLevelParameteriv", [(GLenum, "target"), (GLint, "level"), (GLenum, "pname"), (OutPointer(GLint), "params")]),
311 DllFunction(GLboolean, "glIsEnabled", [(GLenum, "cap")]),
312 DllFunction(GLboolean, "glIsList", [(GLuint, "list")]),
313 DllFunction(Void, "glDepthRange", [(GLclampd, "zNear"), (GLclampd, "zFar")]),
314 DllFunction(Void, "glFrustum", [(GLdouble, "left"), (GLdouble, "right"), (GLdouble, "bottom"), (GLdouble, "top"), (GLdouble, "zNear"), (GLdouble, "zFar")]),
315 DllFunction(Void, "glLoadIdentity", []),
316 DllFunction(Void, "glLoadMatrixf", [(Pointer(Const(GLfloat)), "m")]),
317 DllFunction(Void, "glLoadMatrixd", [(Pointer(Const(GLdouble)), "m")]),
318 DllFunction(Void, "glMatrixMode", [(GLenum, "mode")]),
319 DllFunction(Void, "glMultMatrixf", [(Pointer(Const(GLfloat)), "m")]),
320 DllFunction(Void, "glMultMatrixd", [(Pointer(Const(GLdouble)), "m")]),
321 DllFunction(Void, "glOrtho", [(GLdouble, "left"), (GLdouble, "right"), (GLdouble, "bottom"), (GLdouble, "top"), (GLdouble, "zNear"), (GLdouble, "zFar")]),
322 DllFunction(Void, "glPopMatrix", []),
323 DllFunction(Void, "glPushMatrix", []),
324 DllFunction(Void, "glRotated", [(GLdouble, "angle"), (GLdouble, "x"), (GLdouble, "y"), (GLdouble, "z")]),
325 DllFunction(Void, "glRotatef", [(GLfloat, "angle"), (GLfloat, "x"), (GLfloat, "y"), (GLfloat, "z")]),
326 DllFunction(Void, "glScaled", [(GLdouble, "x"), (GLdouble, "y"), (GLdouble, "z")]),
327 DllFunction(Void, "glScalef", [(GLfloat, "x"), (GLfloat, "y"), (GLfloat, "z")]),
328 DllFunction(Void, "glTranslated", [(GLdouble, "x"), (GLdouble, "y"), (GLdouble, "z")]),
329 DllFunction(Void, "glTranslatef", [(GLfloat, "x"), (GLfloat, "y"), (GLfloat, "z")]),
330 DllFunction(Void, "glViewport", [(GLint, "x"), (GLint, "y"), (GLsizei, "width"), (GLsizei, "height")]),
331 DllFunction(Void, "glArrayElement", [(GLint, "i")]),
332 DllFunction(Void, "glBindTexture", [(GLenum, "target"), (GLuint, "texture")]),
333 DllFunction(Void, "glColorPointer", [(GLint, "size"), (GLenum, "type"), (GLsizei, "stride"), (Pointer(Const(GLvoid)), "pointer")]),
334 DllFunction(Void, "glDisableClientState", [(GLenum, "array")]),
335 DllFunction(Void, "glDrawArrays", [(GLenum, "mode"), (GLint, "first"), (GLsizei, "count")]),
336 DllFunction(Void, "glDrawElements", [(GLenum, "mode"), (GLsizei, "count"), (GLenum, "type"), (Pointer(Const(GLvoid)), "indices")]),
337 DllFunction(Void, "glEdgeFlagPointer", [(GLsizei, "stride"), (Pointer(Const(GLvoid)), "pointer")]),
338 DllFunction(Void, "glEnableClientState", [(GLenum, "array")]),
339 DllFunction(Void, "glIndexPointer", [(GLenum, "type"), (GLsizei, "stride"), (Pointer(Const(GLvoid)), "pointer")]),
340 DllFunction(Void, "glIndexub", [(GLubyte, "c")]),
341 DllFunction(Void, "glIndexubv", [(Pointer(Const(GLubyte)), "c")]),
342 DllFunction(Void, "glInterleavedArrays", [(GLenum, "format"), (GLsizei, "stride"), (Pointer(Const(GLvoid)), "pointer")]),
343 DllFunction(Void, "glNormalPointer", [(GLenum, "type"), (GLsizei, "stride"), (Pointer(Const(GLvoid)), "pointer")]),
344 DllFunction(Void, "glPolygonOffset", [(GLfloat, "factor"), (GLfloat, "units")]),
345 DllFunction(Void, "glTexCoordPointer", [(GLint, "size"), (GLenum, "type"), (GLsizei, "stride"), (Pointer(Const(GLvoid)), "pointer")]),
346 DllFunction(Void, "glVertexPointer", [(GLint, "size"), (GLenum, "type"), (GLsizei, "stride"), (Pointer(Const(GLvoid)), "pointer")]),
347 DllFunction(GLboolean, "glAreTexturesResident", [(GLsizei, "n"), (Pointer(Const(GLuint)), "textures"), (Pointer(GLboolean), "residences")]),
348 DllFunction(Void, "glCopyTexImage1D", [(GLenum, "target"), (GLint, "level"), (GLenum, "internalformat"), (GLint, "x"), (GLint, "y"), (GLsizei, "width"), (GLint, "border")]),
349 DllFunction(Void, "glCopyTexImage2D", [(GLenum, "target"), (GLint, "level"), (GLenum, "internalformat"), (GLint, "x"), (GLint, "y"), (GLsizei, "width"), (GLsizei, "height"), (GLint, "border")]),
350 DllFunction(Void, "glCopyTexSubImage1D", [(GLenum, "target"), (GLint, "level"), (GLint, "xoffset"), (GLint, "x"), (GLint, "y"), (GLsizei, "width")]),
351 DllFunction(Void, "glCopyTexSubImage2D", [(GLenum, "target"), (GLint, "level"), (GLint, "xoffset"), (GLint, "yoffset"), (GLint, "x"), (GLint, "y"), (GLsizei, "width"), (GLsizei, "height")]),
352 DllFunction(Void, "glDeleteTextures", [(GLsizei, "n"), (Pointer(Const(GLuint)), "textures")]),
353 DllFunction(Void, "glGenTextures", [(GLsizei, "n"), (Pointer(GLuint), "textures")]),
354 DllFunction(Void, "glGetPointerv", [(GLenum, "pname"), (Pointer(Pointer(GLvoid)), "params")]),
355 DllFunction(GLboolean, "glIsTexture", [(GLuint, "texture")]),
356 DllFunction(Void, "glPrioritizeTextures", [(GLsizei, "n"), (Pointer(Const(GLuint)), "textures"), (Pointer(Const(GLclampf)), "priorities")]),
357 DllFunction(Void, "glTexSubImage1D", [(GLenum, "target"), (GLint, "level"), (GLint, "xoffset"), (GLsizei, "width"), (GLenum, "format"), (GLenum, "type"), (Pointer(Const(GLvoid)), "pixels")]),
358 DllFunction(Void, "glTexSubImage2D", [(GLenum, "target"), (GLint, "level"), (GLint, "xoffset"), (GLint, "yoffset"), (GLsizei, "width"), (GLsizei, "height"), (GLenum, "format"), (GLenum, "type"), (Pointer(Const(GLvoid)), "pixels")]),
359 DllFunction(Void, "glPopClientAttrib", []),
360 DllFunction(Void, "glPushClientAttrib", [(GLbitfield, "mask")]),
361 DllFunction(Void, "glBlendColor", [(GLclampf, "red"), (GLclampf, "green"), (GLclampf, "blue"), (GLclampf, "alpha")]),
362 DllFunction(Void, "glBlendEquation", [(GLenum, "mode")]),
363 DllFunction(Void, "glDrawRangeElements", [(GLenum, "mode"), (GLuint, "start"), (GLuint, "end"), (GLsizei, "count"), (GLenum, "type"), (Pointer(Const(GLvoid)), "indices")]),
364 DllFunction(Void, "glColorTable", [(GLenum, "target"), (GLenum, "internalformat"), (GLsizei, "width"), (GLenum, "format"), (GLenum, "type"), (Pointer(Const(GLvoid)), "table")]),
365 DllFunction(Void, "glColorTableParameterfv", [(GLenum, "target"), (GLenum, "pname"), (Pointer(Const(GLfloat)), "params")]),
366 DllFunction(Void, "glColorTableParameteriv", [(GLenum, "target"), (GLenum, "pname"), (Pointer(Const(GLint)), "params")]),
367 DllFunction(Void, "glCopyColorTable", [(GLenum, "target"), (GLenum, "internalformat"), (GLint, "x"), (GLint, "y"), (GLsizei, "width")]),
368 DllFunction(Void, "glGetColorTable", [(GLenum, "target"), (GLenum, "format"), (GLenum, "type"), (Pointer(GLvoid), "table")]),
369 DllFunction(Void, "glGetColorTableParameterfv", [(GLenum, "target"), (GLenum, "pname"), (Pointer(GLfloat), "params")]),
370 DllFunction(Void, "glGetColorTableParameteriv", [(GLenum, "target"), (GLenum, "pname"), (Pointer(GLint), "params")]),
371 DllFunction(Void, "glColorSubTable", [(GLenum, "target"), (GLsizei, "start"), (GLsizei, "count"), (GLenum, "format"), (GLenum, "type"), (Pointer(Const(GLvoid)), "data")]),
372 DllFunction(Void, "glCopyColorSubTable", [(GLenum, "target"), (GLsizei, "start"), (GLint, "x"), (GLint, "y"), (GLsizei, "width")]),
373 DllFunction(Void, "glConvolutionFilter1D", [(GLenum, "target"), (GLenum, "internalformat"), (GLsizei, "width"), (GLenum, "format"), (GLenum, "type"), (Pointer(Const(GLvoid)), "image")]),
374 DllFunction(Void, "glConvolutionFilter2D", [(GLenum, "target"), (GLenum, "internalformat"), (GLsizei, "width"), (GLsizei, "height"), (GLenum, "format"), (GLenum, "type"), (Pointer(Const(GLvoid)), "image")]),
375 DllFunction(Void, "glConvolutionParameterf", [(GLenum, "target"), (GLenum, "pname"), (GLfloat, "params")]),
376 DllFunction(Void, "glConvolutionParameterfv", [(GLenum, "target"), (GLenum, "pname"), (Pointer(Const(GLfloat)), "params")]),
377 DllFunction(Void, "glConvolutionParameteri", [(GLenum, "target"), (GLenum, "pname"), (GLint, "params")]),
378 DllFunction(Void, "glConvolutionParameteriv", [(GLenum, "target"), (GLenum, "pname"), (Pointer(Const(GLint)), "params")]),
379 DllFunction(Void, "glCopyConvolutionFilter1D", [(GLenum, "target"), (GLenum, "internalformat"), (GLint, "x"), (GLint, "y"), (GLsizei, "width")]),
380 DllFunction(Void, "glCopyConvolutionFilter2D", [(GLenum, "target"), (GLenum, "internalformat"), (GLint, "x"), (GLint, "y"), (GLsizei, "width"), (GLsizei, "height")]),
381 DllFunction(Void, "glGetConvolutionFilter", [(GLenum, "target"), (GLenum, "format"), (GLenum, "type"), (Pointer(GLvoid), "image")]),
382 DllFunction(Void, "glGetConvolutionParameterfv", [(GLenum, "target"), (GLenum, "pname"), (Pointer(GLfloat), "params")]),
383 DllFunction(Void, "glGetConvolutionParameteriv", [(GLenum, "target"), (GLenum, "pname"), (Pointer(GLint), "params")]),
384 DllFunction(Void, "glGetSeparableFilter", [(GLenum, "target"), (GLenum, "format"), (GLenum, "type"), (Pointer(GLvoid), "row"), (Pointer(GLvoid), "column"), (Pointer(GLvoid), "span")]),
385 DllFunction(Void, "glSeparableFilter2D", [(GLenum, "target"), (GLenum, "internalformat"), (GLsizei, "width"), (GLsizei, "height"), (GLenum, "format"), (GLenum, "type"), (Pointer(Const(GLvoid)), "row"), (Pointer(Const(GLvoid)), "column")]),
386 DllFunction(Void, "glGetHistogram", [(GLenum, "target"), (GLboolean, "reset"), (GLenum, "format"), (GLenum, "type"), (Pointer(GLvoid), "values")]),
387 DllFunction(Void, "glGetHistogramParameterfv", [(GLenum, "target"), (GLenum, "pname"), (Pointer(GLfloat), "params")]),
388 DllFunction(Void, "glGetHistogramParameteriv", [(GLenum, "target"), (GLenum, "pname"), (Pointer(GLint), "params")]),
389 DllFunction(Void, "glGetMinmax", [(GLenum, "target"), (GLboolean, "reset"), (GLenum, "format"), (GLenum, "type"), (Pointer(GLvoid), "values")]),
390 DllFunction(Void, "glGetMinmaxParameterfv", [(GLenum, "target"), (GLenum, "pname"), (Pointer(GLfloat), "params")]),
391 DllFunction(Void, "glGetMinmaxParameteriv", [(GLenum, "target"), (GLenum, "pname"), (Pointer(GLint), "params")]),
392 DllFunction(Void, "glHistogram", [(GLenum, "target"), (GLsizei, "width"), (GLenum, "internalformat"), (GLboolean, "sink")]),
393 DllFunction(Void, "glMinmax", [(GLenum, "target"), (GLenum, "internalformat"), (GLboolean, "sink")]),
394 DllFunction(Void, "glResetHistogram", [(GLenum, "target")]),
395 DllFunction(Void, "glResetMinmax", [(GLenum, "target")]),
396 DllFunction(Void, "glTexImage3D", [(GLenum, "target"), (GLint, "level"), (GLint, "internalformat"), (GLsizei, "width"), (GLsizei, "height"), (GLsizei, "depth"), (GLint, "border"), (GLenum, "format"), (GLenum, "type"), (Pointer(Const(GLvoid)), "pixels")]),
397 DllFunction(Void, "glTexSubImage3D", [(GLenum, "target"), (GLint, "level"), (GLint, "xoffset"), (GLint, "yoffset"), (GLint, "zoffset"), (GLsizei, "width"), (GLsizei, "height"), (GLsizei, "depth"), (GLenum, "format"), (GLenum, "type"), (Pointer(Const(GLvoid)), "pixels")]),
398 DllFunction(Void, "glCopyTexSubImage3D", [(GLenum, "target"), (GLint, "level"), (GLint, "xoffset"), (GLint, "yoffset"), (GLint, "zoffset"), (GLint, "x"), (GLint, "y"), (GLsizei, "width"), (GLsizei, "height")]),
399 DllFunction(Void, "glActiveTextureARB", [(GLenum, "texture")]),
400 DllFunction(Void, "glClientActiveTextureARB", [(GLenum, "texture")]),
401 DllFunction(Void, "glMultiTexCoord1dARB", [(GLenum, "target"), (GLdouble, "s")]),
402 DllFunction(Void, "glMultiTexCoord1dvARB", [(GLenum, "target"), (Pointer(Const(GLdouble)), "v")]),
403 DllFunction(Void, "glMultiTexCoord1fARB", [(GLenum, "target"), (GLfloat, "s")]),
404 DllFunction(Void, "glMultiTexCoord1fvARB", [(GLenum, "target"), (Pointer(Const(GLfloat)), "v")]),
405 DllFunction(Void, "glMultiTexCoord1iARB", [(GLenum, "target"), (GLint, "s")]),
406 DllFunction(Void, "glMultiTexCoord1ivARB", [(GLenum, "target"), (Pointer(Const(GLint)), "v")]),
407 DllFunction(Void, "glMultiTexCoord1sARB", [(GLenum, "target"), (GLshort, "s")]),
408 DllFunction(Void, "glMultiTexCoord1svARB", [(GLenum, "target"), (Pointer(Const(GLshort)), "v")]),
409 DllFunction(Void, "glMultiTexCoord2dARB", [(GLenum, "target"), (GLdouble, "s"), (GLdouble, "t")]),
410 DllFunction(Void, "glMultiTexCoord2dvARB", [(GLenum, "target"), (Pointer(Const(GLdouble)), "v")]),
411 DllFunction(Void, "glMultiTexCoord2fARB", [(GLenum, "target"), (GLfloat, "s"), (GLfloat, "t")]),
412 DllFunction(Void, "glMultiTexCoord2fvARB", [(GLenum, "target"), (Pointer(Const(GLfloat)), "v")]),
413 DllFunction(Void, "glMultiTexCoord2iARB", [(GLenum, "target"), (GLint, "s"), (GLint, "t")]),
414 DllFunction(Void, "glMultiTexCoord2ivARB", [(GLenum, "target"), (Pointer(Const(GLint)), "v")]),
415 DllFunction(Void, "glMultiTexCoord2sARB", [(GLenum, "target"), (GLshort, "s"), (GLshort, "t")]),
416 DllFunction(Void, "glMultiTexCoord2svARB", [(GLenum, "target"), (Pointer(Const(GLshort)), "v")]),
417 DllFunction(Void, "glMultiTexCoord3dARB", [(GLenum, "target"), (GLdouble, "s"), (GLdouble, "t"), (GLdouble, "r")]),
418 DllFunction(Void, "glMultiTexCoord3dvARB", [(GLenum, "target"), (Pointer(Const(GLdouble)), "v")]),
419 DllFunction(Void, "glMultiTexCoord3fARB", [(GLenum, "target"), (GLfloat, "s"), (GLfloat, "t"), (GLfloat, "r")]),
420 DllFunction(Void, "glMultiTexCoord3fvARB", [(GLenum, "target"), (Pointer(Const(GLfloat)), "v")]),
421 DllFunction(Void, "glMultiTexCoord3iARB", [(GLenum, "target"), (GLint, "s"), (GLint, "t"), (GLint, "r")]),
422 DllFunction(Void, "glMultiTexCoord3ivARB", [(GLenum, "target"), (Pointer(Const(GLint)), "v")]),
423 DllFunction(Void, "glMultiTexCoord3sARB", [(GLenum, "target"), (GLshort, "s"), (GLshort, "t"), (GLshort, "r")]),
424 DllFunction(Void, "glMultiTexCoord3svARB", [(GLenum, "target"), (Pointer(Const(GLshort)), "v")]),
425 DllFunction(Void, "glMultiTexCoord4dARB", [(GLenum, "target"), (GLdouble, "s"), (GLdouble, "t"), (GLdouble, "r"), (GLdouble, "q")]),
426 DllFunction(Void, "glMultiTexCoord4dvARB", [(GLenum, "target"), (Pointer(Const(GLdouble)), "v")]),
427 DllFunction(Void, "glMultiTexCoord4fARB", [(GLenum, "target"), (GLfloat, "s"), (GLfloat, "t"), (GLfloat, "r"), (GLfloat, "q")]),
428 DllFunction(Void, "glMultiTexCoord4fvARB", [(GLenum, "target"), (Pointer(Const(GLfloat)), "v")]),
429 DllFunction(Void, "glMultiTexCoord4iARB", [(GLenum, "target"), (GLint, "s"), (GLint, "t"), (GLint, "r"), (GLint, "q")]),
430 DllFunction(Void, "glMultiTexCoord4ivARB", [(GLenum, "target"), (Pointer(Const(GLint)), "v")]),
431 DllFunction(Void, "glMultiTexCoord4sARB", [(GLenum, "target"), (GLshort, "s"), (GLshort, "t"), (GLshort, "r"), (GLshort, "q")]),
432 DllFunction(Void, "glMultiTexCoord4svARB", [(GLenum, "target"), (Pointer(Const(GLshort)), "v")]),
435 HGLRC = Alias("HGLRC", HANDLE)
436 PROC = Intrinsic("PROC", "%p")
441 "PFD_DRAW_TO_WINDOW",
442 "PFD_DRAW_TO_BITMAP",
444 "PFD_SUPPORT_OPENGL",
445 "PFD_GENERIC_FORMAT",
447 "PFD_NEED_SYSTEM_PALETTE",
450 "PFD_SWAP_LAYER_BUFFERS",
451 "PFD_GENERIC_ACCELERATED",
452 #"PFD_SUPPORT_DIRECTDRAW",
455 PIXELFORMATDESCRIPTOR = Struct("PIXELFORMATDESCRIPTOR", [
459 (BYTE, "iPixelType"),
460 (BYTE, "cColorBits"),
463 (BYTE, "cGreenBits"),
464 (BYTE, "cGreenShift"),
466 (BYTE, "cBlueShift"),
467 (BYTE, "cAlphaBits"),
468 (BYTE, "cAlphaShift"),
469 (BYTE, "cAccumBits"),
470 (BYTE, "cAccumRedBits"),
471 (BYTE, "cAccumGreenBits"),
472 (BYTE, "cAccumBlueBits"),
473 (BYTE, "cAccumAlphaBits"),
474 (BYTE, "cDepthBits"),
475 (BYTE, "cStencilBits"),
476 (BYTE, "cAuxBuffers"),
477 (BYTE, "iLayerType"),
479 (DWORD, "dwLayerMask"),
480 (DWORD, "dwVisibleMask"),
481 (DWORD, "dwDamageMask"),
484 POINTFLOAT = Struct("POINTFLOAT", [
489 GLYPHMETRICSFLOAT = Struct("GLYPHMETRICSFLOAT", [
490 (FLOAT, "gmfBlackBoxX"),
491 (FLOAT, "gmfBlackBoxY"),
492 (POINTFLOAT, "gmfptGlyphOrigin"),
493 (FLOAT, "gmfCellIncX"),
494 (FLOAT, "gmfCellIncY"),
496 LPGLYPHMETRICSFLOAT = Pointer(GLYPHMETRICSFLOAT)
498 COLORREF = Alias("COLORREF", DWORD)
501 LAYERPLANEDESCRIPTOR = Struct("LAYERPLANEDESCRIPTOR", [
505 (BYTE, "iPixelType"),
506 (BYTE, "cColorBits"),
509 (BYTE, "cGreenBits"),
510 (BYTE, "cGreenShift"),
512 (BYTE, "cBlueShift"),
513 (BYTE, "cAlphaBits"),
514 (BYTE, "cAlphaShift"),
515 (BYTE, "cAccumBits"),
516 (BYTE, "cAccumRedBits"),
517 (BYTE, "cAccumGreenBits"),
518 (BYTE, "cAccumBlueBits"),
519 (BYTE, "cAccumAlphaBits"),
520 (BYTE, "cDepthBits"),
521 (BYTE, "cStencilBits"),
522 (BYTE, "cAuxBuffers"),
523 (BYTE, "iLayerPlane"),
525 (COLORREF, "crTransparent"),
527 LPLAYERPLANEDESCRIPTOR = Pointer(LAYERPLANEDESCRIPTOR)
529 opengl32.functions += [
530 DllFunction(BOOL, "wglCopyContext", [(HGLRC, "hglrcSrc"), (HGLRC, "hglrcDst"), (UINT, "mask")]),
531 DllFunction(HGLRC, "wglCreateContext", [(HDC, "hdc")]),
532 DllFunction(HGLRC, "wglCreateLayerContext", [(HDC, "hdc"), (Int, "iLayerPlane")]),
533 DllFunction(BOOL, "wglDeleteContext", [(HGLRC, "hglrc")]),
534 DllFunction(HGLRC, "wglGetCurrentContext", []),
535 DllFunction(HDC, "wglGetCurrentDC", []),
536 DllFunction(PROC, "wglGetProcAddress", [(LPCSTR, "lpszProc")]),
537 DllFunction(PROC, "wglGetDefaultProcAddress", [(LPCSTR, "lpszProc")]),
538 DllFunction(Int, "wglChoosePixelFormat", [(HDC, "hdc"), (Pointer(Const(PIXELFORMATDESCRIPTOR)), "ppfd")]),
539 DllFunction(Int, "wglDescribePixelFormat", [(HDC, "hdc"), (Int, "iPixelFormat"), (UINT, "nBytes"), (OutPointer(PIXELFORMATDESCRIPTOR), "ppfd")]),
540 DllFunction(Int, "wglGetPixelFormat", [(HDC, "hdc")]),
541 DllFunction(BOOL, "wglSetPixelFormat", [(HDC, "hdc"), (Int, "iPixelFormat"), (Pointer(Const(PIXELFORMATDESCRIPTOR)), "ppfd")]),
542 DllFunction(BOOL, "wglMakeCurrent", [(HDC, "hdc"), (HGLRC, "hglrc")]),
543 DllFunction(BOOL, "wglShareLists", [(HGLRC, "hglrc1"), (HGLRC, "hglrc2")]),
544 DllFunction(BOOL, "wglUseFontBitmapsA", [(HDC, "hdc"), (DWORD, "first"), (DWORD, "count"), (DWORD, "listBase")]),
545 DllFunction(BOOL, "wglUseFontBitmapsW", [(HDC, "hdc"), (DWORD, "first"), (DWORD, "count"), (DWORD, "listBase")]),
546 DllFunction(BOOL, "wglSwapBuffers", [(HDC, "hdc")]),
547 DllFunction(BOOL, "wglUseFontOutlinesA", [(HDC, "hdc"), (DWORD, "first"), (DWORD, "count"), (DWORD, "listBase"), (FLOAT, "deviation"), (FLOAT, "extrusion"), (Int, "format"), (LPGLYPHMETRICSFLOAT, "lpgmf")]),
548 DllFunction(BOOL, "wglUseFontOutlinesW", [(HDC, "hdc"), (DWORD, "first"), (DWORD, "count"), (DWORD, "listBase"), (FLOAT, "deviation"), (FLOAT, "extrusion"), (Int, "format"), (LPGLYPHMETRICSFLOAT, "lpgmf")]),
549 DllFunction(BOOL , "wglDescribeLayerPlane", [(HDC, "hdc"), (Int, "iPixelFormat"), (Int, "iLayerPlane"), (UINT, "nBytes"), (OutPointer(LAYERPLANEDESCRIPTOR), "plpd")]),
550 DllFunction(Int , "wglSetLayerPaletteEntries", [(HDC, "hdc"), (Int, "iLayerPlane"), (Int, "iStart"), (Int, "cEntries"), (Pointer(Const(COLORREF)), "pcr")]),
551 DllFunction(Int , "wglGetLayerPaletteEntries", [(HDC, "hdc"), (Int, "iLayerPlane"), (Int, "iStart"), (Int, "cEntries"), (OutPointer(COLORREF), "pcr")]),
552 DllFunction(BOOL , "wglRealizeLayerPalette", [(HDC, "hdc"), (Int, "iLayerPlane"), (BOOL, "bRealize")]),
553 DllFunction(BOOL , "wglSwapLayerBuffers", [(HDC, "hdc"), (UINT, "fuPlanes")]),
557 WGLSWAP = Struct("WGLSWAP", [
562 opengl32.functions += [
563 DllFunction(DWORD, "wglSwapMultipleBuffers", [(UINT, "n"), (Pointer(Const(WGLSWAP)), "ps")]),
566 if __name__ == '__main__':
568 print '#define _GDI32_'
570 print '#include <windows.h>'
571 print '#include <tchar.h>'
572 print '#include <GL/gl.h>'
573 print '#include "glext.h"'
574 print '#include "wglext.h"'
576 print '#include "log.hpp"'