10 ** License Applicability. Except to the extent portions of this file are
11 ** made subject to an alternative license as permitted in the SGI Free
12 ** Software License B, Version 1.0 (the "License"), the contents of this
13 ** file are subject only to the provisions of the License. You may not use
14 ** this file except in compliance with the License. You may obtain a copy
15 ** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
16 ** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
18 ** http://oss.sgi.com/projects/FreeB
20 ** Note that, as provided in the License, the Software is distributed on an
21 ** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
22 ** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
23 ** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
24 ** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
26 ** Original Code. The Original Code is: OpenGL Sample Implementation,
27 ** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
28 ** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
29 ** Copyright in any portions created by third parties is as indicated
30 ** elsewhere herein. All Rights Reserved.
32 ** Additional Notice Provisions: The application programming interfaces
33 ** established by SGI in conjunction with the Original Code are The
34 ** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
35 ** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
36 ** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
37 ** Window System(R) (Version 1.3), released October 19, 1998. This software
38 ** was created using the OpenGL(R) version 1.2.1 Sample Implementation
39 ** published by SGI, but has not been independently verified as being
40 ** compliant with the OpenGL(R) version 1.2.1 Specification.
44 # define GL_APIENTRYP GL_APIENTRY*
47 /*------------------------------------------------------------------------*
48 * OES extension tokens
49 *------------------------------------------------------------------------*/
51 /* GL_OES_compressed_ETC1_RGB8_texture */
52 #ifndef GL_OES_compressed_ETC1_RGB8_texture
53 #define GL_ETC1_RGB8_OES 0x8D64
56 /* GL_OES_compressed_paletted_texture */
57 #ifndef GL_OES_compressed_paletted_texture
58 #define GL_PALETTE4_RGB8_OES 0x8B90
59 #define GL_PALETTE4_RGBA8_OES 0x8B91
60 #define GL_PALETTE4_R5_G6_B5_OES 0x8B92
61 #define GL_PALETTE4_RGBA4_OES 0x8B93
62 #define GL_PALETTE4_RGB5_A1_OES 0x8B94
63 #define GL_PALETTE8_RGB8_OES 0x8B95
64 #define GL_PALETTE8_RGBA8_OES 0x8B96
65 #define GL_PALETTE8_R5_G6_B5_OES 0x8B97
66 #define GL_PALETTE8_RGBA4_OES 0x8B98
67 #define GL_PALETTE8_RGB5_A1_OES 0x8B99
70 /* GL_OES_EGL_image */
71 #ifndef GL_OES_EGL_image
72 typedef void* GLeglImageOES;
76 #ifndef GL_OES_depth24
77 #define GL_DEPTH_COMPONENT24_OES 0x81A6
81 #ifndef GL_OES_depth32
82 #define GL_DEPTH_COMPONENT32_OES 0x81A7
85 /* GL_OES_depth_texture */
86 /* No new tokens introduced by this extension. */
88 /* GL_OES_mapbuffer */
89 #ifndef GL_OES_mapbuffer
90 /* GL_READ_ONLY and GL_READ_WRITE not supported */
91 #define GL_WRITE_ONLY_OES 0x88B9
92 #define GL_BUFFER_ACCESS_OES 0x88BB
93 #define GL_BUFFER_MAPPED_OES 0x88BC
94 #define GL_BUFFER_MAP_POINTER_OES 0x88BD
97 /* GL_OES_packed_depth_stencil */
98 #ifndef GL_OES_packed_depth_stencil
99 #define GL_DEPTH_STENCIL_OES 0x84F9
100 #define GL_UNSIGNED_INT_24_8_OES 0x84FA
101 #define GL_DEPTH24_STENCIL8_OES 0x88F0
104 /* GL_OES_rgb8_rgba8 */
105 #ifndef GL_OES_rgb8_rgba8
106 #define GL_RGB8_OES 0x8051
107 #define GL_RGBA8_OES 0x8058
110 /* GL_OES_standard_derivatives */
111 #ifndef GL_OES_standard_derivatives
112 #define GL_FRAGMENT_SHADER_DERIVATIVE_HINT_OES 0x8B8B
115 /* GL_OES_stencil1 */
116 #ifndef GL_OES_stencil1
117 #define GL_STENCIL_INDEX1_OES 0x8D46
120 /* GL_OES_stencil4 */
121 #ifndef GL_OES_stencil4
122 #define GL_STENCIL_INDEX4_OES 0x8D47
125 /* GL_OES_texture3D */
126 #ifndef GL_OES_texture3D
127 #define GL_TEXTURE_WRAP_R_OES 0x8072
128 #define GL_TEXTURE_3D_OES 0x806F
129 #define GL_TEXTURE_BINDING_3D_OES 0x806A
130 #define GL_MAX_3D_TEXTURE_SIZE_OES 0x8073
131 #define GL_SAMPLER_3D_OES 0x8B5F
132 #define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_3D_ZOFFSET_OES 0x8CD4
135 /* GL_OES_texture_half_float */
136 #ifndef GL_OES_texture_half_float
137 #define GL_HALF_FLOAT_OES 0x8D61
140 /* GL_OES_vertex_half_float */
141 /* GL_HALF_FLOAT_OES defined in GL_OES_texture_half_float already. */
143 /* GL_OES_vertex_type_10_10_10_2 */
144 #ifndef GL_OES_vertex_type_10_10_10_2
145 #define GL_UNSIGNED_INT_10_10_10_2_OES 0x8DF6
146 #define GL_INT_10_10_10_2_OES 0x8DF7
149 /* GL_OES_get_program_binary */
150 #ifndef GL_OES_get_program_binary
151 #define GL_PROGRAM_BINARY_LENGTH_OES 0x8741
152 #define GL_NUM_PROGRAM_BINARY_FORMATS_OES 0x87FE
153 #define GL_PROGRAM_BINARY_FORMATS_OES 0x87FF
156 /* GL_AMD_program_binary_Z400 */
157 #ifndef GL_AMD_program_binary_Z400
158 #define GL_Z400_BINARY_AMD 0x8740
161 /*------------------------------------------------------------------------*
162 * AMD extension tokens
163 *------------------------------------------------------------------------*/
165 /* GL_AMD_compressed_3DC_texture */
166 #ifndef GL_AMD_compressed_3DC_texture
167 #define GL_3DC_X_AMD 0x87F9
168 #define GL_3DC_XY_AMD 0x87FA
171 /* GL_AMD_compressed_ATC_texture */
172 #ifndef GL_AMD_compressed_ATC_texture
173 #define GL_ATC_RGB_AMD 0x8C92
174 #define GL_ATC_RGBA_EXPLICIT_ALPHA_AMD 0x8C93
175 #define GL_ATC_RGBA_INTERPOLATED_ALPHA_AMD 0x87EE
178 /*------------------------------------------------------------------------*
179 * EXT extension tokens
180 *------------------------------------------------------------------------*/
182 /* GL_EXT_texture_filter_anisotropic */
183 #ifndef GL_EXT_texture_filter_anisotropic
184 #define GL_TEXTURE_MAX_ANISOTROPY_EXT 0x84FE
185 #define GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT 0x84FF
188 /* GL_EXT_texture_type_2_10_10_10_REV */
189 #ifndef GL_EXT_texture_type_2_10_10_10_REV
190 #define GL_UNSIGNED_INT_2_10_10_10_REV_EXT 0x8368
193 /*------------------------------------------------------------------------*
194 * OES extension functions
195 *------------------------------------------------------------------------*/
197 /* GL_OES_compressed_ETC1_RGB8_texture */
198 #ifndef GL_OES_compressed_ETC1_RGB8_texture
199 #define GL_OES_compressed_ETC1_RGB8_texture 1
202 /* GL_OES_compressed_paletted_texture */
203 #ifndef GL_OES_compressed_paletted_texture
204 #define GL_OES_compressed_paletted_texture 1
207 /* GL_OES_EGL_image */
208 #ifndef GL_OES_EGL_image
209 #define GL_OES_EGL_image 1
210 #ifdef GL_GLEXT_PROTOTYPES
211 GL_APICALL void GL_APIENTRY glEGLImageTargetTexture2DOES (GLenum target, GLeglImageOES image);
212 GL_APICALL void GL_APIENTRY glEGLImageTargetRenderbufferStorageOES (GLenum target, GLeglImageOES image);
214 typedef void (GL_APIENTRYP PFNGLEGLIMAGETARGETTEXTURE2DOESPROC) (GLenum target, GLeglImageOES image);
215 typedef void (GL_APIENTRYP PFNGLEGLIMAGETARGETRENDERBUFFERSTORAGEOESPROC) (GLenum target, GLeglImageOES image);
219 #ifndef GL_OES_depth24
220 #define GL_OES_depth24 1
224 #ifndef GL_OES_depth32
225 #define GL_OES_depth32 1
228 /* GL_OES_depth_texture */
229 #ifndef GL_OES_depth_texture
230 #define GL_OES_depth_texture 1
233 /* GL_OES_element_index_uint */
234 #ifndef GL_OES_element_index_uint
235 #define GL_OES_element_index_uint 1
238 /* GL_OES_fbo_render_mipmap */
239 #ifndef GL_OES_fbo_render_mipmap
240 #define GL_OES_fbo_render_mipmap 1
243 /* GL_OES_fragment_precision_high */
244 #ifndef GL_OES_fragment_precision_high
245 #define GL_OES_fragment_precision_high 1
248 /* GL_OES_mapbuffer */
249 #ifndef GL_OES_mapbuffer
250 #define GL_OES_mapbuffer 1
251 #ifdef GL_GLEXT_PROTOTYPES
252 GL_APICALL void* GL_APIENTRY glMapBufferOES (GLenum target, GLenum access);
253 GL_APICALL GLboolean GL_APIENTRY glUnmapBufferOES (GLenum target);
254 GL_APICALL void GL_APIENTRY glGetBufferPointervOES (GLenum target, GLenum pname, void** params);
256 typedef void* (GL_APIENTRYP PFNGLMAPBUFFEROESPROC) (GLenum target, GLenum access);
257 typedef GLboolean (GL_APIENTRYP PFNGLUNMAPBUFFEROESPROC) (GLenum target);
258 typedef void (GL_APIENTRYP PFNGLGETBUFFERPOINTERVOESPROC) (GLenum target, GLenum pname, void** params);
261 /* GL_OES_packed_depth_stencil */
262 #ifndef GL_OES_packed_depth_stencil
263 #define GL_OES_packed_depth_stencil 1
266 /* GL_OES_rgb8_rgba8 */
267 #ifndef GL_OES_rgb8_rgba8
268 #define GL_OES_rgb8_rgba8 1
271 /* GL_OES_standard_derivatives */
272 #ifndef GL_OES_standard_derivatives
273 #define GL_OES_standard_derivatives 1
276 /* GL_OES_stencil1 */
277 #ifndef GL_OES_stencil1
278 #define GL_OES_stencil1 1
281 /* GL_OES_stencil4 */
282 #ifndef GL_OES_stencil4
283 #define GL_OES_stencil4 1
286 /* GL_OES_texture_3D */
287 #ifndef GL_OES_texture_3D
288 #define GL_OES_texture_3D 1
289 #ifdef GL_GLEXT_PROTOTYPES
290 GL_APICALL void GL_APIENTRY glTexImage3DOES (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const void* pixels);
291 GL_APICALL void GL_APIENTRY glTexSubImage3DOES (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const void* pixels);
292 GL_APICALL void GL_APIENTRY glCopyTexSubImage3DOES (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
293 GL_APICALL void GL_APIENTRY glCompressedTexImage3DOES (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const void* data);
294 GL_APICALL void GL_APIENTRY glCompressedTexSubImage3DOES (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const void* data);
295 GL_APICALL void GL_APIENTRY glFramebufferTexture3DOES (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
297 typedef void (GL_APIENTRYP PFNGLTEXIMAGE3DOESPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid* pixels);
298 typedef void (GL_APIENTRYP PFNGLTEXSUBIMAGE3DOESPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const void* pixels);
299 typedef void (GL_APIENTRYP PFNGLCOPYTEXSUBIMAGE3DOESPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
300 typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXIMAGE3DOESPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const void* data);
301 typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE3DOESPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const void* data);
302 typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTURE3DOES) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
305 /* GL_OES_texture_float_linear */
306 #ifndef GL_OES_texture_float_linear
307 #define GL_OES_texture_float_linear 1
310 /* GL_OES_texture_half_float_linear */
311 #ifndef GL_OES_texture_half_float_linear
312 #define GL_OES_texture_half_float_linear 1
315 /* GL_OES_texture_float */
316 #ifndef GL_OES_texture_float
317 #define GL_OES_texture_float 1
320 /* GL_OES_texture_half_float */
321 #ifndef GL_OES_texture_half_float
322 #define GL_OES_texture_half_float 1
325 /* GL_OES_texture_npot */
326 #ifndef GL_OES_texture_npot
327 #define GL_OES_texture_npot 1
330 /* GL_OES_vertex_half_float */
331 #ifndef GL_OES_vertex_half_float
332 #define GL_OES_vertex_half_float 1
335 /* GL_OES_vertex_type_10_10_10_2 */
336 #ifndef GL_OES_vertex_type_10_10_10_2
337 #define GL_OES_vertex_type_10_10_10_2 1
340 /* GL_OES_get_program_binary */
341 #ifndef GL_OES_get_program_binary
342 #define GL_OES_get_program_binary 1
343 #ifdef GL_GLEXT_PROTOTYPES
344 GL_APICALL void GL_APIENTRY glGetProgramBinaryOES (GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, void *binary);
345 GL_APICALL void GL_APIENTRY glProgramBinaryOES (GLuint program, GLenum binaryFormat, const void *binary, GLint length);
347 typedef void (GL_APIENTRYP PFNGLGETPROGRAMBINARYOESPROC) (GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, void *binary);
348 typedef void (GL_APIENTRYP PFNGLPROGRAMBINARYOESPROC) (GLuint program, GLenum binaryFormat, const void *binary, GLint length);
351 /*------------------------------------------------------------------------*
352 * AMD extension functions
353 *------------------------------------------------------------------------*/
355 /* GL_AMD_compressed_3DC_texture */
356 #ifndef GL_AMD_compressed_3DC_texture
357 #define GL_AMD_compressed_3DC_texture 1
360 /* GL_AMD_compressed_ATC_texture */
361 #ifndef GL_AMD_compressed_ATC_texture
362 #define GL_AMD_compressed_ATC_texture 1
365 /* GL_AMD_program_binary_Z400 */
366 #ifndef GL_AMD_program_binary_Z400
367 #define GL_AMD_program_binary_Z400 1
370 /*------------------------------------------------------------------------*
371 * EXT extension functions
372 *------------------------------------------------------------------------*/
374 /* GL_EXT_texture_filter_anisotropic */
375 #ifndef GL_EXT_texture_filter_anisotropic
376 #define GL_EXT_texture_filter_anisotropic 1
379 /* GL_EXT_texture_type_2_10_10_10_REV */
380 #ifndef GL_EXT_texture_type_2_10_10_10_REV
381 #define GL_EXT_texture_type_2_10_10_10_REV 1
388 #endif /* __gl2ext_h_ */