summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoland Scheidegger <sroland@vmware.com>2010-05-21 20:52:01 +0200
committerRoland Scheidegger <sroland@vmware.com>2010-05-21 20:52:01 +0200
commite4f4489e3fc0b36d72821b55794fb843b2b7fa5f (patch)
treead98038ccf9436e39d07a54c1aa142c154104fb5
parent3293bcdc80cdfa20a2381aae2b94505bdf95d857 (diff)
rbug: fix breakage due to interface changes
-rw-r--r--src/gallium/drivers/rbug/rbug_context.c96
-rw-r--r--src/gallium/drivers/rbug/rbug_screen.c2
2 files changed, 56 insertions, 42 deletions
diff --git a/src/gallium/drivers/rbug/rbug_context.c b/src/gallium/drivers/rbug/rbug_context.c
index 59f005ec16..7e032c64e7 100644
--- a/src/gallium/drivers/rbug/rbug_context.c
+++ b/src/gallium/drivers/rbug/rbug_context.c
@@ -752,55 +752,67 @@ rbug_set_vertex_buffers(struct pipe_context *_pipe,
buffers);
}
static void
-rbug_surface_copy(struct pipe_context *_pipe,
- struct pipe_surface *_dst,
- unsigned dstx,
- unsigned dsty,
- struct pipe_surface *_src,
- unsigned srcx,
- unsigned srcy,
- unsigned width,
- unsigned height)
+rbug_resource_copy_region(struct pipe_context *_pipe,
+ struct pipe_resource *_dst,
+ struct pipe_subresource subdst,
+ unsigned dstx,
+ unsigned dsty,
+ unsigned dstz,
+ struct pipe_resource *_src,
+ struct pipe_subresource subsrc,
+ unsigned srcx,
+ unsigned srcy,
+ unsigned srcz,
+ unsigned width,
+ unsigned height)
{
struct rbug_context *rb_pipe = rbug_context(_pipe);
- struct rbug_surface *rb_surface_dst = rbug_surface(_dst);
- struct rbug_surface *rb_surface_src = rbug_surface(_src);
+ struct rbug_resource *rb_resource_dst = rbug_resource(_dst);
+ struct rbug_resource *rb_resource_src = rbug_resource(_src);
struct pipe_context *pipe = rb_pipe->pipe;
- struct pipe_surface *dst = rb_surface_dst->surface;
- struct pipe_surface *src = rb_surface_src->surface;
-
- pipe->surface_copy(pipe,
- dst,
- dstx,
- dsty,
- src,
- srcx,
- srcy,
- width,
- height);
+ struct pipe_resource *dst = rb_resource_dst->resource;
+ struct pipe_resource *src = rb_resource_src->resource;
+
+ pipe->resource_copy_region(pipe,
+ dst,
+ subdst,
+ dstx,
+ dsty,
+ dstz,
+ src,
+ subsrc,
+ srcx,
+ srcy,
+ srcz,
+ width,
+ height);
}
static void
-rbug_surface_fill(struct pipe_context *_pipe,
- struct pipe_surface *_dst,
- unsigned dstx,
- unsigned dsty,
- unsigned width,
- unsigned height,
- unsigned value)
+rbug_resource_fill_region(struct pipe_context *_pipe,
+ struct pipe_resource *_dst,
+ struct pipe_subresource subdst,
+ unsigned dstx,
+ unsigned dsty,
+ unsigned dstz,
+ unsigned width,
+ unsigned height,
+ unsigned value)
{
struct rbug_context *rb_pipe = rbug_context(_pipe);
- struct rbug_surface *rb_surface_dst = rbug_surface(_dst);
+ struct rbug_resource *rb_resource_dst = rbug_resource(_dst);
struct pipe_context *pipe = rb_pipe->pipe;
- struct pipe_surface *dst = rb_surface_dst->surface;
-
- pipe->surface_fill(pipe,
- dst,
- dstx,
- dsty,
- width,
- height,
- value);
+ struct pipe_resource *dst = rb_resource_dst->resource;
+
+ pipe->resource_fill_region(pipe,
+ dst,
+ subdst,
+ dstx,
+ dsty,
+ dstz,
+ width,
+ height,
+ value);
}
static void
@@ -1050,8 +1062,8 @@ rbug_context_create(struct pipe_screen *_screen, struct pipe_context *pipe)
rb_pipe->base.set_fragment_sampler_views = rbug_set_fragment_sampler_views;
rb_pipe->base.set_vertex_sampler_views = rbug_set_vertex_sampler_views;
rb_pipe->base.set_vertex_buffers = rbug_set_vertex_buffers;
- rb_pipe->base.surface_copy = rbug_surface_copy;
- rb_pipe->base.surface_fill = rbug_surface_fill;
+ rb_pipe->base.resource_copy_region = rbug_resource_copy_region;
+ rb_pipe->base.resource_fill_region = rbug_resource_fill_region;
rb_pipe->base.clear = rbug_clear;
rb_pipe->base.flush = rbug_flush;
rb_pipe->base.is_resource_referenced = rbug_is_resource_referenced;
diff --git a/src/gallium/drivers/rbug/rbug_screen.c b/src/gallium/drivers/rbug/rbug_screen.c
index 2b60af2302..b9f32ee6a9 100644
--- a/src/gallium/drivers/rbug/rbug_screen.c
+++ b/src/gallium/drivers/rbug/rbug_screen.c
@@ -94,6 +94,7 @@ static boolean
rbug_screen_is_format_supported(struct pipe_screen *_screen,
enum pipe_format format,
enum pipe_texture_target target,
+ unsigned sample_count,
unsigned tex_usage,
unsigned geom_flags)
{
@@ -103,6 +104,7 @@ rbug_screen_is_format_supported(struct pipe_screen *_screen,
return screen->is_format_supported(screen,
format,
target,
+ sample_count,
tex_usage,
geom_flags);
}