draw: flush when setting stream-out targets
authorErik Faye-Lund <erik.faye-lund@collabora.com>
Wed, 1 May 2019 13:37:45 +0000 (15:37 +0200)
committerErik Faye-Lund <erik.faye-lund@collabora.com>
Mon, 6 May 2019 20:42:37 +0000 (22:42 +0200)
We need to re-prepare the middle-end state to pick up changes to this
state to react correctly to pausing/resuming stream-out. So let's add a
flush here.

Signed-off-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Fixes: ec8cbd79ac4 "draw/softpipe: EXT_transform_feedback support (v2)"
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
src/gallium/auxiliary/draw/draw_context.c

index 3fc096789c0f7a0b5f7c3a18f053ae9e8f3558ef..f8c69585e6aabe8ff7b3c5dc9f0caf7d38175e4f 100644 (file)
@@ -950,6 +950,8 @@ draw_set_mapped_so_targets(struct draw_context *draw,
 {
    int i;
 
+   draw_do_flush( draw, DRAW_FLUSH_STATE_CHANGE );
+
    for (i = 0; i < num_targets; i++)
       draw->so.targets[i] = targets[i];
    for (i = num_targets; i < PIPE_MAX_SO_BUFFERS; i++)