aboutsummaryrefslogtreecommitdiffstats
path: root/src/gallium/auxiliary
diff options
context:
space:
mode:
authorKenneth Graunke <[email protected]>2019-08-13 14:32:57 -0700
committerKenneth Graunke <[email protected]>2019-08-21 22:18:22 +0000
commitf02d1a0b75c72f600ecdd73020673e4bec015153 (patch)
treef46fc7d154d441e09732a476b838deb20fdf15ff /src/gallium/auxiliary
parentc43a44791bfce12da6fb86e05a29fc819c1c1878 (diff)
gallium/rbug: Wrap resource_get_param if available
Fixes: 0346b700833 ("gallium/screen: Add pipe_screen::resource_get_param") Reviewed-by: Jordan Justen <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
Diffstat (limited to 'src/gallium/auxiliary')
-rw-r--r--src/gallium/auxiliary/driver_rbug/rbug_screen.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/gallium/auxiliary/driver_rbug/rbug_screen.c b/src/gallium/auxiliary/driver_rbug/rbug_screen.c
index 2b00e34dbc5..247745fa533 100644
--- a/src/gallium/auxiliary/driver_rbug/rbug_screen.c
+++ b/src/gallium/auxiliary/driver_rbug/rbug_screen.c
@@ -215,6 +215,22 @@ rbug_screen_resource_get_handle(struct pipe_screen *_screen,
resource, handle, usage);
}
+static bool
+rbug_screen_resource_get_param(struct pipe_screen *_screen,
+ struct pipe_resource *_resource,
+ unsigned int plane,
+ enum pipe_resource_param param,
+ uint64_t *value)
+{
+ struct rbug_screen *rb_screen = rbug_screen(_screen);
+ struct rbug_resource *rb_resource = rbug_resource(_resource);
+ struct pipe_screen *screen = rb_screen->screen;
+ struct pipe_resource *resource = rb_resource->resource;
+
+ return screen->resource_get_param(screen, resource, plane, param, value);
+}
+
+
static void
rbug_screen_resource_get_info(struct pipe_screen *_screen,
struct pipe_resource *_resource,
@@ -333,6 +349,7 @@ rbug_screen_create(struct pipe_screen *screen)
rb_screen->base.resource_from_handle = rbug_screen_resource_from_handle;
SCR_INIT(check_resource_capability);
rb_screen->base.resource_get_handle = rbug_screen_resource_get_handle;
+ SCR_INIT(resource_get_param);
SCR_INIT(resource_get_info);
SCR_INIT(resource_changed);
rb_screen->base.resource_destroy = rbug_screen_resource_destroy;