Skip to main content

Module bindless

Module bindless 

Source
Expand description

The bindless texture pool’s capacity, shared by every backend that declares the pool as a fixed-size array.

Metal has always sized its pool this way (BINDLESS_TEXTURE_COUNT), and DirectX declares an unbounded array so it needs no ceiling at all. Vulkan used to size the pool to each world’s texture table, which made the shader’s POOL_SIZE a property of the world rather than of the build – and a shader whose text depends on the world cannot be compiled ahead of that world. This constant is what lets the Vulkan programs be compiled at build time like every other one.

A device that cannot seat the ceiling falls back to sizing the pool to the world, exactly as before. That shader text then differs from the one the build script compiled, so the precompiled artifact simply does not match and the renderer compiles – which is the same content check that governs every other artifact, with no special case for it.

Constants§

BINDLESS_POOL_SIZE
Slots in the bindless texture pool. The shader’s POOL_SIZE define is injected from this value, so the array and the descriptor binding cannot drift.