-
Notifications
You must be signed in to change notification settings - Fork 85
Open
Labels
bugSomething isn't workingSomething isn't working
Description
PR #482 broke location assignment for tesselation, geometry and mesh shaders.
Specifically, it broke the following rules in 16.1.3. Interface Matching, which all have a quite similar pattern:
- if the input is declared in a tessellation control or geometry shader as an OpTypeArray with an Element Type equivalent to the OpType* declaration of the output, and neither is a structure member
- if the output is declared in a mesh shader as an OpTypeArray with an Element Type equivalent to the OpType* declaration of the input, and neither is a structure member
- if the input is decorated with PerVertexKHR, and is declared in a fragment shader as an OpTypeArray with an Element Type equivalent to the OpType* declaration of the output, and neither the input nor the output is a structure member
TLDR: Their output must be a spirv array (sized or unsized aka. rust slice). This "outer layer" must be ignored in terms of location assignment and only it's element type considered for location size, as all of these shaders expand from one element to many elements, and each element in the array is being sent to their respective output element.
Workaround: manual location assignment with #[spirv(location = 123)]
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working