Commit b05e472f authored by Tk-Glitch's avatar Tk-Glitch

wine-tkg-git: Update our proton-winevulkan patchset with fixes from Josh -...

wine-tkg-git: Update our proton-winevulkan patchset with fixes from Josh - https://github.com/Joshua-Ashton/proton-wine/commit/9c92a32fdd5c71e82e30fa3a85fd9f0c018915d3

This doesn't target the no-fshack path.
We don't seem to have VkSwapchainCounterCreateInfoEXT upstream yet either.

https://github.com/ValveSoftware/wine/pull/86
parent 10246b69
......@@ -5,7 +5,7 @@ pkgver=5.4.r11.g75c7644c
# workaround for pkgrel overwritten on regen
pkgrel=1
eval pkgrel=254
eval pkgrel=255
_stgsrcdir='wine-staging-git'
_esyncsrcdir='esync'
......@@ -577,7 +577,7 @@ md5sums=('SKIP'
'16eeb21745eca0044c765d4d9e1e5cfa'
'87eb77f746f8c29bc8cff1d4dfce4bdc'
'ce595b50367e0a11e54587b204da69e3'
'9e1256bea5a24059dbd62d41c386d6cd'
'1455be625bea1fc95bbb9c3bc63fb5ed'
'dfda79f2fc402d976c35c979aa3da221'
'b3b4a54457186f85b9471dbb44f0628d')
......
......@@ -3195,3 +3195,63 @@ index 9bb33339af5..8f08ac19a2a 100644
{
X11DRV_vkCreateInstance,
X11DRV_vkCreateSwapchainKHR,
From 9c92a32fdd5c71e82e30fa3a85fd9f0c018915d3 Mon Sep 17 00:00:00 2001
From: Joshua Ashton <joshua@froggi.es>
Date: Tue, 24 Mar 2020 02:53:52 +0000
Subject: [PATCH] winevulkan: Nuke unsupported pNexts from vkCreateSwapchainKHR
Fixes RenderDoccing DXVK, and potential issues down the line in games using the fullscreen and other exts
---
dlls/winevulkan/vulkan.c | 25 +++++++++++++++++++++++++
1 file changed, 25 insertions(+)
diff --git a/dlls/winevulkan/vulkan.c b/dlls/winevulkan/vulkan.c
index f36315534b9..fdce58c9500 100644
--- a/dlls/winevulkan/vulkan.c
+++ b/dlls/winevulkan/vulkan.c
@@ -49,6 +49,15 @@ static void *wine_vk_find_struct_(void *s, VkStructureType t)
return NULL;
}
+#define wine_vk_exchange_pnext(a, b) wine_vk_exchange_pnext_((VkBaseOutStructure *)a, (VkBaseOutStructure *)b)
+static void wine_vk_exchange_pnext_(VkBaseOutStructure *a, VkBaseOutStructure *b)
+{
+ b->pNext = a->pNext;
+ a->pNext = b;
+}
+
+#define wine_vk_copy_pnext(a, ctype, stype, b) do { ctype* lookup = wine_vk_find_struct(a, stype); if (lookup) { b = *lookup; wine_vk_exchange_pnext(a, &b); } } while (0)
+
static void *wine_vk_get_global_proc_addr(const char *name);
static const struct vulkan_funcs *vk_funcs;
@@ -1739,6 +1748,9 @@ VkResult WINAPI wine_vkCreateSwapchainKHR(VkDevice device, const VkSwapchainCrea
#else
VkSwapchainCreateInfoKHR our_createinfo;
#endif
+ VkDeviceGroupSwapchainCreateInfoKHR our_device_group_swapchain_create_info;
+ VkImageFormatListCreateInfoKHR our_image_format_list_create_info;
+
VkExtent2D user_sz;
struct VkSwapchainKHR_T *object;
uint32_t i;
@@ -1754,6 +1766,19 @@ VkResult WINAPI wine_vkCreateSwapchainKHR(VkDevice device, const VkSwapchainCrea
convert_VkSwapchainCreateInfoKHR_win_to_host(pCreateInfo, &our_createinfo);
+ our_createinfo.pNext = NULL;
+
+ wine_vk_copy_pnext(&our_createinfo, VkDeviceGroupSwapchainCreateInfoKHR, DEVICE_GROUP_SWAPCHAIN_CREATE_INFO_KHR, our_device_group_swapchain_create_info);
+
+ wine_vk_copy_pnext(&our_createinfo, VkImageFormatListCreateInfoKHR, IMAGE_FORMAT_LIST_CREATE_INFO_KHR, our_image_format_list_create_info);
+
+ // VkSwapchainCounterCreateInfoEXT is not in our version of WineVulkan
+ // Come back to me when this gets into Proton Wine!
+
+ // Ignoring VkSurfaceFullScreenExclusiveInfoEXT and VkSurfaceFullScreenExclusiveWin32InfoEXT
+ // as we want to nuke those
+ // and VkSwapchainDisplayNativeHdrCreateInfoAMD (blacklisted for HDR for now)
+
if(our_createinfo.oldSwapchain)
our_createinfo.oldSwapchain = ((struct VkSwapchainKHR_T *)(UINT_PTR)our_createinfo.oldSwapchain)->swapchain;
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment