aboutsummaryrefslogtreecommitdiffstats
path: root/src/x11_vulkan.c
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2020-11-21 17:48:19 +0100
committerDavid Robillard <d@drobilla.net>2020-11-25 14:18:04 +0100
commit3e9a2e01da169007b6fc16492f812055645f6d5f (patch)
treee761ca334ee9b0e3bd91b3a6f83ab1373dd7aa7f /src/x11_vulkan.c
parent6426b03476fb91efbd90acd599472010f5474390 (diff)
downloadpugl-3e9a2e01da169007b6fc16492f812055645f6d5f.tar.gz
pugl-3e9a2e01da169007b6fc16492f812055645f6d5f.tar.bz2
pugl-3e9a2e01da169007b6fc16492f812055645f6d5f.zip
Pass vkGetInstanceProcAddr to puglCreateSurface instead of a loader
This allows puglCreateSurface() to be used with some other loader, or when linking to Vulkan at compile time.
Diffstat (limited to 'src/x11_vulkan.c')
-rw-r--r--src/x11_vulkan.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/x11_vulkan.c b/src/x11_vulkan.c
index 7004fd8..c7ae1b0 100644
--- a/src/x11_vulkan.c
+++ b/src/x11_vulkan.c
@@ -110,7 +110,7 @@ puglGetInstanceExtensions(uint32_t* const count)
}
VkResult
-puglCreateSurface(const PuglVulkanLoader* const loader,
+puglCreateSurface(PFN_vkGetInstanceProcAddr vkGetInstanceProcAddr,
PuglView* const view,
VkInstance instance,
const VkAllocationCallbacks* const allocator,
@@ -120,8 +120,8 @@ puglCreateSurface(const PuglVulkanLoader* const loader,
PuglWorldInternals* world_impl = view->world->impl;
PFN_vkCreateXlibSurfaceKHR vkCreateXlibSurfaceKHR =
- (PFN_vkCreateXlibSurfaceKHR)puglGetInstanceProcAddrFunc(loader)(
- instance, "vkCreateXlibSurfaceKHR");
+ (PFN_vkCreateXlibSurfaceKHR)
+ vkGetInstanceProcAddr(instance, "vkCreateXlibSurfaceKHR");
const VkXlibSurfaceCreateInfoKHR info = {
VK_STRUCTURE_TYPE_XLIB_SURFACE_CREATE_INFO_KHR,