diff options
author | Dave Airlie <[email protected]> | 2017-04-27 01:47:22 +0100 |
---|---|---|
committer | Dave Airlie <[email protected]> | 2017-05-07 23:41:39 +0100 |
commit | 69136f4e633be4eeed0b226b02c9876511414b76 (patch) | |
tree | 4d7caf5fcc415a1f900d9378903f745f2e234fbc /src/amd/vulkan/radv_meta_resolve.c | |
parent | 19be95f71e6e0fbb00032d5b52f7b0c95ecd49db (diff) |
radv/meta: add resolve pass using fragment/vertex shaders
In order to resolve into DCC enabled dests we need to use
the fragment shader. This reuses the code from the compute
path and implements a resolve path in vertex/fragment shader.
This code isn't used until later.
Reviewed-by: Bas Nieuwenhuizen <[email protected]>
Signed-off-by: Dave Airlie <[email protected]>
Diffstat (limited to 'src/amd/vulkan/radv_meta_resolve.c')
-rw-r--r-- | src/amd/vulkan/radv_meta_resolve.c | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/src/amd/vulkan/radv_meta_resolve.c b/src/amd/vulkan/radv_meta_resolve.c index 784d39b58af..3e6633dec03 100644 --- a/src/amd/vulkan/radv_meta_resolve.c +++ b/src/amd/vulkan/radv_meta_resolve.c @@ -319,7 +319,7 @@ void radv_CmdResolveImage( struct radv_meta_saved_state saved_state; VkDevice device_h = radv_device_to_handle(device); bool use_compute_resolve = false; - + bool use_fragment_resolve = false; /* we can use the hw resolve only for single full resolves */ if (region_count == 1) { if (regions[0].srcOffset.x || @@ -338,8 +338,17 @@ void radv_CmdResolveImage( } else use_compute_resolve = true; - if (use_compute_resolve) { + if (use_fragment_resolve) { + radv_meta_resolve_fragment_image(cmd_buffer, + src_image, + src_image_layout, + dest_image, + dest_image_layout, + region_count, regions); + return; + } + if (use_compute_resolve) { radv_meta_resolve_compute_image(cmd_buffer, src_image, src_image_layout, |