Closed ib00 closed 2 years ago
sgl at the moment uses SPIRV-Reflect to get different information about the interface of GLSL shaders to make things easier.
Here's an example of how this functionality can be used from the perspective of a user: https://github.com/chrismile/LineVis/blob/vulkan/src/Renderers/HullRasterPass.cpp The shader for this is here: https://github.com/chrismile/LineVis/blob/vulkan/Data/Shaders/Renderers/MeshHull.glsl
Another example using more than one vertex attribute per binding can be found here: https://github.com/chrismile/sgl/blob/master/src/Graphics/Vulkan/Render/Passes/BlitRenderPass.cpp
Beginner's question:
Is there a way to automatically create all descriptor sets and layouts from a precompiled SPIRV shader?
I am finding this one of the most annoying parts of Vulkan -- tedious setup of descriptors.