draw: cleanup the extra attribs
authorZack Rusin <zackr@vmware.com>
Wed, 7 Aug 2013 00:24:26 +0000 (20:24 -0400)
committerZack Rusin <zackr@vmware.com>
Fri, 9 Aug 2013 00:53:40 +0000 (20:53 -0400)
Before inserting new front face and prim id outputs cleanup
the old extra outputs, otherwise our cache will use previous
output slots which will break as soon as outputs of the current
shader don't match the last.

Signed-off-by: Zack Rusin <zackr@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
src/gallium/auxiliary/draw/draw_context.c

index af9caee0edc933f011f8424579162c37c984853d..2dc6772e7fb84a168448ada2ae49c3530186bacf 100644 (file)
@@ -555,6 +555,7 @@ draw_get_shader_info(const struct draw_context *draw)
 void
 draw_prepare_shader_outputs(struct draw_context *draw)
 {
+   draw_remove_extra_vertex_attribs(draw);
    draw_ia_prepare_outputs(draw, draw->pipeline.ia);
    draw_unfilled_prepare_outputs(draw, draw->pipeline.unfilled);
 }