summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/r300
diff options
context:
space:
mode:
authorMarek Olšák <[email protected]>2011-04-21 12:53:16 +0200
committerMarek Olšák <[email protected]>2011-04-21 15:51:18 +0200
commit883d8a0b449b53d83cc5970d2ce50df536aef55f (patch)
tree10b09a02971b2b1194e5406e67c1c7927f2ae143 /src/gallium/drivers/r300
parent64f55216e4c11e8acb787bfe40e6dd25e862cd43 (diff)
gallium: add fallback for copying buffers to all drivers
Just to keep drivers working. Reviewed-by: Jakob Bornecrantz <[email protected]>
Diffstat (limited to 'src/gallium/drivers/r300')
-rw-r--r--src/gallium/drivers/r300/r300_blit.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/gallium/drivers/r300/r300_blit.c b/src/gallium/drivers/r300/r300_blit.c
index 62d90afdcb0..1217488bac7 100644
--- a/src/gallium/drivers/r300/r300_blit.c
+++ b/src/gallium/drivers/r300/r300_blit.c
@@ -26,6 +26,7 @@
#include "util/u_format.h"
#include "util/u_pack_color.h"
+#include "util/u_surface.h"
enum r300_blitter_op /* bitmask */
{
@@ -415,6 +416,13 @@ static void r300_resource_copy_region(struct pipe_context *pipe,
util_format_description(dst->format);
struct pipe_box box;
+ /* Fallback for buffers. */
+ if (dst->target == PIPE_BUFFER && src->target == PIPE_BUFFER) {
+ util_resource_copy_region(pipe, dst, dst_level, dstx, dsty, dstz,
+ src, src_level, src_box);
+ return;
+ }
+
if (r300->zmask_in_use && !r300->hyperz_locked) {
if (fb->zsbuf->texture == src ||
fb->zsbuf->texture == dst) {