mirror of
https://github.com/KhronosGroup/SPIRV-Cross.git
synced 2024-11-15 08:20:07 +00:00
cb35934248
Vulkan has two types of buffer descriptors, `VK_DESCRIPTOR_TYPE_UNIFORM_BUFFER_DYNAMIC` and `VK_DESCRIPTOR_TYPE_STORAGE_BUFFER_DYNAMIC`, which allow the client to offset the buffers by an amount given when the descriptor set is bound to a pipeline. Metal provides no direct support for this when the buffer in question is in an argument buffer, so once again we're on our own. These offsets cannot be stored or associated in any way with the argument buffer itself, because they are set at bind time. Different pipelines may have different offsets set. Therefore, we must use a separate buffer, not in any argument buffer, to hold these offsets. Then the shader must manually offset the buffer pointer. This change fully supports arrays, including arrays of arrays, even though Vulkan forbids them. It does not, however, support runtime arrays. Perhaps later. |
||
---|---|---|
.. | ||
opt | ||
shaders | ||
shaders-hlsl | ||
shaders-hlsl-no-opt | ||
shaders-msl | ||
shaders-msl-no-opt | ||
shaders-no-opt | ||
shaders-reflection |