diff options
author | James Benton <[email protected]> | 2012-12-03 07:00:37 +0000 |
---|---|---|
committer | José Fonseca <[email protected]> | 2012-12-03 17:21:57 +0000 |
commit | 16f0d70ffe6d42d22b9e6b927b297e75a199aa78 (patch) | |
tree | 743ca3f973a5389fd8ecb49c3181b2ae2b26dfd3 /src/gallium/drivers/llvmpipe/lp_query.h | |
parent | 041966801ec87e3bf32913e43d6882eca9434695 (diff) |
llvmpipe: Implement PIPE_QUERY_TIMESTAMP and PIPE_QUERY_TIME_ELAPSED.
This required an update for the query storage in llvmpipe, there
can now be an active query per query type, so an occlusion query
can run at the same time as a time elapsed query.
Based on PIPE_QUERY_TIME_ELAPSED patch from Dave Airlie.
v2: fix up piglits for timers (also from Dave Airlie)
a) if we don't render anything the result is 0, so just
return the current time
b) add missing screen get_timestamp callback.
Signed-off-by: Dave Airlie <[email protected]>
Signed-off-by: José Fonseca <[email protected]>
Diffstat (limited to 'src/gallium/drivers/llvmpipe/lp_query.h')
-rw-r--r-- | src/gallium/drivers/llvmpipe/lp_query.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/gallium/drivers/llvmpipe/lp_query.h b/src/gallium/drivers/llvmpipe/lp_query.h index ef1bc307037..cacbd9d0b8c 100644 --- a/src/gallium/drivers/llvmpipe/lp_query.h +++ b/src/gallium/drivers/llvmpipe/lp_query.h @@ -42,8 +42,9 @@ struct llvmpipe_context; struct llvmpipe_query { - uint64_t count[LP_MAX_THREADS]; /**< a counter for each thread */ - struct lp_fence *fence; /* fence from last scene this was binned in */ + uint64_t count[LP_MAX_THREADS]; /* a counter for each thread */ + struct lp_fence *fence; /* fence from last scene this was binned in */ + unsigned type; /* PIPE_QUERY_* */ }; |