diff options
author | Józef Kucia <[email protected]> | 2017-12-31 10:19:15 +0100 |
---|---|---|
committer | Juan A. Suarez Romero <[email protected]> | 2018-01-12 21:38:10 +0100 |
commit | 9a7ffd93c28e4e36fa02d4d707f55815c2e8c074 (patch) | |
tree | 0ca1105c56478ca4b196bfaab904573dcff50be8 | |
parent | 9be5e0cf7cea644916ad81f74288d4a1d86ae55d (diff) |
radeonsi: fix alpha-to-coverage if color writes are disabled
If alpha-to-coverage is enabled, we have to compute alpha
even if color writes are disabled.
Signed-off-by: Józef Kucia <[email protected]>
Signed-off-by: Marek Olšák <[email protected]>
(cherry picked from commit f222cf3c6d6fc5d9dee3742d20aa77cfff9c39f8)
-rw-r--r-- | src/gallium/drivers/radeonsi/si_state_shaders.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/gallium/drivers/radeonsi/si_state_shaders.c b/src/gallium/drivers/radeonsi/si_state_shaders.c index 9340328a72a..d0e0e8504eb 100644 --- a/src/gallium/drivers/radeonsi/si_state_shaders.c +++ b/src/gallium/drivers/radeonsi/si_state_shaders.c @@ -1228,10 +1228,13 @@ static void si_shader_selector_key_hw_vs(struct si_context *sctx, /* Find out if PS is disabled. */ bool ps_disabled = true; if (ps) { + const struct si_state_blend *blend = sctx->queued.named.blend; + bool alpha_to_coverage = blend && blend->alpha_to_coverage; bool ps_modifies_zs = ps->info.uses_kill || ps->info.writes_z || ps->info.writes_stencil || ps->info.writes_samplemask || + alpha_to_coverage || si_get_alpha_test_func(sctx) != PIPE_FUNC_ALWAYS; unsigned ps_colormask = sctx->framebuffer.colorbuf_enabled_4bit & |