From d9072a113b2041cebfa10e6e27b5ce2687a02126 Mon Sep 17 00:00:00 2001 From: Rhys Perry Date: Mon, 20 Jul 2020 16:54:22 +0100 Subject: [PATCH] radv: replace discard with demote for Quantic Dream games MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Detroit: Become Human uses dFdx/dFdy immediately after a quad-divergent discard, which can cause the image to become white. Signed-off-by: Rhys Perry Reviewed-by: Daniel Schürmann Reviewed-by: Samuel Pitoiset Cc: Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/3212 Part-of: --- src/amd/vulkan/radv_device.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/amd/vulkan/radv_device.c b/src/amd/vulkan/radv_device.c index 53a6a3d4309..b9969e4e5eb 100644 --- a/src/amd/vulkan/radv_device.c +++ b/src/amd/vulkan/radv_device.c @@ -571,7 +571,8 @@ radv_handle_per_app_options(struct radv_instance *instance, instance->debug_flags |= RADV_DEBUG_ZERO_VRAM; } else if (!strcmp(engine_name, "Quantic Dream Engine")) { /* Fix various artifacts in Detroit: Become Human */ - instance->debug_flags |= RADV_DEBUG_ZERO_VRAM; + instance->debug_flags |= RADV_DEBUG_ZERO_VRAM | + RADV_DEBUG_DISCARD_TO_DEMOTE; } } -- 2.30.2