aboutsummaryrefslogtreecommitdiffstats
path: root/src/intel/vulkan/anv_formats.c
diff options
context:
space:
mode:
authorJason Ekstrand <[email protected]>2017-01-21 11:30:40 -0800
committerJason Ekstrand <[email protected]>2018-05-09 11:16:33 -0700
commit09eede9c9d51629e70ddf8ef35ba0879073b0825 (patch)
tree8e3e3919b82271a7e5e2453a87dfc6b34d1dd36d /src/intel/vulkan/anv_formats.c
parent8ce31c9cc58489c2cc80a7ca62d14af4f386e8ef (diff)
anv: Allow blitting to/from any supported format
Now that blorp handles all the cases, why not? The only real change we have to make is to stop using anv_swizzle_for_render() in blorp_blit because it doesn't work for B4G4R4A4 and blorp now natively handles that. Reviewed-by: Topi Pohjolainen <[email protected]>
Diffstat (limited to 'src/intel/vulkan/anv_formats.c')
-rw-r--r--src/intel/vulkan/anv_formats.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/intel/vulkan/anv_formats.c b/src/intel/vulkan/anv_formats.c
index 3b821f10bdb..0c5b8d3a2c8 100644
--- a/src/intel/vulkan/anv_formats.c
+++ b/src/intel/vulkan/anv_formats.c
@@ -519,8 +519,7 @@ get_image_format_features(const struct gen_device_info *devinfo,
return 0;
if (isl_format_supports_sampling(devinfo, plane_format.isl_format)) {
- flags |= VK_FORMAT_FEATURE_SAMPLED_IMAGE_BIT |
- VK_FORMAT_FEATURE_BLIT_SRC_BIT;
+ flags |= VK_FORMAT_FEATURE_SAMPLED_IMAGE_BIT;
if (isl_format_supports_filtering(devinfo, plane_format.isl_format))
flags |= VK_FORMAT_FEATURE_SAMPLED_IMAGE_FILTER_LINEAR_BIT;
@@ -532,8 +531,7 @@ get_image_format_features(const struct gen_device_info *devinfo,
*/
if (isl_format_supports_rendering(devinfo, plane_format.isl_format) &&
plane_format.swizzle.a == ISL_CHANNEL_SELECT_ALPHA) {
- flags |= VK_FORMAT_FEATURE_COLOR_ATTACHMENT_BIT |
- VK_FORMAT_FEATURE_BLIT_DST_BIT;
+ flags |= VK_FORMAT_FEATURE_COLOR_ATTACHMENT_BIT;
if (isl_format_supports_alpha_blending(devinfo, plane_format.isl_format))
flags |= VK_FORMAT_FEATURE_COLOR_ATTACHMENT_BLEND_BIT;
@@ -550,7 +548,9 @@ get_image_format_features(const struct gen_device_info *devinfo,
flags |= VK_FORMAT_FEATURE_STORAGE_IMAGE_ATOMIC_BIT;
if (flags) {
- flags |= VK_FORMAT_FEATURE_TRANSFER_SRC_BIT |
+ flags |= VK_FORMAT_FEATURE_BLIT_SRC_BIT |
+ VK_FORMAT_FEATURE_BLIT_DST_BIT |
+ VK_FORMAT_FEATURE_TRANSFER_SRC_BIT |
VK_FORMAT_FEATURE_TRANSFER_DST_BIT;
}