The HLSL generator names its "varying" data structures in the order the shaders come in. If the nsl shaders are not in the "right" graphics pipeline stage order, This could lead to problems.
So we need to sort the shader types before naming the structs.
For example, passing data from the vertex shader on to the pixel shader should look like this
The geometry shader looks a little bit different, but the process should be similar there. The HLSL geometry shader code generation does not produce the correct struct name so this is required anyway.
Similar actions had been taken for the GLSL generator here #330 which is mainly for #327.
The HLSL generator names its "varying" data structures in the order the shaders come in. If the nsl shaders are not in the "right" graphics pipeline stage order, This could lead to problems.
So we need to sort the shader types before naming the structs.
For example, passing data from the vertex shader on to the pixel shader should look like this
The geometry shader looks a little bit different, but the process should be similar there. The HLSL geometry shader code generation does not produce the correct struct name so this is required anyway.
Similar actions had been taken for the GLSL generator here #330 which is mainly for #327.