Quick answer: SPIR-V Cross output declaring all resources in set 0 even when source uses multiple sets? Cross-compiler default; specify --resource-binding to preserve.

HLSL uses register space 0 and 1; cross-compiled GLSL has all in set 0. Pipeline layout mismatches.

Pass resource-binding

spirv-cross --resource-binding set 0 binding 0 ...

Per-resource binding specification. Preserves source layout.

Or post-process

Output SPIR-V; remap descriptor sets via spirv-opt. Lossless transformation.

Verify in pipeline layout

Generated layouts match source intent. Mismatches surface at validation.

“Cross-compilers make choices. The choices need to be explicit.”

If you control your shader pipeline end-to-end, the resource binding spec is project-wide. Document.

Related reading