diff options
author | Kenneth Graunke <[email protected]> | 2016-05-08 22:48:02 -0700 |
---|---|---|
committer | Kenneth Graunke <[email protected]> | 2016-05-20 19:55:40 -0700 |
commit | 915f7c25fac2683f924fded2b47208c7fb850044 (patch) | |
tree | 60d2a3bd13e6bdcee10087089970e5b2da437fb5 /src/mesa | |
parent | 47fbe178fa631ae855fa862d638f5313a2b13bc3 (diff) |
i965: Don't write a counter snapshot on EndTransformFeedback if paused.
If the transform feedback object is paused, then we've already written
an ending counter snapshot. We don't want to write another one.
This fixes assertions in GL33-CTS.transform_feedback.api_errors_test,
which calls EndTransformfeedback after PauseTransformFeedback. On the
next BeginTransformFeedback, we tried to tally up the results, and saw
an odd number of snapshots (due to the double-end), and tripped an
assertion.
Signed-off-by: Kenneth Graunke <[email protected]>
Reviewed-by: Jordan Justen <[email protected]>
Diffstat (limited to 'src/mesa')
-rw-r--r-- | src/mesa/drivers/dri/i965/gen7_sol_state.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/i965/gen7_sol_state.c b/src/mesa/drivers/dri/i965/gen7_sol_state.c index d8dbc5f6b2f..f7b14438a22 100644 --- a/src/mesa/drivers/dri/i965/gen7_sol_state.c +++ b/src/mesa/drivers/dri/i965/gen7_sol_state.c @@ -485,7 +485,8 @@ gen7_end_transform_feedback(struct gl_context *ctx, (struct brw_transform_feedback_object *) obj; /* Store the ending value of the SO_NUM_PRIMS_WRITTEN counters. */ - gen7_save_primitives_written_counters(brw, brw_obj); + if (!obj->Paused) + gen7_save_primitives_written_counters(brw, brw_obj); /* EndTransformFeedback() means that we need to update the number of * vertices written. Since it's only necessary if DrawTransformFeedback() |