radv: Fix DCC compatible formats.
authorBas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Sat, 23 Dec 2017 00:40:03 +0000 (01:40 +0100)
committerBas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Sat, 23 Dec 2017 09:58:18 +0000 (10:58 +0100)
DCC was disabled when the image format is !!supported, which is one ! too many.

Ironically the commit that introduced it was supposed to lead to more DCC use ...

Fixes: 969537d9358 "radv: Add support for more DCC compression with VK_KHR_image_format_list."
Reviewed-by: Dave Airlie <airlied@redhat.com>
src/amd/vulkan/radv_image.c

index 15410f140e74bec333a0e7909135464484559a0e..b1c4f3340eddd75011e1db77cd34fc0ec46278a2 100644 (file)
@@ -127,7 +127,7 @@ radv_init_surface(struct radv_device *device,
 
        surface->flags |= RADEON_SURF_OPTIMIZE_FOR_SPACE;
 
-       bool dcc_compatible_formats = !radv_is_colorbuffer_format_supported(pCreateInfo->format, &blendable);
+       bool dcc_compatible_formats = radv_is_colorbuffer_format_supported(pCreateInfo->format, &blendable);
        if (pCreateInfo->flags & VK_IMAGE_CREATE_MUTABLE_FORMAT_BIT) {
                const struct  VkImageFormatListCreateInfoKHR *format_list =
                          (const struct  VkImageFormatListCreateInfoKHR *)