Last active
March 28, 2024 20:49
-
-
Save ananace/f1e5ccc0f447bb152d5679d9b84a3177 to your computer and use it in GitHub Desktop.
Stub for VK_EXT_full_screen_exclusive
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <vkroots.h> | |
#include <cstdint> | |
#include <algorithm> | |
#include <ranges> | |
#include <string_view> | |
#define VK_EXT_FULL_SCREEN_EXTENSION_NAME "VK_EXT_full_screen_exclusive" | |
#define VK_EXT_FULL_SCREEN_SPEC_VERSION 4 | |
namespace FakeFullscreen { | |
class VkInstanceOverrides | |
{ | |
static bool contains(const std::vector<const char *> vec, std::string_view lookupValue) | |
{ | |
return std::ranges::any_of(vec, [&lookupValue](const auto &value) { | |
return value == lookupValue; | |
}); | |
} | |
public: | |
static VkResult CreateDevice( | |
const vkroots::VkInstanceDispatch *pDispatch, | |
VkPhysicalDevice physicalDevice, | |
const VkDeviceCreateInfo* pCreateInfo, | |
const VkAllocationCallbacks* pAllocator, | |
VkDevice* pDevice) | |
{ | |
auto enabledExts = std::vector<const char *>( | |
pCreateInfo->ppEnabledExtensionNames, | |
pCreateInfo->ppEnabledExtensionNames + pCreateInfo->enabledExtensionCount); | |
if (contains(enabledExts, VK_EXT_FULL_SCREEN_EXTENSION_NAME)) { | |
std::erase(enabledExts, VK_EXT_FULL_SCREEN_EXTENSION_NAME); | |
} | |
VkDeviceCreateInfo createInfo = *pCreateInfo; | |
createInfo.enabledExtensionCount = uint32_t(enabledExts.size()); | |
createInfo.ppEnabledExtensionNames = enabledExts.data(); | |
return pDispatch->CreateDevice(physicalDevice, &createInfo, pAllocator, pDevice); | |
} | |
}; | |
} | |
VKROOTS_DEFINE_LAYER_INTERFACES(FakeFullscreen::VkInstanceOverrides, | |
vkroots::NoOverrides, | |
vkroots::NoOverrides) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"file_format_version" : "1.0.0", | |
"layer" : { | |
"name": "VK_LAYER_EXT_fakefullscreen", | |
"type": "GLOBAL", | |
"api_version": "1.3.207", | |
"library_path": "%path%/LAYER_fakefullscreen.so", | |
"implementation_version": "1", | |
"description": "Fake exclusive full-screen extension", | |
"functions": { | |
"vkNegotiateLoaderLayerInterfaceVersion": "vkNegotiateLoaderLayerInterfaceVersion" | |
}, | |
"device_extensions": [ | |
{ | |
"name": "VK_EXT_full_screen_exclusive", | |
"spec_version": "4", | |
"entrypoints": [ | |
"vkAcquireFullScreenExclusiveModeEXT", | |
"vkReleaseFullScreenExclusiveModeEXT", | |
"vkGetDeviceGroupSurfacePresentModes2EXT", | |
"vkGetPhysicalDeviceSurfacePresentModes2EXT" | |
] | |
} | |
], | |
"enable_environment": { | |
"ENABLE_FAKE_FULLSCREEN": "1" | |
}, | |
"disable_environment": { | |
"DISABLE_FAKE_FULLSCREEN": "1" | |
} | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
all: LAYER_fakefullscreen.json LAYER_fakefullscreen.so | |
LAYER_fakefullscreen.json: LAYER_fakefullscreen.json.in | |
sed -e "s|%path%|${shell pwd}|" LAYER_fakefullscreen.json.in > LAYER_fakefullscreen.json | |
LAYER_fakefullscreen.so: LAYER_fakefullscreen.cpp | |
g++ -std=c++20 -O2 -fvisibility=hidden -fPIC -shared LAYER_fakefullscreen.cpp -o LAYER_fakefullscreen.so | |
install: all | |
mkdir -p ~/.local/share/vulkan/implicit_layer.d | |
ln -s ${shell pwd}/LAYER_fakefullscreen.json ~/.local/share/vulkan/implicit_layer.d/ | |
uninstall: | |
rm ~/.local/share/vulkan/implicit_layer.d/LAYER_fakefullscreen.json | |
clean: | |
rm LAYER_fakefullscreen.so LAYER_fakefullscreen.json | |
.PHONY: all clean install uninstall |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Stub implementations for the VK_EXT_full_screen_exclusive extension | |
Acquire/Release are handled as no-ops, Get*SurfacePresentModes2EXT are routed to the KHR equivalents. | |
diff --git a/dlls/winevulkan/loader.c b/dlls/winevulkan/loader.c | |
index bd49b08057d..d0490bf79c0 100644 | |
--- a/dlls/winevulkan/loader.c | |
+++ b/dlls/winevulkan/loader.c | |
@@ -460,6 +460,40 @@ void WINAPI vkGetPhysicalDeviceProperties2KHR(VkPhysicalDevice phys_dev, | |
fill_luid_property(properties2); | |
} | |
+VkResult WINAPI vkAcquireFullScreenExclusiveModeEXT(VkDevice device, VkSwapchainKHR swapchain) | |
+{ | |
+ return VK_SUCCESS; | |
+} | |
+VkResult WINAPI vkReleaseFullScreenExclusiveModeEXT(VkDevice device, VkSwapchainKHR swapchain) | |
+{ | |
+ return VK_SUCCESS; | |
+} | |
+ | |
+VkResult WINAPI vkGetPhysicalDeviceSurfacePresentModes2EXT(VkPhysicalDevice physicalDevice, const VkPhysicalDeviceSurfaceInfo2KHR *pSurfaceInfo, uint32_t *pPresentModeCount, VkPresentModeKHR *pPresentModes) | |
+{ | |
+ struct vkGetPhysicalDeviceSurfacePresentModesKHR_params params; | |
+ NTSTATUS status; | |
+ params.physicalDevice = physicalDevice; | |
+ params.surface = pSurfaceInfo->surface; | |
+ params.pPresentModeCount = pPresentModeCount; | |
+ params.pPresentModes = pPresentModes; | |
+ status = UNIX_CALL(vkGetPhysicalDeviceSurfacePresentModesKHR, ¶ms); | |
+ assert(!status && "vkGetPhysicalDeviceSurfacePresentModes2EXT"); | |
+ return params.result; | |
+} | |
+ | |
+VkResult WINAPI vkGetDeviceGroupSurfacePresentModes2EXT(VkDevice device, const VkPhysicalDeviceSurfaceInfo2KHR *pSurfaceInfo, VkDeviceGroupPresentModeFlagsKHR *pModes) | |
+{ | |
+ struct vkGetDeviceGroupSurfacePresentModesKHR_params params; | |
+ NTSTATUS status; | |
+ params.device = device; | |
+ params.surface = pSurfaceInfo->surface; | |
+ params.pModes = pModes; | |
+ status = UNIX_CALL(vkGetDeviceGroupSurfacePresentModesKHR, ¶ms); | |
+ assert(!status && "vkGetDeviceGroupSurfacePresentModes2EXT"); | |
+ return params.result; | |
+} | |
+ | |
VkResult WINAPI vkCreateDevice(VkPhysicalDevice phys_dev, const VkDeviceCreateInfo *create_info, | |
const VkAllocationCallbacks *allocator, VkDevice *ret) | |
{ | |
diff --git a/dlls/winevulkan/loader_thunks.c b/dlls/winevulkan/loader_thunks.c | |
index 39b17ad3fe4..85a39c04f51 100644 | |
--- a/dlls/winevulkan/loader_thunks.c | |
+++ b/dlls/winevulkan/loader_thunks.c | |
@@ -6153,6 +6153,7 @@ VkResult WINAPI vkWriteMicromapsPropertiesEXT(VkDevice device, uint32_t micromap | |
static const struct vulkan_func vk_device_dispatch_table[] = | |
{ | |
+ {"vkAcquireFullScreenExclusiveModeEXT", vkAcquireFullScreenExclusiveModeEXT}, | |
{"vkAcquireNextImage2KHR", vkAcquireNextImage2KHR}, | |
{"vkAcquireNextImageKHR", vkAcquireNextImageKHR}, | |
{"vkAcquirePerformanceConfigurationINTEL", vkAcquirePerformanceConfigurationINTEL}, | |
@@ -6547,6 +6548,7 @@ static const struct vulkan_func vk_device_dispatch_table[] = | |
{"vkGetDeviceGroupPeerMemoryFeatures", vkGetDeviceGroupPeerMemoryFeatures}, | |
{"vkGetDeviceGroupPeerMemoryFeaturesKHR", vkGetDeviceGroupPeerMemoryFeaturesKHR}, | |
{"vkGetDeviceGroupPresentCapabilitiesKHR", vkGetDeviceGroupPresentCapabilitiesKHR}, | |
+ {"vkGetDeviceGroupSurfacePresentModes2EXT", vkGetDeviceGroupSurfacePresentModes2EXT}, | |
{"vkGetDeviceGroupSurfacePresentModesKHR", vkGetDeviceGroupSurfacePresentModesKHR}, | |
{"vkGetDeviceImageMemoryRequirements", vkGetDeviceImageMemoryRequirements}, | |
{"vkGetDeviceImageMemoryRequirementsKHR", vkGetDeviceImageMemoryRequirementsKHR}, | |
@@ -6628,6 +6630,7 @@ static const struct vulkan_func vk_device_dispatch_table[] = | |
{"vkQueueSubmit2", vkQueueSubmit2}, | |
{"vkQueueSubmit2KHR", vkQueueSubmit2KHR}, | |
{"vkQueueWaitIdle", vkQueueWaitIdle}, | |
+ {"vkReleaseFullScreenExclusiveModeEXT", vkReleaseFullScreenExclusiveModeEXT}, | |
{"vkReleasePerformanceConfigurationINTEL", vkReleasePerformanceConfigurationINTEL}, | |
{"vkReleaseProfilingLockKHR", vkReleaseProfilingLockKHR}, | |
{"vkReleaseSwapchainImagesEXT", vkReleaseSwapchainImagesEXT}, | |
@@ -6713,6 +6716,7 @@ static const struct vulkan_func vk_phys_dev_dispatch_table[] = | |
{"vkGetPhysicalDeviceSurfaceCapabilitiesKHR", vkGetPhysicalDeviceSurfaceCapabilitiesKHR}, | |
{"vkGetPhysicalDeviceSurfaceFormats2KHR", vkGetPhysicalDeviceSurfaceFormats2KHR}, | |
{"vkGetPhysicalDeviceSurfaceFormatsKHR", vkGetPhysicalDeviceSurfaceFormatsKHR}, | |
+ {"vkGetPhysicalDeviceSurfacePresentModes2EXT", vkGetPhysicalDeviceSurfacePresentModes2EXT}, | |
{"vkGetPhysicalDeviceSurfacePresentModesKHR", vkGetPhysicalDeviceSurfacePresentModesKHR}, | |
{"vkGetPhysicalDeviceSurfaceSupportKHR", vkGetPhysicalDeviceSurfaceSupportKHR}, | |
{"vkGetPhysicalDeviceToolProperties", vkGetPhysicalDeviceToolProperties}, | |
diff --git a/dlls/winevulkan/loader_thunks.h b/dlls/winevulkan/loader_thunks.h | |
index 8b06032c637..66764115de3 100644 | |
--- a/dlls/winevulkan/loader_thunks.h | |
+++ b/dlls/winevulkan/loader_thunks.h | |
@@ -17,6 +17,7 @@ enum unix_call | |
unix_init, | |
unix_is_available_instance_function, | |
unix_is_available_device_function, | |
+ unix_vkAcquireFullScreenExclusiveModeEXT, | |
unix_vkAcquireNextImage2KHR, | |
unix_vkAcquireNextImageKHR, | |
unix_vkAcquirePerformanceConfigurationINTEL, | |
@@ -429,6 +430,7 @@ enum unix_call | |
unix_vkGetDeviceGroupPeerMemoryFeatures, | |
unix_vkGetDeviceGroupPeerMemoryFeaturesKHR, | |
unix_vkGetDeviceGroupPresentCapabilitiesKHR, | |
+ unix_vkGetDeviceGroupSurfacePresentModes2EXT, | |
unix_vkGetDeviceGroupSurfacePresentModesKHR, | |
unix_vkGetDeviceImageMemoryRequirements, | |
unix_vkGetDeviceImageMemoryRequirementsKHR, | |
@@ -505,6 +507,7 @@ enum unix_call | |
unix_vkGetPhysicalDeviceSurfaceCapabilitiesKHR, | |
unix_vkGetPhysicalDeviceSurfaceFormats2KHR, | |
unix_vkGetPhysicalDeviceSurfaceFormatsKHR, | |
+ unix_vkGetPhysicalDeviceSurfacePresentModes2EXT, | |
unix_vkGetPhysicalDeviceSurfacePresentModesKHR, | |
unix_vkGetPhysicalDeviceSurfaceSupportKHR, | |
unix_vkGetPhysicalDeviceToolProperties, | |
@@ -555,6 +558,7 @@ enum unix_call | |
unix_vkQueueSubmit2, | |
unix_vkQueueSubmit2KHR, | |
unix_vkQueueWaitIdle, | |
+ unix_vkReleaseFullScreenExclusiveModeEXT, | |
unix_vkReleasePerformanceConfigurationINTEL, | |
unix_vkReleaseProfilingLockKHR, | |
unix_vkReleaseSwapchainImagesEXT, | |
@@ -595,6 +599,13 @@ enum unix_call | |
unix_count, | |
}; | |
+struct vkAcquireFullScreenExclusiveModeEXT_params | |
+{ | |
+ VkDevice device; | |
+ VkSwapchainKHR DECLSPEC_ALIGN(8) swapchain; | |
+ VkResult result; | |
+}; | |
+ | |
struct vkAcquireNextImage2KHR_params | |
{ | |
VkDevice device; | |
@@ -3780,6 +3791,14 @@ struct vkGetDeviceGroupPresentCapabilitiesKHR_params | |
VkResult result; | |
}; | |
+struct vkGetDeviceGroupSurfacePresentModes2EXT_params | |
+{ | |
+ VkDevice device; | |
+ const VkPhysicalDeviceSurfaceInfo2KHR *pSurfaceInfo; | |
+ VkDeviceGroupPresentModeFlagsKHR *pModes; | |
+ VkResult result; | |
+}; | |
+ | |
struct vkGetDeviceGroupSurfacePresentModesKHR_params | |
{ | |
VkDevice device; | |
@@ -4354,6 +4373,15 @@ struct vkGetPhysicalDeviceSurfaceFormatsKHR_params | |
VkResult result; | |
}; | |
+struct vkGetPhysicalDeviceSurfacePresentModes2EXT_params | |
+{ | |
+ VkPhysicalDevice physicalDevice; | |
+ const VkPhysicalDeviceSurfaceInfo2KHR *pSurfaceInfo; | |
+ uint32_t *pPresentModeCount; | |
+ VkPresentModeKHR *pPresentModes; | |
+ VkResult result; | |
+}; | |
+ | |
struct vkGetPhysicalDeviceSurfacePresentModesKHR_params | |
{ | |
VkPhysicalDevice physicalDevice; | |
@@ -4769,6 +4797,13 @@ struct vkQueueWaitIdle_params | |
VkResult result; | |
}; | |
+struct vkReleaseFullScreenExclusiveModeEXT_params | |
+{ | |
+ VkDevice device; | |
+ VkSwapchainKHR DECLSPEC_ALIGN(8) swapchain; | |
+ VkResult result; | |
+}; | |
+ | |
struct vkReleasePerformanceConfigurationINTEL_params | |
{ | |
VkDevice device; | |
diff --git a/dlls/winevulkan/make_vulkan b/dlls/winevulkan/make_vulkan | |
index 6b4debf20ff..35ce4508aba 100755 | |
--- a/dlls/winevulkan/make_vulkan | |
+++ b/dlls/winevulkan/make_vulkan | |
@@ -95,7 +95,7 @@ UNSUPPORTED_EXTENSIONS = [ | |
# Device extensions | |
"VK_AMD_display_native_hdr", | |
- "VK_EXT_full_screen_exclusive", | |
+ # "VK_EXT_full_screen_exclusive", | |
"VK_GOOGLE_display_timing", | |
"VK_KHR_external_fence_win32", | |
"VK_KHR_external_semaphore_win32", | |
@@ -288,6 +288,10 @@ MANUAL_LOADER_THUNKS = { | |
"vkFreeCommandBuffers", | |
"vkGetPhysicalDeviceProperties2", | |
"vkGetPhysicalDeviceProperties2KHR", | |
+ "vkAcquireFullScreenExclusiveModeEXT", | |
+ "vkReleaseFullScreenExclusiveModeEXT", | |
+ "vkGetPhysicalDeviceSurfacePresentModes2EXT", | |
+ "vkGetDeviceGroupSurfacePresentModes2EXT", | |
} | |
STRUCT_CHAIN_CONVERSIONS = { | |
diff --git a/dlls/winevulkan/vulkan_thunks.c b/dlls/winevulkan/vulkan_thunks.c | |
index 93e52b46a9d..fada1fb0c7e 100644 | |
--- a/dlls/winevulkan/vulkan_thunks.c | |
+++ b/dlls/winevulkan/vulkan_thunks.c | |
@@ -4475,6 +4475,20 @@ typedef struct VkDeviceGroupSwapchainCreateInfoKHR32 | |
VkDeviceGroupPresentModeFlagsKHR modes; | |
} VkDeviceGroupSwapchainCreateInfoKHR32; | |
+typedef struct VkSurfaceFullScreenExclusiveInfoEXT32 | |
+{ | |
+ VkStructureType sType; | |
+ PTR32 pNext; | |
+ VkFullScreenExclusiveEXT fullScreenExclusive; | |
+} VkSurfaceFullScreenExclusiveInfoEXT32; | |
+ | |
+typedef struct VkSurfaceFullScreenExclusiveWin32InfoEXT32 | |
+{ | |
+ VkStructureType sType; | |
+ PTR32 pNext; | |
+ HMONITOR hmonitor; | |
+} VkSurfaceFullScreenExclusiveWin32InfoEXT32; | |
+ | |
typedef struct VkSwapchainPresentBarrierCreateInfoNV32 | |
{ | |
VkStructureType sType; | |
@@ -4813,6 +4827,20 @@ typedef struct VkDeviceGroupPresentCapabilitiesKHR32 | |
VkDeviceGroupPresentModeFlagsKHR modes; | |
} VkDeviceGroupPresentCapabilitiesKHR32; | |
+typedef struct VkSurfacePresentModeEXT32 | |
+{ | |
+ VkStructureType sType; | |
+ PTR32 pNext; | |
+ VkPresentModeKHR presentMode; | |
+} VkSurfacePresentModeEXT32; | |
+ | |
+typedef struct VkPhysicalDeviceSurfaceInfo2KHR32 | |
+{ | |
+ VkStructureType sType; | |
+ PTR32 pNext; | |
+ VkSurfaceKHR DECLSPEC_ALIGN(8) surface; | |
+} VkPhysicalDeviceSurfaceInfo2KHR32; | |
+ | |
typedef struct VkDeviceImageMemoryRequirements32 | |
{ | |
VkStructureType sType; | |
@@ -6493,19 +6521,12 @@ typedef struct VkFramebufferMixedSamplesCombinationNV32 | |
VkSampleCountFlags colorSamples; | |
} VkFramebufferMixedSamplesCombinationNV32; | |
-typedef struct VkSurfacePresentModeEXT32 | |
-{ | |
- VkStructureType sType; | |
- PTR32 pNext; | |
- VkPresentModeKHR presentMode; | |
-} VkSurfacePresentModeEXT32; | |
- | |
-typedef struct VkPhysicalDeviceSurfaceInfo2KHR32 | |
+typedef struct VkSurfaceCapabilitiesFullScreenExclusiveEXT32 | |
{ | |
VkStructureType sType; | |
PTR32 pNext; | |
- VkSurfaceKHR DECLSPEC_ALIGN(8) surface; | |
-} VkPhysicalDeviceSurfaceInfo2KHR32; | |
+ VkBool32 fullScreenExclusiveSupported; | |
+} VkSurfaceCapabilitiesFullScreenExclusiveEXT32; | |
typedef struct VkSurfaceCapabilitiesPresentBarrierNV32 | |
{ | |
@@ -19427,6 +19448,28 @@ static inline void convert_VkSwapchainCreateInfoKHR_win32_to_unwrapped_host(stru | |
out_header = (void *)out_ext; | |
break; | |
} | |
+ case VK_STRUCTURE_TYPE_SURFACE_FULL_SCREEN_EXCLUSIVE_INFO_EXT: | |
+ { | |
+ VkSurfaceFullScreenExclusiveInfoEXT *out_ext = conversion_context_alloc(ctx, sizeof(*out_ext)); | |
+ const VkSurfaceFullScreenExclusiveInfoEXT32 *in_ext = (const VkSurfaceFullScreenExclusiveInfoEXT32 *)in_header; | |
+ out_ext->sType = VK_STRUCTURE_TYPE_SURFACE_FULL_SCREEN_EXCLUSIVE_INFO_EXT; | |
+ out_ext->pNext = NULL; | |
+ out_ext->fullScreenExclusive = in_ext->fullScreenExclusive; | |
+ out_header->pNext = (void *)out_ext; | |
+ out_header = (void *)out_ext; | |
+ break; | |
+ } | |
+ case VK_STRUCTURE_TYPE_SURFACE_FULL_SCREEN_EXCLUSIVE_WIN32_INFO_EXT: | |
+ { | |
+ VkSurfaceFullScreenExclusiveWin32InfoEXT *out_ext = conversion_context_alloc(ctx, sizeof(*out_ext)); | |
+ const VkSurfaceFullScreenExclusiveWin32InfoEXT32 *in_ext = (const VkSurfaceFullScreenExclusiveWin32InfoEXT32 *)in_header; | |
+ out_ext->sType = VK_STRUCTURE_TYPE_SURFACE_FULL_SCREEN_EXCLUSIVE_WIN32_INFO_EXT; | |
+ out_ext->pNext = NULL; | |
+ out_ext->hmonitor = in_ext->hmonitor; | |
+ out_header->pNext = (void *)out_ext; | |
+ out_header = (void *)out_ext; | |
+ break; | |
+ } | |
case VK_STRUCTURE_TYPE_SWAPCHAIN_PRESENT_BARRIER_CREATE_INFO_NV: | |
{ | |
VkSwapchainPresentBarrierCreateInfoNV *out_ext = conversion_context_alloc(ctx, sizeof(*out_ext)); | |
@@ -20339,6 +20382,72 @@ static inline void convert_VkDeviceGroupPresentCapabilitiesKHR_host_to_win32(con | |
out->modes = in->modes; | |
} | |
+#ifdef _WIN64 | |
+static inline void convert_VkPhysicalDeviceSurfaceInfo2KHR_win64_to_host(const VkPhysicalDeviceSurfaceInfo2KHR *in, VkPhysicalDeviceSurfaceInfo2KHR *out) | |
+{ | |
+ if (!in) return; | |
+ | |
+ out->sType = in->sType; | |
+ out->pNext = in->pNext; | |
+ out->surface = in->surface ? wine_surface_from_handle(in->surface)->host_surface : 0; | |
+} | |
+#endif /* _WIN64 */ | |
+ | |
+static inline void convert_VkPhysicalDeviceSurfaceInfo2KHR_win32_to_host(struct conversion_context *ctx, const VkPhysicalDeviceSurfaceInfo2KHR32 *in, VkPhysicalDeviceSurfaceInfo2KHR *out) | |
+{ | |
+ const VkBaseInStructure32 *in_header; | |
+ VkBaseOutStructure *out_header = (void *)out; | |
+ | |
+ if (!in) return; | |
+ | |
+ out->sType = in->sType; | |
+ out->pNext = NULL; | |
+ out->surface = in->surface ? wine_surface_from_handle(in->surface)->host_surface : 0; | |
+ | |
+ for (in_header = UlongToPtr(in->pNext); in_header; in_header = UlongToPtr(in_header->pNext)) | |
+ { | |
+ switch (in_header->sType) | |
+ { | |
+ case VK_STRUCTURE_TYPE_SURFACE_FULL_SCREEN_EXCLUSIVE_INFO_EXT: | |
+ { | |
+ VkSurfaceFullScreenExclusiveInfoEXT *out_ext = conversion_context_alloc(ctx, sizeof(*out_ext)); | |
+ const VkSurfaceFullScreenExclusiveInfoEXT32 *in_ext = (const VkSurfaceFullScreenExclusiveInfoEXT32 *)in_header; | |
+ out_ext->sType = VK_STRUCTURE_TYPE_SURFACE_FULL_SCREEN_EXCLUSIVE_INFO_EXT; | |
+ out_ext->pNext = NULL; | |
+ out_ext->fullScreenExclusive = in_ext->fullScreenExclusive; | |
+ out_header->pNext = (void *)out_ext; | |
+ out_header = (void *)out_ext; | |
+ break; | |
+ } | |
+ case VK_STRUCTURE_TYPE_SURFACE_FULL_SCREEN_EXCLUSIVE_WIN32_INFO_EXT: | |
+ { | |
+ VkSurfaceFullScreenExclusiveWin32InfoEXT *out_ext = conversion_context_alloc(ctx, sizeof(*out_ext)); | |
+ const VkSurfaceFullScreenExclusiveWin32InfoEXT32 *in_ext = (const VkSurfaceFullScreenExclusiveWin32InfoEXT32 *)in_header; | |
+ out_ext->sType = VK_STRUCTURE_TYPE_SURFACE_FULL_SCREEN_EXCLUSIVE_WIN32_INFO_EXT; | |
+ out_ext->pNext = NULL; | |
+ out_ext->hmonitor = in_ext->hmonitor; | |
+ out_header->pNext = (void *)out_ext; | |
+ out_header = (void *)out_ext; | |
+ break; | |
+ } | |
+ case VK_STRUCTURE_TYPE_SURFACE_PRESENT_MODE_EXT: | |
+ { | |
+ VkSurfacePresentModeEXT *out_ext = conversion_context_alloc(ctx, sizeof(*out_ext)); | |
+ const VkSurfacePresentModeEXT32 *in_ext = (const VkSurfacePresentModeEXT32 *)in_header; | |
+ out_ext->sType = VK_STRUCTURE_TYPE_SURFACE_PRESENT_MODE_EXT; | |
+ out_ext->pNext = NULL; | |
+ out_ext->presentMode = in_ext->presentMode; | |
+ out_header->pNext = (void *)out_ext; | |
+ out_header = (void *)out_ext; | |
+ break; | |
+ } | |
+ default: | |
+ FIXME("Unhandled sType %u.\n", in_header->sType); | |
+ break; | |
+ } | |
+ } | |
+} | |
+ | |
#ifdef _WIN64 | |
static inline const VkImageCreateInfo *convert_VkImageCreateInfo_array_win64_to_host(struct conversion_context *ctx, const VkImageCreateInfo *in, uint32_t count) | |
{ | |
@@ -28170,6 +28279,28 @@ static inline void convert_VkPhysicalDeviceSurfaceInfo2KHR_win32_to_unwrapped_ho | |
{ | |
switch (in_header->sType) | |
{ | |
+ case VK_STRUCTURE_TYPE_SURFACE_FULL_SCREEN_EXCLUSIVE_INFO_EXT: | |
+ { | |
+ VkSurfaceFullScreenExclusiveInfoEXT *out_ext = conversion_context_alloc(ctx, sizeof(*out_ext)); | |
+ const VkSurfaceFullScreenExclusiveInfoEXT32 *in_ext = (const VkSurfaceFullScreenExclusiveInfoEXT32 *)in_header; | |
+ out_ext->sType = VK_STRUCTURE_TYPE_SURFACE_FULL_SCREEN_EXCLUSIVE_INFO_EXT; | |
+ out_ext->pNext = NULL; | |
+ out_ext->fullScreenExclusive = in_ext->fullScreenExclusive; | |
+ out_header->pNext = (void *)out_ext; | |
+ out_header = (void *)out_ext; | |
+ break; | |
+ } | |
+ case VK_STRUCTURE_TYPE_SURFACE_FULL_SCREEN_EXCLUSIVE_WIN32_INFO_EXT: | |
+ { | |
+ VkSurfaceFullScreenExclusiveWin32InfoEXT *out_ext = conversion_context_alloc(ctx, sizeof(*out_ext)); | |
+ const VkSurfaceFullScreenExclusiveWin32InfoEXT32 *in_ext = (const VkSurfaceFullScreenExclusiveWin32InfoEXT32 *)in_header; | |
+ out_ext->sType = VK_STRUCTURE_TYPE_SURFACE_FULL_SCREEN_EXCLUSIVE_WIN32_INFO_EXT; | |
+ out_ext->pNext = NULL; | |
+ out_ext->hmonitor = in_ext->hmonitor; | |
+ out_header->pNext = (void *)out_ext; | |
+ out_header = (void *)out_ext; | |
+ break; | |
+ } | |
case VK_STRUCTURE_TYPE_SURFACE_PRESENT_MODE_EXT: | |
{ | |
VkSurfacePresentModeEXT *out_ext = conversion_context_alloc(ctx, sizeof(*out_ext)); | |
@@ -28202,6 +28333,17 @@ static inline void convert_VkSurfaceCapabilities2KHR_win32_to_host(struct conver | |
{ | |
switch (in_header->sType) | |
{ | |
+ case VK_STRUCTURE_TYPE_SURFACE_CAPABILITIES_FULL_SCREEN_EXCLUSIVE_EXT: | |
+ { | |
+ VkSurfaceCapabilitiesFullScreenExclusiveEXT *out_ext = conversion_context_alloc(ctx, sizeof(*out_ext)); | |
+ const VkSurfaceCapabilitiesFullScreenExclusiveEXT32 *in_ext = (const VkSurfaceCapabilitiesFullScreenExclusiveEXT32 *)in_header; | |
+ out_ext->sType = VK_STRUCTURE_TYPE_SURFACE_CAPABILITIES_FULL_SCREEN_EXCLUSIVE_EXT; | |
+ out_ext->pNext = NULL; | |
+ out_ext->fullScreenExclusiveSupported = in_ext->fullScreenExclusiveSupported; | |
+ out_header->pNext = (void *)out_ext; | |
+ out_header = (void *)out_ext; | |
+ break; | |
+ } | |
case VK_STRUCTURE_TYPE_SURFACE_CAPABILITIES_PRESENT_BARRIER_NV: | |
{ | |
VkSurfaceCapabilitiesPresentBarrierNV *out_ext = conversion_context_alloc(ctx, sizeof(*out_ext)); | |
@@ -28270,6 +28412,15 @@ static inline void convert_VkSurfaceCapabilities2KHR_host_to_win32(const VkSurfa | |
{ | |
switch (in_header->sType) | |
{ | |
+ case VK_STRUCTURE_TYPE_SURFACE_CAPABILITIES_FULL_SCREEN_EXCLUSIVE_EXT: | |
+ { | |
+ VkSurfaceCapabilitiesFullScreenExclusiveEXT32 *out_ext = find_next_struct32(out_header, VK_STRUCTURE_TYPE_SURFACE_CAPABILITIES_FULL_SCREEN_EXCLUSIVE_EXT); | |
+ const VkSurfaceCapabilitiesFullScreenExclusiveEXT *in_ext = (const VkSurfaceCapabilitiesFullScreenExclusiveEXT *)in_header; | |
+ out_ext->sType = VK_STRUCTURE_TYPE_SURFACE_CAPABILITIES_FULL_SCREEN_EXCLUSIVE_EXT; | |
+ out_ext->fullScreenExclusiveSupported = in_ext->fullScreenExclusiveSupported; | |
+ out_header = (void *)out_ext; | |
+ break; | |
+ } | |
case VK_STRUCTURE_TYPE_SURFACE_CAPABILITIES_PRESENT_BARRIER_NV: | |
{ | |
VkSurfaceCapabilitiesPresentBarrierNV32 *out_ext = find_next_struct32(out_header, VK_STRUCTURE_TYPE_SURFACE_CAPABILITIES_PRESENT_BARRIER_NV); | |
@@ -30239,6 +30390,33 @@ static inline void convert_VkSemaphoreWaitInfo_win32_to_host(const VkSemaphoreWa | |
FIXME("Unexpected pNext\n"); | |
} | |
+#ifdef _WIN64 | |
+static NTSTATUS thunk64_vkAcquireFullScreenExclusiveModeEXT(void *args) | |
+{ | |
+ struct vkAcquireFullScreenExclusiveModeEXT_params *params = args; | |
+ | |
+ TRACE("%p, 0x%s\n", params->device, wine_dbgstr_longlong(params->swapchain)); | |
+ | |
+ params->result = wine_device_from_handle(params->device)->funcs.p_vkAcquireFullScreenExclusiveModeEXT(wine_device_from_handle(params->device)->host_device, wine_swapchain_from_handle(params->swapchain)->host_swapchain); | |
+ return STATUS_SUCCESS; | |
+} | |
+#endif /* _WIN64 */ | |
+ | |
+static NTSTATUS thunk32_vkAcquireFullScreenExclusiveModeEXT(void *args) | |
+{ | |
+ struct | |
+ { | |
+ PTR32 device; | |
+ VkSwapchainKHR DECLSPEC_ALIGN(8) swapchain; | |
+ VkResult result; | |
+ } *params = args; | |
+ | |
+ TRACE("%#x, 0x%s\n", params->device, wine_dbgstr_longlong(params->swapchain)); | |
+ | |
+ params->result = wine_device_from_handle((VkDevice)UlongToPtr(params->device))->funcs.p_vkAcquireFullScreenExclusiveModeEXT(wine_device_from_handle((VkDevice)UlongToPtr(params->device))->host_device, wine_swapchain_from_handle(params->swapchain)->host_swapchain); | |
+ return STATUS_SUCCESS; | |
+} | |
+ | |
#ifdef _WIN64 | |
static NTSTATUS thunk64_vkAcquireNextImage2KHR(void *args) | |
{ | |
@@ -41224,6 +41402,42 @@ static NTSTATUS thunk32_vkGetDeviceGroupPresentCapabilitiesKHR(void *args) | |
return STATUS_SUCCESS; | |
} | |
+#ifdef _WIN64 | |
+static NTSTATUS thunk64_vkGetDeviceGroupSurfacePresentModes2EXT(void *args) | |
+{ | |
+ struct vkGetDeviceGroupSurfacePresentModes2EXT_params *params = args; | |
+ VkPhysicalDeviceSurfaceInfo2KHR pSurfaceInfo_host; | |
+ | |
+ TRACE("%p, %p, %p\n", params->device, params->pSurfaceInfo, params->pModes); | |
+ | |
+ convert_VkPhysicalDeviceSurfaceInfo2KHR_win64_to_host(params->pSurfaceInfo, &pSurfaceInfo_host); | |
+ params->result = wine_device_from_handle(params->device)->funcs.p_vkGetDeviceGroupSurfacePresentModes2EXT(wine_device_from_handle(params->device)->host_device, &pSurfaceInfo_host, params->pModes); | |
+ return STATUS_SUCCESS; | |
+} | |
+#endif /* _WIN64 */ | |
+ | |
+static NTSTATUS thunk32_vkGetDeviceGroupSurfacePresentModes2EXT(void *args) | |
+{ | |
+ struct | |
+ { | |
+ PTR32 device; | |
+ PTR32 pSurfaceInfo; | |
+ PTR32 pModes; | |
+ VkResult result; | |
+ } *params = args; | |
+ VkPhysicalDeviceSurfaceInfo2KHR pSurfaceInfo_host; | |
+ struct conversion_context local_ctx; | |
+ struct conversion_context *ctx = &local_ctx; | |
+ | |
+ TRACE("%#x, %#x, %#x\n", params->device, params->pSurfaceInfo, params->pModes); | |
+ | |
+ init_conversion_context(ctx); | |
+ convert_VkPhysicalDeviceSurfaceInfo2KHR_win32_to_host(ctx, (const VkPhysicalDeviceSurfaceInfo2KHR32 *)UlongToPtr(params->pSurfaceInfo), &pSurfaceInfo_host); | |
+ params->result = wine_device_from_handle((VkDevice)UlongToPtr(params->device))->funcs.p_vkGetDeviceGroupSurfacePresentModes2EXT(wine_device_from_handle((VkDevice)UlongToPtr(params->device))->host_device, &pSurfaceInfo_host, (VkDeviceGroupPresentModeFlagsKHR *)UlongToPtr(params->pModes)); | |
+ free_conversion_context(ctx); | |
+ return STATUS_SUCCESS; | |
+} | |
+ | |
#ifdef _WIN64 | |
static NTSTATUS thunk64_vkGetDeviceGroupSurfacePresentModesKHR(void *args) | |
{ | |
@@ -43750,6 +43964,43 @@ static NTSTATUS thunk32_vkGetPhysicalDeviceSurfaceFormatsKHR(void *args) | |
return STATUS_SUCCESS; | |
} | |
+#ifdef _WIN64 | |
+static NTSTATUS thunk64_vkGetPhysicalDeviceSurfacePresentModes2EXT(void *args) | |
+{ | |
+ struct vkGetPhysicalDeviceSurfacePresentModes2EXT_params *params = args; | |
+ VkPhysicalDeviceSurfaceInfo2KHR pSurfaceInfo_host; | |
+ | |
+ TRACE("%p, %p, %p, %p\n", params->physicalDevice, params->pSurfaceInfo, params->pPresentModeCount, params->pPresentModes); | |
+ | |
+ convert_VkPhysicalDeviceSurfaceInfo2KHR_win64_to_host(params->pSurfaceInfo, &pSurfaceInfo_host); | |
+ params->result = wine_phys_dev_from_handle(params->physicalDevice)->instance->funcs.p_vkGetPhysicalDeviceSurfacePresentModes2EXT(wine_phys_dev_from_handle(params->physicalDevice)->host_physical_device, &pSurfaceInfo_host, params->pPresentModeCount, params->pPresentModes); | |
+ return STATUS_SUCCESS; | |
+} | |
+#endif /* _WIN64 */ | |
+ | |
+static NTSTATUS thunk32_vkGetPhysicalDeviceSurfacePresentModes2EXT(void *args) | |
+{ | |
+ struct | |
+ { | |
+ PTR32 physicalDevice; | |
+ PTR32 pSurfaceInfo; | |
+ PTR32 pPresentModeCount; | |
+ PTR32 pPresentModes; | |
+ VkResult result; | |
+ } *params = args; | |
+ VkPhysicalDeviceSurfaceInfo2KHR pSurfaceInfo_host; | |
+ struct conversion_context local_ctx; | |
+ struct conversion_context *ctx = &local_ctx; | |
+ | |
+ TRACE("%#x, %#x, %#x, %#x\n", params->physicalDevice, params->pSurfaceInfo, params->pPresentModeCount, params->pPresentModes); | |
+ | |
+ init_conversion_context(ctx); | |
+ convert_VkPhysicalDeviceSurfaceInfo2KHR_win32_to_host(ctx, (const VkPhysicalDeviceSurfaceInfo2KHR32 *)UlongToPtr(params->pSurfaceInfo), &pSurfaceInfo_host); | |
+ params->result = wine_phys_dev_from_handle((VkPhysicalDevice)UlongToPtr(params->physicalDevice))->instance->funcs.p_vkGetPhysicalDeviceSurfacePresentModes2EXT(wine_phys_dev_from_handle((VkPhysicalDevice)UlongToPtr(params->physicalDevice))->host_physical_device, &pSurfaceInfo_host, (uint32_t *)UlongToPtr(params->pPresentModeCount), (VkPresentModeKHR *)UlongToPtr(params->pPresentModes)); | |
+ free_conversion_context(ctx); | |
+ return STATUS_SUCCESS; | |
+} | |
+ | |
#ifdef _WIN64 | |
static NTSTATUS thunk64_vkGetPhysicalDeviceSurfacePresentModesKHR(void *args) | |
{ | |
@@ -45356,6 +45607,33 @@ static NTSTATUS thunk32_vkQueueWaitIdle(void *args) | |
return STATUS_SUCCESS; | |
} | |
+#ifdef _WIN64 | |
+static NTSTATUS thunk64_vkReleaseFullScreenExclusiveModeEXT(void *args) | |
+{ | |
+ struct vkReleaseFullScreenExclusiveModeEXT_params *params = args; | |
+ | |
+ TRACE("%p, 0x%s\n", params->device, wine_dbgstr_longlong(params->swapchain)); | |
+ | |
+ params->result = wine_device_from_handle(params->device)->funcs.p_vkReleaseFullScreenExclusiveModeEXT(wine_device_from_handle(params->device)->host_device, wine_swapchain_from_handle(params->swapchain)->host_swapchain); | |
+ return STATUS_SUCCESS; | |
+} | |
+#endif /* _WIN64 */ | |
+ | |
+static NTSTATUS thunk32_vkReleaseFullScreenExclusiveModeEXT(void *args) | |
+{ | |
+ struct | |
+ { | |
+ PTR32 device; | |
+ VkSwapchainKHR DECLSPEC_ALIGN(8) swapchain; | |
+ VkResult result; | |
+ } *params = args; | |
+ | |
+ TRACE("%#x, 0x%s\n", params->device, wine_dbgstr_longlong(params->swapchain)); | |
+ | |
+ params->result = wine_device_from_handle((VkDevice)UlongToPtr(params->device))->funcs.p_vkReleaseFullScreenExclusiveModeEXT(wine_device_from_handle((VkDevice)UlongToPtr(params->device))->host_device, wine_swapchain_from_handle(params->swapchain)->host_swapchain); | |
+ return STATUS_SUCCESS; | |
+} | |
+ | |
#ifdef _WIN64 | |
static NTSTATUS thunk64_vkReleasePerformanceConfigurationINTEL(void *args) | |
{ | |
@@ -46502,6 +46780,7 @@ static const char * const vk_device_extensions[] = | |
"VK_EXT_fragment_density_map2", | |
"VK_EXT_fragment_shader_interlock", | |
"VK_EXT_frame_boundary", | |
+ "VK_EXT_full_screen_exclusive", | |
"VK_EXT_global_priority", | |
"VK_EXT_global_priority_query", | |
"VK_EXT_graphics_pipeline_library", | |
@@ -46795,6 +47074,7 @@ const unixlib_entry_t __wine_unix_call_funcs[] = | |
init_vulkan, | |
vk_is_available_instance_function, | |
vk_is_available_device_function, | |
+ thunk64_vkAcquireFullScreenExclusiveModeEXT, | |
thunk64_vkAcquireNextImage2KHR, | |
thunk64_vkAcquireNextImageKHR, | |
thunk64_vkAcquirePerformanceConfigurationINTEL, | |
@@ -47207,6 +47487,7 @@ const unixlib_entry_t __wine_unix_call_funcs[] = | |
thunk64_vkGetDeviceGroupPeerMemoryFeatures, | |
thunk64_vkGetDeviceGroupPeerMemoryFeaturesKHR, | |
thunk64_vkGetDeviceGroupPresentCapabilitiesKHR, | |
+ thunk64_vkGetDeviceGroupSurfacePresentModes2EXT, | |
thunk64_vkGetDeviceGroupSurfacePresentModesKHR, | |
thunk64_vkGetDeviceImageMemoryRequirements, | |
thunk64_vkGetDeviceImageMemoryRequirementsKHR, | |
@@ -47283,6 +47564,7 @@ const unixlib_entry_t __wine_unix_call_funcs[] = | |
thunk64_vkGetPhysicalDeviceSurfaceCapabilitiesKHR, | |
thunk64_vkGetPhysicalDeviceSurfaceFormats2KHR, | |
thunk64_vkGetPhysicalDeviceSurfaceFormatsKHR, | |
+ thunk64_vkGetPhysicalDeviceSurfacePresentModes2EXT, | |
thunk64_vkGetPhysicalDeviceSurfacePresentModesKHR, | |
thunk64_vkGetPhysicalDeviceSurfaceSupportKHR, | |
thunk64_vkGetPhysicalDeviceToolProperties, | |
@@ -47333,6 +47615,7 @@ const unixlib_entry_t __wine_unix_call_funcs[] = | |
thunk64_vkQueueSubmit2, | |
thunk64_vkQueueSubmit2KHR, | |
thunk64_vkQueueWaitIdle, | |
+ thunk64_vkReleaseFullScreenExclusiveModeEXT, | |
thunk64_vkReleasePerformanceConfigurationINTEL, | |
thunk64_vkReleaseProfilingLockKHR, | |
thunk64_vkReleaseSwapchainImagesEXT, | |
@@ -47384,6 +47667,7 @@ const unixlib_entry_t __wine_unix_call_funcs[] = | |
init_vulkan, | |
vk_is_available_instance_function32, | |
vk_is_available_device_function32, | |
+ thunk32_vkAcquireFullScreenExclusiveModeEXT, | |
thunk32_vkAcquireNextImage2KHR, | |
thunk32_vkAcquireNextImageKHR, | |
thunk32_vkAcquirePerformanceConfigurationINTEL, | |
@@ -47796,6 +48080,7 @@ const unixlib_entry_t __wine_unix_call_funcs[] = | |
thunk32_vkGetDeviceGroupPeerMemoryFeatures, | |
thunk32_vkGetDeviceGroupPeerMemoryFeaturesKHR, | |
thunk32_vkGetDeviceGroupPresentCapabilitiesKHR, | |
+ thunk32_vkGetDeviceGroupSurfacePresentModes2EXT, | |
thunk32_vkGetDeviceGroupSurfacePresentModesKHR, | |
thunk32_vkGetDeviceImageMemoryRequirements, | |
thunk32_vkGetDeviceImageMemoryRequirementsKHR, | |
@@ -47872,6 +48157,7 @@ const unixlib_entry_t __wine_unix_call_funcs[] = | |
thunk32_vkGetPhysicalDeviceSurfaceCapabilitiesKHR, | |
thunk32_vkGetPhysicalDeviceSurfaceFormats2KHR, | |
thunk32_vkGetPhysicalDeviceSurfaceFormatsKHR, | |
+ thunk32_vkGetPhysicalDeviceSurfacePresentModes2EXT, | |
thunk32_vkGetPhysicalDeviceSurfacePresentModesKHR, | |
thunk32_vkGetPhysicalDeviceSurfaceSupportKHR, | |
thunk32_vkGetPhysicalDeviceToolProperties, | |
@@ -47922,6 +48208,7 @@ const unixlib_entry_t __wine_unix_call_funcs[] = | |
thunk32_vkQueueSubmit2, | |
thunk32_vkQueueSubmit2KHR, | |
thunk32_vkQueueWaitIdle, | |
+ thunk32_vkReleaseFullScreenExclusiveModeEXT, | |
thunk32_vkReleasePerformanceConfigurationINTEL, | |
thunk32_vkReleaseProfilingLockKHR, | |
thunk32_vkReleaseSwapchainImagesEXT, | |
diff --git a/dlls/winevulkan/vulkan_thunks.h b/dlls/winevulkan/vulkan_thunks.h | |
index 2321bb91c09..47ec3e9ab18 100644 | |
--- a/dlls/winevulkan/vulkan_thunks.h | |
+++ b/dlls/winevulkan/vulkan_thunks.h | |
@@ -70,6 +70,7 @@ VkResult wine_vkUnmapMemory2KHR(VkDevice device, const VkMemoryUnmapInfoKHR *pMe | |
/* For use by vkDevice and children */ | |
struct vulkan_device_funcs | |
{ | |
+ VkResult (*p_vkAcquireFullScreenExclusiveModeEXT)(VkDevice, VkSwapchainKHR); | |
VkResult (*p_vkAcquireNextImage2KHR)(VkDevice, const VkAcquireNextImageInfoKHR *, uint32_t *); | |
VkResult (*p_vkAcquireNextImageKHR)(VkDevice, VkSwapchainKHR, uint64_t, VkSemaphore, VkFence, uint32_t *); | |
VkResult (*p_vkAcquirePerformanceConfigurationINTEL)(VkDevice, const VkPerformanceConfigurationAcquireInfoINTEL *, VkPerformanceConfigurationINTEL *); | |
@@ -464,6 +465,7 @@ struct vulkan_device_funcs | |
void (*p_vkGetDeviceGroupPeerMemoryFeatures)(VkDevice, uint32_t, uint32_t, uint32_t, VkPeerMemoryFeatureFlags *); | |
void (*p_vkGetDeviceGroupPeerMemoryFeaturesKHR)(VkDevice, uint32_t, uint32_t, uint32_t, VkPeerMemoryFeatureFlags *); | |
VkResult (*p_vkGetDeviceGroupPresentCapabilitiesKHR)(VkDevice, VkDeviceGroupPresentCapabilitiesKHR *); | |
+ VkResult (*p_vkGetDeviceGroupSurfacePresentModes2EXT)(VkDevice, const VkPhysicalDeviceSurfaceInfo2KHR *, VkDeviceGroupPresentModeFlagsKHR *); | |
VkResult (*p_vkGetDeviceGroupSurfacePresentModesKHR)(VkDevice, VkSurfaceKHR, VkDeviceGroupPresentModeFlagsKHR *); | |
void (*p_vkGetDeviceImageMemoryRequirements)(VkDevice, const VkDeviceImageMemoryRequirements *, VkMemoryRequirements2 *); | |
void (*p_vkGetDeviceImageMemoryRequirementsKHR)(VkDevice, const VkDeviceImageMemoryRequirements *, VkMemoryRequirements2 *); | |
@@ -544,6 +546,7 @@ struct vulkan_device_funcs | |
VkResult (*p_vkQueueSubmit2)(VkQueue, uint32_t, const VkSubmitInfo2 *, VkFence); | |
VkResult (*p_vkQueueSubmit2KHR)(VkQueue, uint32_t, const VkSubmitInfo2 *, VkFence); | |
VkResult (*p_vkQueueWaitIdle)(VkQueue); | |
+ VkResult (*p_vkReleaseFullScreenExclusiveModeEXT)(VkDevice, VkSwapchainKHR); | |
VkResult (*p_vkReleasePerformanceConfigurationINTEL)(VkDevice, VkPerformanceConfigurationINTEL); | |
void (*p_vkReleaseProfilingLockKHR)(VkDevice); | |
VkResult (*p_vkReleaseSwapchainImagesEXT)(VkDevice, const VkReleaseSwapchainImagesInfoEXT *); | |
@@ -635,6 +638,7 @@ struct vulkan_instance_funcs | |
VkResult (*p_vkGetPhysicalDeviceSurfaceCapabilitiesKHR)(VkPhysicalDevice, VkSurfaceKHR, VkSurfaceCapabilitiesKHR *); | |
VkResult (*p_vkGetPhysicalDeviceSurfaceFormats2KHR)(VkPhysicalDevice, const VkPhysicalDeviceSurfaceInfo2KHR *, uint32_t *, VkSurfaceFormat2KHR *); | |
VkResult (*p_vkGetPhysicalDeviceSurfaceFormatsKHR)(VkPhysicalDevice, VkSurfaceKHR, uint32_t *, VkSurfaceFormatKHR *); | |
+ VkResult (*p_vkGetPhysicalDeviceSurfacePresentModes2EXT)(VkPhysicalDevice, const VkPhysicalDeviceSurfaceInfo2KHR *, uint32_t *, VkPresentModeKHR *); | |
VkResult (*p_vkGetPhysicalDeviceSurfacePresentModesKHR)(VkPhysicalDevice, VkSurfaceKHR, uint32_t *, VkPresentModeKHR *); | |
VkResult (*p_vkGetPhysicalDeviceSurfaceSupportKHR)(VkPhysicalDevice, uint32_t, VkSurfaceKHR, VkBool32 *); | |
VkResult (*p_vkGetPhysicalDeviceToolProperties)(VkPhysicalDevice, uint32_t *, VkPhysicalDeviceToolProperties *); | |
@@ -643,6 +647,7 @@ struct vulkan_instance_funcs | |
}; | |
#define ALL_VK_DEVICE_FUNCS() \ | |
+ USE_VK_FUNC(vkAcquireFullScreenExclusiveModeEXT) \ | |
USE_VK_FUNC(vkAcquireNextImage2KHR) \ | |
USE_VK_FUNC(vkAcquireNextImageKHR) \ | |
USE_VK_FUNC(vkAcquirePerformanceConfigurationINTEL) \ | |
@@ -1037,6 +1042,7 @@ struct vulkan_instance_funcs | |
USE_VK_FUNC(vkGetDeviceGroupPeerMemoryFeatures) \ | |
USE_VK_FUNC(vkGetDeviceGroupPeerMemoryFeaturesKHR) \ | |
USE_VK_FUNC(vkGetDeviceGroupPresentCapabilitiesKHR) \ | |
+ USE_VK_FUNC(vkGetDeviceGroupSurfacePresentModes2EXT) \ | |
USE_VK_FUNC(vkGetDeviceGroupSurfacePresentModesKHR) \ | |
USE_VK_FUNC(vkGetDeviceImageMemoryRequirements) \ | |
USE_VK_FUNC(vkGetDeviceImageMemoryRequirementsKHR) \ | |
@@ -1117,6 +1123,7 @@ struct vulkan_instance_funcs | |
USE_VK_FUNC(vkQueueSubmit2) \ | |
USE_VK_FUNC(vkQueueSubmit2KHR) \ | |
USE_VK_FUNC(vkQueueWaitIdle) \ | |
+ USE_VK_FUNC(vkReleaseFullScreenExclusiveModeEXT) \ | |
USE_VK_FUNC(vkReleasePerformanceConfigurationINTEL) \ | |
USE_VK_FUNC(vkReleaseProfilingLockKHR) \ | |
USE_VK_FUNC(vkReleaseSwapchainImagesEXT) \ | |
@@ -1205,6 +1212,7 @@ struct vulkan_instance_funcs | |
USE_VK_FUNC(vkGetPhysicalDeviceSurfaceCapabilitiesKHR) \ | |
USE_VK_FUNC(vkGetPhysicalDeviceSurfaceFormats2KHR) \ | |
USE_VK_FUNC(vkGetPhysicalDeviceSurfaceFormatsKHR) \ | |
+ USE_VK_FUNC(vkGetPhysicalDeviceSurfacePresentModes2EXT) \ | |
USE_VK_FUNC(vkGetPhysicalDeviceSurfacePresentModesKHR) \ | |
USE_VK_FUNC(vkGetPhysicalDeviceSurfaceSupportKHR) \ | |
USE_VK_FUNC(vkGetPhysicalDeviceToolProperties) \ | |
diff --git a/include/wine/vulkan.h b/include/wine/vulkan.h | |
index 8876b8aa794..bf6855bcee6 100644 | |
--- a/include/wine/vulkan.h | |
+++ b/include/wine/vulkan.h | |
@@ -395,6 +395,8 @@ | |
#define VK_KHR_UNIFORM_BUFFER_STANDARD_LAYOUT_EXTENSION_NAME "VK_KHR_uniform_buffer_standard_layout" | |
#define VK_EXT_PROVOKING_VERTEX_SPEC_VERSION 1 | |
#define VK_EXT_PROVOKING_VERTEX_EXTENSION_NAME "VK_EXT_provoking_vertex" | |
+#define VK_EXT_FULL_SCREEN_EXCLUSIVE_SPEC_VERSION 4 | |
+#define VK_EXT_FULL_SCREEN_EXCLUSIVE_EXTENSION_NAME "VK_EXT_full_screen_exclusive" | |
#define VK_KHR_BUFFER_DEVICE_ADDRESS_SPEC_VERSION 1 | |
#define VK_KHR_BUFFER_DEVICE_ADDRESS_EXTENSION_NAME "VK_KHR_buffer_device_address" | |
#define VK_EXT_LINE_RASTERIZATION_SPEC_VERSION 1 | |
@@ -2595,6 +2597,15 @@ typedef enum VkFrontFace | |
VK_FRONT_FACE_MAX_ENUM = 0x7fffffff, | |
} VkFrontFace; | |
+typedef enum VkFullScreenExclusiveEXT | |
+{ | |
+ VK_FULL_SCREEN_EXCLUSIVE_DEFAULT_EXT = 0, | |
+ VK_FULL_SCREEN_EXCLUSIVE_ALLOWED_EXT = 1, | |
+ VK_FULL_SCREEN_EXCLUSIVE_DISALLOWED_EXT = 2, | |
+ VK_FULL_SCREEN_EXCLUSIVE_APPLICATION_CONTROLLED_EXT = 3, | |
+ VK_FULL_SCREEN_EXCLUSIVE_EXT_MAX_ENUM = 0x7fffffff, | |
+} VkFullScreenExclusiveEXT; | |
+ | |
typedef enum VkGeometryFlagBitsKHR | |
{ | |
VK_GEOMETRY_OPAQUE_BIT_KHR = 0x00000001, | |
@@ -3769,6 +3780,7 @@ typedef enum VkResult | |
{ | |
VK_ERROR_COMPRESSION_EXHAUSTED_EXT = -1000338000, | |
VK_ERROR_INVALID_OPAQUE_CAPTURE_ADDRESS = -1000257000, | |
+ VK_ERROR_FULL_SCREEN_EXCLUSIVE_MODE_LOST_EXT = -1000255000, | |
VK_ERROR_NOT_PERMITTED_KHR = -1000174001, | |
VK_ERROR_FRAGMENTATION = -1000161000, | |
VK_ERROR_INVALID_EXTERNAL_HANDLE = -1000072003, | |
@@ -4443,6 +4455,9 @@ typedef enum VkStructureType | |
VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_PROVOKING_VERTEX_FEATURES_EXT = 1000254000, | |
VK_STRUCTURE_TYPE_PIPELINE_RASTERIZATION_PROVOKING_VERTEX_STATE_CREATE_INFO_EXT = 1000254001, | |
VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_PROVOKING_VERTEX_PROPERTIES_EXT = 1000254002, | |
+ VK_STRUCTURE_TYPE_SURFACE_FULL_SCREEN_EXCLUSIVE_INFO_EXT = 1000255000, | |
+ VK_STRUCTURE_TYPE_SURFACE_FULL_SCREEN_EXCLUSIVE_WIN32_INFO_EXT = 1000255001, | |
+ VK_STRUCTURE_TYPE_SURFACE_CAPABILITIES_FULL_SCREEN_EXCLUSIVE_EXT = 1000255002, | |
VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_BUFFER_DEVICE_ADDRESS_FEATURES = 1000257000, | |
VK_STRUCTURE_TYPE_BUFFER_OPAQUE_CAPTURE_ADDRESS_CREATE_INFO = 1000257002, | |
VK_STRUCTURE_TYPE_MEMORY_OPAQUE_CAPTURE_ADDRESS_ALLOCATE_INFO = 1000257003, | |
@@ -11566,6 +11581,13 @@ typedef struct VkSubresourceLayout2KHR | |
} VkSubresourceLayout2KHR; | |
typedef VkSubresourceLayout2KHR VkSubresourceLayout2EXT; | |
+typedef struct VkSurfaceCapabilitiesFullScreenExclusiveEXT | |
+{ | |
+ VkStructureType sType; | |
+ void *pNext; | |
+ VkBool32 fullScreenExclusiveSupported; | |
+} VkSurfaceCapabilitiesFullScreenExclusiveEXT; | |
+ | |
typedef struct VkSurfaceCapabilitiesKHR | |
{ | |
uint32_t minImageCount; | |
@@ -11593,6 +11615,20 @@ typedef struct VkSurfaceFormatKHR | |
VkColorSpaceKHR colorSpace; | |
} VkSurfaceFormatKHR; | |
+typedef struct VkSurfaceFullScreenExclusiveInfoEXT | |
+{ | |
+ VkStructureType sType; | |
+ void *pNext; | |
+ VkFullScreenExclusiveEXT fullScreenExclusive; | |
+} VkSurfaceFullScreenExclusiveInfoEXT; | |
+ | |
+typedef struct VkSurfaceFullScreenExclusiveWin32InfoEXT | |
+{ | |
+ VkStructureType sType; | |
+ const void *pNext; | |
+ HMONITOR hmonitor; | |
+} VkSurfaceFullScreenExclusiveWin32InfoEXT; | |
+ | |
typedef struct VkSurfacePresentModeCompatibilityEXT | |
{ | |
VkStructureType sType; | |
@@ -13058,6 +13094,7 @@ typedef struct VkGraphicsPipelineShaderGroupsCreateInfoNV | |
const VkPipeline *pPipelines; | |
} VkGraphicsPipelineShaderGroupsCreateInfoNV; | |
+typedef VkResult (VKAPI_PTR *PFN_vkAcquireFullScreenExclusiveModeEXT)(VkDevice, VkSwapchainKHR); | |
typedef VkResult (VKAPI_PTR *PFN_vkAcquireNextImage2KHR)(VkDevice, const VkAcquireNextImageInfoKHR *, uint32_t *); | |
typedef VkResult (VKAPI_PTR *PFN_vkAcquireNextImageKHR)(VkDevice, VkSwapchainKHR, uint64_t, VkSemaphore, VkFence, uint32_t *); | |
typedef VkResult (VKAPI_PTR *PFN_vkAcquirePerformanceConfigurationINTEL)(VkDevice, const VkPerformanceConfigurationAcquireInfoINTEL *, VkPerformanceConfigurationINTEL *); | |
@@ -13471,6 +13508,7 @@ typedef VkResult (VKAPI_PTR *PFN_vkGetDeviceFaultInfoEXT)(VkDevice, VkDeviceFaul | |
typedef void (VKAPI_PTR *PFN_vkGetDeviceGroupPeerMemoryFeatures)(VkDevice, uint32_t, uint32_t, uint32_t, VkPeerMemoryFeatureFlags *); | |
typedef void (VKAPI_PTR *PFN_vkGetDeviceGroupPeerMemoryFeaturesKHR)(VkDevice, uint32_t, uint32_t, uint32_t, VkPeerMemoryFeatureFlags *); | |
typedef VkResult (VKAPI_PTR *PFN_vkGetDeviceGroupPresentCapabilitiesKHR)(VkDevice, VkDeviceGroupPresentCapabilitiesKHR *); | |
+typedef VkResult (VKAPI_PTR *PFN_vkGetDeviceGroupSurfacePresentModes2EXT)(VkDevice, const VkPhysicalDeviceSurfaceInfo2KHR *, VkDeviceGroupPresentModeFlagsKHR *); | |
typedef VkResult (VKAPI_PTR *PFN_vkGetDeviceGroupSurfacePresentModesKHR)(VkDevice, VkSurfaceKHR, VkDeviceGroupPresentModeFlagsKHR *); | |
typedef void (VKAPI_PTR *PFN_vkGetDeviceImageMemoryRequirements)(VkDevice, const VkDeviceImageMemoryRequirements *, VkMemoryRequirements2 *); | |
typedef void (VKAPI_PTR *PFN_vkGetDeviceImageMemoryRequirementsKHR)(VkDevice, const VkDeviceImageMemoryRequirements *, VkMemoryRequirements2 *); | |
@@ -13551,6 +13589,7 @@ typedef VkResult (VKAPI_PTR *PFN_vkGetPhysicalDeviceSurfaceCapabilities2KHR)(VkP | |
typedef VkResult (VKAPI_PTR *PFN_vkGetPhysicalDeviceSurfaceCapabilitiesKHR)(VkPhysicalDevice, VkSurfaceKHR, VkSurfaceCapabilitiesKHR *); | |
typedef VkResult (VKAPI_PTR *PFN_vkGetPhysicalDeviceSurfaceFormats2KHR)(VkPhysicalDevice, const VkPhysicalDeviceSurfaceInfo2KHR *, uint32_t *, VkSurfaceFormat2KHR *); | |
typedef VkResult (VKAPI_PTR *PFN_vkGetPhysicalDeviceSurfaceFormatsKHR)(VkPhysicalDevice, VkSurfaceKHR, uint32_t *, VkSurfaceFormatKHR *); | |
+typedef VkResult (VKAPI_PTR *PFN_vkGetPhysicalDeviceSurfacePresentModes2EXT)(VkPhysicalDevice, const VkPhysicalDeviceSurfaceInfo2KHR *, uint32_t *, VkPresentModeKHR *); | |
typedef VkResult (VKAPI_PTR *PFN_vkGetPhysicalDeviceSurfacePresentModesKHR)(VkPhysicalDevice, VkSurfaceKHR, uint32_t *, VkPresentModeKHR *); | |
typedef VkResult (VKAPI_PTR *PFN_vkGetPhysicalDeviceSurfaceSupportKHR)(VkPhysicalDevice, uint32_t, VkSurfaceKHR, VkBool32 *); | |
typedef VkResult (VKAPI_PTR *PFN_vkGetPhysicalDeviceToolProperties)(VkPhysicalDevice, uint32_t *, VkPhysicalDeviceToolProperties *); | |
@@ -13601,6 +13640,7 @@ typedef VkResult (VKAPI_PTR *PFN_vkQueueSubmit)(VkQueue, uint32_t, const VkSubmi | |
typedef VkResult (VKAPI_PTR *PFN_vkQueueSubmit2)(VkQueue, uint32_t, const VkSubmitInfo2 *, VkFence); | |
typedef VkResult (VKAPI_PTR *PFN_vkQueueSubmit2KHR)(VkQueue, uint32_t, const VkSubmitInfo2 *, VkFence); | |
typedef VkResult (VKAPI_PTR *PFN_vkQueueWaitIdle)(VkQueue); | |
+typedef VkResult (VKAPI_PTR *PFN_vkReleaseFullScreenExclusiveModeEXT)(VkDevice, VkSwapchainKHR); | |
typedef VkResult (VKAPI_PTR *PFN_vkReleasePerformanceConfigurationINTEL)(VkDevice, VkPerformanceConfigurationINTEL); | |
typedef void (VKAPI_PTR *PFN_vkReleaseProfilingLockKHR)(VkDevice); | |
typedef VkResult (VKAPI_PTR *PFN_vkReleaseSwapchainImagesEXT)(VkDevice, const VkReleaseSwapchainImagesInfoEXT *); | |
@@ -13640,6 +13680,7 @@ typedef VkResult (VKAPI_PTR *PFN_vkWriteAccelerationStructuresPropertiesKHR)(VkD | |
typedef VkResult (VKAPI_PTR *PFN_vkWriteMicromapsPropertiesEXT)(VkDevice, uint32_t, const VkMicromapEXT *, VkQueryType, size_t, void *, size_t); | |
#ifndef VK_NO_PROTOTYPES | |
+VkResult VKAPI_CALL vkAcquireFullScreenExclusiveModeEXT(VkDevice device, VkSwapchainKHR swapchain); | |
VkResult VKAPI_CALL vkAcquireNextImage2KHR(VkDevice device, const VkAcquireNextImageInfoKHR *pAcquireInfo, uint32_t *pImageIndex); | |
VkResult VKAPI_CALL vkAcquireNextImageKHR(VkDevice device, VkSwapchainKHR swapchain, uint64_t timeout, VkSemaphore semaphore, VkFence fence, uint32_t *pImageIndex); | |
VkResult VKAPI_CALL vkAcquirePerformanceConfigurationINTEL(VkDevice device, const VkPerformanceConfigurationAcquireInfoINTEL *pAcquireInfo, VkPerformanceConfigurationINTEL *pConfiguration); | |
@@ -14053,6 +14094,7 @@ VkResult VKAPI_CALL vkGetDeviceFaultInfoEXT(VkDevice device, VkDeviceFaultCounts | |
void VKAPI_CALL vkGetDeviceGroupPeerMemoryFeatures(VkDevice device, uint32_t heapIndex, uint32_t localDeviceIndex, uint32_t remoteDeviceIndex, VkPeerMemoryFeatureFlags *pPeerMemoryFeatures); | |
void VKAPI_CALL vkGetDeviceGroupPeerMemoryFeaturesKHR(VkDevice device, uint32_t heapIndex, uint32_t localDeviceIndex, uint32_t remoteDeviceIndex, VkPeerMemoryFeatureFlags *pPeerMemoryFeatures); | |
VkResult VKAPI_CALL vkGetDeviceGroupPresentCapabilitiesKHR(VkDevice device, VkDeviceGroupPresentCapabilitiesKHR *pDeviceGroupPresentCapabilities); | |
+VkResult VKAPI_CALL vkGetDeviceGroupSurfacePresentModes2EXT(VkDevice device, const VkPhysicalDeviceSurfaceInfo2KHR *pSurfaceInfo, VkDeviceGroupPresentModeFlagsKHR *pModes); | |
VkResult VKAPI_CALL vkGetDeviceGroupSurfacePresentModesKHR(VkDevice device, VkSurfaceKHR surface, VkDeviceGroupPresentModeFlagsKHR *pModes); | |
void VKAPI_CALL vkGetDeviceImageMemoryRequirements(VkDevice device, const VkDeviceImageMemoryRequirements *pInfo, VkMemoryRequirements2 *pMemoryRequirements); | |
void VKAPI_CALL vkGetDeviceImageMemoryRequirementsKHR(VkDevice device, const VkDeviceImageMemoryRequirements *pInfo, VkMemoryRequirements2 *pMemoryRequirements); | |
@@ -14133,6 +14175,7 @@ VkResult VKAPI_CALL vkGetPhysicalDeviceSurfaceCapabilities2KHR(VkPhysicalDevice | |
VkResult VKAPI_CALL vkGetPhysicalDeviceSurfaceCapabilitiesKHR(VkPhysicalDevice physicalDevice, VkSurfaceKHR surface, VkSurfaceCapabilitiesKHR *pSurfaceCapabilities); | |
VkResult VKAPI_CALL vkGetPhysicalDeviceSurfaceFormats2KHR(VkPhysicalDevice physicalDevice, const VkPhysicalDeviceSurfaceInfo2KHR *pSurfaceInfo, uint32_t *pSurfaceFormatCount, VkSurfaceFormat2KHR *pSurfaceFormats); | |
VkResult VKAPI_CALL vkGetPhysicalDeviceSurfaceFormatsKHR(VkPhysicalDevice physicalDevice, VkSurfaceKHR surface, uint32_t *pSurfaceFormatCount, VkSurfaceFormatKHR *pSurfaceFormats); | |
+VkResult VKAPI_CALL vkGetPhysicalDeviceSurfacePresentModes2EXT(VkPhysicalDevice physicalDevice, const VkPhysicalDeviceSurfaceInfo2KHR *pSurfaceInfo, uint32_t *pPresentModeCount, VkPresentModeKHR *pPresentModes); | |
VkResult VKAPI_CALL vkGetPhysicalDeviceSurfacePresentModesKHR(VkPhysicalDevice physicalDevice, VkSurfaceKHR surface, uint32_t *pPresentModeCount, VkPresentModeKHR *pPresentModes); | |
VkResult VKAPI_CALL vkGetPhysicalDeviceSurfaceSupportKHR(VkPhysicalDevice physicalDevice, uint32_t queueFamilyIndex, VkSurfaceKHR surface, VkBool32 *pSupported); | |
VkResult VKAPI_CALL vkGetPhysicalDeviceToolProperties(VkPhysicalDevice physicalDevice, uint32_t *pToolCount, VkPhysicalDeviceToolProperties *pToolProperties); | |
@@ -14183,6 +14226,7 @@ VkResult VKAPI_CALL vkQueueSubmit(VkQueue queue, uint32_t submitCount, const VkS | |
VkResult VKAPI_CALL vkQueueSubmit2(VkQueue queue, uint32_t submitCount, const VkSubmitInfo2 *pSubmits, VkFence fence); | |
VkResult VKAPI_CALL vkQueueSubmit2KHR(VkQueue queue, uint32_t submitCount, const VkSubmitInfo2 *pSubmits, VkFence fence); | |
VkResult VKAPI_CALL vkQueueWaitIdle(VkQueue queue); | |
+VkResult VKAPI_CALL vkReleaseFullScreenExclusiveModeEXT(VkDevice device, VkSwapchainKHR swapchain); | |
VkResult VKAPI_CALL vkReleasePerformanceConfigurationINTEL(VkDevice device, VkPerformanceConfigurationINTEL configuration); | |
void VKAPI_CALL vkReleaseProfilingLockKHR(VkDevice device); | |
VkResult VKAPI_CALL vkReleaseSwapchainImagesEXT(VkDevice device, const VkReleaseSwapchainImagesInfoEXT *pReleaseInfo); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment