1 #ifndef __gl2ext_h_ 2 #define __gl2ext_h_ 3 4 /* $Revision: 10969 $ on $Date:: 2010-04-09 02:27:15 -0700 #$ */ 5 6 #ifdef __cplusplus 7 extern "C" { 8 #endif 9 10 /* 11 * This document is licensed under the SGI Free Software B License Version 12 * 2.0. For details, see http://oss.sgi.com/projects/FreeB/ . 13 */ 14 15 #ifndef GL_APIENTRYP 16 # define GL_APIENTRYP GL_APIENTRY* 17 #endif 18 19 /*------------------------------------------------------------------------* 20 * OES extension tokens 21 *------------------------------------------------------------------------*/ 22 23 /* GL_OES_compressed_ETC1_RGB8_texture */ 24 #ifndef GL_OES_compressed_ETC1_RGB8_texture 25 #define GL_ETC1_RGB8_OES 0x8D64 26 #endif 27 28 /* GL_OES_compressed_paletted_texture */ 29 #ifndef GL_OES_compressed_paletted_texture 30 #define GL_PALETTE4_RGB8_OES 0x8B90 31 #define GL_PALETTE4_RGBA8_OES 0x8B91 32 #define GL_PALETTE4_R5_G6_B5_OES 0x8B92 33 #define GL_PALETTE4_RGBA4_OES 0x8B93 34 #define GL_PALETTE4_RGB5_A1_OES 0x8B94 35 #define GL_PALETTE8_RGB8_OES 0x8B95 36 #define GL_PALETTE8_RGBA8_OES 0x8B96 37 #define GL_PALETTE8_R5_G6_B5_OES 0x8B97 38 #define GL_PALETTE8_RGBA4_OES 0x8B98 39 #define GL_PALETTE8_RGB5_A1_OES 0x8B99 40 #endif 41 42 /* GL_OES_depth24 */ 43 #ifndef GL_OES_depth24 44 #define GL_DEPTH_COMPONENT24_OES 0x81A6 45 #endif 46 47 /* GL_OES_depth32 */ 48 #ifndef GL_OES_depth32 49 #define GL_DEPTH_COMPONENT32_OES 0x81A7 50 #endif 51 52 /* GL_OES_depth_texture */ 53 /* No new tokens introduced by this extension. */ 54 55 /* GL_OES_EGL_image */ 56 #ifndef GL_OES_EGL_image 57 typedef void* GLeglImageOES; 58 #endif 59 60 /* GL_OES_element_index_uint */ 61 #ifndef GL_OES_element_index_uint 62 #define GL_UNSIGNED_INT 0x1405 63 #endif 64 65 /* GL_OES_get_program_binary */ 66 #ifndef GL_OES_get_program_binary 67 #define GL_PROGRAM_BINARY_LENGTH_OES 0x8741 68 #define GL_NUM_PROGRAM_BINARY_FORMATS_OES 0x87FE 69 #define GL_PROGRAM_BINARY_FORMATS_OES 0x87FF 70 #endif 71 72 /* GL_OES_mapbuffer */ 73 #ifndef GL_OES_mapbuffer 74 #define GL_WRITE_ONLY_OES 0x88B9 75 #define GL_BUFFER_ACCESS_OES 0x88BB 76 #define GL_BUFFER_MAPPED_OES 0x88BC 77 #define GL_BUFFER_MAP_POINTER_OES 0x88BD 78 #endif 79 80 /* GL_OES_packed_depth_stencil */ 81 #ifndef GL_OES_packed_depth_stencil 82 #define GL_DEPTH_STENCIL_OES 0x84F9 83 #define GL_UNSIGNED_INT_24_8_OES 0x84FA 84 #define GL_DEPTH24_STENCIL8_OES 0x88F0 85 #endif 86 87 /* GL_OES_rgb8_rgba8 */ 88 #ifndef GL_OES_rgb8_rgba8 89 #define GL_RGB8_OES 0x8051 90 #define GL_RGBA8_OES 0x8058 91 #endif 92 93 /* GL_OES_standard_derivatives */ 94 #ifndef GL_OES_standard_derivatives 95 #define GL_FRAGMENT_SHADER_DERIVATIVE_HINT_OES 0x8B8B 96 #endif 97 98 /* GL_OES_stencil1 */ 99 #ifndef GL_OES_stencil1 100 #define GL_STENCIL_INDEX1_OES 0x8D46 101 #endif 102 103 /* GL_OES_stencil4 */ 104 #ifndef GL_OES_stencil4 105 #define GL_STENCIL_INDEX4_OES 0x8D47 106 #endif 107 108 /* GL_OES_texture_3D */ 109 #ifndef GL_OES_texture_3D 110 #define GL_TEXTURE_WRAP_R_OES 0x8072 111 #define GL_TEXTURE_3D_OES 0x806F 112 #define GL_TEXTURE_BINDING_3D_OES 0x806A 113 #define GL_MAX_3D_TEXTURE_SIZE_OES 0x8073 114 #define GL_SAMPLER_3D_OES 0x8B5F 115 #define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_3D_ZOFFSET_OES 0x8CD4 116 #endif 117 118 /* GL_OES_texture_float */ 119 /* No new tokens introduced by this extension. */ 120 121 /* GL_OES_texture_float_linear */ 122 /* No new tokens introduced by this extension. */ 123 124 /* GL_OES_texture_half_float */ 125 #ifndef GL_OES_texture_half_float 126 #define GL_HALF_FLOAT_OES 0x8D61 127 #endif 128 129 /* GL_OES_texture_half_float_linear */ 130 /* No new tokens introduced by this extension. */ 131 132 /* GL_OES_texture_npot */ 133 /* No new tokens introduced by this extension. */ 134 135 /* GL_OES_vertex_array_object */ 136 #ifndef GL_OES_vertex_array_object 137 #define GL_VERTEX_ARRAY_BINDING_OES 0x85B5 138 #endif 139 140 /* GL_OES_vertex_half_float */ 141 /* GL_HALF_FLOAT_OES defined in GL_OES_texture_half_float already. */ 142 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 147 #endif 148 149 /* GL_OES_EGL_image_external */ 150 #ifndef GL_OES_EGL_image_external 151 #define GL_TEXTURE_EXTERNAL_OES 0x8D65 152 #define GL_SAMPLER_EXTERNAL_OES 0x8D66 153 #define GL_TEXTURE_BINDING_EXTERNAL_OES 0x8D67 154 #define GL_REQUIRED_TEXTURE_IMAGE_UNITS_OES 0x8D68 155 #endif 156 157 /*------------------------------------------------------------------------* 158 * AMD extension tokens 159 *------------------------------------------------------------------------*/ 160 161 /* GL_AMD_compressed_3DC_texture */ 162 #ifndef GL_AMD_compressed_3DC_texture 163 #define GL_3DC_X_AMD 0x87F9 164 #define GL_3DC_XY_AMD 0x87FA 165 #endif 166 167 /* GL_AMD_compressed_ATC_texture */ 168 #ifndef GL_AMD_compressed_ATC_texture 169 #define GL_ATC_RGB_AMD 0x8C92 170 #define GL_ATC_RGBA_EXPLICIT_ALPHA_AMD 0x8C93 171 #define GL_ATC_RGBA_INTERPOLATED_ALPHA_AMD 0x87EE 172 #endif 173 174 /* GL_AMD_performance_monitor */ 175 #ifndef GL_AMD_performance_monitor 176 #define GL_COUNTER_TYPE_AMD 0x8BC0 177 #define GL_COUNTER_RANGE_AMD 0x8BC1 178 #define GL_UNSIGNED_INT64_AMD 0x8BC2 179 #define GL_PERCENTAGE_AMD 0x8BC3 180 #define GL_PERFMON_RESULT_AVAILABLE_AMD 0x8BC4 181 #define GL_PERFMON_RESULT_SIZE_AMD 0x8BC5 182 #define GL_PERFMON_RESULT_AMD 0x8BC6 183 #endif 184 185 /* GL_AMD_program_binary_Z400 */ 186 #ifndef GL_AMD_program_binary_Z400 187 #define GL_Z400_BINARY_AMD 0x8740 188 #endif 189 190 /*------------------------------------------------------------------------* 191 * EXT extension tokens 192 *------------------------------------------------------------------------*/ 193 194 /* GL_EXT_blend_minmax */ 195 #ifndef GL_EXT_blend_minmax 196 #define GL_MIN_EXT 0x8007 197 #define GL_MAX_EXT 0x8008 198 #endif 199 200 /* GL_EXT_discard_framebuffer */ 201 #ifndef GL_EXT_discard_framebuffer 202 #define GL_COLOR_EXT 0x1800 203 #define GL_DEPTH_EXT 0x1801 204 #define GL_STENCIL_EXT 0x1802 205 #endif 206 207 /* GL_EXT_multi_draw_arrays */ 208 /* No new tokens introduced by this extension. */ 209 210 /* GL_EXT_read_format_bgra */ 211 #ifndef GL_EXT_read_format_bgra 212 #define GL_BGRA_EXT 0x80E1 213 #define GL_UNSIGNED_SHORT_4_4_4_4_REV_EXT 0x8365 214 #define GL_UNSIGNED_SHORT_1_5_5_5_REV_EXT 0x8366 215 #endif 216 217 /* GL_EXT_texture_filter_anisotropic */ 218 #ifndef GL_EXT_texture_filter_anisotropic 219 #define GL_TEXTURE_MAX_ANISOTROPY_EXT 0x84FE 220 #define GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT 0x84FF 221 #endif 222 223 /* GL_EXT_texture_format_BGRA8888 */ 224 #ifndef GL_EXT_texture_format_BGRA8888 225 #define GL_BGRA_EXT 0x80E1 226 #endif 227 228 /* GL_EXT_texture_type_2_10_10_10_REV */ 229 #ifndef GL_EXT_texture_type_2_10_10_10_REV 230 #define GL_UNSIGNED_INT_2_10_10_10_REV_EXT 0x8368 231 #endif 232 233 /* GL_EXT_texture_compression_dxt1 */ 234 #ifndef GL_EXT_texture_compression_dxt1 235 #define GL_COMPRESSED_RGB_S3TC_DXT1_EXT 0x83F0 236 #define GL_COMPRESSED_RGBA_S3TC_DXT1_EXT 0x83F1 237 #endif 238 239 /*------------------------------------------------------------------------* 240 * IMG extension tokens 241 *------------------------------------------------------------------------*/ 242 243 /* GL_IMG_program_binary */ 244 #ifndef GL_IMG_program_binary 245 #define GL_SGX_PROGRAM_BINARY_IMG 0x9130 246 #endif 247 248 /* GL_IMG_read_format */ 249 #ifndef GL_IMG_read_format 250 #define GL_BGRA_IMG 0x80E1 251 #define GL_UNSIGNED_SHORT_4_4_4_4_REV_IMG 0x8365 252 #endif 253 254 /* GL_IMG_shader_binary */ 255 #ifndef GL_IMG_shader_binary 256 #define GL_SGX_BINARY_IMG 0x8C0A 257 #endif 258 259 /* GL_IMG_texture_compression_pvrtc */ 260 #ifndef GL_IMG_texture_compression_pvrtc 261 #define GL_COMPRESSED_RGB_PVRTC_4BPPV1_IMG 0x8C00 262 #define GL_COMPRESSED_RGB_PVRTC_2BPPV1_IMG 0x8C01 263 #define GL_COMPRESSED_RGBA_PVRTC_4BPPV1_IMG 0x8C02 264 #define GL_COMPRESSED_RGBA_PVRTC_2BPPV1_IMG 0x8C03 265 #endif 266 267 /* GL_IMG_multisampled_render_to_texture */ 268 #ifndef GL_IMG_multisampled_render_to_texture 269 #define GL_RENDERBUFFER_SAMPLES_IMG 0x9133 270 #define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_IMG 0x9134 271 #define GL_MAX_SAMPLES_IMG 0x9135 272 #define GL_TEXTURE_SAMPLES_IMG 0x9136 273 #endif 274 275 /*------------------------------------------------------------------------* 276 * NV extension tokens 277 *------------------------------------------------------------------------*/ 278 279 /* GL_NV_fence */ 280 #ifndef GL_NV_fence 281 #define GL_ALL_COMPLETED_NV 0x84F2 282 #define GL_FENCE_STATUS_NV 0x84F3 283 #define GL_FENCE_CONDITION_NV 0x84F4 284 #endif 285 286 /* GL_NV_coverage_sample */ 287 #ifndef GL_NV_coverage_sample 288 #define GL_COVERAGE_COMPONENT_NV 0x8ED0 289 #define GL_COVERAGE_COMPONENT4_NV 0x8ED1 290 #define GL_COVERAGE_ATTACHMENT_NV 0x8ED2 291 #define GL_COVERAGE_BUFFERS_NV 0x8ED3 292 #define GL_COVERAGE_SAMPLES_NV 0x8ED4 293 #define GL_COVERAGE_ALL_FRAGMENTS_NV 0x8ED5 294 #define GL_COVERAGE_EDGE_FRAGMENTS_NV 0x8ED6 295 #define GL_COVERAGE_AUTOMATIC_NV 0x8ED7 296 #define GL_COVERAGE_BUFFER_BIT_NV 0x8000 297 #endif 298 299 /* GL_NV_depth_nonlinear */ 300 #ifndef GL_NV_depth_nonlinear 301 #define GL_DEPTH_COMPONENT16_NONLINEAR_NV 0x8E2C 302 #endif 303 304 /*------------------------------------------------------------------------* 305 * QCOM extension tokens 306 *------------------------------------------------------------------------*/ 307 308 /* GL_QCOM_driver_control */ 309 /* No new tokens introduced by this extension. */ 310 311 /* GL_QCOM_extended_get */ 312 #ifndef GL_QCOM_extended_get 313 #define GL_TEXTURE_WIDTH_QCOM 0x8BD2 314 #define GL_TEXTURE_HEIGHT_QCOM 0x8BD3 315 #define GL_TEXTURE_DEPTH_QCOM 0x8BD4 316 #define GL_TEXTURE_INTERNAL_FORMAT_QCOM 0x8BD5 317 #define GL_TEXTURE_FORMAT_QCOM 0x8BD6 318 #define GL_TEXTURE_TYPE_QCOM 0x8BD7 319 #define GL_TEXTURE_IMAGE_VALID_QCOM 0x8BD8 320 #define GL_TEXTURE_NUM_LEVELS_QCOM 0x8BD9 321 #define GL_TEXTURE_TARGET_QCOM 0x8BDA 322 #define GL_TEXTURE_OBJECT_VALID_QCOM 0x8BDB 323 #define GL_STATE_RESTORE 0x8BDC 324 #endif 325 326 /* GL_QCOM_extended_get2 */ 327 /* No new tokens introduced by this extension. */ 328 329 /* GL_QCOM_perfmon_global_mode */ 330 #ifndef GL_QCOM_perfmon_global_mode 331 #define GL_PERFMON_GLOBAL_MODE_QCOM 0x8FA0 332 #endif 333 334 /* GL_QCOM_writeonly_rendering */ 335 #ifndef GL_QCOM_writeonly_rendering 336 #define GL_WRITEONLY_RENDERING_QCOM 0x8823 337 #endif 338 339 /* GL_QCOM_tiled_rendering */ 340 #ifndef GL_QCOM_tiled_rendering 341 #define GL_COLOR_BUFFER_BIT0_QCOM 0x00000001 342 #define GL_COLOR_BUFFER_BIT1_QCOM 0x00000002 343 #define GL_COLOR_BUFFER_BIT2_QCOM 0x00000004 344 #define GL_COLOR_BUFFER_BIT3_QCOM 0x00000008 345 #define GL_COLOR_BUFFER_BIT4_QCOM 0x00000010 346 #define GL_COLOR_BUFFER_BIT5_QCOM 0x00000020 347 #define GL_COLOR_BUFFER_BIT6_QCOM 0x00000040 348 #define GL_COLOR_BUFFER_BIT7_QCOM 0x00000080 349 #define GL_DEPTH_BUFFER_BIT0_QCOM 0x00000100 350 #define GL_DEPTH_BUFFER_BIT1_QCOM 0x00000200 351 #define GL_DEPTH_BUFFER_BIT2_QCOM 0x00000400 352 #define GL_DEPTH_BUFFER_BIT3_QCOM 0x00000800 353 #define GL_DEPTH_BUFFER_BIT4_QCOM 0x00001000 354 #define GL_DEPTH_BUFFER_BIT5_QCOM 0x00002000 355 #define GL_DEPTH_BUFFER_BIT6_QCOM 0x00004000 356 #define GL_DEPTH_BUFFER_BIT7_QCOM 0x00008000 357 #define GL_STENCIL_BUFFER_BIT0_QCOM 0x00010000 358 #define GL_STENCIL_BUFFER_BIT1_QCOM 0x00020000 359 #define GL_STENCIL_BUFFER_BIT2_QCOM 0x00040000 360 #define GL_STENCIL_BUFFER_BIT3_QCOM 0x00080000 361 #define GL_STENCIL_BUFFER_BIT4_QCOM 0x00100000 362 #define GL_STENCIL_BUFFER_BIT5_QCOM 0x00200000 363 #define GL_STENCIL_BUFFER_BIT6_QCOM 0x00400000 364 #define GL_STENCIL_BUFFER_BIT7_QCOM 0x00800000 365 #define GL_MULTISAMPLE_BUFFER_BIT0_QCOM 0x01000000 366 #define GL_MULTISAMPLE_BUFFER_BIT1_QCOM 0x02000000 367 #define GL_MULTISAMPLE_BUFFER_BIT2_QCOM 0x04000000 368 #define GL_MULTISAMPLE_BUFFER_BIT3_QCOM 0x08000000 369 #define GL_MULTISAMPLE_BUFFER_BIT4_QCOM 0x10000000 370 #define GL_MULTISAMPLE_BUFFER_BIT5_QCOM 0x20000000 371 #define GL_MULTISAMPLE_BUFFER_BIT6_QCOM 0x40000000 372 #define GL_MULTISAMPLE_BUFFER_BIT7_QCOM 0x80000000 373 #endif 374 375 /*------------------------------------------------------------------------* 376 * End of extension tokens, start of corresponding extension functions 377 *------------------------------------------------------------------------*/ 378 379 /*------------------------------------------------------------------------* 380 * OES extension functions 381 *------------------------------------------------------------------------*/ 382 383 /* GL_OES_compressed_ETC1_RGB8_texture */ 384 #ifndef GL_OES_compressed_ETC1_RGB8_texture 385 #define GL_OES_compressed_ETC1_RGB8_texture 1 386 #endif 387 388 /* GL_OES_compressed_paletted_texture */ 389 #ifndef GL_OES_compressed_paletted_texture 390 #define GL_OES_compressed_paletted_texture 1 391 #endif 392 393 /* GL_OES_depth24 */ 394 #ifndef GL_OES_depth24 395 #define GL_OES_depth24 1 396 #endif 397 398 /* GL_OES_depth32 */ 399 #ifndef GL_OES_depth32 400 #define GL_OES_depth32 1 401 #endif 402 403 /* GL_OES_depth_texture */ 404 #ifndef GL_OES_depth_texture 405 #define GL_OES_depth_texture 1 406 #endif 407 408 /* GL_OES_EGL_image */ 409 #ifndef GL_OES_EGL_image 410 #define GL_OES_EGL_image 1 411 #ifdef GL_GLEXT_PROTOTYPES 412 GL_APICALL void GL_APIENTRY glEGLImageTargetTexture2DOES (GLenum target, GLeglImageOES image); 413 GL_APICALL void GL_APIENTRY glEGLImageTargetRenderbufferStorageOES (GLenum target, GLeglImageOES image); 414 #endif 415 typedef void (GL_APIENTRYP PFNGLEGLIMAGETARGETTEXTURE2DOESPROC) (GLenum target, GLeglImageOES image); 416 typedef void (GL_APIENTRYP PFNGLEGLIMAGETARGETRENDERBUFFERSTORAGEOESPROC) (GLenum target, GLeglImageOES image); 417 #endif 418 419 /* GL_OES_element_index_uint */ 420 #ifndef GL_OES_element_index_uint 421 #define GL_OES_element_index_uint 1 422 #endif 423 424 /* GL_OES_fbo_render_mipmap */ 425 #ifndef GL_OES_fbo_render_mipmap 426 #define GL_OES_fbo_render_mipmap 1 427 #endif 428 429 /* GL_OES_fragment_precision_high */ 430 #ifndef GL_OES_fragment_precision_high 431 #define GL_OES_fragment_precision_high 1 432 #endif 433 434 /* GL_OES_get_program_binary */ 435 #ifndef GL_OES_get_program_binary 436 #define GL_OES_get_program_binary 1 437 #ifdef GL_GLEXT_PROTOTYPES 438 GL_APICALL void GL_APIENTRY glGetProgramBinaryOES (GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary); 439 GL_APICALL void GL_APIENTRY glProgramBinaryOES (GLuint program, GLenum binaryFormat, const GLvoid *binary, GLint length); 440 #endif 441 typedef void (GL_APIENTRYP PFNGLGETPROGRAMBINARYOESPROC) (GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary); 442 typedef void (GL_APIENTRYP PFNGLPROGRAMBINARYOESPROC) (GLuint program, GLenum binaryFormat, const GLvoid *binary, GLint length); 443 #endif 444 445 /* GL_OES_mapbuffer */ 446 #ifndef GL_OES_mapbuffer 447 #define GL_OES_mapbuffer 1 448 #ifdef GL_GLEXT_PROTOTYPES 449 GL_APICALL void* GL_APIENTRY glMapBufferOES (GLenum target, GLenum access); 450 GL_APICALL GLboolean GL_APIENTRY glUnmapBufferOES (GLenum target); 451 GL_APICALL void GL_APIENTRY glGetBufferPointervOES (GLenum target, GLenum pname, GLvoid** params); 452 #endif 453 typedef void* (GL_APIENTRYP PFNGLMAPBUFFEROESPROC) (GLenum target, GLenum access); 454 typedef GLboolean (GL_APIENTRYP PFNGLUNMAPBUFFEROESPROC) (GLenum target); 455 typedef void (GL_APIENTRYP PFNGLGETBUFFERPOINTERVOESPROC) (GLenum target, GLenum pname, GLvoid** params); 456 #endif 457 458 /* GL_OES_packed_depth_stencil */ 459 #ifndef GL_OES_packed_depth_stencil 460 #define GL_OES_packed_depth_stencil 1 461 #endif 462 463 /* GL_OES_rgb8_rgba8 */ 464 #ifndef GL_OES_rgb8_rgba8 465 #define GL_OES_rgb8_rgba8 1 466 #endif 467 468 /* GL_OES_standard_derivatives */ 469 #ifndef GL_OES_standard_derivatives 470 #define GL_OES_standard_derivatives 1 471 #endif 472 473 /* GL_OES_stencil1 */ 474 #ifndef GL_OES_stencil1 475 #define GL_OES_stencil1 1 476 #endif 477 478 /* GL_OES_stencil4 */ 479 #ifndef GL_OES_stencil4 480 #define GL_OES_stencil4 1 481 #endif 482 483 /* GL_OES_texture_3D */ 484 #ifndef GL_OES_texture_3D 485 #define GL_OES_texture_3D 1 486 #ifdef GL_GLEXT_PROTOTYPES 487 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 GLvoid* pixels); 488 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 GLvoid* pixels); 489 GL_APICALL void GL_APIENTRY glCopyTexSubImage3DOES (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height); 490 GL_APICALL void GL_APIENTRY glCompressedTexImage3DOES (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data); 491 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 GLvoid* data); 492 GL_APICALL void GL_APIENTRY glFramebufferTexture3DOES (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset); 493 #endif 494 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); 495 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 GLvoid* pixels); 496 typedef void (GL_APIENTRYP PFNGLCOPYTEXSUBIMAGE3DOESPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height); 497 typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXIMAGE3DOESPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data); 498 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 GLvoid* data); 499 typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTURE3DOES) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset); 500 #endif 501 502 /* GL_OES_texture_float */ 503 #ifndef GL_OES_texture_float 504 #define GL_OES_texture_float 1 505 #endif 506 507 /* GL_OES_texture_float_linear */ 508 #ifndef GL_OES_texture_float_linear 509 #define GL_OES_texture_float_linear 1 510 #endif 511 512 /* GL_OES_texture_half_float */ 513 #ifndef GL_OES_texture_half_float 514 #define GL_OES_texture_half_float 1 515 #endif 516 517 /* GL_OES_texture_half_float_linear */ 518 #ifndef GL_OES_texture_half_float_linear 519 #define GL_OES_texture_half_float_linear 1 520 #endif 521 522 /* GL_OES_texture_npot */ 523 #ifndef GL_OES_texture_npot 524 #define GL_OES_texture_npot 1 525 #endif 526 527 /* GL_OES_vertex_array_object */ 528 #ifndef GL_OES_vertex_array_object 529 #define GL_OES_vertex_array_object 1 530 #ifdef GL_GLEXT_PROTOTYPES 531 GL_APICALL void GL_APIENTRY glBindVertexArrayOES (GLuint array); 532 GL_APICALL void GL_APIENTRY glDeleteVertexArraysOES (GLsizei n, const GLuint *arrays); 533 GL_APICALL void GL_APIENTRY glGenVertexArraysOES (GLsizei n, GLuint *arrays); 534 GL_APICALL GLboolean GL_APIENTRY glIsVertexArrayOES (GLuint array); 535 #endif 536 typedef void (GL_APIENTRYP PFNGLBINDVERTEXARRAYOESPROC) (GLuint array); 537 typedef void (GL_APIENTRYP PFNGLDELETEVERTEXARRAYSOESPROC) (GLsizei n, const GLuint *arrays); 538 typedef void (GL_APIENTRYP PFNGLGENVERTEXARRAYSOESPROC) (GLsizei n, GLuint *arrays); 539 typedef GLboolean (GL_APIENTRYP PFNGLISVERTEXARRAYOESPROC) (GLuint array); 540 #endif 541 542 /* GL_OES_vertex_half_float */ 543 #ifndef GL_OES_vertex_half_float 544 #define GL_OES_vertex_half_float 1 545 #endif 546 547 /* GL_OES_vertex_type_10_10_10_2 */ 548 #ifndef GL_OES_vertex_type_10_10_10_2 549 #define GL_OES_vertex_type_10_10_10_2 1 550 #endif 551 552 /* GL_OES_EGL_image_external */ 553 #ifndef GL_OES_EGL_image_external 554 #define GL_OES_EGL_image_external 1 555 #endif 556 557 /*------------------------------------------------------------------------* 558 * AMD extension functions 559 *------------------------------------------------------------------------*/ 560 561 /* GL_AMD_compressed_3DC_texture */ 562 #ifndef GL_AMD_compressed_3DC_texture 563 #define GL_AMD_compressed_3DC_texture 1 564 #endif 565 566 /* GL_AMD_compressed_ATC_texture */ 567 #ifndef GL_AMD_compressed_ATC_texture 568 #define GL_AMD_compressed_ATC_texture 1 569 #endif 570 571 /* AMD_performance_monitor */ 572 #ifndef GL_AMD_performance_monitor 573 #define GL_AMD_performance_monitor 1 574 #ifdef GL_GLEXT_PROTOTYPES 575 GL_APICALL void GL_APIENTRY glGetPerfMonitorGroupsAMD (GLint *numGroups, GLsizei groupsSize, GLuint *groups); 576 GL_APICALL void GL_APIENTRY glGetPerfMonitorCountersAMD (GLuint group, GLint *numCounters, GLint *maxActiveCounters, GLsizei counterSize, GLuint *counters); 577 GL_APICALL void GL_APIENTRY glGetPerfMonitorGroupStringAMD (GLuint group, GLsizei bufSize, GLsizei *length, GLchar *groupString); 578 GL_APICALL void GL_APIENTRY glGetPerfMonitorCounterStringAMD (GLuint group, GLuint counter, GLsizei bufSize, GLsizei *length, GLchar *counterString); 579 GL_APICALL void GL_APIENTRY glGetPerfMonitorCounterInfoAMD (GLuint group, GLuint counter, GLenum pname, GLvoid *data); 580 GL_APICALL void GL_APIENTRY glGenPerfMonitorsAMD (GLsizei n, GLuint *monitors); 581 GL_APICALL void GL_APIENTRY glDeletePerfMonitorsAMD (GLsizei n, GLuint *monitors); 582 GL_APICALL void GL_APIENTRY glSelectPerfMonitorCountersAMD (GLuint monitor, GLboolean enable, GLuint group, GLint numCounters, GLuint *countersList); 583 GL_APICALL void GL_APIENTRY glBeginPerfMonitorAMD (GLuint monitor); 584 GL_APICALL void GL_APIENTRY glEndPerfMonitorAMD (GLuint monitor); 585 GL_APICALL void GL_APIENTRY glGetPerfMonitorCounterDataAMD (GLuint monitor, GLenum pname, GLsizei dataSize, GLuint *data, GLint *bytesWritten); 586 #endif 587 typedef void (GL_APIENTRYP PFNGLGETPERFMONITORGROUPSAMDPROC) (GLint *numGroups, GLsizei groupsSize, GLuint *groups); 588 typedef void (GL_APIENTRYP PFNGLGETPERFMONITORCOUNTERSAMDPROC) (GLuint group, GLint *numCounters, GLint *maxActiveCounters, GLsizei counterSize, GLuint *counters); 589 typedef void (GL_APIENTRYP PFNGLGETPERFMONITORGROUPSTRINGAMDPROC) (GLuint group, GLsizei bufSize, GLsizei *length, GLchar *groupString); 590 typedef void (GL_APIENTRYP PFNGLGETPERFMONITORCOUNTERSTRINGAMDPROC) (GLuint group, GLuint counter, GLsizei bufSize, GLsizei *length, GLchar *counterString); 591 typedef void (GL_APIENTRYP PFNGLGETPERFMONITORCOUNTERINFOAMDPROC) (GLuint group, GLuint counter, GLenum pname, GLvoid *data); 592 typedef void (GL_APIENTRYP PFNGLGENPERFMONITORSAMDPROC) (GLsizei n, GLuint *monitors); 593 typedef void (GL_APIENTRYP PFNGLDELETEPERFMONITORSAMDPROC) (GLsizei n, GLuint *monitors); 594 typedef void (GL_APIENTRYP PFNGLSELECTPERFMONITORCOUNTERSAMDPROC) (GLuint monitor, GLboolean enable, GLuint group, GLint numCounters, GLuint *countersList); 595 typedef void (GL_APIENTRYP PFNGLBEGINPERFMONITORAMDPROC) (GLuint monitor); 596 typedef void (GL_APIENTRYP PFNGLENDPERFMONITORAMDPROC) (GLuint monitor); 597 typedef void (GL_APIENTRYP PFNGLGETPERFMONITORCOUNTERDATAAMDPROC) (GLuint monitor, GLenum pname, GLsizei dataSize, GLuint *data, GLint *bytesWritten); 598 #endif 599 600 /* GL_AMD_program_binary_Z400 */ 601 #ifndef GL_AMD_program_binary_Z400 602 #define GL_AMD_program_binary_Z400 1 603 #endif 604 605 /*------------------------------------------------------------------------* 606 * EXT extension functions 607 *------------------------------------------------------------------------*/ 608 609 /* GL_EXT_blend_minmax */ 610 #ifndef GL_EXT_blend_minmax 611 #define GL_EXT_blend_minmax 1 612 #endif 613 614 /* GL_EXT_discard_framebuffer */ 615 #ifndef GL_EXT_discard_framebuffer 616 #define GL_EXT_discard_framebuffer 1 617 #ifdef GL_GLEXT_PROTOTYPES 618 GL_APICALL void GL_APIENTRY glDiscardFramebufferEXT (GLenum target, GLsizei numAttachments, const GLenum *attachments); 619 #endif 620 typedef void (GL_APIENTRYP PFNGLDISCARDFRAMEBUFFEREXTPROC) (GLenum target, GLsizei numAttachments, const GLenum *attachments); 621 #endif 622 623 #ifndef GL_EXT_multi_draw_arrays 624 #define GL_EXT_multi_draw_arrays 1 625 #ifdef GL_GLEXT_PROTOTYPES 626 GL_APICALL void GL_APIENTRY glMultiDrawArraysEXT (GLenum mode, GLint *first, GLsizei *count, GLsizei primcount); 627 GL_APICALL void GL_APIENTRY glMultiDrawElementsEXT (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount); 628 #endif /* GL_GLEXT_PROTOTYPES */ 629 typedef void (GL_APIENTRYP PFNGLMULTIDRAWARRAYSEXTPROC) (GLenum mode, GLint *first, GLsizei *count, GLsizei primcount); 630 typedef void (GL_APIENTRYP PFNGLMULTIDRAWELEMENTSEXTPROC) (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount); 631 #endif 632 633 /* GL_EXT_read_format_bgra */ 634 #ifndef GL_EXT_read_format_bgra 635 #define GL_EXT_read_format_bgra 1 636 #endif 637 638 /* GL_EXT_texture_filter_anisotropic */ 639 #ifndef GL_EXT_texture_filter_anisotropic 640 #define GL_EXT_texture_filter_anisotropic 1 641 #endif 642 643 /* GL_EXT_texture_format_BGRA8888 */ 644 #ifndef GL_EXT_texture_format_BGRA8888 645 #define GL_EXT_texture_format_BGRA8888 1 646 #endif 647 648 /* GL_EXT_texture_type_2_10_10_10_REV */ 649 #ifndef GL_EXT_texture_type_2_10_10_10_REV 650 #define GL_EXT_texture_type_2_10_10_10_REV 1 651 #endif 652 653 /* GL_EXT_texture_compression_dxt1 */ 654 #ifndef GL_EXT_texture_compression_dxt1 655 #define GL_EXT_texture_compression_dxt1 1 656 #endif 657 658 /*------------------------------------------------------------------------* 659 * IMG extension functions 660 *------------------------------------------------------------------------*/ 661 662 /* GL_IMG_program_binary */ 663 #ifndef GL_IMG_program_binary 664 #define GL_IMG_program_binary 1 665 #endif 666 667 /* GL_IMG_read_format */ 668 #ifndef GL_IMG_read_format 669 #define GL_IMG_read_format 1 670 #endif 671 672 /* GL_IMG_shader_binary */ 673 #ifndef GL_IMG_shader_binary 674 #define GL_IMG_shader_binary 1 675 #endif 676 677 /* GL_IMG_texture_compression_pvrtc */ 678 #ifndef GL_IMG_texture_compression_pvrtc 679 #define GL_IMG_texture_compression_pvrtc 1 680 #endif 681 682 /* GL_IMG_multisampled_render_to_texture */ 683 #ifndef GL_IMG_multisampled_render_to_texture 684 #define GL_IMG_multisampled_render_to_texture 1 685 #ifdef GL_GLEXT_PROTOTYPES 686 GL_APICALL void GL_APIENTRY glRenderbufferStorageMultisampleIMG (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); 687 GL_APICALL void GL_APIENTRY glFramebufferTexture2DMultisampleIMG (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples); 688 #endif 689 typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEIMG) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); 690 typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTURE2DMULTISAMPLEIMG) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples); 691 #endif 692 693 /*------------------------------------------------------------------------* 694 * NV extension functions 695 *------------------------------------------------------------------------*/ 696 697 /* GL_NV_fence */ 698 #ifndef GL_NV_fence 699 #define GL_NV_fence 1 700 #ifdef GL_GLEXT_PROTOTYPES 701 GL_APICALL void GL_APIENTRY glDeleteFencesNV (GLsizei n, const GLuint *fences); 702 GL_APICALL void GL_APIENTRY glGenFencesNV (GLsizei n, GLuint *fences); 703 GL_APICALL GLboolean GL_APIENTRY glIsFenceNV (GLuint fence); 704 GL_APICALL GLboolean GL_APIENTRY glTestFenceNV (GLuint fence); 705 GL_APICALL void GL_APIENTRY glGetFenceivNV (GLuint fence, GLenum pname, GLint *params); 706 GL_APICALL void GL_APIENTRY glFinishFenceNV (GLuint fence); 707 GL_APICALL void GL_APIENTRY glSetFenceNV (GLuint fence, GLenum condition); 708 #endif 709 typedef void (GL_APIENTRYP PFNGLDELETEFENCESNVPROC) (GLsizei n, const GLuint *fences); 710 typedef void (GL_APIENTRYP PFNGLGENFENCESNVPROC) (GLsizei n, GLuint *fences); 711 typedef GLboolean (GL_APIENTRYP PFNGLISFENCENVPROC) (GLuint fence); 712 typedef GLboolean (GL_APIENTRYP PFNGLTESTFENCENVPROC) (GLuint fence); 713 typedef void (GL_APIENTRYP PFNGLGETFENCEIVNVPROC) (GLuint fence, GLenum pname, GLint *params); 714 typedef void (GL_APIENTRYP PFNGLFINISHFENCENVPROC) (GLuint fence); 715 typedef void (GL_APIENTRYP PFNGLSETFENCENVPROC) (GLuint fence, GLenum condition); 716 #endif 717 718 /* GL_NV_coverage_sample */ 719 #ifndef GL_NV_coverage_sample 720 #define GL_NV_coverage_sample 1 721 #ifdef GL_GLEXT_PROTOTYPES 722 GL_APICALL void GL_APIENTRY glCoverageMaskNV (GLboolean mask); 723 GL_APICALL void GL_APIENTRY glCoverageOperationNV (GLenum operation); 724 #endif 725 typedef void (GL_APIENTRYP PFNGLCOVERAGEMASKNVPROC) (GLboolean mask); 726 typedef void (GL_APIENTRYP PFNGLCOVERAGEOPERATIONNVPROC) (GLenum operation); 727 #endif 728 729 /* GL_NV_depth_nonlinear */ 730 #ifndef GL_NV_depth_nonlinear 731 #define GL_NV_depth_nonlinear 1 732 #endif 733 734 /*------------------------------------------------------------------------* 735 * QCOM extension functions 736 *------------------------------------------------------------------------*/ 737 738 /* GL_QCOM_driver_control */ 739 #ifndef GL_QCOM_driver_control 740 #define GL_QCOM_driver_control 1 741 #ifdef GL_GLEXT_PROTOTYPES 742 GL_APICALL void GL_APIENTRY glGetDriverControlsQCOM (GLint *num, GLsizei size, GLuint *driverControls); 743 GL_APICALL void GL_APIENTRY glGetDriverControlStringQCOM (GLuint driverControl, GLsizei bufSize, GLsizei *length, GLchar *driverControlString); 744 GL_APICALL void GL_APIENTRY glEnableDriverControlQCOM (GLuint driverControl); 745 GL_APICALL void GL_APIENTRY glDisableDriverControlQCOM (GLuint driverControl); 746 #endif 747 typedef void (GL_APIENTRYP PFNGLGETDRIVERCONTROLSQCOMPROC) (GLint *num, GLsizei size, GLuint *driverControls); 748 typedef void (GL_APIENTRYP PFNGLGETDRIVERCONTROLSTRINGQCOMPROC) (GLuint driverControl, GLsizei bufSize, GLsizei *length, GLchar *driverControlString); 749 typedef void (GL_APIENTRYP PFNGLENABLEDRIVERCONTROLQCOMPROC) (GLuint driverControl); 750 typedef void (GL_APIENTRYP PFNGLDISABLEDRIVERCONTROLQCOMPROC) (GLuint driverControl); 751 #endif 752 753 /* GL_QCOM_extended_get */ 754 #ifndef GL_QCOM_extended_get 755 #define GL_QCOM_extended_get 1 756 #ifdef GL_GLEXT_PROTOTYPES 757 GL_APICALL void GL_APIENTRY glExtGetTexturesQCOM (GLuint *textures, GLint maxTextures, GLint *numTextures); 758 GL_APICALL void GL_APIENTRY glExtGetBuffersQCOM (GLuint *buffers, GLint maxBuffers, GLint *numBuffers); 759 GL_APICALL void GL_APIENTRY glExtGetRenderbuffersQCOM (GLuint *renderbuffers, GLint maxRenderbuffers, GLint *numRenderbuffers); 760 GL_APICALL void GL_APIENTRY glExtGetFramebuffersQCOM (GLuint *framebuffers, GLint maxFramebuffers, GLint *numFramebuffers); 761 GL_APICALL void GL_APIENTRY glExtGetTexLevelParameterivQCOM (GLuint texture, GLenum face, GLint level, GLenum pname, GLint *params); 762 GL_APICALL void GL_APIENTRY glExtTexObjectStateOverrideiQCOM (GLenum target, GLenum pname, GLint param); 763 GL_APICALL void GL_APIENTRY glExtGetTexSubImageQCOM (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, GLvoid *texels); 764 GL_APICALL void GL_APIENTRY glExtGetBufferPointervQCOM (GLenum target, GLvoid **params); 765 #endif 766 typedef void (GL_APIENTRYP PFNGLEXTGETTEXTURESQCOMPROC) (GLuint *textures, GLint maxTextures, GLint *numTextures); 767 typedef void (GL_APIENTRYP PFNGLEXTGETBUFFERSQCOMPROC) (GLuint *buffers, GLint maxBuffers, GLint *numBuffers); 768 typedef void (GL_APIENTRYP PFNGLEXTGETRENDERBUFFERSQCOMPROC) (GLuint *renderbuffers, GLint maxRenderbuffers, GLint *numRenderbuffers); 769 typedef void (GL_APIENTRYP PFNGLEXTGETFRAMEBUFFERSQCOMPROC) (GLuint *framebuffers, GLint maxFramebuffers, GLint *numFramebuffers); 770 typedef void (GL_APIENTRYP PFNGLEXTGETTEXLEVELPARAMETERIVQCOMPROC) (GLuint texture, GLenum face, GLint level, GLenum pname, GLint *params); 771 typedef void (GL_APIENTRYP PFNGLEXTTEXOBJECTSTATEOVERRIDEIQCOMPROC) (GLenum target, GLenum pname, GLint param); 772 typedef void (GL_APIENTRYP PFNGLEXTGETTEXSUBIMAGEQCOMPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, GLvoid *texels); 773 typedef void (GL_APIENTRYP PFNGLEXTGETBUFFERPOINTERVQCOMPROC) (GLenum target, GLvoid **params); 774 #endif 775 776 /* GL_QCOM_extended_get2 */ 777 #ifndef GL_QCOM_extended_get2 778 #define GL_QCOM_extended_get2 1 779 #ifdef GL_GLEXT_PROTOTYPES 780 GL_APICALL void GL_APIENTRY glExtGetShadersQCOM (GLuint *shaders, GLint maxShaders, GLint *numShaders); 781 GL_APICALL void GL_APIENTRY glExtGetProgramsQCOM (GLuint *programs, GLint maxPrograms, GLint *numPrograms); 782 GL_APICALL GLboolean GL_APIENTRY glExtIsProgramBinaryQCOM (GLuint program); 783 GL_APICALL void GL_APIENTRY glExtGetProgramBinarySourceQCOM (GLuint program, GLenum shadertype, GLchar *source, GLint *length); 784 #endif 785 typedef void (GL_APIENTRYP PFNGLEXTGETSHADERSQCOMPROC) (GLuint *shaders, GLint maxShaders, GLint *numShaders); 786 typedef void (GL_APIENTRYP PFNGLEXTGETPROGRAMSQCOMPROC) (GLuint *programs, GLint maxPrograms, GLint *numPrograms); 787 typedef GLboolean (GL_APIENTRYP PFNGLEXTISPROGRAMBINARYQCOMPROC) (GLuint program); 788 typedef void (GL_APIENTRYP PFNGLEXTGETPROGRAMBINARYSOURCEQCOMPROC) (GLuint program, GLenum shadertype, GLchar *source, GLint *length); 789 #endif 790 791 /* GL_QCOM_perfmon_global_mode */ 792 #ifndef GL_QCOM_perfmon_global_mode 793 #define GL_QCOM_perfmon_global_mode 1 794 #endif 795 796 /* GL_QCOM_writeonly_rendering */ 797 #ifndef GL_QCOM_writeonly_rendering 798 #define GL_QCOM_writeonly_rendering 1 799 #endif 800 801 /* GL_QCOM_tiled_rendering */ 802 #ifndef GL_QCOM_tiled_rendering 803 #define GL_QCOM_tiled_rendering 1 804 #ifdef GL_GLEXT_PROTOTYPES 805 GL_APICALL void GL_APIENTRY glStartTilingQCOM (GLuint x, GLuint y, GLuint width, GLuint height, GLbitfield preserveMask); 806 GL_APICALL void GL_APIENTRY glEndTilingQCOM (GLbitfield preserveMask); 807 #endif 808 typedef void (GL_APIENTRYP PFNGLSTARTTILINGQCOMPROC) (GLuint x, GLuint y, GLuint width, GLuint height, GLbitfield preserveMask); 809 typedef void (GL_APIENTRYP PFNGLENDTILINGQCOMPROC) (GLbitfield preserveMask); 810 #endif 811 812 #ifdef __cplusplus 813 } 814 #endif 815 816 #endif /* __gl2ext_h_ */ 817