diff options
author | Marek Olšák <[email protected]> | 2012-08-12 20:06:33 +0200 |
---|---|---|
committer | Marek Olšák <[email protected]> | 2012-08-27 04:31:00 +0200 |
commit | a3d9d7ec79d6f7205fab2324e47d8ea185431de0 (patch) | |
tree | 3aa8b27b500d9e7535053e01c5345f025ab4f86a /src/gallium/drivers/r600/r600_pipe.c | |
parent | 48edfe0505ee79d35f770f53b9c9b7ca3c69fd2b (diff) |
r600g: implement compression for MSAA colorbuffers for evergreen
This adds the FMASK and CMASK buffers. They share the same resource
with color data.
COMPRESSION and FAST_CLEAR are always enabled if both FMASK and CMASK are
allocated. We initialize the CMASK to a "compressed" state (not "fast cleared"),
so that we can keep FAST_CLEAR enabled all the time.
Both FMASK and CMASK must be present at the moment. If either one is missing,
the other one is not used.
v2: add cayman regs in the list
Reviewed-by: Jerome Glisse <[email protected]>
Diffstat (limited to 'src/gallium/drivers/r600/r600_pipe.c')
-rw-r--r-- | src/gallium/drivers/r600/r600_pipe.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/gallium/drivers/r600/r600_pipe.c b/src/gallium/drivers/r600/r600_pipe.c index 7936c475bb6..0d489100dfb 100644 --- a/src/gallium/drivers/r600/r600_pipe.c +++ b/src/gallium/drivers/r600/r600_pipe.c @@ -168,6 +168,9 @@ static void r600_destroy_context(struct pipe_context *context) if (rctx->custom_blend_resolve) { rctx->context.delete_blend_state(&rctx->context, rctx->custom_blend_resolve); } + if (rctx->custom_blend_decompress) { + rctx->context.delete_blend_state(&rctx->context, rctx->custom_blend_decompress); + } util_unreference_framebuffer_state(&rctx->framebuffer); r600_context_fini(rctx); @@ -262,6 +265,7 @@ static struct pipe_context *r600_create_context(struct pipe_screen *screen, void goto fail; rctx->custom_dsa_flush = evergreen_create_db_flush_dsa(rctx); rctx->custom_blend_resolve = evergreen_create_resolve_blend(rctx); + rctx->custom_blend_decompress = evergreen_create_decompress_blend(rctx); rctx->has_vertex_cache = !(rctx->family == CHIP_CEDAR || rctx->family == CHIP_PALM || rctx->family == CHIP_SUMO || |