-
-
Notifications
You must be signed in to change notification settings - Fork 9.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add option to provide custom header file with vulkan function prototypes #6582
Conversation
Hello, What is the reason for also adding all those checks next to the VK_NO_PROTOTYPES checks? |
This was written with Volk in mind which does define The proposed solution in issue #4854 where you load the function pointers separately for ImGui would also work and maybe it's not a big deal to have to do that if you want to have a custom loader. However given that Volk currently ships with the Vulkan SDK I think it's reasonable to include this simpler alternative which only requires 1 define from the usage code pointing to the Volk header file or some other custom loader. |
Thank you for the clarification. I have installed volk and toying with it now. Basically what I am not liking is to assume that Given that everyone who posted in those thread are using Volk, I am tempted instead to add a define explicitly named after VOLK, and if other cases manifests we can later consider to introduce a more generic version. |
I have pushed b720c0f which adds support for Thanks for your help! |
With the addition of VOLK this can be easily achieved. You can actually use custom vulkan headers with VOLK, without touching ImGui sources. Volk has a compile time define
|
When using a custom Vulkan function loader the current solution can cause symbol conflicts and runtime errors as discussed in issue #4854. This adds an option to replace the Vulkan header file with a custom header file by defining
IMGUI_IMPL_VULKAN_CUSTOM_HEADER
to resolve these issues.