mesa/st: use sanitized shader keys for feedback draws

the draw module shouldn't use any other shader keys, so ensure they
are never set

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28189>
This commit is contained in:
Mike Blumenkrantz 2024-03-13 15:38:40 -04:00 committed by Marge Bot
parent 5eb0136a3c
commit c0158b40ca

View file

@ -116,11 +116,11 @@ st_feedback_draw_vbo(struct gl_context *ctx,
return;
/* must get these after state validation! */
struct st_common_variant_key key;
/* We have to use memcpy to make sure that all bits are copied. */
memcpy(&key, &st->vp_variant->key, sizeof(key));
key.is_draw_shader = true;
struct st_common_variant_key key = {
.st = st,
.passthrough_edgeflags = st->ctx->Array._PerVertexEdgeFlagsEnabled,
.is_draw_shader = true
};
vp = (struct gl_vertex_program *)ctx->VertexProgram._Current;
vp_variant = st_get_common_variant(st, &vp->Base, &key);