From d18792f93d6dcdf7ef971522bdfba1ceeb0c6668 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Marek=20Ol=C5=A1=C3=A1k?= Date: Sun, 29 May 2011 03:59:07 +0200 Subject: [PATCH] r300g: cleanup render_condition a bit --- src/gallium/drivers/r300/r300_query.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/gallium/drivers/r300/r300_query.c b/src/gallium/drivers/r300/r300_query.c index 55a2e2fde7f..782f041e926 100644 --- a/src/gallium/drivers/r300/r300_query.c +++ b/src/gallium/drivers/r300/r300_query.c @@ -156,17 +156,15 @@ static void r300_render_condition(struct pipe_context *pipe, uint64_t result = 0; boolean wait; + r300->skip_rendering = FALSE; + if (query) { wait = mode == PIPE_RENDER_COND_WAIT || mode == PIPE_RENDER_COND_BY_REGION_WAIT; - if (!r300_get_query_result(pipe, query, wait, &result)) { - r300->skip_rendering = FALSE; - } else { + if (r300_get_query_result(pipe, query, wait, &result)) { r300->skip_rendering = result == 0; } - } else { - r300->skip_rendering = FALSE; } } -- 2.30.2