From: Marek Olšák Date: Fri, 18 Nov 2022 12:20:20 +0000 (-0500) Subject: mesa: set fewer dirty flags for PointSizeEnabled state changes X-Git-Tag: upstream/23.3.3~15893 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=5acc0fa1d2250f4c955f0c24898b36b15773c2b3;p=platform%2Fupstream%2Fmesa.git mesa: set fewer dirty flags for PointSizeEnabled state changes Reviewed-by: Pierre-Eric Pelloux-Prayer Part-of: --- diff --git a/src/mesa/main/enable.c b/src/mesa/main/enable.c index 5aab142..ed8016b 100644 --- a/src/mesa/main/enable.c +++ b/src/mesa/main/enable.c @@ -128,7 +128,9 @@ client_state(struct gl_context *ctx, struct gl_vertex_array_object* vao, case GL_POINT_SIZE_ARRAY_OES: if (ctx->VertexProgram.PointSizeEnabled != state) { - FLUSH_VERTICES(ctx, _NEW_PROGRAM, 0); + FLUSH_VERTICES(ctx, ctx->st->lower_point_size ? _NEW_PROGRAM : 0, + 0); + ctx->NewDriverState |= ST_NEW_RASTERIZER; ctx->VertexProgram.PointSizeEnabled = state; } vao_state(ctx, vao, VERT_ATTRIB_POINT_SIZE, state); @@ -1091,7 +1093,9 @@ _mesa_set_enable(struct gl_context *ctx, GLenum cap, GLboolean state) goto invalid_enum_error; if (ctx->VertexProgram.PointSizeEnabled == state) return; - FLUSH_VERTICES(ctx, _NEW_PROGRAM, GL_ENABLE_BIT); + FLUSH_VERTICES(ctx, ctx->st->lower_point_size ? _NEW_PROGRAM : 0, + GL_ENABLE_BIT); + ctx->NewDriverState |= ST_NEW_RASTERIZER; ctx->VertexProgram.PointSizeEnabled = state; break; case GL_VERTEX_PROGRAM_TWO_SIDE_ARB: