Commit f7bff880 authored by Rémi Bernon's avatar Rémi Bernon Committed by Alexandre Julliard

winevulkan: Remove now unnecessary vkGetPhysicalDeviceSurfaceFormatsKHR driver entry.

parent 8a984080
......@@ -86,7 +86,6 @@ static VkResult (*pvkEnumerateInstanceExtensionProperties)(const char *, uint32_
static void * (*pvkGetDeviceProcAddr)(VkDevice, const char *);
static void * (*pvkGetInstanceProcAddr)(VkInstance, const char *);
static VkResult (*pvkGetPhysicalDeviceSurfaceCapabilities2KHR)(VkPhysicalDevice, const VkPhysicalDeviceSurfaceInfo2KHR *, VkSurfaceCapabilities2KHR *);
static VkResult (*pvkGetPhysicalDeviceSurfaceFormatsKHR)(VkPhysicalDevice, VkSurfaceKHR, uint32_t *, VkSurfaceFormatKHR *);
static VkResult (*pvkGetSwapchainImagesKHR)(VkDevice, VkSwapchainKHR, uint32_t *, VkImage *);
static VkResult (*pvkQueuePresentKHR)(VkQueue, const VkPresentInfoKHR *);
......@@ -119,7 +118,6 @@ static void wine_vk_init(void)
LOAD_FUNCPTR(vkEnumerateInstanceExtensionProperties)
LOAD_FUNCPTR(vkGetDeviceProcAddr)
LOAD_FUNCPTR(vkGetInstanceProcAddr)
LOAD_FUNCPTR(vkGetPhysicalDeviceSurfaceFormatsKHR)
LOAD_FUNCPTR(vkGetSwapchainImagesKHR)
LOAD_FUNCPTR(vkQueuePresentKHR)
#undef LOAD_FUNCPTR
......@@ -457,17 +455,6 @@ static void *macdrv_vkGetInstanceProcAddr(VkInstance instance, const char *name)
return pvkGetInstanceProcAddr(instance, name);
}
static VkResult macdrv_vkGetPhysicalDeviceSurfaceFormatsKHR(VkPhysicalDevice phys_dev,
VkSurfaceKHR surface, uint32_t *count, VkSurfaceFormatKHR *formats)
{
struct wine_vk_surface *mac_surface = surface_from_handle(surface);
TRACE("%p, 0x%s, %p, %p\n", phys_dev, wine_dbgstr_longlong(surface), count, formats);
return pvkGetPhysicalDeviceSurfaceFormatsKHR(phys_dev, mac_surface->host_surface,
count, formats);
}
static VkBool32 macdrv_vkGetPhysicalDeviceWin32PresentationSupportKHR(VkPhysicalDevice phys_dev,
uint32_t index)
{
......@@ -532,7 +519,6 @@ static const struct vulkan_funcs vulkan_funcs =
macdrv_vkEnumerateInstanceExtensionProperties,
macdrv_vkGetDeviceProcAddr,
macdrv_vkGetInstanceProcAddr,
macdrv_vkGetPhysicalDeviceSurfaceFormatsKHR,
macdrv_vkGetPhysicalDeviceWin32PresentationSupportKHR,
macdrv_vkGetSwapchainImagesKHR,
macdrv_vkQueuePresentKHR,
......
......@@ -160,7 +160,7 @@ PERF_CRITICAL_FUNCTIONS = [
# Functions part of our winevulkan graphics driver interface.
# DRIVER_VERSION should be bumped on any change to driver interface
# in FUNCTION_OVERRIDES
DRIVER_VERSION = 18
DRIVER_VERSION = 19
# Table of functions for which we have a special implementation.
# These are regular device / instance functions for which we need
......@@ -203,7 +203,6 @@ USER_DRIVER_FUNCS = {
"vkEnumerateInstanceExtensionProperties",
"vkGetDeviceProcAddr",
"vkGetInstanceProcAddr",
"vkGetPhysicalDeviceSurfaceFormatsKHR",
"vkGetPhysicalDeviceWin32PresentationSupportKHR",
"vkGetSwapchainImagesKHR",
"vkQueuePresentKHR",
......
......@@ -1946,7 +1946,7 @@ VkResult wine_vkGetPhysicalDeviceSurfaceFormatsKHR(VkPhysicalDevice device_handl
struct wine_surface *surface = wine_surface_from_handle(surface_handle);
struct wine_instance *instance = physical_device->instance;
return instance->funcs.p_vkGetPhysicalDeviceSurfaceFormatsKHR(physical_device->host_physical_device, surface->driver_surface,
return instance->funcs.p_vkGetPhysicalDeviceSurfaceFormatsKHR(physical_device->host_physical_device, surface->host_surface,
format_count, formats);
}
......
......@@ -43512,7 +43512,7 @@ static NTSTATUS thunk64_vkGetPhysicalDeviceSurfaceFormatsKHR(void *args)
TRACE("%p, 0x%s, %p, %p\n", params->physicalDevice, wine_dbgstr_longlong(params->surface), params->pSurfaceFormatCount, params->pSurfaceFormats);
params->result = wine_phys_dev_from_handle(params->physicalDevice)->instance->funcs.p_vkGetPhysicalDeviceSurfaceFormatsKHR(wine_phys_dev_from_handle(params->physicalDevice)->host_physical_device, params->surface ? wine_surface_from_handle(params->surface)->driver_surface : 0, params->pSurfaceFormatCount, params->pSurfaceFormats);
params->result = wine_phys_dev_from_handle(params->physicalDevice)->instance->funcs.p_vkGetPhysicalDeviceSurfaceFormatsKHR(wine_phys_dev_from_handle(params->physicalDevice)->host_physical_device, params->surface ? wine_surface_from_handle(params->surface)->host_surface : 0, params->pSurfaceFormatCount, params->pSurfaceFormats);
return STATUS_SUCCESS;
}
#endif /* _WIN64 */
......@@ -43530,7 +43530,7 @@ static NTSTATUS thunk32_vkGetPhysicalDeviceSurfaceFormatsKHR(void *args)
TRACE("%#x, 0x%s, %#x, %#x\n", params->physicalDevice, wine_dbgstr_longlong(params->surface), params->pSurfaceFormatCount, params->pSurfaceFormats);
params->result = wine_phys_dev_from_handle((VkPhysicalDevice)UlongToPtr(params->physicalDevice))->instance->funcs.p_vkGetPhysicalDeviceSurfaceFormatsKHR(wine_phys_dev_from_handle((VkPhysicalDevice)UlongToPtr(params->physicalDevice))->host_physical_device, params->surface ? wine_surface_from_handle(params->surface)->driver_surface : 0, (uint32_t *)UlongToPtr(params->pSurfaceFormatCount), (VkSurfaceFormatKHR *)UlongToPtr(params->pSurfaceFormats));
params->result = wine_phys_dev_from_handle((VkPhysicalDevice)UlongToPtr(params->physicalDevice))->instance->funcs.p_vkGetPhysicalDeviceSurfaceFormatsKHR(wine_phys_dev_from_handle((VkPhysicalDevice)UlongToPtr(params->physicalDevice))->host_physical_device, params->surface ? wine_surface_from_handle(params->surface)->host_surface : 0, (uint32_t *)UlongToPtr(params->pSurfaceFormatCount), (VkSurfaceFormatKHR *)UlongToPtr(params->pSurfaceFormats));
return STATUS_SUCCESS;
}
......@@ -60,7 +60,6 @@ static void (*pvkDestroySwapchainKHR)(VkDevice, VkSwapchainKHR, const VkAllocati
static VkResult (*pvkEnumerateInstanceExtensionProperties)(const char *, uint32_t *, VkExtensionProperties *);
static void * (*pvkGetDeviceProcAddr)(VkDevice, const char *);
static void * (*pvkGetInstanceProcAddr)(VkInstance, const char *);
static VkResult (*pvkGetPhysicalDeviceSurfaceFormatsKHR)(VkPhysicalDevice, VkSurfaceKHR, uint32_t *, VkSurfaceFormatKHR *);
static VkBool32 (*pvkGetPhysicalDeviceWaylandPresentationSupportKHR)(VkPhysicalDevice, uint32_t, struct wl_display *);
static VkResult (*pvkGetSwapchainImagesKHR)(VkDevice, VkSwapchainKHR, uint32_t *, VkImage *);
static VkResult (*pvkQueuePresentKHR)(VkQueue, const VkPresentInfoKHR *);
......@@ -533,19 +532,6 @@ static void *wayland_vkGetInstanceProcAddr(VkInstance instance, const char *name
return pvkGetInstanceProcAddr(instance, name);
}
static VkResult wayland_vkGetPhysicalDeviceSurfaceFormatsKHR(VkPhysicalDevice phys_dev,
VkSurfaceKHR surface,
uint32_t *count,
VkSurfaceFormatKHR *formats)
{
struct wine_vk_surface *wine_vk_surface = wine_vk_surface_from_handle(surface);
TRACE("%p, 0x%s, %p, %p\n", phys_dev, wine_dbgstr_longlong(surface), count, formats);
return pvkGetPhysicalDeviceSurfaceFormatsKHR(phys_dev, wine_vk_surface->host_surface,
count, formats);
}
static VkBool32 wayland_vkGetPhysicalDeviceWin32PresentationSupportKHR(VkPhysicalDevice phys_dev,
uint32_t index)
{
......@@ -598,7 +584,6 @@ static void wine_vk_init(void)
LOAD_FUNCPTR(vkEnumerateInstanceExtensionProperties);
LOAD_FUNCPTR(vkGetDeviceProcAddr);
LOAD_FUNCPTR(vkGetInstanceProcAddr);
LOAD_FUNCPTR(vkGetPhysicalDeviceSurfaceFormatsKHR);
LOAD_FUNCPTR(vkGetPhysicalDeviceWaylandPresentationSupportKHR);
LOAD_FUNCPTR(vkGetSwapchainImagesKHR);
LOAD_FUNCPTR(vkQueuePresentKHR);
......@@ -623,7 +608,6 @@ static const struct vulkan_funcs vulkan_funcs =
.p_vkEnumerateInstanceExtensionProperties = wayland_vkEnumerateInstanceExtensionProperties,
.p_vkGetDeviceProcAddr = wayland_vkGetDeviceProcAddr,
.p_vkGetInstanceProcAddr = wayland_vkGetInstanceProcAddr,
.p_vkGetPhysicalDeviceSurfaceFormatsKHR = wayland_vkGetPhysicalDeviceSurfaceFormatsKHR,
.p_vkGetPhysicalDeviceWin32PresentationSupportKHR = wayland_vkGetPhysicalDeviceWin32PresentationSupportKHR,
.p_vkGetSwapchainImagesKHR = wayland_vkGetSwapchainImagesKHR,
.p_vkQueuePresentKHR = wayland_vkQueuePresentKHR,
......
......@@ -83,7 +83,6 @@ static void (*pvkDestroySwapchainKHR)(VkDevice, VkSwapchainKHR, const VkAllocati
static VkResult (*pvkEnumerateInstanceExtensionProperties)(const char *, uint32_t *, VkExtensionProperties *);
static void * (*pvkGetDeviceProcAddr)(VkDevice, const char *);
static void * (*pvkGetInstanceProcAddr)(VkInstance, const char *);
static VkResult (*pvkGetPhysicalDeviceSurfaceFormatsKHR)(VkPhysicalDevice, VkSurfaceKHR, uint32_t *, VkSurfaceFormatKHR *);
static VkBool32 (*pvkGetPhysicalDeviceXlibPresentationSupportKHR)(VkPhysicalDevice, uint32_t, Display *, VisualID);
static VkResult (*pvkGetSwapchainImagesKHR)(VkDevice, VkSwapchainKHR, uint32_t *, VkImage *);
static VkResult (*pvkQueuePresentKHR)(VkQueue, const VkPresentInfoKHR *);
......@@ -119,7 +118,6 @@ static void wine_vk_init(void)
LOAD_FUNCPTR(vkEnumerateInstanceExtensionProperties);
LOAD_FUNCPTR(vkGetDeviceProcAddr);
LOAD_FUNCPTR(vkGetInstanceProcAddr);
LOAD_FUNCPTR(vkGetPhysicalDeviceSurfaceFormatsKHR);
LOAD_FUNCPTR(vkGetPhysicalDeviceXlibPresentationSupportKHR);
LOAD_FUNCPTR(vkGetSwapchainImagesKHR);
LOAD_FUNCPTR(vkQueuePresentKHR);
......@@ -473,16 +471,6 @@ static void *X11DRV_vkGetInstanceProcAddr(VkInstance instance, const char *name)
return pvkGetInstanceProcAddr(instance, name);
}
static VkResult X11DRV_vkGetPhysicalDeviceSurfaceFormatsKHR(VkPhysicalDevice phys_dev,
VkSurfaceKHR surface, uint32_t *count, VkSurfaceFormatKHR *formats)
{
struct wine_vk_surface *x11_surface = surface_from_handle(surface);
TRACE("%p, 0x%s, %p, %p\n", phys_dev, wine_dbgstr_longlong(surface), count, formats);
return pvkGetPhysicalDeviceSurfaceFormatsKHR( phys_dev, x11_surface->host_surface, count, formats );
}
static VkBool32 X11DRV_vkGetPhysicalDeviceWin32PresentationSupportKHR(VkPhysicalDevice phys_dev,
uint32_t index)
{
......@@ -551,7 +539,6 @@ static const struct vulkan_funcs vulkan_funcs =
X11DRV_vkEnumerateInstanceExtensionProperties,
X11DRV_vkGetDeviceProcAddr,
X11DRV_vkGetInstanceProcAddr,
X11DRV_vkGetPhysicalDeviceSurfaceFormatsKHR,
X11DRV_vkGetPhysicalDeviceWin32PresentationSupportKHR,
X11DRV_vkGetSwapchainImagesKHR,
X11DRV_vkQueuePresentKHR,
......
......@@ -13,7 +13,7 @@
#define __WINE_VULKAN_DRIVER_H
/* Wine internal vulkan driver version, needs to be bumped upon vulkan_funcs changes. */
#define WINE_VULKAN_DRIVER_VERSION 18
#define WINE_VULKAN_DRIVER_VERSION 19
struct vulkan_funcs
{
......@@ -30,7 +30,6 @@ struct vulkan_funcs
VkResult (*p_vkEnumerateInstanceExtensionProperties)(const char *, uint32_t *, VkExtensionProperties *);
void * (*p_vkGetDeviceProcAddr)(VkDevice, const char *);
void * (*p_vkGetInstanceProcAddr)(VkInstance, const char *);
VkResult (*p_vkGetPhysicalDeviceSurfaceFormatsKHR)(VkPhysicalDevice, VkSurfaceKHR, uint32_t *, VkSurfaceFormatKHR *);
VkBool32 (*p_vkGetPhysicalDeviceWin32PresentationSupportKHR)(VkPhysicalDevice, uint32_t);
VkResult (*p_vkGetSwapchainImagesKHR)(VkDevice, VkSwapchainKHR, uint32_t *, VkImage *);
VkResult (*p_vkQueuePresentKHR)(VkQueue, const VkPresentInfoKHR *);
......@@ -82,8 +81,6 @@ static inline void *get_vulkan_driver_instance_proc_addr(
return vulkan_funcs->p_vkDestroySurfaceKHR;
if (!strcmp(name, "GetInstanceProcAddr"))
return vulkan_funcs->p_vkGetInstanceProcAddr;
if (!strcmp(name, "GetPhysicalDeviceSurfaceFormatsKHR"))
return vulkan_funcs->p_vkGetPhysicalDeviceSurfaceFormatsKHR;
if (!strcmp(name, "GetPhysicalDeviceWin32PresentationSupportKHR"))
return vulkan_funcs->p_vkGetPhysicalDeviceWin32PresentationSupportKHR;
......
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