mesa: Ignore glPointSize when GL_POINT_SIZE_ARRAY_OES is enabled
authorPlamena Manolova <plamena.manolova@intel.com>
Tue, 15 Mar 2016 18:39:49 +0000 (20:39 +0200)
committerKenneth Graunke <kenneth@whitecape.org>
Tue, 15 Mar 2016 22:49:48 +0000 (15:49 -0700)
When a user defines a point size array and enables it, the point
size value set via glPointSize should be ignored. To achieve this,
we can simply toggle ctx->VertexProgram.PointSizeEnabled.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=42187
Signed-off-by: Plamena Manolova <plamena.manolova@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/mesa/main/enable.c

index 3985457f21a250dff6075883fd29dc7d1052490f..b90a60ba03fdf17ee22290ff063ae1358dd952f8 100644 (file)
@@ -105,6 +105,8 @@ client_state(struct gl_context *ctx, GLenum cap, GLboolean state)
       case GL_POINT_SIZE_ARRAY_OES:
          var = &vao->VertexAttrib[VERT_ATTRIB_POINT_SIZE].Enabled;
          flag = VERT_BIT_POINT_SIZE;
+         FLUSH_VERTICES(ctx, _NEW_PROGRAM);
+         ctx->VertexProgram.PointSizeEnabled = state;
          break;
 
       /* GL_NV_primitive_restart */