Mesa (master): mesa: Don' t install glVertexAttribL* functions in compatibility profile

Ian Romanick idr at kemper.freedesktop.org
Fri May 29 00:03:42 UTC 2015


Module: Mesa
Branch: master
Commit: a6fa74e6bb65f852ad1608f43dd0731e854ea42f
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=a6fa74e6bb65f852ad1608f43dd0731e854ea42f

Author: Ian Romanick <ian.d.romanick at intel.com>
Date:   Wed May 20 20:13:12 2015 -0700

mesa: Don't install glVertexAttribL* functions in compatibility profile

GL_ARB_vertex_attrib_64bit is exclusive to core profile, and none of the
other functions added by the extension are advertised in other profiles.

Signed-off-by: Ian Romanick <ian.d.romanick at intel.com>
Cc: Dave Airlie <airlied at redhat.com>
Cc: Ilia Mirkin <imirkin at alum.mit.edu>
Cc: "10.6" <mesa-stable at lists.freedesktop.org>

---

 src/mesa/main/api_loopback.c |    2 ++
 src/mesa/main/vtxfmt.c       |    2 +-
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/src/mesa/main/api_loopback.c b/src/mesa/main/api_loopback.c
index 9932a83..a7fd82c 100644
--- a/src/mesa/main/api_loopback.c
+++ b/src/mesa/main/api_loopback.c
@@ -1772,7 +1772,9 @@ _mesa_loopback_init_api_table(const struct gl_context *ctx,
       SET_VertexAttribI4sv(dest, _mesa_VertexAttribI4sv);
       SET_VertexAttribI4ubv(dest, _mesa_VertexAttribI4ubv);
       SET_VertexAttribI4usv(dest, _mesa_VertexAttribI4usv);
+   }
 
+   if (ctx->API == API_OPENGL_CORE) {
       /* GL 4.1 / GL_ARB_vertex_attrib_64bit */
       SET_VertexAttribL1d(dest, _mesa_VertexAttribL1d);
       SET_VertexAttribL2d(dest, _mesa_VertexAttribL2d);
diff --git a/src/mesa/main/vtxfmt.c b/src/mesa/main/vtxfmt.c
index d7ef7e2..81bf4c5 100644
--- a/src/mesa/main/vtxfmt.c
+++ b/src/mesa/main/vtxfmt.c
@@ -207,7 +207,7 @@ install_vtxfmt(struct gl_context *ctx, struct _glapi_table *tab,
       SET_VertexAttribP4uiv(tab, vfmt->VertexAttribP4uiv);
    }
 
-   if (_mesa_is_desktop_gl(ctx)) {
+   if (ctx->API == API_OPENGL_CORE) {
       SET_VertexAttribL1d(tab, vfmt->VertexAttribL1d);
       SET_VertexAttribL2d(tab, vfmt->VertexAttribL2d);
       SET_VertexAttribL3d(tab, vfmt->VertexAttribL3d);




More information about the mesa-commit mailing list