summaryrefslogtreecommitdiff
path: root/src/gallium/drivers/r600/r600_blit.c
diff options
context:
space:
mode:
authorJerome Glisse <jglisse@redhat.com>2010-09-26 16:25:47 -0400
committerJerome Glisse <jglisse@redhat.com>2010-09-26 16:29:33 -0400
commit4ca1a92b7fe44158a13910d01c76f41f6946165c (patch)
tree2618b3d0f92e77d8c7f82a97e64be1b9a876e44e /src/gallium/drivers/r600/r600_blit.c
parent16baa465a249cc9a382fa2834ec6133561d0a562 (diff)
r600g: move around variables to share depth uncompression code
Signed-off-by: Jerome Glisse <jglisse@redhat.com>
Diffstat (limited to 'src/gallium/drivers/r600/r600_blit.c')
-rw-r--r--src/gallium/drivers/r600/r600_blit.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/src/gallium/drivers/r600/r600_blit.c b/src/gallium/drivers/r600/r600_blit.c
index c30a7c187c..52326534e6 100644
--- a/src/gallium/drivers/r600/r600_blit.c
+++ b/src/gallium/drivers/r600/r600_blit.c
@@ -180,10 +180,8 @@ void r600_init_blit_functions(struct r600_context *rctx)
int r600_blit_uncompress_depth(struct pipe_context *ctx, struct r600_resource_texture *texture)
{
struct r600_context *rctx = r600_context(ctx);
- struct r600_screen *rscreen = rctx->screen;
- struct pipe_framebuffer_state *fb = &rctx->framebuffer->state.framebuffer;
+ struct pipe_framebuffer_state *fb = rctx->pframebuffer;
struct pipe_surface *zsurf, *cbsurf;
- enum radeon_family family;
int level = 0;
float depth = 1.0f;
@@ -196,11 +194,10 @@ int r600_blit_uncompress_depth(struct pipe_context *ctx, struct r600_resource_te
r600_blitter_save_states(ctx);
util_blitter_save_framebuffer(rctx->blitter, fb);
- family = radeon_get_family(rscreen->rw);
- if (family == CHIP_RV610 || family == CHIP_RV630 || family == CHIP_RV620 ||
- family == CHIP_RV635)
+ if (rctx->family == CHIP_RV610 || rctx->family == CHIP_RV630 ||
+ rctx->family == CHIP_RV620 || rctx->family == CHIP_RV635)
depth = 0.0f;
-
+
util_blitter_custom_depth_stencil(rctx->blitter, zsurf, cbsurf, rctx->custom_dsa_flush, depth);
/* resume queries */