From 22aa573de2860ddfe9092167525e2917e3a03cb8 Mon Sep 17 00:00:00 2001 From: Carl Worth Date: Tue, 11 Jun 2013 17:18:12 -0700 Subject: [PATCH] Switch from glGetQueryObjectiv to glGetQueryObjectuiv The latter is available in OpenGL ES 3 while the former is not. We don't really care about the signedness either way, (we're fetching a Boolean), so sticking consistently to the unsigned version provides better portability with no downside. --- metrics.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/metrics.c b/metrics.c index 8d2d644..b6dbbd0 100644 --- a/metrics.c +++ b/metrics.c @@ -147,11 +147,10 @@ metrics_end_frame (void) counter_t *counter = current_context.counter_head; while (counter) { - GLint available; - GLuint elapsed; + GLuint available, elapsed; - glGetQueryObjectiv (counter->id, GL_QUERY_RESULT_AVAILABLE, - &available); + glGetQueryObjectuiv (counter->id, GL_QUERY_RESULT_AVAILABLE, + &available); if (! available) break; -- 2.43.0