diff options
author | Nanley Chery <[email protected]> | 2017-01-21 13:35:50 -0800 |
---|---|---|
committer | Emil Velikov <[email protected]> | 2017-02-10 12:37:49 +0000 |
commit | 7e6b4a2dd75a4082cb0c82a4bf240a6d2059a410 (patch) | |
tree | 976d25908f37975c61fb6fcbf4a3b58b226d3a3f /src/intel | |
parent | 72156aa1007089daafef5662a00e02654576ab2c (diff) |
anv/blorp: Disable resolves for transparent black clears
Signed-off-by: Nanley Chery <[email protected]>
Reviewed-by: Jason Ekstrand <[email protected]>
(cherry picked from commit 84dbf683781241038d847b9db81f153ab59e27f6)
Diffstat (limited to 'src/intel')
-rw-r--r-- | src/intel/vulkan/anv_blorp.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/intel/vulkan/anv_blorp.c b/src/intel/vulkan/anv_blorp.c index 2edd0712c95..4a4b4791162 100644 --- a/src/intel/vulkan/anv_blorp.c +++ b/src/intel/vulkan/anv_blorp.c @@ -1448,9 +1448,15 @@ ccs_resolve_attachment(struct anv_cmd_buffer *cmd_buffer, resolve_op = BLORP_FAST_CLEAR_OP_RESOLVE_FULL; } else if (att_state->fast_clear) { /* We don't know what to do with clear colors outside the render - * pass. We need a partial resolve. + * pass. We need a partial resolve. Only transparent black is + * built into the surface state object and thus no resolve is + * required for this case. */ - resolve_op = BLORP_FAST_CLEAR_OP_RESOLVE_PARTIAL; + if (att_state->clear_value.color.uint32[0] || + att_state->clear_value.color.uint32[1] || + att_state->clear_value.color.uint32[2] || + att_state->clear_value.color.uint32[3]) + resolve_op = BLORP_FAST_CLEAR_OP_RESOLVE_PARTIAL; } else { /* The image "natively" supports all the compression we care about * and we don't need to resolve at all. If this is the case, we also |