Vulkan in Qt on macOS?
-
Re: macos:: can't find QVulkanInstance
I'm trying to work my way through the standard Vulkan-in-Qt examples in Qt Creator's Welcome mode: Hello Vulkan Window, Hello Vulkan Triangle, etc. They fail to build, giving the same error messages as in the unanswered thread linked above: "unknown class name QVulkanWindowRenderer", etc. Any advice?
Searching the Web yields answers about editing .pro files (these examples have none), about Qt 5 (which might be out of date), etc.
Sorry if this is a newbie question. I am new to Qt. (I'm trying to evaluate it for a new project I'm starting.) I've been programming Vulkan for a year using non-Qt APIs. I can build various non-Vulkan Qt examples.
macOS Monterey 12.6.3
Qt 6, Qt Creator 9.0.1
LunarG Vulkan SDK, Vulkan 1.3.204.1, moltenVK -
macOS does not support Vulkan (out of the box). As you know you need MoltenVK for that. I expect that the pre-compiled Qt libraries are not compiled with Vulkan support (because MoltenVK is not available by default). In this case you'd need to compile Qt yourself together with Vulkan support enabled.