diff options
author | marha <marha@users.sourceforge.net> | 2012-11-05 07:36:16 +0100 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2012-11-05 07:36:16 +0100 |
commit | 1cc98f5a48924d750fbef7ea6b05a1ba49c28589 (patch) | |
tree | 24c2eebc8ef3536e89b355b099d844083646d190 /mesalib/src/mesa/main/shaderapi.c | |
parent | 67c290de36ddc1caae94c0892157ac16b90e4f99 (diff) | |
download | vcxsrv-1cc98f5a48924d750fbef7ea6b05a1ba49c28589.tar.gz vcxsrv-1cc98f5a48924d750fbef7ea6b05a1ba49c28589.tar.bz2 vcxsrv-1cc98f5a48924d750fbef7ea6b05a1ba49c28589.zip |
xserver mesa xkbcomp git update 5 nov 2012
xserver: a194630f7f7b287cb4ea4a459df0745f4c0d4c1a
mesa: ccbfe3dde94cd50a4e6468cfeabf95c79c9d8072
xkbcomp: a68c5b7b29eb1433b1be73b50c4248e10eab8e64
Diffstat (limited to 'mesalib/src/mesa/main/shaderapi.c')
-rw-r--r-- | mesalib/src/mesa/main/shaderapi.c | 76 |
1 files changed, 39 insertions, 37 deletions
diff --git a/mesalib/src/mesa/main/shaderapi.c b/mesalib/src/mesa/main/shaderapi.c index d40a35376..9376b0f42 100644 --- a/mesalib/src/mesa/main/shaderapi.c +++ b/mesalib/src/mesa/main/shaderapi.c @@ -1692,7 +1692,7 @@ _mesa_init_shader_dispatch(const struct gl_context *ctx, { #if FEATURE_GL /* GL_ARB_vertex/fragment_shader */ - if (ctx->API != API_OPENGLES2) { + if (_mesa_is_desktop_gl(ctx)) { SET_DeleteObjectARB(exec, _mesa_DeleteObjectARB); SET_GetHandleARB(exec, _mesa_GetHandleARB); SET_DetachObjectARB(exec, _mesa_DetachObjectARB); @@ -1705,56 +1705,58 @@ _mesa_init_shader_dispatch(const struct gl_context *ctx, SET_GetAttachedObjectsARB(exec, _mesa_GetAttachedObjectsARB); } - SET_ShaderSourceARB(exec, _mesa_ShaderSourceARB); - SET_CompileShaderARB(exec, _mesa_CompileShaderARB); - SET_LinkProgramARB(exec, _mesa_LinkProgramARB); - SET_UseProgramObjectARB(exec, _mesa_UseProgramObjectARB); - SET_ValidateProgramARB(exec, _mesa_ValidateProgramARB); - SET_GetShaderSourceARB(exec, _mesa_GetShaderSourceARB); - - /* OpenGL 2.0 */ - SET_AttachShader(exec, _mesa_AttachShader); - SET_CreateProgram(exec, _mesa_CreateProgram); - SET_CreateShader(exec, _mesa_CreateShader); - SET_DeleteProgram(exec, _mesa_DeleteProgram); - SET_DeleteShader(exec, _mesa_DeleteShader); - SET_DetachShader(exec, _mesa_DetachShader); - SET_GetAttachedShaders(exec, _mesa_GetAttachedShaders); - SET_GetProgramiv(exec, _mesa_GetProgramiv); - SET_GetProgramInfoLog(exec, _mesa_GetProgramInfoLog); - SET_GetShaderiv(exec, _mesa_GetShaderiv); - SET_GetShaderInfoLog(exec, _mesa_GetShaderInfoLog); - SET_IsProgram(exec, _mesa_IsProgram); - SET_IsShader(exec, _mesa_IsShader); - - /* GL_ARB_vertex_shader */ - SET_BindAttribLocationARB(exec, _mesa_BindAttribLocationARB); - SET_GetActiveAttribARB(exec, _mesa_GetActiveAttribARB); - SET_GetAttribLocationARB(exec, _mesa_GetAttribLocationARB); - - if (ctx->API != API_OPENGLES2) { - SET_ProgramParameteriARB(exec, _mesa_ProgramParameteriARB); - + if (ctx->API != API_OPENGLES) { + SET_ShaderSourceARB(exec, _mesa_ShaderSourceARB); + SET_CompileShaderARB(exec, _mesa_CompileShaderARB); + SET_LinkProgramARB(exec, _mesa_LinkProgramARB); + SET_UseProgramObjectARB(exec, _mesa_UseProgramObjectARB); + SET_ValidateProgramARB(exec, _mesa_ValidateProgramARB); + SET_GetShaderSourceARB(exec, _mesa_GetShaderSourceARB); + + /* OpenGL 2.0 */ + SET_AttachShader(exec, _mesa_AttachShader); + SET_CreateProgram(exec, _mesa_CreateProgram); + SET_CreateShader(exec, _mesa_CreateShader); + SET_DeleteProgram(exec, _mesa_DeleteProgram); + SET_DeleteShader(exec, _mesa_DeleteShader); + SET_DetachShader(exec, _mesa_DetachShader); + SET_GetAttachedShaders(exec, _mesa_GetAttachedShaders); + SET_GetProgramiv(exec, _mesa_GetProgramiv); + SET_GetProgramInfoLog(exec, _mesa_GetProgramInfoLog); + SET_GetShaderiv(exec, _mesa_GetShaderiv); + SET_GetShaderInfoLog(exec, _mesa_GetShaderInfoLog); + SET_IsProgram(exec, _mesa_IsProgram); + SET_IsShader(exec, _mesa_IsShader); + + /* GL_ARB_vertex_shader */ + SET_BindAttribLocationARB(exec, _mesa_BindAttribLocationARB); + SET_GetActiveAttribARB(exec, _mesa_GetActiveAttribARB); + SET_GetAttribLocationARB(exec, _mesa_GetAttribLocationARB); + } + + if (ctx->API == API_OPENGL) { SET_UseShaderProgramEXT(exec, _mesa_UseShaderProgramEXT); SET_ActiveProgramEXT(exec, _mesa_ActiveProgramEXT); SET_CreateShaderProgramEXT(exec, _mesa_CreateShaderProgramEXT); } /* GL_EXT_gpu_shader4 / GL 3.0 */ - if (ctx->API != API_OPENGLES2) { + if (_mesa_is_desktop_gl(ctx)) { SET_BindFragDataLocationEXT(exec, _mesa_BindFragDataLocation); } - if (ctx->API != API_OPENGLES2 || _mesa_is_gles3(ctx)) { + if (_mesa_is_desktop_gl(ctx) || _mesa_is_gles3(ctx)) { SET_GetFragDataLocationEXT(exec, _mesa_GetFragDataLocation); } /* GL_ARB_ES2_compatibility */ - SET_ReleaseShaderCompiler(exec, _mesa_ReleaseShaderCompiler); - SET_GetShaderPrecisionFormat(exec, _mesa_GetShaderPrecisionFormat); - SET_ShaderBinary(exec, _mesa_ShaderBinary); + if (ctx->API != API_OPENGLES) { + SET_ReleaseShaderCompiler(exec, _mesa_ReleaseShaderCompiler); + SET_GetShaderPrecisionFormat(exec, _mesa_GetShaderPrecisionFormat); + SET_ShaderBinary(exec, _mesa_ShaderBinary); + } /* GL_ARB_blend_func_extended */ - if (ctx->API != API_OPENGLES2) { + if (_mesa_is_desktop_gl(ctx)) { SET_BindFragDataLocationIndexed(exec, _mesa_BindFragDataLocationIndexed); SET_GetFragDataIndex(exec, _mesa_GetFragDataIndex); } |