Browse Source

[vk] Add back VIDS but disable on EDS0 (#2957)

Should fix regressions from removing it while also fixing black screen with it enabled

Co-authored-by: JPikachu <jpikachu.eden@gmail.com>
Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/2957
Reviewed-by: Maufeat <sahyno1996@gmail.com>
Reviewed-by: CamilleLaVey <camillelavey99@gmail.com>
Co-authored-by: JPikachu <jpikachu@eden-emu.dev>
Co-committed-by: JPikachu <jpikachu@eden-emu.dev>
pull/2959/head
JPikachu 2 months ago
committed by crueter
parent
commit
1c4dae066b
No known key found for this signature in database GPG Key ID: 425ACD2D4830EBC6
  1. 19
      src/video_core/vulkan_common/vulkan_device.cpp

19
src/video_core/vulkan_common/vulkan_device.cpp

@ -612,21 +612,26 @@ Device::Device(VkInstance instance_, vk::PhysicalDevice physical_, VkSurfaceKHR
}
}
// DO NOT REMOVE THIS!!!!!!!!!!!!!!!!!
// We have confirmed on multiple different occasions that this is completely broken on RADV
// Apparently very old versions of RADV on RDNA3 as well
// RDNA1 status is unknown
// VK_EXT_vertex_input_dynamic_state (VIDS) workaround
// VIDS causes black screen when EDS=0, must be off in this case
// May cause glitches on RDNA2:
// https://gitlab.freedesktop.org/mesa/mesa/-/issues/6577
// MESA claims to have fixed it multiple times yet they haven't (expected for a project that uses GitLab)
if (extensions.vertex_input_dynamic_state && is_radv) {
const bool is_rdna2 =
supported_extensions.contains(VK_KHR_FRAGMENT_SHADING_RATE_EXTENSION_NAME);
if (is_rdna2 && !force_extensions) {
// Always disable VIDS when EDS=0 to prevent black screen
if (Settings::values.dyna_state.GetValue() == 0) {
LOG_WARNING(Render_Vulkan,
"RADV has broken VK_EXT_vertex_input_dynamic_state on RDNA2 hardware");
"Disabling VK_EXT_vertex_input_dynamic_state due to black screen with EDS=0");
RemoveExtensionFeature(extensions.vertex_input_dynamic_state,
features.vertex_input_dynamic_state,
VK_EXT_VERTEX_INPUT_DYNAMIC_STATE_EXTENSION_NAME);
} else if (is_rdna2) {
// RDNA1 status unknown
// Warn about glitches on RDNA2
LOG_WARNING(Render_Vulkan,
"RADV glitchy VK_EXT_vertex_input_dynamic_state may cause glitches on some driver versions");
}
}
if (extensions.extended_dynamic_state3 &&

Loading…
Cancel
Save