diff options
Diffstat (limited to 'src/mesa/main')
125 files changed, 8055 insertions, 4809 deletions
diff --git a/src/mesa/main/.gitignore b/src/mesa/main/.gitignore index d2fe135008..391c334ab7 100644 --- a/src/mesa/main/.gitignore +++ b/src/mesa/main/.gitignore @@ -1,2 +1,4 @@ +api_exec_es1.c +api_exec_es2.c get_es1.c get_es2.c diff --git a/src/mesa/main/APIspec.xml b/src/mesa/main/APIspec.xml index 16d0c9413d..0f82d0a38e 100644 --- a/src/mesa/main/APIspec.xml +++ b/src/mesa/main/APIspec.xml @@ -379,15 +379,68 @@ <value name="GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_OES" category="OES_texture_cube_map"/> </desc> - <desc name="internalFormat" error="GL_INVALID_VALUE"> + <desc name="internalFormat"> <value name="GL_ALPHA"/> + + <desc name="format" error="GL_INVALID_VALUE"> + <value name="GL_ALPHA"/> + </desc> + </desc> + + <desc name="internalFormat"> <value name="GL_RGB"/> + + <desc name="format" error="GL_INVALID_VALUE"> + <value name="GL_RGB"/> + </desc> + </desc> + + <desc name="internalFormat"> <value name="GL_RGBA"/> - <value name="GL_BGRA_EXT"/> + + <desc name="format" error="GL_INVALID_VALUE"> + <value name="GL_RGBA"/> + </desc> + </desc> + + <desc name="internalFormat"> <value name="GL_LUMINANCE"/> + + <desc name="format" error="GL_INVALID_VALUE"> + <value name="GL_LUMINANCE"/> + </desc> + </desc> + + <desc name="internalFormat"> <value name="GL_LUMINANCE_ALPHA"/> - <value name="GL_DEPTH_COMPONENT" category="OES_depth_texture"/> - <value name="GL_DEPTH_STENCIL_OES" category="OES_packed_depth_stencil"/> + + <desc name="format" error="GL_INVALID_VALUE"> + <value name="GL_LUMINANCE_ALPHA"/> + </desc> + </desc> + + <desc name="internalFormat" category="OES_depth_texture"> + <value name="GL_DEPTH_COMPONENT"/> + + <desc name="format" error="GL_INVALID_VALUE"> + <value name="GL_DEPTH_COMPONENT"/> + </desc> + </desc> + + <desc name="internalFormat" category="OES_packed_depth_stencil"> + <value name="GL_DEPTH_STENCIL_OES"/> + + <desc name="format" error="GL_INVALID_VALUE"> + <value name="GL_DEPTH_STENCIL_OES"/> + </desc> + </desc> + + <desc name="internalFormat" category="EXT_texture_format_BGRA8888"> + <value name="GL_BGRA_EXT"/> + + <desc name="format" error="GL_INVALID_VALUE"> + <value name="GL_BGRA_EXT"/> + </desc> </desc> <desc name="border" error="GL_INVALID_VALUE"> @@ -2004,6 +2057,14 @@ <value name="GL_UNSIGNED_INT_24_8_OES"/> </desc> </desc> + + <desc name="format" category="EXT_texture_format_BGRA8888"> + <value name="GL_BGRA_EXT"/> + + <desc name="type" error="GL_INVALID_OPERATION"> + <value name="GL_UNSIGNED_BYTE"/> + </desc> + </desc> </template> <template name="BindTexture"> @@ -3582,6 +3643,7 @@ <function name="ClearColor" template="ClearColor" gltype="GLclampf"/> <function name="ClearStencil" template="ClearStencil"/> <function name="ClearDepth" template="ClearDepth" gltype="GLclampd"/> + <function name="ClearDepthf" template="ClearDepth" gltype="GLclampf"/> <function name="StencilMask" template="StencilMask"/> <function name="StencilMaskSeparate" template="StencilMaskSeparate"/> @@ -3626,6 +3688,7 @@ <function name="IsEnabled" template="IsEnabled"/> <function name="DepthRange" template="DepthRange" gltype="GLclampd"/> + <function name="DepthRangef" template="DepthRange" gltype="GLclampf"/> <function name="Frustum" template="Frustum" gltype="GLdouble"/> <function name="LoadIdentity" template="LoadIdentity"/> diff --git a/src/mesa/main/accum.c b/src/mesa/main/accum.c index 9026110f3e..6a83930a13 100644 --- a/src/mesa/main/accum.c +++ b/src/mesa/main/accum.c @@ -27,6 +27,7 @@ #include "context.h" #include "imports.h" #include "macros.h" +#include "mfeatures.h" #include "state.h" #include "mtypes.h" #include "main/dispatch.h" @@ -50,7 +51,6 @@ _mesa_ClearAccum( GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha ) if (TEST_EQ_4V(tmp, ctx->Accum.ClearColor)) return; - FLUSH_VERTICES(ctx, _NEW_ACCUM); COPY_4FV( ctx->Accum.ClearColor, tmp ); } diff --git a/src/mesa/main/api_arrayelt.c b/src/mesa/main/api_arrayelt.c index c22e18c9fb..b429e2627e 100644 --- a/src/mesa/main/api_arrayelt.c +++ b/src/mesa/main/api_arrayelt.c @@ -40,6 +40,8 @@ #include "context.h" #include "imports.h" #include "macros.h" +#include "mfeatures.h" +#include "mtypes.h" #include "main/dispatch.h" typedef void (GLAPIENTRY *array_func)( const void * ); diff --git a/src/mesa/main/api_arrayelt.h b/src/mesa/main/api_arrayelt.h index 610e522a94..b90d713682 100644 --- a/src/mesa/main/api_arrayelt.h +++ b/src/mesa/main/api_arrayelt.h @@ -28,6 +28,7 @@ #define API_ARRAYELT_H +#include "main/mfeatures.h" #include "main/mtypes.h" #if FEATURE_arrayelt diff --git a/src/mesa/main/api_exec.c b/src/mesa/main/api_exec.c index 1427abd107..4da4893648 100644 --- a/src/mesa/main/api_exec.c +++ b/src/mesa/main/api_exec.c @@ -87,6 +87,7 @@ #include "texobj.h" #include "texparam.h" #include "texstate.h" +#include "texturebarrier.h" #include "transformfeedback.h" #include "mtypes.h" #include "varray.h" @@ -361,6 +362,10 @@ _mesa_create_exec_table(void) SET_PointParameterfvEXT(exec, _mesa_PointParameterfv); #endif + /* 95. GL_ARB_ES2_compatibility */ + SET_ClearDepthf(exec, _mesa_ClearDepthf); + SET_DepthRangef(exec, _mesa_DepthRangef); + /* 97. GL_EXT_compiled_vertex_array */ #if _HAVE_FULL_GL SET_LockArraysEXT(exec, _mesa_LockArraysEXT); @@ -707,7 +712,18 @@ _mesa_create_exec_table(void) SET_GetStringi(exec, _mesa_GetStringi); SET_ClampColor(exec, _mesa_ClampColorARB); + /* GL_ARB_instanced_arrays */ + SET_VertexAttribDivisorARB(exec, _mesa_VertexAttribDivisor); + + /* GL_ARB_draw_buffer_blend */ + SET_BlendFunciARB(exec, _mesa_BlendFunci); + SET_BlendFuncSeparateiARB(exec, _mesa_BlendFuncSeparatei); + SET_BlendEquationiARB(exec, _mesa_BlendEquationi); + SET_BlendEquationSeparateiARB(exec, _mesa_BlendEquationSeparatei); + /* GL_NV_texture_barrier */ + SET_TextureBarrierNV(exec, _mesa_TextureBarrierNV); + return exec; } diff --git a/src/mesa/main/api_exec_es1.c b/src/mesa/main/api_exec_es1.c index b29eb5a6d6..45cc19ce40 100644 --- a/src/mesa/main/api_exec_es1.c +++ b/src/mesa/main/api_exec_es1.c @@ -2,7 +2,7 @@ * THIS FILE AUTOMATICALLY GENERATED BY THE es_generator.py SCRIPT * API specification file: main/APIspec.xml * GLES version: GLES1.1 - * date: 2010-12-09 17:05:10 + * date: 2011-03-16 14:46:40 */ @@ -430,24 +430,17 @@ static void GL_APIENTRY _es_ClearColorx(GLclampx red, GLclampx green, GLclampx b _mesa_ClearColor(converted_red, converted_green, converted_blue, converted_alpha); } -extern void GL_APIENTRY _mesa_ClearDepth(GLclampd depth); -static void GL_APIENTRY _es_ClearDepthf(GLclampf depth) -{ - GLclampd converted_depth; - - converted_depth = (GLclampd) (depth); - - _mesa_ClearDepth(converted_depth); -} +extern void GL_APIENTRY _mesa_ClearDepthf(GLclampf depth); +#define _es_ClearDepthf _mesa_ClearDepthf -extern void GL_APIENTRY _mesa_ClearDepth(GLclampd depth); +extern void GL_APIENTRY _mesa_ClearDepthf(GLclampf depth); static void GL_APIENTRY _es_ClearDepthx(GLclampx depth) { - GLclampd converted_depth; + GLclampf converted_depth; - converted_depth = (GLclampd) (depth / 65536.0); + converted_depth = (GLclampf) (depth / 65536.0f); - _mesa_ClearDepth(converted_depth); + _mesa_ClearDepthf(converted_depth); } extern void GL_APIENTRY _mesa_ClearStencil(GLint s); @@ -787,28 +780,19 @@ static void GL_APIENTRY _es_DepthFunc(GLenum func) extern void GL_APIENTRY _mesa_DepthMask(GLboolean flag); #define _es_DepthMask _mesa_DepthMask -extern void GL_APIENTRY _mesa_DepthRange(GLclampd zNear, GLclampd zFar); -static void GL_APIENTRY _es_DepthRangef(GLclampf zNear, GLclampf zFar) -{ - GLclampd converted_zNear; - GLclampd converted_zFar; - - converted_zNear = (GLclampd) (zNear); - converted_zFar = (GLclampd) (zFar); +extern void GL_APIENTRY _mesa_DepthRangef(GLclampf zNear, GLclampf zFar); +#define _es_DepthRangef _mesa_DepthRangef - _mesa_DepthRange(converted_zNear, converted_zFar); -} - -extern void GL_APIENTRY _mesa_DepthRange(GLclampd zNear, GLclampd zFar); +extern void GL_APIENTRY _mesa_DepthRangef(GLclampf zNear, GLclampf zFar); static void GL_APIENTRY _es_DepthRangex(GLclampx zNear, GLclampx zFar) { - GLclampd converted_zNear; - GLclampd converted_zFar; + GLclampf converted_zNear; + GLclampf converted_zFar; - converted_zNear = (GLclampd) (zNear / 65536.0); - converted_zFar = (GLclampd) (zFar / 65536.0); + converted_zNear = (GLclampf) (zNear / 65536.0f); + converted_zFar = (GLclampf) (zFar / 65536.0f); - _mesa_DepthRange(converted_zNear, converted_zFar); + _mesa_DepthRangef(converted_zNear, converted_zFar); } extern void GL_APIENTRY _mesa_Disable(GLenum cap); @@ -4111,11 +4095,34 @@ static void GL_APIENTRY _es_TexImage2D(GLenum target, GLint level, GLint interna } switch(internalFormat) { case GL_ALPHA: + if (format != GL_ALPHA) { + _mesa_error(_mesa_get_current_context(), GL_INVALID_VALUE, "glTexImage2D(internalFormat=0x%x)", internalFormat); + return; + } + break; case GL_RGB: + if (format != GL_RGB) { + _mesa_error(_mesa_get_current_context(), GL_INVALID_VALUE, "glTexImage2D(internalFormat=0x%x)", internalFormat); + return; + } + break; case GL_RGBA: - case GL_BGRA_EXT: + if (format != GL_RGBA) { + _mesa_error(_mesa_get_current_context(), GL_INVALID_VALUE, "glTexImage2D(internalFormat=0x%x)", internalFormat); + return; + } + break; case GL_LUMINANCE: + if (format != GL_LUMINANCE) { + _mesa_error(_mesa_get_current_context(), GL_INVALID_VALUE, "glTexImage2D(internalFormat=0x%x)", internalFormat); + return; + } + break; case GL_LUMINANCE_ALPHA: + if (format != GL_LUMINANCE_ALPHA) { + _mesa_error(_mesa_get_current_context(), GL_INVALID_VALUE, "glTexImage2D(internalFormat=0x%x)", internalFormat); + return; + } break; default: _mesa_error(_mesa_get_current_context(), GL_INVALID_VALUE, "glTexImage2D(internalFormat=%d)", internalFormat); diff --git a/src/mesa/main/api_exec_es2.c b/src/mesa/main/api_exec_es2.c index e706bc2c32..4c53e99f22 100644 --- a/src/mesa/main/api_exec_es2.c +++ b/src/mesa/main/api_exec_es2.c @@ -2,7 +2,7 @@ * THIS FILE AUTOMATICALLY GENERATED BY THE es_generator.py SCRIPT * API specification file: main/APIspec.xml * GLES version: GLES2.0 - * date: 2010-12-09 17:05:11 + * date: 2011-03-16 14:46:40 */ @@ -403,15 +403,8 @@ static void GL_APIENTRY _es_Clear(GLbitfield mask) extern void GL_APIENTRY _mesa_ClearColor(GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha); #define _es_ClearColor _mesa_ClearColor -extern void GL_APIENTRY _mesa_ClearDepth(GLclampd depth); -static void GL_APIENTRY _es_ClearDepthf(GLclampf depth) -{ - GLclampd converted_depth; - - converted_depth = (GLclampd) (depth); - - _mesa_ClearDepth(converted_depth); -} +extern void GL_APIENTRY _mesa_ClearDepthf(GLclampf depth); +#define _es_ClearDepthf _mesa_ClearDepthf extern void GL_APIENTRY _mesa_ClearStencil(GLint s); #define _es_ClearStencil _mesa_ClearStencil @@ -671,17 +664,8 @@ static void GL_APIENTRY _es_DepthFunc(GLenum func) extern void GL_APIENTRY _mesa_DepthMask(GLboolean flag); #define _es_DepthMask _mesa_DepthMask -extern void GL_APIENTRY _mesa_DepthRange(GLclampd zNear, GLclampd zFar); -static void GL_APIENTRY _es_DepthRangef(GLclampf zNear, GLclampf zFar) -{ - GLclampd converted_zNear; - GLclampd converted_zFar; - - converted_zNear = (GLclampd) (zNear); - converted_zFar = (GLclampd) (zFar); - - _mesa_DepthRange(converted_zNear, converted_zFar); -} +extern void GL_APIENTRY _mesa_DepthRangef(GLclampf zNear, GLclampf zFar); +#define _es_DepthRangef _mesa_DepthRangef extern void GL_APIENTRY _mesa_DetachShader(GLuint program, GLuint shader); #define _es_DetachShader _mesa_DetachShader @@ -1743,13 +1727,52 @@ static void GL_APIENTRY _es_TexImage2D(GLenum target, GLint level, GLint interna } switch(internalFormat) { case GL_ALPHA: + if (format != GL_ALPHA) { + _mesa_error(_mesa_get_current_context(), GL_INVALID_VALUE, "glTexImage2D(internalFormat=0x%x)", internalFormat); + return; + } + break; case GL_RGB: + if (format != GL_RGB) { + _mesa_error(_mesa_get_current_context(), GL_INVALID_VALUE, "glTexImage2D(internalFormat=0x%x)", internalFormat); + return; + } + break; case GL_RGBA: - case GL_BGRA_EXT: + if (format != GL_RGBA) { + _mesa_error(_mesa_get_current_context(), GL_INVALID_VALUE, "glTexImage2D(internalFormat=0x%x)", internalFormat); + return; + } + break; case GL_LUMINANCE: + if (format != GL_LUMINANCE) { + _mesa_error(_mesa_get_current_context(), GL_INVALID_VALUE, "glTexImage2D(internalFormat=0x%x)", internalFormat); + return; + } + break; case GL_LUMINANCE_ALPHA: + if (format != GL_LUMINANCE_ALPHA) { + _mesa_error(_mesa_get_current_context(), GL_INVALID_VALUE, "glTexImage2D(internalFormat=0x%x)", internalFormat); + return; + } + break; case GL_DEPTH_COMPONENT: + if (format != GL_DEPTH_COMPONENT) { + _mesa_error(_mesa_get_current_context(), GL_INVALID_VALUE, "glTexImage2D(internalFormat=0x%x)", internalFormat); + return; + } + break; case GL_DEPTH_STENCIL_OES: + if (format != GL_DEPTH_STENCIL_OES) { + _mesa_error(_mesa_get_current_context(), GL_INVALID_VALUE, "glTexImage2D(internalFormat=0x%x)", internalFormat); + return; + } + break; + case GL_BGRA_EXT: + if (format != GL_BGRA_EXT) { + _mesa_error(_mesa_get_current_context(), GL_INVALID_VALUE, "glTexImage2D(internalFormat=0x%x)", internalFormat); + return; + } break; default: _mesa_error(_mesa_get_current_context(), GL_INVALID_VALUE, "glTexImage2D(internalFormat=%d)", internalFormat); @@ -2095,6 +2118,12 @@ static void GL_APIENTRY _es_TexSubImage2D(GLenum target, GLint level, GLint xoff return; } break; + case GL_BGRA_EXT: + if (type != GL_UNSIGNED_BYTE) { + _mesa_error(_mesa_get_current_context(), GL_INVALID_OPERATION, "glTexSubImage2D(format=0x%x)", format); + return; + } + break; default: _mesa_error(_mesa_get_current_context(), GL_INVALID_OPERATION, "glTexSubImage2D(format=0x%x)", format); return; diff --git a/src/mesa/main/api_noop.c b/src/mesa/main/api_noop.c index 08b4b4a3b6..7d3d332727 100644 --- a/src/mesa/main/api_noop.c +++ b/src/mesa/main/api_noop.c @@ -30,6 +30,7 @@ #include "context.h" #include "light.h" #include "macros.h" +#include "mfeatures.h" #include "dlist.h" #include "eval.h" #include "main/dispatch.h" diff --git a/src/mesa/main/api_noop.h b/src/mesa/main/api_noop.h index e7fd49bafb..aca7f088db 100644 --- a/src/mesa/main/api_noop.h +++ b/src/mesa/main/api_noop.h @@ -25,6 +25,7 @@ #ifndef _API_NOOP_H #define _API_NOOP_H +#include "main/mfeatures.h" #include "main/mtypes.h" #if FEATURE_beginend diff --git a/src/mesa/main/api_validate.c b/src/mesa/main/api_validate.c index ac9709db3f..7c4652f747 100644 --- a/src/mesa/main/api_validate.c +++ b/src/mesa/main/api_validate.c @@ -329,7 +329,7 @@ _mesa_validate_DrawArrays(struct gl_context *ctx, GLboolean _mesa_validate_DrawArraysInstanced(struct gl_context *ctx, GLenum mode, GLint first, - GLsizei count, GLsizei primcount) + GLsizei count, GLsizei numInstances) { ASSERT_OUTSIDE_BEGIN_END_WITH_RETVAL(ctx, GL_FALSE); @@ -346,10 +346,10 @@ _mesa_validate_DrawArraysInstanced(struct gl_context *ctx, GLenum mode, GLint fi return GL_FALSE; } - if (primcount <= 0) { - if (primcount < 0) + if (numInstances <= 0) { + if (numInstances < 0) _mesa_error(ctx, GL_INVALID_VALUE, - "glDrawArraysInstanced(primcount=%d)", primcount); + "glDrawArraysInstanced(numInstances=%d)", numInstances); return GL_FALSE; } @@ -374,7 +374,7 @@ _mesa_validate_DrawArraysInstanced(struct gl_context *ctx, GLenum mode, GLint fi GLboolean _mesa_validate_DrawElementsInstanced(struct gl_context *ctx, GLenum mode, GLsizei count, GLenum type, - const GLvoid *indices, GLsizei primcount) + const GLvoid *indices, GLsizei numInstances) { ASSERT_OUTSIDE_BEGIN_END_WITH_RETVAL(ctx, GL_FALSE); @@ -399,10 +399,10 @@ _mesa_validate_DrawElementsInstanced(struct gl_context *ctx, return GL_FALSE; } - if (primcount <= 0) { - if (primcount < 0) + if (numInstances <= 0) { + if (numInstances < 0) _mesa_error(ctx, GL_INVALID_VALUE, - "glDrawElementsInstanced(primcount=%d)", primcount); + "glDrawElementsInstanced(numInstances=%d)", numInstances); return GL_FALSE; } diff --git a/src/mesa/main/arrayobj.c b/src/mesa/main/arrayobj.c index 0d64b7de8d..4601022337 100644 --- a/src/mesa/main/arrayobj.c +++ b/src/mesa/main/arrayobj.c @@ -43,11 +43,13 @@ #include "hash.h" #include "imports.h" #include "context.h" +#include "mfeatures.h" #if FEATURE_ARB_vertex_buffer_object #include "bufferobj.h" #endif #include "arrayobj.h" #include "macros.h" +#include "mtypes.h" #include "main/dispatch.h" @@ -232,7 +234,7 @@ _mesa_initialize_array_object( struct gl_context *ctx, init_array(ctx, &obj->Weight, 1, GL_FLOAT); init_array(ctx, &obj->Normal, 3, GL_FLOAT); init_array(ctx, &obj->Color, 4, GL_FLOAT); - init_array(ctx, &obj->SecondaryColor, 4, GL_FLOAT); + init_array(ctx, &obj->SecondaryColor, 3, GL_FLOAT); init_array(ctx, &obj->FogCoord, 1, GL_FLOAT); init_array(ctx, &obj->Index, 1, GL_FLOAT); for (i = 0; i < Elements(obj->TexCoord); i++) { diff --git a/src/mesa/main/atifragshader.c b/src/mesa/main/atifragshader.c index ae2feb3229..44097e1a26 100644 --- a/src/mesa/main/atifragshader.c +++ b/src/mesa/main/atifragshader.c @@ -26,6 +26,7 @@ #include "main/hash.h" #include "main/imports.h" #include "main/macros.h" +#include "main/mfeatures.h" #include "main/enums.h" #include "main/mtypes.h" #include "main/dispatch.h" @@ -316,6 +317,7 @@ _mesa_DeleteFragmentShaderATI(GLuint id) if (prog) { prog->RefCount--; if (prog->RefCount <= 0) { + assert(prog != &DummyShader); free(prog); } } diff --git a/src/mesa/main/attrib.c b/src/mesa/main/attrib.c index fb6fbe5b6d..ae7f633b8d 100644 --- a/src/mesa/main/attrib.c +++ b/src/mesa/main/attrib.c @@ -43,6 +43,7 @@ #include "lines.h" #include "macros.h" #include "matrix.h" +#include "mfeatures.h" #include "multisample.h" #include "points.h" #include "polygon.h" @@ -124,9 +125,6 @@ struct gl_enable_attrib GLbitfield Texture[MAX_TEXTURE_UNITS]; GLbitfield TexGen[MAX_TEXTURE_UNITS]; - /* SGI_texture_color_table */ - GLboolean TextureColorTable[MAX_TEXTURE_UNITS]; - /* GL_ARB_vertex_program / GL_NV_vertex_program */ GLboolean VertexProgram; GLboolean VertexProgramPointSize; @@ -310,7 +308,6 @@ _mesa_PushAttrib(GLbitfield mask) for (i = 0; i < ctx->Const.MaxTextureUnits; i++) { attr->Texture[i] = ctx->Texture.Unit[i].Enabled; attr->TexGen[i] = ctx->Texture.Unit[i].TexGenEnabled; - attr->TextureColorTable[i] = ctx->Texture.Unit[i].ColorTableEnabled; } /* GL_NV_vertex_program */ attr->VertexProgram = ctx->VertexProgram.Enabled; @@ -656,9 +653,6 @@ pop_enable_group(struct gl_context *ctx, const struct gl_enable_attrib *enable) _mesa_set_enable(ctx, GL_TEXTURE_GEN_Q, (genEnabled & Q_BIT) ? GL_TRUE : GL_FALSE); } - - /* GL_SGI_texture_color_table */ - ctx->Texture.Unit[i].ColorTableEnabled = enable->TextureColorTable[i]; } _mesa_ActiveTextureARB(GL_TEXTURE0 + curTexUnitSave); @@ -701,10 +695,6 @@ pop_texture_group(struct gl_context *ctx, struct texture_state *texstate) (unit->Enabled & TEXTURE_2D_ARRAY_BIT) ? GL_TRUE : GL_FALSE); } - if (ctx->Extensions.SGI_texture_color_table) { - _mesa_set_enable(ctx, GL_TEXTURE_COLOR_TABLE_SGI, - unit->ColorTableEnabled); - } _mesa_TexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, unit->EnvMode); _mesa_TexEnvfv(GL_TEXTURE_ENV, GL_TEXTURE_ENV_COLOR, unit->EnvColor); _mesa_TexGeni(GL_S, GL_TEXTURE_GEN_MODE, unit->GenS.Mode); @@ -953,20 +943,39 @@ _mesa_PopAttrib(void) _mesa_set_enable(ctx, GL_BLEND, (color->BlendEnabled & 1)); } } - _mesa_BlendFuncSeparateEXT(color->BlendSrcRGB, - color->BlendDstRGB, - color->BlendSrcA, - color->BlendDstA); - /* This special case is because glBlendEquationSeparateEXT - * cannot take GL_LOGIC_OP as a parameter. - */ - if ( color->BlendEquationRGB == color->BlendEquationA ) { - _mesa_BlendEquation(color->BlendEquationRGB); - } - else { - _mesa_BlendEquationSeparateEXT(color->BlendEquationRGB, - color->BlendEquationA); - } + if (ctx->Color._BlendFuncPerBuffer || + ctx->Color._BlendEquationPerBuffer) { + /* set blend per buffer */ + GLuint buf; + for (buf = 0; buf < ctx->Const.MaxDrawBuffers; buf++) { + _mesa_BlendFuncSeparatei(buf, color->Blend[buf].SrcRGB, + color->Blend[buf].DstRGB, + color->Blend[buf].SrcA, + color->Blend[buf].DstA); + _mesa_BlendEquationSeparatei(buf, + color->Blend[buf].EquationRGB, + color->Blend[buf].EquationA); + } + } + else { + /* set same blend modes for all buffers */ + _mesa_BlendFuncSeparateEXT(color->Blend[0].SrcRGB, + color->Blend[0].DstRGB, + color->Blend[0].SrcA, + color->Blend[0].DstA); + /* This special case is because glBlendEquationSeparateEXT + * cannot take GL_LOGIC_OP as a parameter. + */ + if (color->Blend[0].EquationRGB == + color->Blend[0].EquationA) { + _mesa_BlendEquation(color->Blend[0].EquationRGB); + } + else { + _mesa_BlendEquationSeparateEXT( + color->Blend[0].EquationRGB, + color->Blend[0].EquationA); + } + } _mesa_BlendColor(color->BlendColor[0], color->BlendColor[1], color->BlendColor[2], diff --git a/src/mesa/main/blend.c b/src/mesa/main/blend.c index ec778b7244..c74a168036 100644 --- a/src/mesa/main/blend.c +++ b/src/mesa/main/blend.c @@ -37,6 +37,110 @@ #include "mtypes.h" + +/** + * Check if given blend source factor is legal. + * \return GL_TRUE if legal, GL_FALSE otherwise. + */ +static GLboolean +legal_src_factor(const struct gl_context *ctx, GLenum factor) +{ + switch (factor) { + case GL_SRC_COLOR: + case GL_ONE_MINUS_SRC_COLOR: + return ctx->Extensions.NV_blend_square; + case GL_ZERO: + case GL_ONE: + case GL_DST_COLOR: + case GL_ONE_MINUS_DST_COLOR: + case GL_SRC_ALPHA: + case GL_ONE_MINUS_SRC_ALPHA: + case GL_DST_ALPHA: + case GL_ONE_MINUS_DST_ALPHA: + case GL_SRC_ALPHA_SATURATE: + case GL_CONSTANT_COLOR: + case GL_ONE_MINUS_CONSTANT_COLOR: + case GL_CONSTANT_ALPHA: + case GL_ONE_MINUS_CONSTANT_ALPHA: + return GL_TRUE; + default: + return GL_FALSE; + } +} + + +/** + * Check if given blend destination factor is legal. + * \return GL_TRUE if legal, GL_FALSE otherwise. + */ +static GLboolean +legal_dst_factor(const struct gl_context *ctx, GLenum factor) +{ + switch (factor) { + case GL_DST_COLOR: + case GL_ONE_MINUS_DST_COLOR: + return ctx->Extensions.NV_blend_square; + case GL_ZERO: + case GL_ONE: + case GL_SRC_COLOR: + case GL_ONE_MINUS_SRC_COLOR: + case GL_SRC_ALPHA: + case GL_ONE_MINUS_SRC_ALPHA: + case GL_DST_ALPHA: + case GL_ONE_MINUS_DST_ALPHA: + case GL_CONSTANT_COLOR: + case GL_ONE_MINUS_CONSTANT_COLOR: + case GL_CONSTANT_ALPHA: + case GL_ONE_MINUS_CONSTANT_ALPHA: + return GL_TRUE; + default: + return GL_FALSE; + } +} + + +/** + * Check if src/dest RGB/A blend factors are legal. If not generate + * a GL error. + * \return GL_TRUE if factors are legal, GL_FALSE otherwise. + */ +static GLboolean +validate_blend_factors(struct gl_context *ctx, const char *func, + GLenum sfactorRGB, GLenum dfactorRGB, + GLenum sfactorA, GLenum dfactorA) +{ + if (!legal_src_factor(ctx, sfactorRGB)) { + _mesa_error(ctx, GL_INVALID_ENUM, + "%s(sfactorRGB = %s)", func, + _mesa_lookup_enum_by_nr(sfactorRGB)); + return GL_FALSE; + } + + if (!legal_dst_factor(ctx, dfactorRGB)) { + _mesa_error(ctx, GL_INVALID_ENUM, + "%s(dfactorRGB = %s)", func, + _mesa_lookup_enum_by_nr(dfactorRGB)); + return GL_FALSE; + } + + if (sfactorA != sfactorRGB && !legal_src_factor(ctx, sfactorA)) { + _mesa_error(ctx, GL_INVALID_ENUM, + "%s(sfactorA = %s)", func, + _mesa_lookup_enum_by_nr(sfactorA)); + return GL_FALSE; + } + + if (dfactorA != dfactorRGB && !legal_dst_factor(ctx, dfactorA)) { + _mesa_error(ctx, GL_INVALID_ENUM, + "%s(dfactorA = %s)", func, + _mesa_lookup_enum_by_nr(dfactorA)); + return GL_FALSE; + } + + return GL_TRUE; +} + + /** * Specify the blending operation. * @@ -53,21 +157,19 @@ _mesa_BlendFunc( GLenum sfactor, GLenum dfactor ) /** - * Process GL_EXT_blend_func_separate(). + * Set the separate blend source/dest factors for all draw buffers. * * \param sfactorRGB RGB source factor operator. * \param dfactorRGB RGB destination factor operator. * \param sfactorA alpha source factor operator. * \param dfactorA alpha destination factor operator. - * - * Verifies the parameters and updates gl_colorbuffer_attrib. - * On a change, flush the vertices and notify the driver via - * dd_function_table::BlendFuncSeparate. */ void GLAPIENTRY _mesa_BlendFuncSeparateEXT( GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorA, GLenum dfactorA ) { + GLuint buf, numBuffers; + GLboolean changed; GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END(ctx); @@ -78,165 +180,130 @@ _mesa_BlendFuncSeparateEXT( GLenum sfactorRGB, GLenum dfactorRGB, _mesa_lookup_enum_by_nr(sfactorA), _mesa_lookup_enum_by_nr(dfactorA)); - switch (sfactorRGB) { - case GL_SRC_COLOR: - case GL_ONE_MINUS_SRC_COLOR: - if (!ctx->Extensions.NV_blend_square) { - _mesa_error(ctx, GL_INVALID_ENUM, "glBlendFunc or glBlendFuncSeparate (sfactorRGB)"); - return; - } - /* fall-through */ - case GL_ZERO: - case GL_ONE: - case GL_DST_COLOR: - case GL_ONE_MINUS_DST_COLOR: - case GL_SRC_ALPHA: - case GL_ONE_MINUS_SRC_ALPHA: - case GL_DST_ALPHA: - case GL_ONE_MINUS_DST_ALPHA: - case GL_SRC_ALPHA_SATURATE: - case GL_CONSTANT_COLOR: - case GL_ONE_MINUS_CONSTANT_COLOR: - case GL_CONSTANT_ALPHA: - case GL_ONE_MINUS_CONSTANT_ALPHA: - break; - default: - _mesa_error(ctx, GL_INVALID_ENUM, "glBlendFunc or glBlendFuncSeparate (sfactorRGB)"); - return; + if (!validate_blend_factors(ctx, "glBlendFuncSeparate", + sfactorRGB, dfactorRGB, + sfactorA, dfactorA)) { + return; } - switch (dfactorRGB) { - case GL_DST_COLOR: - case GL_ONE_MINUS_DST_COLOR: - if (!ctx->Extensions.NV_blend_square) { - _mesa_error(ctx, GL_INVALID_ENUM, "glBlendFunc or glBlendFuncSeparate (dfactorRGB)"); - return; - } - /* fall-through */ - case GL_ZERO: - case GL_ONE: - case GL_SRC_COLOR: - case GL_ONE_MINUS_SRC_COLOR: - case GL_SRC_ALPHA: - case GL_ONE_MINUS_SRC_ALPHA: - case GL_DST_ALPHA: - case GL_ONE_MINUS_DST_ALPHA: - case GL_CONSTANT_COLOR: - case GL_ONE_MINUS_CONSTANT_COLOR: - case GL_CONSTANT_ALPHA: - case GL_ONE_MINUS_CONSTANT_ALPHA: + numBuffers = ctx->Extensions.ARB_draw_buffers_blend + ? ctx->Const.MaxDrawBuffers : 1; + + changed = GL_FALSE; + for (buf = 0; buf < numBuffers; buf++) { + if (ctx->Color.Blend[buf].SrcRGB != sfactorRGB || + ctx->Color.Blend[buf].DstRGB != dfactorRGB || + ctx->Color.Blend[buf].SrcA != sfactorA || + ctx->Color.Blend[buf].DstA != dfactorA) { + changed = GL_TRUE; break; - default: - _mesa_error(ctx, GL_INVALID_ENUM, "glBlendFunc or glBlendFuncSeparate (dfactorRGB)"); - return; + } } + if (!changed) + return; - switch (sfactorA) { - case GL_SRC_COLOR: - case GL_ONE_MINUS_SRC_COLOR: - if (!ctx->Extensions.NV_blend_square) { - _mesa_error(ctx, GL_INVALID_ENUM, "glBlendFunc or glBlendFuncSeparate (sfactorA)"); - return; - } - /* fall-through */ - case GL_ZERO: - case GL_ONE: - case GL_DST_COLOR: - case GL_ONE_MINUS_DST_COLOR: - case GL_SRC_ALPHA: - case GL_ONE_MINUS_SRC_ALPHA: - case GL_DST_ALPHA: - case GL_ONE_MINUS_DST_ALPHA: - case GL_SRC_ALPHA_SATURATE: - case GL_CONSTANT_COLOR: - case GL_ONE_MINUS_CONSTANT_COLOR: - case GL_CONSTANT_ALPHA: - case GL_ONE_MINUS_CONSTANT_ALPHA: - break; - default: - _mesa_error(ctx, GL_INVALID_ENUM, "glBlendFunc or glBlendFuncSeparate (sfactorA)"); - return; + FLUSH_VERTICES(ctx, _NEW_COLOR); + + for (buf = 0; buf < numBuffers; buf++) { + ctx->Color.Blend[buf].SrcRGB = sfactorRGB; + ctx->Color.Blend[buf].DstRGB = dfactorRGB; + ctx->Color.Blend[buf].SrcA = sfactorA; + ctx->Color.Blend[buf].DstA = dfactorA; } + ctx->Color._BlendFuncPerBuffer = GL_FALSE; - switch (dfactorA) { - case GL_DST_COLOR: - case GL_ONE_MINUS_DST_COLOR: - if (!ctx->Extensions.NV_blend_square) { - _mesa_error(ctx, GL_INVALID_ENUM, "glBlendFunc or glBlendFuncSeparate (dfactorA)"); - return; - } - /* fall-through */ - case GL_ZERO: - case GL_ONE: - case GL_SRC_COLOR: - case GL_ONE_MINUS_SRC_COLOR: - case GL_SRC_ALPHA: - case GL_ONE_MINUS_SRC_ALPHA: - case GL_DST_ALPHA: - case GL_ONE_MINUS_DST_ALPHA: - case GL_CONSTANT_COLOR: - case GL_ONE_MINUS_CONSTANT_COLOR: - case GL_CONSTANT_ALPHA: - case GL_ONE_MINUS_CONSTANT_ALPHA: - break; - default: - _mesa_error( ctx, GL_INVALID_ENUM, "glBlendFunc or glBlendFuncSeparate (dfactorA)" ); - return; + if (ctx->Driver.BlendFuncSeparate) { + ctx->Driver.BlendFuncSeparate(ctx, sfactorRGB, dfactorRGB, + sfactorA, dfactorA); + } +} + + +#if _HAVE_FULL_GL + + +/** + * Set blend source/dest factors for one color buffer/target. + */ +void GLAPIENTRY +_mesa_BlendFunci(GLuint buf, GLenum sfactor, GLenum dfactor) +{ + _mesa_BlendFuncSeparatei(buf, sfactor, dfactor, sfactor, dfactor); +} + + +/** + * Set separate blend source/dest factors for one color buffer/target. + */ +void GLAPIENTRY +_mesa_BlendFuncSeparatei(GLuint buf, GLenum sfactorRGB, GLenum dfactorRGB, + GLenum sfactorA, GLenum dfactorA) +{ + GET_CURRENT_CONTEXT(ctx); + ASSERT_OUTSIDE_BEGIN_END(ctx); + + if (!ctx->Extensions.ARB_draw_buffers_blend) { + _mesa_error(ctx, GL_INVALID_OPERATION, "glBlendFunc[Separate]i()"); + return; + } + + if (buf >= ctx->Const.MaxDrawBuffers) { + _mesa_error(ctx, GL_INVALID_VALUE, "glBlendFuncSeparatei(buffer=%u)", + buf); + return; } - if (ctx->Color.BlendSrcRGB == sfactorRGB && - ctx->Color.BlendDstRGB == dfactorRGB && - ctx->Color.BlendSrcA == sfactorA && - ctx->Color.BlendDstA == dfactorA) + if (!validate_blend_factors(ctx, "glBlendFuncSeparatei", + sfactorRGB, dfactorRGB, + sfactorA, dfactorA)) { return; + } + + if (ctx->Color.Blend[buf].SrcRGB == sfactorRGB && + ctx->Color.Blend[buf].DstRGB == dfactorRGB && + ctx->Color.Blend[buf].SrcA == sfactorA && + ctx->Color.Blend[buf].DstA == dfactorA) + return; /* no change */ FLUSH_VERTICES(ctx, _NEW_COLOR); - ctx->Color.BlendSrcRGB = sfactorRGB; - ctx->Color.BlendDstRGB = dfactorRGB; - ctx->Color.BlendSrcA = sfactorA; - ctx->Color.BlendDstA = dfactorA; + ctx->Color.Blend[buf].SrcRGB = sfactorRGB; + ctx->Color.Blend[buf].DstRGB = dfactorRGB; + ctx->Color.Blend[buf].SrcA = sfactorA; + ctx->Color.Blend[buf].DstA = dfactorA; + ctx->Color._BlendFuncPerBuffer = GL_TRUE; - if (ctx->Driver.BlendFuncSeparate) { - (*ctx->Driver.BlendFuncSeparate)( ctx, sfactorRGB, dfactorRGB, - sfactorA, dfactorA ); + if (ctx->Driver.BlendFuncSeparatei) { + ctx->Driver.BlendFuncSeparatei(ctx, buf, sfactorRGB, dfactorRGB, + sfactorA, dfactorA); } } -#if _HAVE_FULL_GL - +/** + * Check if given blend equation is legal. + * \return GL_TRUE if legal, GL_FALSE otherwise. + */ static GLboolean -_mesa_validate_blend_equation( struct gl_context *ctx, - GLenum mode, GLboolean is_separate ) +legal_blend_equation(const struct gl_context *ctx, + GLenum mode, GLboolean is_separate) { switch (mode) { - case GL_FUNC_ADD: - break; - case GL_MIN: - case GL_MAX: - if (!ctx->Extensions.EXT_blend_minmax) { - return GL_FALSE; - } - break; + case GL_FUNC_ADD: + return GL_TRUE; + case GL_MIN: + case GL_MAX: + return ctx->Extensions.EXT_blend_minmax; + case GL_LOGIC_OP: /* glBlendEquationSeparate cannot take GL_LOGIC_OP as a parameter. */ - case GL_LOGIC_OP: - if (!ctx->Extensions.EXT_blend_logic_op || is_separate) { - return GL_FALSE; - } - break; - case GL_FUNC_SUBTRACT: - case GL_FUNC_REVERSE_SUBTRACT: - if (!ctx->Extensions.EXT_blend_subtract) { - return GL_FALSE; - } - break; - default: - return GL_FALSE; + return ctx->Extensions.EXT_blend_logic_op && !is_separate; + case GL_FUNC_SUBTRACT: + case GL_FUNC_REVERSE_SUBTRACT: + return ctx->Extensions.EXT_blend_subtract; + default: + return GL_FALSE; } - - return GL_TRUE; } @@ -244,39 +311,94 @@ _mesa_validate_blend_equation( struct gl_context *ctx, void GLAPIENTRY _mesa_BlendEquation( GLenum mode ) { + GLuint buf, numBuffers; + GLboolean changed; GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END(ctx); if (MESA_VERBOSE & VERBOSE_API) - _mesa_debug(ctx, "glBlendEquation %s\n", + _mesa_debug(ctx, "glBlendEquation(%s)\n", _mesa_lookup_enum_by_nr(mode)); - if ( ! _mesa_validate_blend_equation( ctx, mode, GL_FALSE ) ) { + if (!legal_blend_equation(ctx, mode, GL_FALSE)) { _mesa_error(ctx, GL_INVALID_ENUM, "glBlendEquation"); return; } - if ( (ctx->Color.BlendEquationRGB == mode) && - (ctx->Color.BlendEquationA == mode) ) + numBuffers = ctx->Extensions.ARB_draw_buffers_blend + ? ctx->Const.MaxDrawBuffers : 1; + + changed = GL_FALSE; + for (buf = 0; buf < numBuffers; buf++) { + if (ctx->Color.Blend[buf].EquationRGB != mode || + ctx->Color.Blend[buf].EquationA != mode) { + changed = GL_TRUE; + break; + } + } + if (!changed) return; FLUSH_VERTICES(ctx, _NEW_COLOR); - ctx->Color.BlendEquationRGB = mode; - ctx->Color.BlendEquationA = mode; + for (buf = 0; buf < numBuffers; buf++) { + ctx->Color.Blend[buf].EquationRGB = mode; + ctx->Color.Blend[buf].EquationA = mode; + } + ctx->Color._BlendEquationPerBuffer = GL_FALSE; if (ctx->Driver.BlendEquationSeparate) (*ctx->Driver.BlendEquationSeparate)( ctx, mode, mode ); } +/** + * Set blend equation for one color buffer/target. + */ +void GLAPIENTRY +_mesa_BlendEquationi(GLuint buf, GLenum mode) +{ + GET_CURRENT_CONTEXT(ctx); + ASSERT_OUTSIDE_BEGIN_END(ctx); + + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glBlendEquationi(%u, %s)\n", + buf, _mesa_lookup_enum_by_nr(mode)); + + if (buf >= ctx->Const.MaxDrawBuffers) { + _mesa_error(ctx, GL_INVALID_VALUE, "glBlendFuncSeparatei(buffer=%u)", + buf); + return; + } + + if (!legal_blend_equation(ctx, mode, GL_FALSE)) { + _mesa_error(ctx, GL_INVALID_ENUM, "glBlendEquationi"); + return; + } + + if (ctx->Color.Blend[buf].EquationRGB == mode && + ctx->Color.Blend[buf].EquationA == mode) + return; /* no change */ + + FLUSH_VERTICES(ctx, _NEW_COLOR); + ctx->Color.Blend[buf].EquationRGB = mode; + ctx->Color.Blend[buf].EquationA = mode; + ctx->Color._BlendEquationPerBuffer = GL_TRUE; + + if (ctx->Driver.BlendEquationSeparatei) + ctx->Driver.BlendEquationSeparatei(ctx, buf, mode, mode); +} + + void GLAPIENTRY _mesa_BlendEquationSeparateEXT( GLenum modeRGB, GLenum modeA ) { + GLuint buf, numBuffers; + GLboolean changed; GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END(ctx); if (MESA_VERBOSE & VERBOSE_API) - _mesa_debug(ctx, "glBlendEquationSeparateEXT %s %s\n", + _mesa_debug(ctx, "glBlendEquationSeparateEXT(%s %s)\n", _mesa_lookup_enum_by_nr(modeRGB), _mesa_lookup_enum_by_nr(modeA)); @@ -286,29 +408,88 @@ _mesa_BlendEquationSeparateEXT( GLenum modeRGB, GLenum modeA ) return; } - if ( ! _mesa_validate_blend_equation( ctx, modeRGB, GL_TRUE ) ) { + if (!legal_blend_equation(ctx, modeRGB, GL_TRUE)) { _mesa_error(ctx, GL_INVALID_ENUM, "glBlendEquationSeparateEXT(modeRGB)"); return; } - if ( ! _mesa_validate_blend_equation( ctx, modeA, GL_TRUE ) ) { + if (!legal_blend_equation(ctx, modeA, GL_TRUE)) { _mesa_error(ctx, GL_INVALID_ENUM, "glBlendEquationSeparateEXT(modeA)"); return; } + numBuffers = ctx->Extensions.ARB_draw_buffers_blend + ? ctx->Const.MaxDrawBuffers : 1; - if ( (ctx->Color.BlendEquationRGB == modeRGB) && - (ctx->Color.BlendEquationA == modeA) ) + changed = GL_FALSE; + for (buf = 0; buf < numBuffers; buf++) { + if (ctx->Color.Blend[buf].EquationRGB != modeRGB || + ctx->Color.Blend[buf].EquationA != modeA) { + changed = GL_TRUE; + break; + } + } + if (!changed) return; FLUSH_VERTICES(ctx, _NEW_COLOR); - ctx->Color.BlendEquationRGB = modeRGB; - ctx->Color.BlendEquationA = modeA; + for (buf = 0; buf < numBuffers; buf++) { + ctx->Color.Blend[buf].EquationRGB = modeRGB; + ctx->Color.Blend[buf].EquationA = modeA; + } + ctx->Color._BlendEquationPerBuffer = GL_FALSE; if (ctx->Driver.BlendEquationSeparate) - (*ctx->Driver.BlendEquationSeparate)( ctx, modeRGB, modeA ); + ctx->Driver.BlendEquationSeparate(ctx, modeRGB, modeA); } -#endif + + +/** + * Set separate blend equations for one color buffer/target. + */ +void +_mesa_BlendEquationSeparatei(GLuint buf, GLenum modeRGB, GLenum modeA) +{ + GET_CURRENT_CONTEXT(ctx); + ASSERT_OUTSIDE_BEGIN_END(ctx); + + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glBlendEquationSeparatei(%u, %s %s)\n", buf, + _mesa_lookup_enum_by_nr(modeRGB), + _mesa_lookup_enum_by_nr(modeA)); + + if (buf >= ctx->Const.MaxDrawBuffers) { + _mesa_error(ctx, GL_INVALID_VALUE, "glBlendEquationSeparatei(buffer=%u)", + buf); + return; + } + + if (!legal_blend_equation(ctx, modeRGB, GL_TRUE)) { + _mesa_error(ctx, GL_INVALID_ENUM, "glBlendEquationSeparatei(modeRGB)"); + return; + } + + if (!legal_blend_equation(ctx, modeA, GL_TRUE)) { + _mesa_error(ctx, GL_INVALID_ENUM, "glBlendEquationSeparatei(modeA)"); + return; + } + + if (ctx->Color.Blend[buf].EquationRGB == modeRGB && + ctx->Color.Blend[buf].EquationA == modeA) + return; /* no change */ + + FLUSH_VERTICES(ctx, _NEW_COLOR); + ctx->Color.Blend[buf].EquationRGB = modeRGB; + ctx->Color.Blend[buf].EquationA = modeA; + ctx->Color._BlendEquationPerBuffer = GL_TRUE; + + if (ctx->Driver.BlendEquationSeparatei) + ctx->Driver.BlendEquationSeparatei(ctx, buf, modeRGB, modeA); +} + + + +#endif /* _HAVE_FULL_GL */ /** @@ -364,6 +545,10 @@ _mesa_AlphaFunc( GLenum func, GLclampf ref ) GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glAlphaFunc(%s, %f)\n", + _mesa_lookup_enum_by_nr(func), ref); + switch (func) { case GL_NEVER: case GL_LESS: @@ -409,6 +594,9 @@ _mesa_LogicOp( GLenum opcode ) GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glLogicOp(%s)\n", _mesa_lookup_enum_by_nr(opcode)); + switch (opcode) { case GL_CLEAR: case GL_SET: @@ -483,7 +671,8 @@ _mesa_ColorMask( GLboolean red, GLboolean green, ASSERT_OUTSIDE_BEGIN_END(ctx); if (MESA_VERBOSE & VERBOSE_API) - _mesa_debug(ctx, "glColorMask %d %d %d %d\n", red, green, blue, alpha); + _mesa_debug(ctx, "glColorMask(%d, %d, %d, %d)\n", + red, green, blue, alpha); /* Shouldn't have any information about channel depth in core mesa * -- should probably store these as the native booleans: @@ -593,6 +782,8 @@ _mesa_ClampColorARB(GLenum target, GLenum clamp) */ void _mesa_init_color( struct gl_context * ctx ) { + GLuint i; + /* Color buffer group */ ctx->Color.IndexMask = ~0u; memset(ctx->Color.ColorMask, 0xff, sizeof(ctx->Color.ColorMask)); @@ -602,12 +793,14 @@ void _mesa_init_color( struct gl_context * ctx ) ctx->Color.AlphaFunc = GL_ALWAYS; ctx->Color.AlphaRef = 0; ctx->Color.BlendEnabled = 0x0; - ctx->Color.BlendSrcRGB = GL_ONE; - ctx->Color.BlendDstRGB = GL_ZERO; - ctx->Color.BlendSrcA = GL_ONE; - ctx->Color.BlendDstA = GL_ZERO; - ctx->Color.BlendEquationRGB = GL_FUNC_ADD; - ctx->Color.BlendEquationA = GL_FUNC_ADD; + for (i = 0; i < Elements(ctx->Color.Blend); i++) { + ctx->Color.Blend[i].SrcRGB = GL_ONE; + ctx->Color.Blend[i].DstRGB = GL_ZERO; + ctx->Color.Blend[i].SrcA = GL_ONE; + ctx->Color.Blend[i].DstA = GL_ZERO; + ctx->Color.Blend[i].EquationRGB = GL_FUNC_ADD; + ctx->Color.Blend[i].EquationA = GL_FUNC_ADD; + } ASSIGN_4V( ctx->Color.BlendColor, 0.0, 0.0, 0.0, 0.0 ); ctx->Color.IndexLogicOpEnabled = GL_FALSE; ctx->Color.ColorLogicOpEnabled = GL_FALSE; diff --git a/src/mesa/main/blend.h b/src/mesa/main/blend.h index f72c779f1a..39e7c9fd49 100644 --- a/src/mesa/main/blend.h +++ b/src/mesa/main/blend.h @@ -48,13 +48,30 @@ _mesa_BlendFuncSeparateEXT( GLenum sfactorRGB, GLenum dfactorRGB, extern void GLAPIENTRY +_mesa_BlendFunci(GLuint buf, GLenum sfactor, GLenum dfactor); + + +extern void GLAPIENTRY +_mesa_BlendFuncSeparatei(GLuint buf, GLenum sfactorRGB, GLenum dfactorRGB, + GLenum sfactorA, GLenum dfactorA); + + +extern void GLAPIENTRY _mesa_BlendEquation( GLenum mode ); extern void GLAPIENTRY +_mesa_BlendEquationi(GLuint buf, GLenum mode); + + +extern void GLAPIENTRY _mesa_BlendEquationSeparateEXT( GLenum modeRGB, GLenum modeA ); +extern void +_mesa_BlendEquationSeparatei(GLuint buf, GLenum modeRGB, GLenum modeA); + + extern void GLAPIENTRY _mesa_BlendColor(GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha); diff --git a/src/mesa/main/bufferobj.c b/src/mesa/main/bufferobj.c index 4d62f54a95..3343bb2f40 100644 --- a/src/mesa/main/bufferobj.c +++ b/src/mesa/main/bufferobj.c @@ -39,6 +39,8 @@ #include "context.h" #include "bufferobj.h" #include "fbobject.h" +#include "mfeatures.h" +#include "mtypes.h" #include "texobj.h" @@ -556,6 +558,7 @@ void _mesa_init_buffer_objects( struct gl_context *ctx ) { memset(&DummyBufferObject, 0, sizeof(DummyBufferObject)); + _glthread_INIT_MUTEX(DummyBufferObject.Mutex); DummyBufferObject.RefCount = 1000*1000*1000; /* never delete */ _mesa_reference_buffer_object(ctx, &ctx->Array.ArrayBufferObj, @@ -656,248 +659,6 @@ _mesa_update_default_objects_buffer_objects(struct gl_context *ctx) } -/** - * When we're about to read pixel data out of a PBO (via glDrawPixels, - * glTexImage, etc) or write data into a PBO (via glReadPixels, - * glGetTexImage, etc) we call this function to check that we're not - * going to read out of bounds. - * - * XXX This would also be a convenient time to check that the PBO isn't - * currently mapped. Whoever calls this function should check for that. - * Remember, we can't use a PBO when it's mapped! - * - * If we're not using a PBO, this is a no-op. - * - * \param width width of image to read/write - * \param height height of image to read/write - * \param depth depth of image to read/write - * \param format format of image to read/write - * \param type datatype of image to read/write - * \param ptr the user-provided pointer/offset - * \return GL_TRUE if the PBO access is OK, GL_FALSE if the access would - * go out of bounds. - */ -GLboolean -_mesa_validate_pbo_access(GLuint dimensions, - const struct gl_pixelstore_attrib *pack, - GLsizei width, GLsizei height, GLsizei depth, - GLenum format, GLenum type, const GLvoid *ptr) -{ - GLvoid *start, *end; - const GLubyte *sizeAddr; /* buffer size, cast to a pointer */ - - if (!_mesa_is_bufferobj(pack->BufferObj)) - return GL_TRUE; /* no PBO, OK */ - - if (pack->BufferObj->Size == 0) - /* no buffer! */ - return GL_FALSE; - - /* get address of first pixel we'll read */ - start = _mesa_image_address(dimensions, pack, ptr, width, height, - format, type, 0, 0, 0); - - /* get address just past the last pixel we'll read */ - end = _mesa_image_address(dimensions, pack, ptr, width, height, - format, type, depth-1, height-1, width); - - - sizeAddr = ((const GLubyte *) 0) + pack->BufferObj->Size; - - if ((const GLubyte *) start > sizeAddr) { - /* This will catch negative values / wrap-around */ - return GL_FALSE; - } - if ((const GLubyte *) end > sizeAddr) { - /* Image read goes beyond end of buffer */ - return GL_FALSE; - } - - /* OK! */ - return GL_TRUE; -} - - -/** - * For commands that read from a PBO (glDrawPixels, glTexImage, - * glPolygonStipple, etc), if we're reading from a PBO, map it read-only - * and return the pointer into the PBO. If we're not reading from a - * PBO, return \p src as-is. - * If non-null return, must call _mesa_unmap_pbo_source() when done. - * - * \return NULL if error, else pointer to start of data - */ -const GLvoid * -_mesa_map_pbo_source(struct gl_context *ctx, - const struct gl_pixelstore_attrib *unpack, - const GLvoid *src) -{ - const GLubyte *buf; - - if (_mesa_is_bufferobj(unpack->BufferObj)) { - /* unpack from PBO */ - buf = (GLubyte *) ctx->Driver.MapBuffer(ctx, GL_PIXEL_UNPACK_BUFFER_EXT, - GL_READ_ONLY_ARB, - unpack->BufferObj); - if (!buf) - return NULL; - - buf = ADD_POINTERS(buf, src); - } - else { - /* unpack from normal memory */ - buf = src; - } - - return buf; -} - - -/** - * Combine PBO-read validation and mapping. - * If any GL errors are detected, they'll be recorded and NULL returned. - * \sa _mesa_validate_pbo_access - * \sa _mesa_map_pbo_source - * A call to this function should have a matching call to - * _mesa_unmap_pbo_source(). - */ -const GLvoid * -_mesa_map_validate_pbo_source(struct gl_context *ctx, - GLuint dimensions, - const struct gl_pixelstore_attrib *unpack, - GLsizei width, GLsizei height, GLsizei depth, - GLenum format, GLenum type, const GLvoid *ptr, - const char *where) -{ - ASSERT(dimensions == 1 || dimensions == 2 || dimensions == 3); - - if (!_mesa_is_bufferobj(unpack->BufferObj)) { - /* non-PBO access: no validation to be done */ - return ptr; - } - - if (!_mesa_validate_pbo_access(dimensions, unpack, - width, height, depth, format, type, ptr)) { - _mesa_error(ctx, GL_INVALID_OPERATION, - "%s(out of bounds PBO access)", where); - return NULL; - } - - if (_mesa_bufferobj_mapped(unpack->BufferObj)) { - /* buffer is already mapped - that's an error */ - _mesa_error(ctx, GL_INVALID_OPERATION, "%s(PBO is mapped)", where); - return NULL; - } - - ptr = _mesa_map_pbo_source(ctx, unpack, ptr); - return ptr; -} - - -/** - * Counterpart to _mesa_map_pbo_source() - */ -void -_mesa_unmap_pbo_source(struct gl_context *ctx, - const struct gl_pixelstore_attrib *unpack) -{ - ASSERT(unpack != &ctx->Pack); /* catch pack/unpack mismatch */ - if (_mesa_is_bufferobj(unpack->BufferObj)) { - ctx->Driver.UnmapBuffer(ctx, GL_PIXEL_UNPACK_BUFFER_EXT, - unpack->BufferObj); - } -} - - -/** - * For commands that write to a PBO (glReadPixels, glGetColorTable, etc), - * if we're writing to a PBO, map it write-only and return the pointer - * into the PBO. If we're not writing to a PBO, return \p dst as-is. - * If non-null return, must call _mesa_unmap_pbo_dest() when done. - * - * \return NULL if error, else pointer to start of data - */ -void * -_mesa_map_pbo_dest(struct gl_context *ctx, - const struct gl_pixelstore_attrib *pack, - GLvoid *dest) -{ - void *buf; - - if (_mesa_is_bufferobj(pack->BufferObj)) { - /* pack into PBO */ - buf = (GLubyte *) ctx->Driver.MapBuffer(ctx, GL_PIXEL_PACK_BUFFER_EXT, - GL_WRITE_ONLY_ARB, - pack->BufferObj); - if (!buf) - return NULL; - - buf = ADD_POINTERS(buf, dest); - } - else { - /* pack to normal memory */ - buf = dest; - } - - return buf; -} - - -/** - * Combine PBO-write validation and mapping. - * If any GL errors are detected, they'll be recorded and NULL returned. - * \sa _mesa_validate_pbo_access - * \sa _mesa_map_pbo_dest - * A call to this function should have a matching call to - * _mesa_unmap_pbo_dest(). - */ -GLvoid * -_mesa_map_validate_pbo_dest(struct gl_context *ctx, - GLuint dimensions, - const struct gl_pixelstore_attrib *unpack, - GLsizei width, GLsizei height, GLsizei depth, - GLenum format, GLenum type, GLvoid *ptr, - const char *where) -{ - ASSERT(dimensions == 1 || dimensions == 2 || dimensions == 3); - - if (!_mesa_is_bufferobj(unpack->BufferObj)) { - /* non-PBO access: no validation to be done */ - return ptr; - } - - if (!_mesa_validate_pbo_access(dimensions, unpack, - width, height, depth, format, type, ptr)) { - _mesa_error(ctx, GL_INVALID_OPERATION, - "%s(out of bounds PBO access)", where); - return NULL; - } - - if (_mesa_bufferobj_mapped(unpack->BufferObj)) { - /* buffer is already mapped - that's an error */ - _mesa_error(ctx, GL_INVALID_OPERATION, "%s(PBO is mapped)", where); - return NULL; - } - - ptr = _mesa_map_pbo_dest(ctx, unpack, ptr); - return ptr; -} - - -/** - * Counterpart to _mesa_map_pbo_dest() - */ -void -_mesa_unmap_pbo_dest(struct gl_context *ctx, - const struct gl_pixelstore_attrib *pack) -{ - ASSERT(pack != &ctx->Unpack); /* catch pack/unpack mismatch */ - if (_mesa_is_bufferobj(pack->BufferObj)) { - ctx->Driver.UnmapBuffer(ctx, GL_PIXEL_PACK_BUFFER_EXT, pack->BufferObj); - } -} - - /** * Return the gl_buffer_object for the given ID. @@ -968,6 +729,10 @@ _mesa_BindBufferARB(GLenum target, GLuint buffer) GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glBindBuffer(%s, %u)\n", + _mesa_lookup_enum_by_nr(target), buffer); + bind_buffer_object(ctx, target, buffer); } @@ -984,6 +749,7 @@ _mesa_DeleteBuffersARB(GLsizei n, const GLuint *ids) GET_CURRENT_CONTEXT(ctx); GLsizei i; ASSERT_OUTSIDE_BEGIN_END(ctx); + FLUSH_VERTICES(ctx, 0); if (n < 0) { _mesa_error(ctx, GL_INVALID_VALUE, "glDeleteBuffersARB(n)"); @@ -1062,6 +828,9 @@ _mesa_GenBuffersARB(GLsizei n, GLuint *buffer) GLint i; ASSERT_OUTSIDE_BEGIN_END(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glGenBuffers(%d)\n", n); + if (n < 0) { _mesa_error(ctx, GL_INVALID_VALUE, "glGenBuffersARB"); return; @@ -1119,6 +888,12 @@ _mesa_BufferDataARB(GLenum target, GLsizeiptrARB size, struct gl_buffer_object *bufObj; ASSERT_OUTSIDE_BEGIN_END(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glBufferData(%s, %ld, %p, %s)\n", + _mesa_lookup_enum_by_nr(target), + (long int) size, data, + _mesa_lookup_enum_by_nr(usage)); + if (size < 0) { _mesa_error(ctx, GL_INVALID_VALUE, "glBufferDataARB(size < 0)"); return; diff --git a/src/mesa/main/bufferobj.h b/src/mesa/main/bufferobj.h index 4b97e34767..91fa073b64 100644 --- a/src/mesa/main/bufferobj.h +++ b/src/mesa/main/bufferobj.h @@ -29,6 +29,7 @@ #define BUFFEROBJ_H +#include "mfeatures.h" #include "mtypes.h" @@ -78,47 +79,6 @@ _mesa_reference_buffer_object(struct gl_context *ctx, struct gl_buffer_object **ptr, struct gl_buffer_object *bufObj); -extern GLboolean -_mesa_validate_pbo_access(GLuint dimensions, - const struct gl_pixelstore_attrib *pack, - GLsizei width, GLsizei height, GLsizei depth, - GLenum format, GLenum type, const GLvoid *ptr); - -extern const GLvoid * -_mesa_map_pbo_source(struct gl_context *ctx, - const struct gl_pixelstore_attrib *unpack, - const GLvoid *src); - -extern const GLvoid * -_mesa_map_validate_pbo_source(struct gl_context *ctx, - GLuint dimensions, - const struct gl_pixelstore_attrib *unpack, - GLsizei width, GLsizei height, GLsizei depth, - GLenum format, GLenum type, const GLvoid *ptr, - const char *where); - -extern void -_mesa_unmap_pbo_source(struct gl_context *ctx, - const struct gl_pixelstore_attrib *unpack); - -extern void * -_mesa_map_pbo_dest(struct gl_context *ctx, - const struct gl_pixelstore_attrib *pack, - GLvoid *dest); - -extern GLvoid * -_mesa_map_validate_pbo_dest(struct gl_context *ctx, - GLuint dimensions, - const struct gl_pixelstore_attrib *unpack, - GLsizei width, GLsizei height, GLsizei depth, - GLenum format, GLenum type, GLvoid *ptr, - const char *where); - -extern void -_mesa_unmap_pbo_dest(struct gl_context *ctx, - const struct gl_pixelstore_attrib *pack); - - extern void _mesa_init_buffer_object_functions(struct dd_function_table *driver); diff --git a/src/mesa/main/buffers.c b/src/mesa/main/buffers.c index 86446311fe..5c37f3d1a8 100644 --- a/src/mesa/main/buffers.c +++ b/src/mesa/main/buffers.c @@ -35,6 +35,7 @@ #include "colormac.h" #include "context.h" #include "enums.h" +#include "mtypes.h" #define BAD_MASK ~0u diff --git a/src/mesa/main/clear.c b/src/mesa/main/clear.c index c4c1d96e49..43a9ccc116 100644 --- a/src/mesa/main/clear.c +++ b/src/mesa/main/clear.c @@ -36,6 +36,7 @@ #include "colormac.h" #include "enums.h" #include "macros.h" +#include "mtypes.h" #include "state.h" diff --git a/src/mesa/main/colormac.h b/src/mesa/main/colormac.h index 245fb658bb..a328dcd32a 100644 --- a/src/mesa/main/colormac.h +++ b/src/mesa/main/colormac.h @@ -198,12 +198,23 @@ do { \ ((((B) & 0xf8) >> 1) | (((G) & 0xc0) >> 6) | (((G) & 0x38) << 10) | (((R) & 0xf8) << 5) | \ ((A) ? 0x80 : 0)) +#define PACK_COLOR_2101010_UB( A, B, G, R ) \ + (((B) << 22) | ((G) << 12) | ((R) << 2) | \ + (((A) & 0xc0) << 24)) + +#define PACK_COLOR_2101010_US( A, B, G, R ) \ + ((((B) >> 6) << 20) | (((G) >> 6) << 10) | ((R) >> 6) | \ + (((A) >> 14) << 30)) + #define PACK_COLOR_4444( R, G, B, A ) \ ((((R) & 0xf0) << 8) | (((G) & 0xf0) << 4) | ((B) & 0xf0) | ((A) >> 4)) #define PACK_COLOR_4444_REV( R, G, B, A ) \ ((((B) & 0xf0) << 8) | (((A) & 0xf0) << 4) | ((R) & 0xf0) | ((G) >> 4)) +#define PACK_COLOR_44( L, A ) \ + (((L) & 0xf0) | (((A) & 0xf0) >> 4)) + #define PACK_COLOR_88( L, A ) \ (((L) << 8) | (A)) diff --git a/src/mesa/main/colortab.c b/src/mesa/main/colortab.c index caa95835bc..d0c865735a 100644 --- a/src/mesa/main/colortab.c +++ b/src/mesa/main/colortab.c @@ -29,7 +29,10 @@ #include "context.h" #include "image.h" #include "macros.h" +#include "mfeatures.h" +#include "mtypes.h" #include "pack.h" +#include "pbo.h" #include "state.h" #include "teximage.h" #include "texstate.h" @@ -298,23 +301,6 @@ _mesa_ColorTable( GLenum target, GLenum internalFormat, case GL_SHARED_TEXTURE_PALETTE_EXT: table = &ctx->Texture.Palette; break; - case GL_TEXTURE_COLOR_TABLE_SGI: - if (!ctx->Extensions.SGI_texture_color_table) { - _mesa_error(ctx, GL_INVALID_ENUM, "glColorTable(target)"); - return; - } - table = &(texUnit->ColorTable); - scale = ctx->Pixel.TextureColorTableScale; - bias = ctx->Pixel.TextureColorTableBias; - break; - case GL_PROXY_TEXTURE_COLOR_TABLE_SGI: - if (!ctx->Extensions.SGI_texture_color_table) { - _mesa_error(ctx, GL_INVALID_ENUM, "glColorTable(target)"); - return; - } - table = &(texUnit->ProxyColorTable); - proxy = GL_TRUE; - break; default: /* try texture targets */ { @@ -433,15 +419,6 @@ _mesa_ColorSubTable( GLenum target, GLsizei start, case GL_SHARED_TEXTURE_PALETTE_EXT: table = &ctx->Texture.Palette; break; - case GL_TEXTURE_COLOR_TABLE_SGI: - if (!ctx->Extensions.SGI_texture_color_table) { - _mesa_error(ctx, GL_INVALID_ENUM, "glColorSubTable(target)"); - return; - } - table = &(texUnit->ColorTable); - scale = ctx->Pixel.TextureColorTableScale; - bias = ctx->Pixel.TextureColorTableBias; - break; default: /* try texture targets */ texObj = _mesa_select_tex_object(ctx, texUnit, target); @@ -549,13 +526,6 @@ _mesa_GetColorTable( GLenum target, GLenum format, case GL_SHARED_TEXTURE_PALETTE_EXT: table = &ctx->Texture.Palette; break; - case GL_TEXTURE_COLOR_TABLE_SGI: - if (!ctx->Extensions.SGI_texture_color_table) { - _mesa_error(ctx, GL_INVALID_ENUM, "glGetColorTable(target)"); - return; - } - table = &(texUnit->ColorTable); - break; default: /* try texture targets */ { @@ -659,32 +629,10 @@ _mesa_GetColorTable( GLenum target, GLenum format, static void GLAPIENTRY _mesa_ColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params) { - GLfloat *scale, *bias; + /* no extensions use this function */ GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END_AND_FLUSH(ctx); - - switch (target) { - case GL_TEXTURE_COLOR_TABLE_SGI: - scale = ctx->Pixel.TextureColorTableScale; - bias = ctx->Pixel.TextureColorTableBias; - break; - default: - _mesa_error(ctx, GL_INVALID_ENUM, "glColorTableParameter(target)"); - return; - } - - if (pname == GL_COLOR_TABLE_SCALE_SGI) { - COPY_4V(scale, params); - } - else if (pname == GL_COLOR_TABLE_BIAS_SGI) { - COPY_4V(bias, params); - } - else { - _mesa_error(ctx, GL_INVALID_ENUM, "glColorTableParameterfv(pname)"); - return; - } - - ctx->NewState |= _NEW_PIXEL; + _mesa_error(ctx, GL_INVALID_ENUM, "glColorTableParameterfv(target)"); } @@ -692,19 +640,10 @@ _mesa_ColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params) static void GLAPIENTRY _mesa_ColorTableParameteriv(GLenum target, GLenum pname, const GLint *params) { - GLfloat fparams[4]; - if (pname == GL_TEXTURE_COLOR_TABLE_SGI) { - /* four values */ - fparams[0] = (GLfloat) params[0]; - fparams[1] = (GLfloat) params[1]; - fparams[2] = (GLfloat) params[2]; - fparams[3] = (GLfloat) params[3]; - } - else { - /* one values */ - fparams[0] = (GLfloat) params[0]; - } - _mesa_ColorTableParameterfv(target, pname, fparams); + /* no extensions use this function */ + GET_CURRENT_CONTEXT(ctx); + ASSERT_OUTSIDE_BEGIN_END_AND_FLUSH(ctx); + _mesa_error(ctx, GL_INVALID_ENUM, "glColorTableParameteriv(target)"); } @@ -721,28 +660,6 @@ _mesa_GetColorTableParameterfv( GLenum target, GLenum pname, GLfloat *params ) case GL_SHARED_TEXTURE_PALETTE_EXT: table = &ctx->Texture.Palette; break; - case GL_TEXTURE_COLOR_TABLE_SGI: - if (!ctx->Extensions.SGI_texture_color_table) { - _mesa_error(ctx, GL_INVALID_ENUM, "glGetColorTableParameter(target)"); - return; - } - table = &(texUnit->ColorTable); - if (pname == GL_COLOR_TABLE_SCALE_SGI) { - COPY_4V(params, ctx->Pixel.TextureColorTableScale); - return; - } - else if (pname == GL_COLOR_TABLE_BIAS_SGI) { - COPY_4V(params, ctx->Pixel.TextureColorTableBias); - return; - } - break; - case GL_PROXY_TEXTURE_COLOR_TABLE_SGI: - if (!ctx->Extensions.SGI_texture_color_table) { - _mesa_error(ctx, GL_INVALID_ENUM, "glGetColorTableParameter(target)"); - return; - } - table = &(texUnit->ProxyColorTable); - break; default: /* try texture targets */ { @@ -806,34 +723,6 @@ _mesa_GetColorTableParameteriv( GLenum target, GLenum pname, GLint *params ) case GL_SHARED_TEXTURE_PALETTE_EXT: table = &ctx->Texture.Palette; break; - case GL_TEXTURE_COLOR_TABLE_SGI: - if (!ctx->Extensions.SGI_texture_color_table) { - _mesa_error(ctx, GL_INVALID_ENUM, "glGetColorTableParameter(target)"); - return; - } - table = &(texUnit->ColorTable); - if (pname == GL_COLOR_TABLE_SCALE_SGI) { - params[0] = (GLint) ctx->Pixel.TextureColorTableScale[0]; - params[1] = (GLint) ctx->Pixel.TextureColorTableScale[1]; - params[2] = (GLint) ctx->Pixel.TextureColorTableScale[2]; - params[3] = (GLint) ctx->Pixel.TextureColorTableScale[3]; - return; - } - else if (pname == GL_COLOR_TABLE_BIAS_SGI) { - params[0] = (GLint) ctx->Pixel.TextureColorTableBias[0]; - params[1] = (GLint) ctx->Pixel.TextureColorTableBias[1]; - params[2] = (GLint) ctx->Pixel.TextureColorTableBias[2]; - params[3] = (GLint) ctx->Pixel.TextureColorTableBias[3]; - return; - } - break; - case GL_PROXY_TEXTURE_COLOR_TABLE_SGI: - if (!ctx->Extensions.SGI_texture_color_table) { - _mesa_error(ctx, GL_INVALID_ENUM, "glGetColorTableParameter(target)"); - return; - } - table = &(texUnit->ProxyColorTable); - break; default: /* Try texture targets */ { diff --git a/src/mesa/main/condrender.c b/src/mesa/main/condrender.c index 25b3dd678d..352e2e2b16 100644 --- a/src/mesa/main/condrender.c +++ b/src/mesa/main/condrender.c @@ -34,6 +34,7 @@ #include "glheader.h" #include "condrender.h" #include "enums.h" +#include "mtypes.h" #include "queryobj.h" diff --git a/src/mesa/main/context.c b/src/mesa/main/context.c index f42a566c30..ca74284ca8 100644 --- a/src/mesa/main/context.c +++ b/src/mesa/main/context.c @@ -96,6 +96,7 @@ #include "fbobject.h" #include "feedback.h" #include "fog.h" +#include "formats.h" #include "framebuffer.h" #include "hint.h" #include "hash.h" @@ -417,6 +418,10 @@ one_time_init( struct gl_context *ctx ) MESA_VERSION_STRING, __DATE__, __TIME__); } #endif + +#ifdef DEBUG + _mesa_test_formats(); +#endif } /* per-API one-time init */ @@ -481,30 +486,26 @@ init_program_limits(GLenum type, struct gl_program_constants *prog) prog->MaxTemps = MAX_PROGRAM_TEMPS; prog->MaxEnvParams = MAX_PROGRAM_ENV_PARAMS; prog->MaxLocalParams = MAX_PROGRAM_LOCAL_PARAMS; - prog->MaxUniformComponents = 4 * MAX_UNIFORMS; + prog->MaxAddressOffset = MAX_PROGRAM_LOCAL_PARAMS; switch (type) { case GL_VERTEX_PROGRAM_ARB: prog->MaxParameters = MAX_VERTEX_PROGRAM_PARAMS; prog->MaxAttribs = MAX_NV_VERTEX_PROGRAM_INPUTS; prog->MaxAddressRegs = MAX_VERTEX_PROGRAM_ADDRESS_REGS; + prog->MaxUniformComponents = 4 * MAX_UNIFORMS; break; case GL_FRAGMENT_PROGRAM_ARB: prog->MaxParameters = MAX_NV_FRAGMENT_PROGRAM_PARAMS; prog->MaxAttribs = MAX_NV_FRAGMENT_PROGRAM_INPUTS; prog->MaxAddressRegs = MAX_FRAGMENT_PROGRAM_ADDRESS_REGS; + prog->MaxUniformComponents = 4 * MAX_UNIFORMS; break; case MESA_GEOMETRY_PROGRAM: prog->MaxParameters = MAX_NV_VERTEX_PROGRAM_PARAMS; prog->MaxAttribs = MAX_NV_VERTEX_PROGRAM_INPUTS; prog->MaxAddressRegs = MAX_VERTEX_PROGRAM_ADDRESS_REGS; - - prog->MaxGeometryTextureImageUnits = MAX_GEOMETRY_TEXTURE_IMAGE_UNITS; - prog->MaxGeometryVaryingComponents = MAX_GEOMETRY_VARYING_COMPONENTS; - prog->MaxVertexVaryingComponents = MAX_VERTEX_VARYING_COMPONENTS; - prog->MaxGeometryUniformComponents = MAX_GEOMETRY_UNIFORM_COMPONENTS; - prog->MaxGeometryOutputVertices = MAX_GEOMETRY_OUTPUT_VERTICES; - prog->MaxGeometryTotalOutputComponents = MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS; + prog->MaxUniformComponents = MAX_GEOMETRY_UNIFORM_COMPONENTS; break; default: assert(0 && "Bad program type in init_program_limits()"); @@ -521,6 +522,25 @@ init_program_limits(GLenum type, struct gl_program_constants *prog) prog->MaxNativeTemps = 0; prog->MaxNativeAddressRegs = 0; prog->MaxNativeParameters = 0; + + /* Set GLSL datatype range/precision info assuming IEEE float values. + * Drivers should override these defaults as needed. + */ + prog->MediumFloat.RangeMin = 127; + prog->MediumFloat.RangeMax = 127; + prog->MediumFloat.Precision = 23; + prog->LowFloat = prog->HighFloat = prog->MediumFloat; + + /* Assume ints are stored as floats for now, since this is the least-common + * denominator. The OpenGL ES spec implies (page 132) that the precision + * of integer types should be 0. Practically speaking, IEEE + * single-precision floating point values can only store integers in the + * range [-0x01000000, 0x01000000] without loss of precision. + */ + prog->MediumInt.RangeMin = 24; + prog->MediumInt.RangeMax = 24; + prog->MediumInt.Precision = 0; + prog->LowInt = prog->HighInt = prog->MediumInt; } @@ -594,6 +614,13 @@ _mesa_init_constants(struct gl_context *ctx) ctx->Const.MaxCombinedTextureImageUnits = MAX_COMBINED_TEXTURE_IMAGE_UNITS; ctx->Const.MaxVarying = MAX_VARYING; #endif +#if FEATURE_ARB_geometry_shader4 + ctx->Const.MaxGeometryTextureImageUnits = MAX_GEOMETRY_TEXTURE_IMAGE_UNITS; + ctx->Const.MaxVertexVaryingComponents = MAX_VERTEX_VARYING_COMPONENTS; + ctx->Const.MaxGeometryVaryingComponents = MAX_GEOMETRY_VARYING_COMPONENTS; + ctx->Const.MaxGeometryOutputVertices = MAX_GEOMETRY_OUTPUT_VERTICES; + ctx->Const.MaxGeometryTotalOutputComponents = MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS; +#endif /* Shading language version */ if (ctx->API == API_OPENGL) { @@ -862,12 +889,12 @@ _mesa_alloc_dispatch_table(int size) * \param driverContext pointer to driver-specific context data */ GLboolean -_mesa_initialize_context_for_api(struct gl_context *ctx, - gl_api api, - const struct gl_config *visual, - struct gl_context *share_list, - const struct dd_function_table *driverFunctions, - void *driverContext) +_mesa_initialize_context(struct gl_context *ctx, + gl_api api, + const struct gl_config *visual, + struct gl_context *share_list, + const struct dd_function_table *driverFunctions, + void *driverContext) { struct gl_shared_state *shared; int i; @@ -955,6 +982,14 @@ _mesa_initialize_context_for_api(struct gl_context *ctx, ctx->FragmentProgram._MaintainTexEnvProgram = GL_TRUE; } + /* Mesa core handles all the formats that mesa core knows about. + * Drivers will want to override this list with just the formats + * they can handle, and confirm that appropriate fallbacks exist in + * _mesa_choose_tex_format(). + */ + memset(&ctx->TextureFormatSupported, GL_TRUE, + sizeof(ctx->TextureFormatSupported)); + switch (ctx->API) { case API_OPENGL: #if FEATURE_dlist @@ -997,25 +1032,6 @@ _mesa_initialize_context_for_api(struct gl_context *ctx, /** - * Initialize an OpenGL context. - */ -GLboolean -_mesa_initialize_context(struct gl_context *ctx, - const struct gl_config *visual, - struct gl_context *share_list, - const struct dd_function_table *driverFunctions, - void *driverContext) -{ - return _mesa_initialize_context_for_api(ctx, - API_OPENGL, - visual, - share_list, - driverFunctions, - driverContext); -} - - -/** * Allocate and initialize a struct gl_context structure. * Note that the driver needs to pass in its dd_function_table here since * we need to at least call driverFunctions->NewTextureObject to initialize @@ -1031,11 +1047,11 @@ _mesa_initialize_context(struct gl_context *ctx, * \return pointer to a new __struct gl_contextRec or NULL if error. */ struct gl_context * -_mesa_create_context_for_api(gl_api api, - const struct gl_config *visual, - struct gl_context *share_list, - const struct dd_function_table *driverFunctions, - void *driverContext) +_mesa_create_context(gl_api api, + const struct gl_config *visual, + struct gl_context *share_list, + const struct dd_function_table *driverFunctions, + void *driverContext) { struct gl_context *ctx; @@ -1046,8 +1062,8 @@ _mesa_create_context_for_api(gl_api api, if (!ctx) return NULL; - if (_mesa_initialize_context_for_api(ctx, api, visual, share_list, - driverFunctions, driverContext)) { + if (_mesa_initialize_context(ctx, api, visual, share_list, + driverFunctions, driverContext)) { return ctx; } else { @@ -1058,22 +1074,6 @@ _mesa_create_context_for_api(gl_api api, /** - * Create an OpenGL context. - */ -struct gl_context * -_mesa_create_context(const struct gl_config *visual, - struct gl_context *share_list, - const struct dd_function_table *driverFunctions, - void *driverContext) -{ - return _mesa_create_context_for_api(API_OPENGL, visual, - share_list, - driverFunctions, - driverContext); -} - - -/** * Free the data associated with the given context. * * But doesn't free the struct gl_context struct itself. diff --git a/src/mesa/main/context.h b/src/mesa/main/context.h index 42d98a33a8..33a36311c8 100644 --- a/src/mesa/main/context.h +++ b/src/mesa/main/context.h @@ -99,33 +99,20 @@ _mesa_destroy_visual( struct gl_config *vis ); /** \name Context-related functions */ /*@{*/ -extern struct gl_context * -_mesa_create_context( const struct gl_config *visual, - struct gl_context *share_list, - const struct dd_function_table *driverFunctions, - void *driverContext ); - extern GLboolean _mesa_initialize_context( struct gl_context *ctx, + gl_api api, const struct gl_config *visual, struct gl_context *share_list, const struct dd_function_table *driverFunctions, void *driverContext ); extern struct gl_context * -_mesa_create_context_for_api(gl_api api, - const struct gl_config *visual, - struct gl_context *share_list, - const struct dd_function_table *driverFunctions, - void *driverContext); - -extern GLboolean -_mesa_initialize_context_for_api(struct gl_context *ctx, - gl_api api, - const struct gl_config *visual, - struct gl_context *share_list, - const struct dd_function_table *driverFunctions, - void *driverContext); +_mesa_create_context(gl_api api, + const struct gl_config *visual, + struct gl_context *share_list, + const struct dd_function_table *driverFunctions, + void *driverContext); extern void _mesa_free_context_data( struct gl_context *ctx ); @@ -299,28 +286,4 @@ do { \ -/** - * Is the secondary color needed? - */ -#define NEED_SECONDARY_COLOR(CTX) \ - (((CTX)->Light.Enabled && \ - (CTX)->Light.Model.ColorControl == GL_SEPARATE_SPECULAR_COLOR) \ - || (CTX)->Fog.ColorSumEnabled \ - || ((CTX)->VertexProgram._Current && \ - ((CTX)->VertexProgram._Current != (CTX)->VertexProgram._TnlProgram) && \ - ((CTX)->VertexProgram._Current->Base.InputsRead & VERT_BIT_COLOR1)) \ - || ((CTX)->FragmentProgram._Current && \ - ((CTX)->FragmentProgram._Current != (CTX)->FragmentProgram._TexEnvProgram) && \ - ((CTX)->FragmentProgram._Current->Base.InputsRead & FRAG_BIT_COL1)) \ - ) - - -/** - * Is RGBA LogicOp enabled? - */ -#define RGBA_LOGICOP_ENABLED(CTX) \ - ((CTX)->Color.ColorLogicOpEnabled || \ - ((CTX)->Color.BlendEnabled && (CTX)->Color.BlendEquationRGB == GL_LOGIC_OP)) - - #endif /* CONTEXT_H */ diff --git a/src/mesa/main/convolve.c b/src/mesa/main/convolve.c index 0231bcf6d3..5d286eb316 100644 --- a/src/mesa/main/convolve.c +++ b/src/mesa/main/convolve.c @@ -36,6 +36,7 @@ #include "colormac.h" #include "convolve.h" #include "macros.h" +#include "mfeatures.h" #include "mtypes.h" #include "main/dispatch.h" diff --git a/src/mesa/main/cpuinfo.c b/src/mesa/main/cpuinfo.c index 35de69b180..6363512961 100644 --- a/src/mesa/main/cpuinfo.c +++ b/src/mesa/main/cpuinfo.c @@ -23,7 +23,7 @@ */ -#include "main/imports.h" +#include "main/compiler.h" #include "main/cpuinfo.h" diff --git a/src/mesa/main/dd.h b/src/mesa/main/dd.h index c62969e9b7..0947672a08 100644 --- a/src/mesa/main/dd.h +++ b/src/mesa/main/dd.h @@ -635,10 +635,15 @@ struct dd_function_table { void (*BlendColor)(struct gl_context *ctx, const GLfloat color[4]); /** Set the blend equation */ void (*BlendEquationSeparate)(struct gl_context *ctx, GLenum modeRGB, GLenum modeA); + void (*BlendEquationSeparatei)(struct gl_context *ctx, GLuint buffer, + GLenum modeRGB, GLenum modeA); /** Specify pixel arithmetic */ void (*BlendFuncSeparate)(struct gl_context *ctx, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorA, GLenum dfactorA); + void (*BlendFuncSeparatei)(struct gl_context *ctx, GLuint buffer, + GLenum sfactorRGB, GLenum dfactorRGB, + GLenum sfactorA, GLenum dfactorA); /** Specify clear values for the color buffers */ void (*ClearColor)(struct gl_context *ctx, const GLfloat color[4]); /** Specify the clear value for the depth buffer */ @@ -876,11 +881,6 @@ struct dd_function_table { */ void (*ValidateTnlModule)( struct gl_context *ctx, GLuint new_state ); - -#define PRIM_OUTSIDE_BEGIN_END (GL_POLYGON+1) -#define PRIM_INSIDE_UNKNOWN_PRIM (GL_POLYGON+2) -#define PRIM_UNKNOWN (GL_POLYGON+3) - /** * Set by the driver-supplied T&L engine. * @@ -1025,6 +1025,11 @@ struct dd_function_table { struct gl_transform_feedback_object *obj); void (*DrawTransformFeedback)(struct gl_context *ctx, GLenum mode, struct gl_transform_feedback_object *obj); + + /** + * \name GL_NV_texture_barrier interface + */ + void (*TextureBarrier)(struct gl_context *ctx); }; diff --git a/src/mesa/main/debug.c b/src/mesa/main/debug.c index 79aa53585f..78881668e4 100644 --- a/src/mesa/main/debug.c +++ b/src/mesa/main/debug.c @@ -37,26 +37,6 @@ #include "texobj.h" -/** - * Primitive names - */ -const char *_mesa_prim_name[GL_POLYGON+4] = { - "GL_POINTS", - "GL_LINES", - "GL_LINE_LOOP", - "GL_LINE_STRIP", - "GL_TRIANGLES", - "GL_TRIANGLE_STRIP", - "GL_TRIANGLE_FAN", - "GL_QUADS", - "GL_QUAD_STRIP", - "GL_POLYGON", - "outside begin/end", - "inside unknown primitive", - "unknown state" -}; - - static const char * tex_target_name(GLenum tgt) { @@ -85,13 +65,12 @@ void _mesa_print_state( const char *msg, GLuint state ) { _mesa_debug(NULL, - "%s: (0x%x) %s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s\n", + "%s: (0x%x) %s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s\n", msg, state, (state & _NEW_MODELVIEW) ? "ctx->ModelView, " : "", (state & _NEW_PROJECTION) ? "ctx->Projection, " : "", (state & _NEW_TEXTURE_MATRIX) ? "ctx->TextureMatrix, " : "", - (state & _NEW_ACCUM) ? "ctx->Accum, " : "", (state & _NEW_COLOR) ? "ctx->Color, " : "", (state & _NEW_DEPTH) ? "ctx->Depth, " : "", (state & _NEW_EVAL) ? "ctx->Eval/EvalMap, " : "", @@ -234,16 +213,6 @@ void _mesa_init_debug( struct gl_context *ctx ) { char *c; - - /* Dither disable */ - ctx->NoDither = _mesa_getenv("MESA_NO_DITHER") ? GL_TRUE : GL_FALSE; - if (ctx->NoDither) { - if (_mesa_getenv("MESA_DEBUG")) { - _mesa_debug(ctx, "MESA_NO_DITHER set - dithering disabled\n"); - } - ctx->Color.DitherFlag = GL_FALSE; - } - c = _mesa_getenv("MESA_DEBUG"); if (c) add_debug_flags(c); @@ -327,8 +296,8 @@ write_texture_image(struct gl_texture_object *texObj, /** * Write renderbuffer image to a ppm file. */ -static void -write_renderbuffer_image(const struct gl_renderbuffer *rb) +void +_mesa_write_renderbuffer_image(const struct gl_renderbuffer *rb) { GET_CURRENT_CONTEXT(ctx); GLubyte *buffer; @@ -345,6 +314,10 @@ write_renderbuffer_image(const struct gl_renderbuffer *rb) type = GL_UNSIGNED_INT_24_8; } else { + _mesa_debug(NULL, + "Unsupported BaseFormat 0x%x in " + "_mesa_write_renderbuffer_image()\n", + rb->_BaseFormat); return; } @@ -355,8 +328,12 @@ write_renderbuffer_image(const struct gl_renderbuffer *rb) /* make filename */ _mesa_snprintf(s, sizeof(s), "/tmp/renderbuffer%u.ppm", rb->Name); + _mesa_snprintf(s, sizeof(s), "C:\\renderbuffer%u.ppm", rb->Name); printf(" Writing renderbuffer image to %s\n", s); + + _mesa_debug(NULL, " Writing renderbuffer image to %s\n", s); + write_ppm(s, buffer, rb->Width, rb->Height, 4, 0, 1, 2, GL_TRUE); free(buffer); @@ -443,7 +420,7 @@ dump_renderbuffer(const struct gl_renderbuffer *rb, GLboolean writeImage) rb->Name, rb->Width, rb->Height, _mesa_lookup_enum_by_nr(rb->InternalFormat)); if (writeImage) { - write_renderbuffer_image(rb); + _mesa_write_renderbuffer_image(rb); } } diff --git a/src/mesa/main/debug.h b/src/mesa/main/debug.h index 17aa897e8d..4968a9f197 100644 --- a/src/mesa/main/debug.h +++ b/src/mesa/main/debug.h @@ -64,6 +64,9 @@ extern void _mesa_init_debug( struct gl_context *ctx ); #endif extern void +_mesa_write_renderbuffer_image(const struct gl_renderbuffer *rb); + +extern void _mesa_dump_texture(GLuint texture, GLuint writeImages); extern void diff --git a/src/mesa/main/depth.c b/src/mesa/main/depth.c index c5a910e144..52c69a6bcd 100644 --- a/src/mesa/main/depth.c +++ b/src/mesa/main/depth.c @@ -44,6 +44,9 @@ _mesa_ClearDepth( GLclampd depth ) GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glClearDepth(%f)\n", depth); + depth = CLAMP( depth, 0.0, 1.0 ); if (ctx->Depth.Clear == depth) @@ -56,6 +59,12 @@ _mesa_ClearDepth( GLclampd depth ) } +void GLAPIENTRY +_mesa_ClearDepthf( GLclampf depth ) +{ + _mesa_ClearDepth(depth); +} + void GLAPIENTRY _mesa_DepthFunc( GLenum func ) @@ -127,6 +136,9 @@ _mesa_DepthBoundsEXT( GLclampd zmin, GLclampd zmax ) GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glDepthBounds(%f, %f)\n", zmin, zmax); + if (zmin > zmax) { _mesa_error(ctx, GL_INVALID_VALUE, "glDepthBoundsEXT(zmin > zmax)"); return; diff --git a/src/mesa/main/depth.h b/src/mesa/main/depth.h index b498a47153..2f428629f9 100644 --- a/src/mesa/main/depth.h +++ b/src/mesa/main/depth.h @@ -44,6 +44,9 @@ extern void GLAPIENTRY _mesa_ClearDepth( GLclampd depth ); extern void GLAPIENTRY +_mesa_ClearDepthf( GLclampf depth ); + +extern void GLAPIENTRY _mesa_DepthFunc( GLenum func ); extern void GLAPIENTRY diff --git a/src/mesa/main/dlist.c b/src/mesa/main/dlist.c index 6c0c556ad8..0112d9dde3 100644 --- a/src/mesa/main/dlist.c +++ b/src/mesa/main/dlist.c @@ -54,6 +54,7 @@ #include "light.h" #include "macros.h" #include "pack.h" +#include "pbo.h" #include "queryobj.h" #include "teximage.h" #include "mtypes.h" @@ -188,6 +189,12 @@ typedef enum OPCODE_BLEND_EQUATION, OPCODE_BLEND_EQUATION_SEPARATE, OPCODE_BLEND_FUNC_SEPARATE, + + OPCODE_BLEND_EQUATION_I, + OPCODE_BLEND_EQUATION_SEPARATE_I, + OPCODE_BLEND_FUNC_I, + OPCODE_BLEND_FUNC_SEPARATE_I, + OPCODE_CALL_LIST, OPCODE_CALL_LIST_OFFSET, OPCODE_CLEAR, @@ -421,6 +428,12 @@ typedef enum OPCODE_ACTIVE_PROGRAM_EXT, OPCODE_USE_SHADER_PROGRAM_EXT, + /* GL_ARB_instanced_arrays */ + OPCODE_VERTEX_ATTRIB_DIVISOR, + + /* GL_NV_texture_barrier */ + OPCODE_TEXTURE_BARRIER_NV, + /* The following three are meta instructions */ OPCODE_ERROR, /* raise compiled-in error */ OPCODE_CONTINUE, @@ -1143,6 +1156,82 @@ save_BlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha) } } +/* GL_ARB_draw_buffers_blend */ +static void GLAPIENTRY +save_BlendFuncSeparatei(GLuint buf, GLenum sfactorRGB, GLenum dfactorRGB, + GLenum sfactorA, GLenum dfactorA) +{ + GET_CURRENT_CONTEXT(ctx); + Node *n; + ASSERT_OUTSIDE_SAVE_BEGIN_END_AND_FLUSH(ctx); + n = alloc_instruction(ctx, OPCODE_BLEND_FUNC_SEPARATE_I, 5); + if (n) { + n[1].ui = buf; + n[2].e = sfactorRGB; + n[3].e = dfactorRGB; + n[4].e = sfactorA; + n[5].e = dfactorA; + } + if (ctx->ExecuteFlag) { + CALL_BlendFuncSeparateiARB(ctx->Exec, (buf, sfactorRGB, dfactorRGB, + sfactorA, dfactorA)); + } +} + +/* GL_ARB_draw_buffers_blend */ +static void GLAPIENTRY +save_BlendFunci(GLuint buf, GLenum sfactor, GLenum dfactor) +{ + GET_CURRENT_CONTEXT(ctx); + Node *n; + ASSERT_OUTSIDE_SAVE_BEGIN_END_AND_FLUSH(ctx); + n = alloc_instruction(ctx, OPCODE_BLEND_FUNC_SEPARATE_I, 3); + if (n) { + n[1].ui = buf; + n[2].e = sfactor; + n[3].e = dfactor; + } + if (ctx->ExecuteFlag) { + CALL_BlendFunciARB(ctx->Exec, (buf, sfactor, dfactor)); + } +} + +/* GL_ARB_draw_buffers_blend */ +static void GLAPIENTRY +save_BlendEquationi(GLuint buf, GLenum mode) +{ + GET_CURRENT_CONTEXT(ctx); + Node *n; + ASSERT_OUTSIDE_SAVE_BEGIN_END_AND_FLUSH(ctx); + n = alloc_instruction(ctx, OPCODE_BLEND_EQUATION_I, 2); + if (n) { + n[1].ui = buf; + n[2].e = mode; + } + if (ctx->ExecuteFlag) { + CALL_BlendEquationiARB(ctx->Exec, (buf, mode)); + } +} + +/* GL_ARB_draw_buffers_blend */ +static void GLAPIENTRY +save_BlendEquationSeparatei(GLuint buf, GLenum modeRGB, GLenum modeA) +{ + GET_CURRENT_CONTEXT(ctx); + Node *n; + ASSERT_OUTSIDE_SAVE_BEGIN_END_AND_FLUSH(ctx); + n = alloc_instruction(ctx, OPCODE_BLEND_EQUATION_SEPARATE_I, 3); + if (n) { + n[1].ui = buf; + n[2].e = modeRGB; + n[3].e = modeA; + } + if (ctx->ExecuteFlag) { + CALL_BlendEquationSeparateiARB(ctx->Exec, (buf, modeRGB, modeA)); + } +} + + static void invalidate_saved_current_state( struct gl_context *ctx ) { GLint i; @@ -6927,8 +7016,36 @@ exec_GetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params) } +/* GL_ARB_instanced_arrays */ +static void +save_VertexAttribDivisor(GLuint index, GLuint divisor) +{ + GET_CURRENT_CONTEXT(ctx); + Node *n; + ASSERT_OUTSIDE_SAVE_BEGIN_END_AND_FLUSH(ctx); + n = alloc_instruction(ctx, OPCODE_VERTEX_ATTRIB_DIVISOR, 2); + if (n) { + n[1].ui = index; + n[2].ui = divisor; + } + if (ctx->ExecuteFlag) { + CALL_VertexAttribDivisorARB(ctx->Exec, (index, divisor)); + } +} +/* GL_NV_texture_barrier */ +static void +save_TextureBarrierNV() +{ + GET_CURRENT_CONTEXT(ctx); + ASSERT_OUTSIDE_SAVE_BEGIN_END_AND_FLUSH(ctx); + alloc_instruction(ctx, OPCODE_TEXTURE_BARRIER_NV, 0); + if (ctx->ExecuteFlag) { + CALL_TextureBarrierNV(ctx->Exec, ()); + } +} + /** * Save an error-generating command into display list. @@ -7058,6 +7175,26 @@ execute_list(struct gl_context *ctx, GLuint list) CALL_BlendFuncSeparateEXT(ctx->Exec, (n[1].e, n[2].e, n[3].e, n[4].e)); break; + + case OPCODE_BLEND_FUNC_I: + /* GL_ARB_draw_buffers_blend */ + CALL_BlendFunciARB(ctx->Exec, (n[1].ui, n[2].e, n[3].e)); + break; + case OPCODE_BLEND_FUNC_SEPARATE_I: + /* GL_ARB_draw_buffers_blend */ + CALL_BlendFuncSeparateiARB(ctx->Exec, (n[1].ui, n[2].e, n[3].e, + n[4].e, n[5].e)); + break; + case OPCODE_BLEND_EQUATION_I: + /* GL_ARB_draw_buffers_blend */ + CALL_BlendEquationiARB(ctx->Exec, (n[1].ui, n[2].e)); + break; + case OPCODE_BLEND_EQUATION_SEPARATE_I: + /* GL_ARB_draw_buffers_blend */ + CALL_BlendEquationSeparateiARB(ctx->Exec, + (n[1].ui, n[2].e, n[3].e)); + break; + case OPCODE_CALL_LIST: /* Generated by glCallList(), don't add ListBase */ if (ctx->ListState.CallDepth < MAX_LIST_NESTING) { @@ -8080,6 +8217,15 @@ execute_list(struct gl_context *ctx, GLuint list) } break; + case OPCODE_VERTEX_ATTRIB_DIVISOR: + /* GL_ARB_instanced_arrays */ + CALL_VertexAttribDivisorARB(ctx->Exec, (n[1].ui, n[2].ui)); + break; + + case OPCODE_TEXTURE_BARRIER_NV: + CALL_TextureBarrierNV(ctx->Exec, ()); + break; + case OPCODE_CONTINUE: n = (Node *) n[1].next; break; @@ -8293,8 +8439,6 @@ _mesa_CallList(GLuint list) GLboolean save_compile_flag; GET_CURRENT_CONTEXT(ctx); FLUSH_CURRENT(ctx, 0); - /* VERY IMPORTANT: Save the CompileFlag status, turn it off, */ - /* execute the display list, and restore the CompileFlag. */ if (MESA_VERBOSE & VERBOSE_API) _mesa_debug(ctx, "glCallList %d\n", list); @@ -8304,8 +8448,12 @@ _mesa_CallList(GLuint list) return; } -/* mesa_print_display_list( list ); */ + if (0) + mesa_print_display_list( list ); + /* VERY IMPORTANT: Save the CompileFlag status, turn it off, + * execute the display list, and restore the CompileFlag. + */ save_compile_flag = ctx->CompileFlag; if (save_compile_flag) { ctx->CompileFlag = GL_FALSE; @@ -9749,6 +9897,18 @@ _mesa_create_save_table(void) (void) save_Uniform4uiv; #endif + /* GL_ARB_instanced_arrays */ + SET_VertexAttribDivisorARB(table, save_VertexAttribDivisor); + + /* GL_NV_texture_barrier */ + SET_TextureBarrierNV(table, save_TextureBarrierNV); + + /* GL_ARB_draw_buffer_blend */ + SET_BlendFunciARB(table, save_BlendFunci); + SET_BlendFuncSeparateiARB(table, save_BlendFuncSeparatei); + SET_BlendEquationiARB(table, save_BlendEquationi); + SET_BlendEquationSeparateiARB(table, save_BlendEquationSeparatei); + return table; } diff --git a/src/mesa/main/dlist.h b/src/mesa/main/dlist.h index 24241a4bd4..160ed62f55 100644 --- a/src/mesa/main/dlist.h +++ b/src/mesa/main/dlist.h @@ -33,6 +33,7 @@ #define DLIST_H +#include "main/mfeatures.h" #include "main/mtypes.h" diff --git a/src/mesa/main/drawpix.c b/src/mesa/main/drawpix.c index 757aae6e70..fb86036a18 100644 --- a/src/mesa/main/drawpix.c +++ b/src/mesa/main/drawpix.c @@ -30,6 +30,8 @@ #include "enums.h" #include "feedback.h" #include "framebuffer.h" +#include "mfeatures.h" +#include "pbo.h" #include "readpix.h" #include "state.h" #include "dispatch.h" @@ -48,6 +50,17 @@ _mesa_DrawPixels( GLsizei width, GLsizei height, GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END_AND_FLUSH(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glDrawPixels(%d, %d, %s, %s, %p) // to %s at %d, %d\n", + width, height, + _mesa_lookup_enum_by_nr(format), + _mesa_lookup_enum_by_nr(type), + pixels, + _mesa_lookup_enum_by_nr(ctx->DrawBuffer->ColorDrawBuffer[0]), + IROUND(ctx->Current.RasterPos[0]), + IROUND(ctx->Current.RasterPos[1])); + + if (width < 0 || height < 0) { _mesa_error( ctx, GL_INVALID_VALUE, "glDrawPixels(width or height < 0" ); return; @@ -123,6 +136,16 @@ _mesa_CopyPixels( GLint srcx, GLint srcy, GLsizei width, GLsizei height, GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END_AND_FLUSH(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, + "glCopyPixels(%d, %d, %d, %d, %s) // from %s to %s at %d, %d\n", + srcx, srcy, width, height, + _mesa_lookup_enum_by_nr(type), + _mesa_lookup_enum_by_nr(ctx->ReadBuffer->ColorReadBuffer), + _mesa_lookup_enum_by_nr(ctx->DrawBuffer->ColorDrawBuffer[0]), + IROUND(ctx->Current.RasterPos[0]), + IROUND(ctx->Current.RasterPos[1])); + if (width < 0 || height < 0) { _mesa_error(ctx, GL_INVALID_VALUE, "glCopyPixels(width or height < 0)"); return; diff --git a/src/mesa/main/drawtex.c b/src/mesa/main/drawtex.c index b9afc9974e..83485a928d 100644 --- a/src/mesa/main/drawtex.c +++ b/src/mesa/main/drawtex.c @@ -24,6 +24,8 @@ #include "main/drawtex.h" #include "main/state.h" #include "main/imports.h" +#include "main/mfeatures.h" +#include "main/mtypes.h" #if FEATURE_OES_draw_texture @@ -43,11 +45,15 @@ draw_texture(struct gl_context *ctx, GLfloat x, GLfloat y, GLfloat z, return; } + _mesa_set_vp_override(ctx, GL_TRUE); + if (ctx->NewState) _mesa_update_state(ctx); ASSERT(ctx->Driver.DrawTex); ctx->Driver.DrawTex(ctx, x, y, z, width, height); + + _mesa_set_vp_override(ctx, GL_FALSE); } diff --git a/src/mesa/main/enable.c b/src/mesa/main/enable.c index a038a95c55..f247092410 100644 --- a/src/mesa/main/enable.c +++ b/src/mesa/main/enable.c @@ -33,6 +33,7 @@ #include "enable.h" #include "light.h" #include "simple_list.h" +#include "mfeatures.h" #include "mtypes.h" #include "enums.h" #include "api_arrayelt.h" @@ -351,9 +352,6 @@ _mesa_set_enable(struct gl_context *ctx, GLenum cap, GLboolean state) ctx->Depth.Test = state; break; case GL_DITHER: - if (ctx->NoDither) { - state = GL_FALSE; /* MESA_NO_DITHER env var */ - } if (ctx->Color.DitherFlag == state) return; FLUSH_VERTICES(ctx, _NEW_COLOR); @@ -705,15 +703,6 @@ _mesa_set_enable(struct gl_context *ctx, GLenum cap, GLboolean state) client_state( ctx, cap, state ); return; - /* GL_SGI_texture_color_table */ - case GL_TEXTURE_COLOR_TABLE_SGI: - CHECK_EXTENSION(SGI_texture_color_table, cap); - if (ctx->Texture.Unit[ctx->Texture.CurrentUnit].ColorTableEnabled == state) - return; - FLUSH_VERTICES(ctx, _NEW_TEXTURE); - ctx->Texture.Unit[ctx->Texture.CurrentUnit].ColorTableEnabled = state; - break; - /* GL_ARB_texture_cube_map */ case GL_TEXTURE_CUBE_MAP_ARB: CHECK_EXTENSION(ARB_texture_cube_map, cap); @@ -967,6 +956,13 @@ _mesa_set_enable(struct gl_context *ctx, GLenum cap, GLboolean state) } break; + /* GL3.0 - GL_framebuffer_sRGB */ + case GL_FRAMEBUFFER_SRGB_EXT: + CHECK_EXTENSION(EXT_framebuffer_sRGB, cap); + FLUSH_VERTICES(ctx, _NEW_BUFFERS); + ctx->Color.sRGBEnabled = state; + break; + default: goto invalid_enum_error; } @@ -1303,11 +1299,6 @@ _mesa_IsEnabled( GLenum cap ) return (ctx->Array.ArrayObj->PointSize.Enabled != 0); #endif - /* GL_SGI_texture_color_table */ - case GL_TEXTURE_COLOR_TABLE_SGI: - CHECK_EXTENSION(SGI_texture_color_table); - return ctx->Texture.Unit[ctx->Texture.CurrentUnit].ColorTableEnabled; - /* GL_ARB_texture_cube_map */ case GL_TEXTURE_CUBE_MAP_ARB: CHECK_EXTENSION(ARB_texture_cube_map); @@ -1479,6 +1470,11 @@ _mesa_IsEnabled( GLenum cap ) } return ctx->Array.PrimitiveRestart; + /* GL3.0 - GL_framebuffer_sRGB */ + case GL_FRAMEBUFFER_SRGB_EXT: + CHECK_EXTENSION(EXT_framebuffer_sRGB); + return ctx->Color.sRGBEnabled; + default: goto invalid_enum_error; } diff --git a/src/mesa/main/enums.c b/src/mesa/main/enums.c index 0ce62c0e3c..e9d6b6b156 100644 --- a/src/mesa/main/enums.c +++ b/src/mesa/main/enums.c @@ -29,6 +29,7 @@ #include "main/mfeatures.h" #include "main/enums.h" #include "main/imports.h" +#include "main/mtypes.h" typedef struct { size_t offset; @@ -2275,6 +2276,7 @@ LONGSTRING static const char enum_string_table[] = "GL_VERTEX_ATTRIB_ARRAY9_NV\0" "GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING\0" "GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING_ARB\0" + "GL_VERTEX_ATTRIB_ARRAY_DIVISOR_ARB\0" "GL_VERTEX_ATTRIB_ARRAY_ENABLED\0" "GL_VERTEX_ATTRIB_ARRAY_ENABLED_ARB\0" "GL_VERTEX_ATTRIB_ARRAY_INTEGER\0" @@ -2332,7 +2334,7 @@ LONGSTRING static const char enum_string_table[] = "GL_ZOOM_Y\0" ; -static const enum_elt all_enums[2294] = +static const enum_elt all_enums[2295] = { { 0, 0x00000600 }, /* GL_2D */ { 6, 0x00001407 }, /* GL_2_BYTES */ @@ -4573,64 +4575,65 @@ static const enum_elt all_enums[2294] = { 49885, 0x00008659 }, /* GL_VERTEX_ATTRIB_ARRAY9_NV */ { 49912, 0x0000889F }, /* GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING */ { 49950, 0x0000889F }, /* GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING_ARB */ - { 49992, 0x00008622 }, /* GL_VERTEX_ATTRIB_ARRAY_ENABLED */ - { 50023, 0x00008622 }, /* GL_VERTEX_ATTRIB_ARRAY_ENABLED_ARB */ - { 50058, 0x000088FD }, /* GL_VERTEX_ATTRIB_ARRAY_INTEGER */ - { 50089, 0x000088FD }, /* GL_VERTEX_ATTRIB_ARRAY_INTEGER_EXT */ - { 50124, 0x0000886A }, /* GL_VERTEX_ATTRIB_ARRAY_NORMALIZED */ - { 50158, 0x0000886A }, /* GL_VERTEX_ATTRIB_ARRAY_NORMALIZED_ARB */ - { 50196, 0x00008645 }, /* GL_VERTEX_ATTRIB_ARRAY_POINTER */ - { 50227, 0x00008645 }, /* GL_VERTEX_ATTRIB_ARRAY_POINTER_ARB */ - { 50262, 0x00008623 }, /* GL_VERTEX_ATTRIB_ARRAY_SIZE */ - { 50290, 0x00008623 }, /* GL_VERTEX_ATTRIB_ARRAY_SIZE_ARB */ - { 50322, 0x00008624 }, /* GL_VERTEX_ATTRIB_ARRAY_STRIDE */ - { 50352, 0x00008624 }, /* GL_VERTEX_ATTRIB_ARRAY_STRIDE_ARB */ - { 50386, 0x00008625 }, /* GL_VERTEX_ATTRIB_ARRAY_TYPE */ - { 50414, 0x00008625 }, /* GL_VERTEX_ATTRIB_ARRAY_TYPE_ARB */ - { 50446, 0x000086A7 }, /* GL_VERTEX_BLEND_ARB */ - { 50466, 0x00008620 }, /* GL_VERTEX_PROGRAM_ARB */ - { 50488, 0x0000864A }, /* GL_VERTEX_PROGRAM_BINDING_NV */ - { 50517, 0x00008620 }, /* GL_VERTEX_PROGRAM_NV */ - { 50538, 0x00008642 }, /* GL_VERTEX_PROGRAM_POINT_SIZE */ - { 50567, 0x00008642 }, /* GL_VERTEX_PROGRAM_POINT_SIZE_ARB */ - { 50600, 0x00008642 }, /* GL_VERTEX_PROGRAM_POINT_SIZE_NV */ - { 50632, 0x00008643 }, /* GL_VERTEX_PROGRAM_TWO_SIDE */ - { 50659, 0x00008643 }, /* GL_VERTEX_PROGRAM_TWO_SIDE_ARB */ - { 50690, 0x00008643 }, /* GL_VERTEX_PROGRAM_TWO_SIDE_NV */ - { 50720, 0x00008B31 }, /* GL_VERTEX_SHADER */ - { 50737, 0x00008B31 }, /* GL_VERTEX_SHADER_ARB */ - { 50758, 0x00008621 }, /* GL_VERTEX_STATE_PROGRAM_NV */ - { 50785, 0x00000BA2 }, /* GL_VIEWPORT */ - { 50797, 0x00000800 }, /* GL_VIEWPORT_BIT */ - { 50813, 0x00008A1A }, /* GL_VOLATILE_APPLE */ - { 50831, 0x0000911D }, /* GL_WAIT_FAILED */ - { 50846, 0x000086AD }, /* GL_WEIGHT_ARRAY_ARB */ - { 50866, 0x0000889E }, /* GL_WEIGHT_ARRAY_BUFFER_BINDING */ - { 50897, 0x0000889E }, /* GL_WEIGHT_ARRAY_BUFFER_BINDING_ARB */ - { 50932, 0x0000889E }, /* GL_WEIGHT_ARRAY_BUFFER_BINDING_OES */ - { 50967, 0x000086AD }, /* GL_WEIGHT_ARRAY_OES */ - { 50987, 0x000086AC }, /* GL_WEIGHT_ARRAY_POINTER_ARB */ - { 51015, 0x000086AC }, /* GL_WEIGHT_ARRAY_POINTER_OES */ - { 51043, 0x000086AB }, /* GL_WEIGHT_ARRAY_SIZE_ARB */ - { 51068, 0x000086AB }, /* GL_WEIGHT_ARRAY_SIZE_OES */ - { 51093, 0x000086AA }, /* GL_WEIGHT_ARRAY_STRIDE_ARB */ - { 51120, 0x000086AA }, /* GL_WEIGHT_ARRAY_STRIDE_OES */ - { 51147, 0x000086A9 }, /* GL_WEIGHT_ARRAY_TYPE_ARB */ - { 51172, 0x000086A9 }, /* GL_WEIGHT_ARRAY_TYPE_OES */ - { 51197, 0x000086A6 }, /* GL_WEIGHT_SUM_UNITY_ARB */ - { 51221, 0x000081D4 }, /* GL_WRAP_BORDER_SUN */ - { 51240, 0x000088B9 }, /* GL_WRITE_ONLY */ - { 51254, 0x000088B9 }, /* GL_WRITE_ONLY_ARB */ - { 51272, 0x000088B9 }, /* GL_WRITE_ONLY_OES */ - { 51290, 0x00001506 }, /* GL_XOR */ - { 51297, 0x000085B9 }, /* GL_YCBCR_422_APPLE */ - { 51316, 0x00008757 }, /* GL_YCBCR_MESA */ - { 51330, 0x00000000 }, /* GL_ZERO */ - { 51338, 0x00000D16 }, /* GL_ZOOM_X */ - { 51348, 0x00000D17 }, /* GL_ZOOM_Y */ + { 49992, 0x000088FE }, /* GL_VERTEX_ATTRIB_ARRAY_DIVISOR_ARB */ + { 50027, 0x00008622 }, /* GL_VERTEX_ATTRIB_ARRAY_ENABLED */ + { 50058, 0x00008622 }, /* GL_VERTEX_ATTRIB_ARRAY_ENABLED_ARB */ + { 50093, 0x000088FD }, /* GL_VERTEX_ATTRIB_ARRAY_INTEGER */ + { 50124, 0x000088FD }, /* GL_VERTEX_ATTRIB_ARRAY_INTEGER_EXT */ + { 50159, 0x0000886A }, /* GL_VERTEX_ATTRIB_ARRAY_NORMALIZED */ + { 50193, 0x0000886A }, /* GL_VERTEX_ATTRIB_ARRAY_NORMALIZED_ARB */ + { 50231, 0x00008645 }, /* GL_VERTEX_ATTRIB_ARRAY_POINTER */ + { 50262, 0x00008645 }, /* GL_VERTEX_ATTRIB_ARRAY_POINTER_ARB */ + { 50297, 0x00008623 }, /* GL_VERTEX_ATTRIB_ARRAY_SIZE */ + { 50325, 0x00008623 }, /* GL_VERTEX_ATTRIB_ARRAY_SIZE_ARB */ + { 50357, 0x00008624 }, /* GL_VERTEX_ATTRIB_ARRAY_STRIDE */ + { 50387, 0x00008624 }, /* GL_VERTEX_ATTRIB_ARRAY_STRIDE_ARB */ + { 50421, 0x00008625 }, /* GL_VERTEX_ATTRIB_ARRAY_TYPE */ + { 50449, 0x00008625 }, /* GL_VERTEX_ATTRIB_ARRAY_TYPE_ARB */ + { 50481, 0x000086A7 }, /* GL_VERTEX_BLEND_ARB */ + { 50501, 0x00008620 }, /* GL_VERTEX_PROGRAM_ARB */ + { 50523, 0x0000864A }, /* GL_VERTEX_PROGRAM_BINDING_NV */ + { 50552, 0x00008620 }, /* GL_VERTEX_PROGRAM_NV */ + { 50573, 0x00008642 }, /* GL_VERTEX_PROGRAM_POINT_SIZE */ + { 50602, 0x00008642 }, /* GL_VERTEX_PROGRAM_POINT_SIZE_ARB */ + { 50635, 0x00008642 }, /* GL_VERTEX_PROGRAM_POINT_SIZE_NV */ + { 50667, 0x00008643 }, /* GL_VERTEX_PROGRAM_TWO_SIDE */ + { 50694, 0x00008643 }, /* GL_VERTEX_PROGRAM_TWO_SIDE_ARB */ + { 50725, 0x00008643 }, /* GL_VERTEX_PROGRAM_TWO_SIDE_NV */ + { 50755, 0x00008B31 }, /* GL_VERTEX_SHADER */ + { 50772, 0x00008B31 }, /* GL_VERTEX_SHADER_ARB */ + { 50793, 0x00008621 }, /* GL_VERTEX_STATE_PROGRAM_NV */ + { 50820, 0x00000BA2 }, /* GL_VIEWPORT */ + { 50832, 0x00000800 }, /* GL_VIEWPORT_BIT */ + { 50848, 0x00008A1A }, /* GL_VOLATILE_APPLE */ + { 50866, 0x0000911D }, /* GL_WAIT_FAILED */ + { 50881, 0x000086AD }, /* GL_WEIGHT_ARRAY_ARB */ + { 50901, 0x0000889E }, /* GL_WEIGHT_ARRAY_BUFFER_BINDING */ + { 50932, 0x0000889E }, /* GL_WEIGHT_ARRAY_BUFFER_BINDING_ARB */ + { 50967, 0x0000889E }, /* GL_WEIGHT_ARRAY_BUFFER_BINDING_OES */ + { 51002, 0x000086AD }, /* GL_WEIGHT_ARRAY_OES */ + { 51022, 0x000086AC }, /* GL_WEIGHT_ARRAY_POINTER_ARB */ + { 51050, 0x000086AC }, /* GL_WEIGHT_ARRAY_POINTER_OES */ + { 51078, 0x000086AB }, /* GL_WEIGHT_ARRAY_SIZE_ARB */ + { 51103, 0x000086AB }, /* GL_WEIGHT_ARRAY_SIZE_OES */ + { 51128, 0x000086AA }, /* GL_WEIGHT_ARRAY_STRIDE_ARB */ + { 51155, 0x000086AA }, /* GL_WEIGHT_ARRAY_STRIDE_OES */ + { 51182, 0x000086A9 }, /* GL_WEIGHT_ARRAY_TYPE_ARB */ + { 51207, 0x000086A9 }, /* GL_WEIGHT_ARRAY_TYPE_OES */ + { 51232, 0x000086A6 }, /* GL_WEIGHT_SUM_UNITY_ARB */ + { 51256, 0x000081D4 }, /* GL_WRAP_BORDER_SUN */ + { 51275, 0x000088B9 }, /* GL_WRITE_ONLY */ + { 51289, 0x000088B9 }, /* GL_WRITE_ONLY_ARB */ + { 51307, 0x000088B9 }, /* GL_WRITE_ONLY_OES */ + { 51325, 0x00001506 }, /* GL_XOR */ + { 51332, 0x000085B9 }, /* GL_YCBCR_422_APPLE */ + { 51351, 0x00008757 }, /* GL_YCBCR_MESA */ + { 51365, 0x00000000 }, /* GL_ZERO */ + { 51373, 0x00000D16 }, /* GL_ZOOM_X */ + { 51383, 0x00000D17 }, /* GL_ZOOM_Y */ }; -static const unsigned reduced_enums[1551] = +static const unsigned reduced_enums[1552] = { 535, /* GL_FALSE */ 827, /* GL_LINES */ @@ -4776,7 +4779,7 @@ static const unsigned reduced_enums[1551] = 1856, /* GL_STENCIL_WRITEMASK */ 1006, /* GL_MATRIX_MODE */ 1222, /* GL_NORMALIZE */ - 2266, /* GL_VIEWPORT */ + 2267, /* GL_VIEWPORT */ 1195, /* GL_MODELVIEW_STACK_DEPTH */ 1481, /* GL_PROJECTION_STACK_DEPTH */ 2089, /* GL_TEXTURE_STACK_DEPTH */ @@ -4856,8 +4859,8 @@ static const unsigned reduced_enums[1551] = 741, /* GL_INDEX_OFFSET */ 1550, /* GL_RED_SCALE */ 1546, /* GL_RED_BIAS */ - 2292, /* GL_ZOOM_X */ - 2293, /* GL_ZOOM_Y */ + 2293, /* GL_ZOOM_X */ + 2294, /* GL_ZOOM_Y */ 697, /* GL_GREEN_SCALE */ 693, /* GL_GREEN_BIAS */ 115, /* GL_BLUE_SCALE */ @@ -4960,7 +4963,7 @@ static const unsigned reduced_enums[1551] = 347, /* GL_COPY */ 59, /* GL_AND_INVERTED */ 1220, /* GL_NOOP */ - 2288, /* GL_XOR */ + 2289, /* GL_XOR */ 1287, /* GL_OR */ 1221, /* GL_NOR */ 526, /* GL_EQUIV */ @@ -5301,7 +5304,7 @@ static const unsigned reduced_enums[1551] = 354, /* GL_CULL_VERTEX_EXT */ 356, /* GL_CULL_VERTEX_OBJECT_POSITION_EXT */ 355, /* GL_CULL_VERTEX_EYE_POSITION_EXT */ - 2284, /* GL_WRAP_BORDER_SUN */ + 2285, /* GL_WRAP_BORDER_SUN */ 1991, /* GL_TEXTURE_COLOR_WRITEMASK_SGIS */ 816, /* GL_LIGHT_MODEL_COLOR_CONTROL */ 1758, /* GL_SINGLE_COLOR */ @@ -5481,7 +5484,7 @@ static const unsigned reduced_enums[1551] = 2213, /* GL_VERTEX_ARRAY_BINDING */ 2080, /* GL_TEXTURE_RANGE_LENGTH_APPLE */ 2081, /* GL_TEXTURE_RANGE_POINTER_APPLE */ - 2289, /* GL_YCBCR_422_APPLE */ + 2290, /* GL_YCBCR_422_APPLE */ 2202, /* GL_UNSIGNED_SHORT_8_8_APPLE */ 2204, /* GL_UNSIGNED_SHORT_8_8_REV_APPLE */ 2092, /* GL_TEXTURE_STORAGE_HINT_APPLE */ @@ -5491,12 +5494,12 @@ static const unsigned reduced_enums[1551] = 1760, /* GL_SLICE_ACCUM_SUN */ 1510, /* GL_QUAD_MESH_SUN */ 2139, /* GL_TRIANGLE_MESH_SUN */ - 2254, /* GL_VERTEX_PROGRAM_ARB */ - 2265, /* GL_VERTEX_STATE_PROGRAM_NV */ - 2239, /* GL_VERTEX_ATTRIB_ARRAY_ENABLED */ - 2247, /* GL_VERTEX_ATTRIB_ARRAY_SIZE */ - 2249, /* GL_VERTEX_ATTRIB_ARRAY_STRIDE */ - 2251, /* GL_VERTEX_ATTRIB_ARRAY_TYPE */ + 2255, /* GL_VERTEX_PROGRAM_ARB */ + 2266, /* GL_VERTEX_STATE_PROGRAM_NV */ + 2240, /* GL_VERTEX_ATTRIB_ARRAY_ENABLED */ + 2248, /* GL_VERTEX_ATTRIB_ARRAY_SIZE */ + 2250, /* GL_VERTEX_ATTRIB_ARRAY_STRIDE */ + 2252, /* GL_VERTEX_ATTRIB_ARRAY_TYPE */ 383, /* GL_CURRENT_VERTEX_ATTRIB */ 1455, /* GL_PROGRAM_LENGTH_ARB */ 1471, /* GL_PROGRAM_STRING_ARB */ @@ -5518,14 +5521,14 @@ static const unsigned reduced_enums[1551] = 366, /* GL_CURRENT_MATRIX_STACK_DEPTH_ARB */ 363, /* GL_CURRENT_MATRIX_ARB */ 1468, /* GL_PROGRAM_POINT_SIZE */ - 2260, /* GL_VERTEX_PROGRAM_TWO_SIDE */ + 2261, /* GL_VERTEX_PROGRAM_TWO_SIDE */ 1467, /* GL_PROGRAM_PARAMETER_NV */ - 2245, /* GL_VERTEX_ATTRIB_ARRAY_POINTER */ + 2246, /* GL_VERTEX_ATTRIB_ARRAY_POINTER */ 1473, /* GL_PROGRAM_TARGET_NV */ 1470, /* GL_PROGRAM_RESIDENT_NV */ 2102, /* GL_TRACK_MATRIX_NV */ 2103, /* GL_TRACK_MATRIX_TRANSFORM_NV */ - 2255, /* GL_VERTEX_PROGRAM_BINDING_NV */ + 2256, /* GL_VERTEX_PROGRAM_BINDING_NV */ 1449, /* GL_PROGRAM_ERROR_POSITION_ARB */ 408, /* GL_DEPTH_CLAMP */ 2221, /* GL_VERTEX_ATTRIB_ARRAY0_NV */ @@ -5582,14 +5585,14 @@ static const unsigned reduced_enums[1551] = 311, /* GL_COMPRESSED_TEXTURE_FORMATS */ 1134, /* GL_MAX_VERTEX_UNITS_ARB */ 23, /* GL_ACTIVE_VERTEX_UNITS_ARB */ - 2283, /* GL_WEIGHT_SUM_UNITY_ARB */ - 2253, /* GL_VERTEX_BLEND_ARB */ + 2284, /* GL_WEIGHT_SUM_UNITY_ARB */ + 2254, /* GL_VERTEX_BLEND_ARB */ 385, /* GL_CURRENT_WEIGHT_ARB */ - 2281, /* GL_WEIGHT_ARRAY_TYPE_ARB */ - 2279, /* GL_WEIGHT_ARRAY_STRIDE_ARB */ - 2277, /* GL_WEIGHT_ARRAY_SIZE_ARB */ - 2275, /* GL_WEIGHT_ARRAY_POINTER_ARB */ - 2270, /* GL_WEIGHT_ARRAY_ARB */ + 2282, /* GL_WEIGHT_ARRAY_TYPE_ARB */ + 2280, /* GL_WEIGHT_ARRAY_STRIDE_ARB */ + 2278, /* GL_WEIGHT_ARRAY_SIZE_ARB */ + 2276, /* GL_WEIGHT_ARRAY_POINTER_ARB */ + 2271, /* GL_WEIGHT_ARRAY_ARB */ 442, /* GL_DOT3_RGB */ 443, /* GL_DOT3_RGBA */ 305, /* GL_COMPRESSED_RGB_FXT1_3DFX */ @@ -5634,7 +5637,7 @@ static const unsigned reduced_enums[1551] = 1197, /* GL_MODULATE_ADD_ATI */ 1198, /* GL_MODULATE_SIGNED_ADD_ATI */ 1199, /* GL_MODULATE_SUBTRACT_ATI */ - 2290, /* GL_YCBCR_MESA */ + 2291, /* GL_YCBCR_MESA */ 1294, /* GL_PACK_INVERT_MESA */ 388, /* GL_DEBUG_OBJECT_MESA */ 389, /* GL_DEBUG_PRINT_MESA */ @@ -5713,7 +5716,7 @@ static const unsigned reduced_enums[1551] = 1520, /* GL_QUERY_RESULT */ 1522, /* GL_QUERY_RESULT_AVAILABLE */ 1126, /* GL_MAX_VERTEX_ATTRIBS */ - 2243, /* GL_VERTEX_ATTRIB_ARRAY_NORMALIZED */ + 2244, /* GL_VERTEX_ATTRIB_ARRAY_NORMALIZED */ 433, /* GL_DEPTH_STENCIL_TO_RGBA_NV */ 432, /* GL_DEPTH_STENCIL_TO_BGRA_NV */ 1103, /* GL_MAX_TEXTURE_COORDS */ @@ -5736,7 +5739,7 @@ static const unsigned reduced_enums[1551] = 516, /* GL_EDGE_FLAG_ARRAY_BUFFER_BINDING */ 1730, /* GL_SECONDARY_COLOR_ARRAY_BUFFER_BINDING */ 573, /* GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING */ - 2271, /* GL_WEIGHT_ARRAY_BUFFER_BINDING */ + 2272, /* GL_WEIGHT_ARRAY_BUFFER_BINDING */ 2237, /* GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING */ 1454, /* GL_PROGRAM_INSTRUCTIONS_ARB */ 1070, /* GL_MAX_PROGRAM_INSTRUCTIONS_ARB */ @@ -5763,7 +5766,7 @@ static const unsigned reduced_enums[1551] = 1477, /* GL_PROGRAM_UNDER_NATIVE_LIMITS_ARB */ 2127, /* GL_TRANSPOSE_CURRENT_MATRIX_ARB */ 1539, /* GL_READ_ONLY */ - 2285, /* GL_WRITE_ONLY */ + 2286, /* GL_WRITE_ONLY */ 1541, /* GL_READ_WRITE */ 124, /* GL_BUFFER_ACCESS */ 129, /* GL_BUFFER_MAPPED */ @@ -5821,7 +5824,8 @@ static const unsigned reduced_enums[1551] = 1069, /* GL_MAX_PROGRAM_IF_DEPTH_NV */ 1073, /* GL_MAX_PROGRAM_LOOP_DEPTH_NV */ 1072, /* GL_MAX_PROGRAM_LOOP_COUNT_NV */ - 2241, /* GL_VERTEX_ATTRIB_ARRAY_INTEGER */ + 2242, /* GL_VERTEX_ATTRIB_ARRAY_INTEGER */ + 2239, /* GL_VERTEX_ATTRIB_ARRAY_DIVISOR_ARB */ 1012, /* GL_MAX_ARRAY_TEXTURE_LAYERS */ 1149, /* GL_MIN_PROGRAM_TEXEL_OFFSET */ 1086, /* GL_MAX_PROGRAM_TEXEL_OFFSET */ @@ -5843,12 +5847,12 @@ static const unsigned reduced_enums[1551] = 138, /* GL_BUFFER_SERIALIZED_MODIFY_APPLE */ 128, /* GL_BUFFER_FLUSHING_UNMAP_APPLE */ 1556, /* GL_RELEASED_APPLE */ - 2268, /* GL_VOLATILE_APPLE */ + 2269, /* GL_VOLATILE_APPLE */ 1595, /* GL_RETAINED_APPLE */ 2144, /* GL_UNDEFINED_APPLE */ 1504, /* GL_PURGEABLE_APPLE */ 596, /* GL_FRAGMENT_SHADER */ - 2263, /* GL_VERTEX_SHADER */ + 2264, /* GL_VERTEX_SHADER */ 1465, /* GL_PROGRAM_OBJECT_ARB */ 1747, /* GL_SHADER_OBJECT_ARB */ 1041, /* GL_MAX_FRAGMENT_UNIFORM_COMPONENTS */ @@ -5909,8 +5913,8 @@ static const unsigned reduced_enums[1551] = 1306, /* GL_PALETTE8_R5_G6_B5_OES */ 1309, /* GL_PALETTE8_RGBA4_OES */ 1307, /* GL_PALETTE8_RGB5_A1_OES */ - 726, /* GL_IMPLEMENTATION_COLOR_READ_TYPE_OES */ - 724, /* GL_IMPLEMENTATION_COLOR_READ_FORMAT_OES */ + 725, /* GL_IMPLEMENTATION_COLOR_READ_TYPE */ + 723, /* GL_IMPLEMENTATION_COLOR_READ_FORMAT */ 1355, /* GL_POINT_SIZE_ARRAY_OES */ 2014, /* GL_TEXTURE_CROP_RECT_OES */ 996, /* GL_MATRIX_INDEX_ARRAY_BUFFER_BINDING_OES */ @@ -6166,7 +6170,7 @@ static const unsigned reduced_enums[1551] = 54, /* GL_ALREADY_SIGNALED */ 2100, /* GL_TIMEOUT_EXPIRED */ 312, /* GL_CONDITION_SATISFIED */ - 2269, /* GL_WAIT_FAILED */ + 2270, /* GL_WAIT_FAILED */ 126, /* GL_BUFFER_ACCESS_FLAGS */ 132, /* GL_BUFFER_MAP_LENGTH */ 133, /* GL_BUFFER_MAP_OFFSET */ @@ -6240,29 +6244,39 @@ const char *_mesa_lookup_enum_by_nr( int nr ) } } +/** + * Primitive names + */ +static const char *prim_names[PRIM_UNKNOWN + 1] = { + "GL_POINTS", + "GL_LINES", + "GL_LINE_LOOP", + "GL_LINE_STRIP", + "GL_TRIANGLES", + "GL_TRIANGLE_STRIP", + "GL_TRIANGLE_FAN", + "GL_QUADS", + "GL_QUAD_STRIP", + "GL_POLYGON", + "outside begin/end", + "inside unknown primitive", + "unknown state" +}; + + /* Get the name of an enum given that it is a primitive type. Avoids * GL_FALSE/GL_POINTS ambiguity and others. */ -const char *_mesa_lookup_prim_by_nr( int nr ) +const char * +_mesa_lookup_prim_by_nr(GLuint nr) { - switch (nr) { - case GL_POINTS: return "GL_POINTS"; - case GL_LINES: return "GL_LINES"; - case GL_LINE_STRIP: return "GL_LINE_STRIP"; - case GL_LINE_LOOP: return "GL_LINE_LOOP"; - case GL_TRIANGLES: return "GL_TRIANGLES"; - case GL_TRIANGLE_STRIP: return "GL_TRIANGLE_STRIP"; - case GL_TRIANGLE_FAN: return "GL_TRIANGLE_FAN"; - case GL_QUADS: return "GL_QUADS"; - case GL_QUAD_STRIP: return "GL_QUAD_STRIP"; - case GL_POLYGON: return "GL_POLYGON"; - case GL_POLYGON+1: return "OUTSIDE_BEGIN_END"; - default: return "<invalid>"; - } + if (nr < Elements(prim_names)) + return prim_names[nr]; + else + return "invalid mode"; } - int _mesa_lookup_enum_by_name( const char *symbol ) { enum_elt * f = NULL; diff --git a/src/mesa/main/enums.h b/src/mesa/main/enums.h index c03cd34da9..7733df22f9 100644 --- a/src/mesa/main/enums.h +++ b/src/mesa/main/enums.h @@ -45,7 +45,7 @@ extern const char *_mesa_lookup_enum_by_nr( int nr ); /* Get the name of an enum given that it is a primitive type. Avoids * GL_FALSE/GL_POINTS ambiguity and others. */ -const char *_mesa_lookup_prim_by_nr( int nr ); +const char *_mesa_lookup_prim_by_nr( unsigned nr ); extern int _mesa_lookup_enum_by_name( const char *symbol ); diff --git a/src/mesa/main/eval.c b/src/mesa/main/eval.c index c607e6a26a..9ab55072f0 100644 --- a/src/mesa/main/eval.c +++ b/src/mesa/main/eval.c @@ -43,6 +43,7 @@ #include "context.h" #include "eval.h" #include "macros.h" +#include "mfeatures.h" #include "mtypes.h" #include "main/dispatch.h" diff --git a/src/mesa/main/eval.h b/src/mesa/main/eval.h index bd908f00cd..bfeeebde54 100644 --- a/src/mesa/main/eval.h +++ b/src/mesa/main/eval.h @@ -37,6 +37,7 @@ #define EVAL_H +#include "main/mfeatures.h" #include "main/mtypes.h" diff --git a/src/mesa/main/extensions.c b/src/mesa/main/extensions.c index b71afdd61f..3fec91b465 100644 --- a/src/mesa/main/extensions.c +++ b/src/mesa/main/extensions.c @@ -24,206 +24,354 @@ */ +/** + * \file + * \brief Extension handling + */ + + #include "glheader.h" #include "imports.h" #include "context.h" #include "extensions.h" +#include "mfeatures.h" #include "mtypes.h" +enum { + DISABLE = 0, + GL = 1 << API_OPENGL, + ES1 = 1 << API_OPENGLES, + ES2 = 1 << API_OPENGLES2, +}; -#define F(x) offsetof(struct gl_extensions, x) -#define ON GL_TRUE -#define OFF GL_FALSE +/** + * \brief An element of the \c extension_table. + */ +struct extension { + /** Name of extension, such as "GL_ARB_depth_clamp". */ + const char *name; + /** Offset (in bytes) of the corresponding member in struct gl_extensions. */ + size_t offset; -/* + /** Set of API's in which the extension exists, as a bitset. */ + uint8_t api_set; +}; + + +/** + * Given a member \c x of struct gl_extensions, return offset of + * \c x in bytes. + */ +#define o(x) offsetof(struct gl_extensions, x) + + +/** + * \brief Table of supported OpenGL extensions for all API's. + * * Note: The GL_MESAX_* extensions are placeholders for future ARB extensions. */ -static const struct { - GLboolean enabled; - const char *name; - int flag_offset; -} default_extensions[] = { - { OFF, "GL_ARB_blend_func_extended", F(ARB_blend_func_extended) }, - { ON, "GL_ARB_copy_buffer", F(ARB_copy_buffer) }, - { OFF, "GL_ARB_depth_buffer_float", F(ARB_depth_buffer_float) }, - { OFF, "GL_ARB_depth_clamp", F(ARB_depth_clamp) }, - { OFF, "GL_ARB_depth_texture", F(ARB_depth_texture) }, - { ON, "GL_ARB_draw_buffers", F(ARB_draw_buffers) }, - { OFF, "GL_ARB_draw_elements_base_vertex", F(ARB_draw_elements_base_vertex) }, - { OFF, "GL_ARB_draw_instanced", F(ARB_draw_instanced) }, - { OFF, "GL_ARB_explicit_attrib_location", F(ARB_explicit_attrib_location) }, - { OFF, "GL_ARB_fragment_coord_conventions", F(ARB_fragment_coord_conventions) }, - { OFF, "GL_ARB_fragment_program", F(ARB_fragment_program) }, - { OFF, "GL_ARB_fragment_program_shadow", F(ARB_fragment_program_shadow) }, - { OFF, "GL_ARB_fragment_shader", F(ARB_fragment_shader) }, - { OFF, "GL_ARB_framebuffer_object", F(ARB_framebuffer_object) }, - /* TODO: reenable this when the new GLSL compiler actually supports them */ - /* { OFF, "GL_ARB_geometry_shader4", F(ARB_geometry_shader4) }, */ - { OFF, "GL_ARB_half_float_pixel", F(ARB_half_float_pixel) }, - { OFF, "GL_ARB_half_float_vertex", F(ARB_half_float_vertex) }, - { OFF, "GL_ARB_instanced_arrays", F(ARB_instanced_arrays) }, - { OFF, "GL_ARB_map_buffer_range", F(ARB_map_buffer_range) }, - { ON, "GL_ARB_multisample", F(ARB_multisample) }, - { OFF, "GL_ARB_multitexture", F(ARB_multitexture) }, - { OFF, "GL_ARB_occlusion_query", F(ARB_occlusion_query) }, - { OFF, "GL_ARB_occlusion_query2", F(ARB_occlusion_query2) }, - { OFF, "GL_ARB_pixel_buffer_object", F(EXT_pixel_buffer_object) }, - { OFF, "GL_ARB_point_parameters", F(EXT_point_parameters) }, - { OFF, "GL_ARB_point_sprite", F(ARB_point_sprite) }, - { OFF, "GL_ARB_provoking_vertex", F(EXT_provoking_vertex) }, - { OFF, "GL_ARB_sampler_objects", F(ARB_sampler_objects) }, - { OFF, "GL_ARB_seamless_cube_map", F(ARB_seamless_cube_map) }, - { OFF, "GL_ARB_shader_objects", F(ARB_shader_objects) }, - { OFF, "GL_ARB_shader_stencil_export", F(ARB_shader_stencil_export) }, - { OFF, "GL_ARB_shading_language_100", F(ARB_shading_language_100) }, - { OFF, "GL_ARB_shadow", F(ARB_shadow) }, - { OFF, "GL_ARB_shadow_ambient", F(ARB_shadow_ambient) }, - { OFF, "GL_ARB_sync", F(ARB_sync) }, - { OFF, "GL_ARB_texture_border_clamp", F(ARB_texture_border_clamp) }, - { OFF, "GL_ARB_texture_buffer_object", F(ARB_texture_buffer_object) }, - { ON, "GL_ARB_texture_compression", F(ARB_texture_compression) }, - { OFF, "GL_ARB_texture_compression_rgtc", F(ARB_texture_compression_rgtc) }, - { OFF, "GL_ARB_texture_cube_map", F(ARB_texture_cube_map) }, - { OFF, "GL_ARB_texture_env_add", F(EXT_texture_env_add) }, - { OFF, "GL_ARB_texture_env_combine", F(ARB_texture_env_combine) }, - { OFF, "GL_ARB_texture_env_crossbar", F(ARB_texture_env_crossbar) }, - { OFF, "GL_ARB_texture_env_dot3", F(ARB_texture_env_dot3) }, - { OFF, "GL_MESAX_texture_float", F(ARB_texture_float) }, - { OFF, "GL_ARB_texture_mirrored_repeat", F(ARB_texture_mirrored_repeat)}, - { OFF, "GL_ARB_texture_multisample", F(ARB_texture_multisample) }, - { OFF, "GL_ARB_texture_non_power_of_two", F(ARB_texture_non_power_of_two)}, - { OFF, "GL_ARB_texture_rectangle", F(NV_texture_rectangle) }, - { OFF, "GL_ARB_texture_rg", F(ARB_texture_rg) }, - { OFF, "GL_ARB_texture_rgb10_a2ui", F(ARB_texture_rgb10_a2ui) }, - { OFF, "GL_ARB_texture_swizzle", F(EXT_texture_swizzle) }, - { ON, "GL_ARB_transpose_matrix", F(ARB_transpose_matrix) }, - { OFF, "GL_ARB_transform_feedback2", F(ARB_transform_feedback2) }, - { OFF, "GL_ARB_uniform_buffer_object", F(ARB_uniform_buffer_object) }, - { OFF, "GL_ARB_vertex_array_bgra", F(EXT_vertex_array_bgra) }, - { OFF, "GL_ARB_vertex_array_object", F(ARB_vertex_array_object) }, - { ON, "GL_ARB_vertex_buffer_object", F(ARB_vertex_buffer_object) }, - { OFF, "GL_ARB_vertex_program", F(ARB_vertex_program) }, - { OFF, "GL_ARB_vertex_shader", F(ARB_vertex_shader) }, - { OFF, "GL_ARB_vertex_type_2_10_10_10_rev", F(ARB_vertex_type_2_10_10_10_rev) }, - { ON, "GL_ARB_window_pos", F(ARB_window_pos) }, - { ON, "GL_EXT_abgr", F(EXT_abgr) }, - { ON, "GL_EXT_bgra", F(EXT_bgra) }, - { OFF, "GL_EXT_blend_color", F(EXT_blend_color) }, - { OFF, "GL_EXT_blend_equation_separate", F(EXT_blend_equation_separate) }, - { OFF, "GL_EXT_blend_func_separate", F(EXT_blend_func_separate) }, - { OFF, "GL_EXT_blend_logic_op", F(EXT_blend_logic_op) }, - { OFF, "GL_EXT_blend_minmax", F(EXT_blend_minmax) }, - { OFF, "GL_EXT_blend_subtract", F(EXT_blend_subtract) }, - { OFF, "GL_EXT_clip_volume_hint", F(EXT_clip_volume_hint) }, - { ON, "GL_EXT_compiled_vertex_array", F(EXT_compiled_vertex_array) }, - { ON, "GL_EXT_copy_texture", F(EXT_copy_texture) }, - { OFF, "GL_EXT_depth_bounds_test", F(EXT_depth_bounds_test) }, - { OFF, "GL_EXT_draw_buffers2", F(EXT_draw_buffers2) }, - { OFF, "GL_EXT_draw_instanced", F(ARB_draw_instanced) }, - { ON, "GL_EXT_draw_range_elements", F(EXT_draw_range_elements) }, - { OFF, "GL_EXT_framebuffer_blit", F(EXT_framebuffer_blit) }, - { OFF, "GL_EXT_framebuffer_multisample", F(EXT_framebuffer_multisample) }, - { OFF, "GL_EXT_framebuffer_object", F(EXT_framebuffer_object) }, - { OFF, "GL_EXT_framebuffer_sRGB", F(EXT_framebuffer_sRGB) }, - { OFF, "GL_EXT_fog_coord", F(EXT_fog_coord) }, - { OFF, "GL_EXT_gpu_program_parameters", F(EXT_gpu_program_parameters) }, - { OFF, "GL_EXT_gpu_shader4", F(EXT_gpu_shader4) }, - { ON, "GL_EXT_multi_draw_arrays", F(EXT_multi_draw_arrays) }, - { OFF, "GL_EXT_packed_depth_stencil", F(EXT_packed_depth_stencil) }, - { OFF, "GL_EXT_packed_float", F(EXT_packed_float) }, - { ON, "GL_EXT_packed_pixels", F(EXT_packed_pixels) }, - { OFF, "GL_EXT_paletted_texture", F(EXT_paletted_texture) }, - { OFF, "GL_EXT_pixel_buffer_object", F(EXT_pixel_buffer_object) }, - { OFF, "GL_EXT_point_parameters", F(EXT_point_parameters) }, - { ON, "GL_EXT_polygon_offset", F(EXT_polygon_offset) }, - { OFF, "GL_EXT_provoking_vertex", F(EXT_provoking_vertex) }, - { ON, "GL_EXT_rescale_normal", F(EXT_rescale_normal) }, - { OFF, "GL_EXT_secondary_color", F(EXT_secondary_color) }, - { OFF, "GL_EXT_separate_shader_objects", F(EXT_separate_shader_objects) }, - { ON, "GL_EXT_separate_specular_color", F(EXT_separate_specular_color) }, - { OFF, "GL_EXT_shadow_funcs", F(EXT_shadow_funcs) }, - { OFF, "GL_EXT_shared_texture_palette", F(EXT_shared_texture_palette) }, - { OFF, "GL_EXT_stencil_two_side", F(EXT_stencil_two_side) }, - { OFF, "GL_EXT_stencil_wrap", F(EXT_stencil_wrap) }, - { ON, "GL_EXT_subtexture", F(EXT_subtexture) }, - { ON, "GL_EXT_texture", F(EXT_texture) }, - { ON, "GL_EXT_texture3D", F(EXT_texture3D) }, - { OFF, "GL_EXT_texture_array", F(EXT_texture_array) }, - { OFF, "GL_EXT_texture_compression_s3tc", F(EXT_texture_compression_s3tc) }, - { OFF, "GL_EXT_texture_compression_rgtc", F(ARB_texture_compression_rgtc) }, - { OFF, "GL_EXT_texture_cube_map", F(ARB_texture_cube_map) }, - { ON, "GL_EXT_texture_edge_clamp", F(SGIS_texture_edge_clamp) }, - { OFF, "GL_EXT_texture_env_add", F(EXT_texture_env_add) }, - { OFF, "GL_EXT_texture_env_combine", F(EXT_texture_env_combine) }, - { OFF, "GL_EXT_texture_env_dot3", F(EXT_texture_env_dot3) }, - { OFF, "GL_EXT_texture_filter_anisotropic", F(EXT_texture_filter_anisotropic) }, - { OFF, "GL_EXT_texture_integer", F(EXT_texture_integer) }, - { OFF, "GL_EXT_texture_lod_bias", F(EXT_texture_lod_bias) }, - { OFF, "GL_EXT_texture_mirror_clamp", F(EXT_texture_mirror_clamp) }, - { ON, "GL_EXT_texture_object", F(EXT_texture_object) }, - { OFF, "GL_EXT_texture_rectangle", F(NV_texture_rectangle) }, - { OFF, "GL_EXT_texture_shared_exponent", F(EXT_texture_shared_exponent) }, - { OFF, "GL_EXT_texture_sRGB", F(EXT_texture_sRGB) }, - { OFF, "GL_EXT_texture_swizzle", F(EXT_texture_swizzle) }, - { OFF, "GL_EXT_timer_query", F(EXT_timer_query) }, - { OFF, "GL_EXT_transform_feedback", F(EXT_transform_feedback) }, - { ON, "GL_EXT_vertex_array", F(EXT_vertex_array) }, - { OFF, "GL_EXT_vertex_array_bgra", F(EXT_vertex_array_bgra) }, - { OFF, "GL_EXT_vertex_array_set", F(EXT_vertex_array_set) }, - { OFF, "GL_3DFX_texture_compression_FXT1", F(TDFX_texture_compression_FXT1) }, - { OFF, "GL_APPLE_client_storage", F(APPLE_client_storage) }, - { ON, "GL_APPLE_packed_pixels", F(APPLE_packed_pixels) }, - { OFF, "GL_APPLE_vertex_array_object", F(APPLE_vertex_array_object) }, - { OFF, "GL_APPLE_object_purgeable", F(APPLE_object_purgeable) }, - { OFF, "GL_ATI_blend_equation_separate", F(EXT_blend_equation_separate) }, - { OFF, "GL_ATI_envmap_bumpmap", F(ATI_envmap_bumpmap) }, - { OFF, "GL_ATI_texture_env_combine3", F(ATI_texture_env_combine3)}, - { OFF, "GL_ATI_texture_mirror_once", F(ATI_texture_mirror_once)}, - { OFF, "GL_ATI_fragment_shader", F(ATI_fragment_shader)}, - { OFF, "GL_ATI_separate_stencil", F(ATI_separate_stencil)}, - { ON, "GL_IBM_multimode_draw_arrays", F(IBM_multimode_draw_arrays) }, - { ON, "GL_IBM_rasterpos_clip", F(IBM_rasterpos_clip) }, - { OFF, "GL_IBM_texture_mirrored_repeat", F(ARB_texture_mirrored_repeat)}, - { OFF, "GL_INGR_blend_func_separate", F(EXT_blend_func_separate) }, - { OFF, "GL_MESA_pack_invert", F(MESA_pack_invert) }, - { OFF, "GL_MESA_resize_buffers", F(MESA_resize_buffers) }, - { OFF, "GL_MESA_texture_array", F(MESA_texture_array) }, - { OFF, "GL_MESA_texture_signed_rgba", F(MESA_texture_signed_rgba) }, - { OFF, "GL_MESA_ycbcr_texture", F(MESA_ycbcr_texture) }, - { ON, "GL_MESA_window_pos", F(ARB_window_pos) }, - { OFF, "GL_NV_blend_square", F(NV_blend_square) }, - { OFF, "GL_NV_conditional_render", F(NV_conditional_render) }, - { OFF, "GL_NV_depth_clamp", F(ARB_depth_clamp) }, - { OFF, "GL_NV_fragment_program", F(NV_fragment_program) }, - { OFF, "GL_NV_fragment_program_option", F(NV_fragment_program_option) }, - { ON, "GL_NV_light_max_exponent", F(NV_light_max_exponent) }, - { OFF, "GL_NV_packed_depth_stencil", F(EXT_packed_depth_stencil) }, - { OFF, "GL_NV_point_sprite", F(NV_point_sprite) }, - { OFF, "GL_NV_primitive_restart", F(NV_primitive_restart) }, - { ON, "GL_NV_texgen_reflection", F(NV_texgen_reflection) }, - { OFF, "GL_NV_texture_env_combine4", F(NV_texture_env_combine4) }, - { OFF, "GL_NV_texture_rectangle", F(NV_texture_rectangle) }, - { OFF, "GL_NV_vertex_program", F(NV_vertex_program) }, - { OFF, "GL_NV_vertex_program1_1", F(NV_vertex_program1_1) }, - { ON, "GL_OES_read_format", F(OES_read_format) }, - { OFF, "GL_SGI_texture_color_table", F(SGI_texture_color_table) }, - { ON, "GL_SGIS_generate_mipmap", F(SGIS_generate_mipmap) }, - { OFF, "GL_SGIS_texture_border_clamp", F(ARB_texture_border_clamp) }, - { ON, "GL_SGIS_texture_edge_clamp", F(SGIS_texture_edge_clamp) }, - { ON, "GL_SGIS_texture_lod", F(SGIS_texture_lod) }, - { ON, "GL_SUN_multi_draw_arrays", F(EXT_multi_draw_arrays) }, - { OFF, "GL_S3_s3tc", F(S3_s3tc) }, - { OFF, "GL_EXT_texture_format_BGRA8888", F(EXT_texture_format_BGRA8888) }, -#if FEATURE_OES_EGL_image - { OFF, "GL_OES_EGL_image", F(OES_EGL_image) }, -#endif +static const struct extension extension_table[] = { + /* ARB Extensions */ + { "GL_ARB_ES2_compatibility", o(ARB_ES2_compatibility), GL }, + { "GL_ARB_blend_func_extended", o(ARB_blend_func_extended), GL }, + { "GL_ARB_copy_buffer", o(ARB_copy_buffer), GL }, + { "GL_ARB_depth_buffer_float", o(ARB_depth_buffer_float), GL }, + { "GL_ARB_depth_clamp", o(ARB_depth_clamp), GL }, + { "GL_ARB_depth_texture", o(ARB_depth_texture), GL }, + { "GL_ARB_draw_buffers", o(ARB_draw_buffers), GL }, + { "GL_ARB_draw_buffers_blend", o(ARB_draw_buffers_blend), GL }, + { "GL_ARB_draw_elements_base_vertex", o(ARB_draw_elements_base_vertex), GL }, + { "GL_ARB_draw_instanced", o(ARB_draw_instanced), GL }, + { "GL_ARB_explicit_attrib_location", o(ARB_explicit_attrib_location), GL }, + { "GL_ARB_fragment_coord_conventions", o(ARB_fragment_coord_conventions), GL }, + { "GL_ARB_fragment_program", o(ARB_fragment_program), GL }, + { "GL_ARB_fragment_program_shadow", o(ARB_fragment_program_shadow), GL }, + { "GL_ARB_fragment_shader", o(ARB_fragment_shader), GL }, + { "GL_ARB_framebuffer_object", o(ARB_framebuffer_object), GL }, + { "GL_ARB_framebuffer_sRGB", o(EXT_framebuffer_sRGB), GL }, + { "GL_ARB_half_float_pixel", o(ARB_half_float_pixel), GL }, + { "GL_ARB_half_float_vertex", o(ARB_half_float_vertex), GL }, + { "GL_ARB_instanced_arrays", o(ARB_instanced_arrays), GL }, + { "GL_ARB_map_buffer_range", o(ARB_map_buffer_range), GL }, + { "GL_ARB_multisample", o(ARB_multisample), GL }, + { "GL_ARB_multitexture", o(ARB_multitexture), GL }, + { "GL_ARB_occlusion_query2", o(ARB_occlusion_query2), GL }, + { "GL_ARB_occlusion_query", o(ARB_occlusion_query), GL }, + { "GL_ARB_pixel_buffer_object", o(EXT_pixel_buffer_object), GL }, + { "GL_ARB_point_parameters", o(EXT_point_parameters), GL }, + { "GL_ARB_point_sprite", o(ARB_point_sprite), GL }, + { "GL_ARB_provoking_vertex", o(EXT_provoking_vertex), GL }, + { "GL_ARB_sampler_objects", o(ARB_sampler_objects), GL }, + { "GL_ARB_seamless_cube_map", o(ARB_seamless_cube_map), GL }, + { "GL_ARB_shader_objects", o(ARB_shader_objects), GL }, + { "GL_ARB_shader_stencil_export", o(ARB_shader_stencil_export), GL }, + { "GL_ARB_shading_language_100", o(ARB_shading_language_100), GL }, + { "GL_ARB_shadow_ambient", o(ARB_shadow_ambient), GL }, + { "GL_ARB_shadow", o(ARB_shadow), GL }, + { "GL_ARB_sync", o(ARB_sync), GL }, + { "GL_ARB_texture_border_clamp", o(ARB_texture_border_clamp), GL }, + { "GL_ARB_texture_buffer_object", o(ARB_texture_buffer_object), GL }, + { "GL_ARB_texture_compression", o(ARB_texture_compression), GL }, + { "GL_ARB_texture_compression_rgtc", o(ARB_texture_compression_rgtc), GL }, + { "GL_ARB_texture_cube_map", o(ARB_texture_cube_map), GL }, + { "GL_ARB_texture_env_add", o(EXT_texture_env_add), GL }, + { "GL_ARB_texture_env_combine", o(ARB_texture_env_combine), GL }, + { "GL_ARB_texture_env_crossbar", o(ARB_texture_env_crossbar), GL }, + { "GL_ARB_texture_env_dot3", o(ARB_texture_env_dot3), GL }, + { "GL_ARB_texture_mirrored_repeat", o(ARB_texture_mirrored_repeat), GL }, + { "GL_ARB_texture_multisample", o(ARB_texture_multisample), GL }, + { "GL_ARB_texture_non_power_of_two", o(ARB_texture_non_power_of_two), GL | ES1 | ES2 }, + { "GL_ARB_texture_rectangle", o(NV_texture_rectangle), GL }, + { "GL_ARB_texture_rgb10_a2ui", o(ARB_texture_rgb10_a2ui), GL }, + { "GL_ARB_texture_rg", o(ARB_texture_rg), GL }, + { "GL_ARB_texture_swizzle", o(EXT_texture_swizzle), GL }, + { "GL_ARB_transform_feedback2", o(ARB_transform_feedback2), GL }, + { "GL_ARB_transpose_matrix", o(ARB_transpose_matrix), GL }, + { "GL_ARB_uniform_buffer_object", o(ARB_uniform_buffer_object), GL }, + { "GL_ARB_vertex_array_bgra", o(EXT_vertex_array_bgra), GL }, + { "GL_ARB_vertex_array_object", o(ARB_vertex_array_object), GL }, + { "GL_ARB_vertex_buffer_object", o(ARB_vertex_buffer_object), GL }, + { "GL_ARB_vertex_program", o(ARB_vertex_program), GL }, + { "GL_ARB_vertex_shader", o(ARB_vertex_shader), GL }, + { "GL_ARB_vertex_type_2_10_10_10_rev", o(ARB_vertex_type_2_10_10_10_rev), GL }, + { "GL_ARB_window_pos", o(ARB_window_pos), GL }, + + /* EXT extensions */ + { "GL_EXT_abgr", o(EXT_abgr), GL }, + { "GL_EXT_bgra", o(EXT_bgra), GL }, + { "GL_EXT_blend_color", o(EXT_blend_color), GL }, + { "GL_EXT_blend_equation_separate", o(EXT_blend_equation_separate), GL }, + { "GL_EXT_blend_func_separate", o(EXT_blend_func_separate), GL }, + { "GL_EXT_blend_logic_op", o(EXT_blend_logic_op), GL }, + { "GL_EXT_blend_minmax", o(EXT_blend_minmax), GL | ES1 | ES2 }, + { "GL_EXT_blend_subtract", o(EXT_blend_subtract), GL }, + { "GL_EXT_clip_volume_hint", o(EXT_clip_volume_hint), GL }, + { "GL_EXT_compiled_vertex_array", o(EXT_compiled_vertex_array), GL }, + { "GL_EXT_copy_texture", o(EXT_copy_texture), GL }, + { "GL_EXT_depth_bounds_test", o(EXT_depth_bounds_test), GL }, + { "GL_EXT_draw_buffers2", o(EXT_draw_buffers2), GL }, + { "GL_EXT_draw_instanced", o(ARB_draw_instanced), GL }, + { "GL_EXT_draw_range_elements", o(EXT_draw_range_elements), GL }, + { "GL_EXT_fog_coord", o(EXT_fog_coord), GL }, + { "GL_EXT_framebuffer_blit", o(EXT_framebuffer_blit), GL }, + { "GL_EXT_framebuffer_multisample", o(EXT_framebuffer_multisample), GL }, + { "GL_EXT_framebuffer_object", o(EXT_framebuffer_object), GL }, + { "GL_EXT_framebuffer_sRGB", o(EXT_framebuffer_sRGB), GL }, + { "GL_EXT_gpu_program_parameters", o(EXT_gpu_program_parameters), GL }, + { "GL_EXT_gpu_shader4", o(EXT_gpu_shader4), GL }, + { "GL_EXT_multi_draw_arrays", o(EXT_multi_draw_arrays), GL | ES1 | ES2 }, + { "GL_EXT_packed_depth_stencil", o(EXT_packed_depth_stencil), GL }, + { "GL_EXT_packed_float", o(EXT_packed_float), GL }, + { "GL_EXT_packed_pixels", o(EXT_packed_pixels), GL }, + { "GL_EXT_paletted_texture", o(EXT_paletted_texture), GL }, + { "GL_EXT_pixel_buffer_object", o(EXT_pixel_buffer_object), GL }, + { "GL_EXT_point_parameters", o(EXT_point_parameters), GL }, + { "GL_EXT_polygon_offset", o(EXT_polygon_offset), GL }, + { "GL_EXT_provoking_vertex", o(EXT_provoking_vertex), GL }, + { "GL_EXT_rescale_normal", o(EXT_rescale_normal), GL }, + { "GL_EXT_secondary_color", o(EXT_secondary_color), GL }, + { "GL_EXT_separate_shader_objects", o(EXT_separate_shader_objects), GL }, + { "GL_EXT_separate_specular_color", o(EXT_separate_specular_color), GL }, + { "GL_EXT_shadow_funcs", o(EXT_shadow_funcs), GL }, + { "GL_EXT_shared_texture_palette", o(EXT_shared_texture_palette), GL }, + { "GL_EXT_stencil_two_side", o(EXT_stencil_two_side), GL }, + { "GL_EXT_stencil_wrap", o(EXT_stencil_wrap), GL }, + { "GL_EXT_subtexture", o(EXT_subtexture), GL }, + { "GL_EXT_texture3D", o(EXT_texture3D), GL }, + { "GL_EXT_texture_array", o(EXT_texture_array), GL }, + { "GL_EXT_texture_compression_dxt1", o(EXT_texture_compression_s3tc), GL | ES1 | ES2 }, + { "GL_EXT_texture_compression_latc", o(EXT_texture_compression_latc), GL }, + { "GL_EXT_texture_compression_rgtc", o(ARB_texture_compression_rgtc), GL }, + { "GL_EXT_texture_compression_s3tc", o(EXT_texture_compression_s3tc), GL }, + { "GL_EXT_texture_cube_map", o(ARB_texture_cube_map), GL }, + { "GL_EXT_texture_edge_clamp", o(SGIS_texture_edge_clamp), GL }, + { "GL_EXT_texture_env_add", o(EXT_texture_env_add), GL }, + { "GL_EXT_texture_env_combine", o(EXT_texture_env_combine), GL }, + { "GL_EXT_texture_env_dot3", o(EXT_texture_env_dot3), GL }, + { "GL_EXT_texture_filter_anisotropic", o(EXT_texture_filter_anisotropic), GL | ES1 | ES2 }, + { "GL_EXT_texture_format_BGRA8888", o(EXT_texture_format_BGRA8888), ES1 | ES2 }, + { "GL_EXT_texture_integer", o(EXT_texture_integer), GL }, + { "GL_EXT_texture_lod_bias", o(EXT_texture_lod_bias), GL | ES1 }, + { "GL_EXT_texture_mirror_clamp", o(EXT_texture_mirror_clamp), GL }, + { "GL_EXT_texture_object", o(EXT_texture_object), GL }, + { "GL_EXT_texture", o(EXT_texture), GL }, + { "GL_EXT_texture_rectangle", o(NV_texture_rectangle), GL }, + { "GL_EXT_texture_shared_exponent", o(EXT_texture_shared_exponent), GL }, + { "GL_EXT_texture_sRGB", o(EXT_texture_sRGB), GL }, + { "GL_EXT_texture_sRGB_decode", o(EXT_texture_sRGB_decode), GL }, + { "GL_EXT_texture_swizzle", o(EXT_texture_swizzle), GL }, + { "GL_EXT_texture_type_2_10_10_10_REV", o(dummy_true), ES2 }, + { "GL_EXT_timer_query", o(EXT_timer_query), GL }, + { "GL_EXT_transform_feedback", o(EXT_transform_feedback), GL }, + { "GL_EXT_vertex_array_bgra", o(EXT_vertex_array_bgra), GL }, + { "GL_EXT_vertex_array", o(EXT_vertex_array), GL }, + { "GL_EXT_vertex_array_set", o(EXT_vertex_array_set), GL }, + + /* OES extensions */ + { "GL_OES_blend_equation_separate", o(EXT_blend_equation_separate), ES1 }, + { "GL_OES_blend_func_separate", o(EXT_blend_func_separate), ES1 }, + { "GL_OES_blend_subtract", o(EXT_blend_subtract), ES1 }, + { "GL_OES_byte_coordinates", o(dummy_true), ES1 }, + { "GL_OES_compressed_paletted_texture", o(dummy_false), DISABLE }, + { "GL_OES_depth24", o(EXT_framebuffer_object), ES1 | ES2 }, + { "GL_OES_depth32", o(dummy_false), DISABLE }, + { "GL_OES_depth_texture", o(ARB_depth_texture), ES2 }, #if FEATURE_OES_draw_texture - { OFF, "GL_OES_draw_texture", F(OES_draw_texture) }, -#endif /* FEATURE_OES_draw_texture */ + { "GL_OES_draw_texture", o(OES_draw_texture), ES1 | ES2 }, +#endif +#if FEATURE_OES_EGL_image + /* FIXME: Mesa expects GL_OES_EGL_image to be available in OpenGL contexts. */ + { "GL_OES_EGL_image", o(OES_EGL_image), GL | ES1 | ES2 }, +#endif + { "GL_OES_element_index_uint", o(EXT_vertex_array), ES1 | ES2 }, + { "GL_OES_fbo_render_mipmap", o(EXT_framebuffer_object), ES1 | ES2 }, + { "GL_OES_fixed_point", o(dummy_true), ES1 }, + { "GL_OES_framebuffer_object", o(EXT_framebuffer_object), ES1 }, + { "GL_OES_mapbuffer", o(ARB_vertex_buffer_object), ES1 | ES2 }, + { "GL_OES_matrix_get", o(dummy_true), ES1 }, + { "GL_OES_packed_depth_stencil", o(EXT_packed_depth_stencil), ES1 | ES2 }, + { "GL_OES_point_size_array", o(dummy_true), ES1 }, + { "GL_OES_point_sprite", o(ARB_point_sprite), ES1 }, + { "GL_OES_query_matrix", o(dummy_true), ES1 }, + { "GL_OES_read_format", o(OES_read_format), GL | ES1 }, + { "GL_OES_rgb8_rgba8", o(EXT_framebuffer_object), ES1 | ES2 }, + { "GL_OES_single_precision", o(dummy_true), ES1 }, + { "GL_OES_standard_derivatives", o(OES_standard_derivatives), ES2 }, + { "GL_OES_stencil1", o(dummy_false), DISABLE }, + { "GL_OES_stencil4", o(dummy_false), DISABLE }, + { "GL_OES_stencil8", o(EXT_framebuffer_object), ES1 | ES2 }, + { "GL_OES_stencil_wrap", o(EXT_stencil_wrap), ES1 }, + { "GL_OES_texture_3D", o(EXT_texture3D), ES2 }, + { "GL_OES_texture_cube_map", o(ARB_texture_cube_map), ES1 }, + { "GL_OES_texture_env_crossbar", o(ARB_texture_env_crossbar), ES1 }, + { "GL_OES_texture_mirrored_repeat", o(ARB_texture_mirrored_repeat), ES1 }, + { "GL_OES_texture_npot", o(ARB_texture_non_power_of_two), ES2 }, + + /* Vendor extensions */ + { "GL_3DFX_texture_compression_FXT1", o(TDFX_texture_compression_FXT1), GL }, + { "GL_AMD_conservative_depth", o(AMD_conservative_depth), GL }, + { "GL_APPLE_client_storage", o(APPLE_client_storage), GL }, + { "GL_APPLE_object_purgeable", o(APPLE_object_purgeable), GL }, + { "GL_APPLE_packed_pixels", o(APPLE_packed_pixels), GL }, + { "GL_APPLE_vertex_array_object", o(APPLE_vertex_array_object), GL }, + { "GL_ATI_blend_equation_separate", o(EXT_blend_equation_separate), GL }, + { "GL_ATI_envmap_bumpmap", o(ATI_envmap_bumpmap), GL }, + { "GL_ATI_fragment_shader", o(ATI_fragment_shader), GL }, + { "GL_ATI_separate_stencil", o(ATI_separate_stencil), GL }, + { "GL_ATI_texture_compression_3dc", o(ATI_texture_compression_3dc), GL }, + { "GL_ATI_texture_env_combine3", o(ATI_texture_env_combine3), GL }, + { "GL_ATI_texture_mirror_once", o(ATI_texture_mirror_once), GL }, + { "GL_IBM_multimode_draw_arrays", o(IBM_multimode_draw_arrays), GL }, + { "GL_IBM_rasterpos_clip", o(IBM_rasterpos_clip), GL }, + { "GL_IBM_texture_mirrored_repeat", o(ARB_texture_mirrored_repeat), GL }, + { "GL_INGR_blend_func_separate", o(EXT_blend_func_separate), GL }, + { "GL_MESA_pack_invert", o(MESA_pack_invert), GL }, + { "GL_MESA_resize_buffers", o(MESA_resize_buffers), GL }, + { "GL_MESA_texture_array", o(MESA_texture_array), GL }, + { "GL_MESA_texture_signed_rgba", o(MESA_texture_signed_rgba), GL }, + { "GL_MESA_window_pos", o(ARB_window_pos), GL }, + { "GL_MESAX_texture_float", o(ARB_texture_float), GL }, + { "GL_MESA_ycbcr_texture", o(MESA_ycbcr_texture), GL }, + { "GL_NV_blend_square", o(NV_blend_square), GL }, + { "GL_NV_conditional_render", o(NV_conditional_render), GL }, + { "GL_NV_depth_clamp", o(ARB_depth_clamp), GL }, + { "GL_NV_fragment_program", o(NV_fragment_program), GL }, + { "GL_NV_fragment_program_option", o(NV_fragment_program_option), GL }, + { "GL_NV_light_max_exponent", o(NV_light_max_exponent), GL }, + { "GL_NV_packed_depth_stencil", o(EXT_packed_depth_stencil), GL }, + { "GL_NV_point_sprite", o(NV_point_sprite), GL }, + { "GL_NV_primitive_restart", o(NV_primitive_restart), GL }, + { "GL_NV_texgen_reflection", o(NV_texgen_reflection), GL }, + { "GL_NV_texture_barrier", o(NV_texture_barrier), GL }, + { "GL_NV_texture_env_combine4", o(NV_texture_env_combine4), GL }, + { "GL_NV_texture_rectangle", o(NV_texture_rectangle), GL }, + { "GL_NV_vertex_program1_1", o(NV_vertex_program1_1), GL }, + { "GL_NV_vertex_program", o(NV_vertex_program), GL }, + { "GL_S3_s3tc", o(S3_s3tc), GL }, + { "GL_SGIS_generate_mipmap", o(SGIS_generate_mipmap), GL }, + { "GL_SGIS_texture_border_clamp", o(ARB_texture_border_clamp), GL }, + { "GL_SGIS_texture_edge_clamp", o(SGIS_texture_edge_clamp), GL }, + { "GL_SGIS_texture_lod", o(SGIS_texture_lod), GL }, + { "GL_SUN_multi_draw_arrays", o(EXT_multi_draw_arrays), GL }, + + { 0, 0, 0 }, }; +/** + * Given an extension name, lookup up the corresponding member of struct + * gl_extensions and return that member's offset (in bytes). If the name is + * not found in the \c extension_table, return 0. + * + * \param name Name of extension. + * \return Offset of member in struct gl_extensions. + */ +static size_t +name_to_offset(const char* name) +{ + const struct extension *i; + + if (name == 0) + return 0; + + for (i = extension_table; i->name != 0; ++i) { + if (strcmp(name, i->name) == 0) + return i->offset; + } + + return 0; +} + + +/** + * \brief Extensions enabled by default. + * + * These extensions are enabled by _mesa_init_extensions(). + * + * XXX: Should these defaults also apply to GLES? + */ +static const size_t default_extensions[] = { + o(ARB_copy_buffer), + o(ARB_draw_buffers), + o(ARB_multisample), + o(ARB_texture_compression), + o(ARB_transpose_matrix), + o(ARB_vertex_buffer_object), + o(ARB_window_pos), + + o(EXT_abgr), + o(EXT_bgra), + o(EXT_compiled_vertex_array), + o(EXT_copy_texture), + o(EXT_draw_range_elements), + o(EXT_multi_draw_arrays), + o(EXT_packed_pixels), + o(EXT_polygon_offset), + o(EXT_rescale_normal), + o(EXT_separate_specular_color), + o(EXT_subtexture), + o(EXT_texture), + o(EXT_texture3D), + o(EXT_texture_object), + o(EXT_vertex_array), + + o(OES_read_format), + o(OES_standard_derivatives), + + /* Vendor Extensions */ + o(APPLE_packed_pixels), + o(IBM_multimode_draw_arrays), + o(IBM_rasterpos_clip), + o(NV_light_max_exponent), + o(NV_texgen_reflection), + o(SGIS_generate_mipmap), + o(SGIS_texture_edge_clamp), + o(SGIS_texture_lod), + + 0, +}; + /** * Enable all extensions suitable for a software-only renderer. @@ -237,6 +385,7 @@ _mesa_enable_sw_extensions(struct gl_context *ctx) ctx->Extensions.ARB_depth_texture = GL_TRUE; /*ctx->Extensions.ARB_draw_buffers = GL_TRUE;*/ ctx->Extensions.ARB_draw_elements_base_vertex = GL_TRUE; + ctx->Extensions.ARB_draw_instanced = GL_TRUE; ctx->Extensions.ARB_explicit_attrib_location = GL_TRUE; ctx->Extensions.ARB_fragment_coord_conventions = GL_TRUE; #if FEATURE_ARB_fragment_program @@ -249,7 +398,8 @@ _mesa_enable_sw_extensions(struct gl_context *ctx) #if FEATURE_ARB_framebuffer_object ctx->Extensions.ARB_framebuffer_object = GL_TRUE; #endif -#if FEATURE_ARB_geometry_shader4 +#if FEATURE_ARB_geometry_shader4 && 0 + /* XXX re-enable when GLSL compiler again supports geometry shaders */ ctx->Extensions.ARB_geometry_shader4 = GL_TRUE; #endif ctx->Extensions.ARB_half_float_pixel = GL_TRUE; @@ -258,6 +408,7 @@ _mesa_enable_sw_extensions(struct gl_context *ctx) ctx->Extensions.ARB_multitexture = GL_TRUE; #if FEATURE_queryobj ctx->Extensions.ARB_occlusion_query = GL_TRUE; + ctx->Extensions.ARB_occlusion_query2 = GL_TRUE; #endif ctx->Extensions.ARB_point_sprite = GL_TRUE; #if FEATURE_ARB_shader_objects @@ -278,6 +429,7 @@ _mesa_enable_sw_extensions(struct gl_context *ctx) ctx->Extensions.ARB_texture_mirrored_repeat = GL_TRUE; ctx->Extensions.ARB_texture_non_power_of_two = GL_TRUE; ctx->Extensions.ARB_texture_rg = GL_TRUE; + ctx->Extensions.ARB_texture_compression_rgtc = GL_TRUE; ctx->Extensions.ARB_vertex_array_object = GL_TRUE; #if FEATURE_ARB_vertex_program ctx->Extensions.ARB_vertex_program = GL_TRUE; @@ -299,6 +451,7 @@ _mesa_enable_sw_extensions(struct gl_context *ctx) #if FEATURE_ATI_fragment_shader ctx->Extensions.ATI_fragment_shader = GL_TRUE; #endif + ctx->Extensions.ATI_texture_compression_3dc = GL_TRUE; ctx->Extensions.ATI_texture_env_combine3 = GL_TRUE; ctx->Extensions.ATI_texture_mirror_once = GL_TRUE; ctx->Extensions.ATI_separate_stencil = GL_TRUE; @@ -334,6 +487,7 @@ _mesa_enable_sw_extensions(struct gl_context *ctx) ctx->Extensions.EXT_stencil_wrap = GL_TRUE; ctx->Extensions.EXT_stencil_two_side = GL_TRUE; ctx->Extensions.EXT_texture_array = GL_TRUE; + ctx->Extensions.EXT_texture_compression_latc = GL_TRUE; ctx->Extensions.EXT_texture_env_add = GL_TRUE; ctx->Extensions.EXT_texture_env_combine = GL_TRUE; ctx->Extensions.EXT_texture_env_dot3 = GL_TRUE; @@ -341,6 +495,7 @@ _mesa_enable_sw_extensions(struct gl_context *ctx) ctx->Extensions.EXT_texture_lod_bias = GL_TRUE; #if FEATURE_EXT_texture_sRGB ctx->Extensions.EXT_texture_sRGB = GL_TRUE; + ctx->Extensions.EXT_texture_sRGB_decode = GL_TRUE; #endif ctx->Extensions.EXT_texture_swizzle = GL_TRUE; #if FEATURE_EXT_transform_feedback @@ -369,7 +524,6 @@ _mesa_enable_sw_extensions(struct gl_context *ctx) #if FEATURE_NV_fragment_program && FEATURE_ARB_fragment_program ctx->Extensions.NV_fragment_program_option = GL_TRUE; #endif - ctx->Extensions.SGI_texture_color_table = GL_TRUE; /*ctx->Extensions.SGIS_generate_mipmap = GL_TRUE;*/ ctx->Extensions.SGIS_texture_edge_clamp = GL_TRUE; #if FEATURE_ARB_vertex_program || FEATURE_ARB_fragment_program @@ -510,8 +664,7 @@ _mesa_enable_2_1_extensions(struct gl_context *ctx) static GLboolean set_extension( struct gl_context *ctx, const char *name, GLboolean state ) { - GLboolean *base = (GLboolean *) &ctx->Extensions; - GLuint i; + size_t offset; if (ctx->Extensions.String) { /* The string was already queried - can't change it now! */ @@ -519,16 +672,20 @@ set_extension( struct gl_context *ctx, const char *name, GLboolean state ) return GL_FALSE; } - for (i = 0 ; i < Elements(default_extensions) ; i++) { - if (strcmp(default_extensions[i].name, name) == 0) { - if (default_extensions[i].flag_offset) { - GLboolean *enabled = base + default_extensions[i].flag_offset; - *enabled = state; - } - return GL_TRUE; - } + offset = name_to_offset(name); + if (offset == 0) { + _mesa_problem(ctx, "Trying to enable/disable unknown extension %s", + name); + return GL_FALSE; + } else if (offset == o(dummy_true) && state == GL_FALSE) { + _mesa_problem(ctx, "Trying to disable a permanently enabled extension: " + "%s", name); + return GL_FALSE; + } else { + GLboolean *base = (GLboolean *) &ctx->Extensions; + base[offset] = state; + return GL_TRUE; } - return GL_FALSE; } @@ -557,130 +714,112 @@ _mesa_disable_extension( struct gl_context *ctx, const char *name ) /** - * Check if the i-th extension is enabled. - */ -static GLboolean -extension_enabled(struct gl_context *ctx, GLuint index) -{ - const GLboolean *base = (const GLboolean *) &ctx->Extensions; - if (!default_extensions[index].flag_offset || - *(base + default_extensions[index].flag_offset)) { - return GL_TRUE; - } - else { - return GL_FALSE; - } -} - - -/** * Test if the named extension is enabled in this context. */ GLboolean _mesa_extension_is_enabled( struct gl_context *ctx, const char *name ) { - GLuint i; - - for (i = 0 ; i < Elements(default_extensions) ; i++) { - if (strcmp(default_extensions[i].name, name) == 0) { - return extension_enabled(ctx, i); - } - } - return GL_FALSE; -} + size_t offset; + GLboolean *base; + if (name == 0) + return GL_FALSE; -/** - * Append string 'b' onto string 'a'. Free 'a' and return new string. - */ -static char * -append(const char *a, const char *b) -{ - const GLuint aLen = a ? strlen(a) : 0; - const GLuint bLen = b ? strlen(b) : 0; - char *s = calloc(1, aLen + bLen + 1); - if (s) { - if (a) - memcpy(s, a, aLen); - if (b) - memcpy(s + aLen, b, bLen); - s[aLen + bLen] = '\0'; - } - if (a) - free((void *) a); - return s; + offset = name_to_offset(name); + if (offset == 0) + return GL_FALSE; + base = (GLboolean *) &ctx->Extensions; + return base[offset]; } /** - * Check the MESA_EXTENSION_OVERRIDE env var. - * For extension names that are recognized, turn them on. For extension - * names that are recognized and prefixed with '-', turn them off. - * Return a string of the unknown/leftover names. + * \brief Apply the \c MESA_EXTENSION_OVERRIDE environment variable. + * + * \c MESA_EXTENSION_OVERRIDE is a space-separated list of extensions to + * enable or disable. The list is processed thus: + * - Enable recognized extension names that are prefixed with '+'. + * - Disable recognized extension names that are prefixed with '-'. + * - Enable recognized extension names that are not prefixed. + * - Collect unrecognized extension names in a new string. + * + * \return Space-separated list of unrecognized extension names (which must + * be freed). Does not return \c NULL. */ -static const char * +static char * get_extension_override( struct gl_context *ctx ) { - const char *envExt = _mesa_getenv("MESA_EXTENSION_OVERRIDE"); - char *extraExt = NULL; - char ext[1000]; - GLuint extLen = 0; - GLuint i; - GLboolean disableExt = GL_FALSE; - - if (!envExt) - return NULL; + const char *env_const= _mesa_getenv("MESA_EXTENSION_OVERRIDE"); + char *env; + char *ext; + char *extra_exts; + int len; + + if (env_const == NULL) { + /* Return the empty string rather than NULL. This simplifies the logic + * of client functions. */ + return calloc(1, sizeof(char)); + } - for (i = 0; ; i++) { - if (envExt[i] == '\0' || envExt[i] == ' ') { - /* terminate/process 'ext' if extLen > 0 */ - if (extLen > 0) { - assert(extLen < sizeof(ext)); - /* enable extension named by 'ext' */ - ext[extLen] = 0; - if (!set_extension(ctx, ext, !disableExt)) { - /* unknown extension name, append it to extraExt */ - if (extraExt) { - extraExt = append(extraExt, " "); - } - extraExt = append(extraExt, ext); - } - extLen = 0; - disableExt = GL_FALSE; - } - if (envExt[i] == '\0') - break; - } - else if (envExt[i] == '-') { - disableExt = GL_TRUE; + /* extra_exts: List of unrecognized extensions. */ + extra_exts = calloc(strlen(env_const), sizeof(char)); + + /* Copy env_const because strtok() is destructive. */ + env = strdup(env_const); + for (ext = strtok(env, " "); ext != NULL; ext = strtok(NULL, " ")) { + int enable; + int recognized; + switch (ext[0]) { + case '+': + enable = 1; + ++ext; + break; + case '-': + enable = 0; + ++ext; + break; + default: + enable = 1; + break; } - else { - /* accumulate this non-space character */ - ext[extLen++] = envExt[i]; + recognized = set_extension(ctx, ext, enable); + if (!recognized) { + strcat(extra_exts, ext); + strcat(extra_exts, " "); } } - return extraExt; + /* Remove trailing space. */ + len = strlen(extra_exts); + if (extra_exts[len - 1] == ' ') + extra_exts[len - 1] = '\0'; + + return extra_exts; } /** - * Run through the default_extensions array above and set the - * ctx->Extensions.ARB/EXT_* flags accordingly. - * To be called during context initialization. + * \brief Initialize extension tables and enable default extensions. + * + * This should be called during context initialization. + * Note: Sets gl_extensions.dummy_true to true. */ void _mesa_init_extensions( struct gl_context *ctx ) { GLboolean *base = (GLboolean *) &ctx->Extensions; - GLuint i; - - for (i = 0 ; i < Elements(default_extensions) ; i++) { - if (default_extensions[i].enabled && - default_extensions[i].flag_offset) { - *(base + default_extensions[i].flag_offset) = GL_TRUE; - } - } + GLboolean *sentinel = base + o(extension_sentinel); + GLboolean *i; + const size_t *j; + + /* First, turn all extensions off. */ + for (i = base; i != sentinel; ++i) + *i = GL_FALSE; + + /* Then, selectively turn default extensions on. */ + ctx->Extensions.dummy_true = GL_TRUE; + for (j = default_extensions; *j != 0; ++j) + base[*j] = GL_TRUE; } @@ -688,258 +827,46 @@ _mesa_init_extensions( struct gl_context *ctx ) * Construct the GL_EXTENSIONS string. Called the first time that * glGetString(GL_EXTENSIONS) is called. */ -static GLubyte * -compute_extensions( struct gl_context *ctx ) +GLubyte* +_mesa_make_extension_string(struct gl_context *ctx) { - const char *extraExt = get_extension_override(ctx); - GLuint extStrLen = 0; - char *s; - GLuint i; - - /* first, compute length of the extension string */ - for (i = 0 ; i < Elements(default_extensions) ; i++) { - if (extension_enabled(ctx, i)) { - extStrLen += (GLuint) strlen(default_extensions[i].name) + 1; - } - } - - if (extraExt) - extStrLen += strlen(extraExt) + 1; /* +1 for space */ - - /* allocate the extension string */ - s = (char *) malloc(extStrLen); - if (!s) - return NULL; + /* The extension string. */ + char *exts = 0; + /* Length of extension string. */ + size_t length = 0; + /* String of extra extensions. */ + char *extra_extensions = get_extension_override(ctx); + GLboolean *base = (GLboolean *) &ctx->Extensions; + const struct extension *i; - /* second, build the extension string */ - extStrLen = 0; - for (i = 0 ; i < Elements(default_extensions) ; i++) { - if (extension_enabled(ctx, i)) { - GLuint len = (GLuint) strlen(default_extensions[i].name); - memcpy(s + extStrLen, default_extensions[i].name, len); - extStrLen += len; - s[extStrLen] = ' '; - extStrLen++; + /* Compute length of the extension string. */ + for (i = extension_table; i->name != 0; ++i) { + if (base[i->offset] && (i->api_set & (1 << ctx->API))) { + length += strlen(i->name) + 1; /* +1 for space */ } } - ASSERT(extStrLen > 0); - - s[extStrLen - 1] = 0; /* -1 to overwrite trailing the ' ' */ + if (extra_extensions != NULL) + length += 1 + strlen(extra_extensions); /* +1 for space */ - if (extraExt) { - s = append(s, " "); - s = append(s, extraExt); + exts = (char *) calloc(length + 1, sizeof(char)); + if (exts == NULL) { + free(extra_extensions); + return NULL; } - return (GLubyte *) s; -} - -static size_t -append_extension(GLubyte **str, const char *ext) -{ - GLubyte *s = *str; - size_t len = strlen(ext); - - if (s) { - memcpy(s, ext, len); - s[len++] = ' '; - s[len] = '\0'; - - *str += len; - } - else { - len++; + /* Build the extension string.*/ + for (i = extension_table; i->name != 0; ++i) { + if (base[i->offset] && (i->api_set & (1 << ctx->API))) { + strcat(exts, i->name); + strcat(exts, " "); + } } - - return len; -} - - -static size_t -make_extension_string_es1(const struct gl_context *ctx, GLubyte *str) -{ - size_t len = 0; - - /* Core additions */ - len += append_extension(&str, "GL_OES_byte_coordinates"); - len += append_extension(&str, "GL_OES_fixed_point"); - len += append_extension(&str, "GL_OES_single_precision"); - len += append_extension(&str, "GL_OES_matrix_get"); - - /* 1.1 required extensions */ - len += append_extension(&str, "GL_OES_read_format"); - len += append_extension(&str, "GL_OES_compressed_paletted_texture"); - len += append_extension(&str, "GL_OES_point_size_array"); - len += append_extension(&str, "GL_OES_point_sprite"); - - /* 1.1 deprecated extensions */ - len += append_extension(&str, "GL_OES_query_matrix"); - -#if FEATURE_OES_draw_texture - if (ctx->Extensions.OES_draw_texture) - len += append_extension(&str, "GL_OES_draw_texture"); -#endif - - if (ctx->Extensions.EXT_blend_equation_separate) - len += append_extension(&str, "GL_OES_blend_equation_separate"); - if (ctx->Extensions.EXT_blend_func_separate) - len += append_extension(&str, "GL_OES_blend_func_separate"); - if (ctx->Extensions.EXT_blend_subtract) - len += append_extension(&str, "GL_OES_blend_subtract"); - - if (ctx->Extensions.EXT_stencil_wrap) - len += append_extension(&str, "GL_OES_stencil_wrap"); - - if (ctx->Extensions.ARB_texture_cube_map) - len += append_extension(&str, "GL_OES_texture_cube_map"); - if (ctx->Extensions.ARB_texture_env_crossbar) - len += append_extension(&str, "GL_OES_texture_env_crossbar"); - if (ctx->Extensions.ARB_texture_mirrored_repeat) - len += append_extension(&str, "GL_OES_texture_mirrored_repeat"); - - if (ctx->Extensions.ARB_framebuffer_object) { - len += append_extension(&str, "GL_OES_framebuffer_object"); - len += append_extension(&str, "GL_OES_depth24"); - len += append_extension(&str, "GL_OES_depth32"); - len += append_extension(&str, "GL_OES_fbo_render_mipmap"); - len += append_extension(&str, "GL_OES_rgb8_rgba8"); - len += append_extension(&str, "GL_OES_stencil1"); - len += append_extension(&str, "GL_OES_stencil4"); - len += append_extension(&str, "GL_OES_stencil8"); + if (extra_extensions != 0) { + strcat(exts, extra_extensions); + free(extra_extensions); } - if (ctx->Extensions.EXT_vertex_array) - len += append_extension(&str, "GL_OES_element_index_uint"); - if (ctx->Extensions.ARB_vertex_buffer_object) - len += append_extension(&str, "GL_OES_mapbuffer"); - if (ctx->Extensions.EXT_texture_filter_anisotropic) - len += append_extension(&str, "GL_EXT_texture_filter_anisotropic"); - - /* some applications check this for NPOT support */ - if (ctx->Extensions.ARB_texture_non_power_of_two) - len += append_extension(&str, "GL_ARB_texture_non_power_of_two"); - - if (ctx->Extensions.EXT_texture_compression_s3tc) - len += append_extension(&str, "GL_EXT_texture_compression_dxt1"); - if (ctx->Extensions.EXT_texture_lod_bias) - len += append_extension(&str, "GL_EXT_texture_lod_bias"); - if (ctx->Extensions.EXT_blend_minmax) - len += append_extension(&str, "GL_EXT_blend_minmax"); - if (ctx->Extensions.EXT_multi_draw_arrays) - len += append_extension(&str, "GL_EXT_multi_draw_arrays"); - -#if FEATURE_OES_EGL_image - if (ctx->Extensions.OES_EGL_image) - len += append_extension(&str, "GL_OES_EGL_image"); -#endif - - return len; -} - - -static GLubyte * -compute_extensions_es1(const struct gl_context *ctx) -{ - GLubyte *s; - unsigned int len; - - len = make_extension_string_es1(ctx, NULL); - s = malloc(len + 1); - if (!s) - return NULL; - make_extension_string_es1(ctx, s); - - return s; -} - -static size_t -make_extension_string_es2(const struct gl_context *ctx, GLubyte *str) -{ - size_t len = 0; - - len += append_extension(&str, "GL_OES_compressed_paletted_texture"); - - if (ctx->Extensions.ARB_framebuffer_object) { - len += append_extension(&str, "GL_OES_depth24"); - len += append_extension(&str, "GL_OES_depth32"); - len += append_extension(&str, "GL_OES_fbo_render_mipmap"); - len += append_extension(&str, "GL_OES_rgb8_rgba8"); - len += append_extension(&str, "GL_OES_stencil1"); - len += append_extension(&str, "GL_OES_stencil4"); - } - - if (ctx->Extensions.EXT_vertex_array) - len += append_extension(&str, "GL_OES_element_index_uint"); - if (ctx->Extensions.ARB_vertex_buffer_object) - len += append_extension(&str, "GL_OES_mapbuffer"); - -#if 0 - /* disabled because of missing GLSL support */ - if (ctx->Extensions.EXT_texture3D) - len += append_extension(&str, "GL_OES_texture_3D"); -#endif - - if (ctx->Extensions.ARB_texture_non_power_of_two) - len += append_extension(&str, "GL_OES_texture_npot"); - if (ctx->Extensions.EXT_texture_filter_anisotropic) - len += append_extension(&str, "GL_EXT_texture_filter_anisotropic"); - - len += append_extension(&str, "GL_EXT_texture_type_2_10_10_10_REV"); - if (ctx->Extensions.ARB_depth_texture) - len += append_extension(&str, "GL_OES_depth_texture"); - if (ctx->Extensions.EXT_packed_depth_stencil) - len += append_extension(&str, "GL_OES_packed_depth_stencil"); - if (ctx->Extensions.ARB_fragment_shader) - len += append_extension(&str, "GL_OES_standard_derivatives"); - - if (ctx->Extensions.EXT_texture_compression_s3tc) - len += append_extension(&str, "GL_EXT_texture_compression_dxt1"); - if (ctx->Extensions.EXT_blend_minmax) - len += append_extension(&str, "GL_EXT_blend_minmax"); - if (ctx->Extensions.EXT_multi_draw_arrays) - len += append_extension(&str, "GL_EXT_multi_draw_arrays"); - -#if FEATURE_OES_EGL_image - if (ctx->Extensions.OES_EGL_image) - len += append_extension(&str, "GL_OES_EGL_image"); -#endif - - if (ctx->Extensions.EXT_texture_format_BGRA8888) - len += append_extension(&str, "GL_EXT_texture_format_BGRA8888"); - - return len; -} - -static GLubyte * -compute_extensions_es2(struct gl_context *ctx) -{ - GLubyte *s; - unsigned int len; - - len = make_extension_string_es2(ctx, NULL); - s = malloc(len + 1); - if (!s) - return NULL; - make_extension_string_es2(ctx, s); - - return s; -} - - -GLubyte * -_mesa_make_extension_string(struct gl_context *ctx) -{ - switch (ctx->API) { - case API_OPENGL: - return compute_extensions(ctx); - case API_OPENGLES2: - return compute_extensions_es2(ctx); - case API_OPENGLES: - return compute_extensions_es1(ctx); - default: - assert(0); - return NULL; - } + return (GLubyte *) exts; } /** @@ -948,38 +875,42 @@ _mesa_make_extension_string(struct gl_context *ctx) GLuint _mesa_get_extension_count(struct gl_context *ctx) { - GLuint i; + GLboolean *base; + const struct extension *i; /* only count once */ - if (!ctx->Extensions.Count) { - for (i = 0; i < Elements(default_extensions); i++) { - if (extension_enabled(ctx, i)) { - ctx->Extensions.Count++; - } + if (ctx->Extensions.Count != 0) + return ctx->Extensions.Count; + + base = (GLboolean *) &ctx->Extensions; + for (i = extension_table; i->name != 0; ++i) { + if (base[i->offset]) { + ctx->Extensions.Count++; } } - - if (0) - _mesa_debug(ctx, "%u of %d extensions enabled\n", ctx->Extensions.Count, - (int) Elements(default_extensions)); - return ctx->Extensions.Count; } - /** * Return name of i-th enabled extension */ const GLubyte * _mesa_get_enabled_extension(struct gl_context *ctx, GLuint index) { - GLuint i; + const GLboolean *base; + size_t n; + const struct extension *i; + + if (index < 0) + return NULL; - for (i = 0; i < Elements(default_extensions); i++) { - if (extension_enabled(ctx, i)) { - if (index == 0) - return (const GLubyte *) default_extensions[i].name; - index--; + base = (GLboolean*) &ctx->Extensions; + n = 0; + for (i = extension_table; i->name != 0; ++i) { + if (n == index && base[i->offset]) { + return (GLubyte*) i->name; + } else if (base[i->offset]) { + ++n; } } diff --git a/src/mesa/main/fbobject.c b/src/mesa/main/fbobject.c index 975063d0d7..ffdd084256 100644 --- a/src/mesa/main/fbobject.c +++ b/src/mesa/main/fbobject.c @@ -40,6 +40,8 @@ #include "framebuffer.h" #include "hash.h" #include "macros.h" +#include "mfeatures.h" +#include "mtypes.h" #include "renderbuffer.h" #include "state.h" #include "teximage.h" @@ -158,6 +160,29 @@ invalidate_framebuffer(struct gl_framebuffer *fb) /** + * Return the gl_framebuffer object which corresponds to the given + * framebuffer target, such as GL_DRAW_FRAMEBUFFER. + * Check support for GL_EXT_framebuffer_blit to determine if certain + * targets are legal. + * \return gl_framebuffer pointer or NULL if target is illegal + */ +static struct gl_framebuffer * +get_framebuffer_target(struct gl_context *ctx, GLenum target) +{ + switch (target) { + case GL_DRAW_FRAMEBUFFER: + return ctx->Extensions.EXT_framebuffer_blit ? ctx->DrawBuffer : NULL; + case GL_READ_FRAMEBUFFER: + return ctx->Extensions.EXT_framebuffer_blit ? ctx->ReadBuffer : NULL; + case GL_FRAMEBUFFER_EXT: + return ctx->DrawBuffer; + default: + return NULL; + } +} + + +/** * Given a GL_*_ATTACHMENTn token, return a pointer to the corresponding * gl_renderbuffer_attachment object. * This function is only used for user-created FB objects, not the @@ -359,6 +384,7 @@ _mesa_framebuffer_renderbuffer(struct gl_context *ctx, assert(att); _mesa_set_renderbuffer_attachment(ctx, att, rb); } + rb->AttachedAnytime = GL_TRUE; } else { _mesa_remove_attachment(ctx, att); @@ -371,6 +397,37 @@ _mesa_framebuffer_renderbuffer(struct gl_context *ctx, /** + * Fallback for ctx->Driver.ValidateFramebuffer() + * Check if the renderbuffer's formats are supported by the software + * renderer. + * Drivers should probably override this. + */ +void +_mesa_validate_framebuffer(struct gl_context *ctx, struct gl_framebuffer *fb) +{ + gl_buffer_index buf; + for (buf = 0; buf < BUFFER_COUNT; buf++) { + const struct gl_renderbuffer *rb = fb->Attachment[buf].Renderbuffer; + if (rb) { + switch (rb->_BaseFormat) { + case GL_ALPHA: + case GL_LUMINANCE_ALPHA: + case GL_LUMINANCE: + case GL_INTENSITY: + case GL_RED: + case GL_RG: + fb->_Status = GL_FRAMEBUFFER_UNSUPPORTED; + return; + default: + /* render buffer format is supported by software rendering */ + ; + } + } + } +} + + +/** * For debug only. */ static void @@ -402,8 +459,8 @@ fbo_incomplete(const char *msg, int index) /** * Is the given base format a legal format for a color renderbuffer? */ -static GLboolean -is_legal_color_format(const struct gl_context *ctx, GLenum baseFormat) +GLboolean +_mesa_is_legal_color_format(const struct gl_context *ctx, GLenum baseFormat) { switch (baseFormat) { case GL_RGB: @@ -488,7 +545,7 @@ test_attachment_completeness(const struct gl_context *ctx, GLenum format, baseFormat = _mesa_get_format_base_format(texImage->TexFormat); if (format == GL_COLOR) { - if (!is_legal_color_format(ctx, baseFormat)) { + if (!_mesa_is_legal_color_format(ctx, baseFormat)) { att_incomplete("bad format"); att->Complete = GL_FALSE; return; @@ -542,8 +599,7 @@ test_attachment_completeness(const struct gl_context *ctx, GLenum format, return; } if (format == GL_COLOR) { - if (baseFormat != GL_RGB && - baseFormat != GL_RGBA) { + if (!_mesa_is_legal_color_format(ctx, baseFormat)) { att_incomplete("bad renderbuffer color format"); att->Complete = GL_FALSE; return; @@ -620,7 +676,7 @@ _mesa_test_framebuffer_completeness(struct gl_context *ctx, for (i = -2; i < (GLint) ctx->Const.MaxColorAttachments; i++) { struct gl_renderbuffer_attachment *att; GLenum f; - gl_format mesaFormat; + gl_format attFormat; /* * XXX for ARB_fbo, only check color buffers that are named by @@ -667,9 +723,9 @@ _mesa_test_framebuffer_completeness(struct gl_context *ctx, minHeight = MIN2(minHeight, texImg->Height); maxHeight = MAX2(maxHeight, texImg->Height); f = texImg->_BaseFormat; - mesaFormat = texImg->TexFormat; + attFormat = texImg->TexFormat; numImages++; - if (!is_legal_color_format(ctx, f) && + if (!_mesa_is_legal_color_format(ctx, f) && !is_legal_depth_format(ctx, f)) { fb->_Status = GL_FRAMEBUFFER_INCOMPLETE_FORMATS_EXT; fbo_incomplete("texture attachment incomplete", -1); @@ -682,7 +738,7 @@ _mesa_test_framebuffer_completeness(struct gl_context *ctx, minHeight = MIN2(minHeight, att->Renderbuffer->Height); maxHeight = MAX2(minHeight, att->Renderbuffer->Height); f = att->Renderbuffer->InternalFormat; - mesaFormat = att->Renderbuffer->Format; + attFormat = att->Renderbuffer->Format; numImages++; } else { @@ -696,7 +752,7 @@ _mesa_test_framebuffer_completeness(struct gl_context *ctx, } /* check if integer color */ - fb->_IntegerColor = _mesa_is_format_integer_color(mesaFormat); + fb->_IntegerColor = _mesa_is_format_integer_color(attFormat); /* Error-check width, height, format, samples */ @@ -793,7 +849,7 @@ _mesa_test_framebuffer_completeness(struct gl_context *ctx, fb->Height = minHeight; /* finally, update the visual info for the framebuffer */ - _mesa_update_framebuffer_visual(fb); + _mesa_update_framebuffer_visual(ctx, fb); } } @@ -960,26 +1016,53 @@ _mesa_GenRenderbuffersEXT(GLsizei n, GLuint *renderbuffers) /** * Given an internal format token for a render buffer, return the - * corresponding base format. - * This is very similar to _mesa_base_tex_format() but the set of valid - * internal formats is somewhat different. + * corresponding base format (one of GL_RGB, GL_RGBA, GL_STENCIL_INDEX, + * GL_DEPTH_COMPONENT, GL_DEPTH_STENCIL_EXT, GL_ALPHA, GL_LUMINANCE, + * GL_LUMINANCE_ALPHA, GL_INTENSITY, etc). + * + * This is similar to _mesa_base_tex_format() but the set of valid + * internal formats is different. * - * \return one of GL_RGB, GL_RGBA, GL_STENCIL_INDEX, GL_DEPTH_COMPONENT - * GL_DEPTH_STENCIL_EXT or zero if error. + * Note that even if a format is determined to be legal here, validation + * of the FBO may fail if the format is not supported by the driver/GPU. * - * XXX in the future when we support red-only and red-green formats - * we'll also return GL_RED and GL_RG. + * \param internalFormat as passed to glRenderbufferStorage() + * \return the base internal format, or 0 if internalFormat is illegal */ GLenum _mesa_base_fbo_format(struct gl_context *ctx, GLenum internalFormat) { + /* + * Notes: some formats such as alpha, luminance, etc. were added + * with GL_ARB_framebuffer_object. + */ switch (internalFormat) { case GL_ALPHA: case GL_ALPHA4: case GL_ALPHA8: case GL_ALPHA12: case GL_ALPHA16: - return GL_ALPHA; + return ctx->Extensions.ARB_framebuffer_object ? GL_ALPHA : 0; + case GL_LUMINANCE: + case GL_LUMINANCE4: + case GL_LUMINANCE8: + case GL_LUMINANCE12: + case GL_LUMINANCE16: + return ctx->Extensions.ARB_framebuffer_object ? GL_LUMINANCE : 0; + case GL_LUMINANCE_ALPHA: + case GL_LUMINANCE4_ALPHA4: + case GL_LUMINANCE6_ALPHA2: + case GL_LUMINANCE8_ALPHA8: + case GL_LUMINANCE12_ALPHA4: + case GL_LUMINANCE12_ALPHA12: + case GL_LUMINANCE16_ALPHA16: + return ctx->Extensions.ARB_framebuffer_object ? GL_LUMINANCE_ALPHA : 0; + case GL_INTENSITY: + case GL_INTENSITY4: + case GL_INTENSITY8: + case GL_INTENSITY12: + case GL_INTENSITY16: + return ctx->Extensions.ARB_framebuffer_object ? GL_INTENSITY : 0; case GL_RGB: case GL_R3_G3_B2: case GL_RGB4: @@ -988,6 +1071,7 @@ _mesa_base_fbo_format(struct gl_context *ctx, GLenum internalFormat) case GL_RGB10: case GL_RGB12: case GL_RGB16: + case GL_SRGB8_EXT: return GL_RGB; case GL_RGBA: case GL_RGBA2: @@ -998,6 +1082,7 @@ _mesa_base_fbo_format(struct gl_context *ctx, GLenum internalFormat) case GL_RGBA12: case GL_RGBA16: case GL_RGBA16_SNORM: + case GL_SRGB8_ALPHA8_EXT: return GL_RGBA; case GL_STENCIL_INDEX: case GL_STENCIL_INDEX1_EXT: @@ -1016,13 +1101,46 @@ _mesa_base_fbo_format(struct gl_context *ctx, GLenum internalFormat) return GL_DEPTH_STENCIL_EXT; else return 0; - /* XXX add floating point formats eventually */ + case GL_RED: + case GL_R8: + case GL_R16: + return ctx->Extensions.ARB_texture_rg ? GL_RED : 0; + case GL_RG: + case GL_RG8: + case GL_RG16: + return ctx->Extensions.ARB_texture_rg ? GL_RG : 0; + /* XXX add floating point and integer formats eventually */ default: return 0; } } +/** + * Invalidate a renderbuffer attachment. Called from _mesa_HashWalk(). + */ +static void +invalidate_rb(GLuint key, void *data, void *userData) +{ + struct gl_framebuffer *fb = (struct gl_framebuffer *) data; + struct gl_renderbuffer *rb = (struct gl_renderbuffer *) userData; + + /* If this is a user-created FBO */ + if (fb->Name) { + GLuint i; + for (i = 0; i < BUFFER_COUNT; i++) { + struct gl_renderbuffer_attachment *att = fb->Attachment + i; + if (att->Type == GL_RENDERBUFFER && + att->Renderbuffer == rb) { + /* Mark fb status as indeterminate to force re-validation */ + fb->_Status = 0; + return; + } + } + } +} + + /** sentinal value, see below */ #define NO_SAMPLES 1000 @@ -1115,12 +1233,10 @@ renderbuffer_storage(GLenum target, GLenum internalFormat, rb->NumSamples = 0; } - /* - test_framebuffer_completeness(ctx, fb); - */ - /* XXX if this renderbuffer is attached anywhere, invalidate attachment - * points??? - */ + /* Invalidate the framebuffers the renderbuffer is attached in. */ + if (rb->AttachedAnytime) { + _mesa_HashWalk(ctx->Shared->FrameBuffers, invalidate_rb, rb); + } } @@ -1172,8 +1288,17 @@ get_component_bits(GLenum pname, GLenum baseFormat, gl_format format) switch (pname) { case GL_RENDERBUFFER_RED_SIZE_EXT: case GL_FRAMEBUFFER_ATTACHMENT_RED_SIZE: + if (baseFormat == GL_RGB || baseFormat == GL_RGBA || + baseFormat == GL_RG || baseFormat == GL_RED) + return _mesa_get_format_bits(format, pname); + else + return 0; case GL_RENDERBUFFER_GREEN_SIZE_EXT: case GL_FRAMEBUFFER_ATTACHMENT_GREEN_SIZE: + if (baseFormat == GL_RGB || baseFormat == GL_RGBA || baseFormat == GL_RG) + return _mesa_get_format_bits(format, pname); + else + return 0; case GL_RENDERBUFFER_BLUE_SIZE_EXT: case GL_FRAMEBUFFER_ATTACHMENT_BLUE_SIZE: if (baseFormat == GL_RGB || baseFormat == GL_RGBA) @@ -1182,7 +1307,8 @@ get_component_bits(GLenum pname, GLenum baseFormat, gl_format format) return 0; case GL_RENDERBUFFER_ALPHA_SIZE_EXT: case GL_FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE: - if (baseFormat == GL_RGBA || baseFormat == GL_ALPHA) + if (baseFormat == GL_RGBA || baseFormat == GL_ALPHA || + baseFormat == GL_LUMINANCE_ALPHA) return _mesa_get_format_bits(format, pname); else return 0; @@ -1598,29 +1724,10 @@ _mesa_CheckFramebufferStatusEXT(GLenum target) ASSERT_OUTSIDE_BEGIN_END_WITH_RETVAL(ctx, 0); - switch (target) { -#if FEATURE_EXT_framebuffer_blit - case GL_DRAW_FRAMEBUFFER_EXT: - if (!ctx->Extensions.EXT_framebuffer_blit) { - _mesa_error(ctx, GL_INVALID_ENUM, "glCheckFramebufferStatus(target)"); - return 0; - } - buffer = ctx->DrawBuffer; - break; - case GL_READ_FRAMEBUFFER_EXT: - if (!ctx->Extensions.EXT_framebuffer_blit) { - _mesa_error(ctx, GL_INVALID_ENUM, "glCheckFramebufferStatus(target)"); - return 0; - } - buffer = ctx->ReadBuffer; - break; -#endif - case GL_FRAMEBUFFER_EXT: - buffer = ctx->DrawBuffer; - break; - default: + buffer = get_framebuffer_target(ctx, target); + if (!buffer) { _mesa_error(ctx, GL_INVALID_ENUM, "glCheckFramebufferStatus(target)"); - return 0; /* formerly GL_FRAMEBUFFER_STATUS_ERROR_EXT */ + return 0; } if (buffer->Name == 0) { @@ -1650,33 +1757,16 @@ framebuffer_texture(struct gl_context *ctx, const char *caller, GLenum target, struct gl_renderbuffer_attachment *att; struct gl_texture_object *texObj = NULL; struct gl_framebuffer *fb; - GLboolean error = GL_FALSE; ASSERT_OUTSIDE_BEGIN_END(ctx); - switch (target) { - case GL_READ_FRAMEBUFFER_EXT: - error = !ctx->Extensions.EXT_framebuffer_blit; - fb = ctx->ReadBuffer; - break; - case GL_DRAW_FRAMEBUFFER_EXT: - error = !ctx->Extensions.EXT_framebuffer_blit; - /* fall-through */ - case GL_FRAMEBUFFER_EXT: - fb = ctx->DrawBuffer; - break; - default: - error = GL_TRUE; - } - - if (error) { + fb = get_framebuffer_target(ctx, target); + if (!fb) { _mesa_error(ctx, GL_INVALID_ENUM, "glFramebufferTexture%sEXT(target=0x%x)", caller, target); return; } - ASSERT(fb); - /* check framebuffer binding */ if (fb->Name == 0) { _mesa_error(ctx, GL_INVALID_OPERATION, @@ -1857,31 +1947,9 @@ _mesa_FramebufferRenderbufferEXT(GLenum target, GLenum attachment, ASSERT_OUTSIDE_BEGIN_END(ctx); - switch (target) { -#if FEATURE_EXT_framebuffer_blit - case GL_DRAW_FRAMEBUFFER_EXT: - if (!ctx->Extensions.EXT_framebuffer_blit) { - _mesa_error(ctx, GL_INVALID_ENUM, - "glFramebufferRenderbufferEXT(target)"); - return; - } - fb = ctx->DrawBuffer; - break; - case GL_READ_FRAMEBUFFER_EXT: - if (!ctx->Extensions.EXT_framebuffer_blit) { - _mesa_error(ctx, GL_INVALID_ENUM, - "glFramebufferRenderbufferEXT(target)"); - return; - } - fb = ctx->ReadBuffer; - break; -#endif - case GL_FRAMEBUFFER_EXT: - fb = ctx->DrawBuffer; - break; - default: - _mesa_error(ctx, GL_INVALID_ENUM, - "glFramebufferRenderbufferEXT(target)"); + fb = get_framebuffer_target(ctx, target); + if (!fb) { + _mesa_error(ctx, GL_INVALID_ENUM, "glFramebufferRenderbufferEXT(target)"); return; } @@ -1913,6 +1981,13 @@ _mesa_FramebufferRenderbufferEXT(GLenum target, GLenum attachment, " renderbuffer %u)", renderbuffer); return; } + else if (rb == &DummyRenderbuffer) { + /* This is what NVIDIA does */ + _mesa_error(ctx, GL_INVALID_VALUE, + "glFramebufferRenderbufferEXT(renderbuffer %u)", + renderbuffer); + return; + } } else { /* remove renderbuffer attachment */ @@ -1940,7 +2015,7 @@ _mesa_FramebufferRenderbufferEXT(GLenum target, GLenum attachment, /* Some subsequent GL commands may depend on the framebuffer's visual * after the binding is updated. Update visual info now. */ - _mesa_update_framebuffer_visual(fb); + _mesa_update_framebuffer_visual(ctx, fb); } @@ -1954,29 +2029,8 @@ _mesa_GetFramebufferAttachmentParameterivEXT(GLenum target, GLenum attachment, ASSERT_OUTSIDE_BEGIN_END(ctx); - switch (target) { -#if FEATURE_EXT_framebuffer_blit - case GL_DRAW_FRAMEBUFFER_EXT: - if (!ctx->Extensions.EXT_framebuffer_blit) { - _mesa_error(ctx, GL_INVALID_ENUM, - "glGetFramebufferAttachmentParameterivEXT(target)"); - return; - } - buffer = ctx->DrawBuffer; - break; - case GL_READ_FRAMEBUFFER_EXT: - if (!ctx->Extensions.EXT_framebuffer_blit) { - _mesa_error(ctx, GL_INVALID_ENUM, - "glGetFramebufferAttachmentParameterivEXT(target)"); - return; - } - buffer = ctx->ReadBuffer; - break; -#endif - case GL_FRAMEBUFFER_EXT: - buffer = ctx->DrawBuffer; - break; - default: + buffer = get_framebuffer_target(ctx, target); + if (!buffer) { _mesa_error(ctx, GL_INVALID_ENUM, "glGetFramebufferAttachmentParameterivEXT(target)"); return; @@ -2071,7 +2125,14 @@ _mesa_GetFramebufferAttachmentParameterivEXT(GLenum target, GLenum attachment, "glGetFramebufferAttachmentParameterivEXT(pname)"); } else { - *params = _mesa_get_format_color_encoding(att->Renderbuffer->Format); + if (ctx->Extensions.EXT_framebuffer_sRGB && ctx->Const.sRGBCapable) { + *params = _mesa_get_format_color_encoding(att->Renderbuffer->Format); + } + else { + /* According to ARB_framebuffer_sRGB, we should return LINEAR + * if the sRGB conversion is unsupported. */ + *params = GL_LINEAR; + } } return; case GL_FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE: @@ -2183,7 +2244,8 @@ _mesa_GenerateMipmapEXT(GLenum target) #if FEATURE_EXT_framebuffer_blit static const struct gl_renderbuffer_attachment * -find_attachment(const struct gl_framebuffer *fb, const struct gl_renderbuffer *rb) +find_attachment(const struct gl_framebuffer *fb, + const struct gl_renderbuffer *rb) { GLuint i; for (i = 0; i < Elements(fb->Attachment); i++) { @@ -2216,6 +2278,13 @@ _mesa_BlitFramebufferEXT(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, ASSERT_OUTSIDE_BEGIN_END(ctx); FLUSH_VERTICES(ctx, _NEW_BUFFERS); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, + "glBlitFramebuffer(%d, %d, %d, %d, %d, %d, %d, %d, 0x%x, %s)\n", + srcX0, srcY0, srcX1, srcY1, + dstX0, dstY0, dstX1, dstY1, + mask, _mesa_lookup_enum_by_nr(filter)); + if (ctx->NewState) { _mesa_update_state(ctx); } diff --git a/src/mesa/main/fbobject.h b/src/mesa/main/fbobject.h index 2aace2ebd4..ba74a95b74 100644 --- a/src/mesa/main/fbobject.h +++ b/src/mesa/main/fbobject.h @@ -69,8 +69,14 @@ _mesa_framebuffer_renderbuffer(struct gl_context *ctx, struct gl_framebuffer *fb GLenum attachment, struct gl_renderbuffer *rb); extern void +_mesa_validate_framebuffer(struct gl_context *ctx, struct gl_framebuffer *fb); + +extern void _mesa_test_framebuffer_completeness(struct gl_context *ctx, struct gl_framebuffer *fb); +extern GLboolean +_mesa_is_legal_color_format(const struct gl_context *ctx, GLenum baseFormat); + extern GLenum _mesa_base_fbo_format(struct gl_context *ctx, GLenum internalFormat); diff --git a/src/mesa/main/feedback.c b/src/mesa/main/feedback.c index ffdecaecc2..fcb089f1f3 100644 --- a/src/mesa/main/feedback.c +++ b/src/mesa/main/feedback.c @@ -35,6 +35,7 @@ #include "enums.h" #include "feedback.h" #include "macros.h" +#include "mfeatures.h" #include "mtypes.h" #include "main/dispatch.h" diff --git a/src/mesa/main/feedback.h b/src/mesa/main/feedback.h index f9fbbce70b..0039a0b4cb 100644 --- a/src/mesa/main/feedback.h +++ b/src/mesa/main/feedback.h @@ -27,6 +27,7 @@ #define FEEDBACK_H +#include "main/mfeatures.h" #include "main/mtypes.h" diff --git a/src/mesa/main/texenvprogram.c b/src/mesa/main/ff_fragment_shader.cpp index a8bffe416d..9be531735e 100644 --- a/src/mesa/main/texenvprogram.c +++ b/src/mesa/main/ff_fragment_shader.cpp @@ -26,8 +26,10 @@ * **************************************************************************/ +extern "C" { #include "glheader.h" #include "imports.h" +#include "mtypes.h" #include "program/program.h" #include "program/prog_parameter.h" #include "program/prog_cache.h" @@ -36,7 +38,7 @@ #include "program/prog_statevars.h" #include "program/programopt.h" #include "texenvprogram.h" - +} /* * Note on texture units: @@ -523,7 +525,7 @@ struct ureg { static const struct ureg undef = { PROGRAM_UNDEFINED, - ~0, + 255, 0, 0, 0 @@ -685,14 +687,15 @@ static struct ureg register_param5( struct texenv_fragment_program *p, GLint s3, GLint s4) { - gl_state_index tokens[STATE_LENGTH]; + int tokens[STATE_LENGTH]; GLuint idx; tokens[0] = s0; tokens[1] = s1; tokens[2] = s2; tokens[3] = s3; tokens[4] = s4; - idx = _mesa_add_state_reference( p->program->Base.Parameters, tokens ); + idx = _mesa_add_state_reference(p->program->Base.Parameters, + (gl_state_index *)tokens); return make_ureg(PROGRAM_STATE_VAR, idx); } @@ -1466,7 +1469,7 @@ create_new_program(struct gl_context *ctx, struct state_key *key, p.last_tex_stage = 0; release_temps(ctx, &p); - if (key->enabled_units) { + if (key->enabled_units && key->num_draw_buffers) { GLboolean needbumpstage = GL_FALSE; /* Zeroth pass - bump map textures first */ @@ -1559,7 +1562,7 @@ create_new_program(struct gl_context *ctx, struct state_key *key, _mesa_copy_instructions(p.program->Base.Instructions, instBuffer, p.program->Base.NumInstructions); - if (p.program->FogOption) { + if (key->num_draw_buffers && p.program->FogOption) { _mesa_append_fog_code(ctx, p.program); p.program->FogOption = GL_NONE; } @@ -1585,6 +1588,7 @@ create_new_program(struct gl_context *ctx, struct state_key *key, } } +extern "C" { /** * Return a fragment program which implements the current @@ -1615,3 +1619,5 @@ _mesa_get_fixed_func_fragment_program(struct gl_context *ctx) return prog; } + +} diff --git a/src/mesa/main/ffvertex_prog.c b/src/mesa/main/ffvertex_prog.c index 0f2c313c81..b8e49a3757 100644 --- a/src/mesa/main/ffvertex_prog.c +++ b/src/mesa/main/ffvertex_prog.c @@ -36,6 +36,7 @@ #include "main/glheader.h" #include "main/mtypes.h" #include "main/macros.h" +#include "main/mfeatures.h" #include "main/enums.h" #include "main/ffvertex_prog.h" #include "program/program.h" diff --git a/src/mesa/main/formats.c b/src/mesa/main/formats.c index cd9eb81852..db10c9b4c2 100644 --- a/src/mesa/main/formats.c +++ b/src/mesa/main/formats.c @@ -40,9 +40,10 @@ struct gl_format_info const char *StrName; /** - * Base format is one of GL_RGB, GL_RGBA, GL_ALPHA, GL_LUMINANCE, - * GL_LUMINANCE_ALPHA, GL_INTENSITY, GL_YCBCR_MESA, GL_COLOR_INDEX, - * GL_DEPTH_COMPONENT, GL_STENCIL_INDEX, GL_DEPTH_STENCIL. + * Base format is one of GL_RED, GL_RG, GL_RGB, GL_RGBA, GL_ALPHA, + * GL_LUMINANCE, GL_LUMINANCE_ALPHA, GL_INTENSITY, GL_YCBCR_MESA, + * GL_COLOR_INDEX, GL_DEPTH_COMPONENT, GL_STENCIL_INDEX, + * GL_DEPTH_STENCIL, GL_DUDV_ATI. */ GLenum BaseFormat; @@ -222,6 +223,15 @@ static struct gl_format_info format_info[MESA_FORMAT_COUNT] = 1, 1, 2 /* BlockWidth/Height,Bytes */ }, { + MESA_FORMAT_AL44, /* Name */ + "MESA_FORMAT_AL44", /* StrName */ + GL_LUMINANCE_ALPHA, /* BaseFormat */ + GL_UNSIGNED_NORMALIZED, /* DataType */ + 0, 0, 0, 4, /* Red/Green/Blue/AlphaBits */ + 4, 0, 0, 0, 0, /* Lum/Int/Index/Depth/StencilBits */ + 1, 1, 1 /* BlockWidth/Height,Bytes */ + }, + { MESA_FORMAT_AL88, /* Name */ "MESA_FORMAT_AL88", /* StrName */ GL_LUMINANCE_ALPHA, /* BaseFormat */ @@ -276,6 +286,15 @@ static struct gl_format_info format_info[MESA_FORMAT_COUNT] = 1, 1, 1 /* BlockWidth/Height,Bytes */ }, { + MESA_FORMAT_A16, /* Name */ + "MESA_FORMAT_A16", /* StrName */ + GL_ALPHA, /* BaseFormat */ + GL_UNSIGNED_NORMALIZED, /* DataType */ + 0, 0, 0, 16, /* Red/Green/Blue/AlphaBits */ + 0, 0, 0, 0, 0, /* Lum/Int/Index/Depth/StencilBits */ + 1, 1, 2 /* BlockWidth/Height,Bytes */ + }, + { MESA_FORMAT_L8, /* Name */ "MESA_FORMAT_L8", /* StrName */ GL_LUMINANCE, /* BaseFormat */ @@ -285,6 +304,15 @@ static struct gl_format_info format_info[MESA_FORMAT_COUNT] = 1, 1, 1 /* BlockWidth/Height,Bytes */ }, { + MESA_FORMAT_L16, /* Name */ + "MESA_FORMAT_L16", /* StrName */ + GL_LUMINANCE, /* BaseFormat */ + GL_UNSIGNED_NORMALIZED, /* DataType */ + 0, 0, 0, 0, /* Red/Green/Blue/AlphaBits */ + 16, 0, 0, 0, 0, /* Lum/Int/Index/Depth/StencilBits */ + 1, 1, 2 /* BlockWidth/Height,Bytes */ + }, + { MESA_FORMAT_I8, /* Name */ "MESA_FORMAT_I8", /* StrName */ GL_INTENSITY, /* BaseFormat */ @@ -294,6 +322,15 @@ static struct gl_format_info format_info[MESA_FORMAT_COUNT] = 1, 1, 1 /* BlockWidth/Height,Bytes */ }, { + MESA_FORMAT_I16, /* Name */ + "MESA_FORMAT_I16", /* StrName */ + GL_INTENSITY, /* BaseFormat */ + GL_UNSIGNED_NORMALIZED, /* DataType */ + 0, 0, 0, 0, /* Red/Green/Blue/AlphaBits */ + 0, 16, 0, 0, 0, /* Lum/Int/Index/Depth/StencilBits */ + 1, 1, 2 /* BlockWidth/Height,Bytes */ + }, + { MESA_FORMAT_CI8, /* Name */ "MESA_FORMAT_CI8", /* StrName */ GL_COLOR_INDEX, /* BaseFormat */ @@ -375,6 +412,15 @@ static struct gl_format_info format_info[MESA_FORMAT_COUNT] = 1, 1, 4 }, { + MESA_FORMAT_ARGB2101010, + "MESA_FORMAT_ARGB2101010", + GL_RGBA, + GL_UNSIGNED_NORMALIZED, + 10, 10, 10, 2, + 0, 0, 0, 0, 0, + 1, 1, 4 + }, + { MESA_FORMAT_Z24_S8, /* Name */ "MESA_FORMAT_Z24_S8", /* StrName */ GL_DEPTH_STENCIL, /* BaseFormat */ @@ -756,7 +802,7 @@ static struct gl_format_info format_info[MESA_FORMAT_COUNT] = { MESA_FORMAT_SIGNED_R8, /* Name */ "MESA_FORMAT_SIGNED_R8", /* StrName */ - GL_RGBA, /* BaseFormat */ + GL_RED, /* BaseFormat */ GL_SIGNED_NORMALIZED, /* DataType */ 8, 0, 0, 0, /* Red/Green/Blue/AlphaBits */ 0, 0, 0, 0, 0, /* Lum/Int/Index/Depth/StencilBits */ @@ -765,7 +811,7 @@ static struct gl_format_info format_info[MESA_FORMAT_COUNT] = { MESA_FORMAT_SIGNED_RG88, "MESA_FORMAT_SIGNED_RG88", - GL_RGBA, + GL_RG, GL_SIGNED_NORMALIZED, 8, 8, 0, 0, 0, 0, 0, 0, 0, @@ -774,7 +820,7 @@ static struct gl_format_info format_info[MESA_FORMAT_COUNT] = { MESA_FORMAT_SIGNED_RGBX8888, "MESA_FORMAT_SIGNED_RGBX8888", - GL_RGBA, + GL_RGB, GL_SIGNED_NORMALIZED, 8, 8, 8, 0, 0, 0, 0, 0, 0, @@ -803,7 +849,7 @@ static struct gl_format_info format_info[MESA_FORMAT_COUNT] = { MESA_FORMAT_SIGNED_R_16, "MESA_FORMAT_SIGNED_R_16", - GL_RGBA, + GL_RED, GL_SIGNED_NORMALIZED, 16, 0, 0, 0, 0, 0, 0, 0, 0, @@ -812,7 +858,7 @@ static struct gl_format_info format_info[MESA_FORMAT_COUNT] = { MESA_FORMAT_SIGNED_RG_16, "MESA_FORMAT_SIGNED_RG_16", - GL_RGBA, + GL_RG, GL_SIGNED_NORMALIZED, 16, 16, 0, 0, 0, 0, 0, 0, 0, @@ -821,7 +867,7 @@ static struct gl_format_info format_info[MESA_FORMAT_COUNT] = { MESA_FORMAT_SIGNED_RGB_16, "MESA_FORMAT_SIGNED_RGB_16", - GL_RGBA, + GL_RGB, GL_SIGNED_NORMALIZED, 16, 16, 16, 0, 0, 0, 0, 0, 0, @@ -844,7 +890,79 @@ static struct gl_format_info format_info[MESA_FORMAT_COUNT] = 16, 16, 16, 16, 0, 0, 0, 0, 0, 1, 1, 8 - } + }, + { + MESA_FORMAT_RED_RGTC1, + "MESA_FORMAT_RED_RGTC1", + GL_RED, + GL_UNSIGNED_NORMALIZED, + 4, 0, 0, 0, + 0, 0, 0, 0, 0, + 4, 4, 8 /* 8 bytes per 4x4 block */ + }, + { + MESA_FORMAT_SIGNED_RED_RGTC1, + "MESA_FORMAT_SIGNED_RED_RGTC1", + GL_RED, + GL_SIGNED_NORMALIZED, + 4, 0, 0, 0, + 0, 0, 0, 0, 0, + 4, 4, 8 /* 8 bytes per 4x4 block */ + }, + { + MESA_FORMAT_RG_RGTC2, + "MESA_FORMAT_RG_RGTC2", + GL_RG, + GL_UNSIGNED_NORMALIZED, + 4, 4, 0, 0, + 0, 0, 0, 0, 0, + 4, 4, 16 /* 16 bytes per 4x4 block */ + }, + { + MESA_FORMAT_SIGNED_RG_RGTC2, + "MESA_FORMAT_SIGNED_RG_RGTC2", + GL_RG, + GL_SIGNED_NORMALIZED, + 4, 4, 0, 0, + 0, 0, 0, 0, 0, + 4, 4, 16 /* 16 bytes per 4x4 block */ + }, + { + MESA_FORMAT_L_LATC1, + "MESA_FORMAT_L_LATC1", + GL_LUMINANCE, + GL_UNSIGNED_NORMALIZED, + 0, 0, 0, 0, + 4, 0, 0, 0, 0, + 4, 4, 8 /* 8 bytes per 4x4 block */ + }, + { + MESA_FORMAT_SIGNED_L_LATC1, + "MESA_FORMAT_SIGNED_L_LATC1", + GL_LUMINANCE, + GL_SIGNED_NORMALIZED, + 0, 0, 0, 0, + 4, 0, 0, 0, 0, + 4, 4, 8 /* 8 bytes per 4x4 block */ + }, + { + MESA_FORMAT_LA_LATC2, + "MESA_FORMAT_LA_LATC2", + GL_LUMINANCE_ALPHA, + GL_UNSIGNED_NORMALIZED, + 0, 0, 0, 4, + 4, 0, 0, 0, 0, + 4, 4, 16 /* 16 bytes per 4x4 block */ + }, + { + MESA_FORMAT_SIGNED_LA_LATC2, + "MESA_FORMAT_SIGNED_LA_LATC2", + GL_LUMINANCE_ALPHA, + GL_SIGNED_NORMALIZED, + 0, 0, 0, 4, + 4, 0, 0, 0, 0, + 4, 4, 16 /* 16 bytes per 4x4 block */ + }, }; @@ -863,7 +981,6 @@ const char * _mesa_get_format_name(gl_format format) { const struct gl_format_info *info = _mesa_get_format_info(format); - ASSERT(info->BytesPerBlock); return info->StrName; } @@ -1047,6 +1164,48 @@ _mesa_get_format_color_encoding(gl_format format) /** + * For an sRGB format, return the corresponding linear color space format. + * For non-sRGB formats, return the format as-is. + */ +gl_format +_mesa_get_srgb_format_linear(gl_format format) +{ + switch (format) { + case MESA_FORMAT_SRGB8: + format = MESA_FORMAT_RGB888; + break; + case MESA_FORMAT_SRGBA8: + format = MESA_FORMAT_RGBA8888; + break; + case MESA_FORMAT_SARGB8: + format = MESA_FORMAT_ARGB8888; + break; + case MESA_FORMAT_SL8: + format = MESA_FORMAT_L8; + break; + case MESA_FORMAT_SLA8: + format = MESA_FORMAT_AL88; + break; + case MESA_FORMAT_SRGB_DXT1: + format = MESA_FORMAT_RGB_DXT1; + break; + case MESA_FORMAT_SRGBA_DXT1: + format = MESA_FORMAT_RGBA_DXT1; + break; + case MESA_FORMAT_SRGBA_DXT3: + format = MESA_FORMAT_RGBA_DXT3; + break; + case MESA_FORMAT_SRGBA_DXT5: + format = MESA_FORMAT_RGBA_DXT5; + break; + default: + break; + } + return format; +} + + +/** * Return number of bytes needed to store an image of the given size * in the given format. */ @@ -1123,6 +1282,27 @@ _mesa_format_row_stride(gl_format format, GLsizei width) } +/** + * Debug/test: check that all formats are handled in the + * _mesa_format_to_type_and_comps() function. When new pixel formats + * are added to Mesa, that function needs to be updated. + * This is a no-op after the first call. + */ +static void +check_format_to_type_and_comps(void) +{ + gl_format f; + + for (f = MESA_FORMAT_NONE + 1; f < MESA_FORMAT_COUNT; f++) { + GLenum datatype = 0; + GLuint comps = 0; + /* This function will emit a problem/warning if the format is + * not handled. + */ + _mesa_format_to_type_and_comps(f, &datatype, &comps); + } +} + /** * Do sanity checking of the format info table. @@ -1147,7 +1327,7 @@ _mesa_test_formats(void) if (info->RedBits > 0) { GLuint t = info->RedBits + info->GreenBits + info->BlueBits + info->AlphaBits; - assert(t / 8 == info->BytesPerBlock); + assert(t / 8 <= info->BytesPerBlock); (void) t; } } @@ -1155,6 +1335,7 @@ _mesa_test_formats(void) assert(info->DataType == GL_UNSIGNED_NORMALIZED || info->DataType == GL_SIGNED_NORMALIZED || info->DataType == GL_UNSIGNED_INT || + info->DataType == GL_INT || info->DataType == GL_FLOAT); if (info->BaseFormat == GL_RGB) { @@ -1205,8 +1386,9 @@ _mesa_test_formats(void) assert(info->LuminanceBits == 0); assert(info->IntensityBits > 0); } - } + + check_format_to_type_and_comps(); } @@ -1252,11 +1434,21 @@ _mesa_format_to_type_and_comps(gl_format format, *comps = 4; return; + case MESA_FORMAT_ARGB2101010: + *datatype = GL_UNSIGNED_INT_2_10_10_10_REV; + *comps = 4; + return; + case MESA_FORMAT_RGBA5551: *datatype = GL_UNSIGNED_SHORT_5_5_5_1; *comps = 4; return; + case MESA_FORMAT_AL44: + *datatype = MESA_UNSIGNED_BYTE_4_4; + *comps = 2; + return; + case MESA_FORMAT_AL88: case MESA_FORMAT_AL88_REV: case MESA_FORMAT_RG88: @@ -1274,6 +1466,9 @@ _mesa_format_to_type_and_comps(gl_format format, return; case MESA_FORMAT_R16: + case MESA_FORMAT_A16: + case MESA_FORMAT_L16: + case MESA_FORMAT_I16: *datatype = GL_UNSIGNED_SHORT; *comps = 1; return; @@ -1407,6 +1602,14 @@ _mesa_format_to_type_and_comps(gl_format format, case MESA_FORMAT_SRGBA_DXT5: #endif #endif + case MESA_FORMAT_RED_RGTC1: + case MESA_FORMAT_SIGNED_RED_RGTC1: + case MESA_FORMAT_RG_RGTC2: + case MESA_FORMAT_SIGNED_RG_RGTC2: + case MESA_FORMAT_L_LATC1: + case MESA_FORMAT_SIGNED_L_LATC1: + case MESA_FORMAT_LA_LATC2: + case MESA_FORMAT_SIGNED_LA_LATC2: /* XXX generate error instead? */ *datatype = GL_UNSIGNED_BYTE; *comps = 0; @@ -1478,10 +1681,13 @@ _mesa_format_to_type_and_comps(gl_format format, *comps = 4; return; - case MESA_FORMAT_NONE: case MESA_FORMAT_COUNT: + assert(0); + return; + + case MESA_FORMAT_NONE: /* For debug builds, warn if any formats are not handled */ -#ifndef DEBUG +#ifdef DEBUG default: #endif _mesa_problem(NULL, "bad format %s in _mesa_format_to_type_and_comps", diff --git a/src/mesa/main/formats.h b/src/mesa/main/formats.h index 997229bf9f..04a18930b4 100644 --- a/src/mesa/main/formats.h +++ b/src/mesa/main/formats.h @@ -35,6 +35,9 @@ #include <GL/gl.h> +/* OpenGL doesn't have GL_UNSIGNED_BYTE_4_4, so we must define our own type + * for GL_LUMINANCE4_ALPHA4. */ +#define MESA_UNSIGNED_BYTE_4_4 (GL_UNSIGNED_BYTE<<1) /** @@ -65,14 +68,18 @@ typedef enum MESA_FORMAT_RGBA5551, /* RRRR RGGG GGBB BBBA */ MESA_FORMAT_ARGB1555, /* ARRR RRGG GGGB BBBB */ MESA_FORMAT_ARGB1555_REV, /* GGGB BBBB ARRR RRGG */ + MESA_FORMAT_AL44, /* AAAA LLLL */ MESA_FORMAT_AL88, /* AAAA AAAA LLLL LLLL */ MESA_FORMAT_AL88_REV, /* LLLL LLLL AAAA AAAA */ MESA_FORMAT_AL1616, /* AAAA AAAA AAAA AAAA LLLL LLLL LLLL LLLL */ MESA_FORMAT_AL1616_REV, /* LLLL LLLL LLLL LLLL AAAA AAAA AAAA AAAA */ MESA_FORMAT_RGB332, /* RRRG GGBB */ MESA_FORMAT_A8, /* AAAA AAAA */ + MESA_FORMAT_A16, /* AAAA AAAA AAAA AAAA */ MESA_FORMAT_L8, /* LLLL LLLL */ + MESA_FORMAT_L16, /* LLLL LLLL LLLL LLLL */ MESA_FORMAT_I8, /* IIII IIII */ + MESA_FORMAT_I16, /* IIII IIII IIII IIII */ MESA_FORMAT_CI8, /* CCCC CCCC */ MESA_FORMAT_YCBCR, /* YYYY YYYY UorV UorV */ MESA_FORMAT_YCBCR_REV, /* UorV UorV YYYY YYYY */ @@ -82,6 +89,7 @@ typedef enum MESA_FORMAT_R16, /* RRRR RRRR RRRR RRRR */ MESA_FORMAT_RG1616, /* RRRR RRRR RRRR RRRR GGGG GGGG GGGG GGGG */ MESA_FORMAT_RG1616_REV, /* GGGG GGGG GGGG GGGG RRRR RRRR RRRR RRRR */ + MESA_FORMAT_ARGB2101010, /* AARR RRRR RRRR GGGG GGGG GGBB BBBB BBBB */ MESA_FORMAT_Z24_S8, /* ZZZZ ZZZZ ZZZZ ZZZZ ZZZZ ZZZZ SSSS SSSS */ MESA_FORMAT_S8_Z24, /* SSSS SSSS ZZZZ ZZZZ ZZZZ ZZZZ ZZZZ ZZZZ */ MESA_FORMAT_Z16, /* ZZZZ ZZZZ ZZZZ ZZZZ */ @@ -171,6 +179,20 @@ typedef enum MESA_FORMAT_RGBA_16, /* ... */ /*@}*/ + /*@{*/ + MESA_FORMAT_RED_RGTC1, + MESA_FORMAT_SIGNED_RED_RGTC1, + MESA_FORMAT_RG_RGTC2, + MESA_FORMAT_SIGNED_RG_RGTC2, + /*@}*/ + + /*@{*/ + MESA_FORMAT_L_LATC1, + MESA_FORMAT_SIGNED_L_LATC1, + MESA_FORMAT_LA_LATC2, + MESA_FORMAT_SIGNED_LA_LATC2, + /*@}*/ + MESA_FORMAT_COUNT } gl_format; @@ -223,4 +245,7 @@ _mesa_format_to_type_and_comps(gl_format format, extern void _mesa_test_formats(void); +extern gl_format +_mesa_get_srgb_format_linear(gl_format format); + #endif /* FORMATS_H */ diff --git a/src/mesa/main/framebuffer.c b/src/mesa/main/framebuffer.c index 5530c51c89..430e013d01 100644 --- a/src/mesa/main/framebuffer.c +++ b/src/mesa/main/framebuffer.c @@ -522,7 +522,8 @@ _mesa_update_draw_buffer_bounds(struct gl_context *ctx) * integer Z values. */ void -_mesa_update_framebuffer_visual(struct gl_framebuffer *fb) +_mesa_update_framebuffer_visual(struct gl_context *ctx, + struct gl_framebuffer *fb) { GLuint i; @@ -542,9 +543,8 @@ _mesa_update_framebuffer_visual(struct gl_framebuffer *fb) const struct gl_renderbuffer *rb = fb->Attachment[i].Renderbuffer; const GLenum baseFormat = _mesa_get_format_base_format(rb->Format); const gl_format fmt = rb->Format; - - if (baseFormat == GL_RGBA || baseFormat == GL_RGB || - baseFormat == GL_ALPHA) { + + if (_mesa_is_legal_color_format(ctx, baseFormat)) { fb->Visual.redBits = _mesa_get_format_bits(fmt, GL_RED_BITS); fb->Visual.greenBits = _mesa_get_format_bits(fmt, GL_GREEN_BITS); fb->Visual.blueBits = _mesa_get_format_bits(fmt, GL_BLUE_BITS); @@ -553,6 +553,8 @@ _mesa_update_framebuffer_visual(struct gl_framebuffer *fb) + fb->Visual.greenBits + fb->Visual.blueBits; fb->Visual.floatMode = GL_FALSE; fb->Visual.samples = rb->NumSamples; + if (_mesa_get_format_color_encoding(fmt) == GL_SRGB) + fb->Visual.sRGBCapable = ctx->Const.sRGBCapable; break; } } @@ -792,9 +794,6 @@ update_framebuffer(struct gl_context *ctx, struct gl_framebuffer *fb) _mesa_drawbuffers(ctx, ctx->Const.MaxDrawBuffers, ctx->Color.DrawBuffer, NULL); } - if (fb->ColorReadBuffer != ctx->Pixel.ReadBuffer) { - - } } else { /* This is a user-created framebuffer. @@ -890,6 +889,8 @@ _mesa_source_buffer_exists(struct gl_context *ctx, GLenum format) } ASSERT(_mesa_get_format_bits(ctx->ReadBuffer->_ColorReadBuffer->Format, GL_RED_BITS) > 0 || _mesa_get_format_bits(ctx->ReadBuffer->_ColorReadBuffer->Format, GL_ALPHA_BITS) > 0 || + _mesa_get_format_bits(ctx->ReadBuffer->_ColorReadBuffer->Format, GL_TEXTURE_LUMINANCE_SIZE) > 0 || + _mesa_get_format_bits(ctx->ReadBuffer->_ColorReadBuffer->Format, GL_TEXTURE_INTENSITY_SIZE) > 0 || _mesa_get_format_bits(ctx->ReadBuffer->_ColorReadBuffer->Format, GL_INDEX_BITS) > 0); break; case GL_DEPTH: diff --git a/src/mesa/main/framebuffer.h b/src/mesa/main/framebuffer.h index 20e3ff56b5..c3bd638c9d 100644 --- a/src/mesa/main/framebuffer.h +++ b/src/mesa/main/framebuffer.h @@ -70,7 +70,8 @@ extern void _mesa_update_draw_buffer_bounds(struct gl_context *ctx); extern void -_mesa_update_framebuffer_visual(struct gl_framebuffer *fb); +_mesa_update_framebuffer_visual(struct gl_context *ctx, + struct gl_framebuffer *fb); extern void _mesa_update_depth_buffer(struct gl_context *ctx, struct gl_framebuffer *fb, diff --git a/src/mesa/main/get.c b/src/mesa/main/get.c index 5ae35b868e..7d1a5cf600 100644 --- a/src/mesa/main/get.c +++ b/src/mesa/main/get.c @@ -29,6 +29,7 @@ #include "extensions.h" #include "get.h" #include "macros.h" +#include "mfeatures.h" #include "mtypes.h" #include "state.h" #include "texcompress.h" @@ -272,6 +273,7 @@ static const int extra_EXT_gpu_shader4[] = { }; +EXTRA_EXT(ARB_ES2_compatibility); EXTRA_EXT(ARB_multitexture); EXTRA_EXT(ARB_texture_cube_map); EXTRA_EXT(MESA_texture_array); @@ -288,7 +290,6 @@ EXTRA_EXT(NV_fragment_program); EXTRA_EXT(NV_texture_rectangle); EXTRA_EXT(EXT_stencil_two_side); EXTRA_EXT(NV_light_max_exponent); -EXTRA_EXT(SGI_texture_color_table); EXTRA_EXT(EXT_depth_bounds_test); EXTRA_EXT(ARB_depth_clamp); EXTRA_EXT(ATI_fragment_shader); @@ -315,6 +316,7 @@ EXTRA_EXT2(ARB_vertex_program, ARB_fragment_program); EXTRA_EXT(ARB_vertex_buffer_object); EXTRA_EXT(ARB_geometry_shader4); EXTRA_EXT(ARB_copy_buffer); +EXTRA_EXT(EXT_framebuffer_sRGB); static const int extra_ARB_vertex_program_ARB_fragment_program_NV_vertex_program[] = { @@ -370,7 +372,7 @@ static const struct value_desc values[] = { API_OPENGL_BIT | API_OPENGLES_BIT | API_OPENGLES2_BIT, NO_EXTRA}, { GL_ALPHA_BITS, BUFFER_INT(Visual.alphaBits), extra_new_buffers }, { GL_BLEND, CONTEXT_BIT0(Color.BlendEnabled), NO_EXTRA }, - { GL_BLEND_SRC, CONTEXT_ENUM(Color.BlendSrcRGB), NO_EXTRA }, + { GL_BLEND_SRC, CONTEXT_ENUM(Color.Blend[0].SrcRGB), NO_EXTRA }, { GL_BLUE_BITS, BUFFER_INT(Visual.blueBits), extra_new_buffers }, { GL_COLOR_CLEAR_VALUE, CONTEXT_FIELD(Color.ClearColor[0], TYPE_FLOATN_4), NO_EXTRA }, { GL_COLOR_WRITEMASK, LOC_CUSTOM, TYPE_INT_4, 0, NO_EXTRA }, @@ -433,15 +435,15 @@ static const struct value_desc values[] = { extra_ARB_texture_cube_map }, /* XXX: OES_texture_cube_map */ /* XXX: OES_blend_subtract */ - { GL_BLEND_SRC_RGB_EXT, CONTEXT_ENUM(Color.BlendSrcRGB), NO_EXTRA }, - { GL_BLEND_DST_RGB_EXT, CONTEXT_ENUM(Color.BlendDstRGB), NO_EXTRA }, - { GL_BLEND_SRC_ALPHA_EXT, CONTEXT_ENUM(Color.BlendSrcA), NO_EXTRA }, - { GL_BLEND_DST_ALPHA_EXT, CONTEXT_ENUM(Color.BlendDstA), NO_EXTRA }, + { GL_BLEND_SRC_RGB_EXT, CONTEXT_ENUM(Color.Blend[0].SrcRGB), NO_EXTRA }, + { GL_BLEND_DST_RGB_EXT, CONTEXT_ENUM(Color.Blend[0].DstRGB), NO_EXTRA }, + { GL_BLEND_SRC_ALPHA_EXT, CONTEXT_ENUM(Color.Blend[0].SrcA), NO_EXTRA }, + { GL_BLEND_DST_ALPHA_EXT, CONTEXT_ENUM(Color.Blend[0].DstA), NO_EXTRA }, /* GL_BLEND_EQUATION_RGB, which is what we're really after, is * defined identically to GL_BLEND_EQUATION. */ - { GL_BLEND_EQUATION, CONTEXT_ENUM(Color.BlendEquationRGB), NO_EXTRA }, - { GL_BLEND_EQUATION_ALPHA_EXT, CONTEXT_ENUM(Color.BlendEquationA), NO_EXTRA }, + { GL_BLEND_EQUATION, CONTEXT_ENUM(Color.Blend[0].EquationRGB), NO_EXTRA }, + { GL_BLEND_EQUATION_ALPHA_EXT, CONTEXT_ENUM(Color.Blend[0].EquationA), NO_EXTRA }, /* GL_ARB_texture_compression */ { GL_NUM_COMPRESSED_TEXTURE_FORMATS_ARB, LOC_CUSTOM, TYPE_INT, 0, NO_EXTRA }, @@ -510,7 +512,7 @@ static const struct value_desc values[] = { { GL_ALPHA_TEST, CONTEXT_BOOL(Color.AlphaEnabled), NO_EXTRA }, { GL_ALPHA_TEST_FUNC, CONTEXT_ENUM(Color.AlphaFunc), NO_EXTRA }, { GL_ALPHA_TEST_REF, CONTEXT_FIELD(Color.AlphaRef, TYPE_FLOATN), NO_EXTRA }, - { GL_BLEND_DST, CONTEXT_ENUM(Color.BlendDstRGB), NO_EXTRA }, + { GL_BLEND_DST, CONTEXT_ENUM(Color.Blend[0].DstRGB), NO_EXTRA }, { GL_CLIP_PLANE0, CONTEXT_BIT0(Transform.ClipPlanesEnabled), NO_EXTRA }, { GL_CLIP_PLANE1, CONTEXT_BIT1(Transform.ClipPlanesEnabled), NO_EXTRA }, { GL_CLIP_PLANE2, CONTEXT_BIT2(Transform.ClipPlanesEnabled), NO_EXTRA }, @@ -586,6 +588,15 @@ static const struct value_desc values[] = { { GL_TEXTURE_COORD_ARRAY_STRIDE, LOC_CUSTOM, TYPE_BOOLEAN, offsetof(struct gl_client_array, Stride), NO_EXTRA }, + /* GL_ARB_ES2_compatibility */ + { GL_SHADER_COMPILER, CONST(1), extra_ARB_ES2_compatibility }, + { GL_MAX_VARYING_VECTORS, CONTEXT_INT(Const.MaxVarying), + extra_ARB_ES2_compatibility }, + { GL_MAX_VERTEX_UNIFORM_VECTORS, LOC_CUSTOM, TYPE_INT, 0, + extra_ARB_ES2_compatibility }, + { GL_MAX_FRAGMENT_UNIFORM_VECTORS, LOC_CUSTOM, TYPE_INT, 0, + extra_ARB_ES2_compatibility }, + /* GL_ARB_multitexture */ { GL_MAX_TEXTURE_UNITS_ARB, CONTEXT_INT(Const.MaxTextureUnits), extra_ARB_multitexture }, @@ -899,11 +910,6 @@ static const struct value_desc values[] = { CONTEXT_MATRIX_T(ProjectionMatrixStack.Top), NO_EXTRA }, { GL_TRANSPOSE_TEXTURE_MATRIX_ARB, CONTEXT_MATRIX_T(TextureMatrixStack), NO_EXTRA }, - /* GL_SGI_texture_color_table */ - { GL_TEXTURE_COLOR_TABLE_SGI, LOC_TEXUNIT, TYPE_BOOLEAN, - offsetof(struct gl_texture_unit, ColorTableEnabled), - extra_SGI_texture_color_table }, - /* GL_EXT_secondary_color */ { GL_COLOR_SUM_EXT, CONTEXT_BOOL(Fog.ColorSumEnabled), extra_EXT_secondary_color_ARB_vertex_program }, @@ -1195,22 +1201,22 @@ static const struct value_desc values[] = { /* GL_ARB_geometry_shader4 */ { GL_MAX_GEOMETRY_TEXTURE_IMAGE_UNITS_ARB, - CONTEXT_INT(Const.GeometryProgram.MaxGeometryTextureImageUnits), + CONTEXT_INT(Const.MaxGeometryTextureImageUnits), extra_ARB_geometry_shader4 }, { GL_MAX_GEOMETRY_OUTPUT_VERTICES_ARB, - CONTEXT_INT(Const.GeometryProgram.MaxGeometryOutputVertices), + CONTEXT_INT(Const.MaxGeometryOutputVertices), extra_ARB_geometry_shader4 }, { GL_MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS_ARB, - CONTEXT_INT(Const.GeometryProgram.MaxGeometryTotalOutputComponents), + CONTEXT_INT(Const.MaxGeometryTotalOutputComponents), extra_ARB_geometry_shader4 }, { GL_MAX_GEOMETRY_UNIFORM_COMPONENTS_ARB, - CONTEXT_INT(Const.GeometryProgram.MaxGeometryUniformComponents), + CONTEXT_INT(Const.GeometryProgram.MaxUniformComponents), extra_ARB_geometry_shader4 }, { GL_MAX_GEOMETRY_VARYING_COMPONENTS_ARB, - CONTEXT_INT(Const.GeometryProgram.MaxGeometryVaryingComponents), + CONTEXT_INT(Const.MaxGeometryVaryingComponents), extra_ARB_geometry_shader4 }, { GL_MAX_VERTEX_VARYING_COMPONENTS_ARB, - CONTEXT_INT(Const.GeometryProgram.MaxVertexVaryingComponents), + CONTEXT_INT(Const.MaxVertexVaryingComponents), extra_ARB_geometry_shader4 }, /* GL_EXT_gpu_shader4 / GL 3.0 */ @@ -1227,6 +1233,10 @@ static const struct value_desc values[] = { { GL_MINOR_VERSION, CONTEXT_INT(VersionMinor), extra_version_30 }, { GL_CONTEXT_FLAGS, CONTEXT_INT(Const.ContextFlags), extra_version_30 }, + /* GL3.0 / GL_EXT_framebuffer_sRGB */ + { GL_FRAMEBUFFER_SRGB_EXT, CONTEXT_BOOL(Color.sRGBEnabled), extra_EXT_framebuffer_sRGB }, + { GL_FRAMEBUFFER_SRGB_CAPABLE_EXT, BUFFER_INT(Visual.sRGBCapable), extra_EXT_framebuffer_sRGB }, + /* GL 3.1 */ /* NOTE: different enum values for GL_PRIMITIVE_RESTART_NV * vs. GL_PRIMITIVE_RESTART! @@ -2260,6 +2270,53 @@ find_value_indexed(const char *func, GLenum pname, int index, union value *v) v->value_int = (ctx->Color.BlendEnabled >> index) & 1; return TYPE_INT; + case GL_BLEND_SRC: + /* fall-through */ + case GL_BLEND_SRC_RGB: + if (index >= ctx->Const.MaxDrawBuffers) + goto invalid_value; + if (!ctx->Extensions.ARB_draw_buffers_blend) + goto invalid_enum; + v->value_int = ctx->Color.Blend[index].SrcRGB; + return TYPE_INT; + case GL_BLEND_SRC_ALPHA: + if (index >= ctx->Const.MaxDrawBuffers) + goto invalid_value; + if (!ctx->Extensions.ARB_draw_buffers_blend) + goto invalid_enum; + v->value_int = ctx->Color.Blend[index].SrcA; + return TYPE_INT; + case GL_BLEND_DST: + /* fall-through */ + case GL_BLEND_DST_RGB: + if (index >= ctx->Const.MaxDrawBuffers) + goto invalid_value; + if (!ctx->Extensions.ARB_draw_buffers_blend) + goto invalid_enum; + v->value_int = ctx->Color.Blend[index].DstRGB; + return TYPE_INT; + case GL_BLEND_DST_ALPHA: + if (index >= ctx->Const.MaxDrawBuffers) + goto invalid_value; + if (!ctx->Extensions.ARB_draw_buffers_blend) + goto invalid_enum; + v->value_int = ctx->Color.Blend[index].DstA; + return TYPE_INT; + case GL_BLEND_EQUATION_RGB: + if (index >= ctx->Const.MaxDrawBuffers) + goto invalid_value; + if (!ctx->Extensions.ARB_draw_buffers_blend) + goto invalid_enum; + v->value_int = ctx->Color.Blend[index].EquationRGB; + return TYPE_INT; + case GL_BLEND_EQUATION_ALPHA: + if (index >= ctx->Const.MaxDrawBuffers) + goto invalid_value; + if (!ctx->Extensions.ARB_draw_buffers_blend) + goto invalid_enum; + v->value_int = ctx->Color.Blend[index].EquationA; + return TYPE_INT; + case GL_COLOR_WRITEMASK: if (index >= ctx->Const.MaxDrawBuffers) goto invalid_value; @@ -2310,8 +2367,10 @@ void GLAPIENTRY _mesa_GetBooleanIndexedv( GLenum pname, GLuint index, GLboolean *params ) { union value v; + enum value_type type = + find_value_indexed("glGetBooleanIndexedv", pname, index, &v); - switch (find_value_indexed("glGetBooleanIndexedv", pname, index, &v)) { + switch (type) { case TYPE_INT: params[0] = INT_TO_BOOLEAN(v.value_int); break; @@ -2325,7 +2384,7 @@ _mesa_GetBooleanIndexedv( GLenum pname, GLuint index, GLboolean *params ) params[0] = INT64_TO_BOOLEAN(v.value_int); break; default: - assert(0); + ; /* nothing - GL error was recorded */ } } @@ -2333,8 +2392,10 @@ void GLAPIENTRY _mesa_GetIntegerIndexedv( GLenum pname, GLuint index, GLint *params ) { union value v; + enum value_type type = + find_value_indexed("glGetIntegerIndexedv", pname, index, &v); - switch (find_value_indexed("glGetIntegerIndexedv", pname, index, &v)) { + switch (type) { case TYPE_INT: params[0] = v.value_int; break; @@ -2348,7 +2409,7 @@ _mesa_GetIntegerIndexedv( GLenum pname, GLuint index, GLint *params ) params[0] = INT64_TO_INT(v.value_int); break; default: - assert(0); + ; /* nothing - GL error was recorded */ } } @@ -2357,8 +2418,10 @@ void GLAPIENTRY _mesa_GetInteger64Indexedv( GLenum pname, GLuint index, GLint64 *params ) { union value v; + enum value_type type = + find_value_indexed("glGetIntegerIndexedv", pname, index, &v); - switch (find_value_indexed("glGetIntegerIndexedv", pname, index, &v)) { + switch (type) { case TYPE_INT: params[0] = v.value_int; break; @@ -2372,7 +2435,7 @@ _mesa_GetInteger64Indexedv( GLenum pname, GLuint index, GLint64 *params ) params[0] = v.value_int; break; default: - assert(0); + ; /* nothing - GL error was recorded */ } } #endif /* FEATURE_ARB_sync */ diff --git a/src/mesa/main/getstring.c b/src/mesa/main/getstring.c index bfa283f6a3..f8866f6858 100644 --- a/src/mesa/main/getstring.c +++ b/src/mesa/main/getstring.c @@ -29,6 +29,8 @@ #include "get.h" #include "enums.h" #include "extensions.h" +#include "mfeatures.h" +#include "mtypes.h" /** diff --git a/src/mesa/main/glapidispatch.h b/src/mesa/main/glapidispatch.h index 87784269c5..cbfe6400e4 100644 --- a/src/mesa/main/glapidispatch.h +++ b/src/mesa/main/glapidispatch.h @@ -59,7 +59,7 @@ } while(0) /* total number of offsets below */ -#define _gloffset_COUNT 881 +#define _gloffset_COUNT 892 #define _gloffset_NewList 0 #define _gloffset_EndList 1 @@ -642,313 +642,324 @@ #define _gloffset_FramebufferTextureARB 575 #define _gloffset_FramebufferTextureFaceARB 576 #define _gloffset_ProgramParameteriARB 577 -#define _gloffset_FlushMappedBufferRange 578 -#define _gloffset_MapBufferRange 579 -#define _gloffset_BindVertexArray 580 -#define _gloffset_GenVertexArrays 581 -#define _gloffset_CopyBufferSubData 582 -#define _gloffset_ClientWaitSync 583 -#define _gloffset_DeleteSync 584 -#define _gloffset_FenceSync 585 -#define _gloffset_GetInteger64v 586 -#define _gloffset_GetSynciv 587 -#define _gloffset_IsSync 588 -#define _gloffset_WaitSync 589 -#define _gloffset_DrawElementsBaseVertex 590 -#define _gloffset_DrawRangeElementsBaseVertex 591 -#define _gloffset_MultiDrawElementsBaseVertex 592 -#define _gloffset_BindTransformFeedback 593 -#define _gloffset_DeleteTransformFeedbacks 594 -#define _gloffset_DrawTransformFeedback 595 -#define _gloffset_GenTransformFeedbacks 596 -#define _gloffset_IsTransformFeedback 597 -#define _gloffset_PauseTransformFeedback 598 -#define _gloffset_ResumeTransformFeedback 599 -#define _gloffset_PolygonOffsetEXT 600 -#define _gloffset_GetPixelTexGenParameterfvSGIS 601 -#define _gloffset_GetPixelTexGenParameterivSGIS 602 -#define _gloffset_PixelTexGenParameterfSGIS 603 -#define _gloffset_PixelTexGenParameterfvSGIS 604 -#define _gloffset_PixelTexGenParameteriSGIS 605 -#define _gloffset_PixelTexGenParameterivSGIS 606 -#define _gloffset_SampleMaskSGIS 607 -#define _gloffset_SamplePatternSGIS 608 -#define _gloffset_ColorPointerEXT 609 -#define _gloffset_EdgeFlagPointerEXT 610 -#define _gloffset_IndexPointerEXT 611 -#define _gloffset_NormalPointerEXT 612 -#define _gloffset_TexCoordPointerEXT 613 -#define _gloffset_VertexPointerEXT 614 -#define _gloffset_PointParameterfEXT 615 -#define _gloffset_PointParameterfvEXT 616 -#define _gloffset_LockArraysEXT 617 -#define _gloffset_UnlockArraysEXT 618 -#define _gloffset_SecondaryColor3bEXT 619 -#define _gloffset_SecondaryColor3bvEXT 620 -#define _gloffset_SecondaryColor3dEXT 621 -#define _gloffset_SecondaryColor3dvEXT 622 -#define _gloffset_SecondaryColor3fEXT 623 -#define _gloffset_SecondaryColor3fvEXT 624 -#define _gloffset_SecondaryColor3iEXT 625 -#define _gloffset_SecondaryColor3ivEXT 626 -#define _gloffset_SecondaryColor3sEXT 627 -#define _gloffset_SecondaryColor3svEXT 628 -#define _gloffset_SecondaryColor3ubEXT 629 -#define _gloffset_SecondaryColor3ubvEXT 630 -#define _gloffset_SecondaryColor3uiEXT 631 -#define _gloffset_SecondaryColor3uivEXT 632 -#define _gloffset_SecondaryColor3usEXT 633 -#define _gloffset_SecondaryColor3usvEXT 634 -#define _gloffset_SecondaryColorPointerEXT 635 -#define _gloffset_MultiDrawArraysEXT 636 -#define _gloffset_MultiDrawElementsEXT 637 -#define _gloffset_FogCoordPointerEXT 638 -#define _gloffset_FogCoorddEXT 639 -#define _gloffset_FogCoorddvEXT 640 -#define _gloffset_FogCoordfEXT 641 -#define _gloffset_FogCoordfvEXT 642 -#define _gloffset_PixelTexGenSGIX 643 -#define _gloffset_BlendFuncSeparateEXT 644 -#define _gloffset_FlushVertexArrayRangeNV 645 -#define _gloffset_VertexArrayRangeNV 646 -#define _gloffset_CombinerInputNV 647 -#define _gloffset_CombinerOutputNV 648 -#define _gloffset_CombinerParameterfNV 649 -#define _gloffset_CombinerParameterfvNV 650 -#define _gloffset_CombinerParameteriNV 651 -#define _gloffset_CombinerParameterivNV 652 -#define _gloffset_FinalCombinerInputNV 653 -#define _gloffset_GetCombinerInputParameterfvNV 654 -#define _gloffset_GetCombinerInputParameterivNV 655 -#define _gloffset_GetCombinerOutputParameterfvNV 656 -#define _gloffset_GetCombinerOutputParameterivNV 657 -#define _gloffset_GetFinalCombinerInputParameterfvNV 658 -#define _gloffset_GetFinalCombinerInputParameterivNV 659 -#define _gloffset_ResizeBuffersMESA 660 -#define _gloffset_WindowPos2dMESA 661 -#define _gloffset_WindowPos2dvMESA 662 -#define _gloffset_WindowPos2fMESA 663 -#define _gloffset_WindowPos2fvMESA 664 -#define _gloffset_WindowPos2iMESA 665 -#define _gloffset_WindowPos2ivMESA 666 -#define _gloffset_WindowPos2sMESA 667 -#define _gloffset_WindowPos2svMESA 668 -#define _gloffset_WindowPos3dMESA 669 -#define _gloffset_WindowPos3dvMESA 670 -#define _gloffset_WindowPos3fMESA 671 -#define _gloffset_WindowPos3fvMESA 672 -#define _gloffset_WindowPos3iMESA 673 -#define _gloffset_WindowPos3ivMESA 674 -#define _gloffset_WindowPos3sMESA 675 -#define _gloffset_WindowPos3svMESA 676 -#define _gloffset_WindowPos4dMESA 677 -#define _gloffset_WindowPos4dvMESA 678 -#define _gloffset_WindowPos4fMESA 679 -#define _gloffset_WindowPos4fvMESA 680 -#define _gloffset_WindowPos4iMESA 681 -#define _gloffset_WindowPos4ivMESA 682 -#define _gloffset_WindowPos4sMESA 683 -#define _gloffset_WindowPos4svMESA 684 -#define _gloffset_MultiModeDrawArraysIBM 685 -#define _gloffset_MultiModeDrawElementsIBM 686 -#define _gloffset_DeleteFencesNV 687 -#define _gloffset_FinishFenceNV 688 -#define _gloffset_GenFencesNV 689 -#define _gloffset_GetFenceivNV 690 -#define _gloffset_IsFenceNV 691 -#define _gloffset_SetFenceNV 692 -#define _gloffset_TestFenceNV 693 -#define _gloffset_AreProgramsResidentNV 694 -#define _gloffset_BindProgramNV 695 -#define _gloffset_DeleteProgramsNV 696 -#define _gloffset_ExecuteProgramNV 697 -#define _gloffset_GenProgramsNV 698 -#define _gloffset_GetProgramParameterdvNV 699 -#define _gloffset_GetProgramParameterfvNV 700 -#define _gloffset_GetProgramStringNV 701 -#define _gloffset_GetProgramivNV 702 -#define _gloffset_GetTrackMatrixivNV 703 -#define _gloffset_GetVertexAttribPointervNV 704 -#define _gloffset_GetVertexAttribdvNV 705 -#define _gloffset_GetVertexAttribfvNV 706 -#define _gloffset_GetVertexAttribivNV 707 -#define _gloffset_IsProgramNV 708 -#define _gloffset_LoadProgramNV 709 -#define _gloffset_ProgramParameters4dvNV 710 -#define _gloffset_ProgramParameters4fvNV 711 -#define _gloffset_RequestResidentProgramsNV 712 -#define _gloffset_TrackMatrixNV 713 -#define _gloffset_VertexAttrib1dNV 714 -#define _gloffset_VertexAttrib1dvNV 715 -#define _gloffset_VertexAttrib1fNV 716 -#define _gloffset_VertexAttrib1fvNV 717 -#define _gloffset_VertexAttrib1sNV 718 -#define _gloffset_VertexAttrib1svNV 719 -#define _gloffset_VertexAttrib2dNV 720 -#define _gloffset_VertexAttrib2dvNV 721 -#define _gloffset_VertexAttrib2fNV 722 -#define _gloffset_VertexAttrib2fvNV 723 -#define _gloffset_VertexAttrib2sNV 724 -#define _gloffset_VertexAttrib2svNV 725 -#define _gloffset_VertexAttrib3dNV 726 -#define _gloffset_VertexAttrib3dvNV 727 -#define _gloffset_VertexAttrib3fNV 728 -#define _gloffset_VertexAttrib3fvNV 729 -#define _gloffset_VertexAttrib3sNV 730 -#define _gloffset_VertexAttrib3svNV 731 -#define _gloffset_VertexAttrib4dNV 732 -#define _gloffset_VertexAttrib4dvNV 733 -#define _gloffset_VertexAttrib4fNV 734 -#define _gloffset_VertexAttrib4fvNV 735 -#define _gloffset_VertexAttrib4sNV 736 -#define _gloffset_VertexAttrib4svNV 737 -#define _gloffset_VertexAttrib4ubNV 738 -#define _gloffset_VertexAttrib4ubvNV 739 -#define _gloffset_VertexAttribPointerNV 740 -#define _gloffset_VertexAttribs1dvNV 741 -#define _gloffset_VertexAttribs1fvNV 742 -#define _gloffset_VertexAttribs1svNV 743 -#define _gloffset_VertexAttribs2dvNV 744 -#define _gloffset_VertexAttribs2fvNV 745 -#define _gloffset_VertexAttribs2svNV 746 -#define _gloffset_VertexAttribs3dvNV 747 -#define _gloffset_VertexAttribs3fvNV 748 -#define _gloffset_VertexAttribs3svNV 749 -#define _gloffset_VertexAttribs4dvNV 750 -#define _gloffset_VertexAttribs4fvNV 751 -#define _gloffset_VertexAttribs4svNV 752 -#define _gloffset_VertexAttribs4ubvNV 753 -#define _gloffset_GetTexBumpParameterfvATI 754 -#define _gloffset_GetTexBumpParameterivATI 755 -#define _gloffset_TexBumpParameterfvATI 756 -#define _gloffset_TexBumpParameterivATI 757 -#define _gloffset_AlphaFragmentOp1ATI 758 -#define _gloffset_AlphaFragmentOp2ATI 759 -#define _gloffset_AlphaFragmentOp3ATI 760 -#define _gloffset_BeginFragmentShaderATI 761 -#define _gloffset_BindFragmentShaderATI 762 -#define _gloffset_ColorFragmentOp1ATI 763 -#define _gloffset_ColorFragmentOp2ATI 764 -#define _gloffset_ColorFragmentOp3ATI 765 -#define _gloffset_DeleteFragmentShaderATI 766 -#define _gloffset_EndFragmentShaderATI 767 -#define _gloffset_GenFragmentShadersATI 768 -#define _gloffset_PassTexCoordATI 769 -#define _gloffset_SampleMapATI 770 -#define _gloffset_SetFragmentShaderConstantATI 771 -#define _gloffset_PointParameteriNV 772 -#define _gloffset_PointParameterivNV 773 -#define _gloffset_ActiveStencilFaceEXT 774 -#define _gloffset_BindVertexArrayAPPLE 775 -#define _gloffset_DeleteVertexArraysAPPLE 776 -#define _gloffset_GenVertexArraysAPPLE 777 -#define _gloffset_IsVertexArrayAPPLE 778 -#define _gloffset_GetProgramNamedParameterdvNV 779 -#define _gloffset_GetProgramNamedParameterfvNV 780 -#define _gloffset_ProgramNamedParameter4dNV 781 -#define _gloffset_ProgramNamedParameter4dvNV 782 -#define _gloffset_ProgramNamedParameter4fNV 783 -#define _gloffset_ProgramNamedParameter4fvNV 784 -#define _gloffset_PrimitiveRestartIndexNV 785 -#define _gloffset_PrimitiveRestartNV 786 -#define _gloffset_DepthBoundsEXT 787 -#define _gloffset_BlendEquationSeparateEXT 788 -#define _gloffset_BindFramebufferEXT 789 -#define _gloffset_BindRenderbufferEXT 790 -#define _gloffset_CheckFramebufferStatusEXT 791 -#define _gloffset_DeleteFramebuffersEXT 792 -#define _gloffset_DeleteRenderbuffersEXT 793 -#define _gloffset_FramebufferRenderbufferEXT 794 -#define _gloffset_FramebufferTexture1DEXT 795 -#define _gloffset_FramebufferTexture2DEXT 796 -#define _gloffset_FramebufferTexture3DEXT 797 -#define _gloffset_GenFramebuffersEXT 798 -#define _gloffset_GenRenderbuffersEXT 799 -#define _gloffset_GenerateMipmapEXT 800 -#define _gloffset_GetFramebufferAttachmentParameterivEXT 801 -#define _gloffset_GetRenderbufferParameterivEXT 802 -#define _gloffset_IsFramebufferEXT 803 -#define _gloffset_IsRenderbufferEXT 804 -#define _gloffset_RenderbufferStorageEXT 805 -#define _gloffset_BlitFramebufferEXT 806 -#define _gloffset_BufferParameteriAPPLE 807 -#define _gloffset_FlushMappedBufferRangeAPPLE 808 -#define _gloffset_BindFragDataLocationEXT 809 -#define _gloffset_GetFragDataLocationEXT 810 -#define _gloffset_GetUniformuivEXT 811 -#define _gloffset_GetVertexAttribIivEXT 812 -#define _gloffset_GetVertexAttribIuivEXT 813 -#define _gloffset_Uniform1uiEXT 814 -#define _gloffset_Uniform1uivEXT 815 -#define _gloffset_Uniform2uiEXT 816 -#define _gloffset_Uniform2uivEXT 817 -#define _gloffset_Uniform3uiEXT 818 -#define _gloffset_Uniform3uivEXT 819 -#define _gloffset_Uniform4uiEXT 820 -#define _gloffset_Uniform4uivEXT 821 -#define _gloffset_VertexAttribI1iEXT 822 -#define _gloffset_VertexAttribI1ivEXT 823 -#define _gloffset_VertexAttribI1uiEXT 824 -#define _gloffset_VertexAttribI1uivEXT 825 -#define _gloffset_VertexAttribI2iEXT 826 -#define _gloffset_VertexAttribI2ivEXT 827 -#define _gloffset_VertexAttribI2uiEXT 828 -#define _gloffset_VertexAttribI2uivEXT 829 -#define _gloffset_VertexAttribI3iEXT 830 -#define _gloffset_VertexAttribI3ivEXT 831 -#define _gloffset_VertexAttribI3uiEXT 832 -#define _gloffset_VertexAttribI3uivEXT 833 -#define _gloffset_VertexAttribI4bvEXT 834 -#define _gloffset_VertexAttribI4iEXT 835 -#define _gloffset_VertexAttribI4ivEXT 836 -#define _gloffset_VertexAttribI4svEXT 837 -#define _gloffset_VertexAttribI4ubvEXT 838 -#define _gloffset_VertexAttribI4uiEXT 839 -#define _gloffset_VertexAttribI4uivEXT 840 -#define _gloffset_VertexAttribI4usvEXT 841 -#define _gloffset_VertexAttribIPointerEXT 842 -#define _gloffset_FramebufferTextureLayerEXT 843 -#define _gloffset_ColorMaskIndexedEXT 844 -#define _gloffset_DisableIndexedEXT 845 -#define _gloffset_EnableIndexedEXT 846 -#define _gloffset_GetBooleanIndexedvEXT 847 -#define _gloffset_GetIntegerIndexedvEXT 848 -#define _gloffset_IsEnabledIndexedEXT 849 -#define _gloffset_ClearColorIiEXT 850 -#define _gloffset_ClearColorIuiEXT 851 -#define _gloffset_GetTexParameterIivEXT 852 -#define _gloffset_GetTexParameterIuivEXT 853 -#define _gloffset_TexParameterIivEXT 854 -#define _gloffset_TexParameterIuivEXT 855 -#define _gloffset_BeginConditionalRenderNV 856 -#define _gloffset_EndConditionalRenderNV 857 -#define _gloffset_BeginTransformFeedbackEXT 858 -#define _gloffset_BindBufferBaseEXT 859 -#define _gloffset_BindBufferOffsetEXT 860 -#define _gloffset_BindBufferRangeEXT 861 -#define _gloffset_EndTransformFeedbackEXT 862 -#define _gloffset_GetTransformFeedbackVaryingEXT 863 -#define _gloffset_TransformFeedbackVaryingsEXT 864 -#define _gloffset_ProvokingVertexEXT 865 -#define _gloffset_GetTexParameterPointervAPPLE 866 -#define _gloffset_TextureRangeAPPLE 867 -#define _gloffset_GetObjectParameterivAPPLE 868 -#define _gloffset_ObjectPurgeableAPPLE 869 -#define _gloffset_ObjectUnpurgeableAPPLE 870 -#define _gloffset_ActiveProgramEXT 871 -#define _gloffset_CreateShaderProgramEXT 872 -#define _gloffset_UseShaderProgramEXT 873 -#define _gloffset_StencilFuncSeparateATI 874 -#define _gloffset_ProgramEnvParameters4fvEXT 875 -#define _gloffset_ProgramLocalParameters4fvEXT 876 -#define _gloffset_GetQueryObjecti64vEXT 877 -#define _gloffset_GetQueryObjectui64vEXT 878 -#define _gloffset_EGLImageTargetRenderbufferStorageOES 879 -#define _gloffset_EGLImageTargetTexture2DOES 880 +#define _gloffset_VertexAttribDivisorARB 578 +#define _gloffset_FlushMappedBufferRange 579 +#define _gloffset_MapBufferRange 580 +#define _gloffset_BindVertexArray 581 +#define _gloffset_GenVertexArrays 582 +#define _gloffset_CopyBufferSubData 583 +#define _gloffset_ClientWaitSync 584 +#define _gloffset_DeleteSync 585 +#define _gloffset_FenceSync 586 +#define _gloffset_GetInteger64v 587 +#define _gloffset_GetSynciv 588 +#define _gloffset_IsSync 589 +#define _gloffset_WaitSync 590 +#define _gloffset_DrawElementsBaseVertex 591 +#define _gloffset_DrawRangeElementsBaseVertex 592 +#define _gloffset_MultiDrawElementsBaseVertex 593 +#define _gloffset_BlendEquationSeparateiARB 594 +#define _gloffset_BlendEquationiARB 595 +#define _gloffset_BlendFuncSeparateiARB 596 +#define _gloffset_BlendFunciARB 597 +#define _gloffset_BindTransformFeedback 598 +#define _gloffset_DeleteTransformFeedbacks 599 +#define _gloffset_DrawTransformFeedback 600 +#define _gloffset_GenTransformFeedbacks 601 +#define _gloffset_IsTransformFeedback 602 +#define _gloffset_PauseTransformFeedback 603 +#define _gloffset_ResumeTransformFeedback 604 +#define _gloffset_ClearDepthf 605 +#define _gloffset_DepthRangef 606 +#define _gloffset_GetShaderPrecisionFormat 607 +#define _gloffset_ReleaseShaderCompiler 608 +#define _gloffset_ShaderBinary 609 +#define _gloffset_PolygonOffsetEXT 610 +#define _gloffset_GetPixelTexGenParameterfvSGIS 611 +#define _gloffset_GetPixelTexGenParameterivSGIS 612 +#define _gloffset_PixelTexGenParameterfSGIS 613 +#define _gloffset_PixelTexGenParameterfvSGIS 614 +#define _gloffset_PixelTexGenParameteriSGIS 615 +#define _gloffset_PixelTexGenParameterivSGIS 616 +#define _gloffset_SampleMaskSGIS 617 +#define _gloffset_SamplePatternSGIS 618 +#define _gloffset_ColorPointerEXT 619 +#define _gloffset_EdgeFlagPointerEXT 620 +#define _gloffset_IndexPointerEXT 621 +#define _gloffset_NormalPointerEXT 622 +#define _gloffset_TexCoordPointerEXT 623 +#define _gloffset_VertexPointerEXT 624 +#define _gloffset_PointParameterfEXT 625 +#define _gloffset_PointParameterfvEXT 626 +#define _gloffset_LockArraysEXT 627 +#define _gloffset_UnlockArraysEXT 628 +#define _gloffset_SecondaryColor3bEXT 629 +#define _gloffset_SecondaryColor3bvEXT 630 +#define _gloffset_SecondaryColor3dEXT 631 +#define _gloffset_SecondaryColor3dvEXT 632 +#define _gloffset_SecondaryColor3fEXT 633 +#define _gloffset_SecondaryColor3fvEXT 634 +#define _gloffset_SecondaryColor3iEXT 635 +#define _gloffset_SecondaryColor3ivEXT 636 +#define _gloffset_SecondaryColor3sEXT 637 +#define _gloffset_SecondaryColor3svEXT 638 +#define _gloffset_SecondaryColor3ubEXT 639 +#define _gloffset_SecondaryColor3ubvEXT 640 +#define _gloffset_SecondaryColor3uiEXT 641 +#define _gloffset_SecondaryColor3uivEXT 642 +#define _gloffset_SecondaryColor3usEXT 643 +#define _gloffset_SecondaryColor3usvEXT 644 +#define _gloffset_SecondaryColorPointerEXT 645 +#define _gloffset_MultiDrawArraysEXT 646 +#define _gloffset_MultiDrawElementsEXT 647 +#define _gloffset_FogCoordPointerEXT 648 +#define _gloffset_FogCoorddEXT 649 +#define _gloffset_FogCoorddvEXT 650 +#define _gloffset_FogCoordfEXT 651 +#define _gloffset_FogCoordfvEXT 652 +#define _gloffset_PixelTexGenSGIX 653 +#define _gloffset_BlendFuncSeparateEXT 654 +#define _gloffset_FlushVertexArrayRangeNV 655 +#define _gloffset_VertexArrayRangeNV 656 +#define _gloffset_CombinerInputNV 657 +#define _gloffset_CombinerOutputNV 658 +#define _gloffset_CombinerParameterfNV 659 +#define _gloffset_CombinerParameterfvNV 660 +#define _gloffset_CombinerParameteriNV 661 +#define _gloffset_CombinerParameterivNV 662 +#define _gloffset_FinalCombinerInputNV 663 +#define _gloffset_GetCombinerInputParameterfvNV 664 +#define _gloffset_GetCombinerInputParameterivNV 665 +#define _gloffset_GetCombinerOutputParameterfvNV 666 +#define _gloffset_GetCombinerOutputParameterivNV 667 +#define _gloffset_GetFinalCombinerInputParameterfvNV 668 +#define _gloffset_GetFinalCombinerInputParameterivNV 669 +#define _gloffset_ResizeBuffersMESA 670 +#define _gloffset_WindowPos2dMESA 671 +#define _gloffset_WindowPos2dvMESA 672 +#define _gloffset_WindowPos2fMESA 673 +#define _gloffset_WindowPos2fvMESA 674 +#define _gloffset_WindowPos2iMESA 675 +#define _gloffset_WindowPos2ivMESA 676 +#define _gloffset_WindowPos2sMESA 677 +#define _gloffset_WindowPos2svMESA 678 +#define _gloffset_WindowPos3dMESA 679 +#define _gloffset_WindowPos3dvMESA 680 +#define _gloffset_WindowPos3fMESA 681 +#define _gloffset_WindowPos3fvMESA 682 +#define _gloffset_WindowPos3iMESA 683 +#define _gloffset_WindowPos3ivMESA 684 +#define _gloffset_WindowPos3sMESA 685 +#define _gloffset_WindowPos3svMESA 686 +#define _gloffset_WindowPos4dMESA 687 +#define _gloffset_WindowPos4dvMESA 688 +#define _gloffset_WindowPos4fMESA 689 +#define _gloffset_WindowPos4fvMESA 690 +#define _gloffset_WindowPos4iMESA 691 +#define _gloffset_WindowPos4ivMESA 692 +#define _gloffset_WindowPos4sMESA 693 +#define _gloffset_WindowPos4svMESA 694 +#define _gloffset_MultiModeDrawArraysIBM 695 +#define _gloffset_MultiModeDrawElementsIBM 696 +#define _gloffset_DeleteFencesNV 697 +#define _gloffset_FinishFenceNV 698 +#define _gloffset_GenFencesNV 699 +#define _gloffset_GetFenceivNV 700 +#define _gloffset_IsFenceNV 701 +#define _gloffset_SetFenceNV 702 +#define _gloffset_TestFenceNV 703 +#define _gloffset_AreProgramsResidentNV 704 +#define _gloffset_BindProgramNV 705 +#define _gloffset_DeleteProgramsNV 706 +#define _gloffset_ExecuteProgramNV 707 +#define _gloffset_GenProgramsNV 708 +#define _gloffset_GetProgramParameterdvNV 709 +#define _gloffset_GetProgramParameterfvNV 710 +#define _gloffset_GetProgramStringNV 711 +#define _gloffset_GetProgramivNV 712 +#define _gloffset_GetTrackMatrixivNV 713 +#define _gloffset_GetVertexAttribPointervNV 714 +#define _gloffset_GetVertexAttribdvNV 715 +#define _gloffset_GetVertexAttribfvNV 716 +#define _gloffset_GetVertexAttribivNV 717 +#define _gloffset_IsProgramNV 718 +#define _gloffset_LoadProgramNV 719 +#define _gloffset_ProgramParameters4dvNV 720 +#define _gloffset_ProgramParameters4fvNV 721 +#define _gloffset_RequestResidentProgramsNV 722 +#define _gloffset_TrackMatrixNV 723 +#define _gloffset_VertexAttrib1dNV 724 +#define _gloffset_VertexAttrib1dvNV 725 +#define _gloffset_VertexAttrib1fNV 726 +#define _gloffset_VertexAttrib1fvNV 727 +#define _gloffset_VertexAttrib1sNV 728 +#define _gloffset_VertexAttrib1svNV 729 +#define _gloffset_VertexAttrib2dNV 730 +#define _gloffset_VertexAttrib2dvNV 731 +#define _gloffset_VertexAttrib2fNV 732 +#define _gloffset_VertexAttrib2fvNV 733 +#define _gloffset_VertexAttrib2sNV 734 +#define _gloffset_VertexAttrib2svNV 735 +#define _gloffset_VertexAttrib3dNV 736 +#define _gloffset_VertexAttrib3dvNV 737 +#define _gloffset_VertexAttrib3fNV 738 +#define _gloffset_VertexAttrib3fvNV 739 +#define _gloffset_VertexAttrib3sNV 740 +#define _gloffset_VertexAttrib3svNV 741 +#define _gloffset_VertexAttrib4dNV 742 +#define _gloffset_VertexAttrib4dvNV 743 +#define _gloffset_VertexAttrib4fNV 744 +#define _gloffset_VertexAttrib4fvNV 745 +#define _gloffset_VertexAttrib4sNV 746 +#define _gloffset_VertexAttrib4svNV 747 +#define _gloffset_VertexAttrib4ubNV 748 +#define _gloffset_VertexAttrib4ubvNV 749 +#define _gloffset_VertexAttribPointerNV 750 +#define _gloffset_VertexAttribs1dvNV 751 +#define _gloffset_VertexAttribs1fvNV 752 +#define _gloffset_VertexAttribs1svNV 753 +#define _gloffset_VertexAttribs2dvNV 754 +#define _gloffset_VertexAttribs2fvNV 755 +#define _gloffset_VertexAttribs2svNV 756 +#define _gloffset_VertexAttribs3dvNV 757 +#define _gloffset_VertexAttribs3fvNV 758 +#define _gloffset_VertexAttribs3svNV 759 +#define _gloffset_VertexAttribs4dvNV 760 +#define _gloffset_VertexAttribs4fvNV 761 +#define _gloffset_VertexAttribs4svNV 762 +#define _gloffset_VertexAttribs4ubvNV 763 +#define _gloffset_GetTexBumpParameterfvATI 764 +#define _gloffset_GetTexBumpParameterivATI 765 +#define _gloffset_TexBumpParameterfvATI 766 +#define _gloffset_TexBumpParameterivATI 767 +#define _gloffset_AlphaFragmentOp1ATI 768 +#define _gloffset_AlphaFragmentOp2ATI 769 +#define _gloffset_AlphaFragmentOp3ATI 770 +#define _gloffset_BeginFragmentShaderATI 771 +#define _gloffset_BindFragmentShaderATI 772 +#define _gloffset_ColorFragmentOp1ATI 773 +#define _gloffset_ColorFragmentOp2ATI 774 +#define _gloffset_ColorFragmentOp3ATI 775 +#define _gloffset_DeleteFragmentShaderATI 776 +#define _gloffset_EndFragmentShaderATI 777 +#define _gloffset_GenFragmentShadersATI 778 +#define _gloffset_PassTexCoordATI 779 +#define _gloffset_SampleMapATI 780 +#define _gloffset_SetFragmentShaderConstantATI 781 +#define _gloffset_PointParameteriNV 782 +#define _gloffset_PointParameterivNV 783 +#define _gloffset_ActiveStencilFaceEXT 784 +#define _gloffset_BindVertexArrayAPPLE 785 +#define _gloffset_DeleteVertexArraysAPPLE 786 +#define _gloffset_GenVertexArraysAPPLE 787 +#define _gloffset_IsVertexArrayAPPLE 788 +#define _gloffset_GetProgramNamedParameterdvNV 789 +#define _gloffset_GetProgramNamedParameterfvNV 790 +#define _gloffset_ProgramNamedParameter4dNV 791 +#define _gloffset_ProgramNamedParameter4dvNV 792 +#define _gloffset_ProgramNamedParameter4fNV 793 +#define _gloffset_ProgramNamedParameter4fvNV 794 +#define _gloffset_PrimitiveRestartIndexNV 795 +#define _gloffset_PrimitiveRestartNV 796 +#define _gloffset_DepthBoundsEXT 797 +#define _gloffset_BlendEquationSeparateEXT 798 +#define _gloffset_BindFramebufferEXT 799 +#define _gloffset_BindRenderbufferEXT 800 +#define _gloffset_CheckFramebufferStatusEXT 801 +#define _gloffset_DeleteFramebuffersEXT 802 +#define _gloffset_DeleteRenderbuffersEXT 803 +#define _gloffset_FramebufferRenderbufferEXT 804 +#define _gloffset_FramebufferTexture1DEXT 805 +#define _gloffset_FramebufferTexture2DEXT 806 +#define _gloffset_FramebufferTexture3DEXT 807 +#define _gloffset_GenFramebuffersEXT 808 +#define _gloffset_GenRenderbuffersEXT 809 +#define _gloffset_GenerateMipmapEXT 810 +#define _gloffset_GetFramebufferAttachmentParameterivEXT 811 +#define _gloffset_GetRenderbufferParameterivEXT 812 +#define _gloffset_IsFramebufferEXT 813 +#define _gloffset_IsRenderbufferEXT 814 +#define _gloffset_RenderbufferStorageEXT 815 +#define _gloffset_BlitFramebufferEXT 816 +#define _gloffset_BufferParameteriAPPLE 817 +#define _gloffset_FlushMappedBufferRangeAPPLE 818 +#define _gloffset_BindFragDataLocationEXT 819 +#define _gloffset_GetFragDataLocationEXT 820 +#define _gloffset_GetUniformuivEXT 821 +#define _gloffset_GetVertexAttribIivEXT 822 +#define _gloffset_GetVertexAttribIuivEXT 823 +#define _gloffset_Uniform1uiEXT 824 +#define _gloffset_Uniform1uivEXT 825 +#define _gloffset_Uniform2uiEXT 826 +#define _gloffset_Uniform2uivEXT 827 +#define _gloffset_Uniform3uiEXT 828 +#define _gloffset_Uniform3uivEXT 829 +#define _gloffset_Uniform4uiEXT 830 +#define _gloffset_Uniform4uivEXT 831 +#define _gloffset_VertexAttribI1iEXT 832 +#define _gloffset_VertexAttribI1ivEXT 833 +#define _gloffset_VertexAttribI1uiEXT 834 +#define _gloffset_VertexAttribI1uivEXT 835 +#define _gloffset_VertexAttribI2iEXT 836 +#define _gloffset_VertexAttribI2ivEXT 837 +#define _gloffset_VertexAttribI2uiEXT 838 +#define _gloffset_VertexAttribI2uivEXT 839 +#define _gloffset_VertexAttribI3iEXT 840 +#define _gloffset_VertexAttribI3ivEXT 841 +#define _gloffset_VertexAttribI3uiEXT 842 +#define _gloffset_VertexAttribI3uivEXT 843 +#define _gloffset_VertexAttribI4bvEXT 844 +#define _gloffset_VertexAttribI4iEXT 845 +#define _gloffset_VertexAttribI4ivEXT 846 +#define _gloffset_VertexAttribI4svEXT 847 +#define _gloffset_VertexAttribI4ubvEXT 848 +#define _gloffset_VertexAttribI4uiEXT 849 +#define _gloffset_VertexAttribI4uivEXT 850 +#define _gloffset_VertexAttribI4usvEXT 851 +#define _gloffset_VertexAttribIPointerEXT 852 +#define _gloffset_FramebufferTextureLayerEXT 853 +#define _gloffset_ColorMaskIndexedEXT 854 +#define _gloffset_DisableIndexedEXT 855 +#define _gloffset_EnableIndexedEXT 856 +#define _gloffset_GetBooleanIndexedvEXT 857 +#define _gloffset_GetIntegerIndexedvEXT 858 +#define _gloffset_IsEnabledIndexedEXT 859 +#define _gloffset_ClearColorIiEXT 860 +#define _gloffset_ClearColorIuiEXT 861 +#define _gloffset_GetTexParameterIivEXT 862 +#define _gloffset_GetTexParameterIuivEXT 863 +#define _gloffset_TexParameterIivEXT 864 +#define _gloffset_TexParameterIuivEXT 865 +#define _gloffset_BeginConditionalRenderNV 866 +#define _gloffset_EndConditionalRenderNV 867 +#define _gloffset_BeginTransformFeedbackEXT 868 +#define _gloffset_BindBufferBaseEXT 869 +#define _gloffset_BindBufferOffsetEXT 870 +#define _gloffset_BindBufferRangeEXT 871 +#define _gloffset_EndTransformFeedbackEXT 872 +#define _gloffset_GetTransformFeedbackVaryingEXT 873 +#define _gloffset_TransformFeedbackVaryingsEXT 874 +#define _gloffset_ProvokingVertexEXT 875 +#define _gloffset_GetTexParameterPointervAPPLE 876 +#define _gloffset_TextureRangeAPPLE 877 +#define _gloffset_GetObjectParameterivAPPLE 878 +#define _gloffset_ObjectPurgeableAPPLE 879 +#define _gloffset_ObjectUnpurgeableAPPLE 880 +#define _gloffset_ActiveProgramEXT 881 +#define _gloffset_CreateShaderProgramEXT 882 +#define _gloffset_UseShaderProgramEXT 883 +#define _gloffset_TextureBarrierNV 884 +#define _gloffset_StencilFuncSeparateATI 885 +#define _gloffset_ProgramEnvParameters4fvEXT 886 +#define _gloffset_ProgramLocalParameters4fvEXT 887 +#define _gloffset_GetQueryObjecti64vEXT 888 +#define _gloffset_GetQueryObjectui64vEXT 889 +#define _gloffset_EGLImageTargetRenderbufferStorageOES 890 +#define _gloffset_EGLImageTargetTexture2DOES 891 #else /* !_GLAPI_USE_REMAP_TABLE */ -#define driDispatchRemapTable_size 473 +#define driDispatchRemapTable_size 484 extern int driDispatchRemapTable[ driDispatchRemapTable_size ]; #define AttachShader_remap_index 0 @@ -1121,309 +1132,320 @@ extern int driDispatchRemapTable[ driDispatchRemapTable_size ]; #define FramebufferTextureARB_remap_index 167 #define FramebufferTextureFaceARB_remap_index 168 #define ProgramParameteriARB_remap_index 169 -#define FlushMappedBufferRange_remap_index 170 -#define MapBufferRange_remap_index 171 -#define BindVertexArray_remap_index 172 -#define GenVertexArrays_remap_index 173 -#define CopyBufferSubData_remap_index 174 -#define ClientWaitSync_remap_index 175 -#define DeleteSync_remap_index 176 -#define FenceSync_remap_index 177 -#define GetInteger64v_remap_index 178 -#define GetSynciv_remap_index 179 -#define IsSync_remap_index 180 -#define WaitSync_remap_index 181 -#define DrawElementsBaseVertex_remap_index 182 -#define DrawRangeElementsBaseVertex_remap_index 183 -#define MultiDrawElementsBaseVertex_remap_index 184 -#define BindTransformFeedback_remap_index 185 -#define DeleteTransformFeedbacks_remap_index 186 -#define DrawTransformFeedback_remap_index 187 -#define GenTransformFeedbacks_remap_index 188 -#define IsTransformFeedback_remap_index 189 -#define PauseTransformFeedback_remap_index 190 -#define ResumeTransformFeedback_remap_index 191 -#define PolygonOffsetEXT_remap_index 192 -#define GetPixelTexGenParameterfvSGIS_remap_index 193 -#define GetPixelTexGenParameterivSGIS_remap_index 194 -#define PixelTexGenParameterfSGIS_remap_index 195 -#define PixelTexGenParameterfvSGIS_remap_index 196 -#define PixelTexGenParameteriSGIS_remap_index 197 -#define PixelTexGenParameterivSGIS_remap_index 198 -#define SampleMaskSGIS_remap_index 199 -#define SamplePatternSGIS_remap_index 200 -#define ColorPointerEXT_remap_index 201 -#define EdgeFlagPointerEXT_remap_index 202 -#define IndexPointerEXT_remap_index 203 -#define NormalPointerEXT_remap_index 204 -#define TexCoordPointerEXT_remap_index 205 -#define VertexPointerEXT_remap_index 206 -#define PointParameterfEXT_remap_index 207 -#define PointParameterfvEXT_remap_index 208 -#define LockArraysEXT_remap_index 209 -#define UnlockArraysEXT_remap_index 210 -#define SecondaryColor3bEXT_remap_index 211 -#define SecondaryColor3bvEXT_remap_index 212 -#define SecondaryColor3dEXT_remap_index 213 -#define SecondaryColor3dvEXT_remap_index 214 -#define SecondaryColor3fEXT_remap_index 215 -#define SecondaryColor3fvEXT_remap_index 216 -#define SecondaryColor3iEXT_remap_index 217 -#define SecondaryColor3ivEXT_remap_index 218 -#define SecondaryColor3sEXT_remap_index 219 -#define SecondaryColor3svEXT_remap_index 220 -#define SecondaryColor3ubEXT_remap_index 221 -#define SecondaryColor3ubvEXT_remap_index 222 -#define SecondaryColor3uiEXT_remap_index 223 -#define SecondaryColor3uivEXT_remap_index 224 -#define SecondaryColor3usEXT_remap_index 225 -#define SecondaryColor3usvEXT_remap_index 226 -#define SecondaryColorPointerEXT_remap_index 227 -#define MultiDrawArraysEXT_remap_index 228 -#define MultiDrawElementsEXT_remap_index 229 -#define FogCoordPointerEXT_remap_index 230 -#define FogCoorddEXT_remap_index 231 -#define FogCoorddvEXT_remap_index 232 -#define FogCoordfEXT_remap_index 233 -#define FogCoordfvEXT_remap_index 234 -#define PixelTexGenSGIX_remap_index 235 -#define BlendFuncSeparateEXT_remap_index 236 -#define FlushVertexArrayRangeNV_remap_index 237 -#define VertexArrayRangeNV_remap_index 238 -#define CombinerInputNV_remap_index 239 -#define CombinerOutputNV_remap_index 240 -#define CombinerParameterfNV_remap_index 241 -#define CombinerParameterfvNV_remap_index 242 -#define CombinerParameteriNV_remap_index 243 -#define CombinerParameterivNV_remap_index 244 -#define FinalCombinerInputNV_remap_index 245 -#define GetCombinerInputParameterfvNV_remap_index 246 -#define GetCombinerInputParameterivNV_remap_index 247 -#define GetCombinerOutputParameterfvNV_remap_index 248 -#define GetCombinerOutputParameterivNV_remap_index 249 -#define GetFinalCombinerInputParameterfvNV_remap_index 250 -#define GetFinalCombinerInputParameterivNV_remap_index 251 -#define ResizeBuffersMESA_remap_index 252 -#define WindowPos2dMESA_remap_index 253 -#define WindowPos2dvMESA_remap_index 254 -#define WindowPos2fMESA_remap_index 255 -#define WindowPos2fvMESA_remap_index 256 -#define WindowPos2iMESA_remap_index 257 -#define WindowPos2ivMESA_remap_index 258 -#define WindowPos2sMESA_remap_index 259 -#define WindowPos2svMESA_remap_index 260 -#define WindowPos3dMESA_remap_index 261 -#define WindowPos3dvMESA_remap_index 262 -#define WindowPos3fMESA_remap_index 263 -#define WindowPos3fvMESA_remap_index 264 -#define WindowPos3iMESA_remap_index 265 -#define WindowPos3ivMESA_remap_index 266 -#define WindowPos3sMESA_remap_index 267 -#define WindowPos3svMESA_remap_index 268 -#define WindowPos4dMESA_remap_index 269 -#define WindowPos4dvMESA_remap_index 270 -#define WindowPos4fMESA_remap_index 271 -#define WindowPos4fvMESA_remap_index 272 -#define WindowPos4iMESA_remap_index 273 -#define WindowPos4ivMESA_remap_index 274 -#define WindowPos4sMESA_remap_index 275 -#define WindowPos4svMESA_remap_index 276 -#define MultiModeDrawArraysIBM_remap_index 277 -#define MultiModeDrawElementsIBM_remap_index 278 -#define DeleteFencesNV_remap_index 279 -#define FinishFenceNV_remap_index 280 -#define GenFencesNV_remap_index 281 -#define GetFenceivNV_remap_index 282 -#define IsFenceNV_remap_index 283 -#define SetFenceNV_remap_index 284 -#define TestFenceNV_remap_index 285 -#define AreProgramsResidentNV_remap_index 286 -#define BindProgramNV_remap_index 287 -#define DeleteProgramsNV_remap_index 288 -#define ExecuteProgramNV_remap_index 289 -#define GenProgramsNV_remap_index 290 -#define GetProgramParameterdvNV_remap_index 291 -#define GetProgramParameterfvNV_remap_index 292 -#define GetProgramStringNV_remap_index 293 -#define GetProgramivNV_remap_index 294 -#define GetTrackMatrixivNV_remap_index 295 -#define GetVertexAttribPointervNV_remap_index 296 -#define GetVertexAttribdvNV_remap_index 297 -#define GetVertexAttribfvNV_remap_index 298 -#define GetVertexAttribivNV_remap_index 299 -#define IsProgramNV_remap_index 300 -#define LoadProgramNV_remap_index 301 -#define ProgramParameters4dvNV_remap_index 302 -#define ProgramParameters4fvNV_remap_index 303 -#define RequestResidentProgramsNV_remap_index 304 -#define TrackMatrixNV_remap_index 305 -#define VertexAttrib1dNV_remap_index 306 -#define VertexAttrib1dvNV_remap_index 307 -#define VertexAttrib1fNV_remap_index 308 -#define VertexAttrib1fvNV_remap_index 309 -#define VertexAttrib1sNV_remap_index 310 -#define VertexAttrib1svNV_remap_index 311 -#define VertexAttrib2dNV_remap_index 312 -#define VertexAttrib2dvNV_remap_index 313 -#define VertexAttrib2fNV_remap_index 314 -#define VertexAttrib2fvNV_remap_index 315 -#define VertexAttrib2sNV_remap_index 316 -#define VertexAttrib2svNV_remap_index 317 -#define VertexAttrib3dNV_remap_index 318 -#define VertexAttrib3dvNV_remap_index 319 -#define VertexAttrib3fNV_remap_index 320 -#define VertexAttrib3fvNV_remap_index 321 -#define VertexAttrib3sNV_remap_index 322 -#define VertexAttrib3svNV_remap_index 323 -#define VertexAttrib4dNV_remap_index 324 -#define VertexAttrib4dvNV_remap_index 325 -#define VertexAttrib4fNV_remap_index 326 -#define VertexAttrib4fvNV_remap_index 327 -#define VertexAttrib4sNV_remap_index 328 -#define VertexAttrib4svNV_remap_index 329 -#define VertexAttrib4ubNV_remap_index 330 -#define VertexAttrib4ubvNV_remap_index 331 -#define VertexAttribPointerNV_remap_index 332 -#define VertexAttribs1dvNV_remap_index 333 -#define VertexAttribs1fvNV_remap_index 334 -#define VertexAttribs1svNV_remap_index 335 -#define VertexAttribs2dvNV_remap_index 336 -#define VertexAttribs2fvNV_remap_index 337 -#define VertexAttribs2svNV_remap_index 338 -#define VertexAttribs3dvNV_remap_index 339 -#define VertexAttribs3fvNV_remap_index 340 -#define VertexAttribs3svNV_remap_index 341 -#define VertexAttribs4dvNV_remap_index 342 -#define VertexAttribs4fvNV_remap_index 343 -#define VertexAttribs4svNV_remap_index 344 -#define VertexAttribs4ubvNV_remap_index 345 -#define GetTexBumpParameterfvATI_remap_index 346 -#define GetTexBumpParameterivATI_remap_index 347 -#define TexBumpParameterfvATI_remap_index 348 -#define TexBumpParameterivATI_remap_index 349 -#define AlphaFragmentOp1ATI_remap_index 350 -#define AlphaFragmentOp2ATI_remap_index 351 -#define AlphaFragmentOp3ATI_remap_index 352 -#define BeginFragmentShaderATI_remap_index 353 -#define BindFragmentShaderATI_remap_index 354 -#define ColorFragmentOp1ATI_remap_index 355 -#define ColorFragmentOp2ATI_remap_index 356 -#define ColorFragmentOp3ATI_remap_index 357 -#define DeleteFragmentShaderATI_remap_index 358 -#define EndFragmentShaderATI_remap_index 359 -#define GenFragmentShadersATI_remap_index 360 -#define PassTexCoordATI_remap_index 361 -#define SampleMapATI_remap_index 362 -#define SetFragmentShaderConstantATI_remap_index 363 -#define PointParameteriNV_remap_index 364 -#define PointParameterivNV_remap_index 365 -#define ActiveStencilFaceEXT_remap_index 366 -#define BindVertexArrayAPPLE_remap_index 367 -#define DeleteVertexArraysAPPLE_remap_index 368 -#define GenVertexArraysAPPLE_remap_index 369 -#define IsVertexArrayAPPLE_remap_index 370 -#define GetProgramNamedParameterdvNV_remap_index 371 -#define GetProgramNamedParameterfvNV_remap_index 372 -#define ProgramNamedParameter4dNV_remap_index 373 -#define ProgramNamedParameter4dvNV_remap_index 374 -#define ProgramNamedParameter4fNV_remap_index 375 -#define ProgramNamedParameter4fvNV_remap_index 376 -#define PrimitiveRestartIndexNV_remap_index 377 -#define PrimitiveRestartNV_remap_index 378 -#define DepthBoundsEXT_remap_index 379 -#define BlendEquationSeparateEXT_remap_index 380 -#define BindFramebufferEXT_remap_index 381 -#define BindRenderbufferEXT_remap_index 382 -#define CheckFramebufferStatusEXT_remap_index 383 -#define DeleteFramebuffersEXT_remap_index 384 -#define DeleteRenderbuffersEXT_remap_index 385 -#define FramebufferRenderbufferEXT_remap_index 386 -#define FramebufferTexture1DEXT_remap_index 387 -#define FramebufferTexture2DEXT_remap_index 388 -#define FramebufferTexture3DEXT_remap_index 389 -#define GenFramebuffersEXT_remap_index 390 -#define GenRenderbuffersEXT_remap_index 391 -#define GenerateMipmapEXT_remap_index 392 -#define GetFramebufferAttachmentParameterivEXT_remap_index 393 -#define GetRenderbufferParameterivEXT_remap_index 394 -#define IsFramebufferEXT_remap_index 395 -#define IsRenderbufferEXT_remap_index 396 -#define RenderbufferStorageEXT_remap_index 397 -#define BlitFramebufferEXT_remap_index 398 -#define BufferParameteriAPPLE_remap_index 399 -#define FlushMappedBufferRangeAPPLE_remap_index 400 -#define BindFragDataLocationEXT_remap_index 401 -#define GetFragDataLocationEXT_remap_index 402 -#define GetUniformuivEXT_remap_index 403 -#define GetVertexAttribIivEXT_remap_index 404 -#define GetVertexAttribIuivEXT_remap_index 405 -#define Uniform1uiEXT_remap_index 406 -#define Uniform1uivEXT_remap_index 407 -#define Uniform2uiEXT_remap_index 408 -#define Uniform2uivEXT_remap_index 409 -#define Uniform3uiEXT_remap_index 410 -#define Uniform3uivEXT_remap_index 411 -#define Uniform4uiEXT_remap_index 412 -#define Uniform4uivEXT_remap_index 413 -#define VertexAttribI1iEXT_remap_index 414 -#define VertexAttribI1ivEXT_remap_index 415 -#define VertexAttribI1uiEXT_remap_index 416 -#define VertexAttribI1uivEXT_remap_index 417 -#define VertexAttribI2iEXT_remap_index 418 -#define VertexAttribI2ivEXT_remap_index 419 -#define VertexAttribI2uiEXT_remap_index 420 -#define VertexAttribI2uivEXT_remap_index 421 -#define VertexAttribI3iEXT_remap_index 422 -#define VertexAttribI3ivEXT_remap_index 423 -#define VertexAttribI3uiEXT_remap_index 424 -#define VertexAttribI3uivEXT_remap_index 425 -#define VertexAttribI4bvEXT_remap_index 426 -#define VertexAttribI4iEXT_remap_index 427 -#define VertexAttribI4ivEXT_remap_index 428 -#define VertexAttribI4svEXT_remap_index 429 -#define VertexAttribI4ubvEXT_remap_index 430 -#define VertexAttribI4uiEXT_remap_index 431 -#define VertexAttribI4uivEXT_remap_index 432 -#define VertexAttribI4usvEXT_remap_index 433 -#define VertexAttribIPointerEXT_remap_index 434 -#define FramebufferTextureLayerEXT_remap_index 435 -#define ColorMaskIndexedEXT_remap_index 436 -#define DisableIndexedEXT_remap_index 437 -#define EnableIndexedEXT_remap_index 438 -#define GetBooleanIndexedvEXT_remap_index 439 -#define GetIntegerIndexedvEXT_remap_index 440 -#define IsEnabledIndexedEXT_remap_index 441 -#define ClearColorIiEXT_remap_index 442 -#define ClearColorIuiEXT_remap_index 443 -#define GetTexParameterIivEXT_remap_index 444 -#define GetTexParameterIuivEXT_remap_index 445 -#define TexParameterIivEXT_remap_index 446 -#define TexParameterIuivEXT_remap_index 447 -#define BeginConditionalRenderNV_remap_index 448 -#define EndConditionalRenderNV_remap_index 449 -#define BeginTransformFeedbackEXT_remap_index 450 -#define BindBufferBaseEXT_remap_index 451 -#define BindBufferOffsetEXT_remap_index 452 -#define BindBufferRangeEXT_remap_index 453 -#define EndTransformFeedbackEXT_remap_index 454 -#define GetTransformFeedbackVaryingEXT_remap_index 455 -#define TransformFeedbackVaryingsEXT_remap_index 456 -#define ProvokingVertexEXT_remap_index 457 -#define GetTexParameterPointervAPPLE_remap_index 458 -#define TextureRangeAPPLE_remap_index 459 -#define GetObjectParameterivAPPLE_remap_index 460 -#define ObjectPurgeableAPPLE_remap_index 461 -#define ObjectUnpurgeableAPPLE_remap_index 462 -#define ActiveProgramEXT_remap_index 463 -#define CreateShaderProgramEXT_remap_index 464 -#define UseShaderProgramEXT_remap_index 465 -#define StencilFuncSeparateATI_remap_index 466 -#define ProgramEnvParameters4fvEXT_remap_index 467 -#define ProgramLocalParameters4fvEXT_remap_index 468 -#define GetQueryObjecti64vEXT_remap_index 469 -#define GetQueryObjectui64vEXT_remap_index 470 -#define EGLImageTargetRenderbufferStorageOES_remap_index 471 -#define EGLImageTargetTexture2DOES_remap_index 472 +#define VertexAttribDivisorARB_remap_index 170 +#define FlushMappedBufferRange_remap_index 171 +#define MapBufferRange_remap_index 172 +#define BindVertexArray_remap_index 173 +#define GenVertexArrays_remap_index 174 +#define CopyBufferSubData_remap_index 175 +#define ClientWaitSync_remap_index 176 +#define DeleteSync_remap_index 177 +#define FenceSync_remap_index 178 +#define GetInteger64v_remap_index 179 +#define GetSynciv_remap_index 180 +#define IsSync_remap_index 181 +#define WaitSync_remap_index 182 +#define DrawElementsBaseVertex_remap_index 183 +#define DrawRangeElementsBaseVertex_remap_index 184 +#define MultiDrawElementsBaseVertex_remap_index 185 +#define BlendEquationSeparateiARB_remap_index 186 +#define BlendEquationiARB_remap_index 187 +#define BlendFuncSeparateiARB_remap_index 188 +#define BlendFunciARB_remap_index 189 +#define BindTransformFeedback_remap_index 190 +#define DeleteTransformFeedbacks_remap_index 191 +#define DrawTransformFeedback_remap_index 192 +#define GenTransformFeedbacks_remap_index 193 +#define IsTransformFeedback_remap_index 194 +#define PauseTransformFeedback_remap_index 195 +#define ResumeTransformFeedback_remap_index 196 +#define ClearDepthf_remap_index 197 +#define DepthRangef_remap_index 198 +#define GetShaderPrecisionFormat_remap_index 199 +#define ReleaseShaderCompiler_remap_index 200 +#define ShaderBinary_remap_index 201 +#define PolygonOffsetEXT_remap_index 202 +#define GetPixelTexGenParameterfvSGIS_remap_index 203 +#define GetPixelTexGenParameterivSGIS_remap_index 204 +#define PixelTexGenParameterfSGIS_remap_index 205 +#define PixelTexGenParameterfvSGIS_remap_index 206 +#define PixelTexGenParameteriSGIS_remap_index 207 +#define PixelTexGenParameterivSGIS_remap_index 208 +#define SampleMaskSGIS_remap_index 209 +#define SamplePatternSGIS_remap_index 210 +#define ColorPointerEXT_remap_index 211 +#define EdgeFlagPointerEXT_remap_index 212 +#define IndexPointerEXT_remap_index 213 +#define NormalPointerEXT_remap_index 214 +#define TexCoordPointerEXT_remap_index 215 +#define VertexPointerEXT_remap_index 216 +#define PointParameterfEXT_remap_index 217 +#define PointParameterfvEXT_remap_index 218 +#define LockArraysEXT_remap_index 219 +#define UnlockArraysEXT_remap_index 220 +#define SecondaryColor3bEXT_remap_index 221 +#define SecondaryColor3bvEXT_remap_index 222 +#define SecondaryColor3dEXT_remap_index 223 +#define SecondaryColor3dvEXT_remap_index 224 +#define SecondaryColor3fEXT_remap_index 225 +#define SecondaryColor3fvEXT_remap_index 226 +#define SecondaryColor3iEXT_remap_index 227 +#define SecondaryColor3ivEXT_remap_index 228 +#define SecondaryColor3sEXT_remap_index 229 +#define SecondaryColor3svEXT_remap_index 230 +#define SecondaryColor3ubEXT_remap_index 231 +#define SecondaryColor3ubvEXT_remap_index 232 +#define SecondaryColor3uiEXT_remap_index 233 +#define SecondaryColor3uivEXT_remap_index 234 +#define SecondaryColor3usEXT_remap_index 235 +#define SecondaryColor3usvEXT_remap_index 236 +#define SecondaryColorPointerEXT_remap_index 237 +#define MultiDrawArraysEXT_remap_index 238 +#define MultiDrawElementsEXT_remap_index 239 +#define FogCoordPointerEXT_remap_index 240 +#define FogCoorddEXT_remap_index 241 +#define FogCoorddvEXT_remap_index 242 +#define FogCoordfEXT_remap_index 243 +#define FogCoordfvEXT_remap_index 244 +#define PixelTexGenSGIX_remap_index 245 +#define BlendFuncSeparateEXT_remap_index 246 +#define FlushVertexArrayRangeNV_remap_index 247 +#define VertexArrayRangeNV_remap_index 248 +#define CombinerInputNV_remap_index 249 +#define CombinerOutputNV_remap_index 250 +#define CombinerParameterfNV_remap_index 251 +#define CombinerParameterfvNV_remap_index 252 +#define CombinerParameteriNV_remap_index 253 +#define CombinerParameterivNV_remap_index 254 +#define FinalCombinerInputNV_remap_index 255 +#define GetCombinerInputParameterfvNV_remap_index 256 +#define GetCombinerInputParameterivNV_remap_index 257 +#define GetCombinerOutputParameterfvNV_remap_index 258 +#define GetCombinerOutputParameterivNV_remap_index 259 +#define GetFinalCombinerInputParameterfvNV_remap_index 260 +#define GetFinalCombinerInputParameterivNV_remap_index 261 +#define ResizeBuffersMESA_remap_index 262 +#define WindowPos2dMESA_remap_index 263 +#define WindowPos2dvMESA_remap_index 264 +#define WindowPos2fMESA_remap_index 265 +#define WindowPos2fvMESA_remap_index 266 +#define WindowPos2iMESA_remap_index 267 +#define WindowPos2ivMESA_remap_index 268 +#define WindowPos2sMESA_remap_index 269 +#define WindowPos2svMESA_remap_index 270 +#define WindowPos3dMESA_remap_index 271 +#define WindowPos3dvMESA_remap_index 272 +#define WindowPos3fMESA_remap_index 273 +#define WindowPos3fvMESA_remap_index 274 +#define WindowPos3iMESA_remap_index 275 +#define WindowPos3ivMESA_remap_index 276 +#define WindowPos3sMESA_remap_index 277 +#define WindowPos3svMESA_remap_index 278 +#define WindowPos4dMESA_remap_index 279 +#define WindowPos4dvMESA_remap_index 280 +#define WindowPos4fMESA_remap_index 281 +#define WindowPos4fvMESA_remap_index 282 +#define WindowPos4iMESA_remap_index 283 +#define WindowPos4ivMESA_remap_index 284 +#define WindowPos4sMESA_remap_index 285 +#define WindowPos4svMESA_remap_index 286 +#define MultiModeDrawArraysIBM_remap_index 287 +#define MultiModeDrawElementsIBM_remap_index 288 +#define DeleteFencesNV_remap_index 289 +#define FinishFenceNV_remap_index 290 +#define GenFencesNV_remap_index 291 +#define GetFenceivNV_remap_index 292 +#define IsFenceNV_remap_index 293 +#define SetFenceNV_remap_index 294 +#define TestFenceNV_remap_index 295 +#define AreProgramsResidentNV_remap_index 296 +#define BindProgramNV_remap_index 297 +#define DeleteProgramsNV_remap_index 298 +#define ExecuteProgramNV_remap_index 299 +#define GenProgramsNV_remap_index 300 +#define GetProgramParameterdvNV_remap_index 301 +#define GetProgramParameterfvNV_remap_index 302 +#define GetProgramStringNV_remap_index 303 +#define GetProgramivNV_remap_index 304 +#define GetTrackMatrixivNV_remap_index 305 +#define GetVertexAttribPointervNV_remap_index 306 +#define GetVertexAttribdvNV_remap_index 307 +#define GetVertexAttribfvNV_remap_index 308 +#define GetVertexAttribivNV_remap_index 309 +#define IsProgramNV_remap_index 310 +#define LoadProgramNV_remap_index 311 +#define ProgramParameters4dvNV_remap_index 312 +#define ProgramParameters4fvNV_remap_index 313 +#define RequestResidentProgramsNV_remap_index 314 +#define TrackMatrixNV_remap_index 315 +#define VertexAttrib1dNV_remap_index 316 +#define VertexAttrib1dvNV_remap_index 317 +#define VertexAttrib1fNV_remap_index 318 +#define VertexAttrib1fvNV_remap_index 319 +#define VertexAttrib1sNV_remap_index 320 +#define VertexAttrib1svNV_remap_index 321 +#define VertexAttrib2dNV_remap_index 322 +#define VertexAttrib2dvNV_remap_index 323 +#define VertexAttrib2fNV_remap_index 324 +#define VertexAttrib2fvNV_remap_index 325 +#define VertexAttrib2sNV_remap_index 326 +#define VertexAttrib2svNV_remap_index 327 +#define VertexAttrib3dNV_remap_index 328 +#define VertexAttrib3dvNV_remap_index 329 +#define VertexAttrib3fNV_remap_index 330 +#define VertexAttrib3fvNV_remap_index 331 +#define VertexAttrib3sNV_remap_index 332 +#define VertexAttrib3svNV_remap_index 333 +#define VertexAttrib4dNV_remap_index 334 +#define VertexAttrib4dvNV_remap_index 335 +#define VertexAttrib4fNV_remap_index 336 +#define VertexAttrib4fvNV_remap_index 337 +#define VertexAttrib4sNV_remap_index 338 +#define VertexAttrib4svNV_remap_index 339 +#define VertexAttrib4ubNV_remap_index 340 +#define VertexAttrib4ubvNV_remap_index 341 +#define VertexAttribPointerNV_remap_index 342 +#define VertexAttribs1dvNV_remap_index 343 +#define VertexAttribs1fvNV_remap_index 344 +#define VertexAttribs1svNV_remap_index 345 +#define VertexAttribs2dvNV_remap_index 346 +#define VertexAttribs2fvNV_remap_index 347 +#define VertexAttribs2svNV_remap_index 348 +#define VertexAttribs3dvNV_remap_index 349 +#define VertexAttribs3fvNV_remap_index 350 +#define VertexAttribs3svNV_remap_index 351 +#define VertexAttribs4dvNV_remap_index 352 +#define VertexAttribs4fvNV_remap_index 353 +#define VertexAttribs4svNV_remap_index 354 +#define VertexAttribs4ubvNV_remap_index 355 +#define GetTexBumpParameterfvATI_remap_index 356 +#define GetTexBumpParameterivATI_remap_index 357 +#define TexBumpParameterfvATI_remap_index 358 +#define TexBumpParameterivATI_remap_index 359 +#define AlphaFragmentOp1ATI_remap_index 360 +#define AlphaFragmentOp2ATI_remap_index 361 +#define AlphaFragmentOp3ATI_remap_index 362 +#define BeginFragmentShaderATI_remap_index 363 +#define BindFragmentShaderATI_remap_index 364 +#define ColorFragmentOp1ATI_remap_index 365 +#define ColorFragmentOp2ATI_remap_index 366 +#define ColorFragmentOp3ATI_remap_index 367 +#define DeleteFragmentShaderATI_remap_index 368 +#define EndFragmentShaderATI_remap_index 369 +#define GenFragmentShadersATI_remap_index 370 +#define PassTexCoordATI_remap_index 371 +#define SampleMapATI_remap_index 372 +#define SetFragmentShaderConstantATI_remap_index 373 +#define PointParameteriNV_remap_index 374 +#define PointParameterivNV_remap_index 375 +#define ActiveStencilFaceEXT_remap_index 376 +#define BindVertexArrayAPPLE_remap_index 377 +#define DeleteVertexArraysAPPLE_remap_index 378 +#define GenVertexArraysAPPLE_remap_index 379 +#define IsVertexArrayAPPLE_remap_index 380 +#define GetProgramNamedParameterdvNV_remap_index 381 +#define GetProgramNamedParameterfvNV_remap_index 382 +#define ProgramNamedParameter4dNV_remap_index 383 +#define ProgramNamedParameter4dvNV_remap_index 384 +#define ProgramNamedParameter4fNV_remap_index 385 +#define ProgramNamedParameter4fvNV_remap_index 386 +#define PrimitiveRestartIndexNV_remap_index 387 +#define PrimitiveRestartNV_remap_index 388 +#define DepthBoundsEXT_remap_index 389 +#define BlendEquationSeparateEXT_remap_index 390 +#define BindFramebufferEXT_remap_index 391 +#define BindRenderbufferEXT_remap_index 392 +#define CheckFramebufferStatusEXT_remap_index 393 +#define DeleteFramebuffersEXT_remap_index 394 +#define DeleteRenderbuffersEXT_remap_index 395 +#define FramebufferRenderbufferEXT_remap_index 396 +#define FramebufferTexture1DEXT_remap_index 397 +#define FramebufferTexture2DEXT_remap_index 398 +#define FramebufferTexture3DEXT_remap_index 399 +#define GenFramebuffersEXT_remap_index 400 +#define GenRenderbuffersEXT_remap_index 401 +#define GenerateMipmapEXT_remap_index 402 +#define GetFramebufferAttachmentParameterivEXT_remap_index 403 +#define GetRenderbufferParameterivEXT_remap_index 404 +#define IsFramebufferEXT_remap_index 405 +#define IsRenderbufferEXT_remap_index 406 +#define RenderbufferStorageEXT_remap_index 407 +#define BlitFramebufferEXT_remap_index 408 +#define BufferParameteriAPPLE_remap_index 409 +#define FlushMappedBufferRangeAPPLE_remap_index 410 +#define BindFragDataLocationEXT_remap_index 411 +#define GetFragDataLocationEXT_remap_index 412 +#define GetUniformuivEXT_remap_index 413 +#define GetVertexAttribIivEXT_remap_index 414 +#define GetVertexAttribIuivEXT_remap_index 415 +#define Uniform1uiEXT_remap_index 416 +#define Uniform1uivEXT_remap_index 417 +#define Uniform2uiEXT_remap_index 418 +#define Uniform2uivEXT_remap_index 419 +#define Uniform3uiEXT_remap_index 420 +#define Uniform3uivEXT_remap_index 421 +#define Uniform4uiEXT_remap_index 422 +#define Uniform4uivEXT_remap_index 423 +#define VertexAttribI1iEXT_remap_index 424 +#define VertexAttribI1ivEXT_remap_index 425 +#define VertexAttribI1uiEXT_remap_index 426 +#define VertexAttribI1uivEXT_remap_index 427 +#define VertexAttribI2iEXT_remap_index 428 +#define VertexAttribI2ivEXT_remap_index 429 +#define VertexAttribI2uiEXT_remap_index 430 +#define VertexAttribI2uivEXT_remap_index 431 +#define VertexAttribI3iEXT_remap_index 432 +#define VertexAttribI3ivEXT_remap_index 433 +#define VertexAttribI3uiEXT_remap_index 434 +#define VertexAttribI3uivEXT_remap_index 435 +#define VertexAttribI4bvEXT_remap_index 436 +#define VertexAttribI4iEXT_remap_index 437 +#define VertexAttribI4ivEXT_remap_index 438 +#define VertexAttribI4svEXT_remap_index 439 +#define VertexAttribI4ubvEXT_remap_index 440 +#define VertexAttribI4uiEXT_remap_index 441 +#define VertexAttribI4uivEXT_remap_index 442 +#define VertexAttribI4usvEXT_remap_index 443 +#define VertexAttribIPointerEXT_remap_index 444 +#define FramebufferTextureLayerEXT_remap_index 445 +#define ColorMaskIndexedEXT_remap_index 446 +#define DisableIndexedEXT_remap_index 447 +#define EnableIndexedEXT_remap_index 448 +#define GetBooleanIndexedvEXT_remap_index 449 +#define GetIntegerIndexedvEXT_remap_index 450 +#define IsEnabledIndexedEXT_remap_index 451 +#define ClearColorIiEXT_remap_index 452 +#define ClearColorIuiEXT_remap_index 453 +#define GetTexParameterIivEXT_remap_index 454 +#define GetTexParameterIuivEXT_remap_index 455 +#define TexParameterIivEXT_remap_index 456 +#define TexParameterIuivEXT_remap_index 457 +#define BeginConditionalRenderNV_remap_index 458 +#define EndConditionalRenderNV_remap_index 459 +#define BeginTransformFeedbackEXT_remap_index 460 +#define BindBufferBaseEXT_remap_index 461 +#define BindBufferOffsetEXT_remap_index 462 +#define BindBufferRangeEXT_remap_index 463 +#define EndTransformFeedbackEXT_remap_index 464 +#define GetTransformFeedbackVaryingEXT_remap_index 465 +#define TransformFeedbackVaryingsEXT_remap_index 466 +#define ProvokingVertexEXT_remap_index 467 +#define GetTexParameterPointervAPPLE_remap_index 468 +#define TextureRangeAPPLE_remap_index 469 +#define GetObjectParameterivAPPLE_remap_index 470 +#define ObjectPurgeableAPPLE_remap_index 471 +#define ObjectUnpurgeableAPPLE_remap_index 472 +#define ActiveProgramEXT_remap_index 473 +#define CreateShaderProgramEXT_remap_index 474 +#define UseShaderProgramEXT_remap_index 475 +#define TextureBarrierNV_remap_index 476 +#define StencilFuncSeparateATI_remap_index 477 +#define ProgramEnvParameters4fvEXT_remap_index 478 +#define ProgramLocalParameters4fvEXT_remap_index 479 +#define GetQueryObjecti64vEXT_remap_index 480 +#define GetQueryObjectui64vEXT_remap_index 481 +#define EGLImageTargetRenderbufferStorageOES_remap_index 482 +#define EGLImageTargetTexture2DOES_remap_index 483 #define _gloffset_AttachShader driDispatchRemapTable[AttachShader_remap_index] #define _gloffset_CreateProgram driDispatchRemapTable[CreateProgram_remap_index] @@ -1595,6 +1617,7 @@ extern int driDispatchRemapTable[ driDispatchRemapTable_size ]; #define _gloffset_FramebufferTextureARB driDispatchRemapTable[FramebufferTextureARB_remap_index] #define _gloffset_FramebufferTextureFaceARB driDispatchRemapTable[FramebufferTextureFaceARB_remap_index] #define _gloffset_ProgramParameteriARB driDispatchRemapTable[ProgramParameteriARB_remap_index] +#define _gloffset_VertexAttribDivisorARB driDispatchRemapTable[VertexAttribDivisorARB_remap_index] #define _gloffset_FlushMappedBufferRange driDispatchRemapTable[FlushMappedBufferRange_remap_index] #define _gloffset_MapBufferRange driDispatchRemapTable[MapBufferRange_remap_index] #define _gloffset_BindVertexArray driDispatchRemapTable[BindVertexArray_remap_index] @@ -1610,6 +1633,10 @@ extern int driDispatchRemapTable[ driDispatchRemapTable_size ]; #define _gloffset_DrawElementsBaseVertex driDispatchRemapTable[DrawElementsBaseVertex_remap_index] #define _gloffset_DrawRangeElementsBaseVertex driDispatchRemapTable[DrawRangeElementsBaseVertex_remap_index] #define _gloffset_MultiDrawElementsBaseVertex driDispatchRemapTable[MultiDrawElementsBaseVertex_remap_index] +#define _gloffset_BlendEquationSeparateiARB driDispatchRemapTable[BlendEquationSeparateiARB_remap_index] +#define _gloffset_BlendEquationiARB driDispatchRemapTable[BlendEquationiARB_remap_index] +#define _gloffset_BlendFuncSeparateiARB driDispatchRemapTable[BlendFuncSeparateiARB_remap_index] +#define _gloffset_BlendFunciARB driDispatchRemapTable[BlendFunciARB_remap_index] #define _gloffset_BindTransformFeedback driDispatchRemapTable[BindTransformFeedback_remap_index] #define _gloffset_DeleteTransformFeedbacks driDispatchRemapTable[DeleteTransformFeedbacks_remap_index] #define _gloffset_DrawTransformFeedback driDispatchRemapTable[DrawTransformFeedback_remap_index] @@ -1617,6 +1644,11 @@ extern int driDispatchRemapTable[ driDispatchRemapTable_size ]; #define _gloffset_IsTransformFeedback driDispatchRemapTable[IsTransformFeedback_remap_index] #define _gloffset_PauseTransformFeedback driDispatchRemapTable[PauseTransformFeedback_remap_index] #define _gloffset_ResumeTransformFeedback driDispatchRemapTable[ResumeTransformFeedback_remap_index] +#define _gloffset_ClearDepthf driDispatchRemapTable[ClearDepthf_remap_index] +#define _gloffset_DepthRangef driDispatchRemapTable[DepthRangef_remap_index] +#define _gloffset_GetShaderPrecisionFormat driDispatchRemapTable[GetShaderPrecisionFormat_remap_index] +#define _gloffset_ReleaseShaderCompiler driDispatchRemapTable[ReleaseShaderCompiler_remap_index] +#define _gloffset_ShaderBinary driDispatchRemapTable[ShaderBinary_remap_index] #define _gloffset_PolygonOffsetEXT driDispatchRemapTable[PolygonOffsetEXT_remap_index] #define _gloffset_GetPixelTexGenParameterfvSGIS driDispatchRemapTable[GetPixelTexGenParameterfvSGIS_remap_index] #define _gloffset_GetPixelTexGenParameterivSGIS driDispatchRemapTable[GetPixelTexGenParameterivSGIS_remap_index] @@ -1891,6 +1923,7 @@ extern int driDispatchRemapTable[ driDispatchRemapTable_size ]; #define _gloffset_ActiveProgramEXT driDispatchRemapTable[ActiveProgramEXT_remap_index] #define _gloffset_CreateShaderProgramEXT driDispatchRemapTable[CreateShaderProgramEXT_remap_index] #define _gloffset_UseShaderProgramEXT driDispatchRemapTable[UseShaderProgramEXT_remap_index] +#define _gloffset_TextureBarrierNV driDispatchRemapTable[TextureBarrierNV_remap_index] #define _gloffset_StencilFuncSeparateATI driDispatchRemapTable[StencilFuncSeparateATI_remap_index] #define _gloffset_ProgramEnvParameters4fvEXT driDispatchRemapTable[ProgramEnvParameters4fvEXT_remap_index] #define _gloffset_ProgramLocalParameters4fvEXT driDispatchRemapTable[ProgramLocalParameters4fvEXT_remap_index] @@ -3635,6 +3668,9 @@ extern int driDispatchRemapTable[ driDispatchRemapTable_size ]; #define CALL_ProgramParameteriARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLuint, GLenum, GLint)), _gloffset_ProgramParameteriARB, parameters) #define GET_ProgramParameteriARB(disp) GET_by_offset(disp, _gloffset_ProgramParameteriARB) #define SET_ProgramParameteriARB(disp, fn) SET_by_offset(disp, _gloffset_ProgramParameteriARB, fn) +#define CALL_VertexAttribDivisorARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLuint, GLuint)), _gloffset_VertexAttribDivisorARB, parameters) +#define GET_VertexAttribDivisorARB(disp) GET_by_offset(disp, _gloffset_VertexAttribDivisorARB) +#define SET_VertexAttribDivisorARB(disp, fn) SET_by_offset(disp, _gloffset_VertexAttribDivisorARB, fn) #define CALL_FlushMappedBufferRange(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLenum, GLintptr, GLsizeiptr)), _gloffset_FlushMappedBufferRange, parameters) #define GET_FlushMappedBufferRange(disp) GET_by_offset(disp, _gloffset_FlushMappedBufferRange) #define SET_FlushMappedBufferRange(disp, fn) SET_by_offset(disp, _gloffset_FlushMappedBufferRange, fn) @@ -3680,6 +3716,18 @@ extern int driDispatchRemapTable[ driDispatchRemapTable_size ]; #define CALL_MultiDrawElementsBaseVertex(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLenum, const GLsizei *, GLenum, const GLvoid **, GLsizei, const GLint *)), _gloffset_MultiDrawElementsBaseVertex, parameters) #define GET_MultiDrawElementsBaseVertex(disp) GET_by_offset(disp, _gloffset_MultiDrawElementsBaseVertex) #define SET_MultiDrawElementsBaseVertex(disp, fn) SET_by_offset(disp, _gloffset_MultiDrawElementsBaseVertex, fn) +#define CALL_BlendEquationSeparateiARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLuint, GLenum, GLenum)), _gloffset_BlendEquationSeparateiARB, parameters) +#define GET_BlendEquationSeparateiARB(disp) GET_by_offset(disp, _gloffset_BlendEquationSeparateiARB) +#define SET_BlendEquationSeparateiARB(disp, fn) SET_by_offset(disp, _gloffset_BlendEquationSeparateiARB, fn) +#define CALL_BlendEquationiARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLuint, GLenum)), _gloffset_BlendEquationiARB, parameters) +#define GET_BlendEquationiARB(disp) GET_by_offset(disp, _gloffset_BlendEquationiARB) +#define SET_BlendEquationiARB(disp, fn) SET_by_offset(disp, _gloffset_BlendEquationiARB, fn) +#define CALL_BlendFuncSeparateiARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLuint, GLenum, GLenum, GLenum, GLenum)), _gloffset_BlendFuncSeparateiARB, parameters) +#define GET_BlendFuncSeparateiARB(disp) GET_by_offset(disp, _gloffset_BlendFuncSeparateiARB) +#define SET_BlendFuncSeparateiARB(disp, fn) SET_by_offset(disp, _gloffset_BlendFuncSeparateiARB, fn) +#define CALL_BlendFunciARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLuint, GLenum, GLenum)), _gloffset_BlendFunciARB, parameters) +#define GET_BlendFunciARB(disp) GET_by_offset(disp, _gloffset_BlendFunciARB) +#define SET_BlendFunciARB(disp, fn) SET_by_offset(disp, _gloffset_BlendFunciARB, fn) #define CALL_BindTransformFeedback(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLenum, GLuint)), _gloffset_BindTransformFeedback, parameters) #define GET_BindTransformFeedback(disp) GET_by_offset(disp, _gloffset_BindTransformFeedback) #define SET_BindTransformFeedback(disp, fn) SET_by_offset(disp, _gloffset_BindTransformFeedback, fn) @@ -3701,6 +3749,21 @@ extern int driDispatchRemapTable[ driDispatchRemapTable_size ]; #define CALL_ResumeTransformFeedback(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(void)), _gloffset_ResumeTransformFeedback, parameters) #define GET_ResumeTransformFeedback(disp) GET_by_offset(disp, _gloffset_ResumeTransformFeedback) #define SET_ResumeTransformFeedback(disp, fn) SET_by_offset(disp, _gloffset_ResumeTransformFeedback, fn) +#define CALL_ClearDepthf(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLclampf)), _gloffset_ClearDepthf, parameters) +#define GET_ClearDepthf(disp) GET_by_offset(disp, _gloffset_ClearDepthf) +#define SET_ClearDepthf(disp, fn) SET_by_offset(disp, _gloffset_ClearDepthf, fn) +#define CALL_DepthRangef(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLclampf, GLclampf)), _gloffset_DepthRangef, parameters) +#define GET_DepthRangef(disp) GET_by_offset(disp, _gloffset_DepthRangef) +#define SET_DepthRangef(disp, fn) SET_by_offset(disp, _gloffset_DepthRangef, fn) +#define CALL_GetShaderPrecisionFormat(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLenum, GLenum, GLint *, GLint *)), _gloffset_GetShaderPrecisionFormat, parameters) +#define GET_GetShaderPrecisionFormat(disp) GET_by_offset(disp, _gloffset_GetShaderPrecisionFormat) +#define SET_GetShaderPrecisionFormat(disp, fn) SET_by_offset(disp, _gloffset_GetShaderPrecisionFormat, fn) +#define CALL_ReleaseShaderCompiler(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(void)), _gloffset_ReleaseShaderCompiler, parameters) +#define GET_ReleaseShaderCompiler(disp) GET_by_offset(disp, _gloffset_ReleaseShaderCompiler) +#define SET_ReleaseShaderCompiler(disp, fn) SET_by_offset(disp, _gloffset_ReleaseShaderCompiler, fn) +#define CALL_ShaderBinary(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLsizei, const GLuint *, GLenum, const GLvoid *, GLsizei)), _gloffset_ShaderBinary, parameters) +#define GET_ShaderBinary(disp) GET_by_offset(disp, _gloffset_ShaderBinary) +#define SET_ShaderBinary(disp, fn) SET_by_offset(disp, _gloffset_ShaderBinary, fn) #define CALL_PolygonOffsetEXT(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLfloat, GLfloat)), _gloffset_PolygonOffsetEXT, parameters) #define GET_PolygonOffsetEXT(disp) GET_by_offset(disp, _gloffset_PolygonOffsetEXT) #define SET_PolygonOffsetEXT(disp, fn) SET_by_offset(disp, _gloffset_PolygonOffsetEXT, fn) @@ -4523,6 +4586,9 @@ extern int driDispatchRemapTable[ driDispatchRemapTable_size ]; #define CALL_UseShaderProgramEXT(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLenum, GLuint)), _gloffset_UseShaderProgramEXT, parameters) #define GET_UseShaderProgramEXT(disp) GET_by_offset(disp, _gloffset_UseShaderProgramEXT) #define SET_UseShaderProgramEXT(disp, fn) SET_by_offset(disp, _gloffset_UseShaderProgramEXT, fn) +#define CALL_TextureBarrierNV(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(void)), _gloffset_TextureBarrierNV, parameters) +#define GET_TextureBarrierNV(disp) GET_by_offset(disp, _gloffset_TextureBarrierNV) +#define SET_TextureBarrierNV(disp, fn) SET_by_offset(disp, _gloffset_TextureBarrierNV, fn) #define CALL_StencilFuncSeparateATI(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLenum, GLenum, GLint, GLuint)), _gloffset_StencilFuncSeparateATI, parameters) #define GET_StencilFuncSeparateATI(disp) GET_by_offset(disp, _gloffset_StencilFuncSeparateATI) #define SET_StencilFuncSeparateATI(disp, fn) SET_by_offset(disp, _gloffset_StencilFuncSeparateATI, fn) diff --git a/src/mesa/main/glheader.h b/src/mesa/main/glheader.h index 08ad5f3201..0df8119866 100644 --- a/src/mesa/main/glheader.h +++ b/src/mesa/main/glheader.h @@ -121,6 +121,10 @@ typedef void *GLeglImageOES; #define GL_MAX_FRAGMENT_UNIFORM_VECTORS 0x8DFD #endif +#ifndef GL_ATI_texture_compression_3dc +#define GL_ATI_texture_compression_3dc 1 +#define GL_COMPRESSED_LUMINANCE_ALPHA_3DC_ATI 0x8837 +#endif /** diff --git a/src/mesa/main/hint.c b/src/mesa/main/hint.c index 878f10d4a4..ff8d88fffe 100644 --- a/src/mesa/main/hint.c +++ b/src/mesa/main/hint.c @@ -29,6 +29,7 @@ #include "context.h" #include "hint.h" #include "imports.h" +#include "mtypes.h" @@ -39,8 +40,9 @@ _mesa_Hint( GLenum target, GLenum mode ) ASSERT_OUTSIDE_BEGIN_END(ctx); if (MESA_VERBOSE & VERBOSE_API) - _mesa_debug(ctx, "glHint %s %d\n", - _mesa_lookup_enum_by_nr(target), mode); + _mesa_debug(ctx, "glHint %s %s\n", + _mesa_lookup_enum_by_nr(target), + _mesa_lookup_enum_by_nr(mode)); if (mode != GL_NICEST && mode != GL_FASTEST && mode != GL_DONT_CARE) { _mesa_error(ctx, GL_INVALID_ENUM, "glHint(mode)"); diff --git a/src/mesa/main/histogram.c b/src/mesa/main/histogram.c index b98e3219c5..75bb925941 100644 --- a/src/mesa/main/histogram.c +++ b/src/mesa/main/histogram.c @@ -28,6 +28,7 @@ #include "colormac.h" #include "histogram.h" #include "macros.h" +#include "mfeatures.h" #include "main/dispatch.h" diff --git a/src/mesa/main/image.c b/src/mesa/main/image.c index f9f2ed7307..bbde3800e8 100644 --- a/src/mesa/main/image.c +++ b/src/mesa/main/image.c @@ -35,6 +35,8 @@ #include "image.h" #include "imports.h" #include "macros.h" +#include "mfeatures.h" +#include "mtypes.h" /** @@ -66,6 +68,7 @@ _mesa_type_is_packed(GLenum type) switch (type) { case GL_UNSIGNED_BYTE_3_3_2: case GL_UNSIGNED_BYTE_2_3_3_REV: + case MESA_UNSIGNED_BYTE_4_4: case GL_UNSIGNED_SHORT_5_6_5: case GL_UNSIGNED_SHORT_5_6_5_REV: case GL_UNSIGNED_SHORT_4_4_4_4: @@ -192,6 +195,8 @@ _mesa_sizeof_packed_type( GLenum type ) return sizeof(GLubyte); case GL_UNSIGNED_BYTE_2_3_3_REV: return sizeof(GLubyte); + case MESA_UNSIGNED_BYTE_4_4: + return sizeof(GLubyte); case GL_UNSIGNED_SHORT_5_6_5: return sizeof(GLushort); case GL_UNSIGNED_SHORT_5_6_5_REV: @@ -738,6 +743,11 @@ _mesa_is_color_format(GLenum format) case GL_COMPRESSED_SIGNED_RED_RGTC1: case GL_COMPRESSED_RG_RGTC2: case GL_COMPRESSED_SIGNED_RG_RGTC2: + case GL_COMPRESSED_LUMINANCE_LATC1_EXT: + case GL_COMPRESSED_SIGNED_LUMINANCE_LATC1_EXT: + case GL_COMPRESSED_LUMINANCE_ALPHA_LATC2_EXT: + case GL_COMPRESSED_SIGNED_LUMINANCE_ALPHA_LATC2_EXT: + case GL_COMPRESSED_LUMINANCE_ALPHA_3DC_ATI: /* signed, normalized texture formats */ case GL_RGBA_SNORM: case GL_RGBA8_SNORM: @@ -1020,6 +1030,13 @@ _mesa_is_compressed_format(struct gl_context *ctx, GLenum format) case GL_COMPRESSED_RG_RGTC2: case GL_COMPRESSED_SIGNED_RG_RGTC2: return ctx->Extensions.ARB_texture_compression_rgtc; + case GL_COMPRESSED_LUMINANCE_LATC1_EXT: + case GL_COMPRESSED_SIGNED_LUMINANCE_LATC1_EXT: + case GL_COMPRESSED_LUMINANCE_ALPHA_LATC2_EXT: + case GL_COMPRESSED_SIGNED_LUMINANCE_ALPHA_LATC2_EXT: + return ctx->Extensions.EXT_texture_compression_latc; + case GL_COMPRESSED_LUMINANCE_ALPHA_3DC_ATI: + return ctx->Extensions.ATI_texture_compression_3dc; default: return GL_FALSE; } @@ -1579,8 +1596,8 @@ _mesa_clip_drawpixels(const struct gl_context *ctx, * scissor box is ignored, and we use the bounds of the current readbuffer * surface. * - * \return GL_TRUE if image is ready for drawing or - * GL_FALSE if image was completely clipped away (draw nothing) + * \return GL_TRUE if region to read is in bounds + * GL_FALSE if region is completely out of bounds (nothing to read) */ GLboolean _mesa_clip_readpixels(const struct gl_context *ctx, diff --git a/src/mesa/main/imports.c b/src/mesa/main/imports.c index d662e055b2..2ff21fa2eb 100644 --- a/src/mesa/main/imports.c +++ b/src/mesa/main/imports.c @@ -46,6 +46,7 @@ #include "imports.h" #include "context.h" +#include "mtypes.h" #include "version.h" #ifdef _GNU_SOURCE @@ -452,6 +453,7 @@ _mesa_inv_sqrtf(float n) #endif } +#ifndef __GNUC__ /** * Find the first bit set in a word. */ @@ -495,9 +497,6 @@ _mesa_ffs(int32_t i) int _mesa_ffsll(int64_t val) { -#ifdef ffsll - return ffsll(val); -#else int bit; assert(sizeof(val) == 8); @@ -511,27 +510,24 @@ _mesa_ffsll(int64_t val) return 32 + bit; return 0; -#endif } +#if ((_GNUC__ == 3 && __GNUC_MINOR__ < 4) || __GNUC__ < 4) /** * Return number of bits set in given GLuint. */ unsigned int _mesa_bitcount(unsigned int n) { -#if defined(__GNUC__) && \ - ((_GNUC__ == 3 && __GNUC_MINOR__ >= 4) || __GNUC__ >= 4) - return __builtin_popcount(n); -#else unsigned int bits; for (bits = 0; n > 0; n = n >> 1) { bits += (n & 1); } return bits; -#endif } +#endif +#endif /** @@ -941,7 +937,7 @@ _mesa_problem( const struct gl_context *ctx, const char *fmtString, ... ) va_end( args ); fprintf(stderr, "Mesa %s implementation error: %s\n", MESA_VERSION_STRING, str); - fprintf(stderr, "Please report at bugzilla.freedesktop.org\n"); + fprintf(stderr, "Please report at bugs.freedesktop.org\n"); } diff --git a/src/mesa/main/imports.h b/src/mesa/main/imports.h index c0686efed2..7c990a4768 100644 --- a/src/mesa/main/imports.h +++ b/src/mesa/main/imports.h @@ -546,6 +546,24 @@ _mesa_inv_sqrtf(float x); extern void _mesa_init_sqrt_table(void); +#ifdef __GNUC__ + +#ifdef __MINGW32__ +#define ffs __builtin_ffs +#define ffsll __builtin_ffsll +#endif + +#define _mesa_ffs(i) ffs(i) +#define _mesa_ffsll(i) ffsll(i) + +#if ((_GNUC__ == 3 && __GNUC_MINOR__ >= 4) || __GNUC__ >= 4) +#define _mesa_bitcount(i) __builtin_popcount(i) +#else +extern unsigned int +_mesa_bitcount(unsigned int n); +#endif + +#else extern int _mesa_ffs(int32_t i); @@ -554,6 +572,7 @@ _mesa_ffsll(int64_t i); extern unsigned int _mesa_bitcount(unsigned int n); +#endif extern GLhalfARB _mesa_float_to_half(float f); diff --git a/src/mesa/main/lines.c b/src/mesa/main/lines.c index 81e179a925..79bf5679d8 100644 --- a/src/mesa/main/lines.c +++ b/src/mesa/main/lines.c @@ -43,6 +43,9 @@ _mesa_LineWidth( GLfloat width ) GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glLineWidth %f\n", width); + if (width<=0.0) { _mesa_error( ctx, GL_INVALID_VALUE, "glLineWidth" ); return; @@ -77,6 +80,9 @@ _mesa_LineStipple( GLint factor, GLushort pattern ) GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glLineStipple %d %u\n", factor, pattern); + factor = CLAMP( factor, 1, 256 ); if (ctx->Line.StippleFactor == factor && diff --git a/src/mesa/main/matrix.c b/src/mesa/main/matrix.c index 105d4a327f..76c7e1c9d1 100644 --- a/src/mesa/main/matrix.c +++ b/src/mesa/main/matrix.c @@ -40,6 +40,7 @@ #include "context.h" #include "enums.h" #include "macros.h" +#include "mfeatures.h" #include "matrix.h" #include "mtypes.h" #include "math/m_matrix.h" diff --git a/src/mesa/main/mipmap.c b/src/mesa/main/mipmap.c index ad63b178df..e594160ad9 100644 --- a/src/mesa/main/mipmap.c +++ b/src/mesa/main/mipmap.c @@ -30,6 +30,7 @@ #include "imports.h" #include "formats.h" #include "mipmap.h" +#include "mtypes.h" #include "teximage.h" #include "texstore.h" #include "image.h" @@ -611,6 +612,28 @@ do_row(GLenum datatype, GLuint comps, GLint srcWidth, dst[i] = (blue << 5) | (green << 2) | red; } } + + else if (datatype == MESA_UNSIGNED_BYTE_4_4 && comps == 2) { + GLuint i, j, k; + const GLubyte *rowA = (const GLubyte *) srcRowA; + const GLubyte *rowB = (const GLubyte *) srcRowB; + GLubyte *dst = (GLubyte *) dstRow; + for (i = j = 0, k = k0; i < (GLuint) dstWidth; + i++, j += colStride, k += colStride) { + const GLint rowAr0 = rowA[j] & 0xf; + const GLint rowAr1 = rowA[k] & 0xf; + const GLint rowBr0 = rowB[j] & 0xf; + const GLint rowBr1 = rowB[k] & 0xf; + const GLint rowAg0 = (rowA[j] >> 4) & 0xf; + const GLint rowAg1 = (rowA[k] >> 4) & 0xf; + const GLint rowBg0 = (rowB[j] >> 4) & 0xf; + const GLint rowBg1 = (rowB[k] >> 4) & 0xf; + const GLint r = (rowAr0 + rowAr1 + rowBr0 + rowBr1) >> 2; + const GLint g = (rowAg0 + rowAg1 + rowBg0 + rowBg1) >> 2; + dst[i] = (g << 4) | r; + } + } + else { _mesa_problem(NULL, "bad format in do_row()"); } @@ -1077,7 +1100,7 @@ do_row_3D(GLenum datatype, GLuint comps, GLint srcWidth, } } else if ((datatype == GL_UNSIGNED_BYTE_3_3_2) && (comps == 3)) { - DECLARE_ROW_POINTERS0(GLushort); + DECLARE_ROW_POINTERS0(GLubyte); for (i = j = 0, k = k0; i < (GLuint) dstWidth; i++, j += colStride, k += colStride) { @@ -1114,6 +1137,34 @@ do_row_3D(GLenum datatype, GLuint comps, GLint srcWidth, dst[i] = (b << 5) | (g << 2) | r; } } + else if (datatype == MESA_UNSIGNED_BYTE_4_4 && comps == 2) { + DECLARE_ROW_POINTERS0(GLubyte); + + for (i = j = 0, k = k0; i < (GLuint) dstWidth; + i++, j += colStride, k += colStride) { + const GLint rowAr0 = rowA[j] & 0xf; + const GLint rowAr1 = rowA[k] & 0xf; + const GLint rowBr0 = rowB[j] & 0xf; + const GLint rowBr1 = rowB[k] & 0xf; + const GLint rowCr0 = rowC[j] & 0xf; + const GLint rowCr1 = rowC[k] & 0xf; + const GLint rowDr0 = rowD[j] & 0xf; + const GLint rowDr1 = rowD[k] & 0xf; + const GLint rowAg0 = (rowA[j] >> 4) & 0xf; + const GLint rowAg1 = (rowA[k] >> 4) & 0xf; + const GLint rowBg0 = (rowB[j] >> 4) & 0xf; + const GLint rowBg1 = (rowB[k] >> 4) & 0xf; + const GLint rowCg0 = (rowC[j] >> 4) & 0xf; + const GLint rowCg1 = (rowC[k] >> 4) & 0xf; + const GLint rowDg0 = (rowD[j] >> 4) & 0xf; + const GLint rowDg1 = (rowD[k] >> 4) & 0xf; + const GLint r = FILTER_SUM_3D(rowAr0, rowAr1, rowBr0, rowBr1, + rowCr0, rowCr1, rowDr0, rowDr1); + const GLint g = FILTER_SUM_3D(rowAg0, rowAg1, rowBg0, rowBg1, + rowCg0, rowCg1, rowDg0, rowDg1); + dst[i] = (g << 4) | r; + } + } else { _mesa_problem(NULL, "bad format in do_row()"); } @@ -1704,12 +1755,22 @@ _mesa_generate_mipmap(struct gl_context *ctx, GLenum target, if (srcImage->_BaseFormat == GL_RGB) { convertFormat = MESA_FORMAT_RGB888; components = 3; - } - else if (srcImage->_BaseFormat == GL_RGBA) { + } else if (srcImage->_BaseFormat == GL_RED) { + convertFormat = MESA_FORMAT_R8; + components = 1; + } else if (srcImage->_BaseFormat == GL_RG) { + convertFormat = MESA_FORMAT_RG88; + components = 2; + } else if (srcImage->_BaseFormat == GL_RGBA) { convertFormat = MESA_FORMAT_RGBA8888; components = 4; - } - else { + } else if (srcImage->_BaseFormat == GL_LUMINANCE) { + convertFormat = MESA_FORMAT_L8; + components = 1; + } else if (srcImage->_BaseFormat == GL_LUMINANCE_ALPHA) { + convertFormat = MESA_FORMAT_AL88; + components = 2; + } else { _mesa_problem(ctx, "bad srcImage->_BaseFormat in _mesa_generate_mipmaps"); return; } diff --git a/src/mesa/main/mtypes.h b/src/mesa/main/mtypes.h index 1c549a8e24..95a7988d7e 100644 --- a/src/mesa/main/mtypes.h +++ b/src/mesa/main/mtypes.h @@ -40,6 +40,7 @@ #include "glapi/glapi.h" #include "math/m_matrix.h" /* GLmatrix */ #include "main/simple_list.h" /* struct simple_node */ +#include "main/formats.h" /* MESA_FORMAT_COUNT */ /** @@ -83,23 +84,12 @@ /*@{*/ typedef GLuint64 GLbitfield64; -#define BITFIELD64_ONE 1ULL -#define BITFIELD64_ALLONES ~0ULL - /** Set a single bit */ -#define BITFIELD64_BIT(b) (BITFIELD64_ONE << (b)) - -/** Set a mask of the least significant \c b bits */ -#define BITFIELD64_MASK(b) (((b) >= 64) ? BITFIELD64_ALLONES : \ - (BITFIELD64_BIT(b) - 1)) - -/** - * Set all bits from l (low bit) to h (high bit), inclusive. - * - * \note \C BITFIELD_64_RANGE(0, 63) return 64 set bits. - */ -#define BITFIELD64_RANGE(l, h) (BITFIELD64_MASK((h) + 1) & ~BITFIELD64_MASK(l)) -/*@}*/ +#ifdef __cplusplus +#define BITFIELD64_BIT(b) (1UL << (b)) +#else +#define BITFIELD64_BIT(b) (1ULL << (b)) +#endif /** @@ -120,6 +110,11 @@ struct st_context; /*@}*/ +/** Extra draw modes beyond GL_POINTS, GL_TRIANGLE_FAN, etc */ +#define PRIM_OUTSIDE_BEGIN_END (GL_POLYGON+1) +#define PRIM_INSIDE_UNKNOWN_PRIM (GL_POLYGON+2) +#define PRIM_UNKNOWN (GL_POLYGON+3) + /** * Shader stages. Note that these will become 5 with tessellation. @@ -295,8 +290,8 @@ typedef enum /** * Indexes for geometry program result attributes */ -/*@{*/ -typedef enum { +typedef enum +{ GEOM_RESULT_POS = 0, GEOM_RESULT_COL0 = 1, GEOM_RESULT_COL1 = 2, @@ -319,7 +314,7 @@ typedef enum { /* ### we need to -2 because var0 is 18 instead 16 like in the others */ GEOM_RESULT_MAX = (GEOM_RESULT_VAR0 + MAX_VARYING - 2) } gl_geom_result; -/*@}*/ + /** * Indexes for fragment program input attributes. @@ -518,6 +513,9 @@ struct gl_config GLint bindToMipmapTexture; GLint bindToTextureTargets; GLint yInverted; + + /* EXT_framebuffer_sRGB */ + GLint sRGBCapable; }; @@ -718,13 +716,20 @@ struct gl_colorbuffer_attrib */ /*@{*/ GLbitfield BlendEnabled; /**< Per-buffer blend enable flags */ - GLenum BlendSrcRGB; /**< Blending source operator */ - GLenum BlendDstRGB; /**< Blending destination operator */ - GLenum BlendSrcA; /**< GL_INGR_blend_func_separate */ - GLenum BlendDstA; /**< GL_INGR_blend_func_separate */ - GLenum BlendEquationRGB; /**< Blending equation */ - GLenum BlendEquationA; /**< GL_EXT_blend_equation_separate */ GLfloat BlendColor[4]; /**< Blending color */ + struct + { + GLenum SrcRGB; /**< RGB blend source term */ + GLenum DstRGB; /**< RGB blend dest term */ + GLenum SrcA; /**< Alpha blend source term */ + GLenum DstA; /**< Alpha blend dest term */ + GLenum EquationRGB; /**< GL_ADD, GL_SUBTRACT, etc. */ + GLenum EquationA; /**< GL_ADD, GL_SUBTRACT, etc. */ + } Blend[MAX_DRAW_BUFFERS]; + /** Are the blend func terms currently different for each buffer/target? */ + GLboolean _BlendFuncPerBuffer; + /** Are the blend equations currently different for each buffer/target? */ + GLboolean _BlendEquationPerBuffer; /*@}*/ /** @@ -741,6 +746,8 @@ struct gl_colorbuffer_attrib GLenum ClampFragmentColor; /**< GL_TRUE, GL_FALSE or GL_FIXED_ONLY_ARB */ GLenum ClampReadColor; /**< GL_TRUE, GL_FALSE or GL_FIXED_ONLY_ARB */ + + GLboolean sRGBEnabled; /**< Framebuffer sRGB blending/updating requested */ }; @@ -849,6 +856,23 @@ struct gl_fog_attrib }; +/** + * \brief Layout qualifiers for gl_FragDepth. + * + * Extension AMD_conservative_depth allows gl_FragDepth to be redeclared with + * a layout qualifier. + * + * \see enum ir_depth_layout + */ +enum gl_frag_depth_layout { + FRAG_DEPTH_LAYOUT_NONE, /**< No layout is specified. */ + FRAG_DEPTH_LAYOUT_ANY, + FRAG_DEPTH_LAYOUT_GREATER, + FRAG_DEPTH_LAYOUT_LESS, + FRAG_DEPTH_LAYOUT_UNCHANGED +}; + + /** * Hint attribute group (GL_HINT_BIT). * @@ -1011,10 +1035,6 @@ struct gl_pixel_attrib /** glPixelZoom */ GLfloat ZoomX, ZoomY; - - /** GL_SGI_texture_color_table */ - GLfloat TextureColorTableScale[4]; /**< RGBA */ - GLfloat TextureColorTableBias[4]; /**< RGBA */ }; @@ -1220,7 +1240,7 @@ struct gl_texture_image * GL_DEPTH_COMPONENT or GL_DEPTH_STENCIL_EXT * only. Used for choosing TexEnv arithmetic. */ - GLuint TexFormat; /**< The actual format: MESA_FORMAT_x */ + gl_format TexFormat; /**< The actual texture memory format */ GLuint Border; /**< 0 or 1 */ GLuint Width; /**< = 2^WidthLog2 + 2*Border */ @@ -1314,6 +1334,7 @@ struct gl_texture_object GLboolean _Complete; /**< Is texture object complete? */ GLboolean _RenderToTexture; /**< Any rendering to this texture? */ GLboolean Purgeable; /**< Is the buffer purgeable under memory pressure? */ + GLenum sRGBDecode; /**< GL_DECODE_EXT or GL_SKIP_DECODE_EXT */ /** Actual texture images, indexed by [cube face] and [mipmap level] */ struct gl_texture_image *Image[MAX_FACES][MAX_TEXTURE_LEVELS]; @@ -1414,13 +1435,6 @@ struct gl_texture_unit /** Points to highest priority, complete and enabled texture object */ struct gl_texture_object *_Current; - - /** GL_SGI_texture_color_table */ - /*@{*/ - struct gl_color_table ColorTable; - struct gl_color_table ProxyColorTable; - GLboolean ColorTableEnabled; - /*@}*/ }; @@ -1545,6 +1559,7 @@ struct gl_client_array GLboolean Enabled; /**< Enabled flag is a boolean */ GLboolean Normalized; /**< GL_ARB_vertex_program */ GLboolean Integer; /**< Integer-valued? */ + GLuint InstanceDivisor; /**< GL_ARB_instanced_arrays */ GLuint _ElementSize; /**< size of each element in bytes */ struct gl_buffer_object *BufferObj;/**< GL_ARB_vertex_buffer_object */ @@ -1621,6 +1636,7 @@ struct gl_array_attrib GLuint RestartIndex; GLbitfield NewState; /**< mask of _NEW_ARRAY_* values */ + GLboolean RebindArrays; /**< whether the VBO module should rebind arrays */ /* GL_ARB_vertex_buffer_object */ struct gl_buffer_object *ArrayBufferObj; @@ -1747,11 +1763,24 @@ typedef enum PROGRAM_WRITE_ONLY, /**< A dummy, write-only register */ PROGRAM_ADDRESS, /**< machine->AddressReg */ PROGRAM_SAMPLER, /**< for shader samplers, compile-time only */ + PROGRAM_SYSTEM_VALUE,/**< InstanceId, PrimitiveID, etc. */ PROGRAM_UNDEFINED, /**< Invalid/TBD value */ PROGRAM_FILE_MAX } gl_register_file; +/** + * If the register file is PROGRAM_SYSTEM_VALUE, the register index will be + * one of these values. + */ +typedef enum +{ + SYSTEM_VALUE_FRONT_FACE, /**< Fragment shader only (not done yet) */ + SYSTEM_VALUE_INSTANCE_ID, /**< Vertex shader only */ + SYSTEM_VALUE_MAX /**< Number of values */ +} gl_system_value; + + /** Vertex and fragment instructions */ struct prog_instruction; struct gl_program_parameter_list; @@ -1774,6 +1803,7 @@ struct gl_program GLbitfield InputsRead; /**< Bitmask of which input regs are read */ GLbitfield64 OutputsWritten; /**< Bitmask of which output regs are written */ + GLbitfield SystemValuesRead; /**< Bitmask of SYSTEM_VALUE_x inputs used */ GLbitfield InputFlags[MAX_PROGRAM_INPUTS]; /**< PROG_PARAM_BIT_x flags */ GLbitfield OutputFlags[MAX_PROGRAM_OUTPUTS]; /**< PROG_PARAM_BIT_x flags */ GLbitfield TexturesUsed[MAX_TEXTURE_UNITS]; /**< TEXTURE_x_BIT bitmask */ @@ -1855,6 +1885,7 @@ struct gl_fragment_program GLboolean UsesKill; /**< shader uses KIL instruction */ GLboolean OriginUpperLeft; GLboolean PixelCenterInteger; + enum gl_frag_depth_layout FragDepthLayout; }; @@ -2066,8 +2097,6 @@ struct gl_shader GLint RefCount; /**< Reference count */ GLboolean DeletePending; GLboolean CompileStatus; - GLboolean Main; /**< shader defines main() */ - GLboolean UnresolvedRefs; const GLchar *Source; /**< Source code string */ GLuint SourceChecksum; /**< for debug/logging purposes */ struct gl_program *Program; /**< Post-compile assembly code */ @@ -2344,13 +2373,15 @@ struct gl_renderbuffer GLenum InternalFormat; /**< The user-specified format */ GLenum _BaseFormat; /**< Either GL_RGB, GL_RGBA, GL_DEPTH_COMPONENT or GL_STENCIL_INDEX. */ - GLuint Format; /**< The actual format: MESA_FORMAT_x */ + gl_format Format; /**< The actual renderbuffer memory format */ GLubyte NumSamples; GLenum DataType; /**< Type of values passed to the Get/Put functions */ GLvoid *Data; /**< This may not be used by some kinds of RBs */ + GLboolean AttachedAnytime; /**< TRUE if it was attached to a framebuffer */ + /* Used to wrap one renderbuffer around another: */ struct gl_renderbuffer *Wrapped; @@ -2525,7 +2556,18 @@ struct gl_framebuffer /** - * Limits for vertex and fragment programs/shaders. + * Precision info for shader datatypes. See glGetShaderPrecisionFormat(). + */ +struct gl_precision +{ + GLushort RangeMin; /**< min value exponent */ + GLushort RangeMax; /**< max value exponent */ + GLushort Precision; /**< number of mantissa bits */ +}; + + +/** + * Limits for vertex, geometry and fragment programs/shaders. */ struct gl_program_constants { @@ -2537,6 +2579,7 @@ struct gl_program_constants GLuint MaxAttribs; GLuint MaxTemps; GLuint MaxAddressRegs; + GLuint MaxAddressOffset; /**< [-MaxAddressOffset, MaxAddressOffset-1] */ GLuint MaxParameters; GLuint MaxLocalParams; GLuint MaxEnvParams; @@ -2550,14 +2593,10 @@ struct gl_program_constants GLuint MaxNativeAddressRegs; GLuint MaxNativeParameters; /* For shaders */ - GLuint MaxUniformComponents; - /* GL_ARB_geometry_shader4 */ - GLuint MaxGeometryTextureImageUnits; - GLuint MaxGeometryVaryingComponents; - GLuint MaxVertexVaryingComponents; - GLuint MaxGeometryUniformComponents; - GLuint MaxGeometryOutputVertices; - GLuint MaxGeometryTotalOutputComponents; + GLuint MaxUniformComponents; /**< Usually == MaxParameters * 4 */ + /* ES 2.0 and GL_ARB_ES2_compatibility */ + struct gl_precision LowFloat, MediumFloat, HighFloat; + struct gl_precision LowInt, MediumInt, HighInt; }; @@ -2577,6 +2616,7 @@ struct gl_constants GLuint MaxTextureImageUnits; GLuint MaxVertexTextureImageUnits; GLuint MaxCombinedTextureImageUnits; + GLuint MaxGeometryTextureImageUnits; GLuint MaxTextureUnits; /**< = MIN(CoordUnits, ImageUnits) */ GLfloat MaxTextureMaxAnisotropy; /**< GL_EXT_texture_filter_anisotropic */ GLfloat MaxTextureLodBias; /**< GL_EXT_texture_lod_bias */ @@ -2616,7 +2656,14 @@ struct gl_constants GLuint MaxRenderbufferSize; /**< GL_EXT_framebuffer_object */ GLuint MaxSamples; /**< GL_ARB_framebuffer_object */ - GLuint MaxVarying; /**< Number of float[4] varying parameters */ + /** Number of varying vectors between vertex and fragment shaders */ + GLuint MaxVarying; + GLuint MaxVertexVaryingComponents; /**< Between vert and geom shader */ + GLuint MaxGeometryVaryingComponents; /**< Between geom and frag shader */ + + /** GL_ARB_geometry_shader4 */ + GLuint MaxGeometryOutputVertices; + GLuint MaxGeometryTotalOutputComponents; GLuint GLSLVersion; /**< GLSL version supported (ex: 120 = 1.20) */ @@ -2644,6 +2691,9 @@ struct gl_constants /** GL_EXT_gpu_shader4 */ GLint MinProgramTexelOffset, MaxProgramTexelOffset; + + /* GL_EXT_framebuffer_sRGB */ + GLboolean sRGBCapable; /* can enable sRGB blend/update on FBOs */ }; @@ -2654,12 +2704,16 @@ struct gl_constants struct gl_extensions { GLboolean dummy; /* don't remove this! */ + GLboolean dummy_true; /* Set true by _mesa_init_extensions(). */ + GLboolean dummy_false; /* Set false by _mesa_init_extensions(). */ + GLboolean ARB_ES2_compatibility; GLboolean ARB_blend_func_extended; GLboolean ARB_copy_buffer; GLboolean ARB_depth_buffer_float; GLboolean ARB_depth_clamp; GLboolean ARB_depth_texture; GLboolean ARB_draw_buffers; + GLboolean ARB_draw_buffers_blend; GLboolean ARB_draw_elements_base_vertex; GLboolean ARB_draw_instanced; GLboolean ARB_fragment_coord_conventions; @@ -2753,6 +2807,7 @@ struct gl_extensions GLboolean EXT_texture_object; GLboolean EXT_texture3D; GLboolean EXT_texture_array; + GLboolean EXT_texture_compression_latc; GLboolean EXT_texture_compression_s3tc; GLboolean EXT_texture_env_add; GLboolean EXT_texture_env_combine; @@ -2763,18 +2818,22 @@ struct gl_extensions GLboolean EXT_texture_mirror_clamp; GLboolean EXT_texture_shared_exponent; GLboolean EXT_texture_sRGB; + GLboolean EXT_texture_sRGB_decode; GLboolean EXT_texture_swizzle; GLboolean EXT_transform_feedback; GLboolean EXT_timer_query; GLboolean EXT_vertex_array; GLboolean EXT_vertex_array_bgra; GLboolean EXT_vertex_array_set; + GLboolean OES_standard_derivatives; /* vendor extensions */ + GLboolean AMD_conservative_depth; GLboolean APPLE_client_storage; GLboolean APPLE_packed_pixels; GLboolean APPLE_vertex_array_object; GLboolean APPLE_object_purgeable; GLboolean ATI_envmap_bumpmap; + GLboolean ATI_texture_compression_3dc; GLboolean ATI_texture_mirror_once; GLboolean ATI_texture_env_combine3; GLboolean ATI_fragment_shader; @@ -2793,13 +2852,13 @@ struct gl_extensions GLboolean NV_light_max_exponent; GLboolean NV_point_sprite; GLboolean NV_primitive_restart; + GLboolean NV_texture_barrier; GLboolean NV_texgen_reflection; GLboolean NV_texture_env_combine4; GLboolean NV_texture_rectangle; GLboolean NV_vertex_program; GLboolean NV_vertex_program1_1; GLboolean OES_read_format; - GLboolean SGI_texture_color_table; GLboolean SGIS_generate_mipmap; GLboolean SGIS_texture_edge_clamp; GLboolean SGIS_texture_lod; @@ -2808,6 +2867,7 @@ struct gl_extensions GLboolean OES_EGL_image; GLboolean OES_draw_texture; GLboolean EXT_texture_format_BGRA8888; + GLboolean extension_sentinel; /** The extension string */ const GLubyte *String; /** Number of supported extensions */ @@ -2846,40 +2906,37 @@ struct gl_matrix_stack /** * \name Bits to indicate what state has changed. - * - * 4 unused flags. */ /*@{*/ -#define _NEW_MODELVIEW 0x1 /**< __struct gl_contextRec::ModelView */ -#define _NEW_PROJECTION 0x2 /**< __struct gl_contextRec::Projection */ -#define _NEW_TEXTURE_MATRIX 0x4 /**< __struct gl_contextRec::TextureMatrix */ -#define _NEW_ACCUM 0x10 /**< __struct gl_contextRec::Accum */ -#define _NEW_COLOR 0x20 /**< __struct gl_contextRec::Color */ -#define _NEW_DEPTH 0x40 /**< __struct gl_contextRec::Depth */ -#define _NEW_EVAL 0x80 /**< __struct gl_contextRec::Eval, __struct gl_contextRec::EvalMap */ -#define _NEW_FOG 0x100 /**< __struct gl_contextRec::Fog */ -#define _NEW_HINT 0x200 /**< __struct gl_contextRec::Hint */ -#define _NEW_LIGHT 0x400 /**< __struct gl_contextRec::Light */ -#define _NEW_LINE 0x800 /**< __struct gl_contextRec::Line */ -#define _NEW_PIXEL 0x1000 /**< __struct gl_contextRec::Pixel */ -#define _NEW_POINT 0x2000 /**< __struct gl_contextRec::Point */ -#define _NEW_POLYGON 0x4000 /**< __struct gl_contextRec::Polygon */ -#define _NEW_POLYGONSTIPPLE 0x8000 /**< __struct gl_contextRec::PolygonStipple */ -#define _NEW_SCISSOR 0x10000 /**< __struct gl_contextRec::Scissor */ -#define _NEW_STENCIL 0x20000 /**< __struct gl_contextRec::Stencil */ -#define _NEW_TEXTURE 0x40000 /**< __struct gl_contextRec::Texture */ -#define _NEW_TRANSFORM 0x80000 /**< __struct gl_contextRec::Transform */ -#define _NEW_VIEWPORT 0x100000 /**< __struct gl_contextRec::Viewport */ -#define _NEW_PACKUNPACK 0x200000 /**< __struct gl_contextRec::Pack, __struct gl_contextRec::Unpack */ -#define _NEW_ARRAY 0x400000 /**< __struct gl_contextRec::Array */ -#define _NEW_RENDERMODE 0x800000 /**< __struct gl_contextRec::RenderMode, __struct gl_contextRec::Feedback, __struct gl_contextRec::Select */ -#define _NEW_BUFFERS 0x1000000 /**< __struct gl_contextRec::Visual, __struct gl_contextRec::DrawBuffer, */ -#define _NEW_MULTISAMPLE 0x2000000 /**< __struct gl_contextRec::Multisample */ -#define _NEW_TRACK_MATRIX 0x4000000 /**< __struct gl_contextRec::VertexProgram */ -#define _NEW_PROGRAM 0x8000000 /**< __struct gl_contextRec::VertexProgram */ -#define _NEW_CURRENT_ATTRIB 0x10000000 /**< __struct gl_contextRec::Current */ -#define _NEW_PROGRAM_CONSTANTS 0x20000000 -#define _NEW_BUFFER_OBJECT 0x40000000 +#define _NEW_MODELVIEW (1 << 0) /**< gl_context::ModelView */ +#define _NEW_PROJECTION (1 << 1) /**< gl_context::Projection */ +#define _NEW_TEXTURE_MATRIX (1 << 2) /**< gl_context::TextureMatrix */ +#define _NEW_COLOR (1 << 3) /**< gl_context::Color */ +#define _NEW_DEPTH (1 << 4) /**< gl_context::Depth */ +#define _NEW_EVAL (1 << 5) /**< gl_context::Eval, EvalMap */ +#define _NEW_FOG (1 << 6) /**< gl_context::Fog */ +#define _NEW_HINT (1 << 7) /**< gl_context::Hint */ +#define _NEW_LIGHT (1 << 8) /**< gl_context::Light */ +#define _NEW_LINE (1 << 9) /**< gl_context::Line */ +#define _NEW_PIXEL (1 << 10) /**< gl_context::Pixel */ +#define _NEW_POINT (1 << 11) /**< gl_context::Point */ +#define _NEW_POLYGON (1 << 12) /**< gl_context::Polygon */ +#define _NEW_POLYGONSTIPPLE (1 << 13) /**< gl_context::PolygonStipple */ +#define _NEW_SCISSOR (1 << 14) /**< gl_context::Scissor */ +#define _NEW_STENCIL (1 << 15) /**< gl_context::Stencil */ +#define _NEW_TEXTURE (1 << 16) /**< gl_context::Texture */ +#define _NEW_TRANSFORM (1 << 17) /**< gl_context::Transform */ +#define _NEW_VIEWPORT (1 << 18) /**< gl_context::Viewport */ +#define _NEW_PACKUNPACK (1 << 19) /**< gl_context::Pack, Unpack */ +#define _NEW_ARRAY (1 << 20) /**< gl_context::Array */ +#define _NEW_RENDERMODE (1 << 21) /**< gl_context::RenderMode, etc */ +#define _NEW_BUFFERS (1 << 22) /**< gl_context::Visual, DrawBuffer, */ +#define _NEW_CURRENT_ATTRIB (1 << 23) /**< gl_context::Current */ +#define _NEW_MULTISAMPLE (1 << 24) /**< gl_context::Multisample */ +#define _NEW_TRACK_MATRIX (1 << 25) /**< gl_context::VertexProgram */ +#define _NEW_PROGRAM (1 << 26) /**< New program/shader state */ +#define _NEW_PROGRAM_CONSTANTS (1 << 27) +#define _NEW_BUFFER_OBJECT (1 << 28) #define _NEW_ALL ~0 /*@}*/ @@ -3043,15 +3100,18 @@ struct gl_dlist_state } Current; }; + /** * Enum for the OpenGL APIs we know about and may support. */ -typedef enum { +typedef enum +{ API_OPENGL, API_OPENGLES, API_OPENGLES2 } gl_api; + /** * Mesa rendering context. * @@ -3234,12 +3294,11 @@ struct gl_context GLboolean FirstTimeCurrent; /*@}*/ - /** Dither disable via MESA_NO_DITHER env var */ - GLboolean NoDither; - /** software compression/decompression supported or not */ GLboolean Mesa_DXTn; + GLboolean TextureFormatSupported[MESA_FORMAT_COUNT]; + /** * Use dp4 (rather than mul/mad) instructions for position * transformation? @@ -3262,10 +3321,6 @@ struct gl_context }; -/** The string names for GL_POINT, GL_LINE_LOOP, etc */ -extern const char *_mesa_prim_name[GL_POLYGON+4]; - - #ifdef DEBUG extern int MESA_VERBOSE; extern int MESA_DEBUG_FLAGS; diff --git a/src/mesa/main/multisample.c b/src/mesa/main/multisample.c index 5487d45f56..67fdb8c9db 100644 --- a/src/mesa/main/multisample.c +++ b/src/mesa/main/multisample.c @@ -27,6 +27,7 @@ #include "main/context.h" #include "main/macros.h" #include "main/multisample.h" +#include "main/mtypes.h" /** diff --git a/src/mesa/main/nvprogram.c b/src/mesa/main/nvprogram.c index 36cea3bb9a..dd198b8141 100644 --- a/src/mesa/main/nvprogram.c +++ b/src/mesa/main/nvprogram.c @@ -42,6 +42,7 @@ #include "main/hash.h" #include "main/imports.h" #include "main/macros.h" +#include "main/mtypes.h" #include "main/nvprogram.h" #include "program/arbprogparse.h" #include "program/nvfragparse.h" diff --git a/src/mesa/main/pack.c b/src/mesa/main/pack.c index 6d524e6490..512835cb80 100644 --- a/src/mesa/main/pack.c +++ b/src/mesa/main/pack.c @@ -34,6 +34,7 @@ #include "enums.h" #include "image.h" #include "imports.h" +#include "mtypes.h" #include "pack.h" #include "pixeltransfer.h" #include "imports.h" diff --git a/src/mesa/main/pbo.c b/src/mesa/main/pbo.c new file mode 100644 index 0000000000..dc00d423ba --- /dev/null +++ b/src/mesa/main/pbo.c @@ -0,0 +1,372 @@ +/* + * Mesa 3-D graphics library + * + * Copyright (C) 1999-2008 Brian Paul All Rights Reserved. + * Copyright (C) 2009-2011 VMware, Inc. All Rights Reserved. + * + * Permission is hereby granted, free of charge, to any person obtaining a + * copy of this software and associated documentation files (the "Software"), + * to deal in the Software without restriction, including without limitation + * the rights to use, copy, modify, merge, publish, distribute, sublicense, + * and/or sell copies of the Software, and to permit persons to whom the + * Software is furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included + * in all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS + * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL + * THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN + * AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN + * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + */ + + +/** + * \file pbo.c + * \brief Functions related to Pixel Buffer Objects. + */ + + + +#include "glheader.h" +#include "bufferobj.h" +#include "image.h" +#include "imports.h" +#include "mtypes.h" +#include "pbo.h" + + + +/** + * When we're about to read pixel data out of a PBO (via glDrawPixels, + * glTexImage, etc) or write data into a PBO (via glReadPixels, + * glGetTexImage, etc) we call this function to check that we're not + * going to read out of bounds. + * + * XXX This would also be a convenient time to check that the PBO isn't + * currently mapped. Whoever calls this function should check for that. + * Remember, we can't use a PBO when it's mapped! + * + * If we're not using a PBO, this is a no-op. + * + * \param width width of image to read/write + * \param height height of image to read/write + * \param depth depth of image to read/write + * \param format format of image to read/write + * \param type datatype of image to read/write + * \param ptr the user-provided pointer/offset + * \return GL_TRUE if the PBO access is OK, GL_FALSE if the access would + * go out of bounds. + */ +GLboolean +_mesa_validate_pbo_access(GLuint dimensions, + const struct gl_pixelstore_attrib *pack, + GLsizei width, GLsizei height, GLsizei depth, + GLenum format, GLenum type, const GLvoid *ptr) +{ + GLvoid *start, *end; + const GLubyte *sizeAddr; /* buffer size, cast to a pointer */ + + if (!_mesa_is_bufferobj(pack->BufferObj)) + return GL_TRUE; /* no PBO, OK */ + + if (pack->BufferObj->Size == 0) + /* no buffer! */ + return GL_FALSE; + + /* get address of first pixel we'll read */ + start = _mesa_image_address(dimensions, pack, ptr, width, height, + format, type, 0, 0, 0); + + /* get address just past the last pixel we'll read */ + end = _mesa_image_address(dimensions, pack, ptr, width, height, + format, type, depth-1, height-1, width); + + + sizeAddr = ((const GLubyte *) 0) + pack->BufferObj->Size; + + if ((const GLubyte *) start > sizeAddr) { + /* This will catch negative values / wrap-around */ + return GL_FALSE; + } + if ((const GLubyte *) end > sizeAddr) { + /* Image read goes beyond end of buffer */ + return GL_FALSE; + } + + /* OK! */ + return GL_TRUE; +} + + +/** + * For commands that read from a PBO (glDrawPixels, glTexImage, + * glPolygonStipple, etc), if we're reading from a PBO, map it read-only + * and return the pointer into the PBO. If we're not reading from a + * PBO, return \p src as-is. + * If non-null return, must call _mesa_unmap_pbo_source() when done. + * + * \return NULL if error, else pointer to start of data + */ +const GLvoid * +_mesa_map_pbo_source(struct gl_context *ctx, + const struct gl_pixelstore_attrib *unpack, + const GLvoid *src) +{ + const GLubyte *buf; + + if (_mesa_is_bufferobj(unpack->BufferObj)) { + /* unpack from PBO */ + buf = (GLubyte *) ctx->Driver.MapBuffer(ctx, GL_PIXEL_UNPACK_BUFFER_EXT, + GL_READ_ONLY_ARB, + unpack->BufferObj); + if (!buf) + return NULL; + + buf = ADD_POINTERS(buf, src); + } + else { + /* unpack from normal memory */ + buf = src; + } + + return buf; +} + + +/** + * Combine PBO-read validation and mapping. + * If any GL errors are detected, they'll be recorded and NULL returned. + * \sa _mesa_validate_pbo_access + * \sa _mesa_map_pbo_source + * A call to this function should have a matching call to + * _mesa_unmap_pbo_source(). + */ +const GLvoid * +_mesa_map_validate_pbo_source(struct gl_context *ctx, + GLuint dimensions, + const struct gl_pixelstore_attrib *unpack, + GLsizei width, GLsizei height, GLsizei depth, + GLenum format, GLenum type, const GLvoid *ptr, + const char *where) +{ + ASSERT(dimensions == 1 || dimensions == 2 || dimensions == 3); + + if (!_mesa_is_bufferobj(unpack->BufferObj)) { + /* non-PBO access: no validation to be done */ + return ptr; + } + + if (!_mesa_validate_pbo_access(dimensions, unpack, + width, height, depth, format, type, ptr)) { + _mesa_error(ctx, GL_INVALID_OPERATION, + "%s(out of bounds PBO access)", where); + return NULL; + } + + if (_mesa_bufferobj_mapped(unpack->BufferObj)) { + /* buffer is already mapped - that's an error */ + _mesa_error(ctx, GL_INVALID_OPERATION, "%s(PBO is mapped)", where); + return NULL; + } + + ptr = _mesa_map_pbo_source(ctx, unpack, ptr); + return ptr; +} + + +/** + * Counterpart to _mesa_map_pbo_source() + */ +void +_mesa_unmap_pbo_source(struct gl_context *ctx, + const struct gl_pixelstore_attrib *unpack) +{ + ASSERT(unpack != &ctx->Pack); /* catch pack/unpack mismatch */ + if (_mesa_is_bufferobj(unpack->BufferObj)) { + ctx->Driver.UnmapBuffer(ctx, GL_PIXEL_UNPACK_BUFFER_EXT, + unpack->BufferObj); + } +} + + +/** + * For commands that write to a PBO (glReadPixels, glGetColorTable, etc), + * if we're writing to a PBO, map it write-only and return the pointer + * into the PBO. If we're not writing to a PBO, return \p dst as-is. + * If non-null return, must call _mesa_unmap_pbo_dest() when done. + * + * \return NULL if error, else pointer to start of data + */ +void * +_mesa_map_pbo_dest(struct gl_context *ctx, + const struct gl_pixelstore_attrib *pack, + GLvoid *dest) +{ + void *buf; + + if (_mesa_is_bufferobj(pack->BufferObj)) { + /* pack into PBO */ + buf = (GLubyte *) ctx->Driver.MapBuffer(ctx, GL_PIXEL_PACK_BUFFER_EXT, + GL_WRITE_ONLY_ARB, + pack->BufferObj); + if (!buf) + return NULL; + + buf = ADD_POINTERS(buf, dest); + } + else { + /* pack to normal memory */ + buf = dest; + } + + return buf; +} + + +/** + * Combine PBO-write validation and mapping. + * If any GL errors are detected, they'll be recorded and NULL returned. + * \sa _mesa_validate_pbo_access + * \sa _mesa_map_pbo_dest + * A call to this function should have a matching call to + * _mesa_unmap_pbo_dest(). + */ +GLvoid * +_mesa_map_validate_pbo_dest(struct gl_context *ctx, + GLuint dimensions, + const struct gl_pixelstore_attrib *unpack, + GLsizei width, GLsizei height, GLsizei depth, + GLenum format, GLenum type, GLvoid *ptr, + const char *where) +{ + ASSERT(dimensions == 1 || dimensions == 2 || dimensions == 3); + + if (!_mesa_is_bufferobj(unpack->BufferObj)) { + /* non-PBO access: no validation to be done */ + return ptr; + } + + if (!_mesa_validate_pbo_access(dimensions, unpack, + width, height, depth, format, type, ptr)) { + _mesa_error(ctx, GL_INVALID_OPERATION, + "%s(out of bounds PBO access)", where); + return NULL; + } + + if (_mesa_bufferobj_mapped(unpack->BufferObj)) { + /* buffer is already mapped - that's an error */ + _mesa_error(ctx, GL_INVALID_OPERATION, "%s(PBO is mapped)", where); + return NULL; + } + + ptr = _mesa_map_pbo_dest(ctx, unpack, ptr); + return ptr; +} + + +/** + * Counterpart to _mesa_map_pbo_dest() + */ +void +_mesa_unmap_pbo_dest(struct gl_context *ctx, + const struct gl_pixelstore_attrib *pack) +{ + ASSERT(pack != &ctx->Unpack); /* catch pack/unpack mismatch */ + if (_mesa_is_bufferobj(pack->BufferObj)) { + ctx->Driver.UnmapBuffer(ctx, GL_PIXEL_PACK_BUFFER_EXT, pack->BufferObj); + } +} + + + +/** + * Check if an unpack PBO is active prior to fetching a texture image. + * If so, do bounds checking and map the buffer into main memory. + * Any errors detected will be recorded. + * The caller _must_ call _mesa_unmap_teximage_pbo() too! + */ +const GLvoid * +_mesa_validate_pbo_teximage(struct gl_context *ctx, GLuint dimensions, + GLsizei width, GLsizei height, GLsizei depth, + GLenum format, GLenum type, const GLvoid *pixels, + const struct gl_pixelstore_attrib *unpack, + const char *funcName) +{ + GLubyte *buf; + + if (!_mesa_is_bufferobj(unpack->BufferObj)) { + /* no PBO */ + return pixels; + } + if (!_mesa_validate_pbo_access(dimensions, unpack, width, height, depth, + format, type, pixels)) { + _mesa_error(ctx, GL_INVALID_OPERATION, funcName, "(invalid PBO access)"); + return NULL; + } + + buf = (GLubyte *) ctx->Driver.MapBuffer(ctx, GL_PIXEL_UNPACK_BUFFER_EXT, + GL_READ_ONLY_ARB, unpack->BufferObj); + if (!buf) { + _mesa_error(ctx, GL_INVALID_OPERATION, funcName, "(PBO is mapped)"); + return NULL; + } + + return ADD_POINTERS(buf, pixels); +} + + +/** + * Check if an unpack PBO is active prior to fetching a compressed texture + * image. + * If so, do bounds checking and map the buffer into main memory. + * Any errors detected will be recorded. + * The caller _must_ call _mesa_unmap_teximage_pbo() too! + */ +const GLvoid * +_mesa_validate_pbo_compressed_teximage(struct gl_context *ctx, + GLsizei imageSize, const GLvoid *pixels, + const struct gl_pixelstore_attrib *packing, + const char *funcName) +{ + GLubyte *buf; + + if (!_mesa_is_bufferobj(packing->BufferObj)) { + /* not using a PBO - return pointer unchanged */ + return pixels; + } + if ((const GLubyte *) pixels + imageSize > + ((const GLubyte *) 0) + packing->BufferObj->Size) { + /* out of bounds read! */ + _mesa_error(ctx, GL_INVALID_OPERATION, funcName, "(invalid PBO access)"); + return NULL; + } + + buf = (GLubyte*) ctx->Driver.MapBuffer(ctx, GL_PIXEL_UNPACK_BUFFER_EXT, + GL_READ_ONLY_ARB, packing->BufferObj); + if (!buf) { + _mesa_error(ctx, GL_INVALID_OPERATION, funcName, "(PBO is mapped"); + return NULL; + } + + return ADD_POINTERS(buf, pixels); +} + + +/** + * This function must be called after either of the validate_pbo_*_teximage() + * functions. It unmaps the PBO buffer if it was mapped earlier. + */ +void +_mesa_unmap_teximage_pbo(struct gl_context *ctx, + const struct gl_pixelstore_attrib *unpack) +{ + if (_mesa_is_bufferobj(unpack->BufferObj)) { + ctx->Driver.UnmapBuffer(ctx, GL_PIXEL_UNPACK_BUFFER_EXT, + unpack->BufferObj); + } +} + + diff --git a/src/mesa/main/pbo.h b/src/mesa/main/pbo.h new file mode 100644 index 0000000000..0cddd72ba7 --- /dev/null +++ b/src/mesa/main/pbo.h @@ -0,0 +1,92 @@ +/* + * Mesa 3-D graphics library + * + * Copyright (C) 1999-2008 Brian Paul All Rights Reserved. + * Copyright (C) 2009-2011 VMware, Inc. All Rights Reserved. + * + * Permission is hereby granted, free of charge, to any person obtaining a + * copy of this software and associated documentation files (the "Software"), + * to deal in the Software without restriction, including without limitation + * the rights to use, copy, modify, merge, publish, distribute, sublicense, + * and/or sell copies of the Software, and to permit persons to whom the + * Software is furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included + * in all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS + * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL + * THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN + * AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN + * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + */ + + +#ifndef PBO_H +#define PBO_H + + +#include "mtypes.h" + + +extern GLboolean +_mesa_validate_pbo_access(GLuint dimensions, + const struct gl_pixelstore_attrib *pack, + GLsizei width, GLsizei height, GLsizei depth, + GLenum format, GLenum type, const GLvoid *ptr); + +extern const GLvoid * +_mesa_map_pbo_source(struct gl_context *ctx, + const struct gl_pixelstore_attrib *unpack, + const GLvoid *src); + +extern const GLvoid * +_mesa_map_validate_pbo_source(struct gl_context *ctx, + GLuint dimensions, + const struct gl_pixelstore_attrib *unpack, + GLsizei width, GLsizei height, GLsizei depth, + GLenum format, GLenum type, const GLvoid *ptr, + const char *where); + +extern void +_mesa_unmap_pbo_source(struct gl_context *ctx, + const struct gl_pixelstore_attrib *unpack); + +extern void * +_mesa_map_pbo_dest(struct gl_context *ctx, + const struct gl_pixelstore_attrib *pack, + GLvoid *dest); + +extern GLvoid * +_mesa_map_validate_pbo_dest(struct gl_context *ctx, + GLuint dimensions, + const struct gl_pixelstore_attrib *unpack, + GLsizei width, GLsizei height, GLsizei depth, + GLenum format, GLenum type, GLvoid *ptr, + const char *where); + +extern void +_mesa_unmap_pbo_dest(struct gl_context *ctx, + const struct gl_pixelstore_attrib *pack); + + +extern const GLvoid * +_mesa_validate_pbo_teximage(struct gl_context *ctx, GLuint dimensions, + GLsizei width, GLsizei height, GLsizei depth, + GLenum format, GLenum type, const GLvoid *pixels, + const struct gl_pixelstore_attrib *unpack, + const char *funcName); + +extern const GLvoid * +_mesa_validate_pbo_compressed_teximage(struct gl_context *ctx, + GLsizei imageSize, const GLvoid *pixels, + const struct gl_pixelstore_attrib *packing, + const char *funcName); + +extern void +_mesa_unmap_teximage_pbo(struct gl_context *ctx, + const struct gl_pixelstore_attrib *unpack); + + +#endif diff --git a/src/mesa/main/pixel.c b/src/mesa/main/pixel.c index 5f824b3429..195fa234be 100644 --- a/src/mesa/main/pixel.c +++ b/src/mesa/main/pixel.c @@ -33,7 +33,9 @@ #include "colormac.h" #include "context.h" #include "macros.h" +#include "mfeatures.h" #include "pixel.h" +#include "pbo.h" #include "mtypes.h" #include "main/dispatch.h" @@ -684,9 +686,6 @@ _mesa_init_pixel( struct gl_context *ctx ) init_pixelmap(&ctx->PixelMaps.GtoG); init_pixelmap(&ctx->PixelMaps.BtoB); init_pixelmap(&ctx->PixelMaps.AtoA); - /* GL_SGI_texture_color_table */ - ASSIGN_4V(ctx->Pixel.TextureColorTableScale, 1.0, 1.0, 1.0, 1.0); - ASSIGN_4V(ctx->Pixel.TextureColorTableBias, 0.0, 0.0, 0.0, 0.0); if (ctx->Visual.doubleBufferMode) { ctx->Pixel.ReadBuffer = GL_BACK; diff --git a/src/mesa/main/pixelstore.c b/src/mesa/main/pixelstore.c index b16d27a4ea..9d78eec7fe 100644 --- a/src/mesa/main/pixelstore.c +++ b/src/mesa/main/pixelstore.c @@ -32,6 +32,7 @@ #include "bufferobj.h" #include "context.h" #include "pixelstore.h" +#include "mfeatures.h" #include "mtypes.h" diff --git a/src/mesa/main/pixeltransfer.c b/src/mesa/main/pixeltransfer.c index 711181fd89..c1832972f5 100644 --- a/src/mesa/main/pixeltransfer.c +++ b/src/mesa/main/pixeltransfer.c @@ -33,6 +33,7 @@ #include "colormac.h" #include "pixeltransfer.h" #include "imports.h" +#include "mtypes.h" /* diff --git a/src/mesa/main/polygon.c b/src/mesa/main/polygon.c index 9c213b9b4c..ff4232ecc3 100644 --- a/src/mesa/main/polygon.c +++ b/src/mesa/main/polygon.c @@ -30,11 +30,11 @@ #include "glheader.h" #include "imports.h" -#include "bufferobj.h" #include "context.h" #include "image.h" #include "enums.h" #include "pack.h" +#include "pbo.h" #include "polygon.h" #include "mtypes.h" diff --git a/src/mesa/main/queryobj.c b/src/mesa/main/queryobj.c index 8874397720..e9cf5f64d0 100644 --- a/src/mesa/main/queryobj.c +++ b/src/mesa/main/queryobj.c @@ -25,9 +25,11 @@ #include "glheader.h" #include "context.h" +#include "enums.h" #include "hash.h" #include "imports.h" #include "queryobj.h" +#include "mfeatures.h" #include "mtypes.h" #include "main/dispatch.h" @@ -143,6 +145,11 @@ get_query_binding_point(struct gl_context *ctx, GLenum target) return &ctx->Query.CurrentOcclusionObject; else return NULL; + case GL_ANY_SAMPLES_PASSED: + if (ctx->Extensions.ARB_occlusion_query2) + return &ctx->Query.CurrentOcclusionObject; + else + return NULL; case GL_TIME_ELAPSED_EXT: if (ctx->Extensions.EXT_timer_query) return &ctx->Query.CurrentTimerObject; @@ -173,6 +180,9 @@ _mesa_GenQueriesARB(GLsizei n, GLuint *ids) GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glGenQueries(%d)\n", n); + if (n < 0) { _mesa_error(ctx, GL_INVALID_VALUE, "glGenQueriesARB(n < 0)"); return; @@ -208,6 +218,10 @@ _mesa_DeleteQueriesARB(GLsizei n, const GLuint *ids) GLint i; GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END(ctx); + FLUSH_VERTICES(ctx, 0); + + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glDeleeteQueries(%d)\n", n); if (n < 0) { _mesa_error(ctx, GL_INVALID_VALUE, "glDeleteQueriesARB(n < 0)"); @@ -240,6 +254,9 @@ _mesa_IsQueryARB(GLuint id) GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END_WITH_RETVAL(ctx, GL_FALSE); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glIsQuery(%u)\n", id); + if (id && _mesa_lookup_query_object(ctx, id)) return GL_TRUE; else @@ -254,6 +271,10 @@ _mesa_BeginQueryARB(GLenum target, GLuint id) GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glBeginQuery(%s, %u)\n", + _mesa_lookup_enum_by_nr(target), id); + FLUSH_VERTICES(ctx, _NEW_DEPTH); bindpt = get_query_binding_point(ctx, target); @@ -305,6 +326,9 @@ _mesa_EndQueryARB(GLenum target) GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glEndQuery(%s)\n", _mesa_lookup_enum_by_nr(target)); + FLUSH_VERTICES(ctx, _NEW_DEPTH); bindpt = get_query_binding_point(ctx, target); @@ -335,6 +359,11 @@ _mesa_GetQueryivARB(GLenum target, GLenum pname, GLint *params) GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glGetQueryiv(%s, %s)\n", + _mesa_lookup_enum_by_nr(target), + _mesa_lookup_enum_by_nr(pname)); + bindpt = get_query_binding_point(ctx, target); if (!bindpt) { _mesa_error(ctx, GL_INVALID_ENUM, "glGetQueryARB(target)"); @@ -364,6 +393,10 @@ _mesa_GetQueryObjectivARB(GLuint id, GLenum pname, GLint *params) GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glGetQueryObjectiv(%u, %s)\n", id, + _mesa_lookup_enum_by_nr(pname)); + if (id) q = _mesa_lookup_query_object(ctx, id); @@ -378,11 +411,18 @@ _mesa_GetQueryObjectivARB(GLuint id, GLenum pname, GLint *params) if (!q->Ready) ctx->Driver.WaitQuery(ctx, q); /* if result is too large for returned type, clamp to max value */ - if (q->Result > 0x7fffffff) { - *params = 0x7fffffff; - } - else { - *params = (GLint)q->Result; + if (q->Target == GL_ANY_SAMPLES_PASSED) { + if (q->Result) + *params = GL_TRUE; + else + *params = GL_FALSE; + } else { + if (q->Result > 0x7fffffff) { + *params = 0x7fffffff; + } + else { + *params = (GLint)q->Result; + } } break; case GL_QUERY_RESULT_AVAILABLE_ARB: @@ -404,6 +444,10 @@ _mesa_GetQueryObjectuivARB(GLuint id, GLenum pname, GLuint *params) GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glGetQueryObjectuiv(%u, %s)\n", id, + _mesa_lookup_enum_by_nr(pname)); + if (id) q = _mesa_lookup_query_object(ctx, id); @@ -418,11 +462,18 @@ _mesa_GetQueryObjectuivARB(GLuint id, GLenum pname, GLuint *params) if (!q->Ready) ctx->Driver.WaitQuery(ctx, q); /* if result is too large for returned type, clamp to max value */ - if (q->Result > 0xffffffff) { - *params = 0xffffffff; - } - else { - *params = (GLuint)q->Result; + if (q->Target == GL_ANY_SAMPLES_PASSED) { + if (q->Result) + *params = GL_TRUE; + else + *params = GL_FALSE; + } else { + if (q->Result > 0xffffffff) { + *params = 0xffffffff; + } + else { + *params = (GLuint)q->Result; + } } break; case GL_QUERY_RESULT_AVAILABLE_ARB: @@ -447,6 +498,10 @@ _mesa_GetQueryObjecti64vEXT(GLuint id, GLenum pname, GLint64EXT *params) GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glGetQueryObjecti64v(%u, %s)\n", id, + _mesa_lookup_enum_by_nr(pname)); + if (id) q = _mesa_lookup_query_object(ctx, id); @@ -484,6 +539,10 @@ _mesa_GetQueryObjectui64vEXT(GLuint id, GLenum pname, GLuint64EXT *params) GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glGetQueryObjectui64v(%u, %s)\n", id, + _mesa_lookup_enum_by_nr(pname)); + if (id) q = _mesa_lookup_query_object(ctx, id); diff --git a/src/mesa/main/queryobj.h b/src/mesa/main/queryobj.h index e289625731..e4ad96ba5a 100644 --- a/src/mesa/main/queryobj.h +++ b/src/mesa/main/queryobj.h @@ -27,6 +27,7 @@ #define QUERYOBJ_H +#include "main/mfeatures.h" #include "main/mtypes.h" #include "main/hash.h" diff --git a/src/mesa/main/rastpos.c b/src/mesa/main/rastpos.c index 6f52f07dfa..a1f6f42341 100644 --- a/src/mesa/main/rastpos.c +++ b/src/mesa/main/rastpos.c @@ -32,6 +32,8 @@ #include "context.h" #include "feedback.h" #include "macros.h" +#include "mfeatures.h" +#include "mtypes.h" #include "rastpos.h" #include "state.h" #include "main/dispatch.h" diff --git a/src/mesa/main/readpix.c b/src/mesa/main/readpix.c index a5612e34ec..6e09a52c88 100644 --- a/src/mesa/main/readpix.c +++ b/src/mesa/main/readpix.c @@ -26,10 +26,13 @@ #include "imports.h" #include "bufferobj.h" #include "context.h" +#include "enums.h" #include "readpix.h" #include "framebuffer.h" #include "formats.h" #include "image.h" +#include "mtypes.h" +#include "pbo.h" #include "state.h" @@ -172,6 +175,13 @@ _mesa_ReadPixels( GLint x, GLint y, GLsizei width, GLsizei height, FLUSH_CURRENT(ctx, 0); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glReadPixels(%d, %d, %s, %s, %p)\n", + width, height, + _mesa_lookup_enum_by_nr(format), + _mesa_lookup_enum_by_nr(type), + pixels); + if (width < 0 || height < 0) { _mesa_error( ctx, GL_INVALID_VALUE, "glReadPixels(width=%d height=%d)", width, height ); diff --git a/src/mesa/main/remap_helper.h b/src/mesa/main/remap_helper.h index 7368c76e7e..61530df3e1 100644 --- a/src/mesa/main/remap_helper.h +++ b/src/mesa/main/remap_helper.h @@ -70,4666 +70,4710 @@ static const char _mesa_function_pool[] = "\0" "glLoadIdentity\0" "\0" - /* _mesa_function_pool[216]: SampleCoverageARB (will be remapped) */ + /* _mesa_function_pool[216]: GetCombinerOutputParameterfvNV (will be remapped) */ + "iiip\0" + "glGetCombinerOutputParameterfvNV\0" + "\0" + /* _mesa_function_pool[255]: SampleCoverageARB (will be remapped) */ "fi\0" "glSampleCoverage\0" "glSampleCoverageARB\0" "\0" - /* _mesa_function_pool[257]: ConvolutionFilter1D (offset 348) */ + /* _mesa_function_pool[296]: ConvolutionFilter1D (offset 348) */ "iiiiip\0" "glConvolutionFilter1D\0" "glConvolutionFilter1DEXT\0" "\0" - /* _mesa_function_pool[312]: BeginQueryARB (will be remapped) */ + /* _mesa_function_pool[351]: BeginQueryARB (will be remapped) */ "ii\0" "glBeginQuery\0" "glBeginQueryARB\0" "\0" - /* _mesa_function_pool[345]: RasterPos3dv (offset 71) */ + /* _mesa_function_pool[384]: RasterPos3dv (offset 71) */ "p\0" "glRasterPos3dv\0" "\0" - /* _mesa_function_pool[363]: PointParameteriNV (will be remapped) */ + /* _mesa_function_pool[402]: PointParameteriNV (will be remapped) */ "ii\0" "glPointParameteri\0" "glPointParameteriNV\0" "\0" - /* _mesa_function_pool[405]: GetProgramiv (will be remapped) */ + /* _mesa_function_pool[444]: GetProgramiv (will be remapped) */ "iip\0" "glGetProgramiv\0" "\0" - /* _mesa_function_pool[425]: MultiTexCoord3sARB (offset 398) */ + /* _mesa_function_pool[464]: MultiTexCoord3sARB (offset 398) */ "iiii\0" "glMultiTexCoord3s\0" "glMultiTexCoord3sARB\0" "\0" - /* _mesa_function_pool[470]: SecondaryColor3iEXT (will be remapped) */ + /* _mesa_function_pool[509]: SecondaryColor3iEXT (will be remapped) */ "iii\0" "glSecondaryColor3i\0" "glSecondaryColor3iEXT\0" "\0" - /* _mesa_function_pool[516]: WindowPos3fMESA (will be remapped) */ + /* _mesa_function_pool[555]: WindowPos3fMESA (will be remapped) */ "fff\0" "glWindowPos3f\0" "glWindowPos3fARB\0" "glWindowPos3fMESA\0" "\0" - /* _mesa_function_pool[570]: TexCoord1iv (offset 99) */ + /* _mesa_function_pool[609]: TexCoord1iv (offset 99) */ "p\0" "glTexCoord1iv\0" "\0" - /* _mesa_function_pool[587]: TexCoord4sv (offset 125) */ + /* _mesa_function_pool[626]: TexCoord4sv (offset 125) */ "p\0" "glTexCoord4sv\0" "\0" - /* _mesa_function_pool[604]: RasterPos4s (offset 84) */ + /* _mesa_function_pool[643]: RasterPos4s (offset 84) */ "iiii\0" "glRasterPos4s\0" "\0" - /* _mesa_function_pool[624]: PixelTexGenParameterfvSGIS (will be remapped) */ + /* _mesa_function_pool[663]: PixelTexGenParameterfvSGIS (will be remapped) */ "ip\0" "glPixelTexGenParameterfvSGIS\0" "\0" - /* _mesa_function_pool[657]: ActiveTextureARB (offset 374) */ + /* _mesa_function_pool[696]: ActiveTextureARB (offset 374) */ "i\0" "glActiveTexture\0" "glActiveTextureARB\0" "\0" - /* _mesa_function_pool[695]: BlitFramebufferEXT (will be remapped) */ + /* _mesa_function_pool[734]: BlitFramebufferEXT (will be remapped) */ "iiiiiiiiii\0" "glBlitFramebuffer\0" "glBlitFramebufferEXT\0" "\0" - /* _mesa_function_pool[746]: TexCoord1f (offset 96) */ + /* _mesa_function_pool[785]: TexCoord1f (offset 96) */ "f\0" "glTexCoord1f\0" "\0" - /* _mesa_function_pool[762]: TexCoord1d (offset 94) */ + /* _mesa_function_pool[801]: TexCoord1d (offset 94) */ "d\0" "glTexCoord1d\0" "\0" - /* _mesa_function_pool[778]: VertexAttrib4ubvNV (will be remapped) */ + /* _mesa_function_pool[817]: VertexAttrib4ubvNV (will be remapped) */ "ip\0" "glVertexAttrib4ubvNV\0" "\0" - /* _mesa_function_pool[803]: TexCoord1i (offset 98) */ + /* _mesa_function_pool[842]: TexCoord1i (offset 98) */ "i\0" "glTexCoord1i\0" "\0" - /* _mesa_function_pool[819]: GetProgramNamedParameterdvNV (will be remapped) */ + /* _mesa_function_pool[858]: GetProgramNamedParameterdvNV (will be remapped) */ "iipp\0" "glGetProgramNamedParameterdvNV\0" "\0" - /* _mesa_function_pool[856]: Histogram (offset 367) */ + /* _mesa_function_pool[895]: Histogram (offset 367) */ "iiii\0" "glHistogram\0" "glHistogramEXT\0" "\0" - /* _mesa_function_pool[889]: TexCoord1s (offset 100) */ + /* _mesa_function_pool[928]: TexCoord1s (offset 100) */ "i\0" "glTexCoord1s\0" "\0" - /* _mesa_function_pool[905]: GetMapfv (offset 267) */ + /* _mesa_function_pool[944]: GetMapfv (offset 267) */ "iip\0" "glGetMapfv\0" "\0" - /* _mesa_function_pool[921]: EvalCoord1f (offset 230) */ + /* _mesa_function_pool[960]: EvalCoord1f (offset 230) */ "f\0" "glEvalCoord1f\0" "\0" - /* _mesa_function_pool[938]: FramebufferTexture (will be remapped) */ + /* _mesa_function_pool[977]: FramebufferTexture (will be remapped) */ "iiii\0" "glFramebufferTexture\0" "\0" - /* _mesa_function_pool[965]: VertexAttribI1ivEXT (will be remapped) */ + /* _mesa_function_pool[1004]: VertexAttribI1ivEXT (will be remapped) */ "ip\0" "glVertexAttribI1ivEXT\0" "glVertexAttribI1iv\0" "\0" - /* _mesa_function_pool[1010]: TexImage4DSGIS (dynamic) */ + /* _mesa_function_pool[1049]: TexImage4DSGIS (dynamic) */ "iiiiiiiiiip\0" "glTexImage4DSGIS\0" "\0" - /* _mesa_function_pool[1040]: PolygonStipple (offset 175) */ + /* _mesa_function_pool[1079]: PolygonStipple (offset 175) */ "p\0" "glPolygonStipple\0" "\0" - /* _mesa_function_pool[1060]: WindowPos2dvMESA (will be remapped) */ + /* _mesa_function_pool[1099]: WindowPos2dvMESA (will be remapped) */ "p\0" "glWindowPos2dv\0" "glWindowPos2dvARB\0" "glWindowPos2dvMESA\0" "\0" - /* _mesa_function_pool[1115]: ReplacementCodeuiColor3fVertex3fvSUN (dynamic) */ + /* _mesa_function_pool[1154]: ReplacementCodeuiColor3fVertex3fvSUN (dynamic) */ "ppp\0" "glReplacementCodeuiColor3fVertex3fvSUN\0" "\0" - /* _mesa_function_pool[1159]: BlendEquationSeparateEXT (will be remapped) */ + /* _mesa_function_pool[1198]: BlendEquationSeparateEXT (will be remapped) */ "ii\0" "glBlendEquationSeparate\0" "glBlendEquationSeparateEXT\0" "glBlendEquationSeparateATI\0" "\0" - /* _mesa_function_pool[1241]: ListParameterfSGIX (dynamic) */ + /* _mesa_function_pool[1280]: ListParameterfSGIX (dynamic) */ "iif\0" "glListParameterfSGIX\0" "\0" - /* _mesa_function_pool[1267]: SecondaryColor3bEXT (will be remapped) */ + /* _mesa_function_pool[1306]: SecondaryColor3bEXT (will be remapped) */ "iii\0" "glSecondaryColor3b\0" "glSecondaryColor3bEXT\0" "\0" - /* _mesa_function_pool[1313]: TexCoord4fColor4fNormal3fVertex4fvSUN (dynamic) */ + /* _mesa_function_pool[1352]: TexCoord4fColor4fNormal3fVertex4fvSUN (dynamic) */ "pppp\0" "glTexCoord4fColor4fNormal3fVertex4fvSUN\0" "\0" - /* _mesa_function_pool[1359]: GetPixelMapfv (offset 271) */ + /* _mesa_function_pool[1398]: GetPixelMapfv (offset 271) */ "ip\0" "glGetPixelMapfv\0" "\0" - /* _mesa_function_pool[1379]: Color3uiv (offset 22) */ + /* _mesa_function_pool[1418]: Color3uiv (offset 22) */ "p\0" "glColor3uiv\0" "\0" - /* _mesa_function_pool[1394]: IsEnabled (offset 286) */ + /* _mesa_function_pool[1433]: IsEnabled (offset 286) */ "i\0" "glIsEnabled\0" "\0" - /* _mesa_function_pool[1409]: VertexAttrib4svNV (will be remapped) */ + /* _mesa_function_pool[1448]: VertexAttrib4svNV (will be remapped) */ "ip\0" "glVertexAttrib4svNV\0" "\0" - /* _mesa_function_pool[1433]: EvalCoord2fv (offset 235) */ + /* _mesa_function_pool[1472]: EvalCoord2fv (offset 235) */ "p\0" "glEvalCoord2fv\0" "\0" - /* _mesa_function_pool[1451]: GetBufferSubDataARB (will be remapped) */ + /* _mesa_function_pool[1490]: GetBufferSubDataARB (will be remapped) */ "iiip\0" "glGetBufferSubData\0" "glGetBufferSubDataARB\0" "\0" - /* _mesa_function_pool[1498]: BufferSubDataARB (will be remapped) */ + /* _mesa_function_pool[1537]: BufferSubDataARB (will be remapped) */ "iiip\0" "glBufferSubData\0" "glBufferSubDataARB\0" "\0" - /* _mesa_function_pool[1539]: TexCoord2fColor4ubVertex3fvSUN (dynamic) */ + /* _mesa_function_pool[1578]: TexCoord2fColor4ubVertex3fvSUN (dynamic) */ "ppp\0" "glTexCoord2fColor4ubVertex3fvSUN\0" "\0" - /* _mesa_function_pool[1577]: AttachShader (will be remapped) */ + /* _mesa_function_pool[1616]: AttachShader (will be remapped) */ "ii\0" "glAttachShader\0" "\0" - /* _mesa_function_pool[1596]: VertexAttrib2fARB (will be remapped) */ + /* _mesa_function_pool[1635]: VertexAttrib2fARB (will be remapped) */ "iff\0" "glVertexAttrib2f\0" "glVertexAttrib2fARB\0" "\0" - /* _mesa_function_pool[1638]: GetDebugLogLengthMESA (dynamic) */ + /* _mesa_function_pool[1677]: GetDebugLogLengthMESA (dynamic) */ "iii\0" "glGetDebugLogLengthMESA\0" "\0" - /* _mesa_function_pool[1667]: GetMapiv (offset 268) */ + /* _mesa_function_pool[1706]: GetMapiv (offset 268) */ "iip\0" "glGetMapiv\0" "\0" - /* _mesa_function_pool[1683]: VertexAttrib3fARB (will be remapped) */ + /* _mesa_function_pool[1722]: VertexAttrib3fARB (will be remapped) */ "ifff\0" "glVertexAttrib3f\0" "glVertexAttrib3fARB\0" "\0" - /* _mesa_function_pool[1726]: Indexubv (offset 316) */ + /* _mesa_function_pool[1765]: Indexubv (offset 316) */ "p\0" "glIndexubv\0" "\0" - /* _mesa_function_pool[1740]: GetQueryivARB (will be remapped) */ + /* _mesa_function_pool[1779]: GetQueryivARB (will be remapped) */ "iip\0" "glGetQueryiv\0" "glGetQueryivARB\0" "\0" - /* _mesa_function_pool[1774]: TexImage3D (offset 371) */ + /* _mesa_function_pool[1813]: TexImage3D (offset 371) */ "iiiiiiiiip\0" "glTexImage3D\0" "glTexImage3DEXT\0" "\0" - /* _mesa_function_pool[1815]: BindFragDataLocationEXT (will be remapped) */ + /* _mesa_function_pool[1854]: BindFragDataLocationEXT (will be remapped) */ "iip\0" "glBindFragDataLocationEXT\0" "glBindFragDataLocation\0" "\0" - /* _mesa_function_pool[1869]: ReplacementCodeuiVertex3fvSUN (dynamic) */ + /* _mesa_function_pool[1908]: ReplacementCodeuiVertex3fvSUN (dynamic) */ "pp\0" "glReplacementCodeuiVertex3fvSUN\0" "\0" - /* _mesa_function_pool[1905]: EdgeFlagPointer (offset 312) */ + /* _mesa_function_pool[1944]: EdgeFlagPointer (offset 312) */ "ip\0" "glEdgeFlagPointer\0" "\0" - /* _mesa_function_pool[1927]: Color3ubv (offset 20) */ + /* _mesa_function_pool[1966]: Color3ubv (offset 20) */ "p\0" "glColor3ubv\0" "\0" - /* _mesa_function_pool[1942]: GetQueryObjectivARB (will be remapped) */ + /* _mesa_function_pool[1981]: GetQueryObjectivARB (will be remapped) */ "iip\0" "glGetQueryObjectiv\0" "glGetQueryObjectivARB\0" "\0" - /* _mesa_function_pool[1988]: Vertex3dv (offset 135) */ + /* _mesa_function_pool[2027]: Vertex3dv (offset 135) */ "p\0" "glVertex3dv\0" "\0" - /* _mesa_function_pool[2003]: ReplacementCodeuiTexCoord2fVertex3fvSUN (dynamic) */ + /* _mesa_function_pool[2042]: ReplacementCodeuiTexCoord2fVertex3fvSUN (dynamic) */ "ppp\0" "glReplacementCodeuiTexCoord2fVertex3fvSUN\0" "\0" - /* _mesa_function_pool[2050]: CompressedTexSubImage2DARB (will be remapped) */ + /* _mesa_function_pool[2089]: CompressedTexSubImage2DARB (will be remapped) */ "iiiiiiiip\0" "glCompressedTexSubImage2D\0" "glCompressedTexSubImage2DARB\0" "\0" - /* _mesa_function_pool[2116]: CombinerOutputNV (will be remapped) */ + /* _mesa_function_pool[2155]: CombinerOutputNV (will be remapped) */ "iiiiiiiiii\0" "glCombinerOutputNV\0" "\0" - /* _mesa_function_pool[2147]: VertexAttribs3fvNV (will be remapped) */ + /* _mesa_function_pool[2186]: VertexAttribs3fvNV (will be remapped) */ "iip\0" "glVertexAttribs3fvNV\0" "\0" - /* _mesa_function_pool[2173]: Uniform2fARB (will be remapped) */ + /* _mesa_function_pool[2212]: Uniform2fARB (will be remapped) */ "iff\0" "glUniform2f\0" "glUniform2fARB\0" "\0" - /* _mesa_function_pool[2205]: LightModeliv (offset 166) */ + /* _mesa_function_pool[2244]: LightModeliv (offset 166) */ "ip\0" "glLightModeliv\0" "\0" - /* _mesa_function_pool[2224]: VertexAttrib1svARB (will be remapped) */ + /* _mesa_function_pool[2263]: VertexAttrib1svARB (will be remapped) */ "ip\0" "glVertexAttrib1sv\0" "glVertexAttrib1svARB\0" "\0" - /* _mesa_function_pool[2267]: VertexAttribs1dvNV (will be remapped) */ + /* _mesa_function_pool[2306]: VertexAttribs1dvNV (will be remapped) */ "iip\0" "glVertexAttribs1dvNV\0" "\0" - /* _mesa_function_pool[2293]: Uniform2ivARB (will be remapped) */ + /* _mesa_function_pool[2332]: Uniform2ivARB (will be remapped) */ "iip\0" "glUniform2iv\0" "glUniform2ivARB\0" "\0" - /* _mesa_function_pool[2327]: GetImageTransformParameterfvHP (dynamic) */ + /* _mesa_function_pool[2366]: GetImageTransformParameterfvHP (dynamic) */ "iip\0" "glGetImageTransformParameterfvHP\0" "\0" - /* _mesa_function_pool[2365]: Normal3bv (offset 53) */ + /* _mesa_function_pool[2404]: Normal3bv (offset 53) */ "p\0" "glNormal3bv\0" "\0" - /* _mesa_function_pool[2380]: TexGeniv (offset 193) */ + /* _mesa_function_pool[2419]: TexGeniv (offset 193) */ "iip\0" "glTexGeniv\0" "\0" - /* _mesa_function_pool[2396]: WeightubvARB (dynamic) */ + /* _mesa_function_pool[2435]: WeightubvARB (dynamic) */ "ip\0" "glWeightubvARB\0" "\0" - /* _mesa_function_pool[2415]: VertexAttrib1fvNV (will be remapped) */ + /* _mesa_function_pool[2454]: VertexAttrib1fvNV (will be remapped) */ "ip\0" "glVertexAttrib1fvNV\0" "\0" - /* _mesa_function_pool[2439]: Vertex3iv (offset 139) */ + /* _mesa_function_pool[2478]: Vertex3iv (offset 139) */ "p\0" "glVertex3iv\0" "\0" - /* _mesa_function_pool[2454]: CopyConvolutionFilter1D (offset 354) */ + /* _mesa_function_pool[2493]: CopyConvolutionFilter1D (offset 354) */ "iiiii\0" "glCopyConvolutionFilter1D\0" "glCopyConvolutionFilter1DEXT\0" "\0" - /* _mesa_function_pool[2516]: VertexAttribI1uiEXT (will be remapped) */ + /* _mesa_function_pool[2555]: VertexAttribI1uiEXT (will be remapped) */ "ii\0" "glVertexAttribI1uiEXT\0" "glVertexAttribI1ui\0" "\0" - /* _mesa_function_pool[2561]: ReplacementCodeuiNormal3fVertex3fSUN (dynamic) */ + /* _mesa_function_pool[2600]: ReplacementCodeuiNormal3fVertex3fSUN (dynamic) */ "iffffff\0" "glReplacementCodeuiNormal3fVertex3fSUN\0" "\0" - /* _mesa_function_pool[2609]: DeleteSync (will be remapped) */ + /* _mesa_function_pool[2648]: DeleteSync (will be remapped) */ "i\0" "glDeleteSync\0" "\0" - /* _mesa_function_pool[2625]: FragmentMaterialfvSGIX (dynamic) */ + /* _mesa_function_pool[2664]: FragmentMaterialfvSGIX (dynamic) */ "iip\0" "glFragmentMaterialfvSGIX\0" "\0" - /* _mesa_function_pool[2655]: BlendColor (offset 336) */ + /* _mesa_function_pool[2694]: BlendColor (offset 336) */ "ffff\0" "glBlendColor\0" "glBlendColorEXT\0" "\0" - /* _mesa_function_pool[2690]: UniformMatrix4fvARB (will be remapped) */ + /* _mesa_function_pool[2729]: UniformMatrix4fvARB (will be remapped) */ "iiip\0" "glUniformMatrix4fv\0" "glUniformMatrix4fvARB\0" "\0" - /* _mesa_function_pool[2737]: DeleteVertexArraysAPPLE (will be remapped) */ + /* _mesa_function_pool[2776]: DeleteVertexArraysAPPLE (will be remapped) */ "ip\0" "glDeleteVertexArrays\0" "glDeleteVertexArraysAPPLE\0" "\0" - /* _mesa_function_pool[2788]: TexBuffer (will be remapped) */ + /* _mesa_function_pool[2827]: TexBuffer (will be remapped) */ "iii\0" "glTexBuffer\0" "\0" - /* _mesa_function_pool[2805]: ReadInstrumentsSGIX (dynamic) */ + /* _mesa_function_pool[2844]: ReadInstrumentsSGIX (dynamic) */ "i\0" "glReadInstrumentsSGIX\0" "\0" - /* _mesa_function_pool[2830]: CallLists (offset 3) */ + /* _mesa_function_pool[2869]: CallLists (offset 3) */ "iip\0" "glCallLists\0" "\0" - /* _mesa_function_pool[2847]: UniformMatrix2x4fv (will be remapped) */ + /* _mesa_function_pool[2886]: UniformMatrix2x4fv (will be remapped) */ "iiip\0" "glUniformMatrix2x4fv\0" "\0" - /* _mesa_function_pool[2874]: Color4ubVertex3fvSUN (dynamic) */ + /* _mesa_function_pool[2913]: Color4ubVertex3fvSUN (dynamic) */ "pp\0" "glColor4ubVertex3fvSUN\0" "\0" - /* _mesa_function_pool[2901]: Normal3iv (offset 59) */ + /* _mesa_function_pool[2940]: Normal3iv (offset 59) */ "p\0" "glNormal3iv\0" "\0" - /* _mesa_function_pool[2916]: PassThrough (offset 199) */ + /* _mesa_function_pool[2955]: PassThrough (offset 199) */ "f\0" "glPassThrough\0" "\0" - /* _mesa_function_pool[2933]: GetVertexAttribIivEXT (will be remapped) */ + /* _mesa_function_pool[2972]: GetVertexAttribIivEXT (will be remapped) */ "iip\0" "glGetVertexAttribIivEXT\0" "glGetVertexAttribIiv\0" "\0" - /* _mesa_function_pool[2983]: TexParameterIivEXT (will be remapped) */ + /* _mesa_function_pool[3022]: TexParameterIivEXT (will be remapped) */ "iip\0" "glTexParameterIivEXT\0" "glTexParameterIiv\0" "\0" - /* _mesa_function_pool[3027]: FramebufferTextureLayerEXT (will be remapped) */ + /* _mesa_function_pool[3066]: FramebufferTextureLayerEXT (will be remapped) */ "iiiii\0" "glFramebufferTextureLayer\0" "glFramebufferTextureLayerEXT\0" "\0" - /* _mesa_function_pool[3089]: GetListParameterfvSGIX (dynamic) */ + /* _mesa_function_pool[3128]: GetListParameterfvSGIX (dynamic) */ "iip\0" "glGetListParameterfvSGIX\0" "\0" - /* _mesa_function_pool[3119]: Viewport (offset 305) */ + /* _mesa_function_pool[3158]: Viewport (offset 305) */ "iiii\0" "glViewport\0" "\0" - /* _mesa_function_pool[3136]: VertexAttrib4NusvARB (will be remapped) */ + /* _mesa_function_pool[3175]: VertexAttrib4NusvARB (will be remapped) */ "ip\0" "glVertexAttrib4Nusv\0" "glVertexAttrib4NusvARB\0" "\0" - /* _mesa_function_pool[3183]: WindowPos4svMESA (will be remapped) */ + /* _mesa_function_pool[3222]: WindowPos4svMESA (will be remapped) */ "p\0" "glWindowPos4svMESA\0" "\0" - /* _mesa_function_pool[3205]: CreateProgramObjectARB (will be remapped) */ + /* _mesa_function_pool[3244]: CreateProgramObjectARB (will be remapped) */ "\0" "glCreateProgramObjectARB\0" "\0" - /* _mesa_function_pool[3232]: DeleteTransformFeedbacks (will be remapped) */ + /* _mesa_function_pool[3271]: DeleteTransformFeedbacks (will be remapped) */ "ip\0" "glDeleteTransformFeedbacks\0" "\0" - /* _mesa_function_pool[3263]: UniformMatrix4x3fv (will be remapped) */ + /* _mesa_function_pool[3302]: UniformMatrix4x3fv (will be remapped) */ "iiip\0" "glUniformMatrix4x3fv\0" "\0" - /* _mesa_function_pool[3290]: PrioritizeTextures (offset 331) */ + /* _mesa_function_pool[3329]: PrioritizeTextures (offset 331) */ "ipp\0" "glPrioritizeTextures\0" "glPrioritizeTexturesEXT\0" "\0" - /* _mesa_function_pool[3340]: VertexAttribI3uiEXT (will be remapped) */ + /* _mesa_function_pool[3379]: VertexAttribI3uiEXT (will be remapped) */ "iiii\0" "glVertexAttribI3uiEXT\0" "glVertexAttribI3ui\0" "\0" - /* _mesa_function_pool[3387]: AsyncMarkerSGIX (dynamic) */ + /* _mesa_function_pool[3426]: AsyncMarkerSGIX (dynamic) */ "i\0" "glAsyncMarkerSGIX\0" "\0" - /* _mesa_function_pool[3408]: GlobalAlphaFactorubSUN (dynamic) */ + /* _mesa_function_pool[3447]: GlobalAlphaFactorubSUN (dynamic) */ "i\0" "glGlobalAlphaFactorubSUN\0" "\0" - /* _mesa_function_pool[3436]: ClearColorIuiEXT (will be remapped) */ + /* _mesa_function_pool[3475]: ClearColorIuiEXT (will be remapped) */ "iiii\0" "glClearColorIuiEXT\0" "\0" - /* _mesa_function_pool[3461]: ClearDebugLogMESA (dynamic) */ + /* _mesa_function_pool[3500]: ClearDebugLogMESA (dynamic) */ "iii\0" "glClearDebugLogMESA\0" "\0" - /* _mesa_function_pool[3486]: Uniform4uiEXT (will be remapped) */ + /* _mesa_function_pool[3525]: Uniform4uiEXT (will be remapped) */ "iiiii\0" "glUniform4uiEXT\0" "glUniform4ui\0" "\0" - /* _mesa_function_pool[3522]: ResetHistogram (offset 369) */ + /* _mesa_function_pool[3561]: ResetHistogram (offset 369) */ "i\0" "glResetHistogram\0" "glResetHistogramEXT\0" "\0" - /* _mesa_function_pool[3562]: GetProgramNamedParameterfvNV (will be remapped) */ + /* _mesa_function_pool[3601]: GetProgramNamedParameterfvNV (will be remapped) */ "iipp\0" "glGetProgramNamedParameterfvNV\0" "\0" - /* _mesa_function_pool[3599]: PointParameterfEXT (will be remapped) */ + /* _mesa_function_pool[3638]: PointParameterfEXT (will be remapped) */ "if\0" "glPointParameterf\0" "glPointParameterfARB\0" "glPointParameterfEXT\0" "glPointParameterfSGIS\0" "\0" - /* _mesa_function_pool[3685]: LoadIdentityDeformationMapSGIX (dynamic) */ + /* _mesa_function_pool[3724]: LoadIdentityDeformationMapSGIX (dynamic) */ "i\0" "glLoadIdentityDeformationMapSGIX\0" "\0" - /* _mesa_function_pool[3721]: GenFencesNV (will be remapped) */ + /* _mesa_function_pool[3760]: GenFencesNV (will be remapped) */ "ip\0" "glGenFencesNV\0" "\0" - /* _mesa_function_pool[3739]: ImageTransformParameterfHP (dynamic) */ + /* _mesa_function_pool[3778]: ImageTransformParameterfHP (dynamic) */ "iif\0" "glImageTransformParameterfHP\0" "\0" - /* _mesa_function_pool[3773]: MatrixIndexusvARB (dynamic) */ + /* _mesa_function_pool[3812]: MatrixIndexusvARB (dynamic) */ "ip\0" "glMatrixIndexusvARB\0" "\0" - /* _mesa_function_pool[3797]: DrawElementsBaseVertex (will be remapped) */ + /* _mesa_function_pool[3836]: DrawElementsBaseVertex (will be remapped) */ "iiipi\0" "glDrawElementsBaseVertex\0" "\0" - /* _mesa_function_pool[3829]: DisableVertexAttribArrayARB (will be remapped) */ + /* _mesa_function_pool[3868]: DisableVertexAttribArrayARB (will be remapped) */ "i\0" "glDisableVertexAttribArray\0" "glDisableVertexAttribArrayARB\0" "\0" - /* _mesa_function_pool[3889]: TexCoord2sv (offset 109) */ + /* _mesa_function_pool[3928]: TexCoord2sv (offset 109) */ "p\0" "glTexCoord2sv\0" "\0" - /* _mesa_function_pool[3906]: Vertex4dv (offset 143) */ + /* _mesa_function_pool[3945]: Vertex4dv (offset 143) */ "p\0" "glVertex4dv\0" "\0" - /* _mesa_function_pool[3921]: StencilMaskSeparate (will be remapped) */ + /* _mesa_function_pool[3960]: StencilMaskSeparate (will be remapped) */ "ii\0" "glStencilMaskSeparate\0" "\0" - /* _mesa_function_pool[3947]: ProgramLocalParameter4dARB (will be remapped) */ + /* _mesa_function_pool[3986]: ProgramLocalParameter4dARB (will be remapped) */ "iidddd\0" "glProgramLocalParameter4dARB\0" "\0" - /* _mesa_function_pool[3984]: CompressedTexImage3DARB (will be remapped) */ + /* _mesa_function_pool[4023]: CompressedTexImage3DARB (will be remapped) */ "iiiiiiiip\0" "glCompressedTexImage3D\0" "glCompressedTexImage3DARB\0" "\0" - /* _mesa_function_pool[4044]: Color3sv (offset 18) */ + /* _mesa_function_pool[4083]: Color3sv (offset 18) */ "p\0" "glColor3sv\0" "\0" - /* _mesa_function_pool[4058]: GetConvolutionParameteriv (offset 358) */ + /* _mesa_function_pool[4097]: GetConvolutionParameteriv (offset 358) */ "iip\0" "glGetConvolutionParameteriv\0" "glGetConvolutionParameterivEXT\0" "\0" - /* _mesa_function_pool[4122]: VertexAttrib1fARB (will be remapped) */ + /* _mesa_function_pool[4161]: VertexAttrib1fARB (will be remapped) */ "if\0" "glVertexAttrib1f\0" "glVertexAttrib1fARB\0" "\0" - /* _mesa_function_pool[4163]: Vertex2dv (offset 127) */ + /* _mesa_function_pool[4202]: Vertex2dv (offset 127) */ "p\0" "glVertex2dv\0" "\0" - /* _mesa_function_pool[4178]: TestFenceNV (will be remapped) */ + /* _mesa_function_pool[4217]: TestFenceNV (will be remapped) */ "i\0" "glTestFenceNV\0" "\0" - /* _mesa_function_pool[4195]: GetVertexAttribIuivEXT (will be remapped) */ - "iip\0" - "glGetVertexAttribIuivEXT\0" - "glGetVertexAttribIuiv\0" - "\0" - /* _mesa_function_pool[4247]: MultiTexCoord1fvARB (offset 379) */ + /* _mesa_function_pool[4234]: MultiTexCoord1fvARB (offset 379) */ "ip\0" "glMultiTexCoord1fv\0" "glMultiTexCoord1fvARB\0" "\0" - /* _mesa_function_pool[4292]: TexCoord3iv (offset 115) */ + /* _mesa_function_pool[4279]: TexCoord3iv (offset 115) */ "p\0" "glTexCoord3iv\0" "\0" - /* _mesa_function_pool[4309]: Uniform2uivEXT (will be remapped) */ + /* _mesa_function_pool[4296]: Uniform2uivEXT (will be remapped) */ "iip\0" "glUniform2uivEXT\0" "glUniform2uiv\0" "\0" - /* _mesa_function_pool[4345]: ColorFragmentOp2ATI (will be remapped) */ + /* _mesa_function_pool[4332]: ColorFragmentOp2ATI (will be remapped) */ "iiiiiiiiii\0" "glColorFragmentOp2ATI\0" "\0" - /* _mesa_function_pool[4379]: SecondaryColorPointerListIBM (dynamic) */ + /* _mesa_function_pool[4366]: SecondaryColorPointerListIBM (dynamic) */ "iiipi\0" "glSecondaryColorPointerListIBM\0" "\0" - /* _mesa_function_pool[4417]: GetPixelTexGenParameterivSGIS (will be remapped) */ + /* _mesa_function_pool[4404]: GetPixelTexGenParameterivSGIS (will be remapped) */ "ip\0" "glGetPixelTexGenParameterivSGIS\0" "\0" - /* _mesa_function_pool[4453]: Color3fv (offset 14) */ + /* _mesa_function_pool[4440]: Color3fv (offset 14) */ "p\0" "glColor3fv\0" "\0" - /* _mesa_function_pool[4467]: VertexAttrib4fNV (will be remapped) */ + /* _mesa_function_pool[4454]: VertexAttrib4fNV (will be remapped) */ "iffff\0" "glVertexAttrib4fNV\0" "\0" - /* _mesa_function_pool[4493]: ReplacementCodeubSUN (dynamic) */ + /* _mesa_function_pool[4480]: ReplacementCodeubSUN (dynamic) */ "i\0" "glReplacementCodeubSUN\0" "\0" - /* _mesa_function_pool[4519]: FinishAsyncSGIX (dynamic) */ + /* _mesa_function_pool[4506]: FinishAsyncSGIX (dynamic) */ "p\0" "glFinishAsyncSGIX\0" "\0" - /* _mesa_function_pool[4540]: GetDebugLogMESA (dynamic) */ + /* _mesa_function_pool[4527]: GetDebugLogMESA (dynamic) */ "iiiipp\0" "glGetDebugLogMESA\0" "\0" - /* _mesa_function_pool[4566]: FogCoorddEXT (will be remapped) */ + /* _mesa_function_pool[4553]: FogCoorddEXT (will be remapped) */ "d\0" "glFogCoordd\0" "glFogCoorddEXT\0" "\0" - /* _mesa_function_pool[4596]: BeginConditionalRenderNV (will be remapped) */ + /* _mesa_function_pool[4583]: BeginConditionalRenderNV (will be remapped) */ "ii\0" "glBeginConditionalRenderNV\0" "glBeginConditionalRender\0" "\0" - /* _mesa_function_pool[4652]: Color4ubVertex3fSUN (dynamic) */ + /* _mesa_function_pool[4639]: Color4ubVertex3fSUN (dynamic) */ "iiiifff\0" "glColor4ubVertex3fSUN\0" "\0" - /* _mesa_function_pool[4683]: FogCoordfEXT (will be remapped) */ + /* _mesa_function_pool[4670]: FogCoordfEXT (will be remapped) */ "f\0" "glFogCoordf\0" "glFogCoordfEXT\0" "\0" - /* _mesa_function_pool[4713]: PointSize (offset 173) */ + /* _mesa_function_pool[4700]: PointSize (offset 173) */ "f\0" "glPointSize\0" "\0" - /* _mesa_function_pool[4728]: VertexAttribI2uivEXT (will be remapped) */ + /* _mesa_function_pool[4715]: VertexAttribI2uivEXT (will be remapped) */ "ip\0" "glVertexAttribI2uivEXT\0" "glVertexAttribI2uiv\0" "\0" - /* _mesa_function_pool[4775]: TexCoord2fVertex3fSUN (dynamic) */ + /* _mesa_function_pool[4762]: TexCoord2fVertex3fSUN (dynamic) */ "fffff\0" "glTexCoord2fVertex3fSUN\0" "\0" - /* _mesa_function_pool[4806]: PopName (offset 200) */ + /* _mesa_function_pool[4793]: PopName (offset 200) */ "\0" "glPopName\0" "\0" - /* _mesa_function_pool[4818]: GlobalAlphaFactoriSUN (dynamic) */ + /* _mesa_function_pool[4805]: GlobalAlphaFactoriSUN (dynamic) */ "i\0" "glGlobalAlphaFactoriSUN\0" "\0" - /* _mesa_function_pool[4845]: VertexAttrib2dNV (will be remapped) */ + /* _mesa_function_pool[4832]: VertexAttrib2dNV (will be remapped) */ "idd\0" "glVertexAttrib2dNV\0" "\0" - /* _mesa_function_pool[4869]: GetProgramInfoLog (will be remapped) */ + /* _mesa_function_pool[4856]: GetProgramInfoLog (will be remapped) */ "iipp\0" "glGetProgramInfoLog\0" "\0" - /* _mesa_function_pool[4895]: VertexAttrib4NbvARB (will be remapped) */ + /* _mesa_function_pool[4882]: VertexAttrib4NbvARB (will be remapped) */ "ip\0" "glVertexAttrib4Nbv\0" "glVertexAttrib4NbvARB\0" "\0" - /* _mesa_function_pool[4940]: GetActiveAttribARB (will be remapped) */ + /* _mesa_function_pool[4927]: GetActiveAttribARB (will be remapped) */ "iiipppp\0" "glGetActiveAttrib\0" "glGetActiveAttribARB\0" "\0" - /* _mesa_function_pool[4988]: Vertex4sv (offset 149) */ + /* _mesa_function_pool[4975]: Vertex4sv (offset 149) */ "p\0" "glVertex4sv\0" "\0" - /* _mesa_function_pool[5003]: VertexAttrib4ubNV (will be remapped) */ + /* _mesa_function_pool[4990]: VertexAttrib4ubNV (will be remapped) */ "iiiii\0" "glVertexAttrib4ubNV\0" "\0" - /* _mesa_function_pool[5030]: ClampColor (will be remapped) */ + /* _mesa_function_pool[5017]: ClampColor (will be remapped) */ "ii\0" "glClampColor\0" "\0" - /* _mesa_function_pool[5047]: TextureRangeAPPLE (will be remapped) */ + /* _mesa_function_pool[5034]: TextureRangeAPPLE (will be remapped) */ "iip\0" "glTextureRangeAPPLE\0" "\0" - /* _mesa_function_pool[5072]: GetTexEnvfv (offset 276) */ + /* _mesa_function_pool[5059]: GetTexEnvfv (offset 276) */ "iip\0" "glGetTexEnvfv\0" "\0" - /* _mesa_function_pool[5091]: BindTransformFeedback (will be remapped) */ + /* _mesa_function_pool[5078]: BindTransformFeedback (will be remapped) */ "ii\0" "glBindTransformFeedback\0" "\0" - /* _mesa_function_pool[5119]: TexCoord2fColor4fNormal3fVertex3fSUN (dynamic) */ + /* _mesa_function_pool[5106]: TexCoord2fColor4fNormal3fVertex3fSUN (dynamic) */ "ffffffffffff\0" "glTexCoord2fColor4fNormal3fVertex3fSUN\0" "\0" - /* _mesa_function_pool[5172]: Indexub (offset 315) */ + /* _mesa_function_pool[5159]: Indexub (offset 315) */ "i\0" "glIndexub\0" "\0" - /* _mesa_function_pool[5185]: TexEnvi (offset 186) */ + /* _mesa_function_pool[5172]: ColorMaskIndexedEXT (will be remapped) */ + "iiiii\0" + "glColorMaskIndexedEXT\0" + "glColorMaski\0" + "\0" + /* _mesa_function_pool[5214]: TexEnvi (offset 186) */ "iii\0" "glTexEnvi\0" "\0" - /* _mesa_function_pool[5200]: GetClipPlane (offset 259) */ + /* _mesa_function_pool[5229]: GetClipPlane (offset 259) */ "ip\0" "glGetClipPlane\0" "\0" - /* _mesa_function_pool[5219]: CombinerParameterfvNV (will be remapped) */ + /* _mesa_function_pool[5248]: CombinerParameterfvNV (will be remapped) */ "ip\0" "glCombinerParameterfvNV\0" "\0" - /* _mesa_function_pool[5247]: VertexAttribs3dvNV (will be remapped) */ + /* _mesa_function_pool[5276]: VertexAttribs3dvNV (will be remapped) */ "iip\0" "glVertexAttribs3dvNV\0" "\0" - /* _mesa_function_pool[5273]: VertexAttribI2uiEXT (will be remapped) */ + /* _mesa_function_pool[5302]: VertexAttribI2uiEXT (will be remapped) */ "iii\0" "glVertexAttribI2uiEXT\0" "glVertexAttribI2ui\0" "\0" - /* _mesa_function_pool[5319]: VertexAttribs4fvNV (will be remapped) */ + /* _mesa_function_pool[5348]: VertexAttribs4fvNV (will be remapped) */ "iip\0" "glVertexAttribs4fvNV\0" "\0" - /* _mesa_function_pool[5345]: VertexArrayRangeNV (will be remapped) */ + /* _mesa_function_pool[5374]: VertexArrayRangeNV (will be remapped) */ "ip\0" "glVertexArrayRangeNV\0" "\0" - /* _mesa_function_pool[5370]: FragmentLightiSGIX (dynamic) */ + /* _mesa_function_pool[5399]: FragmentLightiSGIX (dynamic) */ "iii\0" "glFragmentLightiSGIX\0" "\0" - /* _mesa_function_pool[5396]: PolygonOffsetEXT (will be remapped) */ + /* _mesa_function_pool[5425]: PolygonOffsetEXT (will be remapped) */ "ff\0" "glPolygonOffsetEXT\0" "\0" - /* _mesa_function_pool[5419]: VertexAttribI4uivEXT (will be remapped) */ + /* _mesa_function_pool[5448]: VertexAttribI4uivEXT (will be remapped) */ "ip\0" "glVertexAttribI4uivEXT\0" "glVertexAttribI4uiv\0" "\0" - /* _mesa_function_pool[5466]: PollAsyncSGIX (dynamic) */ + /* _mesa_function_pool[5495]: PollAsyncSGIX (dynamic) */ "p\0" "glPollAsyncSGIX\0" "\0" - /* _mesa_function_pool[5485]: DeleteFragmentShaderATI (will be remapped) */ + /* _mesa_function_pool[5514]: DeleteFragmentShaderATI (will be remapped) */ "i\0" "glDeleteFragmentShaderATI\0" "\0" - /* _mesa_function_pool[5514]: Scaled (offset 301) */ + /* _mesa_function_pool[5543]: Scaled (offset 301) */ "ddd\0" "glScaled\0" "\0" - /* _mesa_function_pool[5528]: ResumeTransformFeedback (will be remapped) */ + /* _mesa_function_pool[5557]: ResumeTransformFeedback (will be remapped) */ "\0" "glResumeTransformFeedback\0" "\0" - /* _mesa_function_pool[5556]: Scalef (offset 302) */ + /* _mesa_function_pool[5585]: Scalef (offset 302) */ "fff\0" "glScalef\0" "\0" - /* _mesa_function_pool[5570]: TexCoord2fNormal3fVertex3fvSUN (dynamic) */ + /* _mesa_function_pool[5599]: TexCoord2fNormal3fVertex3fvSUN (dynamic) */ "ppp\0" "glTexCoord2fNormal3fVertex3fvSUN\0" "\0" - /* _mesa_function_pool[5608]: MultTransposeMatrixdARB (will be remapped) */ + /* _mesa_function_pool[5637]: MultTransposeMatrixdARB (will be remapped) */ "p\0" "glMultTransposeMatrixd\0" "glMultTransposeMatrixdARB\0" "\0" - /* _mesa_function_pool[5660]: ColorMaskIndexedEXT (will be remapped) */ - "iiiii\0" - "glColorMaskIndexedEXT\0" - "glColorMaski\0" - "\0" - /* _mesa_function_pool[5702]: ObjectUnpurgeableAPPLE (will be remapped) */ + /* _mesa_function_pool[5689]: ObjectUnpurgeableAPPLE (will be remapped) */ "iii\0" "glObjectUnpurgeableAPPLE\0" "\0" - /* _mesa_function_pool[5732]: AlphaFunc (offset 240) */ + /* _mesa_function_pool[5719]: AlphaFunc (offset 240) */ "if\0" "glAlphaFunc\0" "\0" - /* _mesa_function_pool[5748]: WindowPos2svMESA (will be remapped) */ + /* _mesa_function_pool[5735]: WindowPos2svMESA (will be remapped) */ "p\0" "glWindowPos2sv\0" "glWindowPos2svARB\0" "glWindowPos2svMESA\0" "\0" - /* _mesa_function_pool[5803]: EdgeFlag (offset 41) */ + /* _mesa_function_pool[5790]: EdgeFlag (offset 41) */ "i\0" "glEdgeFlag\0" "\0" - /* _mesa_function_pool[5817]: TexCoord2iv (offset 107) */ + /* _mesa_function_pool[5804]: TexCoord2iv (offset 107) */ "p\0" "glTexCoord2iv\0" "\0" - /* _mesa_function_pool[5834]: CompressedTexImage1DARB (will be remapped) */ + /* _mesa_function_pool[5821]: CompressedTexImage1DARB (will be remapped) */ "iiiiiip\0" "glCompressedTexImage1D\0" "glCompressedTexImage1DARB\0" "\0" - /* _mesa_function_pool[5892]: Rotated (offset 299) */ + /* _mesa_function_pool[5879]: Rotated (offset 299) */ "dddd\0" "glRotated\0" "\0" - /* _mesa_function_pool[5908]: GetTexParameterIuivEXT (will be remapped) */ + /* _mesa_function_pool[5895]: GetTexParameterIuivEXT (will be remapped) */ "iip\0" "glGetTexParameterIuivEXT\0" "glGetTexParameterIuiv\0" "\0" - /* _mesa_function_pool[5960]: VertexAttrib2sNV (will be remapped) */ + /* _mesa_function_pool[5947]: VertexAttrib2sNV (will be remapped) */ "iii\0" "glVertexAttrib2sNV\0" "\0" - /* _mesa_function_pool[5984]: ReadPixels (offset 256) */ + /* _mesa_function_pool[5971]: ReadPixels (offset 256) */ "iiiiiip\0" "glReadPixels\0" "\0" - /* _mesa_function_pool[6006]: EdgeFlagv (offset 42) */ + /* _mesa_function_pool[5993]: EdgeFlagv (offset 42) */ "p\0" "glEdgeFlagv\0" "\0" - /* _mesa_function_pool[6021]: NormalPointerListIBM (dynamic) */ + /* _mesa_function_pool[6008]: NormalPointerListIBM (dynamic) */ "iipi\0" "glNormalPointerListIBM\0" "\0" - /* _mesa_function_pool[6050]: IndexPointerEXT (will be remapped) */ + /* _mesa_function_pool[6037]: IndexPointerEXT (will be remapped) */ "iiip\0" "glIndexPointerEXT\0" "\0" - /* _mesa_function_pool[6074]: Color4iv (offset 32) */ + /* _mesa_function_pool[6061]: Color4iv (offset 32) */ "p\0" "glColor4iv\0" "\0" - /* _mesa_function_pool[6088]: TexParameterf (offset 178) */ + /* _mesa_function_pool[6075]: TexParameterf (offset 178) */ "iif\0" "glTexParameterf\0" "\0" - /* _mesa_function_pool[6109]: TexParameteri (offset 180) */ + /* _mesa_function_pool[6096]: TexParameteri (offset 180) */ "iii\0" "glTexParameteri\0" "\0" - /* _mesa_function_pool[6130]: NormalPointerEXT (will be remapped) */ + /* _mesa_function_pool[6117]: NormalPointerEXT (will be remapped) */ "iiip\0" "glNormalPointerEXT\0" "\0" - /* _mesa_function_pool[6155]: MultiTexCoord3dARB (offset 392) */ + /* _mesa_function_pool[6142]: MultiTexCoord3dARB (offset 392) */ "iddd\0" "glMultiTexCoord3d\0" "glMultiTexCoord3dARB\0" "\0" - /* _mesa_function_pool[6200]: MultiTexCoord2iARB (offset 388) */ + /* _mesa_function_pool[6187]: MultiTexCoord2iARB (offset 388) */ "iii\0" "glMultiTexCoord2i\0" "glMultiTexCoord2iARB\0" "\0" - /* _mesa_function_pool[6244]: DrawPixels (offset 257) */ + /* _mesa_function_pool[6231]: DrawPixels (offset 257) */ "iiiip\0" "glDrawPixels\0" "\0" - /* _mesa_function_pool[6264]: ReplacementCodeuiTexCoord2fNormal3fVertex3fSUN (dynamic) */ + /* _mesa_function_pool[6251]: ReplacementCodeuiTexCoord2fNormal3fVertex3fSUN (dynamic) */ "iffffffff\0" "glReplacementCodeuiTexCoord2fNormal3fVertex3fSUN\0" "\0" - /* _mesa_function_pool[6324]: MultiTexCoord2svARB (offset 391) */ + /* _mesa_function_pool[6311]: MultiTexCoord2svARB (offset 391) */ "ip\0" "glMultiTexCoord2sv\0" "glMultiTexCoord2svARB\0" "\0" - /* _mesa_function_pool[6369]: ReplacementCodeubvSUN (dynamic) */ + /* _mesa_function_pool[6356]: ReplacementCodeubvSUN (dynamic) */ "p\0" "glReplacementCodeubvSUN\0" "\0" - /* _mesa_function_pool[6396]: Uniform3iARB (will be remapped) */ + /* _mesa_function_pool[6383]: Uniform3iARB (will be remapped) */ "iiii\0" "glUniform3i\0" "glUniform3iARB\0" "\0" - /* _mesa_function_pool[6429]: DrawTransformFeedback (will be remapped) */ + /* _mesa_function_pool[6416]: DrawTransformFeedback (will be remapped) */ "ii\0" "glDrawTransformFeedback\0" "\0" - /* _mesa_function_pool[6457]: DrawElementsInstancedARB (will be remapped) */ + /* _mesa_function_pool[6444]: DrawElementsInstancedARB (will be remapped) */ "iiipi\0" "glDrawElementsInstancedARB\0" "glDrawElementsInstancedEXT\0" "glDrawElementsInstanced\0" "\0" - /* _mesa_function_pool[6542]: GetShaderInfoLog (will be remapped) */ + /* _mesa_function_pool[6529]: GetShaderInfoLog (will be remapped) */ "iipp\0" "glGetShaderInfoLog\0" "\0" - /* _mesa_function_pool[6567]: WeightivARB (dynamic) */ + /* _mesa_function_pool[6554]: WeightivARB (dynamic) */ "ip\0" "glWeightivARB\0" "\0" - /* _mesa_function_pool[6585]: PollInstrumentsSGIX (dynamic) */ + /* _mesa_function_pool[6572]: PollInstrumentsSGIX (dynamic) */ "p\0" "glPollInstrumentsSGIX\0" "\0" - /* _mesa_function_pool[6610]: GlobalAlphaFactordSUN (dynamic) */ + /* _mesa_function_pool[6597]: GlobalAlphaFactordSUN (dynamic) */ "d\0" "glGlobalAlphaFactordSUN\0" "\0" - /* _mesa_function_pool[6637]: GetFinalCombinerInputParameterfvNV (will be remapped) */ + /* _mesa_function_pool[6624]: GetFinalCombinerInputParameterfvNV (will be remapped) */ "iip\0" "glGetFinalCombinerInputParameterfvNV\0" "\0" - /* _mesa_function_pool[6679]: GenerateMipmapEXT (will be remapped) */ + /* _mesa_function_pool[6666]: GenerateMipmapEXT (will be remapped) */ "i\0" "glGenerateMipmap\0" "glGenerateMipmapEXT\0" "\0" - /* _mesa_function_pool[6719]: GenLists (offset 5) */ + /* _mesa_function_pool[6706]: GenLists (offset 5) */ "i\0" "glGenLists\0" "\0" - /* _mesa_function_pool[6733]: SetFragmentShaderConstantATI (will be remapped) */ - "ip\0" - "glSetFragmentShaderConstantATI\0" + /* _mesa_function_pool[6720]: DepthRangef (will be remapped) */ + "ff\0" + "glDepthRangef\0" "\0" - /* _mesa_function_pool[6768]: GetMapAttribParameterivNV (dynamic) */ + /* _mesa_function_pool[6738]: GetMapAttribParameterivNV (dynamic) */ "iiip\0" "glGetMapAttribParameterivNV\0" "\0" - /* _mesa_function_pool[6802]: CreateShaderObjectARB (will be remapped) */ + /* _mesa_function_pool[6772]: CreateShaderObjectARB (will be remapped) */ "i\0" "glCreateShaderObjectARB\0" "\0" - /* _mesa_function_pool[6829]: GetSharpenTexFuncSGIS (dynamic) */ + /* _mesa_function_pool[6799]: GetSharpenTexFuncSGIS (dynamic) */ "ip\0" "glGetSharpenTexFuncSGIS\0" "\0" - /* _mesa_function_pool[6857]: BufferDataARB (will be remapped) */ + /* _mesa_function_pool[6827]: BufferDataARB (will be remapped) */ "iipi\0" "glBufferData\0" "glBufferDataARB\0" "\0" - /* _mesa_function_pool[6892]: FlushVertexArrayRangeNV (will be remapped) */ + /* _mesa_function_pool[6862]: FlushVertexArrayRangeNV (will be remapped) */ "\0" "glFlushVertexArrayRangeNV\0" "\0" - /* _mesa_function_pool[6920]: MapGrid2d (offset 226) */ + /* _mesa_function_pool[6890]: MapGrid2d (offset 226) */ "iddidd\0" "glMapGrid2d\0" "\0" - /* _mesa_function_pool[6940]: MapGrid2f (offset 227) */ + /* _mesa_function_pool[6910]: MapGrid2f (offset 227) */ "iffiff\0" "glMapGrid2f\0" "\0" - /* _mesa_function_pool[6960]: SampleMapATI (will be remapped) */ + /* _mesa_function_pool[6930]: SampleMapATI (will be remapped) */ "iii\0" "glSampleMapATI\0" "\0" - /* _mesa_function_pool[6980]: VertexPointerEXT (will be remapped) */ + /* _mesa_function_pool[6950]: VertexPointerEXT (will be remapped) */ "iiiip\0" "glVertexPointerEXT\0" "\0" - /* _mesa_function_pool[7006]: GetTexFilterFuncSGIS (dynamic) */ + /* _mesa_function_pool[6976]: GetTexFilterFuncSGIS (dynamic) */ "iip\0" "glGetTexFilterFuncSGIS\0" "\0" - /* _mesa_function_pool[7034]: Scissor (offset 176) */ + /* _mesa_function_pool[7004]: Scissor (offset 176) */ "iiii\0" "glScissor\0" "\0" - /* _mesa_function_pool[7050]: Fogf (offset 153) */ + /* _mesa_function_pool[7020]: Fogf (offset 153) */ "if\0" "glFogf\0" "\0" - /* _mesa_function_pool[7061]: ReplacementCodeuiColor4ubVertex3fvSUN (dynamic) */ + /* _mesa_function_pool[7031]: ReplacementCodeuiColor4ubVertex3fvSUN (dynamic) */ "ppp\0" "glReplacementCodeuiColor4ubVertex3fvSUN\0" "\0" - /* _mesa_function_pool[7106]: TexSubImage1D (offset 332) */ + /* _mesa_function_pool[7076]: TexSubImage1D (offset 332) */ "iiiiiip\0" "glTexSubImage1D\0" "glTexSubImage1DEXT\0" "\0" - /* _mesa_function_pool[7150]: VertexAttrib1sARB (will be remapped) */ + /* _mesa_function_pool[7120]: VertexAttrib1sARB (will be remapped) */ "ii\0" "glVertexAttrib1s\0" "glVertexAttrib1sARB\0" "\0" - /* _mesa_function_pool[7191]: FenceSync (will be remapped) */ + /* _mesa_function_pool[7161]: FenceSync (will be remapped) */ "ii\0" "glFenceSync\0" "\0" - /* _mesa_function_pool[7207]: Color4usv (offset 40) */ + /* _mesa_function_pool[7177]: Color4usv (offset 40) */ "p\0" "glColor4usv\0" "\0" - /* _mesa_function_pool[7222]: Fogi (offset 155) */ + /* _mesa_function_pool[7192]: Fogi (offset 155) */ "ii\0" "glFogi\0" "\0" - /* _mesa_function_pool[7233]: DepthRange (offset 288) */ + /* _mesa_function_pool[7203]: DepthRange (offset 288) */ "dd\0" "glDepthRange\0" "\0" - /* _mesa_function_pool[7250]: RasterPos3iv (offset 75) */ + /* _mesa_function_pool[7220]: RasterPos3iv (offset 75) */ "p\0" "glRasterPos3iv\0" "\0" - /* _mesa_function_pool[7268]: FinalCombinerInputNV (will be remapped) */ + /* _mesa_function_pool[7238]: FinalCombinerInputNV (will be remapped) */ "iiii\0" "glFinalCombinerInputNV\0" "\0" - /* _mesa_function_pool[7297]: TexCoord2i (offset 106) */ + /* _mesa_function_pool[7267]: TexCoord2i (offset 106) */ "ii\0" "glTexCoord2i\0" "\0" - /* _mesa_function_pool[7314]: PixelMapfv (offset 251) */ + /* _mesa_function_pool[7284]: PixelMapfv (offset 251) */ "iip\0" "glPixelMapfv\0" "\0" - /* _mesa_function_pool[7332]: Color4ui (offset 37) */ + /* _mesa_function_pool[7302]: Color4ui (offset 37) */ "iiii\0" "glColor4ui\0" "\0" - /* _mesa_function_pool[7349]: RasterPos3s (offset 76) */ + /* _mesa_function_pool[7319]: RasterPos3s (offset 76) */ "iii\0" "glRasterPos3s\0" "\0" - /* _mesa_function_pool[7368]: Color3usv (offset 24) */ + /* _mesa_function_pool[7338]: Color3usv (offset 24) */ "p\0" "glColor3usv\0" "\0" - /* _mesa_function_pool[7383]: FlushRasterSGIX (dynamic) */ + /* _mesa_function_pool[7353]: FlushRasterSGIX (dynamic) */ "\0" "glFlushRasterSGIX\0" "\0" - /* _mesa_function_pool[7403]: TexCoord2f (offset 104) */ + /* _mesa_function_pool[7373]: TexCoord2f (offset 104) */ "ff\0" "glTexCoord2f\0" "\0" - /* _mesa_function_pool[7420]: ReplacementCodeuiTexCoord2fVertex3fSUN (dynamic) */ + /* _mesa_function_pool[7390]: ReplacementCodeuiTexCoord2fVertex3fSUN (dynamic) */ "ifffff\0" "glReplacementCodeuiTexCoord2fVertex3fSUN\0" "\0" - /* _mesa_function_pool[7469]: TexCoord2d (offset 102) */ + /* _mesa_function_pool[7439]: TexCoord2d (offset 102) */ "dd\0" "glTexCoord2d\0" "\0" - /* _mesa_function_pool[7486]: RasterPos3d (offset 70) */ + /* _mesa_function_pool[7456]: RasterPos3d (offset 70) */ "ddd\0" "glRasterPos3d\0" "\0" - /* _mesa_function_pool[7505]: RasterPos3f (offset 72) */ + /* _mesa_function_pool[7475]: RasterPos3f (offset 72) */ "fff\0" "glRasterPos3f\0" "\0" - /* _mesa_function_pool[7524]: Uniform1fARB (will be remapped) */ + /* _mesa_function_pool[7494]: Uniform1fARB (will be remapped) */ "if\0" "glUniform1f\0" "glUniform1fARB\0" "\0" - /* _mesa_function_pool[7555]: AreTexturesResident (offset 322) */ + /* _mesa_function_pool[7525]: AreTexturesResident (offset 322) */ "ipp\0" "glAreTexturesResident\0" "glAreTexturesResidentEXT\0" "\0" - /* _mesa_function_pool[7607]: TexCoord2s (offset 108) */ + /* _mesa_function_pool[7577]: TexCoord2s (offset 108) */ "ii\0" "glTexCoord2s\0" "\0" - /* _mesa_function_pool[7624]: StencilOpSeparate (will be remapped) */ + /* _mesa_function_pool[7594]: StencilOpSeparate (will be remapped) */ "iiii\0" "glStencilOpSeparate\0" "glStencilOpSeparateATI\0" "\0" - /* _mesa_function_pool[7673]: ColorTableParameteriv (offset 341) */ + /* _mesa_function_pool[7643]: ColorTableParameteriv (offset 341) */ "iip\0" "glColorTableParameteriv\0" "glColorTableParameterivSGI\0" "\0" - /* _mesa_function_pool[7729]: FogCoordPointerListIBM (dynamic) */ + /* _mesa_function_pool[7699]: FogCoordPointerListIBM (dynamic) */ "iipi\0" "glFogCoordPointerListIBM\0" "\0" - /* _mesa_function_pool[7760]: WindowPos3dMESA (will be remapped) */ + /* _mesa_function_pool[7730]: WindowPos3dMESA (will be remapped) */ "ddd\0" "glWindowPos3d\0" "glWindowPos3dARB\0" "glWindowPos3dMESA\0" "\0" - /* _mesa_function_pool[7814]: Color4us (offset 39) */ + /* _mesa_function_pool[7784]: Color4us (offset 39) */ "iiii\0" "glColor4us\0" "\0" - /* _mesa_function_pool[7831]: PointParameterfvEXT (will be remapped) */ + /* _mesa_function_pool[7801]: PointParameterfvEXT (will be remapped) */ "ip\0" "glPointParameterfv\0" "glPointParameterfvARB\0" "glPointParameterfvEXT\0" "glPointParameterfvSGIS\0" "\0" - /* _mesa_function_pool[7921]: Color3bv (offset 10) */ + /* _mesa_function_pool[7891]: Color3bv (offset 10) */ "p\0" "glColor3bv\0" "\0" - /* _mesa_function_pool[7935]: WindowPos2fvMESA (will be remapped) */ + /* _mesa_function_pool[7905]: WindowPos2fvMESA (will be remapped) */ "p\0" "glWindowPos2fv\0" "glWindowPos2fvARB\0" "glWindowPos2fvMESA\0" "\0" - /* _mesa_function_pool[7990]: SecondaryColor3bvEXT (will be remapped) */ + /* _mesa_function_pool[7960]: SecondaryColor3bvEXT (will be remapped) */ "p\0" "glSecondaryColor3bv\0" "glSecondaryColor3bvEXT\0" "\0" - /* _mesa_function_pool[8036]: VertexPointerListIBM (dynamic) */ + /* _mesa_function_pool[8006]: VertexPointerListIBM (dynamic) */ "iiipi\0" "glVertexPointerListIBM\0" "\0" - /* _mesa_function_pool[8066]: GetProgramLocalParameterfvARB (will be remapped) */ + /* _mesa_function_pool[8036]: GetProgramLocalParameterfvARB (will be remapped) */ "iip\0" "glGetProgramLocalParameterfvARB\0" "\0" - /* _mesa_function_pool[8103]: FragmentMaterialfSGIX (dynamic) */ + /* _mesa_function_pool[8073]: FragmentMaterialfSGIX (dynamic) */ "iif\0" "glFragmentMaterialfSGIX\0" "\0" - /* _mesa_function_pool[8132]: TexCoord2fNormal3fVertex3fSUN (dynamic) */ + /* _mesa_function_pool[8102]: TexCoord2fNormal3fVertex3fSUN (dynamic) */ "ffffffff\0" "glTexCoord2fNormal3fVertex3fSUN\0" "\0" - /* _mesa_function_pool[8174]: RenderbufferStorageEXT (will be remapped) */ + /* _mesa_function_pool[8144]: RenderbufferStorageEXT (will be remapped) */ "iiii\0" "glRenderbufferStorage\0" "glRenderbufferStorageEXT\0" "\0" - /* _mesa_function_pool[8227]: IsFenceNV (will be remapped) */ + /* _mesa_function_pool[8197]: IsFenceNV (will be remapped) */ "i\0" "glIsFenceNV\0" "\0" - /* _mesa_function_pool[8242]: AttachObjectARB (will be remapped) */ + /* _mesa_function_pool[8212]: AttachObjectARB (will be remapped) */ "ii\0" "glAttachObjectARB\0" "\0" - /* _mesa_function_pool[8264]: GetFragmentLightivSGIX (dynamic) */ + /* _mesa_function_pool[8234]: GetFragmentLightivSGIX (dynamic) */ "iip\0" "glGetFragmentLightivSGIX\0" "\0" - /* _mesa_function_pool[8294]: UniformMatrix2fvARB (will be remapped) */ + /* _mesa_function_pool[8264]: UniformMatrix2fvARB (will be remapped) */ "iiip\0" "glUniformMatrix2fv\0" "glUniformMatrix2fvARB\0" "\0" - /* _mesa_function_pool[8341]: MultiTexCoord2fARB (offset 386) */ + /* _mesa_function_pool[8311]: MultiTexCoord2fARB (offset 386) */ "iff\0" "glMultiTexCoord2f\0" "glMultiTexCoord2fARB\0" "\0" - /* _mesa_function_pool[8385]: ColorTable (offset 339) */ + /* _mesa_function_pool[8355]: ColorTable (offset 339) */ "iiiiip\0" "glColorTable\0" "glColorTableSGI\0" "glColorTableEXT\0" "\0" - /* _mesa_function_pool[8438]: IndexPointer (offset 314) */ + /* _mesa_function_pool[8408]: IndexPointer (offset 314) */ "iip\0" "glIndexPointer\0" "\0" - /* _mesa_function_pool[8458]: Accum (offset 213) */ + /* _mesa_function_pool[8428]: Accum (offset 213) */ "if\0" "glAccum\0" "\0" - /* _mesa_function_pool[8470]: GetTexImage (offset 281) */ + /* _mesa_function_pool[8440]: GetTexImage (offset 281) */ "iiiip\0" "glGetTexImage\0" "\0" - /* _mesa_function_pool[8491]: MapControlPointsNV (dynamic) */ + /* _mesa_function_pool[8461]: MapControlPointsNV (dynamic) */ "iiiiiiiip\0" "glMapControlPointsNV\0" "\0" - /* _mesa_function_pool[8523]: ConvolutionFilter2D (offset 349) */ + /* _mesa_function_pool[8493]: ConvolutionFilter2D (offset 349) */ "iiiiiip\0" "glConvolutionFilter2D\0" "glConvolutionFilter2DEXT\0" "\0" - /* _mesa_function_pool[8579]: Finish (offset 216) */ + /* _mesa_function_pool[8549]: Finish (offset 216) */ "\0" "glFinish\0" "\0" - /* _mesa_function_pool[8590]: MapParameterfvNV (dynamic) */ + /* _mesa_function_pool[8560]: MapParameterfvNV (dynamic) */ "iip\0" "glMapParameterfvNV\0" "\0" - /* _mesa_function_pool[8614]: ClearStencil (offset 207) */ + /* _mesa_function_pool[8584]: ClearStencil (offset 207) */ "i\0" "glClearStencil\0" "\0" - /* _mesa_function_pool[8632]: VertexAttrib3dvARB (will be remapped) */ + /* _mesa_function_pool[8602]: VertexAttrib3dvARB (will be remapped) */ "ip\0" "glVertexAttrib3dv\0" "glVertexAttrib3dvARB\0" "\0" - /* _mesa_function_pool[8675]: Uniform4uivEXT (will be remapped) */ + /* _mesa_function_pool[8645]: Uniform4uivEXT (will be remapped) */ "iip\0" "glUniform4uivEXT\0" "glUniform4uiv\0" "\0" - /* _mesa_function_pool[8711]: HintPGI (dynamic) */ + /* _mesa_function_pool[8681]: HintPGI (dynamic) */ "ii\0" "glHintPGI\0" "\0" - /* _mesa_function_pool[8725]: ConvolutionParameteriv (offset 353) */ + /* _mesa_function_pool[8695]: ConvolutionParameteriv (offset 353) */ "iip\0" "glConvolutionParameteriv\0" "glConvolutionParameterivEXT\0" "\0" - /* _mesa_function_pool[8783]: Color4s (offset 33) */ + /* _mesa_function_pool[8753]: Color4s (offset 33) */ "iiii\0" "glColor4s\0" "\0" - /* _mesa_function_pool[8799]: InterleavedArrays (offset 317) */ + /* _mesa_function_pool[8769]: InterleavedArrays (offset 317) */ "iip\0" "glInterleavedArrays\0" "\0" - /* _mesa_function_pool[8824]: RasterPos2fv (offset 65) */ + /* _mesa_function_pool[8794]: RasterPos2fv (offset 65) */ "p\0" "glRasterPos2fv\0" "\0" - /* _mesa_function_pool[8842]: TexCoord1fv (offset 97) */ + /* _mesa_function_pool[8812]: TexCoord1fv (offset 97) */ "p\0" "glTexCoord1fv\0" "\0" - /* _mesa_function_pool[8859]: Vertex2d (offset 126) */ + /* _mesa_function_pool[8829]: Vertex2d (offset 126) */ "dd\0" "glVertex2d\0" "\0" - /* _mesa_function_pool[8874]: CullParameterdvEXT (dynamic) */ + /* _mesa_function_pool[8844]: CullParameterdvEXT (dynamic) */ "ip\0" "glCullParameterdvEXT\0" "\0" - /* _mesa_function_pool[8899]: ProgramNamedParameter4fNV (will be remapped) */ + /* _mesa_function_pool[8869]: ProgramNamedParameter4fNV (will be remapped) */ "iipffff\0" "glProgramNamedParameter4fNV\0" "\0" - /* _mesa_function_pool[8936]: Color3fVertex3fSUN (dynamic) */ + /* _mesa_function_pool[8906]: Color3fVertex3fSUN (dynamic) */ "ffffff\0" "glColor3fVertex3fSUN\0" "\0" - /* _mesa_function_pool[8965]: ProgramEnvParameter4fvARB (will be remapped) */ + /* _mesa_function_pool[8935]: ProgramEnvParameter4fvARB (will be remapped) */ "iip\0" "glProgramEnvParameter4fvARB\0" "glProgramParameter4fvNV\0" "\0" - /* _mesa_function_pool[9022]: Color4i (offset 31) */ + /* _mesa_function_pool[8992]: Color4i (offset 31) */ "iiii\0" "glColor4i\0" "\0" - /* _mesa_function_pool[9038]: Color4f (offset 29) */ + /* _mesa_function_pool[9008]: Color4f (offset 29) */ "ffff\0" "glColor4f\0" "\0" - /* _mesa_function_pool[9054]: RasterPos4fv (offset 81) */ + /* _mesa_function_pool[9024]: RasterPos4fv (offset 81) */ "p\0" "glRasterPos4fv\0" "\0" - /* _mesa_function_pool[9072]: Color4d (offset 27) */ + /* _mesa_function_pool[9042]: Color4d (offset 27) */ "dddd\0" "glColor4d\0" "\0" - /* _mesa_function_pool[9088]: ClearIndex (offset 205) */ + /* _mesa_function_pool[9058]: ClearIndex (offset 205) */ "f\0" "glClearIndex\0" "\0" - /* _mesa_function_pool[9104]: Color4b (offset 25) */ + /* _mesa_function_pool[9074]: Color4b (offset 25) */ "iiii\0" "glColor4b\0" "\0" - /* _mesa_function_pool[9120]: LoadMatrixd (offset 292) */ + /* _mesa_function_pool[9090]: LoadMatrixd (offset 292) */ "p\0" "glLoadMatrixd\0" "\0" - /* _mesa_function_pool[9137]: FragmentLightModeliSGIX (dynamic) */ + /* _mesa_function_pool[9107]: FragmentLightModeliSGIX (dynamic) */ "ii\0" "glFragmentLightModeliSGIX\0" "\0" - /* _mesa_function_pool[9167]: RasterPos2dv (offset 63) */ + /* _mesa_function_pool[9137]: RasterPos2dv (offset 63) */ "p\0" "glRasterPos2dv\0" "\0" - /* _mesa_function_pool[9185]: ConvolutionParameterfv (offset 351) */ + /* _mesa_function_pool[9155]: ConvolutionParameterfv (offset 351) */ "iip\0" "glConvolutionParameterfv\0" "glConvolutionParameterfvEXT\0" "\0" - /* _mesa_function_pool[9243]: TbufferMask3DFX (dynamic) */ + /* _mesa_function_pool[9213]: TbufferMask3DFX (dynamic) */ "i\0" "glTbufferMask3DFX\0" "\0" - /* _mesa_function_pool[9264]: GetTexGendv (offset 278) */ + /* _mesa_function_pool[9234]: GetTexGendv (offset 278) */ "iip\0" "glGetTexGendv\0" "\0" - /* _mesa_function_pool[9283]: GetVertexAttribfvNV (will be remapped) */ + /* _mesa_function_pool[9253]: GetVertexAttribfvNV (will be remapped) */ "iip\0" "glGetVertexAttribfvNV\0" "\0" - /* _mesa_function_pool[9310]: BeginTransformFeedbackEXT (will be remapped) */ + /* _mesa_function_pool[9280]: BeginTransformFeedbackEXT (will be remapped) */ "i\0" "glBeginTransformFeedbackEXT\0" "glBeginTransformFeedback\0" "\0" - /* _mesa_function_pool[9366]: LoadProgramNV (will be remapped) */ + /* _mesa_function_pool[9336]: LoadProgramNV (will be remapped) */ "iiip\0" "glLoadProgramNV\0" "\0" - /* _mesa_function_pool[9388]: WaitSync (will be remapped) */ + /* _mesa_function_pool[9358]: WaitSync (will be remapped) */ "iii\0" "glWaitSync\0" "\0" - /* _mesa_function_pool[9404]: EndList (offset 1) */ + /* _mesa_function_pool[9374]: EndList (offset 1) */ "\0" "glEndList\0" "\0" - /* _mesa_function_pool[9416]: VertexAttrib4fvNV (will be remapped) */ + /* _mesa_function_pool[9386]: VertexAttrib4fvNV (will be remapped) */ "ip\0" "glVertexAttrib4fvNV\0" "\0" - /* _mesa_function_pool[9440]: GetAttachedObjectsARB (will be remapped) */ + /* _mesa_function_pool[9410]: GetAttachedObjectsARB (will be remapped) */ "iipp\0" "glGetAttachedObjectsARB\0" "\0" - /* _mesa_function_pool[9470]: Uniform3fvARB (will be remapped) */ + /* _mesa_function_pool[9440]: Uniform3fvARB (will be remapped) */ "iip\0" "glUniform3fv\0" "glUniform3fvARB\0" "\0" - /* _mesa_function_pool[9504]: EvalCoord1fv (offset 231) */ + /* _mesa_function_pool[9474]: EvalCoord1fv (offset 231) */ "p\0" "glEvalCoord1fv\0" "\0" - /* _mesa_function_pool[9522]: DrawRangeElements (offset 338) */ + /* _mesa_function_pool[9492]: DrawRangeElements (offset 338) */ "iiiiip\0" "glDrawRangeElements\0" "glDrawRangeElementsEXT\0" "\0" - /* _mesa_function_pool[9573]: EvalMesh2 (offset 238) */ + /* _mesa_function_pool[9543]: EvalMesh2 (offset 238) */ "iiiii\0" "glEvalMesh2\0" "\0" - /* _mesa_function_pool[9592]: Vertex4fv (offset 145) */ + /* _mesa_function_pool[9562]: Vertex4fv (offset 145) */ "p\0" "glVertex4fv\0" "\0" - /* _mesa_function_pool[9607]: GenTransformFeedbacks (will be remapped) */ + /* _mesa_function_pool[9577]: GenTransformFeedbacks (will be remapped) */ "ip\0" "glGenTransformFeedbacks\0" "\0" - /* _mesa_function_pool[9635]: SpriteParameterfvSGIX (dynamic) */ + /* _mesa_function_pool[9605]: SpriteParameterfvSGIX (dynamic) */ "ip\0" "glSpriteParameterfvSGIX\0" "\0" - /* _mesa_function_pool[9663]: CheckFramebufferStatusEXT (will be remapped) */ + /* _mesa_function_pool[9633]: CheckFramebufferStatusEXT (will be remapped) */ "i\0" "glCheckFramebufferStatus\0" "glCheckFramebufferStatusEXT\0" "\0" - /* _mesa_function_pool[9719]: GlobalAlphaFactoruiSUN (dynamic) */ + /* _mesa_function_pool[9689]: GlobalAlphaFactoruiSUN (dynamic) */ "i\0" "glGlobalAlphaFactoruiSUN\0" "\0" - /* _mesa_function_pool[9747]: GetHandleARB (will be remapped) */ + /* _mesa_function_pool[9717]: GetHandleARB (will be remapped) */ "i\0" "glGetHandleARB\0" "\0" - /* _mesa_function_pool[9765]: GetVertexAttribivARB (will be remapped) */ + /* _mesa_function_pool[9735]: GetVertexAttribivARB (will be remapped) */ "iip\0" "glGetVertexAttribiv\0" "glGetVertexAttribivARB\0" "\0" - /* _mesa_function_pool[9813]: GetCombinerInputParameterfvNV (will be remapped) */ + /* _mesa_function_pool[9783]: BlendFunciARB (will be remapped) */ + "iii\0" + "glBlendFunciARB\0" + "\0" + /* _mesa_function_pool[9804]: GetCombinerInputParameterfvNV (will be remapped) */ "iiiip\0" "glGetCombinerInputParameterfvNV\0" "\0" - /* _mesa_function_pool[9852]: GetTexParameterIivEXT (will be remapped) */ + /* _mesa_function_pool[9843]: GetTexParameterIivEXT (will be remapped) */ "iip\0" "glGetTexParameterIivEXT\0" "glGetTexParameterIiv\0" "\0" - /* _mesa_function_pool[9902]: CreateProgram (will be remapped) */ + /* _mesa_function_pool[9893]: CreateProgram (will be remapped) */ "\0" "glCreateProgram\0" "\0" - /* _mesa_function_pool[9920]: LoadTransposeMatrixdARB (will be remapped) */ + /* _mesa_function_pool[9911]: LoadTransposeMatrixdARB (will be remapped) */ "p\0" "glLoadTransposeMatrixd\0" "glLoadTransposeMatrixdARB\0" "\0" - /* _mesa_function_pool[9972]: GetMinmax (offset 364) */ + /* _mesa_function_pool[9963]: ReleaseShaderCompiler (will be remapped) */ + "\0" + "glReleaseShaderCompiler\0" + "\0" + /* _mesa_function_pool[9989]: GetMinmax (offset 364) */ "iiiip\0" "glGetMinmax\0" "glGetMinmaxEXT\0" "\0" - /* _mesa_function_pool[10006]: StencilFuncSeparate (will be remapped) */ + /* _mesa_function_pool[10023]: StencilFuncSeparate (will be remapped) */ "iiii\0" "glStencilFuncSeparate\0" "\0" - /* _mesa_function_pool[10034]: SecondaryColor3sEXT (will be remapped) */ + /* _mesa_function_pool[10051]: SecondaryColor3sEXT (will be remapped) */ "iii\0" "glSecondaryColor3s\0" "glSecondaryColor3sEXT\0" "\0" - /* _mesa_function_pool[10080]: Color3fVertex3fvSUN (dynamic) */ + /* _mesa_function_pool[10097]: Color3fVertex3fvSUN (dynamic) */ "pp\0" "glColor3fVertex3fvSUN\0" "\0" - /* _mesa_function_pool[10106]: GetInteger64i_v (will be remapped) */ + /* _mesa_function_pool[10123]: GetInteger64i_v (will be remapped) */ "iip\0" "glGetInteger64i_v\0" "\0" - /* _mesa_function_pool[10129]: Normal3fv (offset 57) */ + /* _mesa_function_pool[10146]: Normal3fv (offset 57) */ "p\0" "glNormal3fv\0" "\0" - /* _mesa_function_pool[10144]: GlobalAlphaFactorbSUN (dynamic) */ + /* _mesa_function_pool[10161]: GlobalAlphaFactorbSUN (dynamic) */ "i\0" "glGlobalAlphaFactorbSUN\0" "\0" - /* _mesa_function_pool[10171]: Color3us (offset 23) */ + /* _mesa_function_pool[10188]: Color3us (offset 23) */ "iii\0" "glColor3us\0" "\0" - /* _mesa_function_pool[10187]: ImageTransformParameterfvHP (dynamic) */ + /* _mesa_function_pool[10204]: ImageTransformParameterfvHP (dynamic) */ "iip\0" "glImageTransformParameterfvHP\0" "\0" - /* _mesa_function_pool[10222]: VertexAttrib4ivARB (will be remapped) */ + /* _mesa_function_pool[10239]: VertexAttrib4ivARB (will be remapped) */ "ip\0" "glVertexAttrib4iv\0" "glVertexAttrib4ivARB\0" "\0" - /* _mesa_function_pool[10265]: End (offset 43) */ + /* _mesa_function_pool[10282]: End (offset 43) */ "\0" "glEnd\0" "\0" - /* _mesa_function_pool[10273]: VertexAttrib3fNV (will be remapped) */ + /* _mesa_function_pool[10290]: VertexAttrib3fNV (will be remapped) */ "ifff\0" "glVertexAttrib3fNV\0" "\0" - /* _mesa_function_pool[10298]: VertexAttribs2dvNV (will be remapped) */ + /* _mesa_function_pool[10315]: VertexAttribs2dvNV (will be remapped) */ "iip\0" "glVertexAttribs2dvNV\0" "\0" - /* _mesa_function_pool[10324]: GetQueryObjectui64vEXT (will be remapped) */ + /* _mesa_function_pool[10341]: GetQueryObjectui64vEXT (will be remapped) */ "iip\0" "glGetQueryObjectui64vEXT\0" "\0" - /* _mesa_function_pool[10354]: MultiTexCoord3fvARB (offset 395) */ + /* _mesa_function_pool[10371]: MultiTexCoord3fvARB (offset 395) */ "ip\0" "glMultiTexCoord3fv\0" "glMultiTexCoord3fvARB\0" "\0" - /* _mesa_function_pool[10399]: SecondaryColor3dEXT (will be remapped) */ + /* _mesa_function_pool[10416]: SecondaryColor3dEXT (will be remapped) */ "ddd\0" "glSecondaryColor3d\0" "glSecondaryColor3dEXT\0" "\0" - /* _mesa_function_pool[10445]: Color3ub (offset 19) */ + /* _mesa_function_pool[10462]: Color3ub (offset 19) */ "iii\0" "glColor3ub\0" "\0" - /* _mesa_function_pool[10461]: GetProgramParameterfvNV (will be remapped) */ + /* _mesa_function_pool[10478]: GetProgramParameterfvNV (will be remapped) */ "iiip\0" "glGetProgramParameterfvNV\0" "\0" - /* _mesa_function_pool[10493]: TangentPointerEXT (dynamic) */ + /* _mesa_function_pool[10510]: TangentPointerEXT (dynamic) */ "iip\0" "glTangentPointerEXT\0" "\0" - /* _mesa_function_pool[10518]: Color4fNormal3fVertex3fvSUN (dynamic) */ + /* _mesa_function_pool[10535]: Color4fNormal3fVertex3fvSUN (dynamic) */ "ppp\0" "glColor4fNormal3fVertex3fvSUN\0" "\0" - /* _mesa_function_pool[10553]: GetInstrumentsSGIX (dynamic) */ + /* _mesa_function_pool[10570]: GetInstrumentsSGIX (dynamic) */ "\0" "glGetInstrumentsSGIX\0" "\0" - /* _mesa_function_pool[10576]: GetUniformuivEXT (will be remapped) */ + /* _mesa_function_pool[10593]: GetUniformuivEXT (will be remapped) */ "iip\0" "glGetUniformuivEXT\0" "glGetUniformuiv\0" "\0" - /* _mesa_function_pool[10616]: Color3ui (offset 21) */ + /* _mesa_function_pool[10633]: Color3ui (offset 21) */ "iii\0" "glColor3ui\0" "\0" - /* _mesa_function_pool[10632]: EvalMapsNV (dynamic) */ + /* _mesa_function_pool[10649]: EvalMapsNV (dynamic) */ "ii\0" "glEvalMapsNV\0" "\0" - /* _mesa_function_pool[10649]: TexSubImage2D (offset 333) */ + /* _mesa_function_pool[10666]: TexSubImage2D (offset 333) */ "iiiiiiiip\0" "glTexSubImage2D\0" "glTexSubImage2DEXT\0" "\0" - /* _mesa_function_pool[10695]: FragmentLightivSGIX (dynamic) */ + /* _mesa_function_pool[10712]: FragmentLightivSGIX (dynamic) */ "iip\0" "glFragmentLightivSGIX\0" "\0" - /* _mesa_function_pool[10722]: GetTexParameterPointervAPPLE (will be remapped) */ + /* _mesa_function_pool[10739]: GetTexParameterPointervAPPLE (will be remapped) */ "iip\0" "glGetTexParameterPointervAPPLE\0" "\0" - /* _mesa_function_pool[10758]: TexGenfv (offset 191) */ + /* _mesa_function_pool[10775]: TexGenfv (offset 191) */ "iip\0" "glTexGenfv\0" "\0" - /* _mesa_function_pool[10774]: GetTransformFeedbackVaryingEXT (will be remapped) */ + /* _mesa_function_pool[10791]: GetTransformFeedbackVaryingEXT (will be remapped) */ "iiipppp\0" "glGetTransformFeedbackVaryingEXT\0" "glGetTransformFeedbackVarying\0" "\0" - /* _mesa_function_pool[10846]: VertexAttrib4bvARB (will be remapped) */ + /* _mesa_function_pool[10863]: VertexAttrib4bvARB (will be remapped) */ "ip\0" "glVertexAttrib4bv\0" "glVertexAttrib4bvARB\0" "\0" - /* _mesa_function_pool[10889]: AlphaFragmentOp2ATI (will be remapped) */ - "iiiiiiiii\0" - "glAlphaFragmentOp2ATI\0" + /* _mesa_function_pool[10906]: ShaderBinary (will be remapped) */ + "ipipi\0" + "glShaderBinary\0" "\0" - /* _mesa_function_pool[10922]: GetIntegerIndexedvEXT (will be remapped) */ + /* _mesa_function_pool[10928]: GetIntegerIndexedvEXT (will be remapped) */ "iip\0" "glGetIntegerIndexedvEXT\0" "glGetIntegeri_v\0" "\0" - /* _mesa_function_pool[10967]: MultiTexCoord4sARB (offset 406) */ + /* _mesa_function_pool[10973]: MultiTexCoord4sARB (offset 406) */ "iiiii\0" "glMultiTexCoord4s\0" "glMultiTexCoord4sARB\0" "\0" - /* _mesa_function_pool[11013]: GetFragmentMaterialivSGIX (dynamic) */ + /* _mesa_function_pool[11019]: GetFragmentMaterialivSGIX (dynamic) */ "iip\0" "glGetFragmentMaterialivSGIX\0" "\0" - /* _mesa_function_pool[11046]: WindowPos4dMESA (will be remapped) */ + /* _mesa_function_pool[11052]: WindowPos4dMESA (will be remapped) */ "dddd\0" "glWindowPos4dMESA\0" "\0" - /* _mesa_function_pool[11070]: WeightPointerARB (dynamic) */ + /* _mesa_function_pool[11076]: WeightPointerARB (dynamic) */ "iiip\0" "glWeightPointerARB\0" "\0" - /* _mesa_function_pool[11095]: WindowPos2dMESA (will be remapped) */ + /* _mesa_function_pool[11101]: WindowPos2dMESA (will be remapped) */ "dd\0" "glWindowPos2d\0" "glWindowPos2dARB\0" "glWindowPos2dMESA\0" "\0" - /* _mesa_function_pool[11148]: FramebufferTexture3DEXT (will be remapped) */ + /* _mesa_function_pool[11154]: FramebufferTexture3DEXT (will be remapped) */ "iiiiii\0" "glFramebufferTexture3D\0" "glFramebufferTexture3DEXT\0" "\0" - /* _mesa_function_pool[11205]: BlendEquation (offset 337) */ + /* _mesa_function_pool[11211]: BlendEquation (offset 337) */ "i\0" "glBlendEquation\0" "glBlendEquationEXT\0" "\0" - /* _mesa_function_pool[11243]: VertexAttrib3dNV (will be remapped) */ + /* _mesa_function_pool[11249]: VertexAttrib3dNV (will be remapped) */ "iddd\0" "glVertexAttrib3dNV\0" "\0" - /* _mesa_function_pool[11268]: VertexAttrib3dARB (will be remapped) */ + /* _mesa_function_pool[11274]: VertexAttrib3dARB (will be remapped) */ "iddd\0" "glVertexAttrib3d\0" "glVertexAttrib3dARB\0" "\0" - /* _mesa_function_pool[11311]: VertexAttribI4usvEXT (will be remapped) */ + /* _mesa_function_pool[11317]: VertexAttribI4usvEXT (will be remapped) */ "ip\0" "glVertexAttribI4usvEXT\0" "glVertexAttribI4usv\0" "\0" - /* _mesa_function_pool[11358]: ReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN (dynamic) */ + /* _mesa_function_pool[11364]: ReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN (dynamic) */ "ppppp\0" "glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN\0" "\0" - /* _mesa_function_pool[11422]: VertexAttrib4fARB (will be remapped) */ + /* _mesa_function_pool[11428]: VertexAttrib4fARB (will be remapped) */ "iffff\0" "glVertexAttrib4f\0" "glVertexAttrib4fARB\0" "\0" - /* _mesa_function_pool[11466]: GetError (offset 261) */ + /* _mesa_function_pool[11472]: GetError (offset 261) */ "\0" "glGetError\0" "\0" - /* _mesa_function_pool[11479]: IndexFuncEXT (dynamic) */ + /* _mesa_function_pool[11485]: IndexFuncEXT (dynamic) */ "if\0" "glIndexFuncEXT\0" "\0" - /* _mesa_function_pool[11498]: TexCoord3dv (offset 111) */ + /* _mesa_function_pool[11504]: TexCoord3dv (offset 111) */ "p\0" "glTexCoord3dv\0" "\0" - /* _mesa_function_pool[11515]: Indexdv (offset 45) */ + /* _mesa_function_pool[11521]: Indexdv (offset 45) */ "p\0" "glIndexdv\0" "\0" - /* _mesa_function_pool[11528]: FramebufferTexture2DEXT (will be remapped) */ + /* _mesa_function_pool[11534]: FramebufferTexture2DEXT (will be remapped) */ "iiiii\0" "glFramebufferTexture2D\0" "glFramebufferTexture2DEXT\0" "\0" - /* _mesa_function_pool[11584]: Normal3s (offset 60) */ + /* _mesa_function_pool[11590]: Normal3s (offset 60) */ "iii\0" "glNormal3s\0" "\0" - /* _mesa_function_pool[11600]: GetObjectParameterivAPPLE (will be remapped) */ + /* _mesa_function_pool[11606]: GetObjectParameterivAPPLE (will be remapped) */ "iiip\0" "glGetObjectParameterivAPPLE\0" "\0" - /* _mesa_function_pool[11634]: PushName (offset 201) */ + /* _mesa_function_pool[11640]: PushName (offset 201) */ "i\0" "glPushName\0" "\0" - /* _mesa_function_pool[11648]: MultiTexCoord2dvARB (offset 385) */ + /* _mesa_function_pool[11654]: MultiTexCoord2dvARB (offset 385) */ "ip\0" "glMultiTexCoord2dv\0" "glMultiTexCoord2dvARB\0" "\0" - /* _mesa_function_pool[11693]: CullParameterfvEXT (dynamic) */ + /* _mesa_function_pool[11699]: CullParameterfvEXT (dynamic) */ "ip\0" "glCullParameterfvEXT\0" "\0" - /* _mesa_function_pool[11718]: Normal3i (offset 58) */ + /* _mesa_function_pool[11724]: Normal3i (offset 58) */ "iii\0" "glNormal3i\0" "\0" - /* _mesa_function_pool[11734]: ProgramNamedParameter4fvNV (will be remapped) */ + /* _mesa_function_pool[11740]: ProgramNamedParameter4fvNV (will be remapped) */ "iipp\0" "glProgramNamedParameter4fvNV\0" "\0" - /* _mesa_function_pool[11769]: SecondaryColorPointerEXT (will be remapped) */ + /* _mesa_function_pool[11775]: SecondaryColorPointerEXT (will be remapped) */ "iiip\0" "glSecondaryColorPointer\0" "glSecondaryColorPointerEXT\0" "\0" - /* _mesa_function_pool[11826]: VertexAttrib4fvARB (will be remapped) */ + /* _mesa_function_pool[11832]: VertexAttrib4fvARB (will be remapped) */ "ip\0" "glVertexAttrib4fv\0" "glVertexAttrib4fvARB\0" "\0" - /* _mesa_function_pool[11869]: ColorPointerListIBM (dynamic) */ + /* _mesa_function_pool[11875]: ColorPointerListIBM (dynamic) */ "iiipi\0" "glColorPointerListIBM\0" "\0" - /* _mesa_function_pool[11898]: GetActiveUniformARB (will be remapped) */ + /* _mesa_function_pool[11904]: GetActiveUniformARB (will be remapped) */ "iiipppp\0" "glGetActiveUniform\0" "glGetActiveUniformARB\0" "\0" - /* _mesa_function_pool[11948]: ImageTransformParameteriHP (dynamic) */ + /* _mesa_function_pool[11954]: ImageTransformParameteriHP (dynamic) */ "iii\0" "glImageTransformParameteriHP\0" "\0" - /* _mesa_function_pool[11982]: Normal3b (offset 52) */ + /* _mesa_function_pool[11988]: Normal3b (offset 52) */ "iii\0" "glNormal3b\0" "\0" - /* _mesa_function_pool[11998]: Normal3d (offset 54) */ + /* _mesa_function_pool[12004]: Normal3d (offset 54) */ "ddd\0" "glNormal3d\0" "\0" - /* _mesa_function_pool[12014]: Uniform1uiEXT (will be remapped) */ + /* _mesa_function_pool[12020]: Uniform1uiEXT (will be remapped) */ "ii\0" "glUniform1uiEXT\0" "glUniform1ui\0" "\0" - /* _mesa_function_pool[12047]: Normal3f (offset 56) */ + /* _mesa_function_pool[12053]: Normal3f (offset 56) */ "fff\0" "glNormal3f\0" "\0" - /* _mesa_function_pool[12063]: MultiTexCoord1svARB (offset 383) */ + /* _mesa_function_pool[12069]: MultiTexCoord1svARB (offset 383) */ "ip\0" "glMultiTexCoord1sv\0" "glMultiTexCoord1svARB\0" "\0" - /* _mesa_function_pool[12108]: Indexi (offset 48) */ + /* _mesa_function_pool[12114]: Indexi (offset 48) */ "i\0" "glIndexi\0" "\0" - /* _mesa_function_pool[12120]: EGLImageTargetTexture2DOES (will be remapped) */ + /* _mesa_function_pool[12126]: EGLImageTargetTexture2DOES (will be remapped) */ "ip\0" "glEGLImageTargetTexture2DOES\0" "\0" - /* _mesa_function_pool[12153]: EndQueryARB (will be remapped) */ + /* _mesa_function_pool[12159]: EndQueryARB (will be remapped) */ "i\0" "glEndQuery\0" "glEndQueryARB\0" "\0" - /* _mesa_function_pool[12181]: DeleteFencesNV (will be remapped) */ + /* _mesa_function_pool[12187]: DeleteFencesNV (will be remapped) */ "ip\0" "glDeleteFencesNV\0" "\0" - /* _mesa_function_pool[12202]: BindBufferRangeEXT (will be remapped) */ + /* _mesa_function_pool[12208]: DeformationMap3dSGIX (dynamic) */ + "iddiiddiiddiip\0" + "glDeformationMap3dSGIX\0" + "\0" + /* _mesa_function_pool[12247]: BindBufferRangeEXT (will be remapped) */ "iiiii\0" "glBindBufferRangeEXT\0" "glBindBufferRange\0" "\0" - /* _mesa_function_pool[12248]: DepthMask (offset 211) */ + /* _mesa_function_pool[12293]: DepthMask (offset 211) */ "i\0" "glDepthMask\0" "\0" - /* _mesa_function_pool[12263]: IsShader (will be remapped) */ + /* _mesa_function_pool[12308]: IsShader (will be remapped) */ "i\0" "glIsShader\0" "\0" - /* _mesa_function_pool[12277]: Indexf (offset 46) */ + /* _mesa_function_pool[12322]: Indexf (offset 46) */ "f\0" "glIndexf\0" "\0" - /* _mesa_function_pool[12289]: GetImageTransformParameterivHP (dynamic) */ + /* _mesa_function_pool[12334]: GetImageTransformParameterivHP (dynamic) */ "iip\0" "glGetImageTransformParameterivHP\0" "\0" - /* _mesa_function_pool[12327]: Indexd (offset 44) */ + /* _mesa_function_pool[12372]: Indexd (offset 44) */ "d\0" "glIndexd\0" "\0" - /* _mesa_function_pool[12339]: GetMaterialiv (offset 270) */ + /* _mesa_function_pool[12384]: GetMaterialiv (offset 270) */ "iip\0" "glGetMaterialiv\0" "\0" - /* _mesa_function_pool[12360]: StencilOp (offset 244) */ + /* _mesa_function_pool[12405]: StencilOp (offset 244) */ "iii\0" "glStencilOp\0" "\0" - /* _mesa_function_pool[12377]: WindowPos4ivMESA (will be remapped) */ + /* _mesa_function_pool[12422]: WindowPos4ivMESA (will be remapped) */ "p\0" "glWindowPos4ivMESA\0" "\0" - /* _mesa_function_pool[12399]: FramebufferTextureLayer (dynamic) */ + /* _mesa_function_pool[12444]: FramebufferTextureLayer (dynamic) */ "iiiii\0" "glFramebufferTextureLayerARB\0" "\0" - /* _mesa_function_pool[12435]: MultiTexCoord3svARB (offset 399) */ + /* _mesa_function_pool[12480]: MultiTexCoord3svARB (offset 399) */ "ip\0" "glMultiTexCoord3sv\0" "glMultiTexCoord3svARB\0" "\0" - /* _mesa_function_pool[12480]: TexEnvfv (offset 185) */ + /* _mesa_function_pool[12525]: TexEnvfv (offset 185) */ "iip\0" "glTexEnvfv\0" "\0" - /* _mesa_function_pool[12496]: MultiTexCoord4iARB (offset 404) */ + /* _mesa_function_pool[12541]: MultiTexCoord4iARB (offset 404) */ "iiiii\0" "glMultiTexCoord4i\0" "glMultiTexCoord4iARB\0" "\0" - /* _mesa_function_pool[12542]: Indexs (offset 50) */ + /* _mesa_function_pool[12587]: Indexs (offset 50) */ "i\0" "glIndexs\0" "\0" - /* _mesa_function_pool[12554]: Binormal3ivEXT (dynamic) */ + /* _mesa_function_pool[12599]: Binormal3ivEXT (dynamic) */ "p\0" "glBinormal3ivEXT\0" "\0" - /* _mesa_function_pool[12574]: ResizeBuffersMESA (will be remapped) */ + /* _mesa_function_pool[12619]: ResizeBuffersMESA (will be remapped) */ "\0" "glResizeBuffersMESA\0" "\0" - /* _mesa_function_pool[12596]: GetUniformivARB (will be remapped) */ + /* _mesa_function_pool[12641]: BlendFuncSeparateiARB (will be remapped) */ + "iiiii\0" + "glBlendFuncSeparateiARB\0" + "\0" + /* _mesa_function_pool[12672]: GetUniformivARB (will be remapped) */ "iip\0" "glGetUniformiv\0" "glGetUniformivARB\0" "\0" - /* _mesa_function_pool[12634]: PixelTexGenParameteriSGIS (will be remapped) */ + /* _mesa_function_pool[12710]: PixelTexGenParameteriSGIS (will be remapped) */ "ii\0" "glPixelTexGenParameteriSGIS\0" "\0" - /* _mesa_function_pool[12666]: VertexPointervINTEL (dynamic) */ + /* _mesa_function_pool[12742]: VertexPointervINTEL (dynamic) */ "iip\0" "glVertexPointervINTEL\0" "\0" - /* _mesa_function_pool[12693]: Vertex2i (offset 130) */ + /* _mesa_function_pool[12769]: Vertex2i (offset 130) */ "ii\0" "glVertex2i\0" "\0" - /* _mesa_function_pool[12708]: LoadMatrixf (offset 291) */ + /* _mesa_function_pool[12784]: LoadMatrixf (offset 291) */ "p\0" "glLoadMatrixf\0" "\0" - /* _mesa_function_pool[12725]: VertexAttribI1uivEXT (will be remapped) */ + /* _mesa_function_pool[12801]: VertexAttribI1uivEXT (will be remapped) */ "ip\0" "glVertexAttribI1uivEXT\0" "glVertexAttribI1uiv\0" "\0" - /* _mesa_function_pool[12772]: Vertex2f (offset 128) */ + /* _mesa_function_pool[12848]: Vertex2f (offset 128) */ "ff\0" "glVertex2f\0" "\0" - /* _mesa_function_pool[12787]: ReplacementCodeuiColor4fNormal3fVertex3fvSUN (dynamic) */ + /* _mesa_function_pool[12863]: ReplacementCodeuiColor4fNormal3fVertex3fvSUN (dynamic) */ "pppp\0" "glReplacementCodeuiColor4fNormal3fVertex3fvSUN\0" "\0" - /* _mesa_function_pool[12840]: Color4bv (offset 26) */ + /* _mesa_function_pool[12916]: Color4bv (offset 26) */ "p\0" "glColor4bv\0" "\0" - /* _mesa_function_pool[12854]: VertexPointer (offset 321) */ + /* _mesa_function_pool[12930]: VertexPointer (offset 321) */ "iiip\0" "glVertexPointer\0" "\0" - /* _mesa_function_pool[12876]: SecondaryColor3uiEXT (will be remapped) */ + /* _mesa_function_pool[12952]: SecondaryColor3uiEXT (will be remapped) */ "iii\0" "glSecondaryColor3ui\0" "glSecondaryColor3uiEXT\0" "\0" - /* _mesa_function_pool[12924]: StartInstrumentsSGIX (dynamic) */ + /* _mesa_function_pool[13000]: StartInstrumentsSGIX (dynamic) */ "\0" "glStartInstrumentsSGIX\0" "\0" - /* _mesa_function_pool[12949]: SecondaryColor3usvEXT (will be remapped) */ + /* _mesa_function_pool[13025]: SecondaryColor3usvEXT (will be remapped) */ "p\0" "glSecondaryColor3usv\0" "glSecondaryColor3usvEXT\0" "\0" - /* _mesa_function_pool[12997]: VertexAttrib2fvNV (will be remapped) */ + /* _mesa_function_pool[13073]: VertexAttrib2fvNV (will be remapped) */ "ip\0" "glVertexAttrib2fvNV\0" "\0" - /* _mesa_function_pool[13021]: ProgramLocalParameter4dvARB (will be remapped) */ + /* _mesa_function_pool[13097]: ProgramLocalParameter4dvARB (will be remapped) */ "iip\0" "glProgramLocalParameter4dvARB\0" "\0" - /* _mesa_function_pool[13056]: DeleteLists (offset 4) */ + /* _mesa_function_pool[13132]: DeleteLists (offset 4) */ "ii\0" "glDeleteLists\0" "\0" - /* _mesa_function_pool[13074]: LogicOp (offset 242) */ + /* _mesa_function_pool[13150]: LogicOp (offset 242) */ "i\0" "glLogicOp\0" "\0" - /* _mesa_function_pool[13087]: MatrixIndexuivARB (dynamic) */ + /* _mesa_function_pool[13163]: MatrixIndexuivARB (dynamic) */ "ip\0" "glMatrixIndexuivARB\0" "\0" - /* _mesa_function_pool[13111]: Vertex2s (offset 132) */ + /* _mesa_function_pool[13187]: Vertex2s (offset 132) */ "ii\0" "glVertex2s\0" "\0" - /* _mesa_function_pool[13126]: RenderbufferStorageMultisample (will be remapped) */ + /* _mesa_function_pool[13202]: RenderbufferStorageMultisample (will be remapped) */ "iiiii\0" "glRenderbufferStorageMultisample\0" "glRenderbufferStorageMultisampleEXT\0" "\0" - /* _mesa_function_pool[13202]: TexCoord4fv (offset 121) */ + /* _mesa_function_pool[13278]: TexCoord4fv (offset 121) */ "p\0" "glTexCoord4fv\0" "\0" - /* _mesa_function_pool[13219]: Tangent3sEXT (dynamic) */ + /* _mesa_function_pool[13295]: Tangent3sEXT (dynamic) */ "iii\0" "glTangent3sEXT\0" "\0" - /* _mesa_function_pool[13239]: GlobalAlphaFactorfSUN (dynamic) */ + /* _mesa_function_pool[13315]: GlobalAlphaFactorfSUN (dynamic) */ "f\0" "glGlobalAlphaFactorfSUN\0" "\0" - /* _mesa_function_pool[13266]: MultiTexCoord3iARB (offset 396) */ + /* _mesa_function_pool[13342]: MultiTexCoord3iARB (offset 396) */ "iiii\0" "glMultiTexCoord3i\0" "glMultiTexCoord3iARB\0" "\0" - /* _mesa_function_pool[13311]: IsProgram (will be remapped) */ + /* _mesa_function_pool[13387]: IsProgram (will be remapped) */ "i\0" "glIsProgram\0" "\0" - /* _mesa_function_pool[13326]: TexCoordPointerListIBM (dynamic) */ + /* _mesa_function_pool[13402]: TexCoordPointerListIBM (dynamic) */ "iiipi\0" "glTexCoordPointerListIBM\0" "\0" - /* _mesa_function_pool[13358]: VertexAttribI4svEXT (will be remapped) */ + /* _mesa_function_pool[13434]: VertexAttribI4svEXT (will be remapped) */ "ip\0" "glVertexAttribI4svEXT\0" "glVertexAttribI4sv\0" "\0" - /* _mesa_function_pool[13403]: GlobalAlphaFactorusSUN (dynamic) */ + /* _mesa_function_pool[13479]: GlobalAlphaFactorusSUN (dynamic) */ "i\0" "glGlobalAlphaFactorusSUN\0" "\0" - /* _mesa_function_pool[13431]: VertexAttrib2dvNV (will be remapped) */ + /* _mesa_function_pool[13507]: VertexAttrib2dvNV (will be remapped) */ "ip\0" "glVertexAttrib2dvNV\0" "\0" - /* _mesa_function_pool[13455]: FramebufferRenderbufferEXT (will be remapped) */ + /* _mesa_function_pool[13531]: FramebufferRenderbufferEXT (will be remapped) */ "iiii\0" "glFramebufferRenderbuffer\0" "glFramebufferRenderbufferEXT\0" "\0" - /* _mesa_function_pool[13516]: ClearBufferuiv (will be remapped) */ + /* _mesa_function_pool[13592]: ClearBufferuiv (will be remapped) */ "iip\0" "glClearBufferuiv\0" "\0" - /* _mesa_function_pool[13538]: VertexAttrib1dvNV (will be remapped) */ + /* _mesa_function_pool[13614]: VertexAttrib1dvNV (will be remapped) */ "ip\0" "glVertexAttrib1dvNV\0" "\0" - /* _mesa_function_pool[13562]: GenTextures (offset 328) */ + /* _mesa_function_pool[13638]: GenTextures (offset 328) */ "ip\0" "glGenTextures\0" "glGenTexturesEXT\0" "\0" - /* _mesa_function_pool[13597]: FramebufferTextureARB (will be remapped) */ + /* _mesa_function_pool[13673]: FramebufferTextureARB (will be remapped) */ "iiii\0" "glFramebufferTextureARB\0" "\0" - /* _mesa_function_pool[13627]: SetFenceNV (will be remapped) */ + /* _mesa_function_pool[13703]: SetFenceNV (will be remapped) */ "ii\0" "glSetFenceNV\0" "\0" - /* _mesa_function_pool[13644]: FramebufferTexture1DEXT (will be remapped) */ + /* _mesa_function_pool[13720]: FramebufferTexture1DEXT (will be remapped) */ "iiiii\0" "glFramebufferTexture1D\0" "glFramebufferTexture1DEXT\0" "\0" - /* _mesa_function_pool[13700]: GetCombinerOutputParameterivNV (will be remapped) */ + /* _mesa_function_pool[13776]: GetCombinerOutputParameterivNV (will be remapped) */ "iiip\0" "glGetCombinerOutputParameterivNV\0" "\0" - /* _mesa_function_pool[13739]: MultiModeDrawArraysIBM (will be remapped) */ - "pppii\0" - "glMultiModeDrawArraysIBM\0" - "\0" - /* _mesa_function_pool[13771]: PixelTexGenParameterivSGIS (will be remapped) */ + /* _mesa_function_pool[13815]: PixelTexGenParameterivSGIS (will be remapped) */ "ip\0" "glPixelTexGenParameterivSGIS\0" "\0" - /* _mesa_function_pool[13804]: TextureNormalEXT (dynamic) */ + /* _mesa_function_pool[13848]: TextureNormalEXT (dynamic) */ "i\0" "glTextureNormalEXT\0" "\0" - /* _mesa_function_pool[13826]: IndexPointerListIBM (dynamic) */ + /* _mesa_function_pool[13870]: IndexPointerListIBM (dynamic) */ "iipi\0" "glIndexPointerListIBM\0" "\0" - /* _mesa_function_pool[13854]: WeightfvARB (dynamic) */ + /* _mesa_function_pool[13898]: WeightfvARB (dynamic) */ "ip\0" "glWeightfvARB\0" "\0" - /* _mesa_function_pool[13872]: GetCombinerOutputParameterfvNV (will be remapped) */ - "iiip\0" - "glGetCombinerOutputParameterfvNV\0" - "\0" - /* _mesa_function_pool[13911]: RasterPos2sv (offset 69) */ + /* _mesa_function_pool[13916]: RasterPos2sv (offset 69) */ "p\0" "glRasterPos2sv\0" "\0" - /* _mesa_function_pool[13929]: Color4ubv (offset 36) */ + /* _mesa_function_pool[13934]: Color4ubv (offset 36) */ "p\0" "glColor4ubv\0" "\0" - /* _mesa_function_pool[13944]: DrawBuffer (offset 202) */ + /* _mesa_function_pool[13949]: DrawBuffer (offset 202) */ "i\0" "glDrawBuffer\0" "\0" - /* _mesa_function_pool[13960]: TexCoord2fv (offset 105) */ + /* _mesa_function_pool[13965]: TexCoord2fv (offset 105) */ "p\0" "glTexCoord2fv\0" "\0" - /* _mesa_function_pool[13977]: WindowPos4fMESA (will be remapped) */ + /* _mesa_function_pool[13982]: WindowPos4fMESA (will be remapped) */ "ffff\0" "glWindowPos4fMESA\0" "\0" - /* _mesa_function_pool[14001]: TexCoord1sv (offset 101) */ + /* _mesa_function_pool[14006]: TexCoord1sv (offset 101) */ "p\0" "glTexCoord1sv\0" "\0" - /* _mesa_function_pool[14018]: WindowPos3dvMESA (will be remapped) */ + /* _mesa_function_pool[14023]: WindowPos3dvMESA (will be remapped) */ "p\0" "glWindowPos3dv\0" "glWindowPos3dvARB\0" "glWindowPos3dvMESA\0" "\0" - /* _mesa_function_pool[14073]: DepthFunc (offset 245) */ + /* _mesa_function_pool[14078]: DepthFunc (offset 245) */ "i\0" "glDepthFunc\0" "\0" - /* _mesa_function_pool[14088]: PixelMapusv (offset 253) */ + /* _mesa_function_pool[14093]: PixelMapusv (offset 253) */ "iip\0" "glPixelMapusv\0" "\0" - /* _mesa_function_pool[14107]: GetQueryObjecti64vEXT (will be remapped) */ + /* _mesa_function_pool[14112]: GetQueryObjecti64vEXT (will be remapped) */ "iip\0" "glGetQueryObjecti64vEXT\0" "\0" - /* _mesa_function_pool[14136]: MultiTexCoord1dARB (offset 376) */ + /* _mesa_function_pool[14141]: MultiTexCoord1dARB (offset 376) */ "id\0" "glMultiTexCoord1d\0" "glMultiTexCoord1dARB\0" "\0" - /* _mesa_function_pool[14179]: PointParameterivNV (will be remapped) */ + /* _mesa_function_pool[14184]: PointParameterivNV (will be remapped) */ "ip\0" "glPointParameteriv\0" "glPointParameterivNV\0" "\0" - /* _mesa_function_pool[14223]: BlendFunc (offset 241) */ + /* _mesa_function_pool[14228]: BlendFunc (offset 241) */ "ii\0" "glBlendFunc\0" "\0" - /* _mesa_function_pool[14239]: EndTransformFeedbackEXT (will be remapped) */ + /* _mesa_function_pool[14244]: EndTransformFeedbackEXT (will be remapped) */ "\0" "glEndTransformFeedbackEXT\0" "glEndTransformFeedback\0" "\0" - /* _mesa_function_pool[14290]: Uniform2fvARB (will be remapped) */ + /* _mesa_function_pool[14295]: Uniform2fvARB (will be remapped) */ "iip\0" "glUniform2fv\0" "glUniform2fvARB\0" "\0" - /* _mesa_function_pool[14324]: BufferParameteriAPPLE (will be remapped) */ + /* _mesa_function_pool[14329]: BufferParameteriAPPLE (will be remapped) */ "iii\0" "glBufferParameteriAPPLE\0" "\0" - /* _mesa_function_pool[14353]: MultiTexCoord3dvARB (offset 393) */ + /* _mesa_function_pool[14358]: MultiTexCoord3dvARB (offset 393) */ "ip\0" "glMultiTexCoord3dv\0" "glMultiTexCoord3dvARB\0" "\0" - /* _mesa_function_pool[14398]: ReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN (dynamic) */ + /* _mesa_function_pool[14403]: ReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN (dynamic) */ "pppp\0" "glReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN\0" "\0" - /* _mesa_function_pool[14454]: DeleteObjectARB (will be remapped) */ + /* _mesa_function_pool[14459]: DeleteObjectARB (will be remapped) */ "i\0" "glDeleteObjectARB\0" "\0" - /* _mesa_function_pool[14475]: MatrixIndexPointerARB (dynamic) */ + /* _mesa_function_pool[14480]: GetShaderPrecisionFormat (will be remapped) */ + "iipp\0" + "glGetShaderPrecisionFormat\0" + "\0" + /* _mesa_function_pool[14513]: MatrixIndexPointerARB (dynamic) */ "iiip\0" "glMatrixIndexPointerARB\0" "\0" - /* _mesa_function_pool[14505]: ProgramNamedParameter4dvNV (will be remapped) */ + /* _mesa_function_pool[14543]: ProgramNamedParameter4dvNV (will be remapped) */ "iipp\0" "glProgramNamedParameter4dvNV\0" "\0" - /* _mesa_function_pool[14540]: Tangent3fvEXT (dynamic) */ + /* _mesa_function_pool[14578]: Tangent3fvEXT (dynamic) */ "p\0" "glTangent3fvEXT\0" "\0" - /* _mesa_function_pool[14559]: Flush (offset 217) */ + /* _mesa_function_pool[14597]: Flush (offset 217) */ "\0" "glFlush\0" "\0" - /* _mesa_function_pool[14569]: Color4uiv (offset 38) */ + /* _mesa_function_pool[14607]: Color4uiv (offset 38) */ "p\0" "glColor4uiv\0" "\0" - /* _mesa_function_pool[14584]: VertexAttribI4iEXT (will be remapped) */ + /* _mesa_function_pool[14622]: VertexAttribI4iEXT (will be remapped) */ "iiiii\0" "glVertexAttribI4iEXT\0" "glVertexAttribI4i\0" "\0" - /* _mesa_function_pool[14630]: GenVertexArrays (will be remapped) */ + /* _mesa_function_pool[14668]: GenVertexArrays (will be remapped) */ "ip\0" "glGenVertexArrays\0" "\0" - /* _mesa_function_pool[14652]: Uniform3uivEXT (will be remapped) */ + /* _mesa_function_pool[14690]: Uniform3uivEXT (will be remapped) */ "iip\0" "glUniform3uivEXT\0" "glUniform3uiv\0" "\0" - /* _mesa_function_pool[14688]: RasterPos3sv (offset 77) */ + /* _mesa_function_pool[14726]: RasterPos3sv (offset 77) */ "p\0" "glRasterPos3sv\0" "\0" - /* _mesa_function_pool[14706]: BindFramebufferEXT (will be remapped) */ + /* _mesa_function_pool[14744]: BindFramebufferEXT (will be remapped) */ "ii\0" "glBindFramebuffer\0" "glBindFramebufferEXT\0" "\0" - /* _mesa_function_pool[14749]: ReferencePlaneSGIX (dynamic) */ + /* _mesa_function_pool[14787]: ReferencePlaneSGIX (dynamic) */ "p\0" "glReferencePlaneSGIX\0" "\0" - /* _mesa_function_pool[14773]: PushAttrib (offset 219) */ + /* _mesa_function_pool[14811]: PushAttrib (offset 219) */ "i\0" "glPushAttrib\0" "\0" - /* _mesa_function_pool[14789]: RasterPos2i (offset 66) */ + /* _mesa_function_pool[14827]: RasterPos2i (offset 66) */ "ii\0" "glRasterPos2i\0" "\0" - /* _mesa_function_pool[14807]: ValidateProgramARB (will be remapped) */ + /* _mesa_function_pool[14845]: ValidateProgramARB (will be remapped) */ "i\0" "glValidateProgram\0" "glValidateProgramARB\0" "\0" - /* _mesa_function_pool[14849]: TexParameteriv (offset 181) */ + /* _mesa_function_pool[14887]: TexParameteriv (offset 181) */ "iip\0" "glTexParameteriv\0" "\0" - /* _mesa_function_pool[14871]: UnlockArraysEXT (will be remapped) */ + /* _mesa_function_pool[14909]: UnlockArraysEXT (will be remapped) */ "\0" "glUnlockArraysEXT\0" "\0" - /* _mesa_function_pool[14891]: TexCoord2fColor3fVertex3fSUN (dynamic) */ + /* _mesa_function_pool[14929]: TexCoord2fColor3fVertex3fSUN (dynamic) */ "ffffffff\0" "glTexCoord2fColor3fVertex3fSUN\0" "\0" - /* _mesa_function_pool[14932]: WindowPos3fvMESA (will be remapped) */ + /* _mesa_function_pool[14970]: WindowPos3fvMESA (will be remapped) */ "p\0" "glWindowPos3fv\0" "glWindowPos3fvARB\0" "glWindowPos3fvMESA\0" "\0" - /* _mesa_function_pool[14987]: RasterPos2f (offset 64) */ + /* _mesa_function_pool[15025]: RasterPos2f (offset 64) */ "ff\0" "glRasterPos2f\0" "\0" - /* _mesa_function_pool[15005]: VertexAttrib1svNV (will be remapped) */ + /* _mesa_function_pool[15043]: VertexAttrib1svNV (will be remapped) */ "ip\0" "glVertexAttrib1svNV\0" "\0" - /* _mesa_function_pool[15029]: RasterPos2d (offset 62) */ + /* _mesa_function_pool[15067]: RasterPos2d (offset 62) */ "dd\0" "glRasterPos2d\0" "\0" - /* _mesa_function_pool[15047]: RasterPos3fv (offset 73) */ + /* _mesa_function_pool[15085]: RasterPos3fv (offset 73) */ "p\0" "glRasterPos3fv\0" "\0" - /* _mesa_function_pool[15065]: CopyTexSubImage3D (offset 373) */ + /* _mesa_function_pool[15103]: CopyTexSubImage3D (offset 373) */ "iiiiiiiii\0" "glCopyTexSubImage3D\0" "glCopyTexSubImage3DEXT\0" "\0" - /* _mesa_function_pool[15119]: VertexAttrib2dARB (will be remapped) */ + /* _mesa_function_pool[15157]: VertexAttrib2dARB (will be remapped) */ "idd\0" "glVertexAttrib2d\0" "glVertexAttrib2dARB\0" "\0" - /* _mesa_function_pool[15161]: Color4ub (offset 35) */ + /* _mesa_function_pool[15199]: Color4ub (offset 35) */ "iiii\0" "glColor4ub\0" "\0" - /* _mesa_function_pool[15178]: GetInteger64v (will be remapped) */ + /* _mesa_function_pool[15216]: GetInteger64v (will be remapped) */ "ip\0" "glGetInteger64v\0" "\0" - /* _mesa_function_pool[15198]: TextureColorMaskSGIS (dynamic) */ + /* _mesa_function_pool[15236]: TextureColorMaskSGIS (dynamic) */ "iiii\0" "glTextureColorMaskSGIS\0" "\0" - /* _mesa_function_pool[15227]: RasterPos2s (offset 68) */ + /* _mesa_function_pool[15265]: RasterPos2s (offset 68) */ "ii\0" "glRasterPos2s\0" "\0" - /* _mesa_function_pool[15245]: GetColorTable (offset 343) */ + /* _mesa_function_pool[15283]: GetColorTable (offset 343) */ "iiip\0" "glGetColorTable\0" "glGetColorTableSGI\0" "glGetColorTableEXT\0" "\0" - /* _mesa_function_pool[15305]: SelectBuffer (offset 195) */ + /* _mesa_function_pool[15343]: SelectBuffer (offset 195) */ "ip\0" "glSelectBuffer\0" "\0" - /* _mesa_function_pool[15324]: Indexiv (offset 49) */ + /* _mesa_function_pool[15362]: Indexiv (offset 49) */ "p\0" "glIndexiv\0" "\0" - /* _mesa_function_pool[15337]: TexCoord3i (offset 114) */ + /* _mesa_function_pool[15375]: TexCoord3i (offset 114) */ "iii\0" "glTexCoord3i\0" "\0" - /* _mesa_function_pool[15355]: CopyColorTable (offset 342) */ + /* _mesa_function_pool[15393]: CopyColorTable (offset 342) */ "iiiii\0" "glCopyColorTable\0" "glCopyColorTableSGI\0" "\0" - /* _mesa_function_pool[15399]: GetHistogramParameterfv (offset 362) */ + /* _mesa_function_pool[15437]: GetHistogramParameterfv (offset 362) */ "iip\0" "glGetHistogramParameterfv\0" "glGetHistogramParameterfvEXT\0" "\0" - /* _mesa_function_pool[15459]: Frustum (offset 289) */ + /* _mesa_function_pool[15497]: Frustum (offset 289) */ "dddddd\0" "glFrustum\0" "\0" - /* _mesa_function_pool[15477]: GetString (offset 275) */ + /* _mesa_function_pool[15515]: GetString (offset 275) */ "i\0" "glGetString\0" "\0" - /* _mesa_function_pool[15492]: ColorPointervINTEL (dynamic) */ + /* _mesa_function_pool[15530]: ColorPointervINTEL (dynamic) */ "iip\0" "glColorPointervINTEL\0" "\0" - /* _mesa_function_pool[15518]: TexEnvf (offset 184) */ + /* _mesa_function_pool[15556]: TexEnvf (offset 184) */ "iif\0" "glTexEnvf\0" "\0" - /* _mesa_function_pool[15533]: TexCoord3d (offset 110) */ + /* _mesa_function_pool[15571]: TexCoord3d (offset 110) */ "ddd\0" "glTexCoord3d\0" "\0" - /* _mesa_function_pool[15551]: AlphaFragmentOp1ATI (will be remapped) */ + /* _mesa_function_pool[15589]: AlphaFragmentOp1ATI (will be remapped) */ "iiiiii\0" "glAlphaFragmentOp1ATI\0" "\0" - /* _mesa_function_pool[15581]: TexCoord3f (offset 112) */ + /* _mesa_function_pool[15619]: TexCoord3f (offset 112) */ "fff\0" "glTexCoord3f\0" "\0" - /* _mesa_function_pool[15599]: MultiTexCoord3ivARB (offset 397) */ + /* _mesa_function_pool[15637]: MultiTexCoord3ivARB (offset 397) */ "ip\0" "glMultiTexCoord3iv\0" "glMultiTexCoord3ivARB\0" "\0" - /* _mesa_function_pool[15644]: MultiTexCoord2sARB (offset 390) */ + /* _mesa_function_pool[15682]: MultiTexCoord2sARB (offset 390) */ "iii\0" "glMultiTexCoord2s\0" "glMultiTexCoord2sARB\0" "\0" - /* _mesa_function_pool[15688]: VertexAttrib1dvARB (will be remapped) */ + /* _mesa_function_pool[15726]: VertexAttrib1dvARB (will be remapped) */ "ip\0" "glVertexAttrib1dv\0" "glVertexAttrib1dvARB\0" "\0" - /* _mesa_function_pool[15731]: DeleteTextures (offset 327) */ + /* _mesa_function_pool[15769]: DeleteTextures (offset 327) */ "ip\0" "glDeleteTextures\0" "glDeleteTexturesEXT\0" "\0" - /* _mesa_function_pool[15772]: TexCoordPointerEXT (will be remapped) */ + /* _mesa_function_pool[15810]: TexCoordPointerEXT (will be remapped) */ "iiiip\0" "glTexCoordPointerEXT\0" "\0" - /* _mesa_function_pool[15800]: TexSubImage4DSGIS (dynamic) */ + /* _mesa_function_pool[15838]: TexSubImage4DSGIS (dynamic) */ "iiiiiiiiiiiip\0" "glTexSubImage4DSGIS\0" "\0" - /* _mesa_function_pool[15835]: TexCoord3s (offset 116) */ + /* _mesa_function_pool[15873]: TexCoord3s (offset 116) */ "iii\0" "glTexCoord3s\0" "\0" - /* _mesa_function_pool[15853]: GetTexLevelParameteriv (offset 285) */ + /* _mesa_function_pool[15891]: GetTexLevelParameteriv (offset 285) */ "iiip\0" "glGetTexLevelParameteriv\0" "\0" - /* _mesa_function_pool[15884]: CombinerStageParameterfvNV (dynamic) */ + /* _mesa_function_pool[15922]: CombinerStageParameterfvNV (dynamic) */ "iip\0" "glCombinerStageParameterfvNV\0" "\0" - /* _mesa_function_pool[15918]: StopInstrumentsSGIX (dynamic) */ + /* _mesa_function_pool[15956]: StopInstrumentsSGIX (dynamic) */ "i\0" "glStopInstrumentsSGIX\0" "\0" - /* _mesa_function_pool[15943]: TexCoord4fColor4fNormal3fVertex4fSUN (dynamic) */ + /* _mesa_function_pool[15981]: TexCoord4fColor4fNormal3fVertex4fSUN (dynamic) */ "fffffffffffffff\0" "glTexCoord4fColor4fNormal3fVertex4fSUN\0" "\0" - /* _mesa_function_pool[15999]: ClearAccum (offset 204) */ + /* _mesa_function_pool[16037]: ClearAccum (offset 204) */ "ffff\0" "glClearAccum\0" "\0" - /* _mesa_function_pool[16018]: DeformSGIX (dynamic) */ + /* _mesa_function_pool[16056]: DeformSGIX (dynamic) */ "i\0" "glDeformSGIX\0" "\0" - /* _mesa_function_pool[16034]: GetVertexAttribfvARB (will be remapped) */ + /* _mesa_function_pool[16072]: GetVertexAttribfvARB (will be remapped) */ "iip\0" "glGetVertexAttribfv\0" "glGetVertexAttribfvARB\0" "\0" - /* _mesa_function_pool[16082]: SecondaryColor3ivEXT (will be remapped) */ + /* _mesa_function_pool[16120]: SecondaryColor3ivEXT (will be remapped) */ "p\0" "glSecondaryColor3iv\0" "glSecondaryColor3ivEXT\0" "\0" - /* _mesa_function_pool[16128]: TexCoord4iv (offset 123) */ + /* _mesa_function_pool[16166]: TexCoord4iv (offset 123) */ "p\0" "glTexCoord4iv\0" "\0" - /* _mesa_function_pool[16145]: VertexAttribI4uiEXT (will be remapped) */ + /* _mesa_function_pool[16183]: VertexAttribI4uiEXT (will be remapped) */ "iiiii\0" "glVertexAttribI4uiEXT\0" "glVertexAttribI4ui\0" "\0" - /* _mesa_function_pool[16193]: GetFragmentMaterialfvSGIX (dynamic) */ + /* _mesa_function_pool[16231]: GetFragmentMaterialfvSGIX (dynamic) */ "iip\0" "glGetFragmentMaterialfvSGIX\0" "\0" - /* _mesa_function_pool[16226]: UniformMatrix4x2fv (will be remapped) */ + /* _mesa_function_pool[16264]: UniformMatrix4x2fv (will be remapped) */ "iiip\0" "glUniformMatrix4x2fv\0" "\0" - /* _mesa_function_pool[16253]: GetDetailTexFuncSGIS (dynamic) */ + /* _mesa_function_pool[16291]: GetDetailTexFuncSGIS (dynamic) */ "ip\0" "glGetDetailTexFuncSGIS\0" "\0" - /* _mesa_function_pool[16280]: GetCombinerStageParameterfvNV (dynamic) */ + /* _mesa_function_pool[16318]: GetCombinerStageParameterfvNV (dynamic) */ "iip\0" "glGetCombinerStageParameterfvNV\0" "\0" - /* _mesa_function_pool[16317]: PolygonOffset (offset 319) */ + /* _mesa_function_pool[16355]: PolygonOffset (offset 319) */ "ff\0" "glPolygonOffset\0" "\0" - /* _mesa_function_pool[16337]: BindVertexArray (will be remapped) */ + /* _mesa_function_pool[16375]: BindVertexArray (will be remapped) */ "i\0" "glBindVertexArray\0" "\0" - /* _mesa_function_pool[16358]: Color4ubVertex2fvSUN (dynamic) */ + /* _mesa_function_pool[16396]: Color4ubVertex2fvSUN (dynamic) */ "pp\0" "glColor4ubVertex2fvSUN\0" "\0" - /* _mesa_function_pool[16385]: Rectd (offset 86) */ + /* _mesa_function_pool[16423]: Rectd (offset 86) */ "dddd\0" "glRectd\0" "\0" - /* _mesa_function_pool[16399]: TexFilterFuncSGIS (dynamic) */ + /* _mesa_function_pool[16437]: TexFilterFuncSGIS (dynamic) */ "iiip\0" "glTexFilterFuncSGIS\0" "\0" - /* _mesa_function_pool[16425]: SampleMaskSGIS (will be remapped) */ - "fi\0" - "glSampleMaskSGIS\0" - "glSampleMaskEXT\0" + /* _mesa_function_pool[16463]: TextureBarrierNV (will be remapped) */ + "\0" + "glTextureBarrierNV\0" "\0" - /* _mesa_function_pool[16462]: VertexAttribI4ubvEXT (will be remapped) */ + /* _mesa_function_pool[16484]: VertexAttribI4ubvEXT (will be remapped) */ "ip\0" "glVertexAttribI4ubvEXT\0" "glVertexAttribI4ubv\0" "\0" - /* _mesa_function_pool[16509]: GetAttribLocationARB (will be remapped) */ + /* _mesa_function_pool[16531]: GetAttribLocationARB (will be remapped) */ "ip\0" "glGetAttribLocation\0" "glGetAttribLocationARB\0" "\0" - /* _mesa_function_pool[16556]: RasterPos3i (offset 74) */ + /* _mesa_function_pool[16578]: RasterPos3i (offset 74) */ "iii\0" "glRasterPos3i\0" "\0" - /* _mesa_function_pool[16575]: VertexAttrib4ubvARB (will be remapped) */ + /* _mesa_function_pool[16597]: VertexAttrib4ubvARB (will be remapped) */ "ip\0" "glVertexAttrib4ubv\0" "glVertexAttrib4ubvARB\0" "\0" - /* _mesa_function_pool[16620]: DetailTexFuncSGIS (dynamic) */ + /* _mesa_function_pool[16642]: DetailTexFuncSGIS (dynamic) */ "iip\0" "glDetailTexFuncSGIS\0" "\0" - /* _mesa_function_pool[16645]: Normal3fVertex3fSUN (dynamic) */ + /* _mesa_function_pool[16667]: Normal3fVertex3fSUN (dynamic) */ "ffffff\0" "glNormal3fVertex3fSUN\0" "\0" - /* _mesa_function_pool[16675]: CopyTexImage2D (offset 324) */ + /* _mesa_function_pool[16697]: CopyTexImage2D (offset 324) */ "iiiiiiii\0" "glCopyTexImage2D\0" "glCopyTexImage2DEXT\0" "\0" - /* _mesa_function_pool[16722]: GetBufferPointervARB (will be remapped) */ + /* _mesa_function_pool[16744]: GetBufferPointervARB (will be remapped) */ "iip\0" "glGetBufferPointerv\0" "glGetBufferPointervARB\0" "\0" - /* _mesa_function_pool[16770]: ProgramEnvParameter4fARB (will be remapped) */ + /* _mesa_function_pool[16792]: ProgramEnvParameter4fARB (will be remapped) */ "iiffff\0" "glProgramEnvParameter4fARB\0" "glProgramParameter4fNV\0" "\0" - /* _mesa_function_pool[16828]: Uniform3ivARB (will be remapped) */ + /* _mesa_function_pool[16850]: Uniform3ivARB (will be remapped) */ "iip\0" "glUniform3iv\0" "glUniform3ivARB\0" "\0" - /* _mesa_function_pool[16862]: Lightfv (offset 160) */ + /* _mesa_function_pool[16884]: Lightfv (offset 160) */ "iip\0" "glLightfv\0" "\0" - /* _mesa_function_pool[16877]: PrimitiveRestartIndexNV (will be remapped) */ + /* _mesa_function_pool[16899]: PrimitiveRestartIndexNV (will be remapped) */ "i\0" "glPrimitiveRestartIndexNV\0" "glPrimitiveRestartIndex\0" "\0" - /* _mesa_function_pool[16930]: ClearDepth (offset 208) */ + /* _mesa_function_pool[16952]: ClearDepth (offset 208) */ "d\0" "glClearDepth\0" "\0" - /* _mesa_function_pool[16946]: GetFenceivNV (will be remapped) */ + /* _mesa_function_pool[16968]: GetFenceivNV (will be remapped) */ "iip\0" "glGetFenceivNV\0" "\0" - /* _mesa_function_pool[16966]: WindowPos4dvMESA (will be remapped) */ + /* _mesa_function_pool[16988]: WindowPos4dvMESA (will be remapped) */ "p\0" "glWindowPos4dvMESA\0" "\0" - /* _mesa_function_pool[16988]: ColorSubTable (offset 346) */ + /* _mesa_function_pool[17010]: ColorSubTable (offset 346) */ "iiiiip\0" "glColorSubTable\0" "glColorSubTableEXT\0" "\0" - /* _mesa_function_pool[17031]: Color4fv (offset 30) */ + /* _mesa_function_pool[17053]: Color4fv (offset 30) */ "p\0" "glColor4fv\0" "\0" - /* _mesa_function_pool[17045]: MultiTexCoord4ivARB (offset 405) */ + /* _mesa_function_pool[17067]: MultiTexCoord4ivARB (offset 405) */ "ip\0" "glMultiTexCoord4iv\0" "glMultiTexCoord4ivARB\0" "\0" - /* _mesa_function_pool[17090]: ProgramLocalParameters4fvEXT (will be remapped) */ + /* _mesa_function_pool[17112]: ProgramLocalParameters4fvEXT (will be remapped) */ "iiip\0" "glProgramLocalParameters4fvEXT\0" "\0" - /* _mesa_function_pool[17127]: ColorPointer (offset 308) */ + /* _mesa_function_pool[17149]: ColorPointer (offset 308) */ "iiip\0" "glColorPointer\0" "\0" - /* _mesa_function_pool[17148]: Rects (offset 92) */ + /* _mesa_function_pool[17170]: Rects (offset 92) */ "iiii\0" "glRects\0" "\0" - /* _mesa_function_pool[17162]: GetMapAttribParameterfvNV (dynamic) */ + /* _mesa_function_pool[17184]: GetMapAttribParameterfvNV (dynamic) */ "iiip\0" "glGetMapAttribParameterfvNV\0" "\0" - /* _mesa_function_pool[17196]: CreateShaderProgramEXT (will be remapped) */ + /* _mesa_function_pool[17218]: CreateShaderProgramEXT (will be remapped) */ "ip\0" "glCreateShaderProgramEXT\0" "\0" - /* _mesa_function_pool[17225]: ActiveProgramEXT (will be remapped) */ + /* _mesa_function_pool[17247]: ActiveProgramEXT (will be remapped) */ "i\0" "glActiveProgramEXT\0" "\0" - /* _mesa_function_pool[17247]: Lightiv (offset 162) */ + /* _mesa_function_pool[17269]: Lightiv (offset 162) */ "iip\0" "glLightiv\0" "\0" - /* _mesa_function_pool[17262]: VertexAttrib4sARB (will be remapped) */ + /* _mesa_function_pool[17284]: VertexAttrib4sARB (will be remapped) */ "iiiii\0" "glVertexAttrib4s\0" "glVertexAttrib4sARB\0" "\0" - /* _mesa_function_pool[17306]: GetQueryObjectuivARB (will be remapped) */ + /* _mesa_function_pool[17328]: GetQueryObjectuivARB (will be remapped) */ "iip\0" "glGetQueryObjectuiv\0" "glGetQueryObjectuivARB\0" "\0" - /* _mesa_function_pool[17354]: GetTexParameteriv (offset 283) */ + /* _mesa_function_pool[17376]: GetTexParameteriv (offset 283) */ "iip\0" "glGetTexParameteriv\0" "\0" - /* _mesa_function_pool[17379]: MapParameterivNV (dynamic) */ + /* _mesa_function_pool[17401]: MapParameterivNV (dynamic) */ "iip\0" "glMapParameterivNV\0" "\0" - /* _mesa_function_pool[17403]: GenRenderbuffersEXT (will be remapped) */ + /* _mesa_function_pool[17425]: GenRenderbuffersEXT (will be remapped) */ "ip\0" "glGenRenderbuffers\0" "glGenRenderbuffersEXT\0" "\0" - /* _mesa_function_pool[17448]: ClearBufferfv (will be remapped) */ + /* _mesa_function_pool[17470]: ClearBufferfv (will be remapped) */ "iip\0" "glClearBufferfv\0" "\0" - /* _mesa_function_pool[17469]: VertexAttrib2dvARB (will be remapped) */ + /* _mesa_function_pool[17491]: VertexAttrib2dvARB (will be remapped) */ "ip\0" "glVertexAttrib2dv\0" "glVertexAttrib2dvARB\0" "\0" - /* _mesa_function_pool[17512]: EdgeFlagPointerEXT (will be remapped) */ + /* _mesa_function_pool[17534]: EdgeFlagPointerEXT (will be remapped) */ "iip\0" "glEdgeFlagPointerEXT\0" "\0" - /* _mesa_function_pool[17538]: VertexAttribs2svNV (will be remapped) */ + /* _mesa_function_pool[17560]: VertexAttribs2svNV (will be remapped) */ "iip\0" "glVertexAttribs2svNV\0" "\0" - /* _mesa_function_pool[17564]: WeightbvARB (dynamic) */ + /* _mesa_function_pool[17586]: WeightbvARB (dynamic) */ "ip\0" "glWeightbvARB\0" "\0" - /* _mesa_function_pool[17582]: VertexAttrib2fvARB (will be remapped) */ + /* _mesa_function_pool[17604]: VertexAttrib2fvARB (will be remapped) */ "ip\0" "glVertexAttrib2fv\0" "glVertexAttrib2fvARB\0" "\0" - /* _mesa_function_pool[17625]: GetBufferParameterivARB (will be remapped) */ + /* _mesa_function_pool[17647]: GetBufferParameterivARB (will be remapped) */ "iip\0" "glGetBufferParameteriv\0" "glGetBufferParameterivARB\0" "\0" - /* _mesa_function_pool[17679]: Rectdv (offset 87) */ + /* _mesa_function_pool[17701]: Rectdv (offset 87) */ "pp\0" "glRectdv\0" "\0" - /* _mesa_function_pool[17692]: ListParameteriSGIX (dynamic) */ + /* _mesa_function_pool[17714]: ListParameteriSGIX (dynamic) */ "iii\0" "glListParameteriSGIX\0" "\0" - /* _mesa_function_pool[17718]: ReplacementCodeuiColor4fNormal3fVertex3fSUN (dynamic) */ + /* _mesa_function_pool[17740]: BlendEquationiARB (will be remapped) */ + "ii\0" + "glBlendEquationiARB\0" + "\0" + /* _mesa_function_pool[17764]: ReplacementCodeuiColor4fNormal3fVertex3fSUN (dynamic) */ "iffffffffff\0" "glReplacementCodeuiColor4fNormal3fVertex3fSUN\0" "\0" - /* _mesa_function_pool[17777]: InstrumentsBufferSGIX (dynamic) */ + /* _mesa_function_pool[17823]: InstrumentsBufferSGIX (dynamic) */ "ip\0" "glInstrumentsBufferSGIX\0" "\0" - /* _mesa_function_pool[17805]: VertexAttrib4NivARB (will be remapped) */ + /* _mesa_function_pool[17851]: VertexAttrib4NivARB (will be remapped) */ "ip\0" "glVertexAttrib4Niv\0" "glVertexAttrib4NivARB\0" "\0" - /* _mesa_function_pool[17850]: DrawArraysInstancedARB (will be remapped) */ + /* _mesa_function_pool[17896]: DrawArraysInstancedARB (will be remapped) */ "iiii\0" "glDrawArraysInstancedARB\0" "glDrawArraysInstancedEXT\0" "glDrawArraysInstanced\0" "\0" - /* _mesa_function_pool[17928]: GetAttachedShaders (will be remapped) */ + /* _mesa_function_pool[17974]: GetAttachedShaders (will be remapped) */ "iipp\0" "glGetAttachedShaders\0" "\0" - /* _mesa_function_pool[17955]: GenVertexArraysAPPLE (will be remapped) */ + /* _mesa_function_pool[18001]: GenVertexArraysAPPLE (will be remapped) */ "ip\0" "glGenVertexArraysAPPLE\0" "\0" - /* _mesa_function_pool[17982]: ClearBufferfi (will be remapped) */ + /* _mesa_function_pool[18028]: ClearBufferfi (will be remapped) */ "iifi\0" "glClearBufferfi\0" "\0" - /* _mesa_function_pool[18004]: Materialiv (offset 172) */ + /* _mesa_function_pool[18050]: Materialiv (offset 172) */ "iip\0" "glMaterialiv\0" "\0" - /* _mesa_function_pool[18022]: PushClientAttrib (offset 335) */ + /* _mesa_function_pool[18068]: PushClientAttrib (offset 335) */ "i\0" "glPushClientAttrib\0" "\0" - /* _mesa_function_pool[18044]: ProgramEnvParameters4fvEXT (will be remapped) */ + /* _mesa_function_pool[18090]: ProgramEnvParameters4fvEXT (will be remapped) */ "iiip\0" "glProgramEnvParameters4fvEXT\0" "\0" - /* _mesa_function_pool[18079]: TexCoord2fColor4fNormal3fVertex3fvSUN (dynamic) */ + /* _mesa_function_pool[18125]: TexCoord2fColor4fNormal3fVertex3fvSUN (dynamic) */ "pppp\0" "glTexCoord2fColor4fNormal3fVertex3fvSUN\0" "\0" - /* _mesa_function_pool[18125]: WindowPos2iMESA (will be remapped) */ + /* _mesa_function_pool[18171]: WindowPos2iMESA (will be remapped) */ "ii\0" "glWindowPos2i\0" "glWindowPos2iARB\0" "glWindowPos2iMESA\0" "\0" - /* _mesa_function_pool[18178]: SecondaryColor3fvEXT (will be remapped) */ + /* _mesa_function_pool[18224]: SampleMaskSGIS (will be remapped) */ + "fi\0" + "glSampleMaskSGIS\0" + "glSampleMaskEXT\0" + "\0" + /* _mesa_function_pool[18261]: SecondaryColor3fvEXT (will be remapped) */ "p\0" "glSecondaryColor3fv\0" "glSecondaryColor3fvEXT\0" "\0" - /* _mesa_function_pool[18224]: PolygonMode (offset 174) */ + /* _mesa_function_pool[18307]: PolygonMode (offset 174) */ "ii\0" "glPolygonMode\0" "\0" - /* _mesa_function_pool[18242]: CompressedTexSubImage1DARB (will be remapped) */ + /* _mesa_function_pool[18325]: CompressedTexSubImage1DARB (will be remapped) */ "iiiiiip\0" "glCompressedTexSubImage1D\0" "glCompressedTexSubImage1DARB\0" "\0" - /* _mesa_function_pool[18306]: VertexAttribI1iEXT (will be remapped) */ + /* _mesa_function_pool[18389]: VertexAttribI1iEXT (will be remapped) */ "ii\0" "glVertexAttribI1iEXT\0" "glVertexAttribI1i\0" "\0" - /* _mesa_function_pool[18349]: GetVertexAttribivNV (will be remapped) */ + /* _mesa_function_pool[18432]: GetVertexAttribivNV (will be remapped) */ "iip\0" "glGetVertexAttribivNV\0" "\0" - /* _mesa_function_pool[18376]: GetProgramStringARB (will be remapped) */ + /* _mesa_function_pool[18459]: GetProgramStringARB (will be remapped) */ "iip\0" "glGetProgramStringARB\0" "\0" - /* _mesa_function_pool[18403]: VertexAttribIPointerEXT (will be remapped) */ + /* _mesa_function_pool[18486]: VertexAttribIPointerEXT (will be remapped) */ "iiiip\0" "glVertexAttribIPointerEXT\0" "glVertexAttribIPointer\0" "\0" - /* _mesa_function_pool[18459]: TexBumpParameterfvATI (will be remapped) */ + /* _mesa_function_pool[18542]: TexBumpParameterfvATI (will be remapped) */ "ip\0" "glTexBumpParameterfvATI\0" "\0" - /* _mesa_function_pool[18487]: CompileShaderARB (will be remapped) */ + /* _mesa_function_pool[18570]: CompileShaderARB (will be remapped) */ "i\0" "glCompileShader\0" "glCompileShaderARB\0" "\0" - /* _mesa_function_pool[18525]: DeleteShader (will be remapped) */ + /* _mesa_function_pool[18608]: DeleteShader (will be remapped) */ "i\0" "glDeleteShader\0" "\0" - /* _mesa_function_pool[18543]: DisableClientState (offset 309) */ + /* _mesa_function_pool[18626]: DisableClientState (offset 309) */ "i\0" "glDisableClientState\0" "\0" - /* _mesa_function_pool[18567]: TexGeni (offset 192) */ + /* _mesa_function_pool[18650]: TexGeni (offset 192) */ "iii\0" "glTexGeni\0" "\0" - /* _mesa_function_pool[18582]: TexGenf (offset 190) */ + /* _mesa_function_pool[18665]: TexGenf (offset 190) */ "iif\0" "glTexGenf\0" "\0" - /* _mesa_function_pool[18597]: Uniform3fARB (will be remapped) */ + /* _mesa_function_pool[18680]: Uniform3fARB (will be remapped) */ "ifff\0" "glUniform3f\0" "glUniform3fARB\0" "\0" - /* _mesa_function_pool[18630]: TexGend (offset 188) */ + /* _mesa_function_pool[18713]: TexGend (offset 188) */ "iid\0" "glTexGend\0" "\0" - /* _mesa_function_pool[18645]: ListParameterfvSGIX (dynamic) */ + /* _mesa_function_pool[18728]: ListParameterfvSGIX (dynamic) */ "iip\0" "glListParameterfvSGIX\0" "\0" - /* _mesa_function_pool[18672]: GetPolygonStipple (offset 274) */ + /* _mesa_function_pool[18755]: GetPolygonStipple (offset 274) */ "p\0" "glGetPolygonStipple\0" "\0" - /* _mesa_function_pool[18695]: Tangent3dvEXT (dynamic) */ + /* _mesa_function_pool[18778]: Tangent3dvEXT (dynamic) */ "p\0" "glTangent3dvEXT\0" "\0" - /* _mesa_function_pool[18714]: BindBufferOffsetEXT (will be remapped) */ + /* _mesa_function_pool[18797]: BindBufferOffsetEXT (will be remapped) */ "iiii\0" "glBindBufferOffsetEXT\0" "\0" - /* _mesa_function_pool[18742]: WindowPos3sMESA (will be remapped) */ + /* _mesa_function_pool[18825]: WindowPos3sMESA (will be remapped) */ "iii\0" "glWindowPos3s\0" "glWindowPos3sARB\0" "glWindowPos3sMESA\0" "\0" - /* _mesa_function_pool[18796]: VertexAttrib2svNV (will be remapped) */ + /* _mesa_function_pool[18879]: VertexAttrib2svNV (will be remapped) */ "ip\0" "glVertexAttrib2svNV\0" "\0" - /* _mesa_function_pool[18820]: DisableIndexedEXT (will be remapped) */ + /* _mesa_function_pool[18903]: DisableIndexedEXT (will be remapped) */ "ii\0" "glDisableIndexedEXT\0" "glDisablei\0" "\0" - /* _mesa_function_pool[18855]: BindBufferBaseEXT (will be remapped) */ + /* _mesa_function_pool[18938]: BindBufferBaseEXT (will be remapped) */ "iii\0" "glBindBufferBaseEXT\0" "glBindBufferBase\0" "\0" - /* _mesa_function_pool[18897]: TexCoord2fVertex3fvSUN (dynamic) */ + /* _mesa_function_pool[18980]: TexCoord2fVertex3fvSUN (dynamic) */ "pp\0" "glTexCoord2fVertex3fvSUN\0" "\0" - /* _mesa_function_pool[18926]: WindowPos4sMESA (will be remapped) */ + /* _mesa_function_pool[19009]: WindowPos4sMESA (will be remapped) */ "iiii\0" "glWindowPos4sMESA\0" "\0" - /* _mesa_function_pool[18950]: VertexAttrib4NuivARB (will be remapped) */ + /* _mesa_function_pool[19033]: VertexAttrib4NuivARB (will be remapped) */ "ip\0" "glVertexAttrib4Nuiv\0" "glVertexAttrib4NuivARB\0" "\0" - /* _mesa_function_pool[18997]: ClientActiveTextureARB (offset 375) */ + /* _mesa_function_pool[19080]: ClientActiveTextureARB (offset 375) */ "i\0" "glClientActiveTexture\0" "glClientActiveTextureARB\0" "\0" - /* _mesa_function_pool[19047]: PixelTexGenSGIX (will be remapped) */ + /* _mesa_function_pool[19130]: PixelTexGenSGIX (will be remapped) */ "i\0" "glPixelTexGenSGIX\0" "\0" - /* _mesa_function_pool[19068]: ReplacementCodeusvSUN (dynamic) */ + /* _mesa_function_pool[19151]: ReplacementCodeusvSUN (dynamic) */ "p\0" "glReplacementCodeusvSUN\0" "\0" - /* _mesa_function_pool[19095]: Uniform4fARB (will be remapped) */ + /* _mesa_function_pool[19178]: Uniform4fARB (will be remapped) */ "iffff\0" "glUniform4f\0" "glUniform4fARB\0" "\0" - /* _mesa_function_pool[19129]: Color4sv (offset 34) */ + /* _mesa_function_pool[19212]: Color4sv (offset 34) */ "p\0" "glColor4sv\0" "\0" - /* _mesa_function_pool[19143]: FlushMappedBufferRange (will be remapped) */ + /* _mesa_function_pool[19226]: FlushMappedBufferRange (will be remapped) */ "iii\0" "glFlushMappedBufferRange\0" "\0" - /* _mesa_function_pool[19173]: IsProgramNV (will be remapped) */ + /* _mesa_function_pool[19256]: IsProgramNV (will be remapped) */ "i\0" "glIsProgramARB\0" "glIsProgramNV\0" "\0" - /* _mesa_function_pool[19205]: FlushMappedBufferRangeAPPLE (will be remapped) */ + /* _mesa_function_pool[19288]: FlushMappedBufferRangeAPPLE (will be remapped) */ "iii\0" "glFlushMappedBufferRangeAPPLE\0" "\0" - /* _mesa_function_pool[19240]: PixelZoom (offset 246) */ + /* _mesa_function_pool[19323]: PixelZoom (offset 246) */ "ff\0" "glPixelZoom\0" "\0" - /* _mesa_function_pool[19256]: ReplacementCodePointerSUN (dynamic) */ + /* _mesa_function_pool[19339]: ReplacementCodePointerSUN (dynamic) */ "iip\0" "glReplacementCodePointerSUN\0" "\0" - /* _mesa_function_pool[19289]: ProgramEnvParameter4dARB (will be remapped) */ + /* _mesa_function_pool[19372]: ProgramEnvParameter4dARB (will be remapped) */ "iidddd\0" "glProgramEnvParameter4dARB\0" "glProgramParameter4dNV\0" "\0" - /* _mesa_function_pool[19347]: ColorTableParameterfv (offset 340) */ + /* _mesa_function_pool[19430]: ColorTableParameterfv (offset 340) */ "iip\0" "glColorTableParameterfv\0" "glColorTableParameterfvSGI\0" "\0" - /* _mesa_function_pool[19403]: FragmentLightModelfSGIX (dynamic) */ + /* _mesa_function_pool[19486]: FragmentLightModelfSGIX (dynamic) */ "if\0" "glFragmentLightModelfSGIX\0" "\0" - /* _mesa_function_pool[19433]: Binormal3bvEXT (dynamic) */ + /* _mesa_function_pool[19516]: Binormal3bvEXT (dynamic) */ "p\0" "glBinormal3bvEXT\0" "\0" - /* _mesa_function_pool[19453]: PixelMapuiv (offset 252) */ + /* _mesa_function_pool[19536]: PixelMapuiv (offset 252) */ "iip\0" "glPixelMapuiv\0" "\0" - /* _mesa_function_pool[19472]: Color3dv (offset 12) */ + /* _mesa_function_pool[19555]: Color3dv (offset 12) */ "p\0" "glColor3dv\0" "\0" - /* _mesa_function_pool[19486]: IsTexture (offset 330) */ + /* _mesa_function_pool[19569]: IsTexture (offset 330) */ "i\0" "glIsTexture\0" "glIsTextureEXT\0" "\0" - /* _mesa_function_pool[19516]: VertexWeightfvEXT (dynamic) */ + /* _mesa_function_pool[19599]: VertexWeightfvEXT (dynamic) */ "p\0" "glVertexWeightfvEXT\0" "\0" - /* _mesa_function_pool[19539]: VertexAttrib1dARB (will be remapped) */ + /* _mesa_function_pool[19622]: VertexAttrib1dARB (will be remapped) */ "id\0" "glVertexAttrib1d\0" "glVertexAttrib1dARB\0" "\0" - /* _mesa_function_pool[19580]: ImageTransformParameterivHP (dynamic) */ + /* _mesa_function_pool[19663]: ImageTransformParameterivHP (dynamic) */ "iip\0" "glImageTransformParameterivHP\0" "\0" - /* _mesa_function_pool[19615]: TexCoord4i (offset 122) */ + /* _mesa_function_pool[19698]: TexCoord4i (offset 122) */ "iiii\0" "glTexCoord4i\0" "\0" - /* _mesa_function_pool[19634]: DeleteQueriesARB (will be remapped) */ + /* _mesa_function_pool[19717]: DeleteQueriesARB (will be remapped) */ "ip\0" "glDeleteQueries\0" "glDeleteQueriesARB\0" "\0" - /* _mesa_function_pool[19673]: Color4ubVertex2fSUN (dynamic) */ + /* _mesa_function_pool[19756]: Color4ubVertex2fSUN (dynamic) */ "iiiiff\0" "glColor4ubVertex2fSUN\0" "\0" - /* _mesa_function_pool[19703]: FragmentColorMaterialSGIX (dynamic) */ + /* _mesa_function_pool[19786]: FragmentColorMaterialSGIX (dynamic) */ "ii\0" "glFragmentColorMaterialSGIX\0" "\0" - /* _mesa_function_pool[19735]: CurrentPaletteMatrixARB (dynamic) */ + /* _mesa_function_pool[19818]: CurrentPaletteMatrixARB (dynamic) */ "i\0" "glCurrentPaletteMatrixARB\0" "\0" - /* _mesa_function_pool[19764]: GetMapdv (offset 266) */ + /* _mesa_function_pool[19847]: GetMapdv (offset 266) */ "iip\0" "glGetMapdv\0" "\0" - /* _mesa_function_pool[19780]: ObjectPurgeableAPPLE (will be remapped) */ + /* _mesa_function_pool[19863]: ObjectPurgeableAPPLE (will be remapped) */ "iii\0" "glObjectPurgeableAPPLE\0" "\0" - /* _mesa_function_pool[19808]: GetStringi (will be remapped) */ + /* _mesa_function_pool[19891]: GetStringi (will be remapped) */ "ii\0" "glGetStringi\0" "\0" - /* _mesa_function_pool[19825]: SamplePatternSGIS (will be remapped) */ + /* _mesa_function_pool[19908]: SamplePatternSGIS (will be remapped) */ "i\0" "glSamplePatternSGIS\0" "glSamplePatternEXT\0" "\0" - /* _mesa_function_pool[19867]: PixelStoref (offset 249) */ + /* _mesa_function_pool[19950]: PixelStoref (offset 249) */ "if\0" "glPixelStoref\0" "\0" - /* _mesa_function_pool[19885]: IsQueryARB (will be remapped) */ + /* _mesa_function_pool[19968]: IsQueryARB (will be remapped) */ "i\0" "glIsQuery\0" "glIsQueryARB\0" "\0" - /* _mesa_function_pool[19911]: ReplacementCodeuiColor4ubVertex3fSUN (dynamic) */ + /* _mesa_function_pool[19994]: ReplacementCodeuiColor4ubVertex3fSUN (dynamic) */ "iiiiifff\0" "glReplacementCodeuiColor4ubVertex3fSUN\0" "\0" - /* _mesa_function_pool[19960]: PixelStorei (offset 250) */ + /* _mesa_function_pool[20043]: PixelStorei (offset 250) */ "ii\0" "glPixelStorei\0" "\0" - /* _mesa_function_pool[19978]: VertexAttrib4usvARB (will be remapped) */ + /* _mesa_function_pool[20061]: VertexAttrib4usvARB (will be remapped) */ "ip\0" "glVertexAttrib4usv\0" "glVertexAttrib4usvARB\0" "\0" - /* _mesa_function_pool[20023]: LinkProgramARB (will be remapped) */ + /* _mesa_function_pool[20106]: LinkProgramARB (will be remapped) */ "i\0" "glLinkProgram\0" "glLinkProgramARB\0" "\0" - /* _mesa_function_pool[20057]: VertexAttrib2fNV (will be remapped) */ + /* _mesa_function_pool[20140]: VertexAttrib2fNV (will be remapped) */ "iff\0" "glVertexAttrib2fNV\0" "\0" - /* _mesa_function_pool[20081]: ShaderSourceARB (will be remapped) */ + /* _mesa_function_pool[20164]: ShaderSourceARB (will be remapped) */ "iipp\0" "glShaderSource\0" "glShaderSourceARB\0" "\0" - /* _mesa_function_pool[20120]: FragmentMaterialiSGIX (dynamic) */ + /* _mesa_function_pool[20203]: FragmentMaterialiSGIX (dynamic) */ "iii\0" "glFragmentMaterialiSGIX\0" "\0" - /* _mesa_function_pool[20149]: EvalCoord2dv (offset 233) */ + /* _mesa_function_pool[20232]: EvalCoord2dv (offset 233) */ "p\0" "glEvalCoord2dv\0" "\0" - /* _mesa_function_pool[20167]: VertexAttrib3svARB (will be remapped) */ + /* _mesa_function_pool[20250]: VertexAttrib3svARB (will be remapped) */ "ip\0" "glVertexAttrib3sv\0" "glVertexAttrib3svARB\0" "\0" - /* _mesa_function_pool[20210]: ColorMaterial (offset 151) */ + /* _mesa_function_pool[20293]: ColorMaterial (offset 151) */ "ii\0" "glColorMaterial\0" "\0" - /* _mesa_function_pool[20230]: CompressedTexSubImage3DARB (will be remapped) */ + /* _mesa_function_pool[20313]: CompressedTexSubImage3DARB (will be remapped) */ "iiiiiiiiiip\0" "glCompressedTexSubImage3D\0" "glCompressedTexSubImage3DARB\0" "\0" - /* _mesa_function_pool[20298]: WindowPos2ivMESA (will be remapped) */ + /* _mesa_function_pool[20381]: WindowPos2ivMESA (will be remapped) */ "p\0" "glWindowPos2iv\0" "glWindowPos2ivARB\0" "glWindowPos2ivMESA\0" "\0" - /* _mesa_function_pool[20353]: IsFramebufferEXT (will be remapped) */ + /* _mesa_function_pool[20436]: IsFramebufferEXT (will be remapped) */ "i\0" "glIsFramebuffer\0" "glIsFramebufferEXT\0" "\0" - /* _mesa_function_pool[20391]: Uniform4ivARB (will be remapped) */ + /* _mesa_function_pool[20474]: Uniform4ivARB (will be remapped) */ "iip\0" "glUniform4iv\0" "glUniform4ivARB\0" "\0" - /* _mesa_function_pool[20425]: GetVertexAttribdvARB (will be remapped) */ + /* _mesa_function_pool[20508]: GetVertexAttribdvARB (will be remapped) */ "iip\0" "glGetVertexAttribdv\0" "glGetVertexAttribdvARB\0" "\0" - /* _mesa_function_pool[20473]: TexBumpParameterivATI (will be remapped) */ + /* _mesa_function_pool[20556]: TexBumpParameterivATI (will be remapped) */ "ip\0" "glTexBumpParameterivATI\0" "\0" - /* _mesa_function_pool[20501]: GetSeparableFilter (offset 359) */ + /* _mesa_function_pool[20584]: GetSeparableFilter (offset 359) */ "iiippp\0" "glGetSeparableFilter\0" "glGetSeparableFilterEXT\0" "\0" - /* _mesa_function_pool[20554]: Binormal3dEXT (dynamic) */ + /* _mesa_function_pool[20637]: Binormal3dEXT (dynamic) */ "ddd\0" "glBinormal3dEXT\0" "\0" - /* _mesa_function_pool[20575]: SpriteParameteriSGIX (dynamic) */ + /* _mesa_function_pool[20658]: SpriteParameteriSGIX (dynamic) */ "ii\0" "glSpriteParameteriSGIX\0" "\0" - /* _mesa_function_pool[20602]: RequestResidentProgramsNV (will be remapped) */ + /* _mesa_function_pool[20685]: RequestResidentProgramsNV (will be remapped) */ "ip\0" "glRequestResidentProgramsNV\0" "\0" - /* _mesa_function_pool[20634]: TagSampleBufferSGIX (dynamic) */ + /* _mesa_function_pool[20717]: TagSampleBufferSGIX (dynamic) */ "\0" "glTagSampleBufferSGIX\0" "\0" - /* _mesa_function_pool[20658]: TransformFeedbackVaryingsEXT (will be remapped) */ + /* _mesa_function_pool[20741]: TransformFeedbackVaryingsEXT (will be remapped) */ "iipi\0" "glTransformFeedbackVaryingsEXT\0" "glTransformFeedbackVaryings\0" "\0" - /* _mesa_function_pool[20723]: FeedbackBuffer (offset 194) */ + /* _mesa_function_pool[20806]: FeedbackBuffer (offset 194) */ "iip\0" "glFeedbackBuffer\0" "\0" - /* _mesa_function_pool[20745]: RasterPos2iv (offset 67) */ + /* _mesa_function_pool[20828]: RasterPos2iv (offset 67) */ "p\0" "glRasterPos2iv\0" "\0" - /* _mesa_function_pool[20763]: TexImage1D (offset 182) */ + /* _mesa_function_pool[20846]: TexImage1D (offset 182) */ "iiiiiiip\0" "glTexImage1D\0" "\0" - /* _mesa_function_pool[20786]: ListParameterivSGIX (dynamic) */ + /* _mesa_function_pool[20869]: ListParameterivSGIX (dynamic) */ "iip\0" "glListParameterivSGIX\0" "\0" - /* _mesa_function_pool[20813]: MultiDrawElementsEXT (will be remapped) */ + /* _mesa_function_pool[20896]: MultiDrawElementsEXT (will be remapped) */ "ipipi\0" "glMultiDrawElements\0" "glMultiDrawElementsEXT\0" "\0" - /* _mesa_function_pool[20863]: Color3s (offset 17) */ + /* _mesa_function_pool[20946]: Color3s (offset 17) */ "iii\0" "glColor3s\0" "\0" - /* _mesa_function_pool[20878]: Uniform1ivARB (will be remapped) */ + /* _mesa_function_pool[20961]: Uniform1ivARB (will be remapped) */ "iip\0" "glUniform1iv\0" "glUniform1ivARB\0" "\0" - /* _mesa_function_pool[20912]: WindowPos2sMESA (will be remapped) */ + /* _mesa_function_pool[20995]: WindowPos2sMESA (will be remapped) */ "ii\0" "glWindowPos2s\0" "glWindowPos2sARB\0" "glWindowPos2sMESA\0" "\0" - /* _mesa_function_pool[20965]: WeightusvARB (dynamic) */ + /* _mesa_function_pool[21048]: WeightusvARB (dynamic) */ "ip\0" "glWeightusvARB\0" "\0" - /* _mesa_function_pool[20984]: TexCoordPointer (offset 320) */ + /* _mesa_function_pool[21067]: TexCoordPointer (offset 320) */ "iiip\0" "glTexCoordPointer\0" "\0" - /* _mesa_function_pool[21008]: FogCoordPointerEXT (will be remapped) */ + /* _mesa_function_pool[21091]: FogCoordPointerEXT (will be remapped) */ "iip\0" "glFogCoordPointer\0" "glFogCoordPointerEXT\0" "\0" - /* _mesa_function_pool[21052]: IndexMaterialEXT (dynamic) */ + /* _mesa_function_pool[21135]: IndexMaterialEXT (dynamic) */ "ii\0" "glIndexMaterialEXT\0" "\0" - /* _mesa_function_pool[21075]: Color3i (offset 15) */ + /* _mesa_function_pool[21158]: Color3i (offset 15) */ "iii\0" "glColor3i\0" "\0" - /* _mesa_function_pool[21090]: FrontFace (offset 157) */ + /* _mesa_function_pool[21173]: FrontFace (offset 157) */ "i\0" "glFrontFace\0" "\0" - /* _mesa_function_pool[21105]: EvalCoord2d (offset 232) */ + /* _mesa_function_pool[21188]: EvalCoord2d (offset 232) */ "dd\0" "glEvalCoord2d\0" "\0" - /* _mesa_function_pool[21123]: SecondaryColor3ubvEXT (will be remapped) */ + /* _mesa_function_pool[21206]: SecondaryColor3ubvEXT (will be remapped) */ "p\0" "glSecondaryColor3ubv\0" "glSecondaryColor3ubvEXT\0" "\0" - /* _mesa_function_pool[21171]: EvalCoord2f (offset 234) */ + /* _mesa_function_pool[21254]: EvalCoord2f (offset 234) */ "ff\0" "glEvalCoord2f\0" "\0" - /* _mesa_function_pool[21189]: VertexAttrib4dvARB (will be remapped) */ + /* _mesa_function_pool[21272]: VertexAttrib4dvARB (will be remapped) */ "ip\0" "glVertexAttrib4dv\0" "glVertexAttrib4dvARB\0" "\0" - /* _mesa_function_pool[21232]: BindAttribLocationARB (will be remapped) */ + /* _mesa_function_pool[21315]: BindAttribLocationARB (will be remapped) */ "iip\0" "glBindAttribLocation\0" "glBindAttribLocationARB\0" "\0" - /* _mesa_function_pool[21282]: Color3b (offset 9) */ + /* _mesa_function_pool[21365]: Color3b (offset 9) */ "iii\0" "glColor3b\0" "\0" - /* _mesa_function_pool[21297]: MultiTexCoord2dARB (offset 384) */ + /* _mesa_function_pool[21380]: MultiTexCoord2dARB (offset 384) */ "idd\0" "glMultiTexCoord2d\0" "glMultiTexCoord2dARB\0" "\0" - /* _mesa_function_pool[21341]: ExecuteProgramNV (will be remapped) */ + /* _mesa_function_pool[21424]: ExecuteProgramNV (will be remapped) */ "iip\0" "glExecuteProgramNV\0" "\0" - /* _mesa_function_pool[21365]: Color3f (offset 13) */ + /* _mesa_function_pool[21448]: Color3f (offset 13) */ "fff\0" "glColor3f\0" "\0" - /* _mesa_function_pool[21380]: LightEnviSGIX (dynamic) */ + /* _mesa_function_pool[21463]: LightEnviSGIX (dynamic) */ "ii\0" "glLightEnviSGIX\0" "\0" - /* _mesa_function_pool[21400]: Color3d (offset 11) */ + /* _mesa_function_pool[21483]: Color3d (offset 11) */ "ddd\0" "glColor3d\0" "\0" - /* _mesa_function_pool[21415]: Normal3dv (offset 55) */ + /* _mesa_function_pool[21498]: Normal3dv (offset 55) */ "p\0" "glNormal3dv\0" "\0" - /* _mesa_function_pool[21430]: Lightf (offset 159) */ + /* _mesa_function_pool[21513]: Lightf (offset 159) */ "iif\0" "glLightf\0" "\0" - /* _mesa_function_pool[21444]: ReplacementCodeuiSUN (dynamic) */ + /* _mesa_function_pool[21527]: ReplacementCodeuiSUN (dynamic) */ "i\0" "glReplacementCodeuiSUN\0" "\0" - /* _mesa_function_pool[21470]: MatrixMode (offset 293) */ + /* _mesa_function_pool[21553]: MatrixMode (offset 293) */ "i\0" "glMatrixMode\0" "\0" - /* _mesa_function_pool[21486]: GetPixelMapusv (offset 273) */ + /* _mesa_function_pool[21569]: GetPixelMapusv (offset 273) */ "ip\0" "glGetPixelMapusv\0" "\0" - /* _mesa_function_pool[21507]: Lighti (offset 161) */ + /* _mesa_function_pool[21590]: Lighti (offset 161) */ "iii\0" "glLighti\0" "\0" - /* _mesa_function_pool[21521]: VertexAttribPointerNV (will be remapped) */ + /* _mesa_function_pool[21604]: VertexAttribPointerNV (will be remapped) */ "iiiip\0" "glVertexAttribPointerNV\0" "\0" - /* _mesa_function_pool[21552]: GetBooleanIndexedvEXT (will be remapped) */ + /* _mesa_function_pool[21635]: ClearDepthf (will be remapped) */ + "f\0" + "glClearDepthf\0" + "\0" + /* _mesa_function_pool[21652]: GetBooleanIndexedvEXT (will be remapped) */ "iip\0" "glGetBooleanIndexedvEXT\0" "glGetBooleani_v\0" "\0" - /* _mesa_function_pool[21597]: GetFramebufferAttachmentParameterivEXT (will be remapped) */ + /* _mesa_function_pool[21697]: GetFramebufferAttachmentParameterivEXT (will be remapped) */ "iiip\0" "glGetFramebufferAttachmentParameteriv\0" "glGetFramebufferAttachmentParameterivEXT\0" "\0" - /* _mesa_function_pool[21682]: PixelTransformParameterfEXT (dynamic) */ + /* _mesa_function_pool[21782]: PixelTransformParameterfEXT (dynamic) */ "iif\0" "glPixelTransformParameterfEXT\0" "\0" - /* _mesa_function_pool[21717]: MultiTexCoord4dvARB (offset 401) */ + /* _mesa_function_pool[21817]: MultiTexCoord4dvARB (offset 401) */ "ip\0" "glMultiTexCoord4dv\0" "glMultiTexCoord4dvARB\0" "\0" - /* _mesa_function_pool[21762]: PixelTransformParameteriEXT (dynamic) */ + /* _mesa_function_pool[21862]: PixelTransformParameteriEXT (dynamic) */ "iii\0" "glPixelTransformParameteriEXT\0" "\0" - /* _mesa_function_pool[21797]: GetDoublev (offset 260) */ + /* _mesa_function_pool[21897]: GetDoublev (offset 260) */ "ip\0" "glGetDoublev\0" "\0" - /* _mesa_function_pool[21814]: MultMatrixd (offset 295) */ + /* _mesa_function_pool[21914]: MultMatrixd (offset 295) */ "p\0" "glMultMatrixd\0" "\0" - /* _mesa_function_pool[21831]: MultMatrixf (offset 294) */ + /* _mesa_function_pool[21931]: MultMatrixf (offset 294) */ "p\0" "glMultMatrixf\0" "\0" - /* _mesa_function_pool[21848]: VertexAttribI4bvEXT (will be remapped) */ + /* _mesa_function_pool[21948]: VertexAttribI4bvEXT (will be remapped) */ "ip\0" "glVertexAttribI4bvEXT\0" "glVertexAttribI4bv\0" "\0" - /* _mesa_function_pool[21893]: TexCoord2fColor4ubVertex3fSUN (dynamic) */ + /* _mesa_function_pool[21993]: TexCoord2fColor4ubVertex3fSUN (dynamic) */ "ffiiiifff\0" "glTexCoord2fColor4ubVertex3fSUN\0" "\0" - /* _mesa_function_pool[21936]: Uniform1iARB (will be remapped) */ + /* _mesa_function_pool[22036]: Uniform1iARB (will be remapped) */ "ii\0" "glUniform1i\0" "glUniform1iARB\0" "\0" - /* _mesa_function_pool[21967]: VertexAttribPointerARB (will be remapped) */ + /* _mesa_function_pool[22067]: VertexAttribPointerARB (will be remapped) */ "iiiiip\0" "glVertexAttribPointer\0" "glVertexAttribPointerARB\0" "\0" - /* _mesa_function_pool[22022]: VertexAttrib3sNV (will be remapped) */ + /* _mesa_function_pool[22122]: VertexAttrib3sNV (will be remapped) */ "iiii\0" "glVertexAttrib3sNV\0" "\0" - /* _mesa_function_pool[22047]: SharpenTexFuncSGIS (dynamic) */ + /* _mesa_function_pool[22147]: SharpenTexFuncSGIS (dynamic) */ "iip\0" "glSharpenTexFuncSGIS\0" "\0" - /* _mesa_function_pool[22073]: MultiTexCoord4fvARB (offset 403) */ + /* _mesa_function_pool[22173]: MultiTexCoord4fvARB (offset 403) */ "ip\0" "glMultiTexCoord4fv\0" "glMultiTexCoord4fvARB\0" "\0" - /* _mesa_function_pool[22118]: Uniform2uiEXT (will be remapped) */ + /* _mesa_function_pool[22218]: Uniform2uiEXT (will be remapped) */ "iii\0" "glUniform2uiEXT\0" "glUniform2ui\0" "\0" - /* _mesa_function_pool[22152]: UniformMatrix2x3fv (will be remapped) */ + /* _mesa_function_pool[22252]: UniformMatrix2x3fv (will be remapped) */ "iiip\0" "glUniformMatrix2x3fv\0" "\0" - /* _mesa_function_pool[22179]: TrackMatrixNV (will be remapped) */ + /* _mesa_function_pool[22279]: TrackMatrixNV (will be remapped) */ "iiii\0" "glTrackMatrixNV\0" "\0" - /* _mesa_function_pool[22201]: CombinerParameteriNV (will be remapped) */ + /* _mesa_function_pool[22301]: CombinerParameteriNV (will be remapped) */ "ii\0" "glCombinerParameteriNV\0" "\0" - /* _mesa_function_pool[22228]: DeleteAsyncMarkersSGIX (dynamic) */ + /* _mesa_function_pool[22328]: DeleteAsyncMarkersSGIX (dynamic) */ "ii\0" "glDeleteAsyncMarkersSGIX\0" "\0" - /* _mesa_function_pool[22257]: ReplacementCodeusSUN (dynamic) */ + /* _mesa_function_pool[22357]: ReplacementCodeusSUN (dynamic) */ "i\0" "glReplacementCodeusSUN\0" "\0" - /* _mesa_function_pool[22283]: IsAsyncMarkerSGIX (dynamic) */ + /* _mesa_function_pool[22383]: IsAsyncMarkerSGIX (dynamic) */ "i\0" "glIsAsyncMarkerSGIX\0" "\0" - /* _mesa_function_pool[22306]: FrameZoomSGIX (dynamic) */ + /* _mesa_function_pool[22406]: FrameZoomSGIX (dynamic) */ "i\0" "glFrameZoomSGIX\0" "\0" - /* _mesa_function_pool[22325]: Normal3fVertex3fvSUN (dynamic) */ + /* _mesa_function_pool[22425]: Normal3fVertex3fvSUN (dynamic) */ "pp\0" "glNormal3fVertex3fvSUN\0" "\0" - /* _mesa_function_pool[22352]: RasterPos4sv (offset 85) */ + /* _mesa_function_pool[22452]: RasterPos4sv (offset 85) */ "p\0" "glRasterPos4sv\0" "\0" - /* _mesa_function_pool[22370]: VertexAttrib4NsvARB (will be remapped) */ + /* _mesa_function_pool[22470]: VertexAttrib4NsvARB (will be remapped) */ "ip\0" "glVertexAttrib4Nsv\0" "glVertexAttrib4NsvARB\0" "\0" - /* _mesa_function_pool[22415]: VertexAttrib3fvARB (will be remapped) */ + /* _mesa_function_pool[22515]: VertexAttrib3fvARB (will be remapped) */ "ip\0" "glVertexAttrib3fv\0" "glVertexAttrib3fvARB\0" "\0" - /* _mesa_function_pool[22458]: ClearColor (offset 206) */ + /* _mesa_function_pool[22558]: ClearColor (offset 206) */ "ffff\0" "glClearColor\0" "\0" - /* _mesa_function_pool[22477]: GetSynciv (will be remapped) */ + /* _mesa_function_pool[22577]: GetSynciv (will be remapped) */ "iiipp\0" "glGetSynciv\0" "\0" - /* _mesa_function_pool[22496]: ClearColorIiEXT (will be remapped) */ + /* _mesa_function_pool[22596]: ClearColorIiEXT (will be remapped) */ "iiii\0" "glClearColorIiEXT\0" "\0" - /* _mesa_function_pool[22520]: DeleteFramebuffersEXT (will be remapped) */ + /* _mesa_function_pool[22620]: DeleteFramebuffersEXT (will be remapped) */ "ip\0" "glDeleteFramebuffers\0" "glDeleteFramebuffersEXT\0" "\0" - /* _mesa_function_pool[22569]: GlobalAlphaFactorsSUN (dynamic) */ + /* _mesa_function_pool[22669]: GlobalAlphaFactorsSUN (dynamic) */ "i\0" "glGlobalAlphaFactorsSUN\0" "\0" - /* _mesa_function_pool[22596]: IsEnabledIndexedEXT (will be remapped) */ + /* _mesa_function_pool[22696]: IsEnabledIndexedEXT (will be remapped) */ "ii\0" "glIsEnabledIndexedEXT\0" "glIsEnabledi\0" "\0" - /* _mesa_function_pool[22635]: TexEnviv (offset 187) */ + /* _mesa_function_pool[22735]: TexEnviv (offset 187) */ "iip\0" "glTexEnviv\0" "\0" - /* _mesa_function_pool[22651]: TexSubImage3D (offset 372) */ + /* _mesa_function_pool[22751]: TexSubImage3D (offset 372) */ "iiiiiiiiiip\0" "glTexSubImage3D\0" "glTexSubImage3DEXT\0" "\0" - /* _mesa_function_pool[22699]: Tangent3fEXT (dynamic) */ + /* _mesa_function_pool[22799]: Tangent3fEXT (dynamic) */ "fff\0" "glTangent3fEXT\0" "\0" - /* _mesa_function_pool[22719]: SecondaryColor3uivEXT (will be remapped) */ + /* _mesa_function_pool[22819]: SecondaryColor3uivEXT (will be remapped) */ "p\0" "glSecondaryColor3uiv\0" "glSecondaryColor3uivEXT\0" "\0" - /* _mesa_function_pool[22767]: MatrixIndexubvARB (dynamic) */ + /* _mesa_function_pool[22867]: MatrixIndexubvARB (dynamic) */ "ip\0" "glMatrixIndexubvARB\0" "\0" - /* _mesa_function_pool[22791]: Color4fNormal3fVertex3fSUN (dynamic) */ + /* _mesa_function_pool[22891]: Color4fNormal3fVertex3fSUN (dynamic) */ "ffffffffff\0" "glColor4fNormal3fVertex3fSUN\0" "\0" - /* _mesa_function_pool[22832]: PixelTexGenParameterfSGIS (will be remapped) */ + /* _mesa_function_pool[22932]: PixelTexGenParameterfSGIS (will be remapped) */ "if\0" "glPixelTexGenParameterfSGIS\0" "\0" - /* _mesa_function_pool[22864]: CreateShader (will be remapped) */ + /* _mesa_function_pool[22964]: CreateShader (will be remapped) */ "i\0" "glCreateShader\0" "\0" - /* _mesa_function_pool[22882]: GetColorTableParameterfv (offset 344) */ + /* _mesa_function_pool[22982]: GetColorTableParameterfv (offset 344) */ "iip\0" "glGetColorTableParameterfv\0" "glGetColorTableParameterfvSGI\0" "glGetColorTableParameterfvEXT\0" "\0" - /* _mesa_function_pool[22974]: FragmentLightModelfvSGIX (dynamic) */ + /* _mesa_function_pool[23074]: FragmentLightModelfvSGIX (dynamic) */ "ip\0" "glFragmentLightModelfvSGIX\0" "\0" - /* _mesa_function_pool[23005]: Bitmap (offset 8) */ + /* _mesa_function_pool[23105]: Bitmap (offset 8) */ "iiffffp\0" "glBitmap\0" "\0" - /* _mesa_function_pool[23023]: MultiTexCoord3fARB (offset 394) */ + /* _mesa_function_pool[23123]: MultiTexCoord3fARB (offset 394) */ "ifff\0" "glMultiTexCoord3f\0" "glMultiTexCoord3fARB\0" "\0" - /* _mesa_function_pool[23068]: GetTexLevelParameterfv (offset 284) */ + /* _mesa_function_pool[23168]: GetTexLevelParameterfv (offset 284) */ "iiip\0" "glGetTexLevelParameterfv\0" "\0" - /* _mesa_function_pool[23099]: GetPixelTexGenParameterfvSGIS (will be remapped) */ + /* _mesa_function_pool[23199]: GetPixelTexGenParameterfvSGIS (will be remapped) */ "ip\0" "glGetPixelTexGenParameterfvSGIS\0" "\0" - /* _mesa_function_pool[23135]: GenFramebuffersEXT (will be remapped) */ + /* _mesa_function_pool[23235]: GenFramebuffersEXT (will be remapped) */ "ip\0" "glGenFramebuffers\0" "glGenFramebuffersEXT\0" "\0" - /* _mesa_function_pool[23178]: VertexAttribDivisor (will be remapped) */ + /* _mesa_function_pool[23278]: VertexAttribDivisor (will be remapped) */ "ii\0" "glVertexAttribDivisor\0" "\0" - /* _mesa_function_pool[23204]: GetProgramParameterdvNV (will be remapped) */ + /* _mesa_function_pool[23304]: GetProgramParameterdvNV (will be remapped) */ "iiip\0" "glGetProgramParameterdvNV\0" "\0" - /* _mesa_function_pool[23236]: Vertex2sv (offset 133) */ + /* _mesa_function_pool[23336]: Vertex2sv (offset 133) */ "p\0" "glVertex2sv\0" "\0" - /* _mesa_function_pool[23251]: GetIntegerv (offset 263) */ + /* _mesa_function_pool[23351]: GetIntegerv (offset 263) */ "ip\0" "glGetIntegerv\0" "\0" - /* _mesa_function_pool[23269]: IsVertexArrayAPPLE (will be remapped) */ + /* _mesa_function_pool[23369]: IsVertexArrayAPPLE (will be remapped) */ "i\0" "glIsVertexArray\0" "glIsVertexArrayAPPLE\0" "\0" - /* _mesa_function_pool[23309]: FragmentLightfvSGIX (dynamic) */ + /* _mesa_function_pool[23409]: FragmentLightfvSGIX (dynamic) */ "iip\0" "glFragmentLightfvSGIX\0" "\0" - /* _mesa_function_pool[23336]: DetachShader (will be remapped) */ + /* _mesa_function_pool[23436]: VertexAttribDivisorARB (will be remapped) */ + "ii\0" + "glVertexAttribDivisorARB\0" + "\0" + /* _mesa_function_pool[23465]: DetachShader (will be remapped) */ "ii\0" "glDetachShader\0" "\0" - /* _mesa_function_pool[23355]: VertexAttrib4NubARB (will be remapped) */ + /* _mesa_function_pool[23484]: VertexAttrib4NubARB (will be remapped) */ "iiiii\0" "glVertexAttrib4Nub\0" "glVertexAttrib4NubARB\0" "\0" - /* _mesa_function_pool[23403]: GetProgramEnvParameterfvARB (will be remapped) */ + /* _mesa_function_pool[23532]: GetProgramEnvParameterfvARB (will be remapped) */ "iip\0" "glGetProgramEnvParameterfvARB\0" "\0" - /* _mesa_function_pool[23438]: GetTrackMatrixivNV (will be remapped) */ + /* _mesa_function_pool[23567]: GetTrackMatrixivNV (will be remapped) */ "iiip\0" "glGetTrackMatrixivNV\0" "\0" - /* _mesa_function_pool[23465]: VertexAttrib3svNV (will be remapped) */ + /* _mesa_function_pool[23594]: VertexAttrib3svNV (will be remapped) */ "ip\0" "glVertexAttrib3svNV\0" "\0" - /* _mesa_function_pool[23489]: Uniform4fvARB (will be remapped) */ + /* _mesa_function_pool[23618]: Uniform4fvARB (will be remapped) */ "iip\0" "glUniform4fv\0" "glUniform4fvARB\0" "\0" - /* _mesa_function_pool[23523]: MultTransposeMatrixfARB (will be remapped) */ + /* _mesa_function_pool[23652]: MultTransposeMatrixfARB (will be remapped) */ "p\0" "glMultTransposeMatrixf\0" "glMultTransposeMatrixfARB\0" "\0" - /* _mesa_function_pool[23575]: GetTexEnviv (offset 277) */ + /* _mesa_function_pool[23704]: GetTexEnviv (offset 277) */ "iip\0" "glGetTexEnviv\0" "\0" - /* _mesa_function_pool[23594]: ColorFragmentOp1ATI (will be remapped) */ + /* _mesa_function_pool[23723]: ColorFragmentOp1ATI (will be remapped) */ "iiiiiii\0" "glColorFragmentOp1ATI\0" "\0" - /* _mesa_function_pool[23625]: GetUniformfvARB (will be remapped) */ + /* _mesa_function_pool[23754]: GetUniformfvARB (will be remapped) */ "iip\0" "glGetUniformfv\0" "glGetUniformfvARB\0" "\0" - /* _mesa_function_pool[23663]: EGLImageTargetRenderbufferStorageOES (will be remapped) */ + /* _mesa_function_pool[23792]: EGLImageTargetRenderbufferStorageOES (will be remapped) */ "ip\0" "glEGLImageTargetRenderbufferStorageOES\0" "\0" - /* _mesa_function_pool[23706]: VertexAttribI2ivEXT (will be remapped) */ + /* _mesa_function_pool[23835]: VertexAttribI2ivEXT (will be remapped) */ "ip\0" "glVertexAttribI2ivEXT\0" "glVertexAttribI2iv\0" "\0" - /* _mesa_function_pool[23751]: PopClientAttrib (offset 334) */ + /* _mesa_function_pool[23880]: PopClientAttrib (offset 334) */ "\0" "glPopClientAttrib\0" "\0" - /* _mesa_function_pool[23771]: ReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN (dynamic) */ + /* _mesa_function_pool[23900]: ReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN (dynamic) */ "iffffffffffff\0" "glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN\0" "\0" - /* _mesa_function_pool[23842]: DetachObjectARB (will be remapped) */ + /* _mesa_function_pool[23971]: DetachObjectARB (will be remapped) */ "ii\0" "glDetachObjectARB\0" "\0" - /* _mesa_function_pool[23864]: VertexBlendARB (dynamic) */ + /* _mesa_function_pool[23993]: VertexBlendARB (dynamic) */ "i\0" "glVertexBlendARB\0" "\0" - /* _mesa_function_pool[23884]: WindowPos3iMESA (will be remapped) */ + /* _mesa_function_pool[24013]: WindowPos3iMESA (will be remapped) */ "iii\0" "glWindowPos3i\0" "glWindowPos3iARB\0" "glWindowPos3iMESA\0" "\0" - /* _mesa_function_pool[23938]: SeparableFilter2D (offset 360) */ + /* _mesa_function_pool[24067]: SeparableFilter2D (offset 360) */ "iiiiiipp\0" "glSeparableFilter2D\0" "glSeparableFilter2DEXT\0" "\0" - /* _mesa_function_pool[23991]: ProgramParameteriARB (will be remapped) */ + /* _mesa_function_pool[24120]: ProgramParameteriARB (will be remapped) */ "iii\0" "glProgramParameteriARB\0" "\0" - /* _mesa_function_pool[24019]: Map1d (offset 220) */ + /* _mesa_function_pool[24148]: Map1d (offset 220) */ "iddiip\0" "glMap1d\0" "\0" - /* _mesa_function_pool[24035]: Map1f (offset 221) */ + /* _mesa_function_pool[24164]: Map1f (offset 221) */ "iffiip\0" "glMap1f\0" "\0" - /* _mesa_function_pool[24051]: CompressedTexImage2DARB (will be remapped) */ + /* _mesa_function_pool[24180]: CompressedTexImage2DARB (will be remapped) */ "iiiiiiip\0" "glCompressedTexImage2D\0" "glCompressedTexImage2DARB\0" "\0" - /* _mesa_function_pool[24110]: ArrayElement (offset 306) */ + /* _mesa_function_pool[24239]: ArrayElement (offset 306) */ "i\0" "glArrayElement\0" "glArrayElementEXT\0" "\0" - /* _mesa_function_pool[24146]: TexImage2D (offset 183) */ + /* _mesa_function_pool[24275]: TexImage2D (offset 183) */ "iiiiiiiip\0" "glTexImage2D\0" "\0" - /* _mesa_function_pool[24170]: DepthBoundsEXT (will be remapped) */ + /* _mesa_function_pool[24299]: DepthBoundsEXT (will be remapped) */ "dd\0" "glDepthBoundsEXT\0" "\0" - /* _mesa_function_pool[24191]: ProgramParameters4fvNV (will be remapped) */ + /* _mesa_function_pool[24320]: ProgramParameters4fvNV (will be remapped) */ "iiip\0" "glProgramParameters4fvNV\0" "\0" - /* _mesa_function_pool[24222]: DeformationMap3fSGIX (dynamic) */ + /* _mesa_function_pool[24351]: DeformationMap3fSGIX (dynamic) */ "iffiiffiiffiip\0" "glDeformationMap3fSGIX\0" "\0" - /* _mesa_function_pool[24261]: GetProgramivNV (will be remapped) */ + /* _mesa_function_pool[24390]: GetProgramivNV (will be remapped) */ "iip\0" "glGetProgramivNV\0" "\0" - /* _mesa_function_pool[24283]: GetFragDataLocationEXT (will be remapped) */ + /* _mesa_function_pool[24412]: GetFragDataLocationEXT (will be remapped) */ "ip\0" "glGetFragDataLocationEXT\0" "glGetFragDataLocation\0" "\0" - /* _mesa_function_pool[24334]: GetMinmaxParameteriv (offset 366) */ + /* _mesa_function_pool[24463]: GetMinmaxParameteriv (offset 366) */ "iip\0" "glGetMinmaxParameteriv\0" "glGetMinmaxParameterivEXT\0" "\0" - /* _mesa_function_pool[24388]: PixelTransferf (offset 247) */ + /* _mesa_function_pool[24517]: PixelTransferf (offset 247) */ "if\0" "glPixelTransferf\0" "\0" - /* _mesa_function_pool[24409]: CopyTexImage1D (offset 323) */ + /* _mesa_function_pool[24538]: CopyTexImage1D (offset 323) */ "iiiiiii\0" "glCopyTexImage1D\0" "glCopyTexImage1DEXT\0" "\0" - /* _mesa_function_pool[24455]: PushMatrix (offset 298) */ + /* _mesa_function_pool[24584]: PushMatrix (offset 298) */ "\0" "glPushMatrix\0" "\0" - /* _mesa_function_pool[24470]: Fogiv (offset 156) */ + /* _mesa_function_pool[24599]: Fogiv (offset 156) */ "ip\0" "glFogiv\0" "\0" - /* _mesa_function_pool[24482]: TexCoord1dv (offset 95) */ + /* _mesa_function_pool[24611]: TexCoord1dv (offset 95) */ "p\0" "glTexCoord1dv\0" "\0" - /* _mesa_function_pool[24499]: AlphaFragmentOp3ATI (will be remapped) */ + /* _mesa_function_pool[24628]: AlphaFragmentOp3ATI (will be remapped) */ "iiiiiiiiiiii\0" "glAlphaFragmentOp3ATI\0" "\0" - /* _mesa_function_pool[24535]: PixelTransferi (offset 248) */ + /* _mesa_function_pool[24664]: PixelTransferi (offset 248) */ "ii\0" "glPixelTransferi\0" "\0" - /* _mesa_function_pool[24556]: GetVertexAttribdvNV (will be remapped) */ + /* _mesa_function_pool[24685]: GetVertexAttribdvNV (will be remapped) */ "iip\0" "glGetVertexAttribdvNV\0" "\0" - /* _mesa_function_pool[24583]: VertexAttrib3fvNV (will be remapped) */ + /* _mesa_function_pool[24712]: VertexAttrib3fvNV (will be remapped) */ "ip\0" "glVertexAttrib3fvNV\0" "\0" - /* _mesa_function_pool[24607]: Rotatef (offset 300) */ + /* _mesa_function_pool[24736]: Rotatef (offset 300) */ "ffff\0" "glRotatef\0" "\0" - /* _mesa_function_pool[24623]: GetFinalCombinerInputParameterivNV (will be remapped) */ + /* _mesa_function_pool[24752]: GetFinalCombinerInputParameterivNV (will be remapped) */ "iip\0" "glGetFinalCombinerInputParameterivNV\0" "\0" - /* _mesa_function_pool[24665]: Vertex3i (offset 138) */ + /* _mesa_function_pool[24794]: Vertex3i (offset 138) */ "iii\0" "glVertex3i\0" "\0" - /* _mesa_function_pool[24681]: Vertex3f (offset 136) */ + /* _mesa_function_pool[24810]: Vertex3f (offset 136) */ "fff\0" "glVertex3f\0" "\0" - /* _mesa_function_pool[24697]: Clear (offset 203) */ + /* _mesa_function_pool[24826]: Clear (offset 203) */ "i\0" "glClear\0" "\0" - /* _mesa_function_pool[24708]: Vertex3d (offset 134) */ + /* _mesa_function_pool[24837]: Vertex3d (offset 134) */ "ddd\0" "glVertex3d\0" "\0" - /* _mesa_function_pool[24724]: GetMapParameterivNV (dynamic) */ + /* _mesa_function_pool[24853]: GetMapParameterivNV (dynamic) */ "iip\0" "glGetMapParameterivNV\0" "\0" - /* _mesa_function_pool[24751]: Uniform4iARB (will be remapped) */ + /* _mesa_function_pool[24880]: Uniform4iARB (will be remapped) */ "iiiii\0" "glUniform4i\0" "glUniform4iARB\0" "\0" - /* _mesa_function_pool[24785]: ReadBuffer (offset 254) */ + /* _mesa_function_pool[24914]: ReadBuffer (offset 254) */ "i\0" "glReadBuffer\0" "\0" - /* _mesa_function_pool[24801]: ConvolutionParameteri (offset 352) */ + /* _mesa_function_pool[24930]: ConvolutionParameteri (offset 352) */ "iii\0" "glConvolutionParameteri\0" "glConvolutionParameteriEXT\0" "\0" - /* _mesa_function_pool[24857]: Ortho (offset 296) */ + /* _mesa_function_pool[24986]: Ortho (offset 296) */ "dddddd\0" "glOrtho\0" "\0" - /* _mesa_function_pool[24873]: Binormal3sEXT (dynamic) */ + /* _mesa_function_pool[25002]: Binormal3sEXT (dynamic) */ "iii\0" "glBinormal3sEXT\0" "\0" - /* _mesa_function_pool[24894]: ListBase (offset 6) */ + /* _mesa_function_pool[25023]: ListBase (offset 6) */ "i\0" "glListBase\0" "\0" - /* _mesa_function_pool[24908]: Vertex3s (offset 140) */ + /* _mesa_function_pool[25037]: Vertex3s (offset 140) */ "iii\0" "glVertex3s\0" "\0" - /* _mesa_function_pool[24924]: ConvolutionParameterf (offset 350) */ + /* _mesa_function_pool[25053]: ConvolutionParameterf (offset 350) */ "iif\0" "glConvolutionParameterf\0" "glConvolutionParameterfEXT\0" "\0" - /* _mesa_function_pool[24980]: GetColorTableParameteriv (offset 345) */ + /* _mesa_function_pool[25109]: GetColorTableParameteriv (offset 345) */ "iip\0" "glGetColorTableParameteriv\0" "glGetColorTableParameterivSGI\0" "glGetColorTableParameterivEXT\0" "\0" - /* _mesa_function_pool[25072]: ProgramEnvParameter4dvARB (will be remapped) */ + /* _mesa_function_pool[25201]: ProgramEnvParameter4dvARB (will be remapped) */ "iip\0" "glProgramEnvParameter4dvARB\0" "glProgramParameter4dvNV\0" "\0" - /* _mesa_function_pool[25129]: ShadeModel (offset 177) */ + /* _mesa_function_pool[25258]: ShadeModel (offset 177) */ "i\0" "glShadeModel\0" "\0" - /* _mesa_function_pool[25145]: VertexAttribs2fvNV (will be remapped) */ + /* _mesa_function_pool[25274]: VertexAttribs2fvNV (will be remapped) */ "iip\0" "glVertexAttribs2fvNV\0" "\0" - /* _mesa_function_pool[25171]: Rectiv (offset 91) */ + /* _mesa_function_pool[25300]: Rectiv (offset 91) */ "pp\0" "glRectiv\0" "\0" - /* _mesa_function_pool[25184]: UseProgramObjectARB (will be remapped) */ + /* _mesa_function_pool[25313]: UseProgramObjectARB (will be remapped) */ "i\0" "glUseProgram\0" "glUseProgramObjectARB\0" "\0" - /* _mesa_function_pool[25222]: GetMapParameterfvNV (dynamic) */ + /* _mesa_function_pool[25351]: GetMapParameterfvNV (dynamic) */ "iip\0" "glGetMapParameterfvNV\0" "\0" - /* _mesa_function_pool[25249]: EndConditionalRenderNV (will be remapped) */ + /* _mesa_function_pool[25378]: EndConditionalRenderNV (will be remapped) */ "\0" "glEndConditionalRenderNV\0" "glEndConditionalRender\0" "\0" - /* _mesa_function_pool[25299]: PassTexCoordATI (will be remapped) */ + /* _mesa_function_pool[25428]: PassTexCoordATI (will be remapped) */ "iii\0" "glPassTexCoordATI\0" "\0" - /* _mesa_function_pool[25322]: DeleteProgram (will be remapped) */ + /* _mesa_function_pool[25451]: DeleteProgram (will be remapped) */ "i\0" "glDeleteProgram\0" "\0" - /* _mesa_function_pool[25341]: Tangent3ivEXT (dynamic) */ + /* _mesa_function_pool[25470]: Tangent3ivEXT (dynamic) */ "p\0" "glTangent3ivEXT\0" "\0" - /* _mesa_function_pool[25360]: Tangent3dEXT (dynamic) */ + /* _mesa_function_pool[25489]: Tangent3dEXT (dynamic) */ "ddd\0" "glTangent3dEXT\0" "\0" - /* _mesa_function_pool[25380]: SecondaryColor3dvEXT (will be remapped) */ + /* _mesa_function_pool[25509]: SecondaryColor3dvEXT (will be remapped) */ "p\0" "glSecondaryColor3dv\0" "glSecondaryColor3dvEXT\0" "\0" - /* _mesa_function_pool[25426]: Vertex2fv (offset 129) */ + /* _mesa_function_pool[25555]: AlphaFragmentOp2ATI (will be remapped) */ + "iiiiiiiii\0" + "glAlphaFragmentOp2ATI\0" + "\0" + /* _mesa_function_pool[25588]: Vertex2fv (offset 129) */ "p\0" "glVertex2fv\0" "\0" - /* _mesa_function_pool[25441]: MultiDrawArraysEXT (will be remapped) */ + /* _mesa_function_pool[25603]: MultiDrawArraysEXT (will be remapped) */ "ippi\0" "glMultiDrawArrays\0" "glMultiDrawArraysEXT\0" "\0" - /* _mesa_function_pool[25486]: BindRenderbufferEXT (will be remapped) */ + /* _mesa_function_pool[25648]: BindRenderbufferEXT (will be remapped) */ "ii\0" "glBindRenderbuffer\0" "glBindRenderbufferEXT\0" "\0" - /* _mesa_function_pool[25531]: MultiTexCoord4dARB (offset 400) */ + /* _mesa_function_pool[25693]: MultiTexCoord4dARB (offset 400) */ "idddd\0" "glMultiTexCoord4d\0" "glMultiTexCoord4dARB\0" "\0" - /* _mesa_function_pool[25577]: FramebufferTextureFaceARB (will be remapped) */ + /* _mesa_function_pool[25739]: FramebufferTextureFaceARB (will be remapped) */ "iiiii\0" "glFramebufferTextureFaceARB\0" "\0" - /* _mesa_function_pool[25612]: Vertex3sv (offset 141) */ + /* _mesa_function_pool[25774]: Vertex3sv (offset 141) */ "p\0" "glVertex3sv\0" "\0" - /* _mesa_function_pool[25627]: SecondaryColor3usEXT (will be remapped) */ + /* _mesa_function_pool[25789]: SecondaryColor3usEXT (will be remapped) */ "iii\0" "glSecondaryColor3us\0" "glSecondaryColor3usEXT\0" "\0" - /* _mesa_function_pool[25675]: ProgramLocalParameter4fvARB (will be remapped) */ + /* _mesa_function_pool[25837]: ProgramLocalParameter4fvARB (will be remapped) */ "iip\0" "glProgramLocalParameter4fvARB\0" "\0" - /* _mesa_function_pool[25710]: DeleteProgramsNV (will be remapped) */ + /* _mesa_function_pool[25872]: DeleteProgramsNV (will be remapped) */ "ip\0" "glDeleteProgramsARB\0" "glDeleteProgramsNV\0" "\0" - /* _mesa_function_pool[25753]: EvalMesh1 (offset 236) */ + /* _mesa_function_pool[25915]: EvalMesh1 (offset 236) */ "iii\0" "glEvalMesh1\0" "\0" - /* _mesa_function_pool[25770]: PauseTransformFeedback (will be remapped) */ + /* _mesa_function_pool[25932]: PauseTransformFeedback (will be remapped) */ "\0" "glPauseTransformFeedback\0" "\0" - /* _mesa_function_pool[25797]: MultiTexCoord1sARB (offset 382) */ + /* _mesa_function_pool[25959]: MultiTexCoord1sARB (offset 382) */ "ii\0" "glMultiTexCoord1s\0" "glMultiTexCoord1sARB\0" "\0" - /* _mesa_function_pool[25840]: ReplacementCodeuiColor3fVertex3fSUN (dynamic) */ + /* _mesa_function_pool[26002]: ReplacementCodeuiColor3fVertex3fSUN (dynamic) */ "iffffff\0" "glReplacementCodeuiColor3fVertex3fSUN\0" "\0" - /* _mesa_function_pool[25887]: GetVertexAttribPointervNV (will be remapped) */ + /* _mesa_function_pool[26049]: GetVertexAttribPointervNV (will be remapped) */ "iip\0" "glGetVertexAttribPointerv\0" "glGetVertexAttribPointervARB\0" "glGetVertexAttribPointervNV\0" "\0" - /* _mesa_function_pool[25975]: VertexAttribs1fvNV (will be remapped) */ + /* _mesa_function_pool[26137]: VertexAttribs1fvNV (will be remapped) */ "iip\0" "glVertexAttribs1fvNV\0" "\0" - /* _mesa_function_pool[26001]: MultiTexCoord1dvARB (offset 377) */ + /* _mesa_function_pool[26163]: MultiTexCoord1dvARB (offset 377) */ "ip\0" "glMultiTexCoord1dv\0" "glMultiTexCoord1dvARB\0" "\0" - /* _mesa_function_pool[26046]: Uniform2iARB (will be remapped) */ + /* _mesa_function_pool[26208]: Uniform2iARB (will be remapped) */ "iii\0" "glUniform2i\0" "glUniform2iARB\0" "\0" - /* _mesa_function_pool[26078]: Vertex2iv (offset 131) */ + /* _mesa_function_pool[26240]: Vertex2iv (offset 131) */ "p\0" "glVertex2iv\0" "\0" - /* _mesa_function_pool[26093]: GetProgramStringNV (will be remapped) */ + /* _mesa_function_pool[26255]: GetProgramStringNV (will be remapped) */ "iip\0" "glGetProgramStringNV\0" "\0" - /* _mesa_function_pool[26119]: ColorPointerEXT (will be remapped) */ + /* _mesa_function_pool[26281]: ColorPointerEXT (will be remapped) */ "iiiip\0" "glColorPointerEXT\0" "\0" - /* _mesa_function_pool[26144]: LineWidth (offset 168) */ + /* _mesa_function_pool[26306]: LineWidth (offset 168) */ "f\0" "glLineWidth\0" "\0" - /* _mesa_function_pool[26159]: MapBufferARB (will be remapped) */ + /* _mesa_function_pool[26321]: MapBufferARB (will be remapped) */ "ii\0" "glMapBuffer\0" "glMapBufferARB\0" "\0" - /* _mesa_function_pool[26190]: MultiDrawElementsBaseVertex (will be remapped) */ + /* _mesa_function_pool[26352]: MultiDrawElementsBaseVertex (will be remapped) */ "ipipip\0" "glMultiDrawElementsBaseVertex\0" "\0" - /* _mesa_function_pool[26228]: TexParameterIuivEXT (will be remapped) */ + /* _mesa_function_pool[26390]: TexParameterIuivEXT (will be remapped) */ "iip\0" "glTexParameterIuivEXT\0" "glTexParameterIuiv\0" "\0" - /* _mesa_function_pool[26274]: Binormal3svEXT (dynamic) */ + /* _mesa_function_pool[26436]: Binormal3svEXT (dynamic) */ "p\0" "glBinormal3svEXT\0" "\0" - /* _mesa_function_pool[26294]: ApplyTextureEXT (dynamic) */ + /* _mesa_function_pool[26456]: ApplyTextureEXT (dynamic) */ "i\0" "glApplyTextureEXT\0" "\0" - /* _mesa_function_pool[26315]: GetBufferParameteri64v (will be remapped) */ + /* _mesa_function_pool[26477]: GetBufferParameteri64v (will be remapped) */ "iip\0" "glGetBufferParameteri64v\0" "\0" - /* _mesa_function_pool[26345]: TexGendv (offset 189) */ + /* _mesa_function_pool[26507]: TexGendv (offset 189) */ "iip\0" "glTexGendv\0" "\0" - /* _mesa_function_pool[26361]: VertexAttribI3iEXT (will be remapped) */ + /* _mesa_function_pool[26523]: VertexAttribI3iEXT (will be remapped) */ "iiii\0" "glVertexAttribI3iEXT\0" "glVertexAttribI3i\0" "\0" - /* _mesa_function_pool[26406]: EnableIndexedEXT (will be remapped) */ + /* _mesa_function_pool[26568]: EnableIndexedEXT (will be remapped) */ "ii\0" "glEnableIndexedEXT\0" "glEnablei\0" "\0" - /* _mesa_function_pool[26439]: TextureMaterialEXT (dynamic) */ + /* _mesa_function_pool[26601]: TextureMaterialEXT (dynamic) */ "ii\0" "glTextureMaterialEXT\0" "\0" - /* _mesa_function_pool[26464]: TextureLightEXT (dynamic) */ + /* _mesa_function_pool[26626]: TextureLightEXT (dynamic) */ "i\0" "glTextureLightEXT\0" "\0" - /* _mesa_function_pool[26485]: ResetMinmax (offset 370) */ + /* _mesa_function_pool[26647]: ResetMinmax (offset 370) */ "i\0" "glResetMinmax\0" "glResetMinmaxEXT\0" "\0" - /* _mesa_function_pool[26519]: SpriteParameterfSGIX (dynamic) */ + /* _mesa_function_pool[26681]: SpriteParameterfSGIX (dynamic) */ "if\0" "glSpriteParameterfSGIX\0" "\0" - /* _mesa_function_pool[26546]: EnableClientState (offset 313) */ + /* _mesa_function_pool[26708]: EnableClientState (offset 313) */ "i\0" "glEnableClientState\0" "\0" - /* _mesa_function_pool[26569]: VertexAttrib4sNV (will be remapped) */ + /* _mesa_function_pool[26731]: VertexAttrib4sNV (will be remapped) */ "iiiii\0" "glVertexAttrib4sNV\0" "\0" - /* _mesa_function_pool[26595]: GetConvolutionParameterfv (offset 357) */ + /* _mesa_function_pool[26757]: GetConvolutionParameterfv (offset 357) */ "iip\0" "glGetConvolutionParameterfv\0" "glGetConvolutionParameterfvEXT\0" "\0" - /* _mesa_function_pool[26659]: VertexAttribs4dvNV (will be remapped) */ + /* _mesa_function_pool[26821]: VertexAttribs4dvNV (will be remapped) */ "iip\0" "glVertexAttribs4dvNV\0" "\0" - /* _mesa_function_pool[26685]: VertexAttrib4dARB (will be remapped) */ + /* _mesa_function_pool[26847]: MultiModeDrawArraysIBM (will be remapped) */ + "pppii\0" + "glMultiModeDrawArraysIBM\0" + "\0" + /* _mesa_function_pool[26879]: VertexAttrib4dARB (will be remapped) */ "idddd\0" "glVertexAttrib4d\0" "glVertexAttrib4dARB\0" "\0" - /* _mesa_function_pool[26729]: GetTexBumpParameterfvATI (will be remapped) */ + /* _mesa_function_pool[26923]: GetTexBumpParameterfvATI (will be remapped) */ "ip\0" "glGetTexBumpParameterfvATI\0" "\0" - /* _mesa_function_pool[26760]: ProgramNamedParameter4dNV (will be remapped) */ + /* _mesa_function_pool[26954]: ProgramNamedParameter4dNV (will be remapped) */ "iipdddd\0" "glProgramNamedParameter4dNV\0" "\0" - /* _mesa_function_pool[26797]: GetMaterialfv (offset 269) */ + /* _mesa_function_pool[26991]: GetMaterialfv (offset 269) */ "iip\0" "glGetMaterialfv\0" "\0" - /* _mesa_function_pool[26818]: VertexWeightfEXT (dynamic) */ + /* _mesa_function_pool[27012]: VertexWeightfEXT (dynamic) */ "f\0" "glVertexWeightfEXT\0" "\0" - /* _mesa_function_pool[26840]: Binormal3fEXT (dynamic) */ + /* _mesa_function_pool[27034]: SetFragmentShaderConstantATI (will be remapped) */ + "ip\0" + "glSetFragmentShaderConstantATI\0" + "\0" + /* _mesa_function_pool[27069]: Binormal3fEXT (dynamic) */ "fff\0" "glBinormal3fEXT\0" "\0" - /* _mesa_function_pool[26861]: CallList (offset 2) */ + /* _mesa_function_pool[27090]: CallList (offset 2) */ "i\0" "glCallList\0" "\0" - /* _mesa_function_pool[26875]: Materialfv (offset 170) */ + /* _mesa_function_pool[27104]: Materialfv (offset 170) */ "iip\0" "glMaterialfv\0" "\0" - /* _mesa_function_pool[26893]: TexCoord3fv (offset 113) */ + /* _mesa_function_pool[27122]: TexCoord3fv (offset 113) */ "p\0" "glTexCoord3fv\0" "\0" - /* _mesa_function_pool[26910]: FogCoordfvEXT (will be remapped) */ + /* _mesa_function_pool[27139]: FogCoordfvEXT (will be remapped) */ "p\0" "glFogCoordfv\0" "glFogCoordfvEXT\0" "\0" - /* _mesa_function_pool[26942]: MultiTexCoord1ivARB (offset 381) */ + /* _mesa_function_pool[27171]: MultiTexCoord1ivARB (offset 381) */ "ip\0" "glMultiTexCoord1iv\0" "glMultiTexCoord1ivARB\0" "\0" - /* _mesa_function_pool[26987]: SecondaryColor3ubEXT (will be remapped) */ + /* _mesa_function_pool[27216]: SecondaryColor3ubEXT (will be remapped) */ "iii\0" "glSecondaryColor3ub\0" "glSecondaryColor3ubEXT\0" "\0" - /* _mesa_function_pool[27035]: MultiTexCoord2ivARB (offset 389) */ + /* _mesa_function_pool[27264]: MultiTexCoord2ivARB (offset 389) */ "ip\0" "glMultiTexCoord2iv\0" "glMultiTexCoord2ivARB\0" "\0" - /* _mesa_function_pool[27080]: FogFuncSGIS (dynamic) */ + /* _mesa_function_pool[27309]: FogFuncSGIS (dynamic) */ "ip\0" "glFogFuncSGIS\0" "\0" - /* _mesa_function_pool[27098]: CopyTexSubImage2D (offset 326) */ + /* _mesa_function_pool[27327]: CopyTexSubImage2D (offset 326) */ "iiiiiiii\0" "glCopyTexSubImage2D\0" "glCopyTexSubImage2DEXT\0" "\0" - /* _mesa_function_pool[27151]: GetObjectParameterivARB (will be remapped) */ + /* _mesa_function_pool[27380]: GetObjectParameterivARB (will be remapped) */ "iip\0" "glGetObjectParameterivARB\0" "\0" - /* _mesa_function_pool[27182]: Color3iv (offset 16) */ + /* _mesa_function_pool[27411]: Color3iv (offset 16) */ "p\0" "glColor3iv\0" "\0" - /* _mesa_function_pool[27196]: TexCoord4fVertex4fSUN (dynamic) */ + /* _mesa_function_pool[27425]: TexCoord4fVertex4fSUN (dynamic) */ "ffffffff\0" "glTexCoord4fVertex4fSUN\0" "\0" - /* _mesa_function_pool[27230]: DrawElements (offset 311) */ + /* _mesa_function_pool[27459]: DrawElements (offset 311) */ "iiip\0" "glDrawElements\0" "\0" - /* _mesa_function_pool[27251]: BindVertexArrayAPPLE (will be remapped) */ + /* _mesa_function_pool[27480]: BindVertexArrayAPPLE (will be remapped) */ "i\0" "glBindVertexArrayAPPLE\0" "\0" - /* _mesa_function_pool[27277]: GetProgramLocalParameterdvARB (will be remapped) */ + /* _mesa_function_pool[27506]: GetProgramLocalParameterdvARB (will be remapped) */ "iip\0" "glGetProgramLocalParameterdvARB\0" "\0" - /* _mesa_function_pool[27314]: GetHistogramParameteriv (offset 363) */ + /* _mesa_function_pool[27543]: GetHistogramParameteriv (offset 363) */ "iip\0" "glGetHistogramParameteriv\0" "glGetHistogramParameterivEXT\0" "\0" - /* _mesa_function_pool[27374]: MultiTexCoord1iARB (offset 380) */ + /* _mesa_function_pool[27603]: MultiTexCoord1iARB (offset 380) */ "ii\0" "glMultiTexCoord1i\0" "glMultiTexCoord1iARB\0" "\0" - /* _mesa_function_pool[27417]: GetConvolutionFilter (offset 356) */ + /* _mesa_function_pool[27646]: GetConvolutionFilter (offset 356) */ "iiip\0" "glGetConvolutionFilter\0" "glGetConvolutionFilterEXT\0" "\0" - /* _mesa_function_pool[27472]: GetProgramivARB (will be remapped) */ + /* _mesa_function_pool[27701]: GetProgramivARB (will be remapped) */ "iip\0" "glGetProgramivARB\0" "\0" - /* _mesa_function_pool[27495]: BlendFuncSeparateEXT (will be remapped) */ + /* _mesa_function_pool[27724]: BlendFuncSeparateEXT (will be remapped) */ "iiii\0" "glBlendFuncSeparate\0" "glBlendFuncSeparateEXT\0" "glBlendFuncSeparateINGR\0" "\0" - /* _mesa_function_pool[27568]: MapBufferRange (will be remapped) */ + /* _mesa_function_pool[27797]: MapBufferRange (will be remapped) */ "iiii\0" "glMapBufferRange\0" "\0" - /* _mesa_function_pool[27591]: ProgramParameters4dvNV (will be remapped) */ + /* _mesa_function_pool[27820]: ProgramParameters4dvNV (will be remapped) */ "iiip\0" "glProgramParameters4dvNV\0" "\0" - /* _mesa_function_pool[27622]: TexCoord2fColor3fVertex3fvSUN (dynamic) */ + /* _mesa_function_pool[27851]: TexCoord2fColor3fVertex3fvSUN (dynamic) */ "ppp\0" "glTexCoord2fColor3fVertex3fvSUN\0" "\0" - /* _mesa_function_pool[27659]: EvalPoint2 (offset 239) */ + /* _mesa_function_pool[27888]: EvalPoint2 (offset 239) */ "ii\0" "glEvalPoint2\0" "\0" - /* _mesa_function_pool[27676]: Uniform1uivEXT (will be remapped) */ + /* _mesa_function_pool[27905]: Uniform1uivEXT (will be remapped) */ "iip\0" "glUniform1uivEXT\0" "glUniform1uiv\0" "\0" - /* _mesa_function_pool[27712]: EvalPoint1 (offset 237) */ + /* _mesa_function_pool[27941]: EvalPoint1 (offset 237) */ "i\0" "glEvalPoint1\0" "\0" - /* _mesa_function_pool[27728]: Binormal3dvEXT (dynamic) */ + /* _mesa_function_pool[27957]: Binormal3dvEXT (dynamic) */ "p\0" "glBinormal3dvEXT\0" "\0" - /* _mesa_function_pool[27748]: PopMatrix (offset 297) */ + /* _mesa_function_pool[27977]: PopMatrix (offset 297) */ "\0" "glPopMatrix\0" "\0" - /* _mesa_function_pool[27762]: FinishFenceNV (will be remapped) */ + /* _mesa_function_pool[27991]: GetVertexAttribIuivEXT (will be remapped) */ + "iip\0" + "glGetVertexAttribIuivEXT\0" + "glGetVertexAttribIuiv\0" + "\0" + /* _mesa_function_pool[28043]: FinishFenceNV (will be remapped) */ "i\0" "glFinishFenceNV\0" "\0" - /* _mesa_function_pool[27781]: GetFogFuncSGIS (dynamic) */ + /* _mesa_function_pool[28062]: GetFogFuncSGIS (dynamic) */ "p\0" "glGetFogFuncSGIS\0" "\0" - /* _mesa_function_pool[27801]: GetUniformLocationARB (will be remapped) */ + /* _mesa_function_pool[28082]: GetUniformLocationARB (will be remapped) */ "ip\0" "glGetUniformLocation\0" "glGetUniformLocationARB\0" "\0" - /* _mesa_function_pool[27850]: SecondaryColor3fEXT (will be remapped) */ + /* _mesa_function_pool[28131]: SecondaryColor3fEXT (will be remapped) */ "fff\0" "glSecondaryColor3f\0" "glSecondaryColor3fEXT\0" "\0" - /* _mesa_function_pool[27896]: GetTexGeniv (offset 280) */ + /* _mesa_function_pool[28177]: GetTexGeniv (offset 280) */ "iip\0" "glGetTexGeniv\0" "\0" - /* _mesa_function_pool[27915]: CombinerInputNV (will be remapped) */ + /* _mesa_function_pool[28196]: CombinerInputNV (will be remapped) */ "iiiiii\0" "glCombinerInputNV\0" "\0" - /* _mesa_function_pool[27941]: VertexAttrib3sARB (will be remapped) */ + /* _mesa_function_pool[28222]: VertexAttrib3sARB (will be remapped) */ "iiii\0" "glVertexAttrib3s\0" "glVertexAttrib3sARB\0" "\0" - /* _mesa_function_pool[27984]: IsTransformFeedback (will be remapped) */ + /* _mesa_function_pool[28265]: IsTransformFeedback (will be remapped) */ "i\0" "glIsTransformFeedback\0" "\0" - /* _mesa_function_pool[28009]: ReplacementCodeuiNormal3fVertex3fvSUN (dynamic) */ + /* _mesa_function_pool[28290]: ReplacementCodeuiNormal3fVertex3fvSUN (dynamic) */ "ppp\0" "glReplacementCodeuiNormal3fVertex3fvSUN\0" "\0" - /* _mesa_function_pool[28054]: Map2d (offset 222) */ + /* _mesa_function_pool[28335]: Map2d (offset 222) */ "iddiiddiip\0" "glMap2d\0" "\0" - /* _mesa_function_pool[28074]: Map2f (offset 223) */ + /* _mesa_function_pool[28355]: Map2f (offset 223) */ "iffiiffiip\0" "glMap2f\0" "\0" - /* _mesa_function_pool[28094]: ProgramStringARB (will be remapped) */ + /* _mesa_function_pool[28375]: ProgramStringARB (will be remapped) */ "iiip\0" "glProgramStringARB\0" "\0" - /* _mesa_function_pool[28119]: Vertex4s (offset 148) */ + /* _mesa_function_pool[28400]: Vertex4s (offset 148) */ "iiii\0" "glVertex4s\0" "\0" - /* _mesa_function_pool[28136]: TexCoord4fVertex4fvSUN (dynamic) */ + /* _mesa_function_pool[28417]: TexCoord4fVertex4fvSUN (dynamic) */ "pp\0" "glTexCoord4fVertex4fvSUN\0" "\0" - /* _mesa_function_pool[28165]: FragmentLightModelivSGIX (dynamic) */ + /* _mesa_function_pool[28446]: FragmentLightModelivSGIX (dynamic) */ "ip\0" "glFragmentLightModelivSGIX\0" "\0" - /* _mesa_function_pool[28196]: VertexAttrib1fNV (will be remapped) */ + /* _mesa_function_pool[28477]: VertexAttrib1fNV (will be remapped) */ "if\0" "glVertexAttrib1fNV\0" "\0" - /* _mesa_function_pool[28219]: Vertex4f (offset 144) */ + /* _mesa_function_pool[28500]: Vertex4f (offset 144) */ "ffff\0" "glVertex4f\0" "\0" - /* _mesa_function_pool[28236]: EvalCoord1d (offset 228) */ + /* _mesa_function_pool[28517]: EvalCoord1d (offset 228) */ "d\0" "glEvalCoord1d\0" "\0" - /* _mesa_function_pool[28253]: Vertex4d (offset 142) */ + /* _mesa_function_pool[28534]: Vertex4d (offset 142) */ "dddd\0" "glVertex4d\0" "\0" - /* _mesa_function_pool[28270]: RasterPos4dv (offset 79) */ + /* _mesa_function_pool[28551]: RasterPos4dv (offset 79) */ "p\0" "glRasterPos4dv\0" "\0" - /* _mesa_function_pool[28288]: UseShaderProgramEXT (will be remapped) */ + /* _mesa_function_pool[28569]: UseShaderProgramEXT (will be remapped) */ "ii\0" "glUseShaderProgramEXT\0" "\0" - /* _mesa_function_pool[28314]: FragmentLightfSGIX (dynamic) */ + /* _mesa_function_pool[28595]: FragmentLightfSGIX (dynamic) */ "iif\0" "glFragmentLightfSGIX\0" "\0" - /* _mesa_function_pool[28340]: GetCompressedTexImageARB (will be remapped) */ + /* _mesa_function_pool[28621]: GetCompressedTexImageARB (will be remapped) */ "iip\0" "glGetCompressedTexImage\0" "glGetCompressedTexImageARB\0" "\0" - /* _mesa_function_pool[28396]: GetTexGenfv (offset 279) */ + /* _mesa_function_pool[28677]: GetTexGenfv (offset 279) */ "iip\0" "glGetTexGenfv\0" "\0" - /* _mesa_function_pool[28415]: Vertex4i (offset 146) */ + /* _mesa_function_pool[28696]: Vertex4i (offset 146) */ "iiii\0" "glVertex4i\0" "\0" - /* _mesa_function_pool[28432]: VertexWeightPointerEXT (dynamic) */ + /* _mesa_function_pool[28713]: VertexWeightPointerEXT (dynamic) */ "iiip\0" "glVertexWeightPointerEXT\0" "\0" - /* _mesa_function_pool[28463]: GetHistogram (offset 361) */ + /* _mesa_function_pool[28744]: GetHistogram (offset 361) */ "iiiip\0" "glGetHistogram\0" "glGetHistogramEXT\0" "\0" - /* _mesa_function_pool[28503]: ActiveStencilFaceEXT (will be remapped) */ + /* _mesa_function_pool[28784]: ActiveStencilFaceEXT (will be remapped) */ "i\0" "glActiveStencilFaceEXT\0" "\0" - /* _mesa_function_pool[28529]: StencilFuncSeparateATI (will be remapped) */ + /* _mesa_function_pool[28810]: StencilFuncSeparateATI (will be remapped) */ "iiii\0" "glStencilFuncSeparateATI\0" "\0" - /* _mesa_function_pool[28560]: Materialf (offset 169) */ + /* _mesa_function_pool[28841]: Materialf (offset 169) */ "iif\0" "glMaterialf\0" "\0" - /* _mesa_function_pool[28577]: GetShaderSourceARB (will be remapped) */ + /* _mesa_function_pool[28858]: GetShaderSourceARB (will be remapped) */ "iipp\0" "glGetShaderSource\0" "glGetShaderSourceARB\0" "\0" - /* _mesa_function_pool[28622]: IglooInterfaceSGIX (dynamic) */ + /* _mesa_function_pool[28903]: IglooInterfaceSGIX (dynamic) */ "ip\0" "glIglooInterfaceSGIX\0" "\0" - /* _mesa_function_pool[28647]: Materiali (offset 171) */ + /* _mesa_function_pool[28928]: Materiali (offset 171) */ "iii\0" "glMateriali\0" "\0" - /* _mesa_function_pool[28664]: VertexAttrib4dNV (will be remapped) */ + /* _mesa_function_pool[28945]: VertexAttrib4dNV (will be remapped) */ "idddd\0" "glVertexAttrib4dNV\0" "\0" - /* _mesa_function_pool[28690]: MultiModeDrawElementsIBM (will be remapped) */ + /* _mesa_function_pool[28971]: MultiModeDrawElementsIBM (will be remapped) */ "ppipii\0" "glMultiModeDrawElementsIBM\0" "\0" - /* _mesa_function_pool[28725]: Indexsv (offset 51) */ + /* _mesa_function_pool[29006]: Indexsv (offset 51) */ "p\0" "glIndexsv\0" "\0" - /* _mesa_function_pool[28738]: MultiTexCoord4svARB (offset 407) */ + /* _mesa_function_pool[29019]: MultiTexCoord4svARB (offset 407) */ "ip\0" "glMultiTexCoord4sv\0" "glMultiTexCoord4svARB\0" "\0" - /* _mesa_function_pool[28783]: LightModelfv (offset 164) */ + /* _mesa_function_pool[29064]: LightModelfv (offset 164) */ "ip\0" "glLightModelfv\0" "\0" - /* _mesa_function_pool[28802]: TexCoord2dv (offset 103) */ + /* _mesa_function_pool[29083]: TexCoord2dv (offset 103) */ "p\0" "glTexCoord2dv\0" "\0" - /* _mesa_function_pool[28819]: GenQueriesARB (will be remapped) */ + /* _mesa_function_pool[29100]: GenQueriesARB (will be remapped) */ "ip\0" "glGenQueries\0" "glGenQueriesARB\0" "\0" - /* _mesa_function_pool[28852]: EvalCoord1dv (offset 229) */ + /* _mesa_function_pool[29133]: EvalCoord1dv (offset 229) */ "p\0" "glEvalCoord1dv\0" "\0" - /* _mesa_function_pool[28870]: ReplacementCodeuiVertex3fSUN (dynamic) */ + /* _mesa_function_pool[29151]: ReplacementCodeuiVertex3fSUN (dynamic) */ "ifff\0" "glReplacementCodeuiVertex3fSUN\0" "\0" - /* _mesa_function_pool[28907]: Translated (offset 303) */ + /* _mesa_function_pool[29188]: Translated (offset 303) */ "ddd\0" "glTranslated\0" "\0" - /* _mesa_function_pool[28925]: Translatef (offset 304) */ + /* _mesa_function_pool[29206]: Translatef (offset 304) */ "fff\0" "glTranslatef\0" "\0" - /* _mesa_function_pool[28943]: Uniform3uiEXT (will be remapped) */ + /* _mesa_function_pool[29224]: Uniform3uiEXT (will be remapped) */ "iiii\0" "glUniform3uiEXT\0" "glUniform3ui\0" "\0" - /* _mesa_function_pool[28978]: StencilMask (offset 209) */ + /* _mesa_function_pool[29259]: StencilMask (offset 209) */ "i\0" "glStencilMask\0" "\0" - /* _mesa_function_pool[28995]: Tangent3iEXT (dynamic) */ + /* _mesa_function_pool[29276]: Tangent3iEXT (dynamic) */ "iii\0" "glTangent3iEXT\0" "\0" - /* _mesa_function_pool[29015]: GetLightiv (offset 265) */ + /* _mesa_function_pool[29296]: GetLightiv (offset 265) */ "iip\0" "glGetLightiv\0" "\0" - /* _mesa_function_pool[29033]: DrawMeshArraysSUN (dynamic) */ + /* _mesa_function_pool[29314]: DrawMeshArraysSUN (dynamic) */ "iiii\0" "glDrawMeshArraysSUN\0" "\0" - /* _mesa_function_pool[29059]: IsList (offset 287) */ + /* _mesa_function_pool[29340]: IsList (offset 287) */ "i\0" "glIsList\0" "\0" - /* _mesa_function_pool[29071]: IsSync (will be remapped) */ + /* _mesa_function_pool[29352]: IsSync (will be remapped) */ "i\0" "glIsSync\0" "\0" - /* _mesa_function_pool[29083]: RenderMode (offset 196) */ + /* _mesa_function_pool[29364]: RenderMode (offset 196) */ "i\0" "glRenderMode\0" "\0" - /* _mesa_function_pool[29099]: GetMapControlPointsNV (dynamic) */ + /* _mesa_function_pool[29380]: GetMapControlPointsNV (dynamic) */ "iiiiiip\0" "glGetMapControlPointsNV\0" "\0" - /* _mesa_function_pool[29132]: DrawBuffersARB (will be remapped) */ + /* _mesa_function_pool[29413]: DrawBuffersARB (will be remapped) */ "ip\0" "glDrawBuffers\0" "glDrawBuffersARB\0" "glDrawBuffersATI\0" "\0" - /* _mesa_function_pool[29184]: ClearBufferiv (will be remapped) */ + /* _mesa_function_pool[29465]: ClearBufferiv (will be remapped) */ "iip\0" "glClearBufferiv\0" "\0" - /* _mesa_function_pool[29205]: ProgramLocalParameter4fARB (will be remapped) */ + /* _mesa_function_pool[29486]: ProgramLocalParameter4fARB (will be remapped) */ "iiffff\0" "glProgramLocalParameter4fARB\0" "\0" - /* _mesa_function_pool[29242]: SpriteParameterivSGIX (dynamic) */ + /* _mesa_function_pool[29523]: SpriteParameterivSGIX (dynamic) */ "ip\0" "glSpriteParameterivSGIX\0" "\0" - /* _mesa_function_pool[29270]: ProvokingVertexEXT (will be remapped) */ + /* _mesa_function_pool[29551]: ProvokingVertexEXT (will be remapped) */ "i\0" "glProvokingVertexEXT\0" "glProvokingVertex\0" "\0" - /* _mesa_function_pool[29312]: MultiTexCoord1fARB (offset 378) */ + /* _mesa_function_pool[29593]: MultiTexCoord1fARB (offset 378) */ "if\0" "glMultiTexCoord1f\0" "glMultiTexCoord1fARB\0" "\0" - /* _mesa_function_pool[29355]: LoadName (offset 198) */ + /* _mesa_function_pool[29636]: LoadName (offset 198) */ "i\0" "glLoadName\0" "\0" - /* _mesa_function_pool[29369]: VertexAttribs4ubvNV (will be remapped) */ + /* _mesa_function_pool[29650]: VertexAttribs4ubvNV (will be remapped) */ "iip\0" "glVertexAttribs4ubvNV\0" "\0" - /* _mesa_function_pool[29396]: WeightsvARB (dynamic) */ + /* _mesa_function_pool[29677]: WeightsvARB (dynamic) */ "ip\0" "glWeightsvARB\0" "\0" - /* _mesa_function_pool[29414]: Uniform1fvARB (will be remapped) */ + /* _mesa_function_pool[29695]: Uniform1fvARB (will be remapped) */ "iip\0" "glUniform1fv\0" "glUniform1fvARB\0" "\0" - /* _mesa_function_pool[29448]: CopyTexSubImage1D (offset 325) */ + /* _mesa_function_pool[29729]: CopyTexSubImage1D (offset 325) */ "iiiiii\0" "glCopyTexSubImage1D\0" "glCopyTexSubImage1DEXT\0" "\0" - /* _mesa_function_pool[29499]: CullFace (offset 152) */ + /* _mesa_function_pool[29780]: CullFace (offset 152) */ "i\0" "glCullFace\0" "\0" - /* _mesa_function_pool[29513]: BindTexture (offset 307) */ + /* _mesa_function_pool[29794]: BindTexture (offset 307) */ "ii\0" "glBindTexture\0" "glBindTextureEXT\0" "\0" - /* _mesa_function_pool[29548]: BeginFragmentShaderATI (will be remapped) */ + /* _mesa_function_pool[29829]: BeginFragmentShaderATI (will be remapped) */ "\0" "glBeginFragmentShaderATI\0" "\0" - /* _mesa_function_pool[29575]: MultiTexCoord4fARB (offset 402) */ + /* _mesa_function_pool[29856]: MultiTexCoord4fARB (offset 402) */ "iffff\0" "glMultiTexCoord4f\0" "glMultiTexCoord4fARB\0" "\0" - /* _mesa_function_pool[29621]: VertexAttribs3svNV (will be remapped) */ + /* _mesa_function_pool[29902]: VertexAttribs3svNV (will be remapped) */ "iip\0" "glVertexAttribs3svNV\0" "\0" - /* _mesa_function_pool[29647]: StencilFunc (offset 243) */ + /* _mesa_function_pool[29928]: StencilFunc (offset 243) */ "iii\0" "glStencilFunc\0" "\0" - /* _mesa_function_pool[29666]: CopyPixels (offset 255) */ + /* _mesa_function_pool[29947]: CopyPixels (offset 255) */ "iiiii\0" "glCopyPixels\0" "\0" - /* _mesa_function_pool[29686]: Rectsv (offset 93) */ + /* _mesa_function_pool[29967]: Rectsv (offset 93) */ "pp\0" "glRectsv\0" "\0" - /* _mesa_function_pool[29699]: ReplacementCodeuivSUN (dynamic) */ + /* _mesa_function_pool[29980]: ReplacementCodeuivSUN (dynamic) */ "p\0" "glReplacementCodeuivSUN\0" "\0" - /* _mesa_function_pool[29726]: EnableVertexAttribArrayARB (will be remapped) */ + /* _mesa_function_pool[30007]: EnableVertexAttribArrayARB (will be remapped) */ "i\0" "glEnableVertexAttribArray\0" "glEnableVertexAttribArrayARB\0" "\0" - /* _mesa_function_pool[29784]: NormalPointervINTEL (dynamic) */ + /* _mesa_function_pool[30065]: NormalPointervINTEL (dynamic) */ "ip\0" "glNormalPointervINTEL\0" "\0" - /* _mesa_function_pool[29810]: CopyConvolutionFilter2D (offset 355) */ + /* _mesa_function_pool[30091]: CopyConvolutionFilter2D (offset 355) */ "iiiiii\0" "glCopyConvolutionFilter2D\0" "glCopyConvolutionFilter2DEXT\0" "\0" - /* _mesa_function_pool[29873]: WindowPos3ivMESA (will be remapped) */ + /* _mesa_function_pool[30154]: WindowPos3ivMESA (will be remapped) */ "p\0" "glWindowPos3iv\0" "glWindowPos3ivARB\0" "glWindowPos3ivMESA\0" "\0" - /* _mesa_function_pool[29928]: CopyBufferSubData (will be remapped) */ + /* _mesa_function_pool[30209]: CopyBufferSubData (will be remapped) */ "iiiii\0" "glCopyBufferSubData\0" "\0" - /* _mesa_function_pool[29955]: NormalPointer (offset 318) */ + /* _mesa_function_pool[30236]: NormalPointer (offset 318) */ "iip\0" "glNormalPointer\0" "\0" - /* _mesa_function_pool[29976]: TexParameterfv (offset 179) */ + /* _mesa_function_pool[30257]: TexParameterfv (offset 179) */ "iip\0" "glTexParameterfv\0" "\0" - /* _mesa_function_pool[29998]: IsBufferARB (will be remapped) */ + /* _mesa_function_pool[30279]: IsBufferARB (will be remapped) */ "i\0" "glIsBuffer\0" "glIsBufferARB\0" "\0" - /* _mesa_function_pool[30026]: WindowPos4iMESA (will be remapped) */ + /* _mesa_function_pool[30307]: WindowPos4iMESA (will be remapped) */ "iiii\0" "glWindowPos4iMESA\0" "\0" - /* _mesa_function_pool[30050]: VertexAttrib4uivARB (will be remapped) */ + /* _mesa_function_pool[30331]: VertexAttrib4uivARB (will be remapped) */ "ip\0" "glVertexAttrib4uiv\0" "glVertexAttrib4uivARB\0" "\0" - /* _mesa_function_pool[30095]: Tangent3bvEXT (dynamic) */ + /* _mesa_function_pool[30376]: Tangent3bvEXT (dynamic) */ "p\0" "glTangent3bvEXT\0" "\0" - /* _mesa_function_pool[30114]: VertexAttribI3uivEXT (will be remapped) */ + /* _mesa_function_pool[30395]: VertexAttribI3uivEXT (will be remapped) */ "ip\0" "glVertexAttribI3uivEXT\0" "glVertexAttribI3uiv\0" "\0" - /* _mesa_function_pool[30161]: UniformMatrix3x4fv (will be remapped) */ + /* _mesa_function_pool[30442]: UniformMatrix3x4fv (will be remapped) */ "iiip\0" "glUniformMatrix3x4fv\0" "\0" - /* _mesa_function_pool[30188]: ClipPlane (offset 150) */ + /* _mesa_function_pool[30469]: ClipPlane (offset 150) */ "ip\0" "glClipPlane\0" "\0" - /* _mesa_function_pool[30204]: Recti (offset 90) */ + /* _mesa_function_pool[30485]: Recti (offset 90) */ "iiii\0" "glRecti\0" "\0" - /* _mesa_function_pool[30218]: VertexAttribI3ivEXT (will be remapped) */ + /* _mesa_function_pool[30499]: VertexAttribI3ivEXT (will be remapped) */ "ip\0" "glVertexAttribI3ivEXT\0" "glVertexAttribI3iv\0" "\0" - /* _mesa_function_pool[30263]: DrawRangeElementsBaseVertex (will be remapped) */ + /* _mesa_function_pool[30544]: DrawRangeElementsBaseVertex (will be remapped) */ "iiiiipi\0" "glDrawRangeElementsBaseVertex\0" "\0" - /* _mesa_function_pool[30302]: TexCoordPointervINTEL (dynamic) */ + /* _mesa_function_pool[30583]: TexCoordPointervINTEL (dynamic) */ "iip\0" "glTexCoordPointervINTEL\0" "\0" - /* _mesa_function_pool[30331]: DeleteBuffersARB (will be remapped) */ + /* _mesa_function_pool[30612]: DeleteBuffersARB (will be remapped) */ "ip\0" "glDeleteBuffers\0" "glDeleteBuffersARB\0" "\0" - /* _mesa_function_pool[30370]: PixelTransformParameterfvEXT (dynamic) */ + /* _mesa_function_pool[30651]: PixelTransformParameterfvEXT (dynamic) */ "iip\0" "glPixelTransformParameterfvEXT\0" "\0" - /* _mesa_function_pool[30406]: PrimitiveRestartNV (will be remapped) */ + /* _mesa_function_pool[30687]: PrimitiveRestartNV (will be remapped) */ "\0" "glPrimitiveRestartNV\0" "\0" - /* _mesa_function_pool[30429]: WindowPos4fvMESA (will be remapped) */ + /* _mesa_function_pool[30710]: WindowPos4fvMESA (will be remapped) */ "p\0" "glWindowPos4fvMESA\0" "\0" - /* _mesa_function_pool[30451]: GetPixelMapuiv (offset 272) */ + /* _mesa_function_pool[30732]: GetPixelMapuiv (offset 272) */ "ip\0" "glGetPixelMapuiv\0" "\0" - /* _mesa_function_pool[30472]: Rectf (offset 88) */ + /* _mesa_function_pool[30753]: Rectf (offset 88) */ "ffff\0" "glRectf\0" "\0" - /* _mesa_function_pool[30486]: VertexAttrib1sNV (will be remapped) */ + /* _mesa_function_pool[30767]: VertexAttrib1sNV (will be remapped) */ "ii\0" "glVertexAttrib1sNV\0" "\0" - /* _mesa_function_pool[30509]: Indexfv (offset 47) */ + /* _mesa_function_pool[30790]: Indexfv (offset 47) */ "p\0" "glIndexfv\0" "\0" - /* _mesa_function_pool[30522]: SecondaryColor3svEXT (will be remapped) */ + /* _mesa_function_pool[30803]: SecondaryColor3svEXT (will be remapped) */ "p\0" "glSecondaryColor3sv\0" "glSecondaryColor3svEXT\0" "\0" - /* _mesa_function_pool[30568]: LoadTransposeMatrixfARB (will be remapped) */ + /* _mesa_function_pool[30849]: LoadTransposeMatrixfARB (will be remapped) */ "p\0" "glLoadTransposeMatrixf\0" "glLoadTransposeMatrixfARB\0" "\0" - /* _mesa_function_pool[30620]: GetPointerv (offset 329) */ + /* _mesa_function_pool[30901]: GetPointerv (offset 329) */ "ip\0" "glGetPointerv\0" "glGetPointervEXT\0" "\0" - /* _mesa_function_pool[30655]: Tangent3bEXT (dynamic) */ + /* _mesa_function_pool[30936]: Tangent3bEXT (dynamic) */ "iii\0" "glTangent3bEXT\0" "\0" - /* _mesa_function_pool[30675]: CombinerParameterfNV (will be remapped) */ + /* _mesa_function_pool[30956]: CombinerParameterfNV (will be remapped) */ "if\0" "glCombinerParameterfNV\0" "\0" - /* _mesa_function_pool[30702]: IndexMask (offset 212) */ + /* _mesa_function_pool[30983]: IndexMask (offset 212) */ "i\0" "glIndexMask\0" "\0" - /* _mesa_function_pool[30717]: BindProgramNV (will be remapped) */ + /* _mesa_function_pool[30998]: BindProgramNV (will be remapped) */ "ii\0" "glBindProgramARB\0" "glBindProgramNV\0" "\0" - /* _mesa_function_pool[30754]: VertexAttrib4svARB (will be remapped) */ + /* _mesa_function_pool[31035]: VertexAttrib4svARB (will be remapped) */ "ip\0" "glVertexAttrib4sv\0" "glVertexAttrib4svARB\0" "\0" - /* _mesa_function_pool[30797]: GetFloatv (offset 262) */ + /* _mesa_function_pool[31078]: GetFloatv (offset 262) */ "ip\0" "glGetFloatv\0" "\0" - /* _mesa_function_pool[30813]: CreateDebugObjectMESA (dynamic) */ + /* _mesa_function_pool[31094]: CreateDebugObjectMESA (dynamic) */ "\0" "glCreateDebugObjectMESA\0" "\0" - /* _mesa_function_pool[30839]: GetShaderiv (will be remapped) */ + /* _mesa_function_pool[31120]: GetShaderiv (will be remapped) */ "iip\0" "glGetShaderiv\0" "\0" - /* _mesa_function_pool[30858]: ClientWaitSync (will be remapped) */ + /* _mesa_function_pool[31139]: ClientWaitSync (will be remapped) */ "iii\0" "glClientWaitSync\0" "\0" - /* _mesa_function_pool[30880]: TexCoord4s (offset 124) */ + /* _mesa_function_pool[31161]: TexCoord4s (offset 124) */ "iiii\0" "glTexCoord4s\0" "\0" - /* _mesa_function_pool[30899]: TexCoord3sv (offset 117) */ + /* _mesa_function_pool[31180]: TexCoord3sv (offset 117) */ "p\0" "glTexCoord3sv\0" "\0" - /* _mesa_function_pool[30916]: BindFragmentShaderATI (will be remapped) */ + /* _mesa_function_pool[31197]: BindFragmentShaderATI (will be remapped) */ "i\0" "glBindFragmentShaderATI\0" "\0" - /* _mesa_function_pool[30943]: PopAttrib (offset 218) */ + /* _mesa_function_pool[31224]: PopAttrib (offset 218) */ "\0" "glPopAttrib\0" "\0" - /* _mesa_function_pool[30957]: Fogfv (offset 154) */ + /* _mesa_function_pool[31238]: Fogfv (offset 154) */ "ip\0" "glFogfv\0" "\0" - /* _mesa_function_pool[30969]: UnmapBufferARB (will be remapped) */ + /* _mesa_function_pool[31250]: UnmapBufferARB (will be remapped) */ "i\0" "glUnmapBuffer\0" "glUnmapBufferARB\0" "\0" - /* _mesa_function_pool[31003]: InitNames (offset 197) */ + /* _mesa_function_pool[31284]: InitNames (offset 197) */ "\0" "glInitNames\0" "\0" - /* _mesa_function_pool[31017]: Normal3sv (offset 61) */ + /* _mesa_function_pool[31298]: Normal3sv (offset 61) */ "p\0" "glNormal3sv\0" "\0" - /* _mesa_function_pool[31032]: Minmax (offset 368) */ + /* _mesa_function_pool[31313]: Minmax (offset 368) */ "iii\0" "glMinmax\0" "glMinmaxEXT\0" "\0" - /* _mesa_function_pool[31058]: TexCoord4d (offset 118) */ + /* _mesa_function_pool[31339]: TexCoord4d (offset 118) */ "dddd\0" "glTexCoord4d\0" "\0" - /* _mesa_function_pool[31077]: DeformationMap3dSGIX (dynamic) */ - "iddiiddiiddiip\0" - "glDeformationMap3dSGIX\0" - "\0" - /* _mesa_function_pool[31116]: TexCoord4f (offset 120) */ + /* _mesa_function_pool[31358]: TexCoord4f (offset 120) */ "ffff\0" "glTexCoord4f\0" "\0" - /* _mesa_function_pool[31135]: FogCoorddvEXT (will be remapped) */ + /* _mesa_function_pool[31377]: FogCoorddvEXT (will be remapped) */ "p\0" "glFogCoorddv\0" "glFogCoorddvEXT\0" "\0" - /* _mesa_function_pool[31167]: FinishTextureSUNX (dynamic) */ + /* _mesa_function_pool[31409]: FinishTextureSUNX (dynamic) */ "\0" "glFinishTextureSUNX\0" "\0" - /* _mesa_function_pool[31189]: GetFragmentLightfvSGIX (dynamic) */ + /* _mesa_function_pool[31431]: GetFragmentLightfvSGIX (dynamic) */ "iip\0" "glGetFragmentLightfvSGIX\0" "\0" - /* _mesa_function_pool[31219]: Binormal3fvEXT (dynamic) */ + /* _mesa_function_pool[31461]: Binormal3fvEXT (dynamic) */ "p\0" "glBinormal3fvEXT\0" "\0" - /* _mesa_function_pool[31239]: GetBooleanv (offset 258) */ + /* _mesa_function_pool[31481]: GetBooleanv (offset 258) */ "ip\0" "glGetBooleanv\0" "\0" - /* _mesa_function_pool[31257]: ColorFragmentOp3ATI (will be remapped) */ + /* _mesa_function_pool[31499]: ColorFragmentOp3ATI (will be remapped) */ "iiiiiiiiiiiii\0" "glColorFragmentOp3ATI\0" "\0" - /* _mesa_function_pool[31294]: Hint (offset 158) */ + /* _mesa_function_pool[31536]: Hint (offset 158) */ "ii\0" "glHint\0" "\0" - /* _mesa_function_pool[31305]: Color4dv (offset 28) */ + /* _mesa_function_pool[31547]: Color4dv (offset 28) */ "p\0" "glColor4dv\0" "\0" - /* _mesa_function_pool[31319]: VertexAttrib2svARB (will be remapped) */ + /* _mesa_function_pool[31561]: VertexAttrib2svARB (will be remapped) */ "ip\0" "glVertexAttrib2sv\0" "glVertexAttrib2svARB\0" "\0" - /* _mesa_function_pool[31362]: AreProgramsResidentNV (will be remapped) */ + /* _mesa_function_pool[31604]: AreProgramsResidentNV (will be remapped) */ "ipp\0" "glAreProgramsResidentNV\0" "\0" - /* _mesa_function_pool[31391]: WindowPos3svMESA (will be remapped) */ + /* _mesa_function_pool[31633]: WindowPos3svMESA (will be remapped) */ "p\0" "glWindowPos3sv\0" "glWindowPos3svARB\0" "glWindowPos3svMESA\0" "\0" - /* _mesa_function_pool[31446]: CopyColorSubTable (offset 347) */ + /* _mesa_function_pool[31688]: CopyColorSubTable (offset 347) */ "iiiii\0" "glCopyColorSubTable\0" "glCopyColorSubTableEXT\0" "\0" - /* _mesa_function_pool[31496]: WeightdvARB (dynamic) */ + /* _mesa_function_pool[31738]: WeightdvARB (dynamic) */ "ip\0" "glWeightdvARB\0" "\0" - /* _mesa_function_pool[31514]: DeleteRenderbuffersEXT (will be remapped) */ + /* _mesa_function_pool[31756]: DeleteRenderbuffersEXT (will be remapped) */ "ip\0" "glDeleteRenderbuffers\0" "glDeleteRenderbuffersEXT\0" "\0" - /* _mesa_function_pool[31565]: VertexAttrib4NubvARB (will be remapped) */ + /* _mesa_function_pool[31807]: VertexAttrib4NubvARB (will be remapped) */ "ip\0" "glVertexAttrib4Nubv\0" "glVertexAttrib4NubvARB\0" "\0" - /* _mesa_function_pool[31612]: VertexAttrib3dvNV (will be remapped) */ + /* _mesa_function_pool[31854]: VertexAttrib3dvNV (will be remapped) */ "ip\0" "glVertexAttrib3dvNV\0" "\0" - /* _mesa_function_pool[31636]: GetObjectParameterfvARB (will be remapped) */ + /* _mesa_function_pool[31878]: GetObjectParameterfvARB (will be remapped) */ "iip\0" "glGetObjectParameterfvARB\0" "\0" - /* _mesa_function_pool[31667]: Vertex4iv (offset 147) */ + /* _mesa_function_pool[31909]: Vertex4iv (offset 147) */ "p\0" "glVertex4iv\0" "\0" - /* _mesa_function_pool[31682]: GetProgramEnvParameterdvARB (will be remapped) */ + /* _mesa_function_pool[31924]: GetProgramEnvParameterdvARB (will be remapped) */ "iip\0" "glGetProgramEnvParameterdvARB\0" "\0" - /* _mesa_function_pool[31717]: TexCoord4dv (offset 119) */ + /* _mesa_function_pool[31959]: TexCoord4dv (offset 119) */ "p\0" "glTexCoord4dv\0" "\0" - /* _mesa_function_pool[31734]: LockArraysEXT (will be remapped) */ + /* _mesa_function_pool[31976]: LockArraysEXT (will be remapped) */ "ii\0" "glLockArraysEXT\0" "\0" - /* _mesa_function_pool[31754]: Begin (offset 7) */ + /* _mesa_function_pool[31996]: Begin (offset 7) */ "i\0" "glBegin\0" "\0" - /* _mesa_function_pool[31765]: LightModeli (offset 165) */ + /* _mesa_function_pool[32007]: LightModeli (offset 165) */ "ii\0" "glLightModeli\0" "\0" - /* _mesa_function_pool[31783]: VertexAttribI4ivEXT (will be remapped) */ + /* _mesa_function_pool[32025]: VertexAttribI4ivEXT (will be remapped) */ "ip\0" "glVertexAttribI4ivEXT\0" "glVertexAttribI4iv\0" "\0" - /* _mesa_function_pool[31828]: Rectfv (offset 89) */ + /* _mesa_function_pool[32070]: Rectfv (offset 89) */ "pp\0" "glRectfv\0" "\0" - /* _mesa_function_pool[31841]: LightModelf (offset 163) */ + /* _mesa_function_pool[32083]: BlendEquationSeparateiARB (will be remapped) */ + "iii\0" + "glBlendEquationSeparateiARB\0" + "\0" + /* _mesa_function_pool[32116]: LightModelf (offset 163) */ "if\0" "glLightModelf\0" "\0" - /* _mesa_function_pool[31859]: GetTexParameterfv (offset 282) */ + /* _mesa_function_pool[32134]: GetTexParameterfv (offset 282) */ "iip\0" "glGetTexParameterfv\0" "\0" - /* _mesa_function_pool[31884]: GetLightfv (offset 264) */ + /* _mesa_function_pool[32159]: GetLightfv (offset 264) */ "iip\0" "glGetLightfv\0" "\0" - /* _mesa_function_pool[31902]: PixelTransformParameterivEXT (dynamic) */ + /* _mesa_function_pool[32177]: PixelTransformParameterivEXT (dynamic) */ "iip\0" "glPixelTransformParameterivEXT\0" "\0" - /* _mesa_function_pool[31938]: BinormalPointerEXT (dynamic) */ + /* _mesa_function_pool[32213]: BinormalPointerEXT (dynamic) */ "iip\0" "glBinormalPointerEXT\0" "\0" - /* _mesa_function_pool[31964]: VertexAttrib1dNV (will be remapped) */ + /* _mesa_function_pool[32239]: VertexAttrib1dNV (will be remapped) */ "id\0" "glVertexAttrib1dNV\0" "\0" - /* _mesa_function_pool[31987]: GetCombinerInputParameterivNV (will be remapped) */ + /* _mesa_function_pool[32262]: GetCombinerInputParameterivNV (will be remapped) */ "iiiip\0" "glGetCombinerInputParameterivNV\0" "\0" - /* _mesa_function_pool[32026]: Disable (offset 214) */ + /* _mesa_function_pool[32301]: Disable (offset 214) */ "i\0" "glDisable\0" "\0" - /* _mesa_function_pool[32039]: MultiTexCoord2fvARB (offset 387) */ + /* _mesa_function_pool[32314]: MultiTexCoord2fvARB (offset 387) */ "ip\0" "glMultiTexCoord2fv\0" "glMultiTexCoord2fvARB\0" "\0" - /* _mesa_function_pool[32084]: GetRenderbufferParameterivEXT (will be remapped) */ + /* _mesa_function_pool[32359]: GetRenderbufferParameterivEXT (will be remapped) */ "iip\0" "glGetRenderbufferParameteriv\0" "glGetRenderbufferParameterivEXT\0" "\0" - /* _mesa_function_pool[32150]: CombinerParameterivNV (will be remapped) */ + /* _mesa_function_pool[32425]: CombinerParameterivNV (will be remapped) */ "ip\0" "glCombinerParameterivNV\0" "\0" - /* _mesa_function_pool[32178]: GenFragmentShadersATI (will be remapped) */ + /* _mesa_function_pool[32453]: GenFragmentShadersATI (will be remapped) */ "i\0" "glGenFragmentShadersATI\0" "\0" - /* _mesa_function_pool[32205]: DrawArrays (offset 310) */ + /* _mesa_function_pool[32480]: DrawArrays (offset 310) */ "iii\0" "glDrawArrays\0" "glDrawArraysEXT\0" "\0" - /* _mesa_function_pool[32239]: WeightuivARB (dynamic) */ + /* _mesa_function_pool[32514]: WeightuivARB (dynamic) */ "ip\0" "glWeightuivARB\0" "\0" - /* _mesa_function_pool[32258]: VertexAttrib2sARB (will be remapped) */ + /* _mesa_function_pool[32533]: VertexAttrib2sARB (will be remapped) */ "iii\0" "glVertexAttrib2s\0" "glVertexAttrib2sARB\0" "\0" - /* _mesa_function_pool[32300]: ColorMask (offset 210) */ + /* _mesa_function_pool[32575]: ColorMask (offset 210) */ "iiii\0" "glColorMask\0" "\0" - /* _mesa_function_pool[32318]: GenAsyncMarkersSGIX (dynamic) */ + /* _mesa_function_pool[32593]: GenAsyncMarkersSGIX (dynamic) */ "i\0" "glGenAsyncMarkersSGIX\0" "\0" - /* _mesa_function_pool[32343]: Tangent3svEXT (dynamic) */ + /* _mesa_function_pool[32618]: Tangent3svEXT (dynamic) */ "p\0" "glTangent3svEXT\0" "\0" - /* _mesa_function_pool[32362]: GetListParameterivSGIX (dynamic) */ + /* _mesa_function_pool[32637]: GetListParameterivSGIX (dynamic) */ "iip\0" "glGetListParameterivSGIX\0" "\0" - /* _mesa_function_pool[32392]: BindBufferARB (will be remapped) */ + /* _mesa_function_pool[32667]: BindBufferARB (will be remapped) */ "ii\0" "glBindBuffer\0" "glBindBufferARB\0" "\0" - /* _mesa_function_pool[32425]: GetInfoLogARB (will be remapped) */ + /* _mesa_function_pool[32700]: GetInfoLogARB (will be remapped) */ "iipp\0" "glGetInfoLogARB\0" "\0" - /* _mesa_function_pool[32447]: RasterPos4iv (offset 83) */ + /* _mesa_function_pool[32722]: RasterPos4iv (offset 83) */ "p\0" "glRasterPos4iv\0" "\0" - /* _mesa_function_pool[32465]: Enable (offset 215) */ + /* _mesa_function_pool[32740]: Enable (offset 215) */ "i\0" "glEnable\0" "\0" - /* _mesa_function_pool[32477]: LineStipple (offset 167) */ + /* _mesa_function_pool[32752]: LineStipple (offset 167) */ "ii\0" "glLineStipple\0" "\0" - /* _mesa_function_pool[32495]: VertexAttribs4svNV (will be remapped) */ + /* _mesa_function_pool[32770]: VertexAttribs4svNV (will be remapped) */ "iip\0" "glVertexAttribs4svNV\0" "\0" - /* _mesa_function_pool[32521]: EdgeFlagPointerListIBM (dynamic) */ + /* _mesa_function_pool[32796]: EdgeFlagPointerListIBM (dynamic) */ "ipi\0" "glEdgeFlagPointerListIBM\0" "\0" - /* _mesa_function_pool[32551]: UniformMatrix3x2fv (will be remapped) */ + /* _mesa_function_pool[32826]: UniformMatrix3x2fv (will be remapped) */ "iiip\0" "glUniformMatrix3x2fv\0" "\0" - /* _mesa_function_pool[32578]: GetMinmaxParameterfv (offset 365) */ + /* _mesa_function_pool[32853]: GetMinmaxParameterfv (offset 365) */ "iip\0" "glGetMinmaxParameterfv\0" "glGetMinmaxParameterfvEXT\0" "\0" - /* _mesa_function_pool[32632]: VertexAttrib1fvARB (will be remapped) */ + /* _mesa_function_pool[32907]: VertexAttrib1fvARB (will be remapped) */ "ip\0" "glVertexAttrib1fv\0" "glVertexAttrib1fvARB\0" "\0" - /* _mesa_function_pool[32675]: GenBuffersARB (will be remapped) */ + /* _mesa_function_pool[32950]: GenBuffersARB (will be remapped) */ "ip\0" "glGenBuffers\0" "glGenBuffersARB\0" "\0" - /* _mesa_function_pool[32708]: VertexAttribs1svNV (will be remapped) */ + /* _mesa_function_pool[32983]: VertexAttribs1svNV (will be remapped) */ "iip\0" "glVertexAttribs1svNV\0" "\0" - /* _mesa_function_pool[32734]: Vertex3fv (offset 137) */ + /* _mesa_function_pool[33009]: Vertex3fv (offset 137) */ "p\0" "glVertex3fv\0" "\0" - /* _mesa_function_pool[32749]: GetTexBumpParameterivATI (will be remapped) */ + /* _mesa_function_pool[33024]: GetTexBumpParameterivATI (will be remapped) */ "ip\0" "glGetTexBumpParameterivATI\0" "\0" - /* _mesa_function_pool[32780]: Binormal3bEXT (dynamic) */ + /* _mesa_function_pool[33055]: Binormal3bEXT (dynamic) */ "iii\0" "glBinormal3bEXT\0" "\0" - /* _mesa_function_pool[32801]: FragmentMaterialivSGIX (dynamic) */ + /* _mesa_function_pool[33076]: FragmentMaterialivSGIX (dynamic) */ "iip\0" "glFragmentMaterialivSGIX\0" "\0" - /* _mesa_function_pool[32831]: IsRenderbufferEXT (will be remapped) */ + /* _mesa_function_pool[33106]: IsRenderbufferEXT (will be remapped) */ "i\0" "glIsRenderbuffer\0" "glIsRenderbufferEXT\0" "\0" - /* _mesa_function_pool[32871]: GenProgramsNV (will be remapped) */ + /* _mesa_function_pool[33146]: GenProgramsNV (will be remapped) */ "ip\0" "glGenProgramsARB\0" "glGenProgramsNV\0" "\0" - /* _mesa_function_pool[32908]: VertexAttrib4dvNV (will be remapped) */ + /* _mesa_function_pool[33183]: VertexAttrib4dvNV (will be remapped) */ "ip\0" "glVertexAttrib4dvNV\0" "\0" - /* _mesa_function_pool[32932]: EndFragmentShaderATI (will be remapped) */ + /* _mesa_function_pool[33207]: EndFragmentShaderATI (will be remapped) */ "\0" "glEndFragmentShaderATI\0" "\0" - /* _mesa_function_pool[32957]: Binormal3iEXT (dynamic) */ + /* _mesa_function_pool[33232]: Binormal3iEXT (dynamic) */ "iii\0" "glBinormal3iEXT\0" "\0" - /* _mesa_function_pool[32978]: WindowPos2fMESA (will be remapped) */ + /* _mesa_function_pool[33253]: WindowPos2fMESA (will be remapped) */ "ff\0" "glWindowPos2f\0" "glWindowPos2fARB\0" @@ -4739,589 +4783,600 @@ static const char _mesa_function_pool[] = /* these functions need to be remapped */ static const struct gl_function_pool_remap MESA_remap_table_functions[] = { - { 1577, AttachShader_remap_index }, - { 9902, CreateProgram_remap_index }, - { 22864, CreateShader_remap_index }, - { 25322, DeleteProgram_remap_index }, - { 18525, DeleteShader_remap_index }, - { 23336, DetachShader_remap_index }, - { 17928, GetAttachedShaders_remap_index }, - { 4869, GetProgramInfoLog_remap_index }, - { 405, GetProgramiv_remap_index }, - { 6542, GetShaderInfoLog_remap_index }, - { 30839, GetShaderiv_remap_index }, - { 13311, IsProgram_remap_index }, - { 12263, IsShader_remap_index }, - { 10006, StencilFuncSeparate_remap_index }, - { 3921, StencilMaskSeparate_remap_index }, - { 7624, StencilOpSeparate_remap_index }, - { 22152, UniformMatrix2x3fv_remap_index }, - { 2847, UniformMatrix2x4fv_remap_index }, - { 32551, UniformMatrix3x2fv_remap_index }, - { 30161, UniformMatrix3x4fv_remap_index }, - { 16226, UniformMatrix4x2fv_remap_index }, - { 3263, UniformMatrix4x3fv_remap_index }, - { 5030, ClampColor_remap_index }, - { 17982, ClearBufferfi_remap_index }, - { 17448, ClearBufferfv_remap_index }, - { 29184, ClearBufferiv_remap_index }, - { 13516, ClearBufferuiv_remap_index }, - { 19808, GetStringi_remap_index }, - { 2788, TexBuffer_remap_index }, - { 938, FramebufferTexture_remap_index }, - { 26315, GetBufferParameteri64v_remap_index }, - { 10106, GetInteger64i_v_remap_index }, - { 23178, VertexAttribDivisor_remap_index }, - { 9920, LoadTransposeMatrixdARB_remap_index }, - { 30568, LoadTransposeMatrixfARB_remap_index }, - { 5608, MultTransposeMatrixdARB_remap_index }, - { 23523, MultTransposeMatrixfARB_remap_index }, - { 216, SampleCoverageARB_remap_index }, - { 5834, CompressedTexImage1DARB_remap_index }, - { 24051, CompressedTexImage2DARB_remap_index }, - { 3984, CompressedTexImage3DARB_remap_index }, - { 18242, CompressedTexSubImage1DARB_remap_index }, - { 2050, CompressedTexSubImage2DARB_remap_index }, - { 20230, CompressedTexSubImage3DARB_remap_index }, - { 28340, GetCompressedTexImageARB_remap_index }, - { 3829, DisableVertexAttribArrayARB_remap_index }, - { 29726, EnableVertexAttribArrayARB_remap_index }, - { 31682, GetProgramEnvParameterdvARB_remap_index }, - { 23403, GetProgramEnvParameterfvARB_remap_index }, - { 27277, GetProgramLocalParameterdvARB_remap_index }, - { 8066, GetProgramLocalParameterfvARB_remap_index }, - { 18376, GetProgramStringARB_remap_index }, - { 27472, GetProgramivARB_remap_index }, - { 20425, GetVertexAttribdvARB_remap_index }, - { 16034, GetVertexAttribfvARB_remap_index }, - { 9765, GetVertexAttribivARB_remap_index }, - { 19289, ProgramEnvParameter4dARB_remap_index }, - { 25072, ProgramEnvParameter4dvARB_remap_index }, - { 16770, ProgramEnvParameter4fARB_remap_index }, - { 8965, ProgramEnvParameter4fvARB_remap_index }, - { 3947, ProgramLocalParameter4dARB_remap_index }, - { 13021, ProgramLocalParameter4dvARB_remap_index }, - { 29205, ProgramLocalParameter4fARB_remap_index }, - { 25675, ProgramLocalParameter4fvARB_remap_index }, - { 28094, ProgramStringARB_remap_index }, - { 19539, VertexAttrib1dARB_remap_index }, - { 15688, VertexAttrib1dvARB_remap_index }, - { 4122, VertexAttrib1fARB_remap_index }, - { 32632, VertexAttrib1fvARB_remap_index }, - { 7150, VertexAttrib1sARB_remap_index }, - { 2224, VertexAttrib1svARB_remap_index }, - { 15119, VertexAttrib2dARB_remap_index }, - { 17469, VertexAttrib2dvARB_remap_index }, - { 1596, VertexAttrib2fARB_remap_index }, - { 17582, VertexAttrib2fvARB_remap_index }, - { 32258, VertexAttrib2sARB_remap_index }, - { 31319, VertexAttrib2svARB_remap_index }, - { 11268, VertexAttrib3dARB_remap_index }, - { 8632, VertexAttrib3dvARB_remap_index }, - { 1683, VertexAttrib3fARB_remap_index }, - { 22415, VertexAttrib3fvARB_remap_index }, - { 27941, VertexAttrib3sARB_remap_index }, - { 20167, VertexAttrib3svARB_remap_index }, - { 4895, VertexAttrib4NbvARB_remap_index }, - { 17805, VertexAttrib4NivARB_remap_index }, - { 22370, VertexAttrib4NsvARB_remap_index }, - { 23355, VertexAttrib4NubARB_remap_index }, - { 31565, VertexAttrib4NubvARB_remap_index }, - { 18950, VertexAttrib4NuivARB_remap_index }, - { 3136, VertexAttrib4NusvARB_remap_index }, - { 10846, VertexAttrib4bvARB_remap_index }, - { 26685, VertexAttrib4dARB_remap_index }, - { 21189, VertexAttrib4dvARB_remap_index }, - { 11422, VertexAttrib4fARB_remap_index }, - { 11826, VertexAttrib4fvARB_remap_index }, - { 10222, VertexAttrib4ivARB_remap_index }, - { 17262, VertexAttrib4sARB_remap_index }, - { 30754, VertexAttrib4svARB_remap_index }, - { 16575, VertexAttrib4ubvARB_remap_index }, - { 30050, VertexAttrib4uivARB_remap_index }, - { 19978, VertexAttrib4usvARB_remap_index }, - { 21967, VertexAttribPointerARB_remap_index }, - { 32392, BindBufferARB_remap_index }, - { 6857, BufferDataARB_remap_index }, - { 1498, BufferSubDataARB_remap_index }, - { 30331, DeleteBuffersARB_remap_index }, - { 32675, GenBuffersARB_remap_index }, - { 17625, GetBufferParameterivARB_remap_index }, - { 16722, GetBufferPointervARB_remap_index }, - { 1451, GetBufferSubDataARB_remap_index }, - { 29998, IsBufferARB_remap_index }, - { 26159, MapBufferARB_remap_index }, - { 30969, UnmapBufferARB_remap_index }, - { 312, BeginQueryARB_remap_index }, - { 19634, DeleteQueriesARB_remap_index }, - { 12153, EndQueryARB_remap_index }, - { 28819, GenQueriesARB_remap_index }, - { 1942, GetQueryObjectivARB_remap_index }, - { 17306, GetQueryObjectuivARB_remap_index }, - { 1740, GetQueryivARB_remap_index }, - { 19885, IsQueryARB_remap_index }, - { 8242, AttachObjectARB_remap_index }, - { 18487, CompileShaderARB_remap_index }, - { 3205, CreateProgramObjectARB_remap_index }, - { 6802, CreateShaderObjectARB_remap_index }, - { 14454, DeleteObjectARB_remap_index }, - { 23842, DetachObjectARB_remap_index }, - { 11898, GetActiveUniformARB_remap_index }, - { 9440, GetAttachedObjectsARB_remap_index }, - { 9747, GetHandleARB_remap_index }, - { 32425, GetInfoLogARB_remap_index }, - { 31636, GetObjectParameterfvARB_remap_index }, - { 27151, GetObjectParameterivARB_remap_index }, - { 28577, GetShaderSourceARB_remap_index }, - { 27801, GetUniformLocationARB_remap_index }, - { 23625, GetUniformfvARB_remap_index }, - { 12596, GetUniformivARB_remap_index }, - { 20023, LinkProgramARB_remap_index }, - { 20081, ShaderSourceARB_remap_index }, - { 7524, Uniform1fARB_remap_index }, - { 29414, Uniform1fvARB_remap_index }, - { 21936, Uniform1iARB_remap_index }, - { 20878, Uniform1ivARB_remap_index }, - { 2173, Uniform2fARB_remap_index }, - { 14290, Uniform2fvARB_remap_index }, - { 26046, Uniform2iARB_remap_index }, - { 2293, Uniform2ivARB_remap_index }, - { 18597, Uniform3fARB_remap_index }, - { 9470, Uniform3fvARB_remap_index }, - { 6396, Uniform3iARB_remap_index }, - { 16828, Uniform3ivARB_remap_index }, - { 19095, Uniform4fARB_remap_index }, - { 23489, Uniform4fvARB_remap_index }, - { 24751, Uniform4iARB_remap_index }, - { 20391, Uniform4ivARB_remap_index }, - { 8294, UniformMatrix2fvARB_remap_index }, + { 1616, AttachShader_remap_index }, + { 9893, CreateProgram_remap_index }, + { 22964, CreateShader_remap_index }, + { 25451, DeleteProgram_remap_index }, + { 18608, DeleteShader_remap_index }, + { 23465, DetachShader_remap_index }, + { 17974, GetAttachedShaders_remap_index }, + { 4856, GetProgramInfoLog_remap_index }, + { 444, GetProgramiv_remap_index }, + { 6529, GetShaderInfoLog_remap_index }, + { 31120, GetShaderiv_remap_index }, + { 13387, IsProgram_remap_index }, + { 12308, IsShader_remap_index }, + { 10023, StencilFuncSeparate_remap_index }, + { 3960, StencilMaskSeparate_remap_index }, + { 7594, StencilOpSeparate_remap_index }, + { 22252, UniformMatrix2x3fv_remap_index }, + { 2886, UniformMatrix2x4fv_remap_index }, + { 32826, UniformMatrix3x2fv_remap_index }, + { 30442, UniformMatrix3x4fv_remap_index }, + { 16264, UniformMatrix4x2fv_remap_index }, + { 3302, UniformMatrix4x3fv_remap_index }, + { 5017, ClampColor_remap_index }, + { 18028, ClearBufferfi_remap_index }, + { 17470, ClearBufferfv_remap_index }, + { 29465, ClearBufferiv_remap_index }, + { 13592, ClearBufferuiv_remap_index }, + { 19891, GetStringi_remap_index }, + { 2827, TexBuffer_remap_index }, + { 977, FramebufferTexture_remap_index }, + { 26477, GetBufferParameteri64v_remap_index }, + { 10123, GetInteger64i_v_remap_index }, + { 23278, VertexAttribDivisor_remap_index }, + { 9911, LoadTransposeMatrixdARB_remap_index }, + { 30849, LoadTransposeMatrixfARB_remap_index }, + { 5637, MultTransposeMatrixdARB_remap_index }, + { 23652, MultTransposeMatrixfARB_remap_index }, + { 255, SampleCoverageARB_remap_index }, + { 5821, CompressedTexImage1DARB_remap_index }, + { 24180, CompressedTexImage2DARB_remap_index }, + { 4023, CompressedTexImage3DARB_remap_index }, + { 18325, CompressedTexSubImage1DARB_remap_index }, + { 2089, CompressedTexSubImage2DARB_remap_index }, + { 20313, CompressedTexSubImage3DARB_remap_index }, + { 28621, GetCompressedTexImageARB_remap_index }, + { 3868, DisableVertexAttribArrayARB_remap_index }, + { 30007, EnableVertexAttribArrayARB_remap_index }, + { 31924, GetProgramEnvParameterdvARB_remap_index }, + { 23532, GetProgramEnvParameterfvARB_remap_index }, + { 27506, GetProgramLocalParameterdvARB_remap_index }, + { 8036, GetProgramLocalParameterfvARB_remap_index }, + { 18459, GetProgramStringARB_remap_index }, + { 27701, GetProgramivARB_remap_index }, + { 20508, GetVertexAttribdvARB_remap_index }, + { 16072, GetVertexAttribfvARB_remap_index }, + { 9735, GetVertexAttribivARB_remap_index }, + { 19372, ProgramEnvParameter4dARB_remap_index }, + { 25201, ProgramEnvParameter4dvARB_remap_index }, + { 16792, ProgramEnvParameter4fARB_remap_index }, + { 8935, ProgramEnvParameter4fvARB_remap_index }, + { 3986, ProgramLocalParameter4dARB_remap_index }, + { 13097, ProgramLocalParameter4dvARB_remap_index }, + { 29486, ProgramLocalParameter4fARB_remap_index }, + { 25837, ProgramLocalParameter4fvARB_remap_index }, + { 28375, ProgramStringARB_remap_index }, + { 19622, VertexAttrib1dARB_remap_index }, + { 15726, VertexAttrib1dvARB_remap_index }, + { 4161, VertexAttrib1fARB_remap_index }, + { 32907, VertexAttrib1fvARB_remap_index }, + { 7120, VertexAttrib1sARB_remap_index }, + { 2263, VertexAttrib1svARB_remap_index }, + { 15157, VertexAttrib2dARB_remap_index }, + { 17491, VertexAttrib2dvARB_remap_index }, + { 1635, VertexAttrib2fARB_remap_index }, + { 17604, VertexAttrib2fvARB_remap_index }, + { 32533, VertexAttrib2sARB_remap_index }, + { 31561, VertexAttrib2svARB_remap_index }, + { 11274, VertexAttrib3dARB_remap_index }, + { 8602, VertexAttrib3dvARB_remap_index }, + { 1722, VertexAttrib3fARB_remap_index }, + { 22515, VertexAttrib3fvARB_remap_index }, + { 28222, VertexAttrib3sARB_remap_index }, + { 20250, VertexAttrib3svARB_remap_index }, + { 4882, VertexAttrib4NbvARB_remap_index }, + { 17851, VertexAttrib4NivARB_remap_index }, + { 22470, VertexAttrib4NsvARB_remap_index }, + { 23484, VertexAttrib4NubARB_remap_index }, + { 31807, VertexAttrib4NubvARB_remap_index }, + { 19033, VertexAttrib4NuivARB_remap_index }, + { 3175, VertexAttrib4NusvARB_remap_index }, + { 10863, VertexAttrib4bvARB_remap_index }, + { 26879, VertexAttrib4dARB_remap_index }, + { 21272, VertexAttrib4dvARB_remap_index }, + { 11428, VertexAttrib4fARB_remap_index }, + { 11832, VertexAttrib4fvARB_remap_index }, + { 10239, VertexAttrib4ivARB_remap_index }, + { 17284, VertexAttrib4sARB_remap_index }, + { 31035, VertexAttrib4svARB_remap_index }, + { 16597, VertexAttrib4ubvARB_remap_index }, + { 30331, VertexAttrib4uivARB_remap_index }, + { 20061, VertexAttrib4usvARB_remap_index }, + { 22067, VertexAttribPointerARB_remap_index }, + { 32667, BindBufferARB_remap_index }, + { 6827, BufferDataARB_remap_index }, + { 1537, BufferSubDataARB_remap_index }, + { 30612, DeleteBuffersARB_remap_index }, + { 32950, GenBuffersARB_remap_index }, + { 17647, GetBufferParameterivARB_remap_index }, + { 16744, GetBufferPointervARB_remap_index }, + { 1490, GetBufferSubDataARB_remap_index }, + { 30279, IsBufferARB_remap_index }, + { 26321, MapBufferARB_remap_index }, + { 31250, UnmapBufferARB_remap_index }, + { 351, BeginQueryARB_remap_index }, + { 19717, DeleteQueriesARB_remap_index }, + { 12159, EndQueryARB_remap_index }, + { 29100, GenQueriesARB_remap_index }, + { 1981, GetQueryObjectivARB_remap_index }, + { 17328, GetQueryObjectuivARB_remap_index }, + { 1779, GetQueryivARB_remap_index }, + { 19968, IsQueryARB_remap_index }, + { 8212, AttachObjectARB_remap_index }, + { 18570, CompileShaderARB_remap_index }, + { 3244, CreateProgramObjectARB_remap_index }, + { 6772, CreateShaderObjectARB_remap_index }, + { 14459, DeleteObjectARB_remap_index }, + { 23971, DetachObjectARB_remap_index }, + { 11904, GetActiveUniformARB_remap_index }, + { 9410, GetAttachedObjectsARB_remap_index }, + { 9717, GetHandleARB_remap_index }, + { 32700, GetInfoLogARB_remap_index }, + { 31878, GetObjectParameterfvARB_remap_index }, + { 27380, GetObjectParameterivARB_remap_index }, + { 28858, GetShaderSourceARB_remap_index }, + { 28082, GetUniformLocationARB_remap_index }, + { 23754, GetUniformfvARB_remap_index }, + { 12672, GetUniformivARB_remap_index }, + { 20106, LinkProgramARB_remap_index }, + { 20164, ShaderSourceARB_remap_index }, + { 7494, Uniform1fARB_remap_index }, + { 29695, Uniform1fvARB_remap_index }, + { 22036, Uniform1iARB_remap_index }, + { 20961, Uniform1ivARB_remap_index }, + { 2212, Uniform2fARB_remap_index }, + { 14295, Uniform2fvARB_remap_index }, + { 26208, Uniform2iARB_remap_index }, + { 2332, Uniform2ivARB_remap_index }, + { 18680, Uniform3fARB_remap_index }, + { 9440, Uniform3fvARB_remap_index }, + { 6383, Uniform3iARB_remap_index }, + { 16850, Uniform3ivARB_remap_index }, + { 19178, Uniform4fARB_remap_index }, + { 23618, Uniform4fvARB_remap_index }, + { 24880, Uniform4iARB_remap_index }, + { 20474, Uniform4ivARB_remap_index }, + { 8264, UniformMatrix2fvARB_remap_index }, { 17, UniformMatrix3fvARB_remap_index }, - { 2690, UniformMatrix4fvARB_remap_index }, - { 25184, UseProgramObjectARB_remap_index }, - { 14807, ValidateProgramARB_remap_index }, - { 21232, BindAttribLocationARB_remap_index }, - { 4940, GetActiveAttribARB_remap_index }, - { 16509, GetAttribLocationARB_remap_index }, - { 29132, DrawBuffersARB_remap_index }, - { 17850, DrawArraysInstancedARB_remap_index }, - { 6457, DrawElementsInstancedARB_remap_index }, - { 13126, RenderbufferStorageMultisample_remap_index }, - { 13597, FramebufferTextureARB_remap_index }, - { 25577, FramebufferTextureFaceARB_remap_index }, - { 23991, ProgramParameteriARB_remap_index }, - { 19143, FlushMappedBufferRange_remap_index }, - { 27568, MapBufferRange_remap_index }, - { 16337, BindVertexArray_remap_index }, - { 14630, GenVertexArrays_remap_index }, - { 29928, CopyBufferSubData_remap_index }, - { 30858, ClientWaitSync_remap_index }, - { 2609, DeleteSync_remap_index }, - { 7191, FenceSync_remap_index }, - { 15178, GetInteger64v_remap_index }, - { 22477, GetSynciv_remap_index }, - { 29071, IsSync_remap_index }, - { 9388, WaitSync_remap_index }, - { 3797, DrawElementsBaseVertex_remap_index }, - { 30263, DrawRangeElementsBaseVertex_remap_index }, - { 26190, MultiDrawElementsBaseVertex_remap_index }, - { 5091, BindTransformFeedback_remap_index }, - { 3232, DeleteTransformFeedbacks_remap_index }, - { 6429, DrawTransformFeedback_remap_index }, - { 9607, GenTransformFeedbacks_remap_index }, - { 27984, IsTransformFeedback_remap_index }, - { 25770, PauseTransformFeedback_remap_index }, - { 5528, ResumeTransformFeedback_remap_index }, - { 5396, PolygonOffsetEXT_remap_index }, - { 23099, GetPixelTexGenParameterfvSGIS_remap_index }, - { 4417, GetPixelTexGenParameterivSGIS_remap_index }, - { 22832, PixelTexGenParameterfSGIS_remap_index }, - { 624, PixelTexGenParameterfvSGIS_remap_index }, - { 12634, PixelTexGenParameteriSGIS_remap_index }, - { 13771, PixelTexGenParameterivSGIS_remap_index }, - { 16425, SampleMaskSGIS_remap_index }, - { 19825, SamplePatternSGIS_remap_index }, - { 26119, ColorPointerEXT_remap_index }, - { 17512, EdgeFlagPointerEXT_remap_index }, - { 6050, IndexPointerEXT_remap_index }, - { 6130, NormalPointerEXT_remap_index }, - { 15772, TexCoordPointerEXT_remap_index }, - { 6980, VertexPointerEXT_remap_index }, - { 3599, PointParameterfEXT_remap_index }, - { 7831, PointParameterfvEXT_remap_index }, - { 31734, LockArraysEXT_remap_index }, - { 14871, UnlockArraysEXT_remap_index }, - { 1267, SecondaryColor3bEXT_remap_index }, - { 7990, SecondaryColor3bvEXT_remap_index }, - { 10399, SecondaryColor3dEXT_remap_index }, - { 25380, SecondaryColor3dvEXT_remap_index }, - { 27850, SecondaryColor3fEXT_remap_index }, - { 18178, SecondaryColor3fvEXT_remap_index }, - { 470, SecondaryColor3iEXT_remap_index }, - { 16082, SecondaryColor3ivEXT_remap_index }, - { 10034, SecondaryColor3sEXT_remap_index }, - { 30522, SecondaryColor3svEXT_remap_index }, - { 26987, SecondaryColor3ubEXT_remap_index }, - { 21123, SecondaryColor3ubvEXT_remap_index }, - { 12876, SecondaryColor3uiEXT_remap_index }, - { 22719, SecondaryColor3uivEXT_remap_index }, - { 25627, SecondaryColor3usEXT_remap_index }, - { 12949, SecondaryColor3usvEXT_remap_index }, - { 11769, SecondaryColorPointerEXT_remap_index }, - { 25441, MultiDrawArraysEXT_remap_index }, - { 20813, MultiDrawElementsEXT_remap_index }, - { 21008, FogCoordPointerEXT_remap_index }, - { 4566, FogCoorddEXT_remap_index }, - { 31135, FogCoorddvEXT_remap_index }, - { 4683, FogCoordfEXT_remap_index }, - { 26910, FogCoordfvEXT_remap_index }, - { 19047, PixelTexGenSGIX_remap_index }, - { 27495, BlendFuncSeparateEXT_remap_index }, - { 6892, FlushVertexArrayRangeNV_remap_index }, - { 5345, VertexArrayRangeNV_remap_index }, - { 27915, CombinerInputNV_remap_index }, - { 2116, CombinerOutputNV_remap_index }, - { 30675, CombinerParameterfNV_remap_index }, - { 5219, CombinerParameterfvNV_remap_index }, - { 22201, CombinerParameteriNV_remap_index }, - { 32150, CombinerParameterivNV_remap_index }, - { 7268, FinalCombinerInputNV_remap_index }, - { 9813, GetCombinerInputParameterfvNV_remap_index }, - { 31987, GetCombinerInputParameterivNV_remap_index }, - { 13872, GetCombinerOutputParameterfvNV_remap_index }, - { 13700, GetCombinerOutputParameterivNV_remap_index }, - { 6637, GetFinalCombinerInputParameterfvNV_remap_index }, - { 24623, GetFinalCombinerInputParameterivNV_remap_index }, - { 12574, ResizeBuffersMESA_remap_index }, - { 11095, WindowPos2dMESA_remap_index }, - { 1060, WindowPos2dvMESA_remap_index }, - { 32978, WindowPos2fMESA_remap_index }, - { 7935, WindowPos2fvMESA_remap_index }, - { 18125, WindowPos2iMESA_remap_index }, - { 20298, WindowPos2ivMESA_remap_index }, - { 20912, WindowPos2sMESA_remap_index }, - { 5748, WindowPos2svMESA_remap_index }, - { 7760, WindowPos3dMESA_remap_index }, - { 14018, WindowPos3dvMESA_remap_index }, - { 516, WindowPos3fMESA_remap_index }, - { 14932, WindowPos3fvMESA_remap_index }, - { 23884, WindowPos3iMESA_remap_index }, - { 29873, WindowPos3ivMESA_remap_index }, - { 18742, WindowPos3sMESA_remap_index }, - { 31391, WindowPos3svMESA_remap_index }, - { 11046, WindowPos4dMESA_remap_index }, - { 16966, WindowPos4dvMESA_remap_index }, - { 13977, WindowPos4fMESA_remap_index }, - { 30429, WindowPos4fvMESA_remap_index }, - { 30026, WindowPos4iMESA_remap_index }, - { 12377, WindowPos4ivMESA_remap_index }, - { 18926, WindowPos4sMESA_remap_index }, - { 3183, WindowPos4svMESA_remap_index }, - { 13739, MultiModeDrawArraysIBM_remap_index }, - { 28690, MultiModeDrawElementsIBM_remap_index }, - { 12181, DeleteFencesNV_remap_index }, - { 27762, FinishFenceNV_remap_index }, - { 3721, GenFencesNV_remap_index }, - { 16946, GetFenceivNV_remap_index }, - { 8227, IsFenceNV_remap_index }, - { 13627, SetFenceNV_remap_index }, - { 4178, TestFenceNV_remap_index }, - { 31362, AreProgramsResidentNV_remap_index }, - { 30717, BindProgramNV_remap_index }, - { 25710, DeleteProgramsNV_remap_index }, - { 21341, ExecuteProgramNV_remap_index }, - { 32871, GenProgramsNV_remap_index }, - { 23204, GetProgramParameterdvNV_remap_index }, - { 10461, GetProgramParameterfvNV_remap_index }, - { 26093, GetProgramStringNV_remap_index }, - { 24261, GetProgramivNV_remap_index }, - { 23438, GetTrackMatrixivNV_remap_index }, - { 25887, GetVertexAttribPointervNV_remap_index }, - { 24556, GetVertexAttribdvNV_remap_index }, - { 9283, GetVertexAttribfvNV_remap_index }, - { 18349, GetVertexAttribivNV_remap_index }, - { 19173, IsProgramNV_remap_index }, - { 9366, LoadProgramNV_remap_index }, - { 27591, ProgramParameters4dvNV_remap_index }, - { 24191, ProgramParameters4fvNV_remap_index }, - { 20602, RequestResidentProgramsNV_remap_index }, - { 22179, TrackMatrixNV_remap_index }, - { 31964, VertexAttrib1dNV_remap_index }, - { 13538, VertexAttrib1dvNV_remap_index }, - { 28196, VertexAttrib1fNV_remap_index }, - { 2415, VertexAttrib1fvNV_remap_index }, - { 30486, VertexAttrib1sNV_remap_index }, - { 15005, VertexAttrib1svNV_remap_index }, - { 4845, VertexAttrib2dNV_remap_index }, - { 13431, VertexAttrib2dvNV_remap_index }, - { 20057, VertexAttrib2fNV_remap_index }, - { 12997, VertexAttrib2fvNV_remap_index }, - { 5960, VertexAttrib2sNV_remap_index }, - { 18796, VertexAttrib2svNV_remap_index }, - { 11243, VertexAttrib3dNV_remap_index }, - { 31612, VertexAttrib3dvNV_remap_index }, - { 10273, VertexAttrib3fNV_remap_index }, - { 24583, VertexAttrib3fvNV_remap_index }, - { 22022, VertexAttrib3sNV_remap_index }, - { 23465, VertexAttrib3svNV_remap_index }, - { 28664, VertexAttrib4dNV_remap_index }, - { 32908, VertexAttrib4dvNV_remap_index }, - { 4467, VertexAttrib4fNV_remap_index }, - { 9416, VertexAttrib4fvNV_remap_index }, - { 26569, VertexAttrib4sNV_remap_index }, - { 1409, VertexAttrib4svNV_remap_index }, - { 5003, VertexAttrib4ubNV_remap_index }, - { 778, VertexAttrib4ubvNV_remap_index }, - { 21521, VertexAttribPointerNV_remap_index }, - { 2267, VertexAttribs1dvNV_remap_index }, - { 25975, VertexAttribs1fvNV_remap_index }, - { 32708, VertexAttribs1svNV_remap_index }, - { 10298, VertexAttribs2dvNV_remap_index }, - { 25145, VertexAttribs2fvNV_remap_index }, - { 17538, VertexAttribs2svNV_remap_index }, - { 5247, VertexAttribs3dvNV_remap_index }, - { 2147, VertexAttribs3fvNV_remap_index }, - { 29621, VertexAttribs3svNV_remap_index }, - { 26659, VertexAttribs4dvNV_remap_index }, - { 5319, VertexAttribs4fvNV_remap_index }, - { 32495, VertexAttribs4svNV_remap_index }, - { 29369, VertexAttribs4ubvNV_remap_index }, - { 26729, GetTexBumpParameterfvATI_remap_index }, - { 32749, GetTexBumpParameterivATI_remap_index }, - { 18459, TexBumpParameterfvATI_remap_index }, - { 20473, TexBumpParameterivATI_remap_index }, - { 15551, AlphaFragmentOp1ATI_remap_index }, - { 10889, AlphaFragmentOp2ATI_remap_index }, - { 24499, AlphaFragmentOp3ATI_remap_index }, - { 29548, BeginFragmentShaderATI_remap_index }, - { 30916, BindFragmentShaderATI_remap_index }, - { 23594, ColorFragmentOp1ATI_remap_index }, - { 4345, ColorFragmentOp2ATI_remap_index }, - { 31257, ColorFragmentOp3ATI_remap_index }, - { 5485, DeleteFragmentShaderATI_remap_index }, - { 32932, EndFragmentShaderATI_remap_index }, - { 32178, GenFragmentShadersATI_remap_index }, - { 25299, PassTexCoordATI_remap_index }, - { 6960, SampleMapATI_remap_index }, - { 6733, SetFragmentShaderConstantATI_remap_index }, - { 363, PointParameteriNV_remap_index }, - { 14179, PointParameterivNV_remap_index }, - { 28503, ActiveStencilFaceEXT_remap_index }, - { 27251, BindVertexArrayAPPLE_remap_index }, - { 2737, DeleteVertexArraysAPPLE_remap_index }, - { 17955, GenVertexArraysAPPLE_remap_index }, - { 23269, IsVertexArrayAPPLE_remap_index }, - { 819, GetProgramNamedParameterdvNV_remap_index }, - { 3562, GetProgramNamedParameterfvNV_remap_index }, - { 26760, ProgramNamedParameter4dNV_remap_index }, - { 14505, ProgramNamedParameter4dvNV_remap_index }, - { 8899, ProgramNamedParameter4fNV_remap_index }, - { 11734, ProgramNamedParameter4fvNV_remap_index }, - { 16877, PrimitiveRestartIndexNV_remap_index }, - { 30406, PrimitiveRestartNV_remap_index }, - { 24170, DepthBoundsEXT_remap_index }, - { 1159, BlendEquationSeparateEXT_remap_index }, - { 14706, BindFramebufferEXT_remap_index }, - { 25486, BindRenderbufferEXT_remap_index }, - { 9663, CheckFramebufferStatusEXT_remap_index }, - { 22520, DeleteFramebuffersEXT_remap_index }, - { 31514, DeleteRenderbuffersEXT_remap_index }, - { 13455, FramebufferRenderbufferEXT_remap_index }, - { 13644, FramebufferTexture1DEXT_remap_index }, - { 11528, FramebufferTexture2DEXT_remap_index }, - { 11148, FramebufferTexture3DEXT_remap_index }, - { 23135, GenFramebuffersEXT_remap_index }, - { 17403, GenRenderbuffersEXT_remap_index }, - { 6679, GenerateMipmapEXT_remap_index }, - { 21597, GetFramebufferAttachmentParameterivEXT_remap_index }, - { 32084, GetRenderbufferParameterivEXT_remap_index }, - { 20353, IsFramebufferEXT_remap_index }, - { 32831, IsRenderbufferEXT_remap_index }, - { 8174, RenderbufferStorageEXT_remap_index }, - { 695, BlitFramebufferEXT_remap_index }, - { 14324, BufferParameteriAPPLE_remap_index }, - { 19205, FlushMappedBufferRangeAPPLE_remap_index }, - { 1815, BindFragDataLocationEXT_remap_index }, - { 24283, GetFragDataLocationEXT_remap_index }, - { 10576, GetUniformuivEXT_remap_index }, - { 2933, GetVertexAttribIivEXT_remap_index }, - { 4195, GetVertexAttribIuivEXT_remap_index }, - { 12014, Uniform1uiEXT_remap_index }, - { 27676, Uniform1uivEXT_remap_index }, - { 22118, Uniform2uiEXT_remap_index }, - { 4309, Uniform2uivEXT_remap_index }, - { 28943, Uniform3uiEXT_remap_index }, - { 14652, Uniform3uivEXT_remap_index }, - { 3486, Uniform4uiEXT_remap_index }, - { 8675, Uniform4uivEXT_remap_index }, - { 18306, VertexAttribI1iEXT_remap_index }, - { 965, VertexAttribI1ivEXT_remap_index }, - { 2516, VertexAttribI1uiEXT_remap_index }, - { 12725, VertexAttribI1uivEXT_remap_index }, + { 2729, UniformMatrix4fvARB_remap_index }, + { 25313, UseProgramObjectARB_remap_index }, + { 14845, ValidateProgramARB_remap_index }, + { 21315, BindAttribLocationARB_remap_index }, + { 4927, GetActiveAttribARB_remap_index }, + { 16531, GetAttribLocationARB_remap_index }, + { 29413, DrawBuffersARB_remap_index }, + { 17896, DrawArraysInstancedARB_remap_index }, + { 6444, DrawElementsInstancedARB_remap_index }, + { 13202, RenderbufferStorageMultisample_remap_index }, + { 13673, FramebufferTextureARB_remap_index }, + { 25739, FramebufferTextureFaceARB_remap_index }, + { 24120, ProgramParameteriARB_remap_index }, + { 23436, VertexAttribDivisorARB_remap_index }, + { 19226, FlushMappedBufferRange_remap_index }, + { 27797, MapBufferRange_remap_index }, + { 16375, BindVertexArray_remap_index }, + { 14668, GenVertexArrays_remap_index }, + { 30209, CopyBufferSubData_remap_index }, + { 31139, ClientWaitSync_remap_index }, + { 2648, DeleteSync_remap_index }, + { 7161, FenceSync_remap_index }, + { 15216, GetInteger64v_remap_index }, + { 22577, GetSynciv_remap_index }, + { 29352, IsSync_remap_index }, + { 9358, WaitSync_remap_index }, + { 3836, DrawElementsBaseVertex_remap_index }, + { 30544, DrawRangeElementsBaseVertex_remap_index }, + { 26352, MultiDrawElementsBaseVertex_remap_index }, + { 32083, BlendEquationSeparateiARB_remap_index }, + { 17740, BlendEquationiARB_remap_index }, + { 12641, BlendFuncSeparateiARB_remap_index }, + { 9783, BlendFunciARB_remap_index }, + { 5078, BindTransformFeedback_remap_index }, + { 3271, DeleteTransformFeedbacks_remap_index }, + { 6416, DrawTransformFeedback_remap_index }, + { 9577, GenTransformFeedbacks_remap_index }, + { 28265, IsTransformFeedback_remap_index }, + { 25932, PauseTransformFeedback_remap_index }, + { 5557, ResumeTransformFeedback_remap_index }, + { 21635, ClearDepthf_remap_index }, + { 6720, DepthRangef_remap_index }, + { 14480, GetShaderPrecisionFormat_remap_index }, + { 9963, ReleaseShaderCompiler_remap_index }, + { 10906, ShaderBinary_remap_index }, + { 5425, PolygonOffsetEXT_remap_index }, + { 23199, GetPixelTexGenParameterfvSGIS_remap_index }, + { 4404, GetPixelTexGenParameterivSGIS_remap_index }, + { 22932, PixelTexGenParameterfSGIS_remap_index }, + { 663, PixelTexGenParameterfvSGIS_remap_index }, + { 12710, PixelTexGenParameteriSGIS_remap_index }, + { 13815, PixelTexGenParameterivSGIS_remap_index }, + { 18224, SampleMaskSGIS_remap_index }, + { 19908, SamplePatternSGIS_remap_index }, + { 26281, ColorPointerEXT_remap_index }, + { 17534, EdgeFlagPointerEXT_remap_index }, + { 6037, IndexPointerEXT_remap_index }, + { 6117, NormalPointerEXT_remap_index }, + { 15810, TexCoordPointerEXT_remap_index }, + { 6950, VertexPointerEXT_remap_index }, + { 3638, PointParameterfEXT_remap_index }, + { 7801, PointParameterfvEXT_remap_index }, + { 31976, LockArraysEXT_remap_index }, + { 14909, UnlockArraysEXT_remap_index }, + { 1306, SecondaryColor3bEXT_remap_index }, + { 7960, SecondaryColor3bvEXT_remap_index }, + { 10416, SecondaryColor3dEXT_remap_index }, + { 25509, SecondaryColor3dvEXT_remap_index }, + { 28131, SecondaryColor3fEXT_remap_index }, + { 18261, SecondaryColor3fvEXT_remap_index }, + { 509, SecondaryColor3iEXT_remap_index }, + { 16120, SecondaryColor3ivEXT_remap_index }, + { 10051, SecondaryColor3sEXT_remap_index }, + { 30803, SecondaryColor3svEXT_remap_index }, + { 27216, SecondaryColor3ubEXT_remap_index }, + { 21206, SecondaryColor3ubvEXT_remap_index }, + { 12952, SecondaryColor3uiEXT_remap_index }, + { 22819, SecondaryColor3uivEXT_remap_index }, + { 25789, SecondaryColor3usEXT_remap_index }, + { 13025, SecondaryColor3usvEXT_remap_index }, + { 11775, SecondaryColorPointerEXT_remap_index }, + { 25603, MultiDrawArraysEXT_remap_index }, + { 20896, MultiDrawElementsEXT_remap_index }, + { 21091, FogCoordPointerEXT_remap_index }, + { 4553, FogCoorddEXT_remap_index }, + { 31377, FogCoorddvEXT_remap_index }, + { 4670, FogCoordfEXT_remap_index }, + { 27139, FogCoordfvEXT_remap_index }, + { 19130, PixelTexGenSGIX_remap_index }, + { 27724, BlendFuncSeparateEXT_remap_index }, + { 6862, FlushVertexArrayRangeNV_remap_index }, + { 5374, VertexArrayRangeNV_remap_index }, + { 28196, CombinerInputNV_remap_index }, + { 2155, CombinerOutputNV_remap_index }, + { 30956, CombinerParameterfNV_remap_index }, + { 5248, CombinerParameterfvNV_remap_index }, + { 22301, CombinerParameteriNV_remap_index }, + { 32425, CombinerParameterivNV_remap_index }, + { 7238, FinalCombinerInputNV_remap_index }, + { 9804, GetCombinerInputParameterfvNV_remap_index }, + { 32262, GetCombinerInputParameterivNV_remap_index }, + { 216, GetCombinerOutputParameterfvNV_remap_index }, + { 13776, GetCombinerOutputParameterivNV_remap_index }, + { 6624, GetFinalCombinerInputParameterfvNV_remap_index }, + { 24752, GetFinalCombinerInputParameterivNV_remap_index }, + { 12619, ResizeBuffersMESA_remap_index }, + { 11101, WindowPos2dMESA_remap_index }, + { 1099, WindowPos2dvMESA_remap_index }, + { 33253, WindowPos2fMESA_remap_index }, + { 7905, WindowPos2fvMESA_remap_index }, + { 18171, WindowPos2iMESA_remap_index }, + { 20381, WindowPos2ivMESA_remap_index }, + { 20995, WindowPos2sMESA_remap_index }, + { 5735, WindowPos2svMESA_remap_index }, + { 7730, WindowPos3dMESA_remap_index }, + { 14023, WindowPos3dvMESA_remap_index }, + { 555, WindowPos3fMESA_remap_index }, + { 14970, WindowPos3fvMESA_remap_index }, + { 24013, WindowPos3iMESA_remap_index }, + { 30154, WindowPos3ivMESA_remap_index }, + { 18825, WindowPos3sMESA_remap_index }, + { 31633, WindowPos3svMESA_remap_index }, + { 11052, WindowPos4dMESA_remap_index }, + { 16988, WindowPos4dvMESA_remap_index }, + { 13982, WindowPos4fMESA_remap_index }, + { 30710, WindowPos4fvMESA_remap_index }, + { 30307, WindowPos4iMESA_remap_index }, + { 12422, WindowPos4ivMESA_remap_index }, + { 19009, WindowPos4sMESA_remap_index }, + { 3222, WindowPos4svMESA_remap_index }, + { 26847, MultiModeDrawArraysIBM_remap_index }, + { 28971, MultiModeDrawElementsIBM_remap_index }, + { 12187, DeleteFencesNV_remap_index }, + { 28043, FinishFenceNV_remap_index }, + { 3760, GenFencesNV_remap_index }, + { 16968, GetFenceivNV_remap_index }, + { 8197, IsFenceNV_remap_index }, + { 13703, SetFenceNV_remap_index }, + { 4217, TestFenceNV_remap_index }, + { 31604, AreProgramsResidentNV_remap_index }, + { 30998, BindProgramNV_remap_index }, + { 25872, DeleteProgramsNV_remap_index }, + { 21424, ExecuteProgramNV_remap_index }, + { 33146, GenProgramsNV_remap_index }, + { 23304, GetProgramParameterdvNV_remap_index }, + { 10478, GetProgramParameterfvNV_remap_index }, + { 26255, GetProgramStringNV_remap_index }, + { 24390, GetProgramivNV_remap_index }, + { 23567, GetTrackMatrixivNV_remap_index }, + { 26049, GetVertexAttribPointervNV_remap_index }, + { 24685, GetVertexAttribdvNV_remap_index }, + { 9253, GetVertexAttribfvNV_remap_index }, + { 18432, GetVertexAttribivNV_remap_index }, + { 19256, IsProgramNV_remap_index }, + { 9336, LoadProgramNV_remap_index }, + { 27820, ProgramParameters4dvNV_remap_index }, + { 24320, ProgramParameters4fvNV_remap_index }, + { 20685, RequestResidentProgramsNV_remap_index }, + { 22279, TrackMatrixNV_remap_index }, + { 32239, VertexAttrib1dNV_remap_index }, + { 13614, VertexAttrib1dvNV_remap_index }, + { 28477, VertexAttrib1fNV_remap_index }, + { 2454, VertexAttrib1fvNV_remap_index }, + { 30767, VertexAttrib1sNV_remap_index }, + { 15043, VertexAttrib1svNV_remap_index }, + { 4832, VertexAttrib2dNV_remap_index }, + { 13507, VertexAttrib2dvNV_remap_index }, + { 20140, VertexAttrib2fNV_remap_index }, + { 13073, VertexAttrib2fvNV_remap_index }, + { 5947, VertexAttrib2sNV_remap_index }, + { 18879, VertexAttrib2svNV_remap_index }, + { 11249, VertexAttrib3dNV_remap_index }, + { 31854, VertexAttrib3dvNV_remap_index }, + { 10290, VertexAttrib3fNV_remap_index }, + { 24712, VertexAttrib3fvNV_remap_index }, + { 22122, VertexAttrib3sNV_remap_index }, + { 23594, VertexAttrib3svNV_remap_index }, + { 28945, VertexAttrib4dNV_remap_index }, + { 33183, VertexAttrib4dvNV_remap_index }, + { 4454, VertexAttrib4fNV_remap_index }, + { 9386, VertexAttrib4fvNV_remap_index }, + { 26731, VertexAttrib4sNV_remap_index }, + { 1448, VertexAttrib4svNV_remap_index }, + { 4990, VertexAttrib4ubNV_remap_index }, + { 817, VertexAttrib4ubvNV_remap_index }, + { 21604, VertexAttribPointerNV_remap_index }, + { 2306, VertexAttribs1dvNV_remap_index }, + { 26137, VertexAttribs1fvNV_remap_index }, + { 32983, VertexAttribs1svNV_remap_index }, + { 10315, VertexAttribs2dvNV_remap_index }, + { 25274, VertexAttribs2fvNV_remap_index }, + { 17560, VertexAttribs2svNV_remap_index }, + { 5276, VertexAttribs3dvNV_remap_index }, + { 2186, VertexAttribs3fvNV_remap_index }, + { 29902, VertexAttribs3svNV_remap_index }, + { 26821, VertexAttribs4dvNV_remap_index }, + { 5348, VertexAttribs4fvNV_remap_index }, + { 32770, VertexAttribs4svNV_remap_index }, + { 29650, VertexAttribs4ubvNV_remap_index }, + { 26923, GetTexBumpParameterfvATI_remap_index }, + { 33024, GetTexBumpParameterivATI_remap_index }, + { 18542, TexBumpParameterfvATI_remap_index }, + { 20556, TexBumpParameterivATI_remap_index }, + { 15589, AlphaFragmentOp1ATI_remap_index }, + { 25555, AlphaFragmentOp2ATI_remap_index }, + { 24628, AlphaFragmentOp3ATI_remap_index }, + { 29829, BeginFragmentShaderATI_remap_index }, + { 31197, BindFragmentShaderATI_remap_index }, + { 23723, ColorFragmentOp1ATI_remap_index }, + { 4332, ColorFragmentOp2ATI_remap_index }, + { 31499, ColorFragmentOp3ATI_remap_index }, + { 5514, DeleteFragmentShaderATI_remap_index }, + { 33207, EndFragmentShaderATI_remap_index }, + { 32453, GenFragmentShadersATI_remap_index }, + { 25428, PassTexCoordATI_remap_index }, + { 6930, SampleMapATI_remap_index }, + { 27034, SetFragmentShaderConstantATI_remap_index }, + { 402, PointParameteriNV_remap_index }, + { 14184, PointParameterivNV_remap_index }, + { 28784, ActiveStencilFaceEXT_remap_index }, + { 27480, BindVertexArrayAPPLE_remap_index }, + { 2776, DeleteVertexArraysAPPLE_remap_index }, + { 18001, GenVertexArraysAPPLE_remap_index }, + { 23369, IsVertexArrayAPPLE_remap_index }, + { 858, GetProgramNamedParameterdvNV_remap_index }, + { 3601, GetProgramNamedParameterfvNV_remap_index }, + { 26954, ProgramNamedParameter4dNV_remap_index }, + { 14543, ProgramNamedParameter4dvNV_remap_index }, + { 8869, ProgramNamedParameter4fNV_remap_index }, + { 11740, ProgramNamedParameter4fvNV_remap_index }, + { 16899, PrimitiveRestartIndexNV_remap_index }, + { 30687, PrimitiveRestartNV_remap_index }, + { 24299, DepthBoundsEXT_remap_index }, + { 1198, BlendEquationSeparateEXT_remap_index }, + { 14744, BindFramebufferEXT_remap_index }, + { 25648, BindRenderbufferEXT_remap_index }, + { 9633, CheckFramebufferStatusEXT_remap_index }, + { 22620, DeleteFramebuffersEXT_remap_index }, + { 31756, DeleteRenderbuffersEXT_remap_index }, + { 13531, FramebufferRenderbufferEXT_remap_index }, + { 13720, FramebufferTexture1DEXT_remap_index }, + { 11534, FramebufferTexture2DEXT_remap_index }, + { 11154, FramebufferTexture3DEXT_remap_index }, + { 23235, GenFramebuffersEXT_remap_index }, + { 17425, GenRenderbuffersEXT_remap_index }, + { 6666, GenerateMipmapEXT_remap_index }, + { 21697, GetFramebufferAttachmentParameterivEXT_remap_index }, + { 32359, GetRenderbufferParameterivEXT_remap_index }, + { 20436, IsFramebufferEXT_remap_index }, + { 33106, IsRenderbufferEXT_remap_index }, + { 8144, RenderbufferStorageEXT_remap_index }, + { 734, BlitFramebufferEXT_remap_index }, + { 14329, BufferParameteriAPPLE_remap_index }, + { 19288, FlushMappedBufferRangeAPPLE_remap_index }, + { 1854, BindFragDataLocationEXT_remap_index }, + { 24412, GetFragDataLocationEXT_remap_index }, + { 10593, GetUniformuivEXT_remap_index }, + { 2972, GetVertexAttribIivEXT_remap_index }, + { 27991, GetVertexAttribIuivEXT_remap_index }, + { 12020, Uniform1uiEXT_remap_index }, + { 27905, Uniform1uivEXT_remap_index }, + { 22218, Uniform2uiEXT_remap_index }, + { 4296, Uniform2uivEXT_remap_index }, + { 29224, Uniform3uiEXT_remap_index }, + { 14690, Uniform3uivEXT_remap_index }, + { 3525, Uniform4uiEXT_remap_index }, + { 8645, Uniform4uivEXT_remap_index }, + { 18389, VertexAttribI1iEXT_remap_index }, + { 1004, VertexAttribI1ivEXT_remap_index }, + { 2555, VertexAttribI1uiEXT_remap_index }, + { 12801, VertexAttribI1uivEXT_remap_index }, { 81, VertexAttribI2iEXT_remap_index }, - { 23706, VertexAttribI2ivEXT_remap_index }, - { 5273, VertexAttribI2uiEXT_remap_index }, - { 4728, VertexAttribI2uivEXT_remap_index }, - { 26361, VertexAttribI3iEXT_remap_index }, - { 30218, VertexAttribI3ivEXT_remap_index }, - { 3340, VertexAttribI3uiEXT_remap_index }, - { 30114, VertexAttribI3uivEXT_remap_index }, - { 21848, VertexAttribI4bvEXT_remap_index }, - { 14584, VertexAttribI4iEXT_remap_index }, - { 31783, VertexAttribI4ivEXT_remap_index }, - { 13358, VertexAttribI4svEXT_remap_index }, - { 16462, VertexAttribI4ubvEXT_remap_index }, - { 16145, VertexAttribI4uiEXT_remap_index }, - { 5419, VertexAttribI4uivEXT_remap_index }, - { 11311, VertexAttribI4usvEXT_remap_index }, - { 18403, VertexAttribIPointerEXT_remap_index }, - { 3027, FramebufferTextureLayerEXT_remap_index }, - { 5660, ColorMaskIndexedEXT_remap_index }, - { 18820, DisableIndexedEXT_remap_index }, - { 26406, EnableIndexedEXT_remap_index }, - { 21552, GetBooleanIndexedvEXT_remap_index }, - { 10922, GetIntegerIndexedvEXT_remap_index }, - { 22596, IsEnabledIndexedEXT_remap_index }, - { 22496, ClearColorIiEXT_remap_index }, - { 3436, ClearColorIuiEXT_remap_index }, - { 9852, GetTexParameterIivEXT_remap_index }, - { 5908, GetTexParameterIuivEXT_remap_index }, - { 2983, TexParameterIivEXT_remap_index }, - { 26228, TexParameterIuivEXT_remap_index }, - { 4596, BeginConditionalRenderNV_remap_index }, - { 25249, EndConditionalRenderNV_remap_index }, - { 9310, BeginTransformFeedbackEXT_remap_index }, - { 18855, BindBufferBaseEXT_remap_index }, - { 18714, BindBufferOffsetEXT_remap_index }, - { 12202, BindBufferRangeEXT_remap_index }, - { 14239, EndTransformFeedbackEXT_remap_index }, - { 10774, GetTransformFeedbackVaryingEXT_remap_index }, - { 20658, TransformFeedbackVaryingsEXT_remap_index }, - { 29270, ProvokingVertexEXT_remap_index }, - { 10722, GetTexParameterPointervAPPLE_remap_index }, - { 5047, TextureRangeAPPLE_remap_index }, - { 11600, GetObjectParameterivAPPLE_remap_index }, - { 19780, ObjectPurgeableAPPLE_remap_index }, - { 5702, ObjectUnpurgeableAPPLE_remap_index }, - { 17225, ActiveProgramEXT_remap_index }, - { 17196, CreateShaderProgramEXT_remap_index }, - { 28288, UseShaderProgramEXT_remap_index }, - { 28529, StencilFuncSeparateATI_remap_index }, - { 18044, ProgramEnvParameters4fvEXT_remap_index }, - { 17090, ProgramLocalParameters4fvEXT_remap_index }, - { 14107, GetQueryObjecti64vEXT_remap_index }, - { 10324, GetQueryObjectui64vEXT_remap_index }, - { 23663, EGLImageTargetRenderbufferStorageOES_remap_index }, - { 12120, EGLImageTargetTexture2DOES_remap_index }, + { 23835, VertexAttribI2ivEXT_remap_index }, + { 5302, VertexAttribI2uiEXT_remap_index }, + { 4715, VertexAttribI2uivEXT_remap_index }, + { 26523, VertexAttribI3iEXT_remap_index }, + { 30499, VertexAttribI3ivEXT_remap_index }, + { 3379, VertexAttribI3uiEXT_remap_index }, + { 30395, VertexAttribI3uivEXT_remap_index }, + { 21948, VertexAttribI4bvEXT_remap_index }, + { 14622, VertexAttribI4iEXT_remap_index }, + { 32025, VertexAttribI4ivEXT_remap_index }, + { 13434, VertexAttribI4svEXT_remap_index }, + { 16484, VertexAttribI4ubvEXT_remap_index }, + { 16183, VertexAttribI4uiEXT_remap_index }, + { 5448, VertexAttribI4uivEXT_remap_index }, + { 11317, VertexAttribI4usvEXT_remap_index }, + { 18486, VertexAttribIPointerEXT_remap_index }, + { 3066, FramebufferTextureLayerEXT_remap_index }, + { 5172, ColorMaskIndexedEXT_remap_index }, + { 18903, DisableIndexedEXT_remap_index }, + { 26568, EnableIndexedEXT_remap_index }, + { 21652, GetBooleanIndexedvEXT_remap_index }, + { 10928, GetIntegerIndexedvEXT_remap_index }, + { 22696, IsEnabledIndexedEXT_remap_index }, + { 22596, ClearColorIiEXT_remap_index }, + { 3475, ClearColorIuiEXT_remap_index }, + { 9843, GetTexParameterIivEXT_remap_index }, + { 5895, GetTexParameterIuivEXT_remap_index }, + { 3022, TexParameterIivEXT_remap_index }, + { 26390, TexParameterIuivEXT_remap_index }, + { 4583, BeginConditionalRenderNV_remap_index }, + { 25378, EndConditionalRenderNV_remap_index }, + { 9280, BeginTransformFeedbackEXT_remap_index }, + { 18938, BindBufferBaseEXT_remap_index }, + { 18797, BindBufferOffsetEXT_remap_index }, + { 12247, BindBufferRangeEXT_remap_index }, + { 14244, EndTransformFeedbackEXT_remap_index }, + { 10791, GetTransformFeedbackVaryingEXT_remap_index }, + { 20741, TransformFeedbackVaryingsEXT_remap_index }, + { 29551, ProvokingVertexEXT_remap_index }, + { 10739, GetTexParameterPointervAPPLE_remap_index }, + { 5034, TextureRangeAPPLE_remap_index }, + { 11606, GetObjectParameterivAPPLE_remap_index }, + { 19863, ObjectPurgeableAPPLE_remap_index }, + { 5689, ObjectUnpurgeableAPPLE_remap_index }, + { 17247, ActiveProgramEXT_remap_index }, + { 17218, CreateShaderProgramEXT_remap_index }, + { 28569, UseShaderProgramEXT_remap_index }, + { 16463, TextureBarrierNV_remap_index }, + { 28810, StencilFuncSeparateATI_remap_index }, + { 18090, ProgramEnvParameters4fvEXT_remap_index }, + { 17112, ProgramLocalParameters4fvEXT_remap_index }, + { 14112, GetQueryObjecti64vEXT_remap_index }, + { 10341, GetQueryObjectui64vEXT_remap_index }, + { 23792, EGLImageTargetRenderbufferStorageOES_remap_index }, + { 12126, EGLImageTargetTexture2DOES_remap_index }, { -1, -1 } }; /* these functions are in the ABI, but have alternative names */ static const struct gl_function_remap MESA_alt_functions[] = { /* from GL_EXT_blend_color */ - { 2655, _gloffset_BlendColor }, + { 2694, _gloffset_BlendColor }, /* from GL_EXT_blend_minmax */ - { 11205, _gloffset_BlendEquation }, + { 11211, _gloffset_BlendEquation }, /* from GL_EXT_color_subtable */ - { 16988, _gloffset_ColorSubTable }, - { 31446, _gloffset_CopyColorSubTable }, + { 17010, _gloffset_ColorSubTable }, + { 31688, _gloffset_CopyColorSubTable }, /* from GL_EXT_convolution */ - { 257, _gloffset_ConvolutionFilter1D }, - { 2454, _gloffset_CopyConvolutionFilter1D }, - { 4058, _gloffset_GetConvolutionParameteriv }, - { 8523, _gloffset_ConvolutionFilter2D }, - { 8725, _gloffset_ConvolutionParameteriv }, - { 9185, _gloffset_ConvolutionParameterfv }, - { 20501, _gloffset_GetSeparableFilter }, - { 23938, _gloffset_SeparableFilter2D }, - { 24801, _gloffset_ConvolutionParameteri }, - { 24924, _gloffset_ConvolutionParameterf }, - { 26595, _gloffset_GetConvolutionParameterfv }, - { 27417, _gloffset_GetConvolutionFilter }, - { 29810, _gloffset_CopyConvolutionFilter2D }, + { 296, _gloffset_ConvolutionFilter1D }, + { 2493, _gloffset_CopyConvolutionFilter1D }, + { 4097, _gloffset_GetConvolutionParameteriv }, + { 8493, _gloffset_ConvolutionFilter2D }, + { 8695, _gloffset_ConvolutionParameteriv }, + { 9155, _gloffset_ConvolutionParameterfv }, + { 20584, _gloffset_GetSeparableFilter }, + { 24067, _gloffset_SeparableFilter2D }, + { 24930, _gloffset_ConvolutionParameteri }, + { 25053, _gloffset_ConvolutionParameterf }, + { 26757, _gloffset_GetConvolutionParameterfv }, + { 27646, _gloffset_GetConvolutionFilter }, + { 30091, _gloffset_CopyConvolutionFilter2D }, /* from GL_EXT_copy_texture */ - { 15065, _gloffset_CopyTexSubImage3D }, - { 16675, _gloffset_CopyTexImage2D }, - { 24409, _gloffset_CopyTexImage1D }, - { 27098, _gloffset_CopyTexSubImage2D }, - { 29448, _gloffset_CopyTexSubImage1D }, + { 15103, _gloffset_CopyTexSubImage3D }, + { 16697, _gloffset_CopyTexImage2D }, + { 24538, _gloffset_CopyTexImage1D }, + { 27327, _gloffset_CopyTexSubImage2D }, + { 29729, _gloffset_CopyTexSubImage1D }, /* from GL_EXT_draw_range_elements */ - { 9522, _gloffset_DrawRangeElements }, + { 9492, _gloffset_DrawRangeElements }, /* from GL_EXT_histogram */ - { 856, _gloffset_Histogram }, - { 3522, _gloffset_ResetHistogram }, - { 9972, _gloffset_GetMinmax }, - { 15399, _gloffset_GetHistogramParameterfv }, - { 24334, _gloffset_GetMinmaxParameteriv }, - { 26485, _gloffset_ResetMinmax }, - { 27314, _gloffset_GetHistogramParameteriv }, - { 28463, _gloffset_GetHistogram }, - { 31032, _gloffset_Minmax }, - { 32578, _gloffset_GetMinmaxParameterfv }, + { 895, _gloffset_Histogram }, + { 3561, _gloffset_ResetHistogram }, + { 9989, _gloffset_GetMinmax }, + { 15437, _gloffset_GetHistogramParameterfv }, + { 24463, _gloffset_GetMinmaxParameteriv }, + { 26647, _gloffset_ResetMinmax }, + { 27543, _gloffset_GetHistogramParameteriv }, + { 28744, _gloffset_GetHistogram }, + { 31313, _gloffset_Minmax }, + { 32853, _gloffset_GetMinmaxParameterfv }, /* from GL_EXT_paletted_texture */ - { 8385, _gloffset_ColorTable }, - { 15245, _gloffset_GetColorTable }, - { 22882, _gloffset_GetColorTableParameterfv }, - { 24980, _gloffset_GetColorTableParameteriv }, + { 8355, _gloffset_ColorTable }, + { 15283, _gloffset_GetColorTable }, + { 22982, _gloffset_GetColorTableParameterfv }, + { 25109, _gloffset_GetColorTableParameteriv }, /* from GL_EXT_subtexture */ - { 7106, _gloffset_TexSubImage1D }, - { 10649, _gloffset_TexSubImage2D }, + { 7076, _gloffset_TexSubImage1D }, + { 10666, _gloffset_TexSubImage2D }, /* from GL_EXT_texture3D */ - { 1774, _gloffset_TexImage3D }, - { 22651, _gloffset_TexSubImage3D }, + { 1813, _gloffset_TexImage3D }, + { 22751, _gloffset_TexSubImage3D }, /* from GL_EXT_texture_object */ - { 3290, _gloffset_PrioritizeTextures }, - { 7555, _gloffset_AreTexturesResident }, - { 13562, _gloffset_GenTextures }, - { 15731, _gloffset_DeleteTextures }, - { 19486, _gloffset_IsTexture }, - { 29513, _gloffset_BindTexture }, + { 3329, _gloffset_PrioritizeTextures }, + { 7525, _gloffset_AreTexturesResident }, + { 13638, _gloffset_GenTextures }, + { 15769, _gloffset_DeleteTextures }, + { 19569, _gloffset_IsTexture }, + { 29794, _gloffset_BindTexture }, /* from GL_EXT_vertex_array */ - { 24110, _gloffset_ArrayElement }, - { 30620, _gloffset_GetPointerv }, - { 32205, _gloffset_DrawArrays }, + { 24239, _gloffset_ArrayElement }, + { 30901, _gloffset_GetPointerv }, + { 32480, _gloffset_DrawArrays }, /* from GL_SGI_color_table */ - { 7673, _gloffset_ColorTableParameteriv }, - { 8385, _gloffset_ColorTable }, - { 15245, _gloffset_GetColorTable }, - { 15355, _gloffset_CopyColorTable }, - { 19347, _gloffset_ColorTableParameterfv }, - { 22882, _gloffset_GetColorTableParameterfv }, - { 24980, _gloffset_GetColorTableParameteriv }, + { 7643, _gloffset_ColorTableParameteriv }, + { 8355, _gloffset_ColorTable }, + { 15283, _gloffset_GetColorTable }, + { 15393, _gloffset_CopyColorTable }, + { 19430, _gloffset_ColorTableParameterfv }, + { 22982, _gloffset_GetColorTableParameterfv }, + { 25109, _gloffset_GetColorTableParameteriv }, /* from GL_VERSION_1_3 */ - { 425, _gloffset_MultiTexCoord3sARB }, - { 657, _gloffset_ActiveTextureARB }, - { 4247, _gloffset_MultiTexCoord1fvARB }, - { 6155, _gloffset_MultiTexCoord3dARB }, - { 6200, _gloffset_MultiTexCoord2iARB }, - { 6324, _gloffset_MultiTexCoord2svARB }, - { 8341, _gloffset_MultiTexCoord2fARB }, - { 10354, _gloffset_MultiTexCoord3fvARB }, - { 10967, _gloffset_MultiTexCoord4sARB }, - { 11648, _gloffset_MultiTexCoord2dvARB }, - { 12063, _gloffset_MultiTexCoord1svARB }, - { 12435, _gloffset_MultiTexCoord3svARB }, - { 12496, _gloffset_MultiTexCoord4iARB }, - { 13266, _gloffset_MultiTexCoord3iARB }, - { 14136, _gloffset_MultiTexCoord1dARB }, - { 14353, _gloffset_MultiTexCoord3dvARB }, - { 15599, _gloffset_MultiTexCoord3ivARB }, - { 15644, _gloffset_MultiTexCoord2sARB }, - { 17045, _gloffset_MultiTexCoord4ivARB }, - { 18997, _gloffset_ClientActiveTextureARB }, - { 21297, _gloffset_MultiTexCoord2dARB }, - { 21717, _gloffset_MultiTexCoord4dvARB }, - { 22073, _gloffset_MultiTexCoord4fvARB }, - { 23023, _gloffset_MultiTexCoord3fARB }, - { 25531, _gloffset_MultiTexCoord4dARB }, - { 25797, _gloffset_MultiTexCoord1sARB }, - { 26001, _gloffset_MultiTexCoord1dvARB }, - { 26942, _gloffset_MultiTexCoord1ivARB }, - { 27035, _gloffset_MultiTexCoord2ivARB }, - { 27374, _gloffset_MultiTexCoord1iARB }, - { 28738, _gloffset_MultiTexCoord4svARB }, - { 29312, _gloffset_MultiTexCoord1fARB }, - { 29575, _gloffset_MultiTexCoord4fARB }, - { 32039, _gloffset_MultiTexCoord2fvARB }, + { 464, _gloffset_MultiTexCoord3sARB }, + { 696, _gloffset_ActiveTextureARB }, + { 4234, _gloffset_MultiTexCoord1fvARB }, + { 6142, _gloffset_MultiTexCoord3dARB }, + { 6187, _gloffset_MultiTexCoord2iARB }, + { 6311, _gloffset_MultiTexCoord2svARB }, + { 8311, _gloffset_MultiTexCoord2fARB }, + { 10371, _gloffset_MultiTexCoord3fvARB }, + { 10973, _gloffset_MultiTexCoord4sARB }, + { 11654, _gloffset_MultiTexCoord2dvARB }, + { 12069, _gloffset_MultiTexCoord1svARB }, + { 12480, _gloffset_MultiTexCoord3svARB }, + { 12541, _gloffset_MultiTexCoord4iARB }, + { 13342, _gloffset_MultiTexCoord3iARB }, + { 14141, _gloffset_MultiTexCoord1dARB }, + { 14358, _gloffset_MultiTexCoord3dvARB }, + { 15637, _gloffset_MultiTexCoord3ivARB }, + { 15682, _gloffset_MultiTexCoord2sARB }, + { 17067, _gloffset_MultiTexCoord4ivARB }, + { 19080, _gloffset_ClientActiveTextureARB }, + { 21380, _gloffset_MultiTexCoord2dARB }, + { 21817, _gloffset_MultiTexCoord4dvARB }, + { 22173, _gloffset_MultiTexCoord4fvARB }, + { 23123, _gloffset_MultiTexCoord3fARB }, + { 25693, _gloffset_MultiTexCoord4dARB }, + { 25959, _gloffset_MultiTexCoord1sARB }, + { 26163, _gloffset_MultiTexCoord1dvARB }, + { 27171, _gloffset_MultiTexCoord1ivARB }, + { 27264, _gloffset_MultiTexCoord2ivARB }, + { 27603, _gloffset_MultiTexCoord1iARB }, + { 29019, _gloffset_MultiTexCoord4svARB }, + { 29593, _gloffset_MultiTexCoord1fARB }, + { 29856, _gloffset_MultiTexCoord4fARB }, + { 32314, _gloffset_MultiTexCoord2fvARB }, { -1, -1 } }; @@ -5329,7 +5384,7 @@ static const struct gl_function_remap MESA_alt_functions[] = { #if defined(need_GL_3DFX_tbuffer) static const struct gl_function_remap GL_3DFX_tbuffer_functions[] = { - { 9243, -1 }, /* TbufferMask3DFX */ + { 9213, -1 }, /* TbufferMask3DFX */ { -1, -1 } }; #endif @@ -5362,6 +5417,13 @@ static const struct gl_function_remap GL_APPLE_vertex_array_object_functions[] = }; #endif +#if defined(need_GL_ARB_ES2_compatibility) +/* functions defined in MESA_remap_table_functions are excluded */ +static const struct gl_function_remap GL_ARB_ES2_compatibility_functions[] = { + { -1, -1 } +}; +#endif + #if defined(need_GL_ARB_copy_buffer) /* functions defined in MESA_remap_table_functions are excluded */ static const struct gl_function_remap GL_ARB_copy_buffer_functions[] = { @@ -5376,6 +5438,13 @@ static const struct gl_function_remap GL_ARB_draw_buffers_functions[] = { }; #endif +#if defined(need_GL_ARB_draw_buffers_blend) +/* functions defined in MESA_remap_table_functions are excluded */ +static const struct gl_function_remap GL_ARB_draw_buffers_blend_functions[] = { + { -1, -1 } +}; +#endif + #if defined(need_GL_ARB_draw_elements_base_vertex) /* functions defined in MESA_remap_table_functions are excluded */ static const struct gl_function_remap GL_ARB_draw_elements_base_vertex_functions[] = { @@ -5400,7 +5469,14 @@ static const struct gl_function_remap GL_ARB_framebuffer_object_functions[] = { #if defined(need_GL_ARB_geometry_shader4) /* functions defined in MESA_remap_table_functions are excluded */ static const struct gl_function_remap GL_ARB_geometry_shader4_functions[] = { - { 12399, -1 }, /* FramebufferTextureLayer */ + { 12444, -1 }, /* FramebufferTextureLayer */ + { -1, -1 } +}; +#endif + +#if defined(need_GL_ARB_instanced_arrays) +/* functions defined in MESA_remap_table_functions are excluded */ +static const struct gl_function_remap GL_ARB_instanced_arrays_functions[] = { { -1, -1 } }; #endif @@ -5414,11 +5490,11 @@ static const struct gl_function_remap GL_ARB_map_buffer_range_functions[] = { #if defined(need_GL_ARB_matrix_palette) static const struct gl_function_remap GL_ARB_matrix_palette_functions[] = { - { 3773, -1 }, /* MatrixIndexusvARB */ - { 13087, -1 }, /* MatrixIndexuivARB */ - { 14475, -1 }, /* MatrixIndexPointerARB */ - { 19735, -1 }, /* CurrentPaletteMatrixARB */ - { 22767, -1 }, /* MatrixIndexubvARB */ + { 3812, -1 }, /* MatrixIndexusvARB */ + { 13163, -1 }, /* MatrixIndexuivARB */ + { 14513, -1 }, /* MatrixIndexPointerARB */ + { 19818, -1 }, /* CurrentPaletteMatrixARB */ + { 22867, -1 }, /* MatrixIndexubvARB */ { -1, -1 } }; #endif @@ -5495,16 +5571,16 @@ static const struct gl_function_remap GL_ARB_vertex_array_object_functions[] = { #if defined(need_GL_ARB_vertex_blend) static const struct gl_function_remap GL_ARB_vertex_blend_functions[] = { - { 2396, -1 }, /* WeightubvARB */ - { 6567, -1 }, /* WeightivARB */ - { 11070, -1 }, /* WeightPointerARB */ - { 13854, -1 }, /* WeightfvARB */ - { 17564, -1 }, /* WeightbvARB */ - { 20965, -1 }, /* WeightusvARB */ - { 23864, -1 }, /* VertexBlendARB */ - { 29396, -1 }, /* WeightsvARB */ - { 31496, -1 }, /* WeightdvARB */ - { 32239, -1 }, /* WeightuivARB */ + { 2435, -1 }, /* WeightubvARB */ + { 6554, -1 }, /* WeightivARB */ + { 11076, -1 }, /* WeightPointerARB */ + { 13898, -1 }, /* WeightfvARB */ + { 17586, -1 }, /* WeightbvARB */ + { 21048, -1 }, /* WeightusvARB */ + { 23993, -1 }, /* VertexBlendARB */ + { 29677, -1 }, /* WeightsvARB */ + { 31738, -1 }, /* WeightdvARB */ + { 32514, -1 }, /* WeightuivARB */ { -1, -1 } }; #endif @@ -5574,7 +5650,7 @@ static const struct gl_function_remap GL_ATI_separate_stencil_functions[] = { #if defined(need_GL_EXT_blend_color) static const struct gl_function_remap GL_EXT_blend_color_functions[] = { - { 2655, _gloffset_BlendColor }, + { 2694, _gloffset_BlendColor }, { -1, -1 } }; #endif @@ -5595,15 +5671,15 @@ static const struct gl_function_remap GL_EXT_blend_func_separate_functions[] = { #if defined(need_GL_EXT_blend_minmax) static const struct gl_function_remap GL_EXT_blend_minmax_functions[] = { - { 11205, _gloffset_BlendEquation }, + { 11211, _gloffset_BlendEquation }, { -1, -1 } }; #endif #if defined(need_GL_EXT_color_subtable) static const struct gl_function_remap GL_EXT_color_subtable_functions[] = { - { 16988, _gloffset_ColorSubTable }, - { 31446, _gloffset_CopyColorSubTable }, + { 17010, _gloffset_ColorSubTable }, + { 31688, _gloffset_CopyColorSubTable }, { -1, -1 } }; #endif @@ -5617,66 +5693,66 @@ static const struct gl_function_remap GL_EXT_compiled_vertex_array_functions[] = #if defined(need_GL_EXT_convolution) static const struct gl_function_remap GL_EXT_convolution_functions[] = { - { 257, _gloffset_ConvolutionFilter1D }, - { 2454, _gloffset_CopyConvolutionFilter1D }, - { 4058, _gloffset_GetConvolutionParameteriv }, - { 8523, _gloffset_ConvolutionFilter2D }, - { 8725, _gloffset_ConvolutionParameteriv }, - { 9185, _gloffset_ConvolutionParameterfv }, - { 20501, _gloffset_GetSeparableFilter }, - { 23938, _gloffset_SeparableFilter2D }, - { 24801, _gloffset_ConvolutionParameteri }, - { 24924, _gloffset_ConvolutionParameterf }, - { 26595, _gloffset_GetConvolutionParameterfv }, - { 27417, _gloffset_GetConvolutionFilter }, - { 29810, _gloffset_CopyConvolutionFilter2D }, + { 296, _gloffset_ConvolutionFilter1D }, + { 2493, _gloffset_CopyConvolutionFilter1D }, + { 4097, _gloffset_GetConvolutionParameteriv }, + { 8493, _gloffset_ConvolutionFilter2D }, + { 8695, _gloffset_ConvolutionParameteriv }, + { 9155, _gloffset_ConvolutionParameterfv }, + { 20584, _gloffset_GetSeparableFilter }, + { 24067, _gloffset_SeparableFilter2D }, + { 24930, _gloffset_ConvolutionParameteri }, + { 25053, _gloffset_ConvolutionParameterf }, + { 26757, _gloffset_GetConvolutionParameterfv }, + { 27646, _gloffset_GetConvolutionFilter }, + { 30091, _gloffset_CopyConvolutionFilter2D }, { -1, -1 } }; #endif #if defined(need_GL_EXT_coordinate_frame) static const struct gl_function_remap GL_EXT_coordinate_frame_functions[] = { - { 10493, -1 }, /* TangentPointerEXT */ - { 12554, -1 }, /* Binormal3ivEXT */ - { 13219, -1 }, /* Tangent3sEXT */ - { 14540, -1 }, /* Tangent3fvEXT */ - { 18695, -1 }, /* Tangent3dvEXT */ - { 19433, -1 }, /* Binormal3bvEXT */ - { 20554, -1 }, /* Binormal3dEXT */ - { 22699, -1 }, /* Tangent3fEXT */ - { 24873, -1 }, /* Binormal3sEXT */ - { 25341, -1 }, /* Tangent3ivEXT */ - { 25360, -1 }, /* Tangent3dEXT */ - { 26274, -1 }, /* Binormal3svEXT */ - { 26840, -1 }, /* Binormal3fEXT */ - { 27728, -1 }, /* Binormal3dvEXT */ - { 28995, -1 }, /* Tangent3iEXT */ - { 30095, -1 }, /* Tangent3bvEXT */ - { 30655, -1 }, /* Tangent3bEXT */ - { 31219, -1 }, /* Binormal3fvEXT */ - { 31938, -1 }, /* BinormalPointerEXT */ - { 32343, -1 }, /* Tangent3svEXT */ - { 32780, -1 }, /* Binormal3bEXT */ - { 32957, -1 }, /* Binormal3iEXT */ + { 10510, -1 }, /* TangentPointerEXT */ + { 12599, -1 }, /* Binormal3ivEXT */ + { 13295, -1 }, /* Tangent3sEXT */ + { 14578, -1 }, /* Tangent3fvEXT */ + { 18778, -1 }, /* Tangent3dvEXT */ + { 19516, -1 }, /* Binormal3bvEXT */ + { 20637, -1 }, /* Binormal3dEXT */ + { 22799, -1 }, /* Tangent3fEXT */ + { 25002, -1 }, /* Binormal3sEXT */ + { 25470, -1 }, /* Tangent3ivEXT */ + { 25489, -1 }, /* Tangent3dEXT */ + { 26436, -1 }, /* Binormal3svEXT */ + { 27069, -1 }, /* Binormal3fEXT */ + { 27957, -1 }, /* Binormal3dvEXT */ + { 29276, -1 }, /* Tangent3iEXT */ + { 30376, -1 }, /* Tangent3bvEXT */ + { 30936, -1 }, /* Tangent3bEXT */ + { 31461, -1 }, /* Binormal3fvEXT */ + { 32213, -1 }, /* BinormalPointerEXT */ + { 32618, -1 }, /* Tangent3svEXT */ + { 33055, -1 }, /* Binormal3bEXT */ + { 33232, -1 }, /* Binormal3iEXT */ { -1, -1 } }; #endif #if defined(need_GL_EXT_copy_texture) static const struct gl_function_remap GL_EXT_copy_texture_functions[] = { - { 15065, _gloffset_CopyTexSubImage3D }, - { 16675, _gloffset_CopyTexImage2D }, - { 24409, _gloffset_CopyTexImage1D }, - { 27098, _gloffset_CopyTexSubImage2D }, - { 29448, _gloffset_CopyTexSubImage1D }, + { 15103, _gloffset_CopyTexSubImage3D }, + { 16697, _gloffset_CopyTexImage2D }, + { 24538, _gloffset_CopyTexImage1D }, + { 27327, _gloffset_CopyTexSubImage2D }, + { 29729, _gloffset_CopyTexSubImage1D }, { -1, -1 } }; #endif #if defined(need_GL_EXT_cull_vertex) static const struct gl_function_remap GL_EXT_cull_vertex_functions[] = { - { 8874, -1 }, /* CullParameterdvEXT */ - { 11693, -1 }, /* CullParameterfvEXT */ + { 8844, -1 }, /* CullParameterdvEXT */ + { 11699, -1 }, /* CullParameterfvEXT */ { -1, -1 } }; #endif @@ -5704,7 +5780,7 @@ static const struct gl_function_remap GL_EXT_draw_instanced_functions[] = { #if defined(need_GL_EXT_draw_range_elements) static const struct gl_function_remap GL_EXT_draw_range_elements_functions[] = { - { 9522, _gloffset_DrawRangeElements }, + { 9492, _gloffset_DrawRangeElements }, { -1, -1 } }; #endif @@ -5753,39 +5829,39 @@ static const struct gl_function_remap GL_EXT_gpu_shader4_functions[] = { #if defined(need_GL_EXT_histogram) static const struct gl_function_remap GL_EXT_histogram_functions[] = { - { 856, _gloffset_Histogram }, - { 3522, _gloffset_ResetHistogram }, - { 9972, _gloffset_GetMinmax }, - { 15399, _gloffset_GetHistogramParameterfv }, - { 24334, _gloffset_GetMinmaxParameteriv }, - { 26485, _gloffset_ResetMinmax }, - { 27314, _gloffset_GetHistogramParameteriv }, - { 28463, _gloffset_GetHistogram }, - { 31032, _gloffset_Minmax }, - { 32578, _gloffset_GetMinmaxParameterfv }, + { 895, _gloffset_Histogram }, + { 3561, _gloffset_ResetHistogram }, + { 9989, _gloffset_GetMinmax }, + { 15437, _gloffset_GetHistogramParameterfv }, + { 24463, _gloffset_GetMinmaxParameteriv }, + { 26647, _gloffset_ResetMinmax }, + { 27543, _gloffset_GetHistogramParameteriv }, + { 28744, _gloffset_GetHistogram }, + { 31313, _gloffset_Minmax }, + { 32853, _gloffset_GetMinmaxParameterfv }, { -1, -1 } }; #endif #if defined(need_GL_EXT_index_func) static const struct gl_function_remap GL_EXT_index_func_functions[] = { - { 11479, -1 }, /* IndexFuncEXT */ + { 11485, -1 }, /* IndexFuncEXT */ { -1, -1 } }; #endif #if defined(need_GL_EXT_index_material) static const struct gl_function_remap GL_EXT_index_material_functions[] = { - { 21052, -1 }, /* IndexMaterialEXT */ + { 21135, -1 }, /* IndexMaterialEXT */ { -1, -1 } }; #endif #if defined(need_GL_EXT_light_texture) static const struct gl_function_remap GL_EXT_light_texture_functions[] = { - { 26294, -1 }, /* ApplyTextureEXT */ - { 26439, -1 }, /* TextureMaterialEXT */ - { 26464, -1 }, /* TextureLightEXT */ + { 26456, -1 }, /* ApplyTextureEXT */ + { 26601, -1 }, /* TextureMaterialEXT */ + { 26626, -1 }, /* TextureLightEXT */ { -1, -1 } }; #endif @@ -5806,20 +5882,20 @@ static const struct gl_function_remap GL_EXT_multisample_functions[] = { #if defined(need_GL_EXT_paletted_texture) static const struct gl_function_remap GL_EXT_paletted_texture_functions[] = { - { 8385, _gloffset_ColorTable }, - { 15245, _gloffset_GetColorTable }, - { 22882, _gloffset_GetColorTableParameterfv }, - { 24980, _gloffset_GetColorTableParameteriv }, + { 8355, _gloffset_ColorTable }, + { 15283, _gloffset_GetColorTable }, + { 22982, _gloffset_GetColorTableParameterfv }, + { 25109, _gloffset_GetColorTableParameteriv }, { -1, -1 } }; #endif #if defined(need_GL_EXT_pixel_transform) static const struct gl_function_remap GL_EXT_pixel_transform_functions[] = { - { 21682, -1 }, /* PixelTransformParameterfEXT */ - { 21762, -1 }, /* PixelTransformParameteriEXT */ - { 30370, -1 }, /* PixelTransformParameterfvEXT */ - { 31902, -1 }, /* PixelTransformParameterivEXT */ + { 21782, -1 }, /* PixelTransformParameterfEXT */ + { 21862, -1 }, /* PixelTransformParameteriEXT */ + { 30651, -1 }, /* PixelTransformParameterfvEXT */ + { 32177, -1 }, /* PixelTransformParameterivEXT */ { -1, -1 } }; #endif @@ -5868,16 +5944,16 @@ static const struct gl_function_remap GL_EXT_stencil_two_side_functions[] = { #if defined(need_GL_EXT_subtexture) static const struct gl_function_remap GL_EXT_subtexture_functions[] = { - { 7106, _gloffset_TexSubImage1D }, - { 10649, _gloffset_TexSubImage2D }, + { 7076, _gloffset_TexSubImage1D }, + { 10666, _gloffset_TexSubImage2D }, { -1, -1 } }; #endif #if defined(need_GL_EXT_texture3D) static const struct gl_function_remap GL_EXT_texture3D_functions[] = { - { 1774, _gloffset_TexImage3D }, - { 22651, _gloffset_TexSubImage3D }, + { 1813, _gloffset_TexImage3D }, + { 22751, _gloffset_TexSubImage3D }, { -1, -1 } }; #endif @@ -5898,19 +5974,19 @@ static const struct gl_function_remap GL_EXT_texture_integer_functions[] = { #if defined(need_GL_EXT_texture_object) static const struct gl_function_remap GL_EXT_texture_object_functions[] = { - { 3290, _gloffset_PrioritizeTextures }, - { 7555, _gloffset_AreTexturesResident }, - { 13562, _gloffset_GenTextures }, - { 15731, _gloffset_DeleteTextures }, - { 19486, _gloffset_IsTexture }, - { 29513, _gloffset_BindTexture }, + { 3329, _gloffset_PrioritizeTextures }, + { 7525, _gloffset_AreTexturesResident }, + { 13638, _gloffset_GenTextures }, + { 15769, _gloffset_DeleteTextures }, + { 19569, _gloffset_IsTexture }, + { 29794, _gloffset_BindTexture }, { -1, -1 } }; #endif #if defined(need_GL_EXT_texture_perturb_normal) static const struct gl_function_remap GL_EXT_texture_perturb_normal_functions[] = { - { 13804, -1 }, /* TextureNormalEXT */ + { 13848, -1 }, /* TextureNormalEXT */ { -1, -1 } }; #endif @@ -5932,30 +6008,30 @@ static const struct gl_function_remap GL_EXT_transform_feedback_functions[] = { #if defined(need_GL_EXT_vertex_array) /* functions defined in MESA_remap_table_functions are excluded */ static const struct gl_function_remap GL_EXT_vertex_array_functions[] = { - { 24110, _gloffset_ArrayElement }, - { 30620, _gloffset_GetPointerv }, - { 32205, _gloffset_DrawArrays }, + { 24239, _gloffset_ArrayElement }, + { 30901, _gloffset_GetPointerv }, + { 32480, _gloffset_DrawArrays }, { -1, -1 } }; #endif #if defined(need_GL_EXT_vertex_weighting) static const struct gl_function_remap GL_EXT_vertex_weighting_functions[] = { - { 19516, -1 }, /* VertexWeightfvEXT */ - { 26818, -1 }, /* VertexWeightfEXT */ - { 28432, -1 }, /* VertexWeightPointerEXT */ + { 19599, -1 }, /* VertexWeightfvEXT */ + { 27012, -1 }, /* VertexWeightfEXT */ + { 28713, -1 }, /* VertexWeightPointerEXT */ { -1, -1 } }; #endif #if defined(need_GL_HP_image_transform) static const struct gl_function_remap GL_HP_image_transform_functions[] = { - { 2327, -1 }, /* GetImageTransformParameterfvHP */ - { 3739, -1 }, /* ImageTransformParameterfHP */ - { 10187, -1 }, /* ImageTransformParameterfvHP */ - { 11948, -1 }, /* ImageTransformParameteriHP */ - { 12289, -1 }, /* GetImageTransformParameterivHP */ - { 19580, -1 }, /* ImageTransformParameterivHP */ + { 2366, -1 }, /* GetImageTransformParameterfvHP */ + { 3778, -1 }, /* ImageTransformParameterfHP */ + { 10204, -1 }, /* ImageTransformParameterfvHP */ + { 11954, -1 }, /* ImageTransformParameteriHP */ + { 12334, -1 }, /* GetImageTransformParameterivHP */ + { 19663, -1 }, /* ImageTransformParameterivHP */ { -1, -1 } }; #endif @@ -5969,14 +6045,14 @@ static const struct gl_function_remap GL_IBM_multimode_draw_arrays_functions[] = #if defined(need_GL_IBM_vertex_array_lists) static const struct gl_function_remap GL_IBM_vertex_array_lists_functions[] = { - { 4379, -1 }, /* SecondaryColorPointerListIBM */ - { 6021, -1 }, /* NormalPointerListIBM */ - { 7729, -1 }, /* FogCoordPointerListIBM */ - { 8036, -1 }, /* VertexPointerListIBM */ - { 11869, -1 }, /* ColorPointerListIBM */ - { 13326, -1 }, /* TexCoordPointerListIBM */ - { 13826, -1 }, /* IndexPointerListIBM */ - { 32521, -1 }, /* EdgeFlagPointerListIBM */ + { 4366, -1 }, /* SecondaryColorPointerListIBM */ + { 6008, -1 }, /* NormalPointerListIBM */ + { 7699, -1 }, /* FogCoordPointerListIBM */ + { 8006, -1 }, /* VertexPointerListIBM */ + { 11875, -1 }, /* ColorPointerListIBM */ + { 13402, -1 }, /* TexCoordPointerListIBM */ + { 13870, -1 }, /* IndexPointerListIBM */ + { 32796, -1 }, /* EdgeFlagPointerListIBM */ { -1, -1 } }; #endif @@ -5990,10 +6066,10 @@ static const struct gl_function_remap GL_INGR_blend_func_separate_functions[] = #if defined(need_GL_INTEL_parallel_arrays) static const struct gl_function_remap GL_INTEL_parallel_arrays_functions[] = { - { 12666, -1 }, /* VertexPointervINTEL */ - { 15492, -1 }, /* ColorPointervINTEL */ - { 29784, -1 }, /* NormalPointervINTEL */ - { 30302, -1 }, /* TexCoordPointervINTEL */ + { 12742, -1 }, /* VertexPointervINTEL */ + { 15530, -1 }, /* ColorPointervINTEL */ + { 30065, -1 }, /* NormalPointervINTEL */ + { 30583, -1 }, /* TexCoordPointervINTEL */ { -1, -1 } }; #endif @@ -6007,10 +6083,10 @@ static const struct gl_function_remap GL_MESA_resize_buffers_functions[] = { #if defined(need_GL_MESA_shader_debug) static const struct gl_function_remap GL_MESA_shader_debug_functions[] = { - { 1638, -1 }, /* GetDebugLogLengthMESA */ - { 3461, -1 }, /* ClearDebugLogMESA */ - { 4540, -1 }, /* GetDebugLogMESA */ - { 30813, -1 }, /* CreateDebugObjectMESA */ + { 1677, -1 }, /* GetDebugLogLengthMESA */ + { 3500, -1 }, /* ClearDebugLogMESA */ + { 4527, -1 }, /* GetDebugLogMESA */ + { 31094, -1 }, /* CreateDebugObjectMESA */ { -1, -1 } }; #endif @@ -6031,15 +6107,15 @@ static const struct gl_function_remap GL_NV_condtitional_render_functions[] = { #if defined(need_GL_NV_evaluators) static const struct gl_function_remap GL_NV_evaluators_functions[] = { - { 6768, -1 }, /* GetMapAttribParameterivNV */ - { 8491, -1 }, /* MapControlPointsNV */ - { 8590, -1 }, /* MapParameterfvNV */ - { 10632, -1 }, /* EvalMapsNV */ - { 17162, -1 }, /* GetMapAttribParameterfvNV */ - { 17379, -1 }, /* MapParameterivNV */ - { 24724, -1 }, /* GetMapParameterivNV */ - { 25222, -1 }, /* GetMapParameterfvNV */ - { 29099, -1 }, /* GetMapControlPointsNV */ + { 6738, -1 }, /* GetMapAttribParameterivNV */ + { 8461, -1 }, /* MapControlPointsNV */ + { 8560, -1 }, /* MapParameterfvNV */ + { 10649, -1 }, /* EvalMapsNV */ + { 17184, -1 }, /* GetMapAttribParameterfvNV */ + { 17401, -1 }, /* MapParameterivNV */ + { 24853, -1 }, /* GetMapParameterivNV */ + { 25351, -1 }, /* GetMapParameterfvNV */ + { 29380, -1 }, /* GetMapControlPointsNV */ { -1, -1 } }; #endif @@ -6081,8 +6157,15 @@ static const struct gl_function_remap GL_NV_register_combiners_functions[] = { #if defined(need_GL_NV_register_combiners2) static const struct gl_function_remap GL_NV_register_combiners2_functions[] = { - { 15884, -1 }, /* CombinerStageParameterfvNV */ - { 16280, -1 }, /* GetCombinerStageParameterfvNV */ + { 15922, -1 }, /* CombinerStageParameterfvNV */ + { 16318, -1 }, /* GetCombinerStageParameterfvNV */ + { -1, -1 } +}; +#endif + +#if defined(need_GL_NV_texture_barrier) +/* functions defined in MESA_remap_table_functions are excluded */ +static const struct gl_function_remap GL_NV_texture_barrier_functions[] = { { -1, -1 } }; #endif @@ -6110,23 +6193,23 @@ static const struct gl_function_remap GL_OES_EGL_image_functions[] = { #if defined(need_GL_PGI_misc_hints) static const struct gl_function_remap GL_PGI_misc_hints_functions[] = { - { 8711, -1 }, /* HintPGI */ + { 8681, -1 }, /* HintPGI */ { -1, -1 } }; #endif #if defined(need_GL_SGIS_detail_texture) static const struct gl_function_remap GL_SGIS_detail_texture_functions[] = { - { 16253, -1 }, /* GetDetailTexFuncSGIS */ - { 16620, -1 }, /* DetailTexFuncSGIS */ + { 16291, -1 }, /* GetDetailTexFuncSGIS */ + { 16642, -1 }, /* DetailTexFuncSGIS */ { -1, -1 } }; #endif #if defined(need_GL_SGIS_fog_function) static const struct gl_function_remap GL_SGIS_fog_function_functions[] = { - { 27080, -1 }, /* FogFuncSGIS */ - { 27781, -1 }, /* GetFogFuncSGIS */ + { 27309, -1 }, /* FogFuncSGIS */ + { 28062, -1 }, /* GetFogFuncSGIS */ { -1, -1 } }; #endif @@ -6154,112 +6237,112 @@ static const struct gl_function_remap GL_SGIS_point_parameters_functions[] = { #if defined(need_GL_SGIS_sharpen_texture) static const struct gl_function_remap GL_SGIS_sharpen_texture_functions[] = { - { 6829, -1 }, /* GetSharpenTexFuncSGIS */ - { 22047, -1 }, /* SharpenTexFuncSGIS */ + { 6799, -1 }, /* GetSharpenTexFuncSGIS */ + { 22147, -1 }, /* SharpenTexFuncSGIS */ { -1, -1 } }; #endif #if defined(need_GL_SGIS_texture4D) static const struct gl_function_remap GL_SGIS_texture4D_functions[] = { - { 1010, -1 }, /* TexImage4DSGIS */ - { 15800, -1 }, /* TexSubImage4DSGIS */ + { 1049, -1 }, /* TexImage4DSGIS */ + { 15838, -1 }, /* TexSubImage4DSGIS */ { -1, -1 } }; #endif #if defined(need_GL_SGIS_texture_color_mask) static const struct gl_function_remap GL_SGIS_texture_color_mask_functions[] = { - { 15198, -1 }, /* TextureColorMaskSGIS */ + { 15236, -1 }, /* TextureColorMaskSGIS */ { -1, -1 } }; #endif #if defined(need_GL_SGIS_texture_filter4) static const struct gl_function_remap GL_SGIS_texture_filter4_functions[] = { - { 7006, -1 }, /* GetTexFilterFuncSGIS */ - { 16399, -1 }, /* TexFilterFuncSGIS */ + { 6976, -1 }, /* GetTexFilterFuncSGIS */ + { 16437, -1 }, /* TexFilterFuncSGIS */ { -1, -1 } }; #endif #if defined(need_GL_SGIX_async) static const struct gl_function_remap GL_SGIX_async_functions[] = { - { 3387, -1 }, /* AsyncMarkerSGIX */ - { 4519, -1 }, /* FinishAsyncSGIX */ - { 5466, -1 }, /* PollAsyncSGIX */ - { 22228, -1 }, /* DeleteAsyncMarkersSGIX */ - { 22283, -1 }, /* IsAsyncMarkerSGIX */ - { 32318, -1 }, /* GenAsyncMarkersSGIX */ + { 3426, -1 }, /* AsyncMarkerSGIX */ + { 4506, -1 }, /* FinishAsyncSGIX */ + { 5495, -1 }, /* PollAsyncSGIX */ + { 22328, -1 }, /* DeleteAsyncMarkersSGIX */ + { 22383, -1 }, /* IsAsyncMarkerSGIX */ + { 32593, -1 }, /* GenAsyncMarkersSGIX */ { -1, -1 } }; #endif #if defined(need_GL_SGIX_flush_raster) static const struct gl_function_remap GL_SGIX_flush_raster_functions[] = { - { 7383, -1 }, /* FlushRasterSGIX */ + { 7353, -1 }, /* FlushRasterSGIX */ { -1, -1 } }; #endif #if defined(need_GL_SGIX_fragment_lighting) static const struct gl_function_remap GL_SGIX_fragment_lighting_functions[] = { - { 2625, -1 }, /* FragmentMaterialfvSGIX */ - { 5370, -1 }, /* FragmentLightiSGIX */ - { 8103, -1 }, /* FragmentMaterialfSGIX */ - { 8264, -1 }, /* GetFragmentLightivSGIX */ - { 9137, -1 }, /* FragmentLightModeliSGIX */ - { 10695, -1 }, /* FragmentLightivSGIX */ - { 11013, -1 }, /* GetFragmentMaterialivSGIX */ - { 16193, -1 }, /* GetFragmentMaterialfvSGIX */ - { 19403, -1 }, /* FragmentLightModelfSGIX */ - { 19703, -1 }, /* FragmentColorMaterialSGIX */ - { 20120, -1 }, /* FragmentMaterialiSGIX */ - { 21380, -1 }, /* LightEnviSGIX */ - { 22974, -1 }, /* FragmentLightModelfvSGIX */ - { 23309, -1 }, /* FragmentLightfvSGIX */ - { 28165, -1 }, /* FragmentLightModelivSGIX */ - { 28314, -1 }, /* FragmentLightfSGIX */ - { 31189, -1 }, /* GetFragmentLightfvSGIX */ - { 32801, -1 }, /* FragmentMaterialivSGIX */ + { 2664, -1 }, /* FragmentMaterialfvSGIX */ + { 5399, -1 }, /* FragmentLightiSGIX */ + { 8073, -1 }, /* FragmentMaterialfSGIX */ + { 8234, -1 }, /* GetFragmentLightivSGIX */ + { 9107, -1 }, /* FragmentLightModeliSGIX */ + { 10712, -1 }, /* FragmentLightivSGIX */ + { 11019, -1 }, /* GetFragmentMaterialivSGIX */ + { 16231, -1 }, /* GetFragmentMaterialfvSGIX */ + { 19486, -1 }, /* FragmentLightModelfSGIX */ + { 19786, -1 }, /* FragmentColorMaterialSGIX */ + { 20203, -1 }, /* FragmentMaterialiSGIX */ + { 21463, -1 }, /* LightEnviSGIX */ + { 23074, -1 }, /* FragmentLightModelfvSGIX */ + { 23409, -1 }, /* FragmentLightfvSGIX */ + { 28446, -1 }, /* FragmentLightModelivSGIX */ + { 28595, -1 }, /* FragmentLightfSGIX */ + { 31431, -1 }, /* GetFragmentLightfvSGIX */ + { 33076, -1 }, /* FragmentMaterialivSGIX */ { -1, -1 } }; #endif #if defined(need_GL_SGIX_framezoom) static const struct gl_function_remap GL_SGIX_framezoom_functions[] = { - { 22306, -1 }, /* FrameZoomSGIX */ + { 22406, -1 }, /* FrameZoomSGIX */ { -1, -1 } }; #endif #if defined(need_GL_SGIX_igloo_interface) static const struct gl_function_remap GL_SGIX_igloo_interface_functions[] = { - { 28622, -1 }, /* IglooInterfaceSGIX */ + { 28903, -1 }, /* IglooInterfaceSGIX */ { -1, -1 } }; #endif #if defined(need_GL_SGIX_instruments) static const struct gl_function_remap GL_SGIX_instruments_functions[] = { - { 2805, -1 }, /* ReadInstrumentsSGIX */ - { 6585, -1 }, /* PollInstrumentsSGIX */ - { 10553, -1 }, /* GetInstrumentsSGIX */ - { 12924, -1 }, /* StartInstrumentsSGIX */ - { 15918, -1 }, /* StopInstrumentsSGIX */ - { 17777, -1 }, /* InstrumentsBufferSGIX */ + { 2844, -1 }, /* ReadInstrumentsSGIX */ + { 6572, -1 }, /* PollInstrumentsSGIX */ + { 10570, -1 }, /* GetInstrumentsSGIX */ + { 13000, -1 }, /* StartInstrumentsSGIX */ + { 15956, -1 }, /* StopInstrumentsSGIX */ + { 17823, -1 }, /* InstrumentsBufferSGIX */ { -1, -1 } }; #endif #if defined(need_GL_SGIX_list_priority) static const struct gl_function_remap GL_SGIX_list_priority_functions[] = { - { 1241, -1 }, /* ListParameterfSGIX */ - { 3089, -1 }, /* GetListParameterfvSGIX */ - { 17692, -1 }, /* ListParameteriSGIX */ - { 18645, -1 }, /* ListParameterfvSGIX */ - { 20786, -1 }, /* ListParameterivSGIX */ - { 32362, -1 }, /* GetListParameterivSGIX */ + { 1280, -1 }, /* ListParameterfSGIX */ + { 3128, -1 }, /* GetListParameterfvSGIX */ + { 17714, -1 }, /* ListParameteriSGIX */ + { 18728, -1 }, /* ListParameterfvSGIX */ + { 20869, -1 }, /* ListParameterivSGIX */ + { 32637, -1 }, /* GetListParameterivSGIX */ { -1, -1 } }; #endif @@ -6273,134 +6356,134 @@ static const struct gl_function_remap GL_SGIX_pixel_texture_functions[] = { #if defined(need_GL_SGIX_polynomial_ffd) static const struct gl_function_remap GL_SGIX_polynomial_ffd_functions[] = { - { 3685, -1 }, /* LoadIdentityDeformationMapSGIX */ - { 16018, -1 }, /* DeformSGIX */ - { 24222, -1 }, /* DeformationMap3fSGIX */ - { 31077, -1 }, /* DeformationMap3dSGIX */ + { 3724, -1 }, /* LoadIdentityDeformationMapSGIX */ + { 12208, -1 }, /* DeformationMap3dSGIX */ + { 16056, -1 }, /* DeformSGIX */ + { 24351, -1 }, /* DeformationMap3fSGIX */ { -1, -1 } }; #endif #if defined(need_GL_SGIX_reference_plane) static const struct gl_function_remap GL_SGIX_reference_plane_functions[] = { - { 14749, -1 }, /* ReferencePlaneSGIX */ + { 14787, -1 }, /* ReferencePlaneSGIX */ { -1, -1 } }; #endif #if defined(need_GL_SGIX_sprite) static const struct gl_function_remap GL_SGIX_sprite_functions[] = { - { 9635, -1 }, /* SpriteParameterfvSGIX */ - { 20575, -1 }, /* SpriteParameteriSGIX */ - { 26519, -1 }, /* SpriteParameterfSGIX */ - { 29242, -1 }, /* SpriteParameterivSGIX */ + { 9605, -1 }, /* SpriteParameterfvSGIX */ + { 20658, -1 }, /* SpriteParameteriSGIX */ + { 26681, -1 }, /* SpriteParameterfSGIX */ + { 29523, -1 }, /* SpriteParameterivSGIX */ { -1, -1 } }; #endif #if defined(need_GL_SGIX_tag_sample_buffer) static const struct gl_function_remap GL_SGIX_tag_sample_buffer_functions[] = { - { 20634, -1 }, /* TagSampleBufferSGIX */ + { 20717, -1 }, /* TagSampleBufferSGIX */ { -1, -1 } }; #endif #if defined(need_GL_SGI_color_table) static const struct gl_function_remap GL_SGI_color_table_functions[] = { - { 7673, _gloffset_ColorTableParameteriv }, - { 8385, _gloffset_ColorTable }, - { 15245, _gloffset_GetColorTable }, - { 15355, _gloffset_CopyColorTable }, - { 19347, _gloffset_ColorTableParameterfv }, - { 22882, _gloffset_GetColorTableParameterfv }, - { 24980, _gloffset_GetColorTableParameteriv }, + { 7643, _gloffset_ColorTableParameteriv }, + { 8355, _gloffset_ColorTable }, + { 15283, _gloffset_GetColorTable }, + { 15393, _gloffset_CopyColorTable }, + { 19430, _gloffset_ColorTableParameterfv }, + { 22982, _gloffset_GetColorTableParameterfv }, + { 25109, _gloffset_GetColorTableParameteriv }, { -1, -1 } }; #endif #if defined(need_GL_SUNX_constant_data) static const struct gl_function_remap GL_SUNX_constant_data_functions[] = { - { 31167, -1 }, /* FinishTextureSUNX */ + { 31409, -1 }, /* FinishTextureSUNX */ { -1, -1 } }; #endif #if defined(need_GL_SUN_global_alpha) static const struct gl_function_remap GL_SUN_global_alpha_functions[] = { - { 3408, -1 }, /* GlobalAlphaFactorubSUN */ - { 4818, -1 }, /* GlobalAlphaFactoriSUN */ - { 6610, -1 }, /* GlobalAlphaFactordSUN */ - { 9719, -1 }, /* GlobalAlphaFactoruiSUN */ - { 10144, -1 }, /* GlobalAlphaFactorbSUN */ - { 13239, -1 }, /* GlobalAlphaFactorfSUN */ - { 13403, -1 }, /* GlobalAlphaFactorusSUN */ - { 22569, -1 }, /* GlobalAlphaFactorsSUN */ + { 3447, -1 }, /* GlobalAlphaFactorubSUN */ + { 4805, -1 }, /* GlobalAlphaFactoriSUN */ + { 6597, -1 }, /* GlobalAlphaFactordSUN */ + { 9689, -1 }, /* GlobalAlphaFactoruiSUN */ + { 10161, -1 }, /* GlobalAlphaFactorbSUN */ + { 13315, -1 }, /* GlobalAlphaFactorfSUN */ + { 13479, -1 }, /* GlobalAlphaFactorusSUN */ + { 22669, -1 }, /* GlobalAlphaFactorsSUN */ { -1, -1 } }; #endif #if defined(need_GL_SUN_mesh_array) static const struct gl_function_remap GL_SUN_mesh_array_functions[] = { - { 29033, -1 }, /* DrawMeshArraysSUN */ + { 29314, -1 }, /* DrawMeshArraysSUN */ { -1, -1 } }; #endif #if defined(need_GL_SUN_triangle_list) static const struct gl_function_remap GL_SUN_triangle_list_functions[] = { - { 4493, -1 }, /* ReplacementCodeubSUN */ - { 6369, -1 }, /* ReplacementCodeubvSUN */ - { 19068, -1 }, /* ReplacementCodeusvSUN */ - { 19256, -1 }, /* ReplacementCodePointerSUN */ - { 21444, -1 }, /* ReplacementCodeuiSUN */ - { 22257, -1 }, /* ReplacementCodeusSUN */ - { 29699, -1 }, /* ReplacementCodeuivSUN */ + { 4480, -1 }, /* ReplacementCodeubSUN */ + { 6356, -1 }, /* ReplacementCodeubvSUN */ + { 19151, -1 }, /* ReplacementCodeusvSUN */ + { 19339, -1 }, /* ReplacementCodePointerSUN */ + { 21527, -1 }, /* ReplacementCodeuiSUN */ + { 22357, -1 }, /* ReplacementCodeusSUN */ + { 29980, -1 }, /* ReplacementCodeuivSUN */ { -1, -1 } }; #endif #if defined(need_GL_SUN_vertex) static const struct gl_function_remap GL_SUN_vertex_functions[] = { - { 1115, -1 }, /* ReplacementCodeuiColor3fVertex3fvSUN */ - { 1313, -1 }, /* TexCoord4fColor4fNormal3fVertex4fvSUN */ - { 1539, -1 }, /* TexCoord2fColor4ubVertex3fvSUN */ - { 1869, -1 }, /* ReplacementCodeuiVertex3fvSUN */ - { 2003, -1 }, /* ReplacementCodeuiTexCoord2fVertex3fvSUN */ - { 2561, -1 }, /* ReplacementCodeuiNormal3fVertex3fSUN */ - { 2874, -1 }, /* Color4ubVertex3fvSUN */ - { 4652, -1 }, /* Color4ubVertex3fSUN */ - { 4775, -1 }, /* TexCoord2fVertex3fSUN */ - { 5119, -1 }, /* TexCoord2fColor4fNormal3fVertex3fSUN */ - { 5570, -1 }, /* TexCoord2fNormal3fVertex3fvSUN */ - { 6264, -1 }, /* ReplacementCodeuiTexCoord2fNormal3fVertex3fSUN */ - { 7061, -1 }, /* ReplacementCodeuiColor4ubVertex3fvSUN */ - { 7420, -1 }, /* ReplacementCodeuiTexCoord2fVertex3fSUN */ - { 8132, -1 }, /* TexCoord2fNormal3fVertex3fSUN */ - { 8936, -1 }, /* Color3fVertex3fSUN */ - { 10080, -1 }, /* Color3fVertex3fvSUN */ - { 10518, -1 }, /* Color4fNormal3fVertex3fvSUN */ - { 11358, -1 }, /* ReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN */ - { 12787, -1 }, /* ReplacementCodeuiColor4fNormal3fVertex3fvSUN */ - { 14398, -1 }, /* ReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN */ - { 14891, -1 }, /* TexCoord2fColor3fVertex3fSUN */ - { 15943, -1 }, /* TexCoord4fColor4fNormal3fVertex4fSUN */ - { 16358, -1 }, /* Color4ubVertex2fvSUN */ - { 16645, -1 }, /* Normal3fVertex3fSUN */ - { 17718, -1 }, /* ReplacementCodeuiColor4fNormal3fVertex3fSUN */ - { 18079, -1 }, /* TexCoord2fColor4fNormal3fVertex3fvSUN */ - { 18897, -1 }, /* TexCoord2fVertex3fvSUN */ - { 19673, -1 }, /* Color4ubVertex2fSUN */ - { 19911, -1 }, /* ReplacementCodeuiColor4ubVertex3fSUN */ - { 21893, -1 }, /* TexCoord2fColor4ubVertex3fSUN */ - { 22325, -1 }, /* Normal3fVertex3fvSUN */ - { 22791, -1 }, /* Color4fNormal3fVertex3fSUN */ - { 23771, -1 }, /* ReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN */ - { 25840, -1 }, /* ReplacementCodeuiColor3fVertex3fSUN */ - { 27196, -1 }, /* TexCoord4fVertex4fSUN */ - { 27622, -1 }, /* TexCoord2fColor3fVertex3fvSUN */ - { 28009, -1 }, /* ReplacementCodeuiNormal3fVertex3fvSUN */ - { 28136, -1 }, /* TexCoord4fVertex4fvSUN */ - { 28870, -1 }, /* ReplacementCodeuiVertex3fSUN */ + { 1154, -1 }, /* ReplacementCodeuiColor3fVertex3fvSUN */ + { 1352, -1 }, /* TexCoord4fColor4fNormal3fVertex4fvSUN */ + { 1578, -1 }, /* TexCoord2fColor4ubVertex3fvSUN */ + { 1908, -1 }, /* ReplacementCodeuiVertex3fvSUN */ + { 2042, -1 }, /* ReplacementCodeuiTexCoord2fVertex3fvSUN */ + { 2600, -1 }, /* ReplacementCodeuiNormal3fVertex3fSUN */ + { 2913, -1 }, /* Color4ubVertex3fvSUN */ + { 4639, -1 }, /* Color4ubVertex3fSUN */ + { 4762, -1 }, /* TexCoord2fVertex3fSUN */ + { 5106, -1 }, /* TexCoord2fColor4fNormal3fVertex3fSUN */ + { 5599, -1 }, /* TexCoord2fNormal3fVertex3fvSUN */ + { 6251, -1 }, /* ReplacementCodeuiTexCoord2fNormal3fVertex3fSUN */ + { 7031, -1 }, /* ReplacementCodeuiColor4ubVertex3fvSUN */ + { 7390, -1 }, /* ReplacementCodeuiTexCoord2fVertex3fSUN */ + { 8102, -1 }, /* TexCoord2fNormal3fVertex3fSUN */ + { 8906, -1 }, /* Color3fVertex3fSUN */ + { 10097, -1 }, /* Color3fVertex3fvSUN */ + { 10535, -1 }, /* Color4fNormal3fVertex3fvSUN */ + { 11364, -1 }, /* ReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN */ + { 12863, -1 }, /* ReplacementCodeuiColor4fNormal3fVertex3fvSUN */ + { 14403, -1 }, /* ReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN */ + { 14929, -1 }, /* TexCoord2fColor3fVertex3fSUN */ + { 15981, -1 }, /* TexCoord4fColor4fNormal3fVertex4fSUN */ + { 16396, -1 }, /* Color4ubVertex2fvSUN */ + { 16667, -1 }, /* Normal3fVertex3fSUN */ + { 17764, -1 }, /* ReplacementCodeuiColor4fNormal3fVertex3fSUN */ + { 18125, -1 }, /* TexCoord2fColor4fNormal3fVertex3fvSUN */ + { 18980, -1 }, /* TexCoord2fVertex3fvSUN */ + { 19756, -1 }, /* Color4ubVertex2fSUN */ + { 19994, -1 }, /* ReplacementCodeuiColor4ubVertex3fSUN */ + { 21993, -1 }, /* TexCoord2fColor4ubVertex3fSUN */ + { 22425, -1 }, /* Normal3fVertex3fvSUN */ + { 22891, -1 }, /* Color4fNormal3fVertex3fSUN */ + { 23900, -1 }, /* ReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN */ + { 26002, -1 }, /* ReplacementCodeuiColor3fVertex3fSUN */ + { 27425, -1 }, /* TexCoord4fVertex4fSUN */ + { 27851, -1 }, /* TexCoord2fColor3fVertex3fvSUN */ + { 28290, -1 }, /* ReplacementCodeuiNormal3fVertex3fvSUN */ + { 28417, -1 }, /* TexCoord4fVertex4fvSUN */ + { 29151, -1 }, /* ReplacementCodeuiVertex3fSUN */ { -1, -1 } }; #endif @@ -6408,40 +6491,40 @@ static const struct gl_function_remap GL_SUN_vertex_functions[] = { #if defined(need_GL_VERSION_1_3) /* functions defined in MESA_remap_table_functions are excluded */ static const struct gl_function_remap GL_VERSION_1_3_functions[] = { - { 425, _gloffset_MultiTexCoord3sARB }, - { 657, _gloffset_ActiveTextureARB }, - { 4247, _gloffset_MultiTexCoord1fvARB }, - { 6155, _gloffset_MultiTexCoord3dARB }, - { 6200, _gloffset_MultiTexCoord2iARB }, - { 6324, _gloffset_MultiTexCoord2svARB }, - { 8341, _gloffset_MultiTexCoord2fARB }, - { 10354, _gloffset_MultiTexCoord3fvARB }, - { 10967, _gloffset_MultiTexCoord4sARB }, - { 11648, _gloffset_MultiTexCoord2dvARB }, - { 12063, _gloffset_MultiTexCoord1svARB }, - { 12435, _gloffset_MultiTexCoord3svARB }, - { 12496, _gloffset_MultiTexCoord4iARB }, - { 13266, _gloffset_MultiTexCoord3iARB }, - { 14136, _gloffset_MultiTexCoord1dARB }, - { 14353, _gloffset_MultiTexCoord3dvARB }, - { 15599, _gloffset_MultiTexCoord3ivARB }, - { 15644, _gloffset_MultiTexCoord2sARB }, - { 17045, _gloffset_MultiTexCoord4ivARB }, - { 18997, _gloffset_ClientActiveTextureARB }, - { 21297, _gloffset_MultiTexCoord2dARB }, - { 21717, _gloffset_MultiTexCoord4dvARB }, - { 22073, _gloffset_MultiTexCoord4fvARB }, - { 23023, _gloffset_MultiTexCoord3fARB }, - { 25531, _gloffset_MultiTexCoord4dARB }, - { 25797, _gloffset_MultiTexCoord1sARB }, - { 26001, _gloffset_MultiTexCoord1dvARB }, - { 26942, _gloffset_MultiTexCoord1ivARB }, - { 27035, _gloffset_MultiTexCoord2ivARB }, - { 27374, _gloffset_MultiTexCoord1iARB }, - { 28738, _gloffset_MultiTexCoord4svARB }, - { 29312, _gloffset_MultiTexCoord1fARB }, - { 29575, _gloffset_MultiTexCoord4fARB }, - { 32039, _gloffset_MultiTexCoord2fvARB }, + { 464, _gloffset_MultiTexCoord3sARB }, + { 696, _gloffset_ActiveTextureARB }, + { 4234, _gloffset_MultiTexCoord1fvARB }, + { 6142, _gloffset_MultiTexCoord3dARB }, + { 6187, _gloffset_MultiTexCoord2iARB }, + { 6311, _gloffset_MultiTexCoord2svARB }, + { 8311, _gloffset_MultiTexCoord2fARB }, + { 10371, _gloffset_MultiTexCoord3fvARB }, + { 10973, _gloffset_MultiTexCoord4sARB }, + { 11654, _gloffset_MultiTexCoord2dvARB }, + { 12069, _gloffset_MultiTexCoord1svARB }, + { 12480, _gloffset_MultiTexCoord3svARB }, + { 12541, _gloffset_MultiTexCoord4iARB }, + { 13342, _gloffset_MultiTexCoord3iARB }, + { 14141, _gloffset_MultiTexCoord1dARB }, + { 14358, _gloffset_MultiTexCoord3dvARB }, + { 15637, _gloffset_MultiTexCoord3ivARB }, + { 15682, _gloffset_MultiTexCoord2sARB }, + { 17067, _gloffset_MultiTexCoord4ivARB }, + { 19080, _gloffset_ClientActiveTextureARB }, + { 21380, _gloffset_MultiTexCoord2dARB }, + { 21817, _gloffset_MultiTexCoord4dvARB }, + { 22173, _gloffset_MultiTexCoord4fvARB }, + { 23123, _gloffset_MultiTexCoord3fARB }, + { 25693, _gloffset_MultiTexCoord4dARB }, + { 25959, _gloffset_MultiTexCoord1sARB }, + { 26163, _gloffset_MultiTexCoord1dvARB }, + { 27171, _gloffset_MultiTexCoord1ivARB }, + { 27264, _gloffset_MultiTexCoord2ivARB }, + { 27603, _gloffset_MultiTexCoord1iARB }, + { 29019, _gloffset_MultiTexCoord4svARB }, + { 29593, _gloffset_MultiTexCoord1fARB }, + { 29856, _gloffset_MultiTexCoord4fARB }, + { 32314, _gloffset_MultiTexCoord2fvARB }, { -1, -1 } }; #endif diff --git a/src/mesa/main/renderbuffer.c b/src/mesa/main/renderbuffer.c index 3d1a8f8592..67ee589d77 100644 --- a/src/mesa/main/renderbuffer.c +++ b/src/mesa/main/renderbuffer.c @@ -1086,7 +1086,7 @@ _mesa_soft_renderbuffer_storage(struct gl_context *ctx, struct gl_renderbuffer * pixelSize = sizeof(GLuint); break; default: - _mesa_problem(ctx, "Bad internalFormat in _mesa_soft_renderbuffer_storage"); + /* unsupported format */ return GL_FALSE; } @@ -1481,7 +1481,7 @@ _mesa_add_color_renderbuffers(struct gl_context *ctx, struct gl_framebuffer *fb, GLboolean frontLeft, GLboolean backLeft, GLboolean frontRight, GLboolean backRight) { - GLuint b; + gl_buffer_index b; if (rgbBits > 16 || alphaBits > 16) { _mesa_problem(ctx, @@ -1545,7 +1545,7 @@ _mesa_add_alpha_renderbuffers(struct gl_context *ctx, struct gl_framebuffer *fb, GLboolean frontLeft, GLboolean backLeft, GLboolean frontRight, GLboolean backRight) { - GLuint b; + gl_buffer_index b; /* for window system framebuffers only! */ assert(fb->Name == 0); @@ -1883,10 +1883,11 @@ _mesa_add_soft_renderbuffers(struct gl_framebuffer *fb, /** * Attach a renderbuffer to a framebuffer. + * \param bufferName one of the BUFFER_x tokens */ void _mesa_add_renderbuffer(struct gl_framebuffer *fb, - GLuint bufferName, struct gl_renderbuffer *rb) + gl_buffer_index bufferName, struct gl_renderbuffer *rb) { assert(fb); assert(rb); @@ -1916,9 +1917,11 @@ _mesa_add_renderbuffer(struct gl_framebuffer *fb, /** * Remove the named renderbuffer from the given framebuffer. + * \param bufferName one of the BUFFER_x tokens */ void -_mesa_remove_renderbuffer(struct gl_framebuffer *fb, GLuint bufferName) +_mesa_remove_renderbuffer(struct gl_framebuffer *fb, + gl_buffer_index bufferName) { struct gl_renderbuffer *rb; diff --git a/src/mesa/main/renderbuffer.h b/src/mesa/main/renderbuffer.h index 62e812f93a..4702a8e952 100644 --- a/src/mesa/main/renderbuffer.h +++ b/src/mesa/main/renderbuffer.h @@ -27,6 +27,7 @@ #define RENDERBUFFER_H #include "glheader.h" +#include "mtypes.h" struct gl_context; struct gl_framebuffer; @@ -95,10 +96,11 @@ _mesa_add_soft_renderbuffers(struct gl_framebuffer *fb, extern void _mesa_add_renderbuffer(struct gl_framebuffer *fb, - GLuint bufferName, struct gl_renderbuffer *rb); + gl_buffer_index bufferName, struct gl_renderbuffer *rb); extern void -_mesa_remove_renderbuffer(struct gl_framebuffer *fb, GLuint bufferName); +_mesa_remove_renderbuffer(struct gl_framebuffer *fb, + gl_buffer_index bufferName); extern void _mesa_reference_renderbuffer(struct gl_renderbuffer **ptr, diff --git a/src/mesa/main/scissor.c b/src/mesa/main/scissor.c index 4cf0bc2528..df665994a9 100644 --- a/src/mesa/main/scissor.c +++ b/src/mesa/main/scissor.c @@ -25,6 +25,7 @@ #include "main/glheader.h" #include "main/context.h" +#include "main/mtypes.h" #include "main/scissor.h" diff --git a/src/mesa/main/shaderapi.c b/src/mesa/main/shaderapi.c index 96df58d35c..2c5f2a147c 100644 --- a/src/mesa/main/shaderapi.c +++ b/src/mesa/main/shaderapi.c @@ -41,13 +41,16 @@ #include "main/dispatch.h" #include "main/enums.h" #include "main/hash.h" +#include "main/mfeatures.h" +#include "main/mtypes.h" #include "main/shaderapi.h" #include "main/shaderobj.h" #include "program/program.h" #include "program/prog_parameter.h" #include "program/prog_uniform.h" -#include "talloc.h" +#include "ralloc.h" #include <stdbool.h> +#include "../glsl/glsl_parser_extras.h" /** Define this to enable shader substitution (see below) */ #define SHADER_SUBST 0 @@ -1134,9 +1137,9 @@ validate_program(struct gl_context *ctx, GLuint program) if (!shProg->Validated) { /* update info log */ if (shProg->InfoLog) { - talloc_free(shProg->InfoLog); + ralloc_free(shProg->InfoLog); } - shProg->InfoLog = talloc_strdup(shProg, errMsg); + shProg->InfoLog = ralloc_strdup(shProg, errMsg); } } @@ -1181,6 +1184,8 @@ void GLAPIENTRY _mesa_CompileShaderARB(GLhandleARB shaderObj) { GET_CURRENT_CONTEXT(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glCompileShader %u\n", shaderObj); compile_shader(ctx, shaderObj); } @@ -1189,6 +1194,8 @@ GLuint GLAPIENTRY _mesa_CreateShader(GLenum type) { GET_CURRENT_CONTEXT(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glCreateShader %s\n", _mesa_lookup_enum_by_nr(type)); return create_shader(ctx, type); } @@ -1205,6 +1212,8 @@ GLuint GLAPIENTRY _mesa_CreateProgram(void) { GET_CURRENT_CONTEXT(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glCreateProgram\n"); return create_shader_program(ctx); } @@ -1220,8 +1229,14 @@ _mesa_CreateProgramObjectARB(void) void GLAPIENTRY _mesa_DeleteObjectARB(GLhandleARB obj) { + if (MESA_VERBOSE & VERBOSE_API) { + GET_CURRENT_CONTEXT(ctx); + _mesa_debug(ctx, "glDeleteObjectARB(%u)\n", obj); + } + if (obj) { GET_CURRENT_CONTEXT(ctx); + FLUSH_VERTICES(ctx, 0); if (is_program(ctx, obj)) { delete_shader_program(ctx, obj); } @@ -1240,6 +1255,7 @@ _mesa_DeleteProgram(GLuint name) { if (name) { GET_CURRENT_CONTEXT(ctx); + FLUSH_VERTICES(ctx, 0); delete_shader_program(ctx, name); } } @@ -1250,6 +1266,7 @@ _mesa_DeleteShader(GLuint name) { if (name) { GET_CURRENT_CONTEXT(ctx); + FLUSH_VERTICES(ctx, 0); delete_shader(ctx, name); } } @@ -1625,20 +1642,58 @@ void GLAPIENTRY _mesa_GetShaderPrecisionFormat(GLenum shadertype, GLenum precisiontype, GLint* range, GLint* precision) { + const struct gl_program_constants *limits; + const struct gl_precision *p; GET_CURRENT_CONTEXT(ctx); - (void) shadertype; - (void) precisiontype; - (void) range; - (void) precision; - _mesa_error(ctx, GL_INVALID_OPERATION, __FUNCTION__); + + switch (shadertype) { + case GL_VERTEX_SHADER: + limits = &ctx->Const.VertexProgram; + break; + case GL_FRAGMENT_SHADER: + limits = &ctx->Const.FragmentProgram; + break; + default: + _mesa_error(ctx, GL_INVALID_ENUM, + "glGetShaderPrecisionFormat(shadertype)"); + return; + } + + switch (precisiontype) { + case GL_LOW_FLOAT: + p = &limits->LowFloat; + break; + case GL_MEDIUM_FLOAT: + p = &limits->MediumFloat; + break; + case GL_HIGH_FLOAT: + p = &limits->HighFloat; + break; + case GL_LOW_INT: + p = &limits->LowInt; + break; + case GL_MEDIUM_INT: + p = &limits->MediumInt; + break; + case GL_HIGH_INT: + p = &limits->HighInt; + break; + default: + _mesa_error(ctx, GL_INVALID_ENUM, + "glGetShaderPrecisionFormat(precisiontype)"); + return; + } + + range[0] = p->RangeMin; + range[1] = p->RangeMax; + precision[0] = p->Precision; } void GLAPIENTRY _mesa_ReleaseShaderCompiler(void) { - GET_CURRENT_CONTEXT(ctx); - _mesa_error(ctx, GL_INVALID_OPERATION, __FUNCTION__); + _mesa_destroy_shader_compiler_caches(); } @@ -1677,7 +1732,7 @@ _mesa_ProgramParameteriARB(GLuint program, GLenum pname, switch (pname) { case GL_GEOMETRY_VERTICES_OUT_ARB: if (value < 1 || - (unsigned) value > ctx->Const.GeometryProgram.MaxGeometryOutputVertices) { + (unsigned) value > ctx->Const.MaxGeometryOutputVertices) { _mesa_error(ctx, GL_INVALID_VALUE, "glProgramParameteri(GL_GEOMETRY_VERTICES_OUT_ARB=%d", value); @@ -1814,7 +1869,7 @@ _mesa_CreateShaderProgramEXT(GLenum type, const GLchar *string) #endif } - shProg->InfoLog = talloc_strdup_append(shProg->InfoLog, sh->InfoLog); + ralloc_strcat(&shProg->InfoLog, sh->InfoLog); } delete_shader(ctx, shader); @@ -1881,6 +1936,10 @@ _mesa_init_shader_dispatch(struct _glapi_table *exec) SET_BindFragDataLocationEXT(exec, _mesa_BindFragDataLocation); SET_GetFragDataLocationEXT(exec, _mesa_GetFragDataLocation); + /* GL_ARB_ES2_compatibility */ + SET_ReleaseShaderCompiler(exec, _mesa_ReleaseShaderCompiler); + SET_GetShaderPrecisionFormat(exec, _mesa_GetShaderPrecisionFormat); + #endif /* FEATURE_GL */ } diff --git a/src/mesa/main/shaderobj.c b/src/mesa/main/shaderobj.c index 216bbce003..62de23bd10 100644 --- a/src/mesa/main/shaderobj.c +++ b/src/mesa/main/shaderobj.c @@ -32,11 +32,13 @@ #include "main/glheader.h" #include "main/context.h" #include "main/hash.h" +#include "main/mfeatures.h" +#include "main/mtypes.h" #include "main/shaderobj.h" #include "program/program.h" #include "program/prog_parameter.h" #include "program/prog_uniform.h" -#include "talloc.h" +#include "ralloc.h" /**********************************************************************/ /*** Shader object functions ***/ @@ -70,7 +72,8 @@ _mesa_reference_shader(struct gl_context *ctx, struct gl_shader **ptr, deleteFlag = (old->RefCount == 0); if (deleteFlag) { - _mesa_HashRemove(ctx->Shared->ShaderObjects, old->Name); + if (old->Name != 0) + _mesa_HashRemove(ctx->Shared->ShaderObjects, old->Name); ctx->Driver.DeleteShader(ctx, old); } @@ -103,7 +106,7 @@ _mesa_new_shader(struct gl_context *ctx, GLuint name, GLenum type) struct gl_shader *shader; assert(type == GL_FRAGMENT_SHADER || type == GL_VERTEX_SHADER || type == GL_GEOMETRY_SHADER_ARB); - shader = talloc_zero(NULL, struct gl_shader); + shader = rzalloc(NULL, struct gl_shader); if (shader) { shader->Type = type; shader->Name = name; @@ -123,7 +126,7 @@ _mesa_delete_shader(struct gl_context *ctx, struct gl_shader *sh) if (sh->Source) free((void *) sh->Source); _mesa_reference_program(ctx, &sh->Program, NULL); - talloc_free(sh); + ralloc_free(sh); } @@ -211,7 +214,8 @@ _mesa_reference_shader_program(struct gl_context *ctx, deleteFlag = (old->RefCount == 0); if (deleteFlag) { - _mesa_HashRemove(ctx->Shared->ShaderObjects, old->Name); + if (old->Name != 0) + _mesa_HashRemove(ctx->Shared->ShaderObjects, old->Name); ctx->Driver.DeleteShaderProgram(ctx, old); } @@ -250,7 +254,7 @@ static struct gl_shader_program * _mesa_new_shader_program(struct gl_context *ctx, GLuint name) { struct gl_shader_program *shProg; - shProg = talloc_zero(NULL, struct gl_shader_program); + shProg = rzalloc(NULL, struct gl_shader_program); if (shProg) { shProg->Name = name; _mesa_init_shader_program(ctx, shProg); @@ -314,7 +318,7 @@ _mesa_free_shader_program_data(struct gl_context *ctx, } if (shProg->InfoLog) { - talloc_free(shProg->InfoLog); + ralloc_free(shProg->InfoLog); shProg->InfoLog = NULL; } @@ -345,7 +349,7 @@ _mesa_delete_shader_program(struct gl_context *ctx, struct gl_shader_program *sh { _mesa_free_shader_program_data(ctx, shProg); - talloc_free(shProg); + ralloc_free(shProg); } diff --git a/src/mesa/main/shared.c b/src/mesa/main/shared.c index 3abee0178e..ce9fc4de32 100644 --- a/src/mesa/main/shared.c +++ b/src/mesa/main/shared.c @@ -30,6 +30,7 @@ #include "imports.h" +#include "mfeatures.h" #include "mtypes.h" #include "hash.h" #if FEATURE_ATI_fragment_shader diff --git a/src/mesa/main/state.c b/src/mesa/main/state.c index cce1b464f0..19c9bbabda 100644 --- a/src/mesa/main/state.c +++ b/src/mesa/main/state.c @@ -53,7 +53,7 @@ static void update_separate_specular(struct gl_context *ctx) { - if (NEED_SECONDARY_COLOR(ctx)) + if (_mesa_need_secondary_color(ctx)) ctx->_TriangleCaps |= DD_SEPARATE_SPECULAR; else ctx->_TriangleCaps &= ~DD_SEPARATE_SPECULAR; @@ -442,7 +442,7 @@ update_color(struct gl_context *ctx) /* This is needed to support 1.1's RGB logic ops AND * 1.0's blending logicops. */ - ctx->Color._LogicOpEnabled = RGBA_LOGICOP_ENABLED(ctx); + ctx->Color._LogicOpEnabled = _mesa_rgba_logicop_enabled(ctx); } @@ -524,7 +524,7 @@ update_tricaps(struct gl_context *ctx, GLbitfield new_state) ctx->_TriangleCaps |= DD_TRI_LIGHT_TWOSIDE; if (ctx->Light.ShadeModel == GL_FLAT) ctx->_TriangleCaps |= DD_FLATSHADE; - if (NEED_SECONDARY_COLOR(ctx)) + if (_mesa_need_secondary_color(ctx)) ctx->_TriangleCaps |= DD_SEPARATE_SPECULAR; /* @@ -662,6 +662,8 @@ _mesa_update_state_locked( struct gl_context *ctx ) ctx->NewState = 0; ctx->Driver.UpdateState(ctx, new_state); ctx->Array.NewState = 0; + if (!ctx->Array.RebindArrays) + ctx->Array.RebindArrays = (new_state & (_NEW_ARRAY | _NEW_PROGRAM)) != 0; } diff --git a/src/mesa/main/state.h b/src/mesa/main/state.h index f0eb43d8ee..a48c777567 100644 --- a/src/mesa/main/state.h +++ b/src/mesa/main/state.h @@ -46,4 +46,43 @@ extern void _mesa_set_vp_override(struct gl_context *ctx, GLboolean flag); +/** + * Is the secondary color needed? + */ +static INLINE GLboolean +_mesa_need_secondary_color(const struct gl_context *ctx) +{ + if (ctx->Light.Enabled && + ctx->Light.Model.ColorControl == GL_SEPARATE_SPECULAR_COLOR) + return GL_TRUE; + + if (ctx->Fog.ColorSumEnabled) + return GL_TRUE; + + if (ctx->VertexProgram._Current && + (ctx->VertexProgram._Current != ctx->VertexProgram._TnlProgram) && + (ctx->VertexProgram._Current->Base.InputsRead & VERT_BIT_COLOR1)) + return GL_TRUE; + + if (ctx->FragmentProgram._Current && + (ctx->FragmentProgram._Current != ctx->FragmentProgram._TexEnvProgram) && + (ctx->FragmentProgram._Current->Base.InputsRead & FRAG_BIT_COL1)) + return GL_TRUE; + + return GL_FALSE; +} + + +/** + * Is RGBA LogicOp enabled? + */ +static INLINE GLboolean +_mesa_rgba_logicop_enabled(const struct gl_context *ctx) +{ + return ctx->Color.ColorLogicOpEnabled || + (ctx->Color.BlendEnabled && ctx->Color.Blend[0].EquationRGB == GL_LOGIC_OP); +} + + + #endif diff --git a/src/mesa/main/stencil.c b/src/mesa/main/stencil.c index 93e2e97ce0..d898bf1d74 100644 --- a/src/mesa/main/stencil.c +++ b/src/mesa/main/stencil.c @@ -147,6 +147,9 @@ _mesa_StencilFuncSeparateATI( GLenum frontfunc, GLenum backfunc, GLint ref, GLui const GLint stencilMax = (1 << ctx->DrawBuffer->Visual.stencilBits) - 1; ASSERT_OUTSIDE_BEGIN_END(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glStencilFuncSeparateATI()\n"); + if (!validate_stencil_func(ctx, frontfunc)) { _mesa_error(ctx, GL_INVALID_ENUM, "glStencilFuncSeparateATI(frontfunc)"); @@ -203,6 +206,9 @@ _mesa_StencilFunc( GLenum func, GLint ref, GLuint mask ) const GLint face = ctx->Stencil.ActiveFace; ASSERT_OUTSIDE_BEGIN_END(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glStencilFunc()\n"); + if (!validate_stencil_func(ctx, func)) { _mesa_error(ctx, GL_INVALID_ENUM, "glStencilFunc(func)"); return; @@ -267,6 +273,9 @@ _mesa_StencilMask( GLuint mask ) GET_CURRENT_CONTEXT(ctx); const GLint face = ctx->Stencil.ActiveFace; + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glStencilMask()\n"); + ASSERT_OUTSIDE_BEGIN_END(ctx); if (face != 0) { @@ -321,6 +330,9 @@ _mesa_StencilOp(GLenum fail, GLenum zfail, GLenum zpass) GET_CURRENT_CONTEXT(ctx); const GLint face = ctx->Stencil.ActiveFace; + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glStencilOp()\n"); + ASSERT_OUTSIDE_BEGIN_END(ctx); if (!validate_stencil_op(ctx, fail)) { @@ -386,6 +398,9 @@ _mesa_ActiveStencilFaceEXT(GLenum face) GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glActiveStencilFaceEXT()\n"); + if (!ctx->Extensions.EXT_stencil_two_side) { _mesa_error(ctx, GL_INVALID_OPERATION, "glActiveStencilFaceEXT"); return; @@ -416,6 +431,9 @@ _mesa_StencilOpSeparate(GLenum face, GLenum sfail, GLenum zfail, GLenum zpass) GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glStencilOpSeparate()\n"); + if (!validate_stencil_op(ctx, sfail)) { _mesa_error(ctx, GL_INVALID_ENUM, "glStencilOpSeparate(sfail)"); return; @@ -471,6 +489,9 @@ _mesa_StencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask) const GLint stencilMax = (1 << ctx->DrawBuffer->Visual.stencilBits) - 1; ASSERT_OUTSIDE_BEGIN_END(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glStencilFuncSeparate()\n"); + if (face != GL_FRONT && face != GL_BACK && face != GL_FRONT_AND_BACK) { _mesa_error(ctx, GL_INVALID_ENUM, "glStencilFuncSeparate(face)"); return; @@ -509,6 +530,9 @@ _mesa_StencilMaskSeparate(GLenum face, GLuint mask) GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END(ctx); + if (MESA_VERBOSE & VERBOSE_API) + _mesa_debug(ctx, "glStencilMaskSeparate()\n"); + if (face != GL_FRONT && face != GL_BACK && face != GL_FRONT_AND_BACK) { _mesa_error(ctx, GL_INVALID_ENUM, "glStencilaMaskSeparate(face)"); return; diff --git a/src/mesa/main/syncobj.c b/src/mesa/main/syncobj.c index 2c8bcbeaf7..e1a5c6c0f9 100644 --- a/src/mesa/main/syncobj.c +++ b/src/mesa/main/syncobj.c @@ -59,8 +59,10 @@ #include "imports.h" #include "context.h" #include "macros.h" +#include "mfeatures.h" #include "get.h" #include "dispatch.h" +#include "mtypes.h" #if FEATURE_ARB_sync #include "syncobj.h" diff --git a/src/mesa/main/texcompress.c b/src/mesa/main/texcompress.c index e3d2a786b3..d820ae9274 100644 --- a/src/mesa/main/texcompress.c +++ b/src/mesa/main/texcompress.c @@ -34,6 +34,8 @@ #include "imports.h" #include "colormac.h" #include "formats.h" +#include "mfeatures.h" +#include "mtypes.h" #include "texcompress.h" @@ -62,6 +64,7 @@ _mesa_get_compressed_formats(struct gl_context *ctx, GLint *formats, GLboolean a n += 2; } } + /* don't return RGTC - ARB_texture_compression_rgtc query 19 */ if (ctx->Extensions.EXT_texture_compression_s3tc) { if (formats) { formats[n++] = GL_COMPRESSED_RGB_S3TC_DXT1_EXT; @@ -161,6 +164,25 @@ _mesa_glenum_to_compressed_format(GLenum format) case GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT: return MESA_FORMAT_SRGBA_DXT5; + case GL_COMPRESSED_RED_RGTC1: + return MESA_FORMAT_RED_RGTC1; + case GL_COMPRESSED_SIGNED_RED_RGTC1: + return MESA_FORMAT_SIGNED_RED_RGTC1; + case GL_COMPRESSED_RG_RGTC2: + return MESA_FORMAT_RG_RGTC2; + case GL_COMPRESSED_SIGNED_RG_RGTC2: + return MESA_FORMAT_SIGNED_RG_RGTC2; + + case GL_COMPRESSED_LUMINANCE_LATC1_EXT: + return MESA_FORMAT_L_LATC1; + case GL_COMPRESSED_SIGNED_LUMINANCE_LATC1_EXT: + return MESA_FORMAT_SIGNED_L_LATC1; + case GL_COMPRESSED_LUMINANCE_ALPHA_LATC2_EXT: + case GL_COMPRESSED_LUMINANCE_ALPHA_3DC_ATI: + return MESA_FORMAT_LA_LATC2; + case GL_COMPRESSED_SIGNED_LUMINANCE_ALPHA_LATC2_EXT: + return MESA_FORMAT_SIGNED_LA_LATC2; + default: return MESA_FORMAT_NONE; } @@ -207,6 +229,25 @@ _mesa_compressed_format_to_glenum(struct gl_context *ctx, GLuint mesaFormat) return GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT; #endif #endif + + case MESA_FORMAT_RED_RGTC1: + return GL_COMPRESSED_RED_RGTC1; + case MESA_FORMAT_SIGNED_RED_RGTC1: + return GL_COMPRESSED_SIGNED_RED_RGTC1; + case MESA_FORMAT_RG_RGTC2: + return GL_COMPRESSED_RG_RGTC2; + case MESA_FORMAT_SIGNED_RG_RGTC2: + return GL_COMPRESSED_SIGNED_RG_RGTC2; + + case MESA_FORMAT_L_LATC1: + return GL_COMPRESSED_LUMINANCE_LATC1_EXT; + case MESA_FORMAT_SIGNED_L_LATC1: + return GL_COMPRESSED_SIGNED_LUMINANCE_LATC1_EXT; + case MESA_FORMAT_LA_LATC2: + return GL_COMPRESSED_LUMINANCE_ALPHA_LATC2_EXT; + case MESA_FORMAT_SIGNED_LA_LATC2: + return GL_COMPRESSED_SIGNED_LUMINANCE_ALPHA_LATC2_EXT; + default: _mesa_problem(ctx, "Unexpected mesa texture format in" " _mesa_compressed_format_to_glenum()"); diff --git a/src/mesa/main/texcompress_fxt1.c b/src/mesa/main/texcompress_fxt1.c index 33f46d4c8b..bb7fb567f2 100644 --- a/src/mesa/main/texcompress_fxt1.c +++ b/src/mesa/main/texcompress_fxt1.c @@ -34,6 +34,7 @@ #include "colormac.h" #include "image.h" #include "macros.h" +#include "mfeatures.h" #include "mipmap.h" #include "texcompress.h" #include "texcompress_fxt1.h" diff --git a/src/mesa/main/texcompress_fxt1.h b/src/mesa/main/texcompress_fxt1.h index 38048b26cc..b991f4c67e 100644 --- a/src/mesa/main/texcompress_fxt1.h +++ b/src/mesa/main/texcompress_fxt1.h @@ -26,6 +26,7 @@ #define TEXCOMPRESS_FXT1_H #include "glheader.h" +#include "mfeatures.h" #include "texstore.h" struct gl_texture_image; diff --git a/src/mesa/main/texcompress_rgtc.c b/src/mesa/main/texcompress_rgtc.c new file mode 100644 index 0000000000..c50df19c5d --- /dev/null +++ b/src/mesa/main/texcompress_rgtc.c @@ -0,0 +1,460 @@ +/* + * Copyright (C) 2011 Red Hat Inc. + * + * block compression parts are: + * Copyright (C) 2004 Roland Scheidegger All Rights Reserved. + * + * Permission is hereby granted, free of charge, to any person obtaining a + * copy of this software and associated documentation files (the "Software"), + * to deal in the Software without restriction, including without limitation + * the rights to use, copy, modify, merge, publish, distribute, sublicense, + * and/or sell copies of the Software, and to permit persons to whom the + * Software is furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice (including the next + * paragraph) shall be included in all copies or substantial portions of the + * Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL + * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER + * DEALINGS IN THE SOFTWARE. + * + * Author: + * Dave Airlie + */ + +/** + * \file texcompress_rgtc.c + * GL_EXT_texture_compression_rgtc support. + */ + + +#include "glheader.h" +#include "imports.h" +#include "colormac.h" +#include "image.h" +#include "macros.h" +#include "mfeatures.h" +#include "mipmap.h" +#include "texcompress.h" +#include "texcompress_rgtc.h" +#include "texstore.h" + +#define RGTC_DEBUG 0 + +static void unsigned_encode_rgtc_chan(GLubyte *blkaddr, GLubyte srccolors[4][4], + GLint numxpixels, GLint numypixels); +static void signed_encode_rgtc_chan(GLbyte *blkaddr, GLbyte srccolors[4][4], + GLint numxpixels, GLint numypixels); + +static void unsigned_fetch_texel_rgtc(unsigned srcRowStride, const GLubyte *pixdata, + unsigned i, unsigned j, GLubyte *value, unsigned comps); + +static void signed_fetch_texel_rgtc(unsigned srcRowStride, const GLbyte *pixdata, + unsigned i, unsigned j, GLbyte *value, unsigned comps); + +static void extractsrc_u( GLubyte srcpixels[4][4], const GLchan *srcaddr, + GLint srcRowStride, GLint numxpixels, GLint numypixels, GLint comps) +{ + GLubyte i, j; + const GLchan *curaddr; + for (j = 0; j < numypixels; j++) { + curaddr = srcaddr + j * srcRowStride * comps; + for (i = 0; i < numxpixels; i++) { + srcpixels[j][i] = *curaddr / (CHAN_MAX / 255); + curaddr += comps; + } + } +} + +static void extractsrc_s( GLbyte srcpixels[4][4], const GLfloat *srcaddr, + GLint srcRowStride, GLint numxpixels, GLint numypixels, GLint comps) +{ + GLubyte i, j; + const GLfloat *curaddr; + for (j = 0; j < numypixels; j++) { + curaddr = srcaddr + j * srcRowStride * comps; + for (i = 0; i < numxpixels; i++) { + srcpixels[j][i] = FLOAT_TO_BYTE_TEX(*curaddr); + curaddr += comps; + } + } +} + + +GLboolean +_mesa_texstore_red_rgtc1(TEXSTORE_PARAMS) +{ + GLubyte *dst; + const GLint texWidth = dstRowStride * 4 / 8; /* a bit of a hack */ + const GLchan *tempImage = NULL; + int i, j; + int numxpixels, numypixels; + const GLchan *srcaddr; + GLubyte srcpixels[4][4]; + GLubyte *blkaddr; + GLint dstRowDiff; + ASSERT(dstFormat == MESA_FORMAT_RED_RGTC1 || + dstFormat == MESA_FORMAT_L_LATC1); + ASSERT(dstXoffset % 4 == 0); + ASSERT(dstYoffset % 4 == 0); + ASSERT(dstZoffset % 4 == 0); + (void) dstZoffset; + (void) dstImageOffsets; + + + tempImage = _mesa_make_temp_chan_image(ctx, dims, + baseInternalFormat, + _mesa_get_format_base_format(dstFormat), + srcWidth, srcHeight, srcDepth, + srcFormat, srcType, srcAddr, + srcPacking); + if (!tempImage) + return GL_FALSE; /* out of memory */ + + dst = _mesa_compressed_image_address(dstXoffset, dstYoffset, 0, + dstFormat, + texWidth, (GLubyte *) dstAddr); + + blkaddr = dst; + dstRowDiff = dstRowStride >= (srcWidth * 4) ? dstRowStride - (((srcWidth + 3) & ~3) * 4) : 0; + for (j = 0; j < srcHeight; j+=4) { + if (srcHeight > j + 3) numypixels = 4; + else numypixels = srcHeight - j; + srcaddr = tempImage + j * srcWidth; + for (i = 0; i < srcWidth; i += 4) { + if (srcWidth > i + 3) numxpixels = 4; + else numxpixels = srcWidth - i; + extractsrc_u(srcpixels, srcaddr, srcWidth, numxpixels, numypixels, 1); + unsigned_encode_rgtc_chan(blkaddr, srcpixels, numxpixels, numypixels); + srcaddr += numxpixels; + blkaddr += 8; + } + blkaddr += dstRowDiff; + } + if (tempImage) + free((void *) tempImage); + + return GL_TRUE; +} + +GLboolean +_mesa_texstore_signed_red_rgtc1(TEXSTORE_PARAMS) +{ + GLbyte *dst; + const GLint texWidth = dstRowStride * 4 / 8; /* a bit of a hack */ + const GLfloat *tempImage = NULL; + int i, j; + int numxpixels, numypixels; + const GLfloat *srcaddr; + GLbyte srcpixels[4][4]; + GLbyte *blkaddr; + GLint dstRowDiff; + ASSERT(dstFormat == MESA_FORMAT_SIGNED_RED_RGTC1 || + dstFormat == MESA_FORMAT_SIGNED_L_LATC1); + ASSERT(dstXoffset % 4 == 0); + ASSERT(dstYoffset % 4 == 0); + ASSERT(dstZoffset % 4 == 0); + (void) dstZoffset; + (void) dstImageOffsets; + + tempImage = _mesa_make_temp_float_image(ctx, dims, + baseInternalFormat, + _mesa_get_format_base_format(dstFormat), + srcWidth, srcHeight, srcDepth, + srcFormat, srcType, srcAddr, + srcPacking, 0x0); + if (!tempImage) + return GL_FALSE; /* out of memory */ + + dst = (GLbyte *)_mesa_compressed_image_address(dstXoffset, dstYoffset, 0, + dstFormat, + texWidth, (GLubyte *) dstAddr); + + blkaddr = dst; + dstRowDiff = dstRowStride >= (srcWidth * 4) ? dstRowStride - (((srcWidth + 3) & ~3) * 4) : 0; + for (j = 0; j < srcHeight; j+=4) { + if (srcHeight > j + 3) numypixels = 4; + else numypixels = srcHeight - j; + srcaddr = tempImage + j * srcWidth; + for (i = 0; i < srcWidth; i += 4) { + if (srcWidth > i + 3) numxpixels = 4; + else numxpixels = srcWidth - i; + extractsrc_s(srcpixels, srcaddr, srcWidth, numxpixels, numypixels, 1); + signed_encode_rgtc_chan(blkaddr, srcpixels, numxpixels, numypixels); + srcaddr += numxpixels; + blkaddr += 8; + } + blkaddr += dstRowDiff; + } + if (tempImage) + free((void *) tempImage); + + return GL_TRUE; +} + +GLboolean +_mesa_texstore_rg_rgtc2(TEXSTORE_PARAMS) +{ + GLubyte *dst; + const GLint texWidth = dstRowStride * 4 / 16; /* a bit of a hack */ + const GLchan *tempImage = NULL; + int i, j; + int numxpixels, numypixels; + const GLchan *srcaddr; + GLubyte srcpixels[4][4]; + GLubyte *blkaddr; + GLint dstRowDiff; + + ASSERT(dstFormat == MESA_FORMAT_RG_RGTC2 || + dstFormat == MESA_FORMAT_LA_LATC2); + ASSERT(dstXoffset % 4 == 0); + ASSERT(dstYoffset % 4 == 0); + ASSERT(dstZoffset % 4 == 0); + (void) dstZoffset; + (void) dstImageOffsets; + + tempImage = _mesa_make_temp_chan_image(ctx, dims, + baseInternalFormat, + _mesa_get_format_base_format(dstFormat), + srcWidth, srcHeight, srcDepth, + srcFormat, srcType, srcAddr, + srcPacking); + if (!tempImage) + return GL_FALSE; /* out of memory */ + + dst = _mesa_compressed_image_address(dstXoffset, dstYoffset, 0, + dstFormat, + texWidth, (GLubyte *) dstAddr); + + blkaddr = dst; + dstRowDiff = dstRowStride >= (srcWidth * 8) ? dstRowStride - (((srcWidth + 7) & ~7) * 8) : 0; + for (j = 0; j < srcHeight; j+=4) { + if (srcHeight > j + 3) numypixels = 4; + else numypixels = srcHeight - j; + srcaddr = tempImage + j * srcWidth * 2; + for (i = 0; i < srcWidth; i += 4) { + if (srcWidth > i + 3) numxpixels = 4; + else numxpixels = srcWidth - i; + extractsrc_u(srcpixels, srcaddr, srcWidth, numxpixels, numypixels, 2); + unsigned_encode_rgtc_chan(blkaddr, srcpixels, numxpixels, numypixels); + + blkaddr += 8; + extractsrc_u(srcpixels, (GLchan *)srcaddr + 1, srcWidth, numxpixels, numypixels, 2); + unsigned_encode_rgtc_chan(blkaddr, srcpixels, numxpixels, numypixels); + + blkaddr += 8; + + srcaddr += numxpixels * 2; + } + blkaddr += dstRowDiff; + } + if (tempImage) + free((void *) tempImage); + + return GL_TRUE; +} + +GLboolean +_mesa_texstore_signed_rg_rgtc2(TEXSTORE_PARAMS) +{ + GLbyte *dst; + const GLint texWidth = dstRowStride * 4 / 16; /* a bit of a hack */ + const GLfloat *tempImage = NULL; + int i, j; + int numxpixels, numypixels; + const GLfloat *srcaddr; + GLbyte srcpixels[4][4]; + GLbyte *blkaddr; + GLint dstRowDiff; + + ASSERT(dstFormat == MESA_FORMAT_SIGNED_RG_RGTC2 || + dstFormat == MESA_FORMAT_SIGNED_LA_LATC2); + ASSERT(dstXoffset % 4 == 0); + ASSERT(dstYoffset % 4 == 0); + ASSERT(dstZoffset % 4 == 0); + (void) dstZoffset; + (void) dstImageOffsets; + + tempImage = _mesa_make_temp_float_image(ctx, dims, + baseInternalFormat, + _mesa_get_format_base_format(dstFormat), + srcWidth, srcHeight, srcDepth, + srcFormat, srcType, srcAddr, + srcPacking, 0x0); + if (!tempImage) + return GL_FALSE; /* out of memory */ + + dst = (GLbyte *)_mesa_compressed_image_address(dstXoffset, dstYoffset, 0, + dstFormat, + texWidth, (GLubyte *) dstAddr); + + blkaddr = dst; + dstRowDiff = dstRowStride >= (srcWidth * 8) ? dstRowStride - (((srcWidth + 7) & ~7) * 8) : 0; + for (j = 0; j < srcHeight; j += 4) { + if (srcHeight > j + 3) numypixels = 4; + else numypixels = srcHeight - j; + srcaddr = tempImage + j * srcWidth * 2; + for (i = 0; i < srcWidth; i += 4) { + if (srcWidth > i + 3) numxpixels = 4; + else numxpixels = srcWidth - i; + + extractsrc_s(srcpixels, srcaddr, srcWidth, numxpixels, numypixels, 2); + signed_encode_rgtc_chan(blkaddr, srcpixels, numxpixels, numypixels); + blkaddr += 8; + + extractsrc_s(srcpixels, srcaddr + 1, srcWidth, numxpixels, numypixels, 2); + signed_encode_rgtc_chan(blkaddr, srcpixels, numxpixels, numypixels); + blkaddr += 8; + + srcaddr += numxpixels * 2; + + } + blkaddr += dstRowDiff; + } + if (tempImage) + free((void *) tempImage); + + return GL_TRUE; +} + +void +_mesa_fetch_texel_2d_f_red_rgtc1(const struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, GLfloat *texel) +{ + GLubyte red; + unsigned_fetch_texel_rgtc(texImage->RowStride, (GLubyte *)(texImage->Data), + i, j, &red, 1); + texel[RCOMP] = UBYTE_TO_FLOAT(red); + texel[GCOMP] = 0.0; + texel[BCOMP] = 0.0; + texel[ACOMP] = 1.0; +} + +void +_mesa_fetch_texel_2d_f_signed_red_rgtc1(const struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, GLfloat *texel) +{ + GLbyte red; + signed_fetch_texel_rgtc(texImage->RowStride, (GLbyte *)(texImage->Data), + i, j, &red, 1); + texel[RCOMP] = BYTE_TO_FLOAT_TEX(red); + texel[GCOMP] = 0.0; + texel[BCOMP] = 0.0; + texel[ACOMP] = 1.0; +} + +void +_mesa_fetch_texel_2d_f_rg_rgtc2(const struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, GLfloat *texel) +{ + GLubyte red, green; + unsigned_fetch_texel_rgtc(texImage->RowStride, (GLubyte *)(texImage->Data), + i, j, &red, 2); + unsigned_fetch_texel_rgtc(texImage->RowStride, (GLubyte *)(texImage->Data) + 8, + i, j, &green, 2); + texel[RCOMP] = UBYTE_TO_FLOAT(red); + texel[GCOMP] = UBYTE_TO_FLOAT(green); + texel[BCOMP] = 0.0; + texel[ACOMP] = 1.0; +} + +void +_mesa_fetch_texel_2d_f_signed_rg_rgtc2(const struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, GLfloat *texel) +{ + GLbyte red, green; + signed_fetch_texel_rgtc(texImage->RowStride, (GLbyte *)(texImage->Data), + i, j, &red, 2); + signed_fetch_texel_rgtc(texImage->RowStride, (GLbyte *)(texImage->Data) + 8, + i, j, &green, 2); + texel[RCOMP] = BYTE_TO_FLOAT_TEX(red); + texel[GCOMP] = BYTE_TO_FLOAT_TEX(green); + texel[BCOMP] = 0.0; + texel[ACOMP] = 1.0; +} + +void +_mesa_fetch_texel_2d_f_l_latc1(const struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, GLfloat *texel) +{ + GLubyte red; + unsigned_fetch_texel_rgtc(texImage->RowStride, (GLubyte *)(texImage->Data), + i, j, &red, 1); + texel[RCOMP] = + texel[GCOMP] = + texel[BCOMP] = UBYTE_TO_FLOAT(red); + texel[ACOMP] = 1.0; +} + +void +_mesa_fetch_texel_2d_f_signed_l_latc1(const struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, GLfloat *texel) +{ + GLbyte red; + signed_fetch_texel_rgtc(texImage->RowStride, (GLbyte *)(texImage->Data), + i, j, &red, 1); + texel[RCOMP] = + texel[GCOMP] = + texel[BCOMP] = BYTE_TO_FLOAT_TEX(red); + texel[ACOMP] = 1.0; +} + +void +_mesa_fetch_texel_2d_f_la_latc2(const struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, GLfloat *texel) +{ + GLubyte red, green; + unsigned_fetch_texel_rgtc(texImage->RowStride, (GLubyte *)(texImage->Data), + i, j, &red, 2); + unsigned_fetch_texel_rgtc(texImage->RowStride, (GLubyte *)(texImage->Data) + 8, + i, j, &green, 2); + texel[RCOMP] = + texel[GCOMP] = + texel[BCOMP] = UBYTE_TO_FLOAT(red); + texel[ACOMP] = UBYTE_TO_FLOAT(green); +} + +void +_mesa_fetch_texel_2d_f_signed_la_latc2(const struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, GLfloat *texel) +{ + GLbyte red, green; + signed_fetch_texel_rgtc(texImage->RowStride, (GLbyte *)(texImage->Data), + i, j, &red, 2); + signed_fetch_texel_rgtc(texImage->RowStride, (GLbyte *)(texImage->Data) + 8, + i, j, &green, 2); + texel[RCOMP] = + texel[GCOMP] = + texel[BCOMP] = BYTE_TO_FLOAT_TEX(red); + texel[ACOMP] = BYTE_TO_FLOAT_TEX(green); +} + +#define TAG(x) unsigned_##x + +#define TYPE GLubyte +#define T_MIN 0 +#define T_MAX 0xff + +#include "texcompress_rgtc_tmp.h" + +#undef TAG +#undef TYPE +#undef T_MIN +#undef T_MAX + +#define TAG(x) signed_##x +#define TYPE GLbyte +#define T_MIN (GLbyte)-128 +#define T_MAX (GLbyte)127 + +#include "texcompress_rgtc_tmp.h" + +#undef TAG +#undef TYPE +#undef T_MIN +#undef T_MAX diff --git a/src/mesa/main/texcompress_rgtc.h b/src/mesa/main/texcompress_rgtc.h new file mode 100644 index 0000000000..18766770d7 --- /dev/null +++ b/src/mesa/main/texcompress_rgtc.h @@ -0,0 +1,77 @@ +/* + * Copyright (C) 2011 Red Hat Inc. + * + * Permission is hereby granted, free of charge, to any person obtaining a + * copy of this software and associated documentation files (the "Software"), + * to deal in the Software without restriction, including without limitation + * the rights to use, copy, modify, merge, publish, distribute, sublicense, + * and/or sell copies of the Software, and to permit persons to whom the + * Software is furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice (including the next + * paragraph) shall be included in all copies or substantial portions of the + * Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL + * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER + * DEALINGS IN THE SOFTWARE. + */ + +#ifndef TEXCOMPRESS_RGTC_H +#define TEXCOMPRESS_RGTC_H + +#include "glheader.h" +#include "mfeatures.h" +#include "texstore.h" + +struct gl_texture_image; + +extern GLboolean +_mesa_texstore_red_rgtc1(TEXSTORE_PARAMS); + +extern GLboolean +_mesa_texstore_signed_red_rgtc1(TEXSTORE_PARAMS); + +extern GLboolean +_mesa_texstore_rg_rgtc2(TEXSTORE_PARAMS); + +extern GLboolean +_mesa_texstore_signed_rg_rgtc2(TEXSTORE_PARAMS); + +extern void +_mesa_fetch_texel_2d_f_red_rgtc1(const struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, GLfloat *texel); + +extern void +_mesa_fetch_texel_2d_f_signed_red_rgtc1(const struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, GLfloat *texel); + +extern void +_mesa_fetch_texel_2d_f_rg_rgtc2(const struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, GLfloat *texel); + +extern void +_mesa_fetch_texel_2d_f_signed_rg_rgtc2(const struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, GLfloat *texel); + +extern void +_mesa_fetch_texel_2d_f_l_latc1(const struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, GLfloat *texel); + +extern void +_mesa_fetch_texel_2d_f_signed_l_latc1(const struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, GLfloat *texel); + +extern void +_mesa_fetch_texel_2d_f_la_latc2(const struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, GLfloat *texel); + +extern void +_mesa_fetch_texel_2d_f_signed_la_latc2(const struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, GLfloat *texel); + +#endif diff --git a/src/mesa/main/texcompress_rgtc_tmp.h b/src/mesa/main/texcompress_rgtc_tmp.h new file mode 100644 index 0000000000..c8bf082a15 --- /dev/null +++ b/src/mesa/main/texcompress_rgtc_tmp.h @@ -0,0 +1,418 @@ +/* + * Copyright (C) 2011 Red Hat Inc. + * + * block compression parts are: + * Copyright (C) 2004 Roland Scheidegger All Rights Reserved. + * + * Permission is hereby granted, free of charge, to any person obtaining a + * copy of this software and associated documentation files (the "Software"), + * to deal in the Software without restriction, including without limitation + * the rights to use, copy, modify, merge, publish, distribute, sublicense, + * and/or sell copies of the Software, and to permit persons to whom the + * Software is furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice (including the next + * paragraph) shall be included in all copies or substantial portions of the + * Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL + * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER + * DEALINGS IN THE SOFTWARE. + * + * Author: + * Dave Airlie + */ + +/* included by texcompress_rgtc to define byte/ubyte compressors */ + +static void TAG(fetch_texel_rgtc)(unsigned srcRowStride, const TYPE *pixdata, + unsigned i, unsigned j, TYPE *value, unsigned comps) +{ + TYPE decode; + const TYPE *blksrc = (pixdata + ((srcRowStride + 3) / 4 * (j / 4) + (i / 4)) * 8 * comps); + const TYPE alpha0 = blksrc[0]; + const TYPE alpha1 = blksrc[1]; + const char bit_pos = ((j&3) * 4 + (i&3)) * 3; + const TYPE acodelow = blksrc[2 + bit_pos / 8]; + const TYPE acodehigh = (3 + bit_pos / 8) < 8 ? blksrc[3 + bit_pos / 8] : 0; + const TYPE code = (acodelow >> (bit_pos & 0x7) | + (acodehigh << (8 - (bit_pos & 0x7)))) & 0x7; + + if (code == 0) + decode = alpha0; + else if (code == 1) + decode = alpha1; + else if (alpha0 > alpha1) + decode = ((alpha0 * (8 - code) + (alpha1 * (code - 1))) / 7); + else if (code < 6) + decode = ((alpha0 * (6 - code) + (alpha1 * (code - 1))) / 5); + else if (code == 6) + decode = T_MIN; + else + decode = T_MAX; + + *value = decode; +} + +static void TAG(write_rgtc_encoded_channel)(TYPE *blkaddr, + TYPE alphabase1, + TYPE alphabase2, + TYPE alphaenc[16]) +{ + *blkaddr++ = alphabase1; + *blkaddr++ = alphabase2; + *blkaddr++ = alphaenc[0] | (alphaenc[1] << 3) | ((alphaenc[2] & 3) << 6); + *blkaddr++ = (alphaenc[2] >> 2) | (alphaenc[3] << 1) | (alphaenc[4] << 4) | ((alphaenc[5] & 1) << 7); + *blkaddr++ = (alphaenc[5] >> 1) | (alphaenc[6] << 2) | (alphaenc[7] << 5); + *blkaddr++ = alphaenc[8] | (alphaenc[9] << 3) | ((alphaenc[10] & 3) << 6); + *blkaddr++ = (alphaenc[10] >> 2) | (alphaenc[11] << 1) | (alphaenc[12] << 4) | ((alphaenc[13] & 1) << 7); + *blkaddr++ = (alphaenc[13] >> 1) | (alphaenc[14] << 2) | (alphaenc[15] << 5); +} + +static void TAG(encode_rgtc_chan)(TYPE *blkaddr, TYPE srccolors[4][4], + int numxpixels, int numypixels) +{ + TYPE alphabase[2], alphause[2]; + short alphatest[2] = { 0 }; + unsigned int alphablockerror1, alphablockerror2, alphablockerror3; + TYPE i, j, aindex, acutValues[7]; + TYPE alphaenc1[16], alphaenc2[16], alphaenc3[16]; + int alphaabsmin = 0, alphaabsmax = 0; + short alphadist; + + /* find lowest and highest alpha value in block, alphabase[0] lowest, alphabase[1] highest */ + alphabase[0] = T_MAX; alphabase[1] = T_MIN; + for (j = 0; j < numypixels; j++) { + for (i = 0; i < numxpixels; i++) { + if (srccolors[j][i] == T_MIN) + alphaabsmin = 1; + else if (srccolors[j][i] == T_MAX) + alphaabsmax = 1; + else { + if (srccolors[j][i] > alphabase[1]) + alphabase[1] = srccolors[j][i]; + if (srccolors[j][i] < alphabase[0]) + alphabase[0] = srccolors[j][i]; + } + } + } + + + if (((alphabase[0] > alphabase[1]) && !(alphaabsmin && alphaabsmax)) + || (alphabase[0] == alphabase[1] && !alphaabsmin && !alphaabsmax)) { /* one color, either max or min */ + /* shortcut here since it is a very common case (and also avoids later problems) */ + /* could also thest for alpha0 == alpha1 (and not min/max), but probably not common, so don't bother */ + + *blkaddr++ = srccolors[0][0]; + blkaddr++; + *blkaddr++ = 0; + *blkaddr++ = 0; + *blkaddr++ = 0; + *blkaddr++ = 0; + *blkaddr++ = 0; + *blkaddr++ = 0; +#if RGTC_DEBUG + fprintf(stderr, "enc0 used\n"); +#endif + return; + } + + /* find best encoding for alpha0 > alpha1 */ + /* it's possible this encoding is better even if both alphaabsmin and alphaabsmax are true */ + alphablockerror1 = 0x0; + alphablockerror2 = 0xffffffff; + alphablockerror3 = 0xffffffff; + if (alphaabsmin) alphause[0] = T_MIN; + else alphause[0] = alphabase[0]; + if (alphaabsmax) alphause[1] = T_MAX; + else alphause[1] = alphabase[1]; + /* calculate the 7 cut values, just the middle between 2 of the computed alpha values */ + for (aindex = 0; aindex < 7; aindex++) { + /* don't forget here is always rounded down */ + acutValues[aindex] = (alphause[0] * (2*aindex + 1) + alphause[1] * (14 - (2*aindex + 1))) / 14; + } + + for (j = 0; j < numypixels; j++) { + for (i = 0; i < numxpixels; i++) { + /* maybe it's overkill to have the most complicated calculation just for the error + calculation which we only need to figure out if encoding1 or encoding2 is better... */ + if (srccolors[j][i] > acutValues[0]) { + alphaenc1[4*j + i] = 0; + alphadist = srccolors[j][i] - alphause[1]; + } + else if (srccolors[j][i] > acutValues[1]) { + alphaenc1[4*j + i] = 2; + alphadist = srccolors[j][i] - (alphause[1] * 6 + alphause[0] * 1) / 7; + } + else if (srccolors[j][i] > acutValues[2]) { + alphaenc1[4*j + i] = 3; + alphadist = srccolors[j][i] - (alphause[1] * 5 + alphause[0] * 2) / 7; + } + else if (srccolors[j][i] > acutValues[3]) { + alphaenc1[4*j + i] = 4; + alphadist = srccolors[j][i] - (alphause[1] * 4 + alphause[0] * 3) / 7; + } + else if (srccolors[j][i] > acutValues[4]) { + alphaenc1[4*j + i] = 5; + alphadist = srccolors[j][i] - (alphause[1] * 3 + alphause[0] * 4) / 7; + } + else if (srccolors[j][i] > acutValues[5]) { + alphaenc1[4*j + i] = 6; + alphadist = srccolors[j][i] - (alphause[1] * 2 + alphause[0] * 5) / 7; + } + else if (srccolors[j][i] > acutValues[6]) { + alphaenc1[4*j + i] = 7; + alphadist = srccolors[j][i] - (alphause[1] * 1 + alphause[0] * 6) / 7; + } + else { + alphaenc1[4*j + i] = 1; + alphadist = srccolors[j][i] - alphause[0]; + } + alphablockerror1 += alphadist * alphadist; + } + } + +#if RGTC_DEBUG + for (i = 0; i < 16; i++) { + fprintf(stderr, "%d ", alphaenc1[i]); + } + fprintf(stderr, "cutVals "); + for (i = 0; i < 8; i++) { + fprintf(stderr, "%d ", acutValues[i]); + } + fprintf(stderr, "srcVals "); + for (j = 0; j < numypixels; j++) { + for (i = 0; i < numxpixels; i++) { + fprintf(stderr, "%d ", srccolors[j][i]); + } + } + fprintf(stderr, "\n"); +#endif + + /* it's not very likely this encoding is better if both alphaabsmin and alphaabsmax + are false but try it anyway */ + if (alphablockerror1 >= 32) { + + /* don't bother if encoding is already very good, this condition should also imply + we have valid alphabase colors which we absolutely need (alphabase[0] <= alphabase[1]) */ + alphablockerror2 = 0; + for (aindex = 0; aindex < 5; aindex++) { + /* don't forget here is always rounded down */ + acutValues[aindex] = (alphabase[0] * (10 - (2*aindex + 1)) + alphabase[1] * (2*aindex + 1)) / 10; + } + for (j = 0; j < numypixels; j++) { + for (i = 0; i < numxpixels; i++) { + /* maybe it's overkill to have the most complicated calculation just for the error + calculation which we only need to figure out if encoding1 or encoding2 is better... */ + if (srccolors[j][i] == T_MIN) { + alphaenc2[4*j + i] = 6; + alphadist = 0; + } + else if (srccolors[j][i] == T_MAX) { + alphaenc2[4*j + i] = 7; + alphadist = 0; + } + else if (srccolors[j][i] <= acutValues[0]) { + alphaenc2[4*j + i] = 0; + alphadist = srccolors[j][i] - alphabase[0]; + } + else if (srccolors[j][i] <= acutValues[1]) { + alphaenc2[4*j + i] = 2; + alphadist = srccolors[j][i] - (alphabase[0] * 4 + alphabase[1] * 1) / 5; + } + else if (srccolors[j][i] <= acutValues[2]) { + alphaenc2[4*j + i] = 3; + alphadist = srccolors[j][i] - (alphabase[0] * 3 + alphabase[1] * 2) / 5; + } + else if (srccolors[j][i] <= acutValues[3]) { + alphaenc2[4*j + i] = 4; + alphadist = srccolors[j][i] - (alphabase[0] * 2 + alphabase[1] * 3) / 5; + } + else if (srccolors[j][i] <= acutValues[4]) { + alphaenc2[4*j + i] = 5; + alphadist = srccolors[j][i] - (alphabase[0] * 1 + alphabase[1] * 4) / 5; + } + else { + alphaenc2[4*j + i] = 1; + alphadist = srccolors[j][i] - alphabase[1]; + } + alphablockerror2 += alphadist * alphadist; + } + } + + + /* skip this if the error is already very small + this encoding is MUCH better on average than #2 though, but expensive! */ + if ((alphablockerror2 > 96) && (alphablockerror1 > 96)) { + short blockerrlin1 = 0; + short blockerrlin2 = 0; + TYPE nralphainrangelow = 0; + TYPE nralphainrangehigh = 0; + alphatest[0] = T_MAX; + alphatest[1] = T_MIN; + /* if we have large range it's likely there are values close to 0/255, try to map them to 0/255 */ + for (j = 0; j < numypixels; j++) { + for (i = 0; i < numxpixels; i++) { + if ((srccolors[j][i] > alphatest[1]) && (srccolors[j][i] < (T_MAX -(alphabase[1] - alphabase[0]) / 28))) + alphatest[1] = srccolors[j][i]; + if ((srccolors[j][i] < alphatest[0]) && (srccolors[j][i] > (alphabase[1] - alphabase[0]) / 28)) + alphatest[0] = srccolors[j][i]; + } + } + /* shouldn't happen too often, don't really care about those degenerated cases */ + if (alphatest[1] <= alphatest[0]) { + alphatest[0] = T_MIN+1; + alphatest[1] = T_MAX-1; + } + for (aindex = 0; aindex < 5; aindex++) { + /* don't forget here is always rounded down */ + acutValues[aindex] = (alphatest[0] * (10 - (2*aindex + 1)) + alphatest[1] * (2*aindex + 1)) / 10; + } + + /* find the "average" difference between the alpha values and the next encoded value. + This is then used to calculate new base values. + Should there be some weighting, i.e. those values closer to alphatest[x] have more weight, + since they will see more improvement, and also because the values in the middle are somewhat + likely to get no improvement at all (because the base values might move in different directions)? + OTOH it would mean the values in the middle are even less likely to get an improvement + */ + for (j = 0; j < numypixels; j++) { + for (i = 0; i < numxpixels; i++) { + if (srccolors[j][i] <= alphatest[0] / 2) { + } + else if (srccolors[j][i] > ((T_MAX + alphatest[1]) / 2)) { + } + else if (srccolors[j][i] <= acutValues[0]) { + blockerrlin1 += (srccolors[j][i] - alphatest[0]); + nralphainrangelow += 1; + } + else if (srccolors[j][i] <= acutValues[1]) { + blockerrlin1 += (srccolors[j][i] - (alphatest[0] * 4 + alphatest[1] * 1) / 5); + blockerrlin2 += (srccolors[j][i] - (alphatest[0] * 4 + alphatest[1] * 1) / 5); + nralphainrangelow += 1; + nralphainrangehigh += 1; + } + else if (srccolors[j][i] <= acutValues[2]) { + blockerrlin1 += (srccolors[j][i] - (alphatest[0] * 3 + alphatest[1] * 2) / 5); + blockerrlin2 += (srccolors[j][i] - (alphatest[0] * 3 + alphatest[1] * 2) / 5); + nralphainrangelow += 1; + nralphainrangehigh += 1; + } + else if (srccolors[j][i] <= acutValues[3]) { + blockerrlin1 += (srccolors[j][i] - (alphatest[0] * 2 + alphatest[1] * 3) / 5); + blockerrlin2 += (srccolors[j][i] - (alphatest[0] * 2 + alphatest[1] * 3) / 5); + nralphainrangelow += 1; + nralphainrangehigh += 1; + } + else if (srccolors[j][i] <= acutValues[4]) { + blockerrlin1 += (srccolors[j][i] - (alphatest[0] * 1 + alphatest[1] * 4) / 5); + blockerrlin2 += (srccolors[j][i] - (alphatest[0] * 1 + alphatest[1] * 4) / 5); + nralphainrangelow += 1; + nralphainrangehigh += 1; + } + else { + blockerrlin2 += (srccolors[j][i] - alphatest[1]); + nralphainrangehigh += 1; + } + } + } + /* shouldn't happen often, needed to avoid div by zero */ + if (nralphainrangelow == 0) nralphainrangelow = 1; + if (nralphainrangehigh == 0) nralphainrangehigh = 1; + alphatest[0] = alphatest[0] + (blockerrlin1 / nralphainrangelow); +#if RGTC_DEBUG + fprintf(stderr, "block err lin low %d, nr %d\n", blockerrlin1, nralphainrangelow); + fprintf(stderr, "block err lin high %d, nr %d\n", blockerrlin2, nralphainrangehigh); +#endif + /* again shouldn't really happen often... */ + if (alphatest[0] < T_MIN) { + alphatest[0] = T_MIN; + } + alphatest[1] = alphatest[1] + (blockerrlin2 / nralphainrangehigh); + if (alphatest[1] > T_MAX) { + alphatest[1] = T_MAX; + } + + alphablockerror3 = 0; + for (aindex = 0; aindex < 5; aindex++) { + /* don't forget here is always rounded down */ + acutValues[aindex] = (alphatest[0] * (10 - (2*aindex + 1)) + alphatest[1] * (2*aindex + 1)) / 10; + } + for (j = 0; j < numypixels; j++) { + for (i = 0; i < numxpixels; i++) { + /* maybe it's overkill to have the most complicated calculation just for the error + calculation which we only need to figure out if encoding1 or encoding2 is better... */ + if (srccolors[j][i] <= alphatest[0] / 2) { + alphaenc3[4*j + i] = 6; + alphadist = srccolors[j][i]; + } + else if (srccolors[j][i] > ((T_MAX + alphatest[1]) / 2)) { + alphaenc3[4*j + i] = 7; + alphadist = T_MAX - srccolors[j][i]; + } + else if (srccolors[j][i] <= acutValues[0]) { + alphaenc3[4*j + i] = 0; + alphadist = srccolors[j][i] - alphatest[0]; + } + else if (srccolors[j][i] <= acutValues[1]) { + alphaenc3[4*j + i] = 2; + alphadist = srccolors[j][i] - (alphatest[0] * 4 + alphatest[1] * 1) / 5; + } + else if (srccolors[j][i] <= acutValues[2]) { + alphaenc3[4*j + i] = 3; + alphadist = srccolors[j][i] - (alphatest[0] * 3 + alphatest[1] * 2) / 5; + } + else if (srccolors[j][i] <= acutValues[3]) { + alphaenc3[4*j + i] = 4; + alphadist = srccolors[j][i] - (alphatest[0] * 2 + alphatest[1] * 3) / 5; + } + else if (srccolors[j][i] <= acutValues[4]) { + alphaenc3[4*j + i] = 5; + alphadist = srccolors[j][i] - (alphatest[0] * 1 + alphatest[1] * 4) / 5; + } + else { + alphaenc3[4*j + i] = 1; + alphadist = srccolors[j][i] - alphatest[1]; + } + alphablockerror3 += alphadist * alphadist; + } + } + } + } + + /* write the alpha values and encoding back. */ + if ((alphablockerror1 <= alphablockerror2) && (alphablockerror1 <= alphablockerror3)) { +#if RGTC_DEBUG + if (alphablockerror1 > 96) fprintf(stderr, "enc1 used, error %d\n", alphablockerror1); + fprintf(stderr,"w1: min %d max %d au0 %d au1 %d\n", + T_MIN, T_MAX, + alphause[1], alphause[0]); +#endif + + TAG(write_rgtc_encoded_channel)( blkaddr, alphause[1], alphause[0], alphaenc1 ); + } + else if (alphablockerror2 <= alphablockerror3) { +#if RGTC_DEBUG + if (alphablockerror2 > 96) fprintf(stderr, "enc2 used, error %d\n", alphablockerror2); + fprintf(stderr,"w2: min %d max %d au0 %d au1 %d\n", + T_MIN, T_MAX, + alphabase[0], alphabase[1]); +#endif + + TAG(write_rgtc_encoded_channel)( blkaddr, alphabase[0], alphabase[1], alphaenc2 ); + } + else { +#if RGTC_DEBUG + fprintf(stderr, "enc3 used, error %d\n", alphablockerror3); + fprintf(stderr,"w3: min %d max %d au0 %d au1 %d\n", + T_MIN, T_MAX, + alphatest[0], alphatest[1]); +#endif + + TAG(write_rgtc_encoded_channel)( blkaddr, (TYPE)alphatest[0], (TYPE)alphatest[1], alphaenc3 ); + } +} diff --git a/src/mesa/main/texcompress_s3tc.c b/src/mesa/main/texcompress_s3tc.c index 0e893a59fa..25257ecc3d 100644 --- a/src/mesa/main/texcompress_s3tc.c +++ b/src/mesa/main/texcompress_s3tc.c @@ -39,6 +39,8 @@ #include "dlopen.h" #include "image.h" #include "macros.h" +#include "mfeatures.h" +#include "mtypes.h" #include "texcompress.h" #include "texcompress_s3tc.h" #include "texstore.h" diff --git a/src/mesa/main/texenv.c b/src/mesa/main/texenv.c index 508dbf4887..194bcbea98 100644 --- a/src/mesa/main/texenv.c +++ b/src/mesa/main/texenv.c @@ -34,6 +34,7 @@ #include "main/context.h" #include "main/enums.h" #include "main/macros.h" +#include "main/mtypes.h" #include "main/texenv.h" #include "main/texstate.h" diff --git a/src/mesa/main/texfetch.c b/src/mesa/main/texfetch.c index 372ef2654a..988a7e0546 100644 --- a/src/mesa/main/texfetch.c +++ b/src/mesa/main/texfetch.c @@ -38,7 +38,9 @@ #include "texcompress.h" #include "texcompress_fxt1.h" #include "texcompress_s3tc.h" +#include "texcompress_rgtc.h" #include "texfetch.h" +#include "teximage.h" /** @@ -237,6 +239,13 @@ texfetch_funcs[MESA_FORMAT_COUNT] = store_texel_argb1555_rev }, { + MESA_FORMAT_AL44, + fetch_texel_1d_f_al44, + fetch_texel_2d_f_al44, + fetch_texel_3d_f_al44, + store_texel_al44 + }, + { MESA_FORMAT_AL88, fetch_texel_1d_f_al88, fetch_texel_2d_f_al88, @@ -279,6 +288,13 @@ texfetch_funcs[MESA_FORMAT_COUNT] = store_texel_a8 }, { + MESA_FORMAT_A16, + fetch_texel_1d_f_a16, + fetch_texel_2d_f_a16, + fetch_texel_3d_f_a16, + store_texel_a16 + }, + { MESA_FORMAT_L8, fetch_texel_1d_f_l8, fetch_texel_2d_f_l8, @@ -286,6 +302,13 @@ texfetch_funcs[MESA_FORMAT_COUNT] = store_texel_l8 }, { + MESA_FORMAT_L16, + fetch_texel_1d_f_l16, + fetch_texel_2d_f_l16, + fetch_texel_3d_f_l16, + store_texel_l16 + }, + { MESA_FORMAT_I8, fetch_texel_1d_f_i8, fetch_texel_2d_f_i8, @@ -293,6 +316,13 @@ texfetch_funcs[MESA_FORMAT_COUNT] = store_texel_i8 }, { + MESA_FORMAT_I16, + fetch_texel_1d_f_i16, + fetch_texel_2d_f_i16, + fetch_texel_3d_f_i16, + store_texel_i16 + }, + { MESA_FORMAT_CI8, fetch_texel_1d_f_ci8, fetch_texel_2d_f_ci8, @@ -356,6 +386,13 @@ texfetch_funcs[MESA_FORMAT_COUNT] = store_texel_rg1616_rev, }, { + MESA_FORMAT_ARGB2101010, + fetch_texel_1d_f_argb2101010, + fetch_texel_2d_f_argb2101010, + fetch_texel_3d_f_argb2101010, + store_texel_argb2101010 + }, + { MESA_FORMAT_Z24_S8, fetch_texel_1d_f_z24_s8, fetch_texel_2d_f_z24_s8, @@ -720,11 +757,67 @@ texfetch_funcs[MESA_FORMAT_COUNT] = fetch_texel_2d_rgba_16, fetch_texel_3d_rgba_16, store_texel_rgba_16 - } + }, + { + MESA_FORMAT_RED_RGTC1, + NULL, + _mesa_fetch_texel_2d_f_red_rgtc1, + NULL, + NULL + }, + { + MESA_FORMAT_SIGNED_RED_RGTC1, + NULL, + _mesa_fetch_texel_2d_f_signed_red_rgtc1, + NULL, + NULL + }, + { + MESA_FORMAT_RG_RGTC2, + NULL, + _mesa_fetch_texel_2d_f_rg_rgtc2, + NULL, + NULL + }, + { + MESA_FORMAT_SIGNED_RG_RGTC2, + NULL, + _mesa_fetch_texel_2d_f_signed_rg_rgtc2, + NULL, + NULL + }, + { + MESA_FORMAT_L_LATC1, + NULL, + _mesa_fetch_texel_2d_f_l_latc1, + NULL, + NULL + }, + { + MESA_FORMAT_SIGNED_L_LATC1, + NULL, + _mesa_fetch_texel_2d_f_signed_l_latc1, + NULL, + NULL + }, + { + MESA_FORMAT_LA_LATC2, + NULL, + _mesa_fetch_texel_2d_f_la_latc2, + NULL, + NULL + }, + { + MESA_FORMAT_SIGNED_LA_LATC2, + NULL, + _mesa_fetch_texel_2d_f_signed_la_latc2, + NULL, + NULL + }, }; -static FetchTexelFuncF +FetchTexelFuncF _mesa_get_texel_fetch_func(gl_format format, GLuint dims) { #ifdef DEBUG @@ -822,13 +915,36 @@ fetch_texel_chan_to_float(const struct gl_texture_image *texImage, void _mesa_set_fetch_functions(struct gl_texture_image *texImage, GLuint dims) { + gl_format format = texImage->TexFormat; + ASSERT(dims == 1 || dims == 2 || dims == 3); - texImage->FetchTexelf = - _mesa_get_texel_fetch_func(texImage->TexFormat, dims); + if (texImage->TexObject->sRGBDecode == GL_SKIP_DECODE_EXT && + _mesa_get_format_color_encoding(format) == GL_SRGB) { + format = _mesa_get_srgb_format_linear(format); + } + + texImage->FetchTexelf = _mesa_get_texel_fetch_func(format, dims); texImage->FetchTexelc = fetch_texel_float_to_chan; ASSERT(texImage->FetchTexelc); ASSERT(texImage->FetchTexelf); } + +void +_mesa_update_fetch_functions(struct gl_texture_object *texObj) +{ + GLuint face, i; + GLuint dims; + + dims = _mesa_get_texture_dimensions(texObj->Target); + + for (face = 0; face < 6; face++) { + for (i = 0; i < MAX_TEXTURE_LEVELS; i++) { + if (texObj->Image[face][i]) { + _mesa_set_fetch_functions(texObj->Image[face][i], dims); + } + } + } +} diff --git a/src/mesa/main/texfetch.h b/src/mesa/main/texfetch.h index ef13bf27fe..002ff0c768 100644 --- a/src/mesa/main/texfetch.h +++ b/src/mesa/main/texfetch.h @@ -34,7 +34,12 @@ extern StoreTexelFunc _mesa_get_texel_store_func(gl_format format); +extern FetchTexelFuncF +_mesa_get_texel_fetch_func(gl_format format, GLuint dims); + extern void _mesa_set_fetch_functions(struct gl_texture_image *texImage, GLuint dims); +void +_mesa_update_fetch_functions(struct gl_texture_object *texObj); #endif diff --git a/src/mesa/main/texfetch_tmp.h b/src/mesa/main/texfetch_tmp.h index 2f583ed522..36dede57f0 100644 --- a/src/mesa/main/texfetch_tmp.h +++ b/src/mesa/main/texfetch_tmp.h @@ -135,7 +135,7 @@ static void store_texel_rgba_f32(struct gl_texture_image *texImage, GLint i, GLint j, GLint k, const void *texel) { const GLfloat *depth = (const GLfloat *) texel; - GLfloat *dst = TEXEL_ADDR(GLfloat, texImage, i, j, k, 1); + GLfloat *dst = TEXEL_ADDR(GLfloat, texImage, i, j, k, 4); dst[0] = depth[RCOMP]; dst[1] = depth[GCOMP]; dst[2] = depth[BCOMP]; @@ -163,9 +163,12 @@ static void FETCH(f_rgba_f16)( const struct gl_texture_image *texImage, static void store_texel_rgba_f16(struct gl_texture_image *texImage, GLint i, GLint j, GLint k, const void *texel) { - const GLfloat *depth = (const GLfloat *) texel; - GLhalfARB *dst = TEXEL_ADDR(GLhalfARB, texImage, i, j, k, 1); - dst[0] = _mesa_float_to_half(*depth); + const GLfloat *src = (const GLfloat *) texel; + GLhalfARB *dst = TEXEL_ADDR(GLhalfARB, texImage, i, j, k, 4); + dst[0] = _mesa_float_to_half(src[RCOMP]); + dst[1] = _mesa_float_to_half(src[GCOMP]); + dst[2] = _mesa_float_to_half(src[BCOMP]); + dst[3] = _mesa_float_to_half(src[ACOMP]); } #endif @@ -188,9 +191,11 @@ static void FETCH(f_rgb_f32)( const struct gl_texture_image *texImage, static void store_texel_rgb_f32(struct gl_texture_image *texImage, GLint i, GLint j, GLint k, const void *texel) { - const GLfloat *depth = (const GLfloat *) texel; - GLfloat *dst = TEXEL_ADDR(GLfloat, texImage, i, j, k, 1); - dst[0] = *depth; + const GLfloat *src = (const GLfloat *) texel; + GLfloat *dst = TEXEL_ADDR(GLfloat, texImage, i, j, k, 3); + dst[0] = src[RCOMP]; + dst[1] = src[GCOMP]; + dst[2] = src[BCOMP]; } #endif @@ -214,9 +219,11 @@ static void FETCH(f_rgb_f16)( const struct gl_texture_image *texImage, static void store_texel_rgb_f16(struct gl_texture_image *texImage, GLint i, GLint j, GLint k, const void *texel) { - const GLfloat *depth = (const GLfloat *) texel; - GLhalfARB *dst = TEXEL_ADDR(GLhalfARB, texImage, i, j, k, 1); - dst[0] = _mesa_float_to_half(*depth); + const GLfloat *src = (const GLfloat *) texel; + GLhalfARB *dst = TEXEL_ADDR(GLhalfARB, texImage, i, j, k, 3); + dst[0] = _mesa_float_to_half(src[RCOMP]); + dst[1] = _mesa_float_to_half(src[GCOMP]); + dst[2] = _mesa_float_to_half(src[BCOMP]); } #endif @@ -810,6 +817,31 @@ static void store_texel_argb1555_rev(struct gl_texture_image *texImage, #endif +/* MESA_FORMAT_ARGB2101010 ***************************************************/ + +/* Fetch texel from 1D, 2D or 3D argb2101010 texture, return 4 GLchans */ +static void FETCH(f_argb2101010)( const struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, GLfloat *texel ) +{ + const GLuint *src = TEXEL_ADDR(GLuint, texImage, i, j, k, 1); + const GLuint s = *src; + texel[RCOMP] = ((s >> 20) & 0x3ff) * (1.0F / 1023.0F); + texel[GCOMP] = ((s >> 10) & 0x3ff) * (1.0F / 1023.0F); + texel[BCOMP] = ((s >> 0) & 0x3ff) * (1.0F / 1023.0F); + texel[ACOMP] = ((s >> 30) & 0x03) * (1.0F / 3.0F); +} + +#if DIM == 3 +static void store_texel_argb2101010(struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, const void *texel) +{ + const GLubyte *rgba = (const GLubyte *) texel; + GLuint *dst = TEXEL_ADDR(GLuint, texImage, i, j, k, 1); + *dst = PACK_COLOR_2101010_UB(rgba[ACOMP], rgba[RCOMP], rgba[GCOMP], rgba[BCOMP]); +} +#endif + + /* MESA_FORMAT_RG88 **********************************************************/ /* Fetch texel from 1D, 2D or 3D rg88 texture, return 4 GLchans */ @@ -858,6 +890,30 @@ static void store_texel_rg88_rev(struct gl_texture_image *texImage, #endif +/* MESA_FORMAT_AL44 **********************************************************/ + +/* Fetch texel from 1D, 2D or 3D al44 texture, return 4 GLchans */ +static void FETCH(f_al44)( const struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, GLfloat *texel ) +{ + const GLubyte s = *TEXEL_ADDR(GLubyte, texImage, i, j, k, 1); + texel[RCOMP] = + texel[GCOMP] = + texel[BCOMP] = (s & 0xf) * (1.0F / 15.0F); + texel[ACOMP] = ((s >> 4) & 0xf) * (1.0F / 15.0F); +} + +#if DIM == 3 +static void store_texel_al44(struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, const void *texel) +{ + const GLubyte *rgba = (const GLubyte *) texel; + GLubyte *dst = TEXEL_ADDR(GLubyte, texImage, i, j, k, 1); + *dst = PACK_COLOR_44(rgba[ACOMP], rgba[RCOMP]); +} +#endif + + /* MESA_FORMAT_AL88 **********************************************************/ /* Fetch texel from 1D, 2D or 3D al88 texture, return 4 GLchans */ @@ -1099,6 +1155,30 @@ static void store_texel_a8(struct gl_texture_image *texImage, #endif +/* MESA_FORMAT_A16 ************************************************************/ + +/* Fetch texel from 1D, 2D or 3D a8 texture, return 4 GLchans */ +static void FETCH(f_a16)( const struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, GLfloat *texel ) +{ + const GLushort *src = TEXEL_ADDR(GLushort, texImage, i, j, k, 1); + texel[RCOMP] = + texel[GCOMP] = + texel[BCOMP] = 0.0F; + texel[ACOMP] = USHORT_TO_FLOAT( src[0] ); +} + +#if DIM == 3 +static void store_texel_a16(struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, const void *texel) +{ + const GLushort *rgba = (const GLushort *) texel; + GLushort *dst = TEXEL_ADDR(GLushort, texImage, i, j, k, 1); + *dst = rgba[ACOMP]; +} +#endif + + /* MESA_FORMAT_L8 ************************************************************/ /* Fetch texel from 1D, 2D or 3D l8 texture, return 4 GLchans */ @@ -1123,6 +1203,30 @@ static void store_texel_l8(struct gl_texture_image *texImage, #endif +/* MESA_FORMAT_L16 ***********************************************************/ + +/* Fetch texel from 1D, 2D or 3D l16 texture, return 4 GLchans */ +static void FETCH(f_l16)( const struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, GLfloat *texel ) +{ + const GLushort *src = TEXEL_ADDR(GLushort, texImage, i, j, k, 1); + texel[RCOMP] = + texel[GCOMP] = + texel[BCOMP] = USHORT_TO_FLOAT( src[0] ); + texel[ACOMP] = 1.0F; +} + +#if DIM == 3 +static void store_texel_l16(struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, const void *texel) +{ + const GLushort *rgba = (const GLushort *) texel; + GLushort *dst = TEXEL_ADDR(GLushort, texImage, i, j, k, 1); + *dst = rgba[RCOMP]; +} +#endif + + /* MESA_FORMAT_I8 ************************************************************/ /* Fetch texel from 1D, 2D or 3D i8 texture, return 4 GLchans */ @@ -1147,6 +1251,30 @@ static void store_texel_i8(struct gl_texture_image *texImage, #endif +/* MESA_FORMAT_I16 ***********************************************************/ + +/* Fetch texel from 1D, 2D or 3D i16 texture, return 4 GLchans */ +static void FETCH(f_i16)( const struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, GLfloat *texel ) +{ + const GLushort *src = TEXEL_ADDR(GLushort, texImage, i, j, k, 1); + texel[RCOMP] = + texel[GCOMP] = + texel[BCOMP] = + texel[ACOMP] = USHORT_TO_FLOAT( src[0] ); +} + +#if DIM == 3 +static void store_texel_i16(struct gl_texture_image *texImage, + GLint i, GLint j, GLint k, const void *texel) +{ + const GLushort *rgba = (const GLushort *) texel; + GLushort *dst = TEXEL_ADDR(GLushort, texImage, i, j, k, 1); + *dst = rgba[RCOMP]; +} +#endif + + /* MESA_FORMAT_CI8 ***********************************************************/ /* Fetch CI texel from 1D, 2D or 3D ci8 texture, lookup the index in a diff --git a/src/mesa/main/texformat.c b/src/mesa/main/texformat.c index 894c0130b4..5eabf2aa52 100644 --- a/src/mesa/main/texformat.c +++ b/src/mesa/main/texformat.c @@ -34,9 +34,15 @@ #include "context.h" +#include "mfeatures.h" +#include "mtypes.h" #include "texcompress.h" #include "texformat.h" +#define RETURN_IF_SUPPORTED(f) do { \ + if (ctx->TextureFormatSupported[f]) \ + return f; \ +} while (0) /** * Choose an appropriate texture format given the format, type and @@ -64,75 +70,132 @@ _mesa_choose_tex_format( struct gl_context *ctx, GLint internalFormat, /* shallow RGBA formats */ case 4: case GL_RGBA: + if (type == GL_UNSIGNED_SHORT_4_4_4_4_REV) { + RETURN_IF_SUPPORTED(MESA_FORMAT_ARGB4444); + } else if (type == GL_UNSIGNED_SHORT_1_5_5_5_REV) { + RETURN_IF_SUPPORTED(MESA_FORMAT_ARGB1555); + } + RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA8888); + RETURN_IF_SUPPORTED(MESA_FORMAT_ARGB8888); + break; + case GL_RGBA8: - return MESA_FORMAT_RGBA8888; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA8888); + RETURN_IF_SUPPORTED(MESA_FORMAT_ARGB8888); + break; case GL_RGB5_A1: - return MESA_FORMAT_ARGB1555; + RETURN_IF_SUPPORTED(MESA_FORMAT_ARGB1555); + break; case GL_RGBA2: - return MESA_FORMAT_ARGB4444_REV; /* just to test another format*/ + RETURN_IF_SUPPORTED(MESA_FORMAT_ARGB4444_REV); /* just to test another format*/ + RETURN_IF_SUPPORTED(MESA_FORMAT_ARGB4444); + break; case GL_RGBA4: - return MESA_FORMAT_ARGB4444; + RETURN_IF_SUPPORTED(MESA_FORMAT_ARGB4444); + break; /* deep RGBA formats */ case GL_RGB10_A2: + RETURN_IF_SUPPORTED(MESA_FORMAT_ARGB2101010); + RETURN_IF_SUPPORTED(MESA_FORMAT_ARGB8888); + break; case GL_RGBA12: case GL_RGBA16: - return MESA_FORMAT_RGBA_16; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA_16); + RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA_16); + RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA8888); + RETURN_IF_SUPPORTED(MESA_FORMAT_ARGB8888); + break; /* shallow RGB formats */ case 3: case GL_RGB: case GL_RGB8: - return MESA_FORMAT_RGB888; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGB888); + RETURN_IF_SUPPORTED(MESA_FORMAT_XRGB8888); + RETURN_IF_SUPPORTED(MESA_FORMAT_ARGB8888); + break; case GL_R3_G3_B2: - return MESA_FORMAT_RGB332; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGB332); + RETURN_IF_SUPPORTED(MESA_FORMAT_RGB888); + RETURN_IF_SUPPORTED(MESA_FORMAT_XRGB8888); + RETURN_IF_SUPPORTED(MESA_FORMAT_ARGB8888); + break; case GL_RGB4: - return MESA_FORMAT_RGB565_REV; /* just to test another format */ + RETURN_IF_SUPPORTED(MESA_FORMAT_RGB565_REV); /* just to test another format */ + RETURN_IF_SUPPORTED(MESA_FORMAT_RGB565); + break; case GL_RGB5: - return MESA_FORMAT_RGB565; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGB565); + break; /* deep RGB formats */ case GL_RGB10: case GL_RGB12: case GL_RGB16: - return MESA_FORMAT_RGBA_16; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA_16); + RETURN_IF_SUPPORTED(MESA_FORMAT_XRGB8888); + RETURN_IF_SUPPORTED(MESA_FORMAT_ARGB8888); + break; /* Alpha formats */ case GL_ALPHA: case GL_ALPHA4: + case GL_ALPHA8: + RETURN_IF_SUPPORTED(MESA_FORMAT_A8); + break; + case GL_ALPHA12: case GL_ALPHA16: - case GL_ALPHA8: - return MESA_FORMAT_A8; + RETURN_IF_SUPPORTED(MESA_FORMAT_A16); + RETURN_IF_SUPPORTED(MESA_FORMAT_A8); + break; /* Luminance formats */ case 1: case GL_LUMINANCE: case GL_LUMINANCE4: + case GL_LUMINANCE8: + RETURN_IF_SUPPORTED(MESA_FORMAT_L8); + break; + case GL_LUMINANCE12: case GL_LUMINANCE16: - case GL_LUMINANCE8: - return MESA_FORMAT_L8; + RETURN_IF_SUPPORTED(MESA_FORMAT_L16); + RETURN_IF_SUPPORTED(MESA_FORMAT_L8); + break; /* Luminance/Alpha formats */ + case GL_LUMINANCE4_ALPHA4: + RETURN_IF_SUPPORTED(MESA_FORMAT_AL44); + RETURN_IF_SUPPORTED(MESA_FORMAT_AL88); + break; + case 2: case GL_LUMINANCE_ALPHA: - case GL_LUMINANCE4_ALPHA4: case GL_LUMINANCE6_ALPHA2: case GL_LUMINANCE8_ALPHA8: - return MESA_FORMAT_AL88; + RETURN_IF_SUPPORTED(MESA_FORMAT_AL88); + break; case GL_LUMINANCE12_ALPHA4: case GL_LUMINANCE12_ALPHA12: case GL_LUMINANCE16_ALPHA16: - return MESA_FORMAT_AL1616; + RETURN_IF_SUPPORTED(MESA_FORMAT_AL1616); + RETURN_IF_SUPPORTED(MESA_FORMAT_AL88); + break; case GL_INTENSITY: case GL_INTENSITY4: + case GL_INTENSITY8: + RETURN_IF_SUPPORTED(MESA_FORMAT_I8); + break; + case GL_INTENSITY12: case GL_INTENSITY16: - case GL_INTENSITY8: - return MESA_FORMAT_I8; + RETURN_IF_SUPPORTED(MESA_FORMAT_I16); + RETURN_IF_SUPPORTED(MESA_FORMAT_I8); + break; case GL_COLOR_INDEX: case GL_COLOR_INDEX1_EXT: @@ -141,7 +204,8 @@ _mesa_choose_tex_format( struct gl_context *ctx, GLint internalFormat, case GL_COLOR_INDEX12_EXT: case GL_COLOR_INDEX16_EXT: case GL_COLOR_INDEX8_EXT: - return MESA_FORMAT_CI8; + RETURN_IF_SUPPORTED(MESA_FORMAT_CI8); + break; default: ; /* fallthrough */ @@ -152,9 +216,12 @@ _mesa_choose_tex_format( struct gl_context *ctx, GLint internalFormat, case GL_DEPTH_COMPONENT: case GL_DEPTH_COMPONENT24: case GL_DEPTH_COMPONENT32: - return MESA_FORMAT_Z32; + RETURN_IF_SUPPORTED(MESA_FORMAT_Z32); + RETURN_IF_SUPPORTED(MESA_FORMAT_S8_Z24); + break; case GL_DEPTH_COMPONENT16: - return MESA_FORMAT_Z16; + RETURN_IF_SUPPORTED(MESA_FORMAT_Z16); + RETURN_IF_SUPPORTED(MESA_FORMAT_S8_Z24); default: ; /* fallthrough */ } @@ -162,27 +229,36 @@ _mesa_choose_tex_format( struct gl_context *ctx, GLint internalFormat, switch (internalFormat) { case GL_COMPRESSED_ALPHA_ARB: - return MESA_FORMAT_A8; + RETURN_IF_SUPPORTED(MESA_FORMAT_A8); + break; case GL_COMPRESSED_LUMINANCE_ARB: - return MESA_FORMAT_L8; + RETURN_IF_SUPPORTED(MESA_FORMAT_L8); + break; case GL_COMPRESSED_LUMINANCE_ALPHA_ARB: - return MESA_FORMAT_AL88; + RETURN_IF_SUPPORTED(MESA_FORMAT_AL88); + break; case GL_COMPRESSED_INTENSITY_ARB: - return MESA_FORMAT_I8; + RETURN_IF_SUPPORTED(MESA_FORMAT_I8); + break; case GL_COMPRESSED_RGB_ARB: if (ctx->Extensions.EXT_texture_compression_s3tc || ctx->Extensions.S3_s3tc) - return MESA_FORMAT_RGB_DXT1; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGB_DXT1); if (ctx->Extensions.TDFX_texture_compression_FXT1) - return MESA_FORMAT_RGB_FXT1; - return MESA_FORMAT_RGB888; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGB_FXT1); + RETURN_IF_SUPPORTED(MESA_FORMAT_RGB888); + RETURN_IF_SUPPORTED(MESA_FORMAT_XRGB8888); + RETURN_IF_SUPPORTED(MESA_FORMAT_ARGB8888); + break; case GL_COMPRESSED_RGBA_ARB: if (ctx->Extensions.EXT_texture_compression_s3tc || ctx->Extensions.S3_s3tc) - return MESA_FORMAT_RGBA_DXT3; /* Not rgba_dxt1, see spec */ + RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA_DXT3); /* Not rgba_dxt1, see spec */ if (ctx->Extensions.TDFX_texture_compression_FXT1) - return MESA_FORMAT_RGBA_FXT1; - return MESA_FORMAT_RGBA8888; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA_FXT1); + RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA8888); + RETURN_IF_SUPPORTED(MESA_FORMAT_ARGB8888); + break; default: ; /* fallthrough */ } @@ -190,9 +266,9 @@ _mesa_choose_tex_format( struct gl_context *ctx, GLint internalFormat, if (ctx->Extensions.MESA_ycbcr_texture) { if (internalFormat == GL_YCBCR_MESA) { if (type == GL_UNSIGNED_SHORT_8_8_MESA) - return MESA_FORMAT_YCBCR; + RETURN_IF_SUPPORTED(MESA_FORMAT_YCBCR); else - return MESA_FORMAT_YCBCR_REV; + RETURN_IF_SUPPORTED(MESA_FORMAT_YCBCR_REV); } } @@ -200,9 +276,11 @@ _mesa_choose_tex_format( struct gl_context *ctx, GLint internalFormat, if (ctx->Extensions.TDFX_texture_compression_FXT1) { switch (internalFormat) { case GL_COMPRESSED_RGB_FXT1_3DFX: - return MESA_FORMAT_RGB_FXT1; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGB_FXT1); + break; case GL_COMPRESSED_RGBA_FXT1_3DFX: - return MESA_FORMAT_RGBA_FXT1; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA_FXT1); + break; default: ; /* fallthrough */ } @@ -213,13 +291,17 @@ _mesa_choose_tex_format( struct gl_context *ctx, GLint internalFormat, if (ctx->Extensions.EXT_texture_compression_s3tc) { switch (internalFormat) { case GL_COMPRESSED_RGB_S3TC_DXT1_EXT: - return MESA_FORMAT_RGB_DXT1; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGB_DXT1); + break; case GL_COMPRESSED_RGBA_S3TC_DXT1_EXT: - return MESA_FORMAT_RGBA_DXT1; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA_DXT1); + break; case GL_COMPRESSED_RGBA_S3TC_DXT3_EXT: - return MESA_FORMAT_RGBA_DXT3; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA_DXT3); + break; case GL_COMPRESSED_RGBA_S3TC_DXT5_EXT: - return MESA_FORMAT_RGBA_DXT5; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA_DXT5); + break; default: ; /* fallthrough */ } @@ -229,10 +311,12 @@ _mesa_choose_tex_format( struct gl_context *ctx, GLint internalFormat, switch (internalFormat) { case GL_RGB_S3TC: case GL_RGB4_S3TC: - return MESA_FORMAT_RGB_DXT1; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGB_DXT1); + break; case GL_RGBA_S3TC: case GL_RGBA4_S3TC: - return MESA_FORMAT_RGBA_DXT3; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA_DXT3); + break; default: ; /* fallthrough */ } @@ -242,29 +326,41 @@ _mesa_choose_tex_format( struct gl_context *ctx, GLint internalFormat, if (ctx->Extensions.ARB_texture_float) { switch (internalFormat) { case GL_ALPHA16F_ARB: - return MESA_FORMAT_ALPHA_FLOAT16; + RETURN_IF_SUPPORTED(MESA_FORMAT_ALPHA_FLOAT16); + break; case GL_ALPHA32F_ARB: - return MESA_FORMAT_ALPHA_FLOAT32; + RETURN_IF_SUPPORTED(MESA_FORMAT_ALPHA_FLOAT32); + break; case GL_LUMINANCE16F_ARB: - return MESA_FORMAT_LUMINANCE_FLOAT16; + RETURN_IF_SUPPORTED(MESA_FORMAT_LUMINANCE_FLOAT16); + break; case GL_LUMINANCE32F_ARB: - return MESA_FORMAT_LUMINANCE_FLOAT32; + RETURN_IF_SUPPORTED(MESA_FORMAT_LUMINANCE_FLOAT32); + break; case GL_LUMINANCE_ALPHA16F_ARB: - return MESA_FORMAT_LUMINANCE_ALPHA_FLOAT16; + RETURN_IF_SUPPORTED(MESA_FORMAT_LUMINANCE_ALPHA_FLOAT16); + break; case GL_LUMINANCE_ALPHA32F_ARB: - return MESA_FORMAT_LUMINANCE_ALPHA_FLOAT32; + RETURN_IF_SUPPORTED(MESA_FORMAT_LUMINANCE_ALPHA_FLOAT32); + break; case GL_INTENSITY16F_ARB: - return MESA_FORMAT_INTENSITY_FLOAT16; + RETURN_IF_SUPPORTED(MESA_FORMAT_INTENSITY_FLOAT16); + break; case GL_INTENSITY32F_ARB: - return MESA_FORMAT_INTENSITY_FLOAT32; + RETURN_IF_SUPPORTED(MESA_FORMAT_INTENSITY_FLOAT32); + break; case GL_RGB16F_ARB: - return MESA_FORMAT_RGB_FLOAT16; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGB_FLOAT16); + break; case GL_RGB32F_ARB: - return MESA_FORMAT_RGB_FLOAT32; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGB_FLOAT32); + break; case GL_RGBA16F_ARB: - return MESA_FORMAT_RGBA_FLOAT16; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA_FLOAT16); + break; case GL_RGBA32F_ARB: - return MESA_FORMAT_RGBA_FLOAT32; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA_FLOAT32); + break; default: ; /* fallthrough */ } @@ -274,7 +370,9 @@ _mesa_choose_tex_format( struct gl_context *ctx, GLint internalFormat, switch (internalFormat) { case GL_DEPTH_STENCIL_EXT: case GL_DEPTH24_STENCIL8_EXT: - return MESA_FORMAT_Z24_S8; + RETURN_IF_SUPPORTED(MESA_FORMAT_Z24_S8); + RETURN_IF_SUPPORTED(MESA_FORMAT_S8_Z24); + break; default: ; /* fallthrough */ } @@ -284,7 +382,8 @@ _mesa_choose_tex_format( struct gl_context *ctx, GLint internalFormat, switch (internalFormat) { case GL_DUDV_ATI: case GL_DU8DV8_ATI: - return MESA_FORMAT_DUDV8; + RETURN_IF_SUPPORTED(MESA_FORMAT_DUDV8); + break; default: ; /* fallthrough */ } @@ -294,7 +393,9 @@ _mesa_choose_tex_format( struct gl_context *ctx, GLint internalFormat, switch (internalFormat) { case GL_RGBA_SNORM: case GL_RGBA8_SNORM: - return MESA_FORMAT_SIGNED_RGBA8888; + RETURN_IF_SUPPORTED(MESA_FORMAT_SIGNED_RGBA8888); + RETURN_IF_SUPPORTED(MESA_FORMAT_SIGNED_RGBA8888_REV); + break; default: ; /* fallthrough */ } @@ -304,24 +405,32 @@ _mesa_choose_tex_format( struct gl_context *ctx, GLint internalFormat, switch (internalFormat) { case GL_RED_SNORM: case GL_R8_SNORM: - return MESA_FORMAT_SIGNED_R8; + RETURN_IF_SUPPORTED(MESA_FORMAT_SIGNED_R8); + break; case GL_RG_SNORM: case GL_RG8_SNORM: - return MESA_FORMAT_SIGNED_RG88; + RETURN_IF_SUPPORTED(MESA_FORMAT_SIGNED_RG88); + break; case GL_RGB_SNORM: case GL_RGB8_SNORM: - return MESA_FORMAT_SIGNED_RGBX8888; + RETURN_IF_SUPPORTED(MESA_FORMAT_SIGNED_RGBX8888); + break; case GL_RGBA_SNORM: case GL_RGBA8_SNORM: - return MESA_FORMAT_SIGNED_RGBA8888; + RETURN_IF_SUPPORTED(MESA_FORMAT_SIGNED_RGBA8888); + break; case GL_R16_SNORM: - return MESA_FORMAT_SIGNED_R_16; + RETURN_IF_SUPPORTED(MESA_FORMAT_SIGNED_R_16); + break; case GL_RG16_SNORM: - return MESA_FORMAT_SIGNED_RG_16; + RETURN_IF_SUPPORTED(MESA_FORMAT_SIGNED_RG_16); + break; case GL_RGB16_SNORM: - return MESA_FORMAT_SIGNED_RGB_16; + RETURN_IF_SUPPORTED(MESA_FORMAT_SIGNED_RGB_16); + break; case GL_RGBA16_SNORM: - return MESA_FORMAT_SIGNED_RGBA_16; + RETURN_IF_SUPPORTED(MESA_FORMAT_SIGNED_RGBA_16); + break; default: ; /* fall-through */ } @@ -332,48 +441,68 @@ _mesa_choose_tex_format( struct gl_context *ctx, GLint internalFormat, switch (internalFormat) { case GL_SRGB_EXT: case GL_SRGB8_EXT: - return MESA_FORMAT_SRGB8; + RETURN_IF_SUPPORTED(MESA_FORMAT_SRGB8); + RETURN_IF_SUPPORTED(MESA_FORMAT_SARGB8); + break; case GL_SRGB_ALPHA_EXT: case GL_SRGB8_ALPHA8_EXT: - return MESA_FORMAT_SRGBA8; + RETURN_IF_SUPPORTED(MESA_FORMAT_SRGBA8); + RETURN_IF_SUPPORTED(MESA_FORMAT_SARGB8); + break; case GL_SLUMINANCE_EXT: case GL_SLUMINANCE8_EXT: - return MESA_FORMAT_SL8; + RETURN_IF_SUPPORTED(MESA_FORMAT_SL8); + RETURN_IF_SUPPORTED(MESA_FORMAT_SARGB8); + break; case GL_SLUMINANCE_ALPHA_EXT: case GL_SLUMINANCE8_ALPHA8_EXT: - return MESA_FORMAT_SLA8; + RETURN_IF_SUPPORTED(MESA_FORMAT_SLA8); + RETURN_IF_SUPPORTED(MESA_FORMAT_SARGB8); + break; case GL_COMPRESSED_SLUMINANCE_EXT: - return MESA_FORMAT_SL8; + RETURN_IF_SUPPORTED(MESA_FORMAT_SL8); + RETURN_IF_SUPPORTED(MESA_FORMAT_SARGB8); + break; case GL_COMPRESSED_SLUMINANCE_ALPHA_EXT: - return MESA_FORMAT_SLA8; + RETURN_IF_SUPPORTED(MESA_FORMAT_SLA8); + RETURN_IF_SUPPORTED(MESA_FORMAT_SARGB8); + break; case GL_COMPRESSED_SRGB_EXT: #if FEATURE_texture_s3tc if (ctx->Extensions.EXT_texture_compression_s3tc) - return MESA_FORMAT_SRGB_DXT1; + RETURN_IF_SUPPORTED(MESA_FORMAT_SRGB_DXT1); #endif - return MESA_FORMAT_SRGB8; + RETURN_IF_SUPPORTED(MESA_FORMAT_SRGB8); + RETURN_IF_SUPPORTED(MESA_FORMAT_SARGB8); + break; case GL_COMPRESSED_SRGB_ALPHA_EXT: #if FEATURE_texture_s3tc if (ctx->Extensions.EXT_texture_compression_s3tc) - return MESA_FORMAT_SRGBA_DXT3; /* Not srgba_dxt1, see spec */ + RETURN_IF_SUPPORTED(MESA_FORMAT_SRGBA_DXT3); /* Not srgba_dxt1, see spec */ #endif - return MESA_FORMAT_SRGBA8; + RETURN_IF_SUPPORTED(MESA_FORMAT_SRGBA8); + RETURN_IF_SUPPORTED(MESA_FORMAT_SARGB8); + break; #if FEATURE_texture_s3tc case GL_COMPRESSED_SRGB_S3TC_DXT1_EXT: if (ctx->Extensions.EXT_texture_compression_s3tc) - return MESA_FORMAT_SRGB_DXT1; + RETURN_IF_SUPPORTED(MESA_FORMAT_SRGB_DXT1); + RETURN_IF_SUPPORTED(MESA_FORMAT_SARGB8); break; case GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT: if (ctx->Extensions.EXT_texture_compression_s3tc) - return MESA_FORMAT_SRGBA_DXT1; + RETURN_IF_SUPPORTED(MESA_FORMAT_SRGBA_DXT1); + RETURN_IF_SUPPORTED(MESA_FORMAT_SARGB8); break; case GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT: if (ctx->Extensions.EXT_texture_compression_s3tc) - return MESA_FORMAT_SRGBA_DXT3; + RETURN_IF_SUPPORTED(MESA_FORMAT_SRGBA_DXT3); + RETURN_IF_SUPPORTED(MESA_FORMAT_SARGB8); break; case GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT: if (ctx->Extensions.EXT_texture_compression_s3tc) - return MESA_FORMAT_SRGBA_DXT5; + RETURN_IF_SUPPORTED(MESA_FORMAT_SRGBA_DXT5); + RETURN_IF_SUPPORTED(MESA_FORMAT_SARGB8); break; #endif default: @@ -390,42 +519,48 @@ _mesa_choose_tex_format( struct gl_context *ctx, GLint internalFormat, case GL_INTENSITY32UI_EXT: case GL_LUMINANCE32UI_EXT: case GL_LUMINANCE_ALPHA32UI_EXT: - return MESA_FORMAT_RGBA_UINT32; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA_UINT32); + break; case GL_RGBA16UI_EXT: case GL_RGB16UI_EXT: case GL_ALPHA16UI_EXT: case GL_INTENSITY16UI_EXT: case GL_LUMINANCE16UI_EXT: case GL_LUMINANCE_ALPHA16UI_EXT: - return MESA_FORMAT_RGBA_UINT16; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA_UINT16); + break; case GL_RGBA8UI_EXT: case GL_RGB8UI_EXT: case GL_ALPHA8UI_EXT: case GL_INTENSITY8UI_EXT: case GL_LUMINANCE8UI_EXT: case GL_LUMINANCE_ALPHA8UI_EXT: - return MESA_FORMAT_RGBA_UINT8; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA_UINT8); + break; case GL_RGBA32I_EXT: case GL_RGB32I_EXT: case GL_ALPHA32I_EXT: case GL_INTENSITY32I_EXT: case GL_LUMINANCE32I_EXT: case GL_LUMINANCE_ALPHA32I_EXT: - return MESA_FORMAT_RGBA_INT32; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA_INT32); + break; case GL_RGBA16I_EXT: case GL_RGB16I_EXT: case GL_ALPHA16I_EXT: case GL_INTENSITY16I_EXT: case GL_LUMINANCE16I_EXT: case GL_LUMINANCE_ALPHA16I_EXT: - return MESA_FORMAT_RGBA_INT16; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA_INT16); + break; case GL_RGBA8I_EXT: case GL_RGB8I_EXT: case GL_ALPHA8I_EXT: case GL_INTENSITY8I_EXT: case GL_LUMINANCE8I_EXT: case GL_LUMINANCE_ALPHA8I_EXT: - return MESA_FORMAT_RGBA_INT8; + RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA_INT8); + break; } } @@ -434,24 +569,87 @@ _mesa_choose_tex_format( struct gl_context *ctx, GLint internalFormat, case GL_R8: case GL_RED: case GL_COMPRESSED_RED: - return MESA_FORMAT_R8; + RETURN_IF_SUPPORTED(MESA_FORMAT_R8); + break; case GL_R16: - return MESA_FORMAT_R16; + RETURN_IF_SUPPORTED(MESA_FORMAT_R16); + break; case GL_RG: case GL_RG8: case GL_COMPRESSED_RG: - return MESA_FORMAT_RG88; + RETURN_IF_SUPPORTED(MESA_FORMAT_RG88); + break; case GL_RG16: - return MESA_FORMAT_RG1616; + RETURN_IF_SUPPORTED(MESA_FORMAT_RG1616); + break; default: ; /* fallthrough */ } } + if (ctx->Extensions.EXT_texture_format_BGRA8888) { + switch (internalFormat) { + case GL_BGRA: + RETURN_IF_SUPPORTED(MESA_FORMAT_ARGB8888); + break; + + default: + ; /* fallthrough */ + } + } + + if (ctx->Extensions.ARB_texture_compression_rgtc) { + switch (internalFormat) { + case GL_COMPRESSED_RED_RGTC1: + RETURN_IF_SUPPORTED(MESA_FORMAT_RED_RGTC1); + break; + case GL_COMPRESSED_SIGNED_RED_RGTC1: + RETURN_IF_SUPPORTED(MESA_FORMAT_SIGNED_RED_RGTC1); + break; + case GL_COMPRESSED_RG_RGTC2: + RETURN_IF_SUPPORTED(MESA_FORMAT_RG_RGTC2); + break; + case GL_COMPRESSED_SIGNED_RG_RGTC2: + RETURN_IF_SUPPORTED(MESA_FORMAT_SIGNED_RG_RGTC2); + break; + default: + ; /* fallthrough */ + } + } + + if (ctx->Extensions.EXT_texture_compression_latc) { + switch (internalFormat) { + case GL_COMPRESSED_LUMINANCE_LATC1_EXT: + RETURN_IF_SUPPORTED(MESA_FORMAT_L_LATC1); + break; + case GL_COMPRESSED_SIGNED_LUMINANCE_LATC1_EXT: + RETURN_IF_SUPPORTED(MESA_FORMAT_SIGNED_L_LATC1); + break; + case GL_COMPRESSED_LUMINANCE_ALPHA_LATC2_EXT: + RETURN_IF_SUPPORTED(MESA_FORMAT_LA_LATC2); + break; + case GL_COMPRESSED_SIGNED_LUMINANCE_ALPHA_LATC2_EXT: + RETURN_IF_SUPPORTED(MESA_FORMAT_SIGNED_LA_LATC2); + break; + default: + ; /* fallthrough */ + } + } + + if (ctx->Extensions.ATI_texture_compression_3dc) { + switch (internalFormat) { + case GL_COMPRESSED_LUMINANCE_ALPHA_3DC_ATI: + RETURN_IF_SUPPORTED(MESA_FORMAT_LA_LATC2); + break; + default: + ; /* fallthrough */ + } + } + _mesa_problem(ctx, "unexpected format in _mesa_choose_tex_format()"); return MESA_FORMAT_NONE; } diff --git a/src/mesa/main/texgen.c b/src/mesa/main/texgen.c index 108ea4cd42..0ace0b9364 100644 --- a/src/mesa/main/texgen.c +++ b/src/mesa/main/texgen.c @@ -34,6 +34,7 @@ #include "main/context.h" #include "main/enums.h" #include "main/macros.h" +#include "main/mfeatures.h" #include "main/texgen.h" #include "main/texstate.h" #include "math/m_matrix.h" diff --git a/src/mesa/main/texgen.h b/src/mesa/main/texgen.h index 9ed8023836..336ffce924 100644 --- a/src/mesa/main/texgen.h +++ b/src/mesa/main/texgen.h @@ -29,6 +29,7 @@ #include "compiler.h" #include "glheader.h" +#include "mfeatures.h" struct _glapi_table; diff --git a/src/mesa/main/texgetimage.c b/src/mesa/main/texgetimage.c index c94f88e16e..21d9140c55 100644 --- a/src/mesa/main/texgetimage.c +++ b/src/mesa/main/texgetimage.c @@ -35,7 +35,10 @@ #include "context.h" #include "formats.h" #include "image.h" +#include "mfeatures.h" +#include "mtypes.h" #include "pack.h" +#include "pbo.h" #include "texgetimage.h" #include "teximage.h" @@ -432,11 +435,21 @@ get_tex_memcpy(struct gl_context *ctx, GLenum format, GLenum type, GLvoid *pixel type == GL_UNSIGNED_BYTE) { memCopy = GL_TRUE; } + else if (texImage->TexFormat == MESA_FORMAT_L16 && + format == GL_LUMINANCE && + type == GL_UNSIGNED_SHORT) { + memCopy = GL_TRUE; + } else if (texImage->TexFormat == MESA_FORMAT_A8 && format == GL_ALPHA && type == GL_UNSIGNED_BYTE) { memCopy = GL_TRUE; } + else if (texImage->TexFormat == MESA_FORMAT_A16 && + format == GL_ALPHA && + type == GL_UNSIGNED_SHORT) { + memCopy = GL_TRUE; + } } if (memCopy) { @@ -793,8 +806,8 @@ _mesa_GetTexImage( GLenum target, GLint level, GLenum format, * \return GL_TRUE if any error, GL_FALSE if no errors. */ static GLboolean -getcompressedteximage_error_check(struct gl_context *ctx, GLenum target, GLint level, - GLvoid *img) +getcompressedteximage_error_check(struct gl_context *ctx, GLenum target, + GLint level, GLvoid *img) { struct gl_texture_object *texObj; struct gl_texture_image *texImage; diff --git a/src/mesa/main/teximage.c b/src/mesa/main/teximage.c index c5ae63052a..2a3037f618 100644 --- a/src/mesa/main/teximage.c +++ b/src/mesa/main/teximage.c @@ -40,6 +40,7 @@ #include "image.h" #include "imports.h" #include "macros.h" +#include "mfeatures.h" #include "state.h" #include "texcompress.h" #include "texfetch.h" @@ -182,6 +183,15 @@ _mesa_base_tex_format( struct gl_context *ctx, GLint internalFormat ) ; /* fallthrough */ } + if (ctx->Extensions.EXT_texture_format_BGRA8888) { + switch (internalFormat) { + case GL_BGRA_EXT: + return GL_RGBA; + default: + ; /* fallthrough */ + } + } + if (ctx->Extensions.EXT_paletted_texture) { switch (internalFormat) { case GL_COLOR_INDEX: @@ -340,11 +350,11 @@ _mesa_base_tex_format( struct gl_context *ctx, GLint internalFormat ) return GL_RGBA; case GL_SLUMINANCE_ALPHA_EXT: case GL_SLUMINANCE8_ALPHA8_EXT: - case GL_COMPRESSED_SLUMINANCE_EXT: case GL_COMPRESSED_SLUMINANCE_ALPHA_EXT: return GL_LUMINANCE_ALPHA; case GL_SLUMINANCE_EXT: case GL_SLUMINANCE8_EXT: + case GL_COMPRESSED_SLUMINANCE_EXT: return GL_LUMINANCE; default: ; /* fallthrough */ @@ -499,6 +509,28 @@ _mesa_base_tex_format( struct gl_context *ctx, GLint internalFormat ) } } + if (ctx->Extensions.EXT_texture_compression_latc) { + switch (internalFormat) { + case GL_COMPRESSED_LUMINANCE_LATC1_EXT: + case GL_COMPRESSED_SIGNED_LUMINANCE_LATC1_EXT: + return GL_LUMINANCE; + case GL_COMPRESSED_LUMINANCE_ALPHA_LATC2_EXT: + case GL_COMPRESSED_SIGNED_LUMINANCE_ALPHA_LATC2_EXT: + return GL_LUMINANCE_ALPHA; + default: + ; /* fallthrough */ + } + } + + if (ctx->Extensions.ATI_texture_compression_3dc) { + switch (internalFormat) { + case GL_COMPRESSED_LUMINANCE_ALPHA_3DC_ATI: + return GL_LUMINANCE_ALPHA; + default: + ; /* fallthrough */ + } + } + return -1; /* error */ } @@ -693,6 +725,9 @@ _mesa_select_tex_object(struct gl_context *ctx, const struct gl_texture_unit *texUnit, GLenum target) { + const GLboolean arrayTex = (ctx->Extensions.MESA_texture_array || + ctx->Extensions.EXT_texture_array); + switch (target) { case GL_TEXTURE_1D: return texUnit->CurrentTex[TEXTURE_1D_INDEX]; @@ -725,17 +760,13 @@ _mesa_select_tex_object(struct gl_context *ctx, return ctx->Extensions.NV_texture_rectangle ? ctx->Texture.ProxyTex[TEXTURE_RECT_INDEX] : NULL; case GL_TEXTURE_1D_ARRAY_EXT: - return ctx->Extensions.MESA_texture_array - ? texUnit->CurrentTex[TEXTURE_1D_ARRAY_INDEX] : NULL; + return arrayTex ? texUnit->CurrentTex[TEXTURE_1D_ARRAY_INDEX] : NULL; case GL_PROXY_TEXTURE_1D_ARRAY_EXT: - return ctx->Extensions.MESA_texture_array - ? ctx->Texture.ProxyTex[TEXTURE_1D_ARRAY_INDEX] : NULL; + return arrayTex ? ctx->Texture.ProxyTex[TEXTURE_1D_ARRAY_INDEX] : NULL; case GL_TEXTURE_2D_ARRAY_EXT: - return ctx->Extensions.MESA_texture_array - ? texUnit->CurrentTex[TEXTURE_2D_ARRAY_INDEX] : NULL; + return arrayTex ? texUnit->CurrentTex[TEXTURE_2D_ARRAY_INDEX] : NULL; case GL_PROXY_TEXTURE_2D_ARRAY_EXT: - return ctx->Extensions.MESA_texture_array - ? ctx->Texture.ProxyTex[TEXTURE_2D_ARRAY_INDEX] : NULL; + return arrayTex ? ctx->Texture.ProxyTex[TEXTURE_2D_ARRAY_INDEX] : NULL; default: _mesa_problem(NULL, "bad target in _mesa_select_tex_object()"); return NULL; @@ -920,7 +951,8 @@ _mesa_max_texture_levels(struct gl_context *ctx, GLenum target) case GL_PROXY_TEXTURE_1D_ARRAY_EXT: case GL_TEXTURE_2D_ARRAY_EXT: case GL_PROXY_TEXTURE_2D_ARRAY_EXT: - return ctx->Extensions.MESA_texture_array + return (ctx->Extensions.MESA_texture_array || + ctx->Extensions.EXT_texture_array) ? ctx->Const.MaxTextureLevels : 0; default: return 0; /* bad target */ @@ -931,8 +963,8 @@ _mesa_max_texture_levels(struct gl_context *ctx, GLenum target) /** * Return number of dimensions per mipmap level for the given texture target. */ -static GLint -get_texture_dimensions(GLenum target) +GLint +_mesa_get_texture_dimensions(GLenum target) { switch (target) { case GL_TEXTURE_1D: @@ -1157,7 +1189,7 @@ _mesa_init_teximage_fields(struct gl_context *ctx, GLenum target, img->TexFormat = format; - dims = get_texture_dimensions(target); + dims = _mesa_get_texture_dimensions(target); _mesa_set_fetch_functions(img, dims); } @@ -1372,7 +1404,8 @@ target_can_be_compressed(const struct gl_context *ctx, GLenum target, return ctx->Extensions.ARB_texture_cube_map; case GL_PROXY_TEXTURE_2D_ARRAY_EXT: case GL_TEXTURE_2D_ARRAY_EXT: - return ctx->Extensions.MESA_texture_array; + return (ctx->Extensions.MESA_texture_array || + ctx->Extensions.EXT_texture_array); default: return GL_FALSE; } @@ -1413,7 +1446,8 @@ legal_teximage_target(struct gl_context *ctx, GLuint dims, GLenum target) return ctx->Extensions.NV_texture_rectangle; case GL_TEXTURE_1D_ARRAY_EXT: case GL_PROXY_TEXTURE_1D_ARRAY_EXT: - return ctx->Extensions.MESA_texture_array; + return (ctx->Extensions.MESA_texture_array || + ctx->Extensions.EXT_texture_array); default: return GL_FALSE; } @@ -1424,7 +1458,8 @@ legal_teximage_target(struct gl_context *ctx, GLuint dims, GLenum target) return GL_TRUE; case GL_TEXTURE_2D_ARRAY_EXT: case GL_PROXY_TEXTURE_2D_ARRAY_EXT: - return ctx->Extensions.MESA_texture_array; + return (ctx->Extensions.MESA_texture_array || + ctx->Extensions.EXT_texture_array); default: return GL_FALSE; } @@ -1461,7 +1496,8 @@ legal_texsubimage_target(struct gl_context *ctx, GLuint dims, GLenum target) case GL_TEXTURE_RECTANGLE_NV: return ctx->Extensions.NV_texture_rectangle; case GL_TEXTURE_1D_ARRAY_EXT: - return ctx->Extensions.MESA_texture_array; + return (ctx->Extensions.MESA_texture_array || + ctx->Extensions.EXT_texture_array); default: return GL_FALSE; } @@ -1470,7 +1506,8 @@ legal_texsubimage_target(struct gl_context *ctx, GLuint dims, GLenum target) case GL_TEXTURE_3D: return GL_TRUE; case GL_TEXTURE_2D_ARRAY_EXT: - return ctx->Extensions.MESA_texture_array; + return (ctx->Extensions.MESA_texture_array || + ctx->Extensions.EXT_texture_array); default: return GL_FALSE; } @@ -1883,7 +1920,9 @@ copytexture_error_check( struct gl_context *ctx, GLuint dimensions, /* Check that the source buffer is complete */ if (ctx->ReadBuffer->Name) { - _mesa_test_framebuffer_completeness(ctx, ctx->ReadBuffer); + if (ctx->ReadBuffer->_Status == 0) { + _mesa_test_framebuffer_completeness(ctx, ctx->ReadBuffer); + } if (ctx->ReadBuffer->_Status != GL_FRAMEBUFFER_COMPLETE_EXT) { _mesa_error(ctx, GL_INVALID_FRAMEBUFFER_OPERATION_EXT, "glCopyTexImage%dD(invalid readbuffer)", dimensions); @@ -1985,7 +2024,9 @@ copytexsubimage_error_check1( struct gl_context *ctx, GLuint dimensions, { /* Check that the source buffer is complete */ if (ctx->ReadBuffer->Name) { - _mesa_test_framebuffer_completeness(ctx, ctx->ReadBuffer); + if (ctx->ReadBuffer->_Status == 0) { + _mesa_test_framebuffer_completeness(ctx, ctx->ReadBuffer); + } if (ctx->ReadBuffer->_Status != GL_FRAMEBUFFER_COMPLETE_EXT) { _mesa_error(ctx, GL_INVALID_FRAMEBUFFER_OPERATION_EXT, "glCopyTexImage%dD(invalid readbuffer)", dimensions); diff --git a/src/mesa/main/teximage.h b/src/mesa/main/teximage.h index 5bb9d492e9..bb5509e5be 100644 --- a/src/mesa/main/teximage.h +++ b/src/mesa/main/teximage.h @@ -126,6 +126,8 @@ _mesa_test_proxy_teximage(struct gl_context *ctx, GLenum target, GLint level, extern GLuint _mesa_tex_target_to_face(GLenum target); +extern GLint +_mesa_get_texture_dimensions(GLenum target); /** * Lock a texture for updating. See also _mesa_lock_context_textures(). diff --git a/src/mesa/main/texobj.c b/src/mesa/main/texobj.c index 5bc5639dbf..5be881ec45 100644 --- a/src/mesa/main/texobj.c +++ b/src/mesa/main/texobj.c @@ -141,6 +141,7 @@ _mesa_initialize_texture_object( struct gl_texture_object *obj, obj->Swizzle[2] = GL_BLUE; obj->Swizzle[3] = GL_ALPHA; obj->_Swizzle = SWIZZLE_NOOP; + obj->sRGBDecode = GL_DECODE_EXT; } @@ -470,6 +471,12 @@ _mesa_test_texobj_completeness( const struct gl_context *ctx, ASSERT(maxLevels > 0); + if (t->MaxLevel < t->BaseLevel) { + incomplete(t, "MAX_LEVEL (%d) < BASE_LEVEL (%d)", + t->MaxLevel, t->BaseLevel); + return; + } + t->_MaxLevel = baseLevel + maxLog2; t->_MaxLevel = MIN2(t->_MaxLevel, t->MaxLevel); t->_MaxLevel = MIN2(t->_MaxLevel, maxLevels - 1); diff --git a/src/mesa/main/texpal.c b/src/mesa/main/texpal.c index a25e7aa4ff..b2112f957a 100644 --- a/src/mesa/main/texpal.c +++ b/src/mesa/main/texpal.c @@ -18,6 +18,7 @@ #include "glheader.h" #include "compiler.h" /* for ASSERT */ #include "context.h" +#include "mfeatures.h" #include "mtypes.h" #include "imports.h" #include "pixelstore.h" diff --git a/src/mesa/main/texparam.c b/src/mesa/main/texparam.c index d5c83de97f..6e14face4d 100644 --- a/src/mesa/main/texparam.c +++ b/src/mesa/main/texparam.c @@ -33,12 +33,16 @@ #include "main/glheader.h" #include "main/colormac.h" #include "main/context.h" +#include "main/enums.h" #include "main/formats.h" #include "main/macros.h" +#include "main/mfeatures.h" +#include "main/mtypes.h" #include "main/texcompress.h" #include "main/texparam.h" #include "main/teximage.h" #include "main/texstate.h" +#include "main/texfetch.h" #include "program/prog_instruction.h" @@ -113,12 +117,14 @@ get_texobj(struct gl_context *ctx, GLenum target, GLboolean get) } break; case GL_TEXTURE_1D_ARRAY_EXT: - if (ctx->Extensions.MESA_texture_array) { + if (ctx->Extensions.MESA_texture_array || + ctx->Extensions.EXT_texture_array) { return texUnit->CurrentTex[TEXTURE_1D_ARRAY_INDEX]; } break; case GL_TEXTURE_2D_ARRAY_EXT: - if (ctx->Extensions.MESA_texture_array) { + if (ctx->Extensions.MESA_texture_array || + ctx->Extensions.EXT_texture_array) { return texUnit->CurrentTex[TEXTURE_2D_ARRAY_INDEX]; } break; @@ -172,13 +178,26 @@ set_swizzle_component(GLuint *swizzle, GLuint comp, GLuint swz) /** - * This is called just prior to changing any texture object state. + * This is called just prior to changing any texture object state which + * will not effect texture completeness. + */ +static INLINE void +flush(struct gl_context *ctx) +{ + FLUSH_VERTICES(ctx, _NEW_TEXTURE); +} + + +/** + * This is called just prior to changing any texture object state which + * can effect texture completeness (texture base level, max level, + * minification filter). * Any pending rendering will be flushed out, we'll set the _NEW_TEXTURE * state flag and then mark the texture object as 'incomplete' so that any * per-texture derived state gets recomputed. */ static INLINE void -flush(struct gl_context *ctx, struct gl_texture_object *texObj) +incomplete(struct gl_context *ctx, struct gl_texture_object *texObj) { FLUSH_VERTICES(ctx, _NEW_TEXTURE); texObj->_Complete = GL_FALSE; @@ -201,7 +220,7 @@ set_tex_parameteri(struct gl_context *ctx, switch (params[0]) { case GL_NEAREST: case GL_LINEAR: - flush(ctx, texObj); + incomplete(ctx, texObj); texObj->MinFilter = params[0]; return GL_TRUE; case GL_NEAREST_MIPMAP_NEAREST: @@ -209,14 +228,13 @@ set_tex_parameteri(struct gl_context *ctx, case GL_NEAREST_MIPMAP_LINEAR: case GL_LINEAR_MIPMAP_LINEAR: if (texObj->Target != GL_TEXTURE_RECTANGLE_NV) { - flush(ctx, texObj); + incomplete(ctx, texObj); texObj->MinFilter = params[0]; return GL_TRUE; } /* fall-through */ default: - _mesa_error( ctx, GL_INVALID_ENUM, "glTexParameter(param=0x%x)", - params[0] ); + goto invalid_param; } return GL_FALSE; @@ -226,12 +244,11 @@ set_tex_parameteri(struct gl_context *ctx, switch (params[0]) { case GL_NEAREST: case GL_LINEAR: - flush(ctx, texObj); + flush(ctx); /* does not effect completeness */ texObj->MagFilter = params[0]; return GL_TRUE; default: - _mesa_error( ctx, GL_INVALID_ENUM, "glTexParameter(param=0x%x)", - params[0]); + goto invalid_param; } return GL_FALSE; @@ -239,7 +256,7 @@ set_tex_parameteri(struct gl_context *ctx, if (texObj->WrapS == params[0]) return GL_FALSE; if (validate_texture_wrap_mode(ctx, texObj->Target, params[0])) { - flush(ctx, texObj); + flush(ctx); texObj->WrapS = params[0]; return GL_TRUE; } @@ -249,7 +266,7 @@ set_tex_parameteri(struct gl_context *ctx, if (texObj->WrapT == params[0]) return GL_FALSE; if (validate_texture_wrap_mode(ctx, texObj->Target, params[0])) { - flush(ctx, texObj); + flush(ctx); texObj->WrapT = params[0]; return GL_TRUE; } @@ -259,7 +276,7 @@ set_tex_parameteri(struct gl_context *ctx, if (texObj->WrapR == params[0]) return GL_FALSE; if (validate_texture_wrap_mode(ctx, texObj->Target, params[0])) { - flush(ctx, texObj); + flush(ctx); texObj->WrapR = params[0]; return GL_TRUE; } @@ -274,7 +291,7 @@ set_tex_parameteri(struct gl_context *ctx, "glTexParameter(param=%d)", params[0]); return GL_FALSE; } - flush(ctx, texObj); + incomplete(ctx, texObj); texObj->BaseLevel = params[0]; return GL_TRUE; @@ -286,34 +303,31 @@ set_tex_parameteri(struct gl_context *ctx, "glTexParameter(param=%d)", params[0]); return GL_FALSE; } - flush(ctx, texObj); + incomplete(ctx, texObj); texObj->MaxLevel = params[0]; return GL_TRUE; case GL_GENERATE_MIPMAP_SGIS: if (texObj->GenerateMipmap != params[0]) { - flush(ctx, texObj); + /* no flush() */ texObj->GenerateMipmap = params[0] ? GL_TRUE : GL_FALSE; return GL_TRUE; } return GL_FALSE; case GL_TEXTURE_COMPARE_MODE_ARB: - if (ctx->Extensions.ARB_shadow && - (params[0] == GL_NONE || - params[0] == GL_COMPARE_R_TO_TEXTURE_ARB)) { - if (texObj->CompareMode != params[0]) { - flush(ctx, texObj); + if (ctx->Extensions.ARB_shadow) { + if (texObj->CompareMode == params[0]) + return GL_FALSE; + if (params[0] == GL_NONE || + params[0] == GL_COMPARE_R_TO_TEXTURE_ARB) { + flush(ctx); texObj->CompareMode = params[0]; return GL_TRUE; } - return GL_FALSE; + goto invalid_param; } - else { - _mesa_error(ctx, GL_INVALID_ENUM, - "glTexParameter(GL_TEXTURE_COMPARE_MODE_ARB)"); - } - return GL_FALSE; + goto invalid_pname; case GL_TEXTURE_COMPARE_FUNC_ARB: if (ctx->Extensions.ARB_shadow) { @@ -322,7 +336,7 @@ set_tex_parameteri(struct gl_context *ctx, switch (params[0]) { case GL_LEQUAL: case GL_GEQUAL: - flush(ctx, texObj); + flush(ctx); texObj->CompareFunc = params[0]; return GL_TRUE; case GL_EQUAL: @@ -332,38 +346,32 @@ set_tex_parameteri(struct gl_context *ctx, case GL_ALWAYS: case GL_NEVER: if (ctx->Extensions.EXT_shadow_funcs) { - flush(ctx, texObj); + flush(ctx); texObj->CompareFunc = params[0]; return GL_TRUE; } /* fall-through */ default: - _mesa_error(ctx, GL_INVALID_ENUM, - "glTexParameter(GL_TEXTURE_COMPARE_FUNC_ARB)"); + goto invalid_param; } } - else { - _mesa_error(ctx, GL_INVALID_ENUM, "glTexParameter(pname=0x%x)", pname); - } - return GL_FALSE; + goto invalid_pname; case GL_DEPTH_TEXTURE_MODE_ARB: - if (ctx->Extensions.ARB_depth_texture && - (params[0] == GL_LUMINANCE || - params[0] == GL_INTENSITY || - params[0] == GL_ALPHA || - (ctx->Extensions.ARB_texture_rg && params[0] == GL_RED))) { - if (texObj->DepthMode != params[0]) { - flush(ctx, texObj); + if (ctx->Extensions.ARB_depth_texture) { + if (texObj->DepthMode == params[0]) + return GL_FALSE; + if (params[0] == GL_LUMINANCE || + params[0] == GL_INTENSITY || + params[0] == GL_ALPHA || + (ctx->Extensions.ARB_texture_rg && params[0] == GL_RED)) { + flush(ctx); texObj->DepthMode = params[0]; return GL_TRUE; } + goto invalid_param; } - else { - _mesa_error(ctx, GL_INVALID_ENUM, - "glTexParameter(GL_DEPTH_TEXTURE_MODE_ARB)"); - } - return GL_FALSE; + goto invalid_pname; #if FEATURE_OES_draw_texture case GL_TEXTURE_CROP_RECT_OES: @@ -388,19 +396,18 @@ set_tex_parameteri(struct gl_context *ctx, } ASSERT(comp < 4); if (swz >= 0) { - flush(ctx, texObj); + flush(ctx); texObj->Swizzle[comp] = params[0]; set_swizzle_component(&texObj->_Swizzle, comp, swz); return GL_TRUE; } } - _mesa_error(ctx, GL_INVALID_ENUM, "glTexParameter(pname=0x%x)", pname); - return GL_FALSE; + goto invalid_pname; case GL_TEXTURE_SWIZZLE_RGBA_EXT: if (ctx->Extensions.EXT_texture_swizzle) { GLuint comp; - flush(ctx, texObj); + flush(ctx); for (comp = 0; comp < 4; comp++) { const GLint swz = comp_to_swizzle(params[comp]); if (swz >= 0) { @@ -415,12 +422,34 @@ set_tex_parameteri(struct gl_context *ctx, } return GL_TRUE; } - _mesa_error(ctx, GL_INVALID_ENUM, "glTexParameter(pname=0x%x)", pname); - return GL_FALSE; + goto invalid_pname; + + case GL_TEXTURE_SRGB_DECODE_EXT: + if (ctx->Extensions.EXT_texture_sRGB_decode) { + GLenum decode = params[0]; + if (decode == GL_DECODE_EXT || decode == GL_SKIP_DECODE_EXT) { + if (texObj->sRGBDecode != decode) { + flush(ctx); + texObj->sRGBDecode = decode; + _mesa_update_fetch_functions(texObj); + } + return GL_TRUE; + } + } + goto invalid_pname; default: - _mesa_error(ctx, GL_INVALID_ENUM, "glTexParameter(pname=0x%x)", pname); + goto invalid_pname; } + +invalid_pname: + _mesa_error(ctx, GL_INVALID_ENUM, "glTexParameter(pname=%s)", + _mesa_lookup_enum_by_nr(pname)); + return GL_FALSE; + +invalid_param: + _mesa_error(ctx, GL_INVALID_ENUM, "glTexParameter(param=%s)", + _mesa_lookup_enum_by_nr(params[0])); return GL_FALSE; } @@ -438,19 +467,19 @@ set_tex_parameterf(struct gl_context *ctx, case GL_TEXTURE_MIN_LOD: if (texObj->MinLod == params[0]) return GL_FALSE; - flush(ctx, texObj); + flush(ctx); texObj->MinLod = params[0]; return GL_TRUE; case GL_TEXTURE_MAX_LOD: if (texObj->MaxLod == params[0]) return GL_FALSE; - flush(ctx, texObj); + flush(ctx); texObj->MaxLod = params[0]; return GL_TRUE; case GL_TEXTURE_PRIORITY: - flush(ctx, texObj); + flush(ctx); texObj->Priority = CLAMP(params[0], 0.0F, 1.0F); return GL_TRUE; @@ -462,7 +491,7 @@ set_tex_parameterf(struct gl_context *ctx, _mesa_error(ctx, GL_INVALID_VALUE, "glTexParameter(param)" ); return GL_FALSE; } - flush(ctx, texObj); + flush(ctx); /* clamp to max, that's what NVIDIA does */ texObj->MaxAnisotropy = MIN2(params[0], ctx->Const.MaxTextureMaxAnisotropy); @@ -479,7 +508,7 @@ set_tex_parameterf(struct gl_context *ctx, case GL_TEXTURE_COMPARE_FAIL_VALUE_ARB: if (ctx->Extensions.ARB_shadow_ambient) { if (texObj->CompareFailValue != params[0]) { - flush(ctx, texObj); + flush(ctx); texObj->CompareFailValue = CLAMP(params[0], 0.0F, 1.0F); return GL_TRUE; } @@ -494,7 +523,7 @@ set_tex_parameterf(struct gl_context *ctx, /* NOTE: this is really part of OpenGL 1.4, not EXT_texture_lod_bias */ if (ctx->Extensions.EXT_texture_lod_bias) { if (texObj->LodBias != params[0]) { - flush(ctx, texObj); + flush(ctx); texObj->LodBias = params[0]; return GL_TRUE; } @@ -503,7 +532,7 @@ set_tex_parameterf(struct gl_context *ctx, break; case GL_TEXTURE_BORDER_COLOR: - flush(ctx, texObj); + flush(ctx); texObj->BorderColor.f[RCOMP] = params[0]; texObj->BorderColor.f[GCOMP] = params[1]; texObj->BorderColor.f[BCOMP] = params[2]; @@ -541,6 +570,7 @@ _mesa_TexParameterf(GLenum target, GLenum pname, GLfloat param) case GL_TEXTURE_COMPARE_MODE_ARB: case GL_TEXTURE_COMPARE_FUNC_ARB: case GL_DEPTH_TEXTURE_MODE_ARB: + case GL_TEXTURE_SRGB_DECODE_EXT: { /* convert float param to int */ GLint p[4]; @@ -589,6 +619,7 @@ _mesa_TexParameterfv(GLenum target, GLenum pname, const GLfloat *params) case GL_TEXTURE_COMPARE_MODE_ARB: case GL_TEXTURE_COMPARE_FUNC_ARB: case GL_DEPTH_TEXTURE_MODE_ARB: + case GL_TEXTURE_SRGB_DECODE_EXT: { /* convert float param to int */ GLint p[4]; @@ -803,7 +834,6 @@ _mesa_GetTexLevelParameteriv( GLenum target, GLint level, const struct gl_texture_unit *texUnit; struct gl_texture_object *texObj; const struct gl_texture_image *img = NULL; - GLboolean isProxy; GLint maxLevels; gl_format texFormat; GET_CURRENT_CONTEXT(ctx); @@ -831,7 +861,6 @@ _mesa_GetTexLevelParameteriv( GLenum target, GLint level, } texObj = _mesa_select_tex_object(ctx, texUnit, target); - _mesa_lock_texture(ctx, texObj); img = _mesa_select_tex_image(ctx, texObj, target, level); if (!img || !img->TexFormat) { @@ -840,13 +869,11 @@ _mesa_GetTexLevelParameteriv( GLenum target, GLint level, *params = 1; else *params = 0; - goto out; + return; } texFormat = img->TexFormat; - isProxy = _mesa_is_proxy_texture(target); - switch (pname) { case GL_TEXTURE_WIDTH: *params = img->Width; @@ -858,9 +885,9 @@ _mesa_GetTexLevelParameteriv( GLenum target, GLint level, *params = img->Depth; break; case GL_TEXTURE_INTERNAL_FORMAT: - if (_mesa_is_format_compressed(img->TexFormat)) { + if (_mesa_is_format_compressed(texFormat)) { /* need to return the actual compressed format */ - *params = _mesa_compressed_format_to_glenum(ctx, img->TexFormat); + *params = _mesa_compressed_format_to_glenum(ctx, texFormat); } else { /* return the user's requested internal format */ @@ -931,8 +958,7 @@ _mesa_GetTexLevelParameteriv( GLenum target, GLint level, if (ctx->Extensions.ARB_depth_texture) *params = _mesa_get_format_bits(texFormat, pname); else - _mesa_error(ctx, GL_INVALID_ENUM, - "glGetTexLevelParameter[if]v(pname)"); + goto invalid_pname; break; case GL_TEXTURE_STENCIL_SIZE_EXT: if (ctx->Extensions.EXT_packed_depth_stencil || @@ -940,8 +966,7 @@ _mesa_GetTexLevelParameteriv( GLenum target, GLint level, *params = _mesa_get_format_bits(texFormat, pname); } else { - _mesa_error(ctx, GL_INVALID_ENUM, - "glGetTexLevelParameter[if]v(pname)"); + goto invalid_pname; } break; case GL_TEXTURE_SHARED_SIZE: @@ -952,14 +977,14 @@ _mesa_GetTexLevelParameteriv( GLenum target, GLint level, *params = 0; } else { - _mesa_error(ctx, GL_INVALID_ENUM, - "glGetTexLevelParameter[if]v(pname)"); + goto invalid_pname; } break; /* GL_ARB_texture_compression */ case GL_TEXTURE_COMPRESSED_IMAGE_SIZE: - if (_mesa_is_format_compressed(img->TexFormat) && !isProxy) { + if (_mesa_is_format_compressed(texFormat) && + !_mesa_is_proxy_texture(target)) { *params = _mesa_format_image_size(texFormat, img->Width, img->Height, img->Depth); } @@ -969,7 +994,7 @@ _mesa_GetTexLevelParameteriv( GLenum target, GLint level, } break; case GL_TEXTURE_COMPRESSED: - *params = (GLint) _mesa_is_format_compressed(img->TexFormat); + *params = (GLint) _mesa_is_format_compressed(texFormat); break; /* GL_ARB_texture_float */ @@ -979,8 +1004,7 @@ _mesa_GetTexLevelParameteriv( GLenum target, GLint level, _mesa_get_format_datatype(texFormat) : GL_NONE; } else { - _mesa_error(ctx, GL_INVALID_ENUM, - "glGetTexLevelParameter[if]v(pname)"); + goto invalid_pname; } break; case GL_TEXTURE_GREEN_TYPE_ARB: @@ -989,8 +1013,7 @@ _mesa_GetTexLevelParameteriv( GLenum target, GLint level, _mesa_get_format_datatype(texFormat) : GL_NONE; } else { - _mesa_error(ctx, GL_INVALID_ENUM, - "glGetTexLevelParameter[if]v(pname)"); + goto invalid_pname; } break; case GL_TEXTURE_BLUE_TYPE_ARB: @@ -999,8 +1022,7 @@ _mesa_GetTexLevelParameteriv( GLenum target, GLint level, _mesa_get_format_datatype(texFormat) : GL_NONE; } else { - _mesa_error(ctx, GL_INVALID_ENUM, - "glGetTexLevelParameter[if]v(pname)"); + goto invalid_pname; } break; case GL_TEXTURE_ALPHA_TYPE_ARB: @@ -1009,8 +1031,7 @@ _mesa_GetTexLevelParameteriv( GLenum target, GLint level, _mesa_get_format_datatype(texFormat) : GL_NONE; } else { - _mesa_error(ctx, GL_INVALID_ENUM, - "glGetTexLevelParameter[if]v(pname)"); + goto invalid_pname; } break; case GL_TEXTURE_LUMINANCE_TYPE_ARB: @@ -1019,8 +1040,7 @@ _mesa_GetTexLevelParameteriv( GLenum target, GLint level, _mesa_get_format_datatype(texFormat) : GL_NONE; } else { - _mesa_error(ctx, GL_INVALID_ENUM, - "glGetTexLevelParameter[if]v(pname)"); + goto invalid_pname; } break; case GL_TEXTURE_INTENSITY_TYPE_ARB: @@ -1029,8 +1049,7 @@ _mesa_GetTexLevelParameteriv( GLenum target, GLint level, _mesa_get_format_datatype(texFormat) : GL_NONE; } else { - _mesa_error(ctx, GL_INVALID_ENUM, - "glGetTexLevelParameter[if]v(pname)"); + goto invalid_pname; } break; case GL_TEXTURE_DEPTH_TYPE_ARB: @@ -1039,18 +1058,21 @@ _mesa_GetTexLevelParameteriv( GLenum target, GLint level, _mesa_get_format_datatype(texFormat) : GL_NONE; } else { - _mesa_error(ctx, GL_INVALID_ENUM, - "glGetTexLevelParameter[if]v(pname)"); + goto invalid_pname; } break; default: - _mesa_error(ctx, GL_INVALID_ENUM, - "glGetTexLevelParameter[if]v(pname)"); + goto invalid_pname; } - out: - _mesa_unlock_texture(ctx, texObj); + /* no error if we get here */ + return; + +invalid_pname: + _mesa_error(ctx, GL_INVALID_ENUM, + "glGetTexLevelParameter[if]v(pname=%s)", + _mesa_lookup_enum_by_nr(pname)); } diff --git a/src/mesa/main/texrender.c b/src/mesa/main/texrender.c index 8961b92648..8cec24c3e2 100644 --- a/src/mesa/main/texrender.c +++ b/src/mesa/main/texrender.c @@ -3,6 +3,7 @@ #include "colormac.h" #include "macros.h" #include "texfetch.h" +#include "teximage.h" #include "texrender.h" #include "renderbuffer.h" @@ -20,6 +21,7 @@ struct texture_renderbuffer struct gl_renderbuffer Base; /**< Base class object */ struct gl_texture_image *TexImage; StoreTexelFunc Store; + FetchTexelFuncF Fetchf; GLint Yoffset; /**< Layer for 1D array textures. */ GLint Zoffset; /**< Layer for 2D array textures, or slice * for 3D textures @@ -48,7 +50,7 @@ texture_get_row(struct gl_context *ctx, struct gl_renderbuffer *rb, GLuint count GLchan *rgbaOut = (GLchan *) values; for (i = 0; i < count; i++) { GLfloat rgba[4]; - trb->TexImage->FetchTexelf(trb->TexImage, x + i, y, z, rgba); + trb->Fetchf(trb->TexImage, x + i, y, z, rgba); UNCLAMPED_FLOAT_TO_RGBA_CHAN(rgbaOut + 4 * i, rgba); } } @@ -56,7 +58,7 @@ texture_get_row(struct gl_context *ctx, struct gl_renderbuffer *rb, GLuint count GLushort *zValues = (GLushort *) values; for (i = 0; i < count; i++) { GLfloat flt; - trb->TexImage->FetchTexelf(trb->TexImage, x + i, y, z, &flt); + trb->Fetchf(trb->TexImage, x + i, y, z, &flt); zValues[i] = (GLushort) (flt * 0xffff); } } @@ -67,7 +69,7 @@ texture_get_row(struct gl_context *ctx, struct gl_renderbuffer *rb, GLuint count */ for (i = 0; i < count; i++) { GLfloat flt; - trb->TexImage->FetchTexelf(trb->TexImage, x + i, y, z, &flt); + trb->Fetchf(trb->TexImage, x + i, y, z, &flt); #if 0 /* this should work, but doesn't (overflow due to low precision) */ zValues[i] = (GLuint) (flt * scale); @@ -81,7 +83,7 @@ texture_get_row(struct gl_context *ctx, struct gl_renderbuffer *rb, GLuint count GLuint *zValues = (GLuint *) values; for (i = 0; i < count; i++) { GLfloat flt; - trb->TexImage->FetchTexelf(trb->TexImage, x + i, y, z, &flt); + trb->Fetchf(trb->TexImage, x + i, y, z, &flt); zValues[i] = ((GLuint) (flt * 0xffffff)) << 8; } } @@ -89,7 +91,7 @@ texture_get_row(struct gl_context *ctx, struct gl_renderbuffer *rb, GLuint count GLuint *zValues = (GLuint *) values; for (i = 0; i < count; i++) { GLfloat flt; - trb->TexImage->FetchTexelf(trb->TexImage, x + i, y, z, &flt); + trb->Fetchf(trb->TexImage, x + i, y, z, &flt); zValues[i] = (GLuint) (flt * 0xffffff); } } @@ -112,7 +114,7 @@ texture_get_values(struct gl_context *ctx, struct gl_renderbuffer *rb, GLuint co GLchan *rgbaOut = (GLchan *) values; for (i = 0; i < count; i++) { GLfloat rgba[4]; - trb->TexImage->FetchTexelf(trb->TexImage, x[i], y[i] + trb->Yoffset, + trb->Fetchf(trb->TexImage, x[i], y[i] + trb->Yoffset, z, rgba); UNCLAMPED_FLOAT_TO_RGBA_CHAN(rgbaOut + 4 * i, rgba); } @@ -121,7 +123,7 @@ texture_get_values(struct gl_context *ctx, struct gl_renderbuffer *rb, GLuint co GLushort *zValues = (GLushort *) values; for (i = 0; i < count; i++) { GLfloat flt; - trb->TexImage->FetchTexelf(trb->TexImage, x[i], y[i] + trb->Yoffset, + trb->Fetchf(trb->TexImage, x[i], y[i] + trb->Yoffset, z, &flt); zValues[i] = (GLushort) (flt * 0xffff); } @@ -130,7 +132,7 @@ texture_get_values(struct gl_context *ctx, struct gl_renderbuffer *rb, GLuint co GLuint *zValues = (GLuint *) values; for (i = 0; i < count; i++) { GLfloat flt; - trb->TexImage->FetchTexelf(trb->TexImage, x[i], y[i] + trb->Yoffset, + trb->Fetchf(trb->TexImage, x[i], y[i] + trb->Yoffset, z, &flt); #if 0 zValues[i] = (GLuint) (flt * 0xffffffff); @@ -143,7 +145,7 @@ texture_get_values(struct gl_context *ctx, struct gl_renderbuffer *rb, GLuint co GLuint *zValues = (GLuint *) values; for (i = 0; i < count; i++) { GLfloat flt; - trb->TexImage->FetchTexelf(trb->TexImage, x[i], y[i] + trb->Yoffset, + trb->Fetchf(trb->TexImage, x[i], y[i] + trb->Yoffset, z, &flt); zValues[i] = ((GLuint) (flt * 0xffffff)) << 8; } @@ -152,7 +154,7 @@ texture_get_values(struct gl_context *ctx, struct gl_renderbuffer *rb, GLuint co GLuint *zValues = (GLuint *) values; for (i = 0; i < count; i++) { GLfloat flt; - trb->TexImage->FetchTexelf(trb->TexImage, x[i], y[i] + trb->Yoffset, + trb->Fetchf(trb->TexImage, x[i], y[i] + trb->Yoffset, z, &flt); zValues[i] = (GLuint) (flt * 0xffffff); } @@ -517,8 +519,6 @@ wrap_texture(struct gl_context *ctx, struct gl_renderbuffer_attachment *att) _mesa_reference_renderbuffer(&att->Renderbuffer, &(trb->Base)); } - - /** * Update the renderbuffer wrapper for rendering to a texture. * For example, update the width, height of the RB based on the texture size, @@ -542,6 +542,8 @@ update_wrapper(struct gl_context *ctx, const struct gl_renderbuffer_attachment * trb->Store = store_nop; } + trb->Fetchf = trb->TexImage->FetchTexelf; + if (att->Texture->Target == GL_TEXTURE_1D_ARRAY_EXT) { trb->Yoffset = att->Zoffset; trb->Zoffset = 0; @@ -582,6 +584,22 @@ update_wrapper(struct gl_context *ctx, const struct gl_renderbuffer_attachment * trb->Base.DataType = GL_UNSIGNED_INT; trb->Base._BaseFormat = GL_DEPTH_COMPONENT; break; + /* SRGB formats pre EXT_framebuffer_sRGB don't do sRGB translations on FBO readback */ + case MESA_FORMAT_SRGB8: + trb->Fetchf = _mesa_get_texel_fetch_func(MESA_FORMAT_RGB888, _mesa_get_texture_dimensions(att->Texture->Target)); + trb->Base.DataType = CHAN_TYPE; + trb->Base._BaseFormat = GL_RGBA; + break; + case MESA_FORMAT_SRGBA8: + trb->Fetchf = _mesa_get_texel_fetch_func(MESA_FORMAT_RGBA8888, _mesa_get_texture_dimensions(att->Texture->Target)); + trb->Base.DataType = CHAN_TYPE; + trb->Base._BaseFormat = GL_RGBA; + break; + case MESA_FORMAT_SARGB8: + trb->Fetchf = _mesa_get_texel_fetch_func(MESA_FORMAT_ARGB8888, _mesa_get_texture_dimensions(att->Texture->Target)); + trb->Base.DataType = CHAN_TYPE; + trb->Base._BaseFormat = GL_RGBA; + break; default: trb->Base.DataType = CHAN_TYPE; trb->Base._BaseFormat = GL_RGBA; diff --git a/src/mesa/main/texstate.c b/src/mesa/main/texstate.c index f4d77189f2..41d531f597 100644 --- a/src/mesa/main/texstate.c +++ b/src/mesa/main/texstate.c @@ -818,9 +818,6 @@ _mesa_free_texture_data(struct gl_context *ctx) /* Free proxy texture objects */ for (tgt = 0; tgt < NUM_TEXTURE_TARGETS; tgt++) ctx->Driver.DeleteTexture(ctx, ctx->Texture.ProxyTex[tgt]); - - for (u = 0; u < Elements(ctx->Texture.Unit); u++) - _mesa_free_colortable_data(&ctx->Texture.Unit[u].ColorTable); } diff --git a/src/mesa/main/texstore.c b/src/mesa/main/texstore.c index 89677c519e..591759149a 100644 --- a/src/mesa/main/texstore.c +++ b/src/mesa/main/texstore.c @@ -58,11 +58,15 @@ #include "image.h" #include "macros.h" #include "mipmap.h" +#include "mfeatures.h" +#include "mtypes.h" #include "pack.h" +#include "pbo.h" #include "imports.h" #include "pack.h" #include "texcompress.h" #include "texcompress_fxt1.h" +#include "texcompress_rgtc.h" #include "texcompress_s3tc.h" #include "teximage.h" #include "texstore.h" @@ -308,15 +312,15 @@ compute_component_mapping(GLenum inFormat, GLenum outFormat, * \param srcPacking source image pixel packing * \return resulting image with format = textureBaseFormat and type = GLfloat. */ -static GLfloat * -make_temp_float_image(struct gl_context *ctx, GLuint dims, - GLenum logicalBaseFormat, - GLenum textureBaseFormat, - GLint srcWidth, GLint srcHeight, GLint srcDepth, - GLenum srcFormat, GLenum srcType, - const GLvoid *srcAddr, - const struct gl_pixelstore_attrib *srcPacking, - GLbitfield transferOps) +GLfloat * +_mesa_make_temp_float_image(struct gl_context *ctx, GLuint dims, + GLenum logicalBaseFormat, + GLenum textureBaseFormat, + GLint srcWidth, GLint srcHeight, GLint srcDepth, + GLenum srcFormat, GLenum srcType, + const GLvoid *srcAddr, + const struct gl_pixelstore_attrib *srcPacking, + GLbitfield transferOps) { GLfloat *tempImage; const GLint components = _mesa_components_in_format(logicalBaseFormat); @@ -2038,6 +2042,132 @@ _mesa_texstore_argb1555(TEXSTORE_PARAMS) } +static GLboolean +_mesa_texstore_argb2101010(TEXSTORE_PARAMS) +{ + const GLuint texelBytes = _mesa_get_format_bytes(dstFormat); + const GLenum baseFormat = _mesa_get_format_base_format(dstFormat); + + ASSERT(dstFormat == MESA_FORMAT_ARGB2101010); + ASSERT(texelBytes == 4); + + if (!ctx->_ImageTransferState && + !srcPacking->SwapBytes && + dstFormat == MESA_FORMAT_ARGB2101010 && + srcFormat == GL_BGRA && + srcType == GL_UNSIGNED_INT_2_10_10_10_REV && + baseInternalFormat == GL_RGBA) { + /* simple memcpy path */ + memcpy_texture(ctx, dims, + dstFormat, dstAddr, dstXoffset, dstYoffset, dstZoffset, + dstRowStride, + dstImageOffsets, + srcWidth, srcHeight, srcDepth, srcFormat, srcType, + srcAddr, srcPacking); + } + else { + /* general path */ + const GLfloat *tempImage = _mesa_make_temp_float_image(ctx, dims, + baseInternalFormat, + baseFormat, + srcWidth, srcHeight, srcDepth, + srcFormat, srcType, srcAddr, + srcPacking, + ctx->_ImageTransferState); + const GLfloat *src = tempImage; + GLint img, row, col; + if (!tempImage) + return GL_FALSE; + for (img = 0; img < srcDepth; img++) { + GLubyte *dstRow = (GLubyte *) dstAddr + + dstImageOffsets[dstZoffset + img] * texelBytes + + dstYoffset * dstRowStride + + dstXoffset * texelBytes; + if (baseInternalFormat == GL_RGBA) { + for (row = 0; row < srcHeight; row++) { + GLuint *dstUI = (GLuint *) dstRow; + for (col = 0; col < srcWidth; col++) { + GLushort a,r,g,b; + + UNCLAMPED_FLOAT_TO_USHORT(a, src[ACOMP]); + UNCLAMPED_FLOAT_TO_USHORT(r, src[RCOMP]); + UNCLAMPED_FLOAT_TO_USHORT(g, src[GCOMP]); + UNCLAMPED_FLOAT_TO_USHORT(b, src[BCOMP]); + dstUI[col] = PACK_COLOR_2101010_US(a, r, g, b); + src += 4; + } + dstRow += dstRowStride; + } + } else if (baseInternalFormat == GL_RGB) { + for (row = 0; row < srcHeight; row++) { + GLuint *dstUI = (GLuint *) dstRow; + for (col = 0; col < srcWidth; col++) { + GLushort r,g,b; + + UNCLAMPED_FLOAT_TO_USHORT(r, src[RCOMP]); + UNCLAMPED_FLOAT_TO_USHORT(g, src[GCOMP]); + UNCLAMPED_FLOAT_TO_USHORT(b, src[BCOMP]); + dstUI[col] = PACK_COLOR_2101010_US(0xffff, r, g, b); + src += 4; + } + dstRow += dstRowStride; + } + } else { + ASSERT(0); + } + } + free((void *) tempImage); + } + return GL_TRUE; +} + + +/** + * Do texstore for 2-channel, 4-bit/channel, unsigned normalized formats. + */ +static GLboolean +_mesa_texstore_unorm44(TEXSTORE_PARAMS) +{ + const GLuint texelBytes = _mesa_get_format_bytes(dstFormat); + const GLenum baseFormat = _mesa_get_format_base_format(dstFormat); + + ASSERT(dstFormat == MESA_FORMAT_AL44); + ASSERT(texelBytes == 1); + + { + /* general path */ + const GLchan *tempImage = _mesa_make_temp_chan_image(ctx, dims, + baseInternalFormat, + baseFormat, + srcWidth, srcHeight, srcDepth, + srcFormat, srcType, srcAddr, + srcPacking); + const GLchan *src = tempImage; + GLint img, row, col; + if (!tempImage) + return GL_FALSE; + for (img = 0; img < srcDepth; img++) { + GLubyte *dstRow = (GLubyte *) dstAddr + + dstImageOffsets[dstZoffset + img] * texelBytes + + dstYoffset * dstRowStride + + dstXoffset * texelBytes; + for (row = 0; row < srcHeight; row++) { + GLubyte *dstUS = (GLubyte *) dstRow; + for (col = 0; col < srcWidth; col++) { + /* src[0] is luminance, src[1] is alpha */ + dstUS[col] = PACK_COLOR_44( CHAN_TO_UBYTE(src[1]), + CHAN_TO_UBYTE(src[0]) ); + src += 2; + } + dstRow += dstRowStride; + } + } + free((void *) tempImage); + } + return GL_TRUE; +} + + /** * Do texstore for 2-channel, 8-bit/channel, unsigned normalized formats. */ @@ -2189,7 +2319,7 @@ _mesa_texstore_unorm1616(TEXSTORE_PARAMS) } else { /* general path */ - const GLfloat *tempImage = make_temp_float_image(ctx, dims, + const GLfloat *tempImage = _mesa_make_temp_float_image(ctx, dims, baseInternalFormat, baseFormat, srcWidth, srcHeight, srcDepth, @@ -2237,21 +2367,23 @@ _mesa_texstore_unorm1616(TEXSTORE_PARAMS) } +/* Texstore for R16, A16, L16, I16. */ static GLboolean -_mesa_texstore_r16(TEXSTORE_PARAMS) +_mesa_texstore_unorm16(TEXSTORE_PARAMS) { const GLboolean littleEndian = _mesa_little_endian(); const GLuint texelBytes = _mesa_get_format_bytes(dstFormat); const GLenum baseFormat = _mesa_get_format_base_format(dstFormat); - ASSERT(dstFormat == MESA_FORMAT_R16); + ASSERT(dstFormat == MESA_FORMAT_R16 || + dstFormat == MESA_FORMAT_A16 || + dstFormat == MESA_FORMAT_L16 || + dstFormat == MESA_FORMAT_I16); ASSERT(texelBytes == 2); if (!ctx->_ImageTransferState && !srcPacking->SwapBytes && - dstFormat == MESA_FORMAT_R16 && - baseInternalFormat == GL_RED && - srcFormat == GL_RED && + baseInternalFormat == srcFormat && srcType == GL_UNSIGNED_SHORT && littleEndian) { /* simple memcpy path */ @@ -2264,7 +2396,7 @@ _mesa_texstore_r16(TEXSTORE_PARAMS) } else { /* general path */ - const GLfloat *tempImage = make_temp_float_image(ctx, dims, + const GLfloat *tempImage = _mesa_make_temp_float_image(ctx, dims, baseInternalFormat, baseFormat, srcWidth, srcHeight, srcDepth, @@ -2322,7 +2454,7 @@ _mesa_texstore_rgba_16(TEXSTORE_PARAMS) } else { /* general path */ - const GLfloat *tempImage = make_temp_float_image(ctx, dims, + const GLfloat *tempImage = _mesa_make_temp_float_image(ctx, dims, baseInternalFormat, baseFormat, srcWidth, srcHeight, srcDepth, @@ -2389,7 +2521,7 @@ _mesa_texstore_signed_rgba_16(TEXSTORE_PARAMS) } else { /* general path */ - const GLfloat *tempImage = make_temp_float_image(ctx, dims, + const GLfloat *tempImage = _mesa_make_temp_float_image(ctx, dims, baseInternalFormat, baseFormat, srcWidth, srcHeight, srcDepth, @@ -2489,7 +2621,7 @@ _mesa_texstore_rgb332(TEXSTORE_PARAMS) * Texstore for _mesa_texformat_a8, _mesa_texformat_l8, _mesa_texformat_i8. */ static GLboolean -_mesa_texstore_a8(TEXSTORE_PARAMS) +_mesa_texstore_unorm8(TEXSTORE_PARAMS) { const GLuint texelBytes = _mesa_get_format_bytes(dstFormat); const GLenum baseFormat = _mesa_get_format_base_format(dstFormat); @@ -2771,7 +2903,7 @@ _mesa_texstore_signed_r8(TEXSTORE_PARAMS) /* XXX look at adding optimized paths */ { /* general path */ - const GLfloat *tempImage = make_temp_float_image(ctx, dims, + const GLfloat *tempImage = _mesa_make_temp_float_image(ctx, dims, baseInternalFormat, baseFormat, srcWidth, srcHeight, srcDepth, @@ -2816,7 +2948,7 @@ _mesa_texstore_signed_rg88(TEXSTORE_PARAMS) /* XXX look at adding optimized paths */ { /* general path */ - const GLfloat *tempImage = make_temp_float_image(ctx, dims, + const GLfloat *tempImage = _mesa_make_temp_float_image(ctx, dims, baseInternalFormat, baseFormat, srcWidth, srcHeight, srcDepth, @@ -2861,7 +2993,7 @@ _mesa_texstore_signed_rgbx8888(TEXSTORE_PARAMS) { /* general path */ - const GLfloat *tempImage = make_temp_float_image(ctx, dims, + const GLfloat *tempImage = _mesa_make_temp_float_image(ctx, dims, baseInternalFormat, baseFormat, srcWidth, srcHeight, srcDepth, @@ -2974,7 +3106,7 @@ _mesa_texstore_signed_rgba8888(TEXSTORE_PARAMS) } else { /* general path */ - const GLfloat *tempImage = make_temp_float_image(ctx, dims, + const GLfloat *tempImage = _mesa_make_temp_float_image(ctx, dims, baseInternalFormat, baseFormat, srcWidth, srcHeight, srcDepth, @@ -3283,7 +3415,7 @@ _mesa_texstore_rgba_float32(TEXSTORE_PARAMS) } else { /* general path */ - const GLfloat *tempImage = make_temp_float_image(ctx, dims, + const GLfloat *tempImage = _mesa_make_temp_float_image(ctx, dims, baseInternalFormat, baseFormat, srcWidth, srcHeight, srcDepth, @@ -3353,7 +3485,7 @@ _mesa_texstore_rgba_float16(TEXSTORE_PARAMS) } else { /* general path */ - const GLfloat *tempImage = make_temp_float_image(ctx, dims, + const GLfloat *tempImage = _mesa_make_temp_float_image(ctx, dims, baseInternalFormat, baseFormat, srcWidth, srcHeight, srcDepth, @@ -3419,7 +3551,7 @@ _mesa_texstore_rgba_int8(TEXSTORE_PARAMS) } else { /* general path */ - const GLfloat *tempImage = make_temp_float_image(ctx, dims, + const GLfloat *tempImage = _mesa_make_temp_float_image(ctx, dims, baseInternalFormat, baseFormat, srcWidth, srcHeight, srcDepth, @@ -3484,7 +3616,7 @@ _mesa_texstore_rgba_int16(TEXSTORE_PARAMS) } else { /* general path */ - const GLfloat *tempImage = make_temp_float_image(ctx, dims, + const GLfloat *tempImage = _mesa_make_temp_float_image(ctx, dims, baseInternalFormat, baseFormat, srcWidth, srcHeight, srcDepth, @@ -3549,7 +3681,7 @@ _mesa_texstore_rgba_int32(TEXSTORE_PARAMS) } else { /* general path */ - const GLfloat *tempImage = make_temp_float_image(ctx, dims, + const GLfloat *tempImage = _mesa_make_temp_float_image(ctx, dims, baseInternalFormat, baseFormat, srcWidth, srcHeight, srcDepth, @@ -3849,7 +3981,7 @@ _mesa_texstore_sl8(TEXSTORE_PARAMS) newDstFormat = MESA_FORMAT_L8; /* _mesa_textore_a8 handles luminance8 too */ - k = _mesa_texstore_a8(ctx, dims, baseInternalFormat, + k = _mesa_texstore_unorm8(ctx, dims, baseInternalFormat, newDstFormat, dstAddr, dstXoffset, dstYoffset, dstZoffset, dstRowStride, dstImageOffsets, @@ -3921,23 +4053,28 @@ texstore_funcs[MESA_FORMAT_COUNT] = { MESA_FORMAT_RGBA5551, _mesa_texstore_rgba5551 }, { MESA_FORMAT_ARGB1555, _mesa_texstore_argb1555 }, { MESA_FORMAT_ARGB1555_REV, _mesa_texstore_argb1555 }, + { MESA_FORMAT_AL44, _mesa_texstore_unorm44 }, { MESA_FORMAT_AL88, _mesa_texstore_unorm88 }, { MESA_FORMAT_AL88_REV, _mesa_texstore_unorm88 }, { MESA_FORMAT_AL1616, _mesa_texstore_unorm1616 }, { MESA_FORMAT_AL1616_REV, _mesa_texstore_unorm1616 }, { MESA_FORMAT_RGB332, _mesa_texstore_rgb332 }, - { MESA_FORMAT_A8, _mesa_texstore_a8 }, - { MESA_FORMAT_L8, _mesa_texstore_a8 }, - { MESA_FORMAT_I8, _mesa_texstore_a8 }, + { MESA_FORMAT_A8, _mesa_texstore_unorm8 }, + { MESA_FORMAT_A16, _mesa_texstore_unorm16 }, + { MESA_FORMAT_L8, _mesa_texstore_unorm8 }, + { MESA_FORMAT_L16, _mesa_texstore_unorm16 }, + { MESA_FORMAT_I8, _mesa_texstore_unorm8 }, + { MESA_FORMAT_I16, _mesa_texstore_unorm16 }, { MESA_FORMAT_CI8, _mesa_texstore_ci8 }, { MESA_FORMAT_YCBCR, _mesa_texstore_ycbcr }, { MESA_FORMAT_YCBCR_REV, _mesa_texstore_ycbcr }, - { MESA_FORMAT_R8, _mesa_texstore_a8 }, + { MESA_FORMAT_R8, _mesa_texstore_unorm8 }, { MESA_FORMAT_RG88, _mesa_texstore_unorm88 }, { MESA_FORMAT_RG88_REV, _mesa_texstore_unorm88 }, - { MESA_FORMAT_R16, _mesa_texstore_r16 }, + { MESA_FORMAT_R16, _mesa_texstore_unorm16 }, { MESA_FORMAT_RG1616, _mesa_texstore_unorm1616 }, { MESA_FORMAT_RG1616_REV, _mesa_texstore_unorm1616 }, + { MESA_FORMAT_ARGB2101010, _mesa_texstore_argb2101010 }, { MESA_FORMAT_Z24_S8, _mesa_texstore_z24_s8 }, { MESA_FORMAT_S8_Z24, _mesa_texstore_s8_z24 }, { MESA_FORMAT_Z16, _mesa_texstore_z16 }, @@ -3993,7 +4130,19 @@ texstore_funcs[MESA_FORMAT_COUNT] = { MESA_FORMAT_SIGNED_RG_16, _mesa_texstore_signed_rgba_16 }, { MESA_FORMAT_SIGNED_RGB_16, _mesa_texstore_signed_rgba_16 }, { MESA_FORMAT_SIGNED_RGBA_16, _mesa_texstore_signed_rgba_16 }, - { MESA_FORMAT_RGBA_16, _mesa_texstore_rgba_16 } + { MESA_FORMAT_RGBA_16, _mesa_texstore_rgba_16 }, + + { MESA_FORMAT_RED_RGTC1, _mesa_texstore_red_rgtc1 }, + { MESA_FORMAT_SIGNED_RED_RGTC1, _mesa_texstore_signed_red_rgtc1 }, + { MESA_FORMAT_RG_RGTC2, _mesa_texstore_rg_rgtc2 }, + { MESA_FORMAT_SIGNED_RG_RGTC2, _mesa_texstore_signed_rg_rgtc2 }, + + /* Re-use the R/RG texstore functions. + * The code is generic enough to handle LATC too. */ + { MESA_FORMAT_L_LATC1, _mesa_texstore_red_rgtc1 }, + { MESA_FORMAT_SIGNED_L_LATC1, _mesa_texstore_signed_red_rgtc1 }, + { MESA_FORMAT_LA_LATC2, _mesa_texstore_rg_rgtc2 }, + { MESA_FORMAT_SIGNED_LA_LATC2, _mesa_texstore_signed_rg_rgtc2 } }; @@ -4059,94 +4208,6 @@ _mesa_texstore(TEXSTORE_PARAMS) } -/** - * Check if an unpack PBO is active prior to fetching a texture image. - * If so, do bounds checking and map the buffer into main memory. - * Any errors detected will be recorded. - * The caller _must_ call _mesa_unmap_teximage_pbo() too! - */ -const GLvoid * -_mesa_validate_pbo_teximage(struct gl_context *ctx, GLuint dimensions, - GLsizei width, GLsizei height, GLsizei depth, - GLenum format, GLenum type, const GLvoid *pixels, - const struct gl_pixelstore_attrib *unpack, - const char *funcName) -{ - GLubyte *buf; - - if (!_mesa_is_bufferobj(unpack->BufferObj)) { - /* no PBO */ - return pixels; - } - if (!_mesa_validate_pbo_access(dimensions, unpack, width, height, depth, - format, type, pixels)) { - _mesa_error(ctx, GL_INVALID_OPERATION, funcName, "(invalid PBO access)"); - return NULL; - } - - buf = (GLubyte *) ctx->Driver.MapBuffer(ctx, GL_PIXEL_UNPACK_BUFFER_EXT, - GL_READ_ONLY_ARB, unpack->BufferObj); - if (!buf) { - _mesa_error(ctx, GL_INVALID_OPERATION, funcName, "(PBO is mapped)"); - return NULL; - } - - return ADD_POINTERS(buf, pixels); -} - - -/** - * Check if an unpack PBO is active prior to fetching a compressed texture - * image. - * If so, do bounds checking and map the buffer into main memory. - * Any errors detected will be recorded. - * The caller _must_ call _mesa_unmap_teximage_pbo() too! - */ -const GLvoid * -_mesa_validate_pbo_compressed_teximage(struct gl_context *ctx, - GLsizei imageSize, const GLvoid *pixels, - const struct gl_pixelstore_attrib *packing, - const char *funcName) -{ - GLubyte *buf; - - if (!_mesa_is_bufferobj(packing->BufferObj)) { - /* not using a PBO - return pointer unchanged */ - return pixels; - } - if ((const GLubyte *) pixels + imageSize > - ((const GLubyte *) 0) + packing->BufferObj->Size) { - /* out of bounds read! */ - _mesa_error(ctx, GL_INVALID_OPERATION, funcName, "(invalid PBO access)"); - return NULL; - } - - buf = (GLubyte*) ctx->Driver.MapBuffer(ctx, GL_PIXEL_UNPACK_BUFFER_EXT, - GL_READ_ONLY_ARB, packing->BufferObj); - if (!buf) { - _mesa_error(ctx, GL_INVALID_OPERATION, funcName, "(PBO is mapped"); - return NULL; - } - - return ADD_POINTERS(buf, pixels); -} - - -/** - * This function must be called after either of the validate_pbo_*_teximage() - * functions. It unmaps the PBO buffer if it was mapped earlier. - */ -void -_mesa_unmap_teximage_pbo(struct gl_context *ctx, - const struct gl_pixelstore_attrib *unpack) -{ - if (_mesa_is_bufferobj(unpack->BufferObj)) { - ctx->Driver.UnmapBuffer(ctx, GL_PIXEL_UNPACK_BUFFER_EXT, - unpack->BufferObj); - } -} - - /** Return texture size in bytes */ static GLuint texture_size(const struct gl_texture_image *texImage) diff --git a/src/mesa/main/texstore.h b/src/mesa/main/texstore.h index 177ede423f..d563187098 100644 --- a/src/mesa/main/texstore.h +++ b/src/mesa/main/texstore.h @@ -81,6 +81,15 @@ _mesa_make_temp_chan_image(struct gl_context *ctx, GLuint dims, const GLvoid *srcAddr, const struct gl_pixelstore_attrib *srcPacking); +GLfloat * +_mesa_make_temp_float_image(struct gl_context *ctx, GLuint dims, + GLenum logicalBaseFormat, + GLenum textureBaseFormat, + GLint srcWidth, GLint srcHeight, GLint srcDepth, + GLenum srcFormat, GLenum srcType, + const GLvoid *srcAddr, + const struct gl_pixelstore_attrib *srcPacking, + GLbitfield transferOps); extern void _mesa_store_teximage1d(struct gl_context *ctx, GLenum target, GLint level, @@ -197,22 +206,4 @@ _mesa_store_compressed_texsubimage3d(struct gl_context *ctx, GLenum target, struct gl_texture_image *texImage); -extern const GLvoid * -_mesa_validate_pbo_teximage(struct gl_context *ctx, GLuint dimensions, - GLsizei width, GLsizei height, GLsizei depth, - GLenum format, GLenum type, const GLvoid *pixels, - const struct gl_pixelstore_attrib *unpack, - const char *funcName); - -extern const GLvoid * -_mesa_validate_pbo_compressed_teximage(struct gl_context *ctx, - GLsizei imageSize, const GLvoid *pixels, - const struct gl_pixelstore_attrib *packing, - const char *funcName); - -extern void -_mesa_unmap_teximage_pbo(struct gl_context *ctx, - const struct gl_pixelstore_attrib *unpack); - - #endif diff --git a/src/mesa/main/texturebarrier.c b/src/mesa/main/texturebarrier.c new file mode 100644 index 0000000000..56cc8718ca --- /dev/null +++ b/src/mesa/main/texturebarrier.c @@ -0,0 +1,54 @@ +/* + * Copyright © 2011 Marek Olšák <maraeo@gmail.com> + * + * Permission is hereby granted, free of charge, to any person obtaining a + * copy of this software and associated documentation files (the "Software"), + * to deal in the Software without restriction, including without limitation + * the rights to use, copy, modify, merge, publish, distribute, sublicense, + * and/or sell copies of the Software, and to permit persons to whom the + * Software is furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice (including the next + * paragraph) shall be included in all copies or substantial portions of the + * Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL + * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER + * DEALINGS IN THE SOFTWARE. + */ + +/** + * \file texturebarrier.c + * Implementation of glTextureBarrierNV. + * + * \author Marek Olšák <maraeo@gmail.com> + */ + +#include "context.h" +#include "texturebarrier.h" + + +static void +_mesa_texture_barrier(struct gl_context *ctx) +{ + /* no-op */ +} + +void +_mesa_init_texture_barrier_functions(struct dd_function_table *driver) +{ + driver->TextureBarrier = _mesa_texture_barrier; +} + +void GLAPIENTRY +_mesa_TextureBarrierNV(void) +{ + GET_CURRENT_CONTEXT(ctx); + ASSERT_OUTSIDE_BEGIN_END(ctx); + + ctx->Driver.TextureBarrier(ctx); +} diff --git a/src/mesa/main/texturebarrier.h b/src/mesa/main/texturebarrier.h new file mode 100644 index 0000000000..a84a85b217 --- /dev/null +++ b/src/mesa/main/texturebarrier.h @@ -0,0 +1,44 @@ +/* + * Copyright © 2011 Marek Olšák <maraeo@gmail.com> + * + * Permission is hereby granted, free of charge, to any person obtaining a + * copy of this software and associated documentation files (the "Software"), + * to deal in the Software without restriction, including without limitation + * the rights to use, copy, modify, merge, publish, distribute, sublicense, + * and/or sell copies of the Software, and to permit persons to whom the + * Software is furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice (including the next + * paragraph) shall be included in all copies or substantial portions of the + * Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL + * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER + * DEALINGS IN THE SOFTWARE. + */ + +/** + * \file texturebarrier.h + * GL_NV_texture_barrier + * + * \author Marek Olšák <maraeo@gmail.com> + */ + +#ifndef TEXTUREBARRIER_H +#define TEXTUREBARRIER_H + +#include "glheader.h" + +struct dd_function_table; + +extern void +_mesa_init_texture_barrier_functions(struct dd_function_table *driver); + +extern void GLAPIENTRY +_mesa_TextureBarrierNV(void); + +#endif /* TEXTUREBARRIER_H */ diff --git a/src/mesa/main/transformfeedback.c b/src/mesa/main/transformfeedback.c index d297b5ed71..fbd70d56ca 100644 --- a/src/mesa/main/transformfeedback.c +++ b/src/mesa/main/transformfeedback.c @@ -34,6 +34,8 @@ #include "bufferobj.h" #include "context.h" #include "hash.h" +#include "mfeatures.h" +#include "mtypes.h" #include "transformfeedback.h" #include "shaderapi.h" #include "shaderobj.h" diff --git a/src/mesa/main/uniforms.c b/src/mesa/main/uniforms.c index d61856d0eb..1d74efafdf 100644 --- a/src/mesa/main/uniforms.c +++ b/src/mesa/main/uniforms.c @@ -39,6 +39,8 @@ #include "main/glheader.h" #include "main/context.h" #include "main/dispatch.h" +#include "main/mfeatures.h" +#include "main/mtypes.h" #include "main/shaderapi.h" #include "main/shaderobj.h" #include "main/uniforms.h" @@ -207,6 +209,18 @@ static struct gl_builtin_uniform_element gl_NormalScale_elements[] = { {NULL, {STATE_NORMAL_SCALE}, SWIZZLE_XXXX}, }; +static struct gl_builtin_uniform_element gl_MESABumpRotMatrix0_elements[] = { + {NULL, {STATE_INTERNAL, STATE_ROT_MATRIX_0}, SWIZZLE_XYZW}, +}; + +static struct gl_builtin_uniform_element gl_MESABumpRotMatrix1_elements[] = { + {NULL, {STATE_INTERNAL, STATE_ROT_MATRIX_1}, SWIZZLE_XYZW}, +}; + +static struct gl_builtin_uniform_element gl_MESAFogParamsOptimized_elements[] = { + {NULL, {STATE_INTERNAL, STATE_FOG_PARAMS_OPTIMIZED}, SWIZZLE_XYZW}, +}; + #define MATRIX(name, statevar, modifier) \ static struct gl_builtin_uniform_element name ## _elements[] = { \ { NULL, { statevar, 0, 0, 0, modifier}, SWIZZLE_XYZW }, \ @@ -310,6 +324,10 @@ const struct gl_builtin_uniform_desc _mesa_builtin_uniform_desc[] = { STATEVAR(gl_NormalMatrix), STATEVAR(gl_NormalScale), + STATEVAR(gl_MESABumpRotMatrix0), + STATEVAR(gl_MESABumpRotMatrix1), + STATEVAR(gl_MESAFogParamsOptimized), + {NULL, NULL, 0} }; @@ -448,6 +466,36 @@ _mesa_get_active_uniform(struct gl_context *ctx, GLuint program, GLuint index, } +static unsigned +get_vector_elements(GLenum type) +{ + switch (type) { + case GL_FLOAT: + case GL_INT: + case GL_BOOL: + case GL_UNSIGNED_INT: + default: /* Catch all the various sampler types. */ + return 1; + + case GL_FLOAT_VEC2: + case GL_INT_VEC2: + case GL_BOOL_VEC2: + case GL_UNSIGNED_INT_VEC2: + return 2; + + case GL_FLOAT_VEC3: + case GL_INT_VEC3: + case GL_BOOL_VEC3: + case GL_UNSIGNED_INT_VEC3: + return 3; + + case GL_FLOAT_VEC4: + case GL_INT_VEC4: + case GL_BOOL_VEC4: + case GL_UNSIGNED_INT_VEC4: + return 4; + } +} static void get_matrix_dims(GLenum type, GLint *rows, GLint *cols) @@ -506,17 +554,8 @@ get_uniform_rows_cols(const struct gl_program_parameter *p, get_matrix_dims(p->DataType, rows, cols); if (*rows == 0 && *cols == 0) { /* not a matrix type, probably a float or vector */ - if (p->Size <= 4) { - *rows = 1; - *cols = p->Size; - } - else { - *rows = p->Size / 4 + 1; - if (p->Size % 4 == 0) - *cols = 4; - else - *cols = p->Size % 4; - } + *rows = 1; + *cols = get_vector_elements(p->DataType); } } @@ -640,8 +679,10 @@ _mesa_get_uniformfv(struct gl_context *ctx, GLuint program, GLint location, k = 0; for (i = 0; i < rows; i++) { + const int base = paramPos + offset + i; + for (j = 0; j < cols; j++ ) { - params[k++] = prog->Parameters->ParameterValues[paramPos+i][j]; + params[k++] = prog->Parameters->ParameterValues[base][j]; } } } @@ -673,8 +714,10 @@ _mesa_get_uniformiv(struct gl_context *ctx, GLuint program, GLint location, k = 0; for (i = 0; i < rows; i++) { + const int base = paramPos + offset + i; + for (j = 0; j < cols; j++ ) { - params[k++] = (GLint) prog->Parameters->ParameterValues[paramPos+i][j]; + params[k++] = (GLint) prog->Parameters->ParameterValues[base][j]; } } } @@ -707,8 +750,10 @@ _mesa_get_uniformuiv(struct gl_context *ctx, GLuint program, GLint location, k = 0; for (i = 0; i < rows; i++) { + const int base = paramPos + offset + i; + for (j = 0; j < cols; j++ ) { - params[k++] = (GLuint) prog->Parameters->ParameterValues[paramPos+i][j]; + params[k++] = (GLuint) prog->Parameters->ParameterValues[base][j]; } } } diff --git a/src/mesa/main/varray.c b/src/mesa/main/varray.c index 2728b38226..cfed4b506a 100644 --- a/src/mesa/main/varray.c +++ b/src/mesa/main/varray.c @@ -33,6 +33,7 @@ #include "hash.h" #include "image.h" #include "macros.h" +#include "mfeatures.h" #include "mtypes.h" #include "varray.h" #include "arrayobj.h" @@ -127,8 +128,8 @@ update_array(struct gl_context *ctx, GLsizei elementSize; GLenum format = GL_RGBA; - if (ctx->API != API_OPENGLES) { - /* fixed point arrays / data is only allowed with OpenGL ES 1.x */ + if (ctx->API != API_OPENGLES && ctx->API != API_OPENGLES2) { + /* fixed point arrays / data is only allowed with OpenGL ES 1.x/2.0 */ legalTypesMask &= ~FIXED_BIT; } @@ -507,7 +508,7 @@ get_vertex_array_attrib(struct gl_context *ctx, GLuint index, GLenum pname, { const struct gl_client_array *array; - if (index >= MAX_VERTEX_GENERIC_ATTRIBS) { + if (index >= ctx->Const.VertexProgram.MaxAttribs) { _mesa_error(ctx, GL_INVALID_VALUE, "%s(index=%u)", caller, index); return 0; } @@ -533,14 +534,41 @@ get_vertex_array_attrib(struct gl_context *ctx, GLuint index, GLenum pname, if (ctx->Extensions.EXT_gpu_shader4) { return array->Integer; } - /* fall-through */ + goto error; + case GL_VERTEX_ATTRIB_ARRAY_DIVISOR_ARB: + if (ctx->Extensions.ARB_instanced_arrays) { + return array->InstanceDivisor; + } + goto error; default: - _mesa_error(ctx, GL_INVALID_ENUM, "%s(pname=0x%x)", caller, pname); - return 0; + ; /* fall-through */ } + +error: + _mesa_error(ctx, GL_INVALID_ENUM, "%s(pname=0x%x)", caller, pname); + return 0; } +static const GLfloat * +get_current_attrib(struct gl_context *ctx, GLuint index, const char *function) +{ + if (index == 0) { + if (ctx->API != API_OPENGLES2) { + _mesa_error(ctx, GL_INVALID_OPERATION, "%s(index==0)", function); + return NULL; + } + } + else if (index >= ctx->Const.VertexProgram.MaxAttribs) { + _mesa_error(ctx, GL_INVALID_VALUE, + "%s(index>=GL_MAX_VERTEX_ATTRIBS)", function); + return NULL; + } + + FLUSH_CURRENT(ctx, 0); + return ctx->Current.Attrib[VERT_ATTRIB_GENERIC0 + index]; +} + void GLAPIENTRY _mesa_GetVertexAttribfvARB(GLuint index, GLenum pname, GLfloat *params) { @@ -548,13 +576,8 @@ _mesa_GetVertexAttribfvARB(GLuint index, GLenum pname, GLfloat *params) ASSERT_OUTSIDE_BEGIN_END(ctx); if (pname == GL_CURRENT_VERTEX_ATTRIB_ARB) { - if (index == 0) { - _mesa_error(ctx, GL_INVALID_OPERATION, - "glGetVertexAttribfv(index==0)"); - } - else { - const GLfloat *v = ctx->Current.Attrib[VERT_ATTRIB_GENERIC0 + index]; - FLUSH_CURRENT(ctx, 0); + const GLfloat *v = get_current_attrib(ctx, index, "glGetVertexAttribfv"); + if (v != NULL) { COPY_4V(params, v); } } @@ -572,13 +595,8 @@ _mesa_GetVertexAttribdvARB(GLuint index, GLenum pname, GLdouble *params) ASSERT_OUTSIDE_BEGIN_END(ctx); if (pname == GL_CURRENT_VERTEX_ATTRIB_ARB) { - if (index == 0) { - _mesa_error(ctx, GL_INVALID_OPERATION, - "glGetVertexAttribdv(index==0)"); - } - else { - const GLfloat *v = ctx->Current.Attrib[VERT_ATTRIB_GENERIC0 + index]; - FLUSH_CURRENT(ctx, 0); + const GLfloat *v = get_current_attrib(ctx, index, "glGetVertexAttribdv"); + if (v != NULL) { params[0] = (GLdouble) v[0]; params[1] = (GLdouble) v[1]; params[2] = (GLdouble) v[2]; @@ -599,13 +617,8 @@ _mesa_GetVertexAttribivARB(GLuint index, GLenum pname, GLint *params) ASSERT_OUTSIDE_BEGIN_END(ctx); if (pname == GL_CURRENT_VERTEX_ATTRIB_ARB) { - if (index == 0) { - _mesa_error(ctx, GL_INVALID_OPERATION, - "glGetVertexAttribiv(index==0)"); - } - else { - const GLfloat *v = ctx->Current.Attrib[VERT_ATTRIB_GENERIC0 + index]; - FLUSH_CURRENT(ctx, 0); + const GLfloat *v = get_current_attrib(ctx, index, "glGetVertexAttribiv"); + if (v != NULL) { /* XXX should floats in[0,1] be scaled to full int range? */ params[0] = (GLint) v[0]; params[1] = (GLint) v[1]; @@ -628,13 +641,9 @@ _mesa_GetVertexAttribIiv(GLuint index, GLenum pname, GLint *params) ASSERT_OUTSIDE_BEGIN_END(ctx); if (pname == GL_CURRENT_VERTEX_ATTRIB_ARB) { - if (index == 0) { - _mesa_error(ctx, GL_INVALID_OPERATION, - "glGetVertexAttribIiv(index==0)"); - } - else { - const GLfloat *v = ctx->Current.Attrib[VERT_ATTRIB_GENERIC0 + index]; - FLUSH_CURRENT(ctx, 0); + const GLfloat *v = + get_current_attrib(ctx, index, "glGetVertexAttribIiv"); + if (v != NULL) { /* XXX we don't have true integer-valued vertex attribs yet */ params[0] = (GLint) v[0]; params[1] = (GLint) v[1]; @@ -657,13 +666,9 @@ _mesa_GetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params) ASSERT_OUTSIDE_BEGIN_END(ctx); if (pname == GL_CURRENT_VERTEX_ATTRIB_ARB) { - if (index == 0) { - _mesa_error(ctx, GL_INVALID_OPERATION, - "glGetVertexAttribIuiv(index==0)"); - } - else { - const GLfloat *v = ctx->Current.Attrib[VERT_ATTRIB_GENERIC0 + index]; - FLUSH_CURRENT(ctx, 0); + const GLfloat *v = + get_current_attrib(ctx, index, "glGetVertexAttribIuiv"); + if (v != NULL) { /* XXX we don't have true integer-valued vertex attribs yet */ params[0] = (GLuint) v[0]; params[1] = (GLuint) v[1]; @@ -1065,6 +1070,33 @@ _mesa_PrimitiveRestartIndex(GLuint index) /** + * See GL_ARB_instanced_arrays. + * Note that the instance divisor only applies to generic arrays, not + * the legacy vertex arrays. + */ +void GLAPIENTRY +_mesa_VertexAttribDivisor(GLuint index, GLuint divisor) +{ + GET_CURRENT_CONTEXT(ctx); + ASSERT_OUTSIDE_BEGIN_END_AND_FLUSH(ctx); + + if (!ctx->Extensions.ARB_instanced_arrays) { + _mesa_error(ctx, GL_INVALID_OPERATION, "glVertexAttribDivisor()"); + return; + } + + if (index >= ctx->Const.VertexProgram.MaxAttribs) { + _mesa_error(ctx, GL_INVALID_ENUM, "glVertexAttribDivisor(index = %u)", + index); + return; + } + + ctx->Array.ArrayObj->VertexAttrib[index].InstanceDivisor = divisor; +} + + + +/** * Copy one client vertex array to another. */ void @@ -1081,6 +1113,7 @@ _mesa_copy_client_array(struct gl_context *ctx, dst->Enabled = src->Enabled; dst->Normalized = src->Normalized; dst->Integer = src->Integer; + dst->InstanceDivisor = src->InstanceDivisor; dst->_ElementSize = src->_ElementSize; _mesa_reference_buffer_object(ctx, &dst->BufferObj, src->BufferObj); dst->_MaxElement = src->_MaxElement; diff --git a/src/mesa/main/varray.h b/src/mesa/main/varray.h index af9324134e..53e68c8966 100644 --- a/src/mesa/main/varray.h +++ b/src/mesa/main/varray.h @@ -218,6 +218,10 @@ extern void GLAPIENTRY _mesa_PrimitiveRestartIndex(GLuint index); +extern void GLAPIENTRY +_mesa_VertexAttribDivisor(GLuint index, GLuint divisor); + + extern void _mesa_copy_client_array(struct gl_context *ctx, struct gl_client_array *dst, diff --git a/src/mesa/main/version.c b/src/mesa/main/version.c index 69a28da84c..a10b86e761 100644 --- a/src/mesa/main/version.c +++ b/src/mesa/main/version.c @@ -22,7 +22,8 @@ */ -#include "context.h" +#include "imports.h" +#include "mtypes.h" #include "version.h" diff --git a/src/mesa/main/version.h b/src/mesa/main/version.h index 1b53508099..2e6335846e 100644 --- a/src/mesa/main/version.h +++ b/src/mesa/main/version.h @@ -1,6 +1,6 @@ /* * Mesa 3-D graphics library - * Version: 7.10 + * Version: 7.11 * * Copyright (C) 1999-2008 Brian Paul All Rights Reserved. * Copyright (C) 2009 VMware, Inc. All Rights Reserved. @@ -33,9 +33,9 @@ struct gl_context; /* Mesa version */ #define MESA_MAJOR 7 -#define MESA_MINOR 10 +#define MESA_MINOR 11 #define MESA_PATCH 0 -#define MESA_VERSION_STRING "7.10-devel" +#define MESA_VERSION_STRING "7.11-devel" /* To make version comparison easy */ #define MESA_VERSION(a,b,c) (((a) << 16) + ((b) << 8) + (c)) diff --git a/src/mesa/main/viewport.c b/src/mesa/main/viewport.c index 4747022d0b..a58697ab37 100644 --- a/src/mesa/main/viewport.c +++ b/src/mesa/main/viewport.c @@ -31,6 +31,7 @@ #include "context.h" #include "macros.h" +#include "mtypes.h" #include "viewport.h" @@ -145,7 +146,11 @@ _mesa_DepthRange(GLclampd nearval, GLclampd farval) } } - +void GLAPIENTRY +_mesa_DepthRangef(GLclampf nearval, GLclampf farval) +{ + _mesa_DepthRange(nearval, farval); +} /** * Initialize the context viewport attribute group. diff --git a/src/mesa/main/viewport.h b/src/mesa/main/viewport.h index 909ff92eee..db4507beaa 100644 --- a/src/mesa/main/viewport.h +++ b/src/mesa/main/viewport.h @@ -43,6 +43,9 @@ _mesa_set_viewport(struct gl_context *ctx, GLint x, GLint y, extern void GLAPIENTRY _mesa_DepthRange(GLclampd nearval, GLclampd farval); +extern void GLAPIENTRY +_mesa_DepthRangef(GLclampf nearval, GLclampf farval); + extern void _mesa_init_viewport(struct gl_context *ctx); diff --git a/src/mesa/main/vtxfmt.c b/src/mesa/main/vtxfmt.c index 8a72641862..692ce080c9 100644 --- a/src/mesa/main/vtxfmt.c +++ b/src/mesa/main/vtxfmt.c @@ -30,6 +30,7 @@ #include "api_arrayelt.h" #include "context.h" #include "imports.h" +#include "mfeatures.h" #include "mtypes.h" #include "vtxfmt.h" #include "eval.h" diff --git a/src/mesa/main/vtxfmt.h b/src/mesa/main/vtxfmt.h index 147385cee9..8bbc54964d 100644 --- a/src/mesa/main/vtxfmt.h +++ b/src/mesa/main/vtxfmt.h @@ -34,6 +34,7 @@ #define _VTXFMT_H_ #include "compiler.h" +#include "mfeatures.h" #include "mtypes.h" #if FEATURE_beginend |