diff options
author | Brian Paul <[email protected]> | 2015-02-27 13:05:16 -0700 |
---|---|---|
committer | Brian Paul <[email protected]> | 2015-02-27 15:22:24 -0700 |
commit | 48f229d759480cf6e42af1236b5889fe389e4dd8 (patch) | |
tree | cd90dd094f9ea90e1b34b76b4db275140c73d6cd /src/mesa/main/queryobj.c | |
parent | 5b089e5f15ca06be82ca36e21d678db17493b6b6 (diff) |
mesa: move declaration before code
To fix MinGW warning.
Reviewed-by: Anuj Phogat <[email protected]>
Diffstat (limited to 'src/mesa/main/queryobj.c')
-rw-r--r-- | src/mesa/main/queryobj.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/mesa/main/queryobj.c b/src/mesa/main/queryobj.c index e02969d2ed7..0842b540de4 100644 --- a/src/mesa/main/queryobj.c +++ b/src/mesa/main/queryobj.c @@ -146,12 +146,13 @@ static struct gl_query_object ** get_pipe_stats_binding_point(struct gl_context *ctx, GLenum target) { + const int which = target - GL_VERTICES_SUBMITTED_ARB; + assert(which < MAX_PIPELINE_STATISTICS); + if (!_mesa_is_desktop_gl(ctx) || !ctx->Extensions.ARB_pipeline_statistics_query) return NULL; - const int which = target - GL_VERTICES_SUBMITTED_ARB; - assert(which < MAX_PIPELINE_STATISTICS); return &ctx->Query.pipeline_stats[which]; } |