diff options
author | Marek Olšák <[email protected]> | 2012-09-25 03:11:22 +0200 |
---|---|---|
committer | Marek Olšák <[email protected]> | 2012-09-27 19:14:44 +0200 |
commit | 933faae2b8669f459e7ab27d6bcbfb6f4136b6d5 (patch) | |
tree | 60fa5ecedd9856f708eb8f700470bacbede7b4f9 /src/gallium/drivers/r600/r600_state.c | |
parent | 9f5d6320f2ee1e8147866030212f9924c6b3bf60 (diff) |
r600g: flush FMASK and CMASK when changing colorbuffers on Evergreen
This fixes rare graphical corruption.
NOTE: This is a candidate for the stable branches.
Diffstat (limited to 'src/gallium/drivers/r600/r600_state.c')
-rw-r--r-- | src/gallium/drivers/r600/r600_state.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/gallium/drivers/r600/r600_state.c b/src/gallium/drivers/r600/r600_state.c index 1b7869c3e65..60c861fc8e0 100644 --- a/src/gallium/drivers/r600/r600_state.c +++ b/src/gallium/drivers/r600/r600_state.c @@ -1456,6 +1456,11 @@ static void r600_set_framebuffer_state(struct pipe_context *ctx, if (rctx->framebuffer.state.nr_cbufs) { rctx->flags |= R600_CONTEXT_CB_FLUSH; + + if (rctx->chip_class >= R700 && + rctx->framebuffer.state.cbufs[0]->texture->nr_samples > 1) { + rctx->flags |= R600_CONTEXT_FLUSH_AND_INV_CB_META; + } } if (rctx->framebuffer.state.zsbuf) { rctx->flags |= R600_CONTEXT_DB_FLUSH; |