opengles/openglesinterface/include/GLES2/gl2ext.h
changeset 0 5d03bc08d59c
child 36 01a6848ebfd7
equal deleted inserted replaced
-1:000000000000 0:5d03bc08d59c
       
     1 #ifndef __gl2ext_h_
       
     2 #define __gl2ext_h_
       
     3 
       
     4 /*
       
     5  *  portions Copyright (c) 2008 - 2009 Nokia Corporation. All rights reserved.
       
     6  * Differences from the actual sample implementation provided by Khronos:
       
     7  * 1. This comment text.
       
     8  * 2. Doxygen comment with tag 'publishedAll', and tag 'released'
       
     9  */
       
    10 
       
    11 /**
       
    12 @publishedAll
       
    13 @released
       
    14 */
       
    15 
       
    16 /* $Id: gl2ext.h 4571 2007-11-28 16:33:30Z benj $ */
       
    17 
       
    18 #ifdef __cplusplus
       
    19 extern "C" {
       
    20 #endif
       
    21 
       
    22 /*
       
    23 ** SGI FREE SOFTWARE LICENSE B (Version 2.0, Sept. 18, 2008)
       
    24 ** Copyright (C) 2008 Silicon Graphics, Inc. All Rights Reserved.
       
    25 ** 
       
    26 ** Permission is hereby granted, free of charge, to any person obtaining 
       
    27 ** a copy of this software and associated documentation files 
       
    28 ** (the "Software"), to deal in the Software without restriction, 
       
    29 ** including without limitation the rights to use, copy, modify, merge, 
       
    30 ** publish, distribute, sublicense, and/or sell copies of the Software, 
       
    31 ** and to permit persons to whom the Software is furnished to do so, 
       
    32 ** subject to the following conditions:
       
    33 **  
       
    34 ** The above copyright notice including the dates of first 
       
    35 ** publication and either this permission notice or a reference to 
       
    36 ** http://oss.sgi.com/projects/FreeB/ shall be included in all copies 
       
    37 ** or substantial portions of the Software.
       
    38 ** 
       
    39 ** THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 
       
    40 ** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 
       
    41 ** MERCHANTABILITY,FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 
       
    42 ** IN NO EVENT SHALL SILICON GRAPHICS, INC. BE LIABLE FOR ANY CLAIM, 
       
    43 ** DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR 
       
    44 ** OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR 
       
    45 ** THE USE OR OTHER DEALINGS IN THE SOFTWARE.
       
    46 ** 
       
    47 ** Except as contained in this notice, the name of Silicon Graphics, Inc. 
       
    48 ** shall not be used in advertising or otherwise to promote the sale, use 
       
    49 ** or other dealings in this Software without prior written authorization 
       
    50 ** from Silicon Graphics, Inc. 
       
    51 */
       
    52 
       
    53 #ifndef GL_APIENTRYP
       
    54 #   define GL_APIENTRYP GL_APIENTRY*
       
    55 #endif
       
    56 
       
    57 /*------------------------------------------------------------------------*
       
    58  * OES extension tokens
       
    59  *------------------------------------------------------------------------*/
       
    60 
       
    61 /* GL_OES_compressed_ETC1_RGB8_texture */
       
    62 #ifndef GL_OES_compressed_ETC1_RGB8_texture
       
    63 #define GL_ETC1_RGB8_OES                                        0x8D64
       
    64 #endif
       
    65 
       
    66 /* GL_OES_compressed_paletted_texture */
       
    67 #ifndef GL_OES_compressed_paletted_texture
       
    68 #define GL_PALETTE4_RGB8_OES                                    0x8B90
       
    69 #define GL_PALETTE4_RGBA8_OES                                   0x8B91
       
    70 #define GL_PALETTE4_R5_G6_B5_OES                                0x8B92
       
    71 #define GL_PALETTE4_RGBA4_OES                                   0x8B93
       
    72 #define GL_PALETTE4_RGB5_A1_OES                                 0x8B94
       
    73 #define GL_PALETTE8_RGB8_OES                                    0x8B95
       
    74 #define GL_PALETTE8_RGBA8_OES                                   0x8B96
       
    75 #define GL_PALETTE8_R5_G6_B5_OES                                0x8B97
       
    76 #define GL_PALETTE8_RGBA4_OES                                   0x8B98
       
    77 #define GL_PALETTE8_RGB5_A1_OES                                 0x8B99
       
    78 #endif
       
    79 
       
    80 /* GL_OES_EGL_image */
       
    81 #ifndef GL_OES_EGL_image
       
    82 typedef void* GLeglImageOES;
       
    83 #endif
       
    84 
       
    85 /* GL_OES_depth24 */
       
    86 #ifndef GL_OES_depth24
       
    87 #define GL_DEPTH_COMPONENT24_OES                                0x81A6
       
    88 #endif
       
    89 
       
    90 /* GL_OES_depth32 */
       
    91 #ifndef GL_OES_depth32
       
    92 #define GL_DEPTH_COMPONENT32_OES                                0x81A7
       
    93 #endif
       
    94 
       
    95 /* GL_OES_mapbuffer */
       
    96 #ifndef GL_OES_mapbuffer
       
    97 /* GL_READ_ONLY and GL_READ_WRITE not supported */
       
    98 #define GL_WRITE_ONLY_OES                                       0x88B9
       
    99 #define GL_BUFFER_ACCESS_OES                                    0x88BB
       
   100 #define GL_BUFFER_MAPPED_OES                                    0x88BC
       
   101 #define GL_BUFFER_MAP_POINTER_OES                               0x88BD
       
   102 #endif
       
   103 
       
   104 /* GL_OES_rgb8_rgba8 */
       
   105 #ifndef GL_OES_rgb8_rgba8
       
   106 #define GL_RGB8_OES                                             0x8051
       
   107 #define GL_RGBA8_OES                                            0x8058
       
   108 #endif
       
   109 
       
   110 /* GL_OES_stencil1 */
       
   111 #ifndef GL_OES_stencil1
       
   112 #define GL_STENCIL_INDEX1_OES                                   0x8D46
       
   113 #endif
       
   114 
       
   115 /* GL_OES_stencil4 */
       
   116 #ifndef GL_OES_stencil4
       
   117 #define GL_STENCIL_INDEX4_OES                                   0x8D47
       
   118 #endif
       
   119 
       
   120 /* GL_OES_texture3D */
       
   121 #ifndef GL_OES_texture3D
       
   122 #define GL_TEXTURE_WRAP_R_OES                                   0x8072
       
   123 #define GL_TEXTURE_3D_OES                                       0x806F
       
   124 #define GL_TEXTURE_BINDING_3D_OES                               0x806A
       
   125 #define GL_MAX_3D_TEXTURE_SIZE_OES                              0x8073
       
   126 #define GL_SAMPLER_3D_OES                                       0x8B5F
       
   127 #define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_3D_ZOFFSET_OES        0x8CD4
       
   128 #endif
       
   129 
       
   130 /* GL_OES_texture_half_float */
       
   131 #ifndef GL_OES_texture_half_float
       
   132 #define GL_HALF_FLOAT_OES                                       0x8D61
       
   133 #endif
       
   134 
       
   135 /* GL_OES_vertex_half_float */
       
   136 /* GL_HALF_FLOAT_OES defined in GL_OES_texture_half_float already. */
       
   137 
       
   138 /* GL_AMD_compressed_3DC_texture */
       
   139 #ifndef GL_AMD_compressed_3DC_texture
       
   140 #define GL_3DC_X_AMD                                            0x87F9
       
   141 #define GL_3DC_XY_AMD                                           0x87FA
       
   142 #endif
       
   143 
       
   144 /* GL_AMD_compressed_ATC_texture */
       
   145 #ifndef GL_AMD_compressed_ATC_texture
       
   146 #define GL_ATC_RGB_AMD                                          0x8C92
       
   147 #define GL_ATC_RGBA_EXPLICIT_ALPHA_AMD                          0x8C93
       
   148 #define GL_ATC_RGBA_INTERPOLATED_ALPHA_AMD                      0x87EE
       
   149 #endif
       
   150 
       
   151 /* GL_EXT_texture_filter_anisotropic */
       
   152 #ifndef GL_EXT_texture_filter_anisotropic
       
   153 #define GL_TEXTURE_MAX_ANISOTROPY_EXT                           0x84FE
       
   154 #define GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT                       0x84FF
       
   155 #endif
       
   156 
       
   157 /*------------------------------------------------------------------------*
       
   158  * OES extension functions
       
   159  *------------------------------------------------------------------------*/
       
   160 
       
   161 /* GL_OES_compressed_ETC1_RGB8_texture */
       
   162 #ifndef GL_OES_compressed_ETC1_RGB8_texture
       
   163 #define GL_OES_compressed_ETC1_RGB8_texture 1
       
   164 #endif
       
   165 
       
   166 /* GL_OES_compressed_paletted_texture */
       
   167 #ifndef GL_OES_compressed_paletted_texture
       
   168 #define GL_OES_compressed_paletted_texture 1
       
   169 #endif
       
   170 
       
   171 /* GL_OES_EGL_image */
       
   172 #ifndef GL_OES_EGL_image
       
   173 #define GL_OES_EGL_image 1
       
   174 #ifdef GL_GLEXT_PROTOTYPES
       
   175 GL_APICALL void GL_APIENTRY glEGLImageTargetTexture2DOES (GLenum target, GLeglImageOES image);
       
   176 GL_APICALL void GL_APIENTRY glEGLImageTargetRenderbufferStorageOES (GLenum target, GLeglImageOES image);
       
   177 #endif
       
   178 typedef void (GL_APIENTRYP PFNGLEGLIMAGETARGETTEXTURE2DOESPROC) (GLenum target, GLeglImageOES image);
       
   179 typedef void (GL_APIENTRYP PFNGLEGLIMAGETARGETRENDERBUFFERSTORAGEOESPROC) (GLenum target, GLeglImageOES image);
       
   180 #endif
       
   181 
       
   182 /* GL_OES_depth24 */
       
   183 #ifndef GL_OES_depth24
       
   184 #define GL_OES_depth24 1
       
   185 #endif
       
   186 
       
   187 /* GL_OES_depth32 */
       
   188 #ifndef GL_OES_depth32
       
   189 #define GL_OES_depth32 1
       
   190 #endif
       
   191 
       
   192 /* GL_OES_element_index_uint */
       
   193 #ifndef GL_OES_element_index_uint
       
   194 #define GL_OES_element_index_uint 1
       
   195 #endif
       
   196 
       
   197 /* GL_OES_fbo_render_mipmap */
       
   198 #ifndef GL_OES_fbo_render_mipmap
       
   199 #define GL_OES_fbo_render_mipmap 1
       
   200 #endif
       
   201 
       
   202 /* GL_OES_fragment_precision_high */
       
   203 #ifndef GL_OES_fragment_precision_high
       
   204 #define GL_OES_fragment_precision_high 1
       
   205 #endif
       
   206 
       
   207 /* GL_OES_mapbuffer */
       
   208 #ifndef GL_OES_mapbuffer
       
   209 #define GL_OES_mapbuffer 1
       
   210 #ifdef GL_GLEXT_PROTOTYPES
       
   211 GL_APICALL void* GL_APIENTRY glMapBufferOES (GLenum target, GLenum access);
       
   212 GL_APICALL GLboolean GL_APIENTRY glUnmapBufferOES (GLenum target);
       
   213 GL_APICALL void GL_APIENTRY glGetBufferPointervOES (GLenum target, GLenum pname, void** params);
       
   214 #endif
       
   215 typedef void* (GL_APIENTRYP PFNGLMAPBUFFEROESPROC) (GLenum target, GLenum access);
       
   216 typedef GLboolean (GL_APIENTRYP PFNGLUNMAPBUFFEROESPROC) (GLenum target);
       
   217 typedef void (GL_APIENTRYP PFNGLGETBUFFERPOINTERVOESPROC) (GLenum target, GLenum pname, void** params);
       
   218 #endif
       
   219 
       
   220 /* GL_OES_rgb8_rgba8 */
       
   221 #ifndef GL_OES_rgb8_rgba8
       
   222 #define GL_OES_rgb8_rgba8 1
       
   223 #endif
       
   224 
       
   225 /* GL_OES_stencil1 */
       
   226 #ifndef GL_OES_stencil1
       
   227 #define GL_OES_stencil1 1
       
   228 #endif
       
   229 
       
   230 /* GL_OES_stencil4 */
       
   231 #ifndef GL_OES_stencil4
       
   232 #define GL_OES_stencil4 1
       
   233 #endif
       
   234 
       
   235 /* GL_OES_texture_3D */
       
   236 #ifndef GL_OES_texture_3D
       
   237 #define GL_OES_texture_3D 1
       
   238 #ifdef GL_GLEXT_PROTOTYPES
       
   239 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);
       
   240 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);
       
   241 GL_APICALL void GL_APIENTRY glCopyTexSubImage3DOES (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
       
   242 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);
       
   243 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);
       
   244 GL_APICALL void GL_APIENTRY glFramebufferTexture3DOES (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
       
   245 #endif
       
   246 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);
       
   247 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);
       
   248 typedef void (GL_APIENTRYP PFNGLCOPYTEXSUBIMAGE3DOESPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
       
   249 typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXIMAGE3DOESPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const void* data);
       
   250 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);
       
   251 typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTURE3DOES) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
       
   252 #endif
       
   253 
       
   254 /* GL_OES_texture_float_linear */
       
   255 #ifndef GL_OES_texture_float_linear
       
   256 #define GL_OES_texture_float_linear 1
       
   257 #endif
       
   258 
       
   259 /* GL_OES_texture_half_float_linear */
       
   260 #ifndef GL_OES_texture_half_float_linear
       
   261 #define GL_OES_texture_half_float_linear 1
       
   262 #endif
       
   263 
       
   264 /* GL_OES_texture_float */
       
   265 #ifndef GL_OES_texture_float
       
   266 #define GL_OES_texture_float 1
       
   267 #endif
       
   268 
       
   269 /* GL_OES_texture_half_float */
       
   270 #ifndef GL_OES_texture_half_float
       
   271 #define GL_OES_texture_half_float 1
       
   272 #endif
       
   273 
       
   274 /* GL_OES_texture_npot */
       
   275 #ifndef GL_OES_texture_npot
       
   276 #define GL_OES_texture_npot 1
       
   277 #endif
       
   278 
       
   279 /* GL_OES_vertex_half_float */
       
   280 #ifndef GL_OES_vertex_half_float
       
   281 #define GL_OES_vertex_half_float 1
       
   282 #endif
       
   283 
       
   284 /* GL_AMD_compressed_3DC_texture */
       
   285 #ifndef GL_AMD_compressed_3DC_texture
       
   286 #define GL_AMD_compressed_3DC_texture 1
       
   287 #endif
       
   288 
       
   289 /* GL_AMD_compressed_ATC_texture */
       
   290 #ifndef GL_AMD_compressed_ATC_texture
       
   291 #define GL_AMD_compressed_ATC_texture 1
       
   292 #endif
       
   293 
       
   294 /* GL_EXT_texture_filter_anisotropic */
       
   295 #ifndef GL_EXT_texture_filter_anisotropic
       
   296 #define GL_EXT_texture_filter_anisotropic 1
       
   297 #endif
       
   298 
       
   299 #ifdef __cplusplus
       
   300 }
       
   301 #endif
       
   302 
       
   303 #endif /* __gl2ext_h_ */