From 93b8f68b2e9ddc450ce63f1b6e1806960312d803 Mon Sep 17 00:00:00 2001 From: skallweitNV <64953474+skallweitNV@users.noreply.github.com> Date: Tue, 19 Dec 2023 00:16:14 +0100 Subject: macos/vulkan support (#3418) --- tools/gfx/vulkan/vk-module.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'tools/gfx/vulkan/vk-module.cpp') diff --git a/tools/gfx/vulkan/vk-module.cpp b/tools/gfx/vulkan/vk-module.cpp index cff75569e..0e4df8e7f 100644 --- a/tools/gfx/vulkan/vk-module.cpp +++ b/tools/gfx/vulkan/vk-module.cpp @@ -32,6 +32,9 @@ Slang::Result VulkanModule::init(bool useSoftwareImpl) dynamicLibraryName = useSoftwareImpl ? "vk_swiftshader.dll" : "vulkan-1.dll"; HMODULE module = ::LoadLibraryA(dynamicLibraryName); m_module = (void*)module; +#elif SLANG_APPLE_FAMILY + dynamicLibraryName = useSoftwareImpl ? "libvk_swiftshader.dylib" : "libvulkan.1.dylib"; + m_module = dlopen(dynamicLibraryName, RTLD_NOW | RTLD_GLOBAL); #else dynamicLibraryName = useSoftwareImpl ? "libvk_swiftshader.so" : "libvulkan.so.1"; if (useSoftwareImpl) -- cgit v1.2.3