Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HLSL Vertex and Fragment Semantics Order Seems to Need to Match #5553

Closed
cwfitzgerald opened this issue Aug 10, 2021 · 0 comments · Fixed by gfx-rs/naga#1189
Closed

HLSL Vertex and Fragment Semantics Order Seems to Need to Match #5553

cwfitzgerald opened this issue Aug 10, 2021 · 0 comments · Fixed by gfx-rs/naga#1189
Labels
lang: HLSL D3D Shading Language

Comments

@cwfitzgerald
Copy link
Member

cwfitzgerald commented Aug 10, 2021

From what I can tell, HLSL semantics needs to have the same order in the output struct as the input struct.

When compiling the following spirv with wgpu (with gfx-rs/naga#1179), I get the following error

spirv.zip

D3D12 ERROR: ID3D12Device::CreateGraphicsPipelineState: Vertex Shader - Pixel Shader linkage error: Signatures between stages are incompatible. Semantic 'LOC' is defined for mismatched hardware registers between the output stage and input stage. [ STATE_CREATION ERROR gfx-rs/naga#660: CREATEGRAPHICSPIPELINESTATE_SHADER_LINKAGE_REGISTERINDEX]

From googling the error it appears that they have to be in the same order, but it's hard to prove that it is truly the solution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lang: HLSL D3D Shading Language
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant