diff options
author | Nicolai Hähnle <[email protected]> | 2016-03-09 15:42:31 -0500 |
---|---|---|
committer | Nicolai Hähnle <[email protected]> | 2016-03-10 18:22:52 -0500 |
commit | 59c5508b9ab357c47aa07dfec6d74fec9d0843aa (patch) | |
tree | 6a32952be911e8b1c74d0bfbb0ef9b4ade17acd6 /src/gallium/drivers/radeonsi/si_blit.c | |
parent | da68a9b21501f4dbff6789362aec40f5221425c9 (diff) |
radeonsi: update compressed_colortex_masks when a cmask is created or disabled
Reviewed-by: Bas Nieuwenhuizen <[email protected]>
Reviewed-by: Marek Olšák <[email protected]>
Diffstat (limited to 'src/gallium/drivers/radeonsi/si_blit.c')
-rw-r--r-- | src/gallium/drivers/radeonsi/si_blit.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/gallium/drivers/radeonsi/si_blit.c b/src/gallium/drivers/radeonsi/si_blit.c index e17343fd3d3..f9a6de48f6b 100644 --- a/src/gallium/drivers/radeonsi/si_blit.c +++ b/src/gallium/drivers/radeonsi/si_blit.c @@ -352,9 +352,18 @@ si_decompress_color_textures(struct si_context *sctx, void si_decompress_textures(struct si_context *sctx) { + unsigned compressed_colortex_counter; + if (sctx->blitter->running) return; + /* Update the compressed_colortex_mask if necessary. */ + compressed_colortex_counter = p_atomic_read(&sctx->screen->b.compressed_colortex_counter); + if (compressed_colortex_counter != sctx->b.last_compressed_colortex_counter) { + sctx->b.last_compressed_colortex_counter = compressed_colortex_counter; + si_update_compressed_colortex_masks(sctx); + } + /* Flush depth textures which need to be flushed. */ for (int i = 0; i < SI_NUM_SHADERS; i++) { if (sctx->samplers[i].depth_texture_mask) { |