radv: lower discards to demote to workaround a RDR2 game bug
authorSamuel Pitoiset <samuel.pitoiset@gmail.com>
Wed, 17 Jun 2020 14:35:05 +0000 (16:35 +0200)
committerSamuel Pitoiset <samuel.pitoiset@gmail.com>
Thu, 18 Jun 2020 06:39:28 +0000 (08:39 +0200)
This fixes some sort of LOD issue.

Cc: 20.1 <mesa-stable@lists.freedesktop.org>
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5525>

src/amd/vulkan/radv_device.c

index 2a51c60725986e6817a79e02b6888c997d3cd96c..f9afd722dd649ea06472f1cff9be16a7bf5699d0 100644 (file)
@@ -579,6 +579,9 @@ radv_handle_per_app_options(struct radv_instance *instance,
                } else if (!strcmp(name, "DOOMEternal")) {
                        /* Zero VRAM for Doom Eternal to fix rendering issues. */
                        instance->debug_flags |= RADV_DEBUG_ZERO_VRAM;
+               } else if (!strcmp(name, "Red Dead Redemption 2")) {
+                       /* Work around a RDR2 game bug */
+                       instance->debug_flags |= RADV_DEBUG_DISCARD_TO_DEMOTE;
                }
        }