diff options
author | Samuel Pitoiset <samuel.pitoiset@gmail.com> | 2014-07-04 11:41:46 +0200 |
---|---|---|
committer | Martin Peres <martin.peres@linux.intel.com> | 2015-05-06 00:03:35 +0300 |
commit | b620829b5e4364e9d5ed30e8603de41087ff454f (patch) | |
tree | 8ca84bfcd78932202f369400a3aafd2484691b03 /src/gallium/auxiliary | |
parent | f137f5c691f5bd97a8b7f881f1f6837bff0ebc7a (diff) | |
download | external_mesa3d-b620829b5e4364e9d5ed30e8603de41087ff454f.zip external_mesa3d-b620829b5e4364e9d5ed30e8603de41087ff454f.tar.gz external_mesa3d-b620829b5e4364e9d5ed30e8603de41087ff454f.tar.bz2 |
gallium: add new fields to pipe_driver_query_info
According to the spec of GL_AMD_performance_monitor, valid type values
returned are UNSIGNED_INT, UNSIGNED_INT64_AMD, PERCENTAGE_AMD, FLOAT.
This also introduces the new field group_id in order to categorize
queries into groups.
v2: add PIPE_DRIVER_QUERY_TYPE_BYTES
v3: fix incorrect query type for radeon and svga drivers
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Martin Peres <martin.peres@free.fr>
Diffstat (limited to 'src/gallium/auxiliary')
-rw-r--r-- | src/gallium/auxiliary/hud/hud_driver_query.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/gallium/auxiliary/hud/hud_driver_query.c b/src/gallium/auxiliary/hud/hud_driver_query.c index 53771fc..1c8c485 100644 --- a/src/gallium/auxiliary/hud/hud_driver_query.c +++ b/src/gallium/auxiliary/hud/hud_driver_query.c @@ -187,6 +187,7 @@ hud_driver_query_install(struct hud_pane *pane, struct pipe_context *pipe, struct pipe_screen *screen = pipe->screen; struct pipe_driver_query_info query; unsigned num_queries, i; + boolean uses_byte_units; boolean found = FALSE; if (!screen->get_driver_query_info) @@ -205,7 +206,8 @@ hud_driver_query_install(struct hud_pane *pane, struct pipe_context *pipe, if (!found) return FALSE; + uses_byte_units = query.type == PIPE_DRIVER_QUERY_TYPE_BYTES; hud_pipe_query_install(pane, pipe, query.name, query.query_type, 0, - query.max_value, query.uses_byte_units); + query.max_value, uses_byte_units); return TRUE; } |