diff options
author | Laura Ekstrand <laura@jlekstrand.net> | 2017-11-01 16:54:01 -0700 |
---|---|---|
committer | Laura Ekstrand <laura@jlekstrand.net> | 2017-11-01 16:54:01 -0700 |
commit | 84c5cae364f85bef62475d2b1448d58f40ee249a (patch) | |
tree | 761d0b11ac7e7b2cbb3823ec6071fcf1932c77b7 | |
parent | 7cd9cc9dd6ed0d4217992aa6ba08078ba17e2750 (diff) |
intel/vulkan: Enable MCS partial resolve in transition_color_buffer.
-rw-r--r-- | src/intel/vulkan/genX_cmd_buffer.c | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/src/intel/vulkan/genX_cmd_buffer.c b/src/intel/vulkan/genX_cmd_buffer.c index 20a885c438..866351afcd 100644 --- a/src/intel/vulkan/genX_cmd_buffer.c +++ b/src/intel/vulkan/genX_cmd_buffer.c @@ -790,9 +790,6 @@ transition_color_buffer(struct anv_cmd_buffer *cmd_buffer, * if the initial layout is COLOR_ATTACHMENT_OPTIMAL. */ return; - } else if (image->samples > 1) { - /* MCS buffers don't need resolving. */ - return; } /* Perform a resolve to synchronize data between the main and aux buffer. @@ -849,11 +846,16 @@ transition_color_buffer(struct anv_cmd_buffer *cmd_buffer, add_image_relocs(cmd_buffer, image, 0, surface_state); genX(copy_fast_clear_dwords)(cmd_buffer, surface_state.state, image, aspect, level, false /* copy to ss */); - anv_ccs_resolve(cmd_buffer, surface_state.state, image, - aspect, level, layer_count, - image->planes[plane].aux_usage == ISL_AUX_USAGE_CCS_E ? - BLORP_FAST_CLEAR_OP_RESOLVE_PARTIAL : - BLORP_FAST_CLEAR_OP_RESOLVE_FULL); + if (image->samples > 1) { + anv_mcs_partial_resolve(cmd_buffer, surface_state.state, image, + aspect, base_layer, layer_count); + } else { + anv_ccs_resolve(cmd_buffer, surface_state.state, image, + aspect, level, layer_count, + image->planes[plane].aux_usage == ISL_AUX_USAGE_CCS_E ? + BLORP_FAST_CLEAR_OP_RESOLVE_PARTIAL : + BLORP_FAST_CLEAR_OP_RESOLVE_FULL); + } genX(set_image_needs_resolve)(cmd_buffer, image, aspect, level, false); } |