From 5fefb9e795dafe195399fac4d4a66c1fcda1b33e Mon Sep 17 00:00:00 2001 From: Mike Blumenkrantz Date: Wed, 10 Sep 2025 09:00:24 -0400 Subject: [PATCH] zink: flag vertex element state for rebind after vstate draws vstate draws bind their own elements unrelated to the bound gallium elements, so any draw occurring after a vstate draw must rebind to ensure the correct ones are bound Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/13570 cc: mesa-stable Part-of: --- src/gallium/drivers/zink/zink_draw.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/gallium/drivers/zink/zink_draw.cpp b/src/gallium/drivers/zink/zink_draw.cpp index 50583e758a3..436152042df 100644 --- a/src/gallium/drivers/zink/zink_draw.cpp +++ b/src/gallium/drivers/zink/zink_draw.cpp @@ -1021,6 +1021,8 @@ zink_draw_vertex_state(struct pipe_context *pctx, zink_draw(pctx, &dinfo, 0, NULL, draws, num_draws, vstate, partial_velem_mask); /* ensure ctx->vertex_buffers gets rebound on next non-vstate draw */ ctx->vertex_buffers_dirty = true; + /* ensure ctx->element_state gets rebound on next non-vstate draw */ + ctx->vertex_state_changed = true; if (info.take_vertex_state_ownership) pipe_vertex_state_reference(&vstate, NULL);