summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/r600/r600_pipe.c
diff options
context:
space:
mode:
authorGrigori Goronzy <[email protected]>2013-09-11 01:41:40 +0200
committerMarek Olšák <[email protected]>2013-09-20 20:35:55 +0200
commitedbbfac6cfc634e697d7f981155a5072c52d77ac (patch)
tree9c04a73fc8b27b2f02bc167b71048c3546314a51 /src/gallium/drivers/r600/r600_pipe.c
parent56d9a397aa2dbee6b12e1bbe56be39f426e1e34d (diff)
r600g: fast color clears for single-sample buffers
Allocate a CMASK on demand and use it to fast clear single-sample colorbuffers. Both FBOs and window system colorbuffers are fast cleared. Expand as needed when colorbuffers are mapped or displayed on screen. v2: cosmetics, move transfer expansion into dma_blit Signed-off-by: Marek Olšák <[email protected]>
Diffstat (limited to 'src/gallium/drivers/r600/r600_pipe.c')
-rw-r--r--src/gallium/drivers/r600/r600_pipe.c4
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 f60252ad315..50ff06c9f0d 100644
--- a/src/gallium/drivers/r600/r600_pipe.c
+++ b/src/gallium/drivers/r600/r600_pipe.c
@@ -331,6 +331,9 @@ static void r600_destroy_context(struct pipe_context *context)
if (rctx->custom_blend_decompress) {
rctx->b.b.delete_blend_state(&rctx->b.b, rctx->custom_blend_decompress);
}
+ if (rctx->custom_blend_fastclear) {
+ rctx->b.b.delete_blend_state(&rctx->b.b, rctx->custom_blend_fastclear);
+ }
util_unreference_framebuffer_state(&rctx->framebuffer.state);
if (rctx->blitter) {
@@ -422,6 +425,7 @@ static struct pipe_context *r600_create_context(struct pipe_screen *screen, void
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->custom_blend_fastclear = evergreen_create_fastclear_blend(rctx);
rctx->has_vertex_cache = !(rctx->b.family == CHIP_CEDAR ||
rctx->b.family == CHIP_PALM ||
rctx->b.family == CHIP_SUMO ||