Module: Mesa Branch: main Commit: 882abacde3694c3bf3b0cfd0d124e7dda49d1977 URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=882abacde3694c3bf3b0cfd0d124e7dda49d1977
Author: Mike Blumenkrantz <[email protected]> Date: Wed Mar 2 10:55:57 2022 -0500 mesa/st: simplify pointsize shader update conditional ES contexts have no API toggle for this, so it will never be flagged Reviewed-by: Ilia Mirkin <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15228> --- src/mesa/state_tracker/st_atom_shader.c | 18 ++++-------------- 1 file changed, 4 insertions(+), 14 deletions(-) diff --git a/src/mesa/state_tracker/st_atom_shader.c b/src/mesa/state_tracker/st_atom_shader.c index a2d6a4a0369..f972ffc604d 100644 --- a/src/mesa/state_tracker/st_atom_shader.c +++ b/src/mesa/state_tracker/st_atom_shader.c @@ -235,13 +235,8 @@ st_update_vp( struct st_context *st ) if (!st->ctx->GeometryProgram._Current && !st->ctx->TessEvalProgram._Current) { /* _NEW_POINT */ - if (st->lower_point_size) { - if (st->ctx->API != API_OPENGLES2) - key.export_point_size = !st->ctx->VertexProgram.PointSizeEnabled; - else - /* PointSizeEnabled is always set in ES2 contexts */ - key.export_point_size = true; - } + if (st->lower_point_size) + key.export_point_size = !st->ctx->VertexProgram.PointSizeEnabled; /* _NEW_TRANSFORM */ if (st->lower_ucp && st_user_clip_planes_enabled(st->ctx)) key.lower_ucp = st->ctx->Transform.ClipPlanesEnabled; @@ -297,13 +292,8 @@ st_update_common_program(struct st_context *st, struct gl_program *prog, !st->ctx->GeometryProgram._Current)) key.lower_ucp = st->ctx->Transform.ClipPlanesEnabled; - if (st->lower_point_size) { - if (st->ctx->API != API_OPENGLES2) - key.export_point_size = !st->ctx->VertexProgram.PointSizeEnabled; - else - /* PointSizeEnabled is always set in ES2 contexts */ - key.export_point_size = true; - } + if (st->lower_point_size) + key.export_point_size = !st->ctx->VertexProgram.PointSizeEnabled; } update_gl_clamp(st, prog, key.gl_clamp);
