diff options
Diffstat (limited to 'src/mesa/pipe/p_context.h')
-rw-r--r-- | src/mesa/pipe/p_context.h | 20 |
1 files changed, 17 insertions, 3 deletions
diff --git a/src/mesa/pipe/p_context.h b/src/mesa/pipe/p_context.h index 83b4ab07fb..92ca7dd8e3 100644 --- a/src/mesa/pipe/p_context.h +++ b/src/mesa/pipe/p_context.h @@ -29,9 +29,13 @@ #define PIPE_CONTEXT_H #include "p_state.h" +#include <stdint.h> struct pipe_state_cache; +/* Opaque driver handles: + */ +struct pipe_query; /** * Gallium rendering context. Basically: @@ -81,9 +85,19 @@ struct pipe_context { /** * Query objects */ - void (*begin_query)(struct pipe_context *pipe, struct pipe_query_object *q); - void (*end_query)(struct pipe_context *pipe, struct pipe_query_object *q); - void (*wait_query)(struct pipe_context *pipe, struct pipe_query_object *q); + struct pipe_query *(*create_query)( struct pipe_context *pipe, + unsigned query_type ); + + void (*destroy_query)(struct pipe_context *pipe, + struct pipe_query *q); + + void (*begin_query)(struct pipe_context *pipe, struct pipe_query *q); + void (*end_query)(struct pipe_context *pipe, struct pipe_query *q); + + boolean (*get_query_result)(struct pipe_context *pipe, + struct pipe_query *q, + boolean wait, + uint64_t *result); /* * State functions |