turnip: use vk_format_is_int to disable COLOR_ATTACHMENT_BLEND_BIT
authorJonathan Marek <jonathan@marek.ca>
Wed, 16 Sep 2020 13:56:33 +0000 (09:56 -0400)
committerMarge Bot <eric+marge@anholt.net>
Wed, 3 Feb 2021 13:45:19 +0000 (13:45 +0000)
This is simpler and easier to understand.

Signed-off-by: Jonathan Marek <jonathan@marek.ca>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8707>

src/freedreno/vulkan/tu_formats.c

index 6a5b9ab..83a3ea8 100644 (file)
@@ -430,12 +430,8 @@ tu_physical_device_get_format_properties(
          buffer |= VK_FORMAT_FEATURE_STORAGE_TEXEL_BUFFER_ATOMIC_BIT;
       }
 
-      if (vk_format_is_float(format) ||
-          vk_format_is_unorm(format) ||
-          vk_format_is_snorm(format) ||
-          vk_format_is_srgb(format)) {
+      if (!vk_format_is_int(format))
          optimal |= VK_FORMAT_FEATURE_COLOR_ATTACHMENT_BLEND_BIT;
-      }
    }
 
    /* For the most part, we can do anything with a linear image that we could