[Mesa-dev] [PATCH 15/19] mesa: Don't set shaderapi dispatch pointers for many things in ES2 or core
Eric Anholt
eric at anholt.net
Fri Sep 7 14:02:37 PDT 2012
Ian Romanick <idr at freedesktop.org> writes:
> From: Ian Romanick <ian.d.romanick at intel.com>
>
> NOTE: This is a candidate for the 9.0 branch
GL_ARB_shader_objects and friends are marked as GL not GLL in
extensions.c -- should their functions still be exposed if we're
exposing the extensions?
> /* GL_EXT_gpu_shader4 / GL 3.0 */
> - SET_BindFragDataLocationEXT(exec, _mesa_BindFragDataLocation);
> - SET_GetFragDataLocationEXT(exec, _mesa_GetFragDataLocation);
> + if (ctx->API != API_OPENGLES2 || _mesa_is_gles3(ctx)) {
> + SET_BindFragDataLocationEXT(exec, _mesa_BindFragDataLocation);
> + }
> + if (ctx->API != API_OPENGLES2 || _mesa_is_gles3(ctx)) {
> + SET_GetFragDataLocationEXT(exec, _mesa_GetFragDataLocation);
> + }
Fold these two ifs together? Also, should the EXTs actually be exposed
on gles3? (seems like just the core versions below should)
> @@ -1778,8 +1788,10 @@ _mesa_init_shader_dispatch(struct _glapi_table *exec)
> SET_ShaderBinary(exec, _mesa_ShaderBinary);
>
> /* GL_ARB_blend_func_extended */
> - SET_BindFragDataLocationIndexed(exec, _mesa_BindFragDataLocationIndexed);
> - SET_GetFragDataIndex(exec, _mesa_GetFragDataIndex);
> + if (ctx->API != API_OPENGLES2) {
> + SET_BindFragDataLocationIndexed(exec, _mesa_BindFragDataLocationIndexed);
> + SET_GetFragDataIndex(exec, _mesa_GetFragDataIndex);
> + }
> #endif /* FEATURE_GL */
> }
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20120907/cf7dc023/attachment.pgp>
More information about the mesa-dev
mailing list