HLSL: Flatten a return struct from an entry point and assign locations after flattening.
Locations now get assigned in order, but skipping built-ins, which can be done post flattening.
This commit is contained in:
parent
7f702124ec
commit
7dc630f3da
93 changed files with 951 additions and 495 deletions
|
|
@ -141,7 +141,7 @@ gl_FragCoord origin is upper left
|
|||
0:41 1.000000
|
||||
0:43 Sequence
|
||||
0:43 move second child to first child (temp structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
0:? '@entryPointOutput' (layout(location=0 ) out structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
0:? '@entryPointOutput' (out structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
0:43 'psout' (temp structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
0:43 Branch: Return
|
||||
0:? Linker Objects
|
||||
|
|
@ -156,7 +156,8 @@ gl_FragCoord origin is upper left
|
|||
0:? 'g_tTexcdf4a' (uniform textureCubeArray)
|
||||
0:? 'g_tTexcdi4a' (uniform itextureCubeArray)
|
||||
0:? 'g_tTexcdu4a' (uniform utextureCubeArray)
|
||||
0:? '@entryPointOutput' (out structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
0:? 'Color' (layout(location=0 ) out 4-component vector of float)
|
||||
0:? 'Depth' (out float FragDepth)
|
||||
|
||||
|
||||
Linked fragment stage:
|
||||
|
|
@ -304,7 +305,7 @@ gl_FragCoord origin is upper left
|
|||
0:41 1.000000
|
||||
0:43 Sequence
|
||||
0:43 move second child to first child (temp structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
0:? '@entryPointOutput' (layout(location=0 ) out structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
0:? '@entryPointOutput' (out structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
0:43 'psout' (temp structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
0:43 Branch: Return
|
||||
0:? Linker Objects
|
||||
|
|
@ -319,11 +320,12 @@ gl_FragCoord origin is upper left
|
|||
0:? 'g_tTexcdf4a' (uniform textureCubeArray)
|
||||
0:? 'g_tTexcdi4a' (uniform itextureCubeArray)
|
||||
0:? 'g_tTexcdu4a' (uniform utextureCubeArray)
|
||||
0:? '@entryPointOutput' (out structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
0:? 'Color' (layout(location=0 ) out 4-component vector of float)
|
||||
0:? 'Depth' (out float FragDepth)
|
||||
|
||||
// Module Version 10000
|
||||
// Generated by (magic number): 80001
|
||||
// Id's are bound by 145
|
||||
// Id's are bound by 149
|
||||
|
||||
Capability Shader
|
||||
Capability Sampled1D
|
||||
|
|
@ -331,7 +333,7 @@ gl_FragCoord origin is upper left
|
|||
Capability ImageQuery
|
||||
1: ExtInstImport "GLSL.std.450"
|
||||
MemoryModel Logical GLSL450
|
||||
EntryPoint Fragment 4 "main" 141
|
||||
EntryPoint Fragment 4 "main" 141 146 148
|
||||
ExecutionMode 4 OriginUpperLeft
|
||||
Name 4 "main"
|
||||
Name 8 "txval10"
|
||||
|
|
@ -359,6 +361,8 @@ gl_FragCoord origin is upper left
|
|||
Name 133 "psout"
|
||||
Name 141 "@entryPointOutput"
|
||||
Name 144 "g_tTex1df4"
|
||||
Name 146 "Color"
|
||||
Name 148 "Depth"
|
||||
Decorate 11(g_tTex1df4a) DescriptorSet 0
|
||||
Decorate 11(g_tTex1df4a) Binding 1
|
||||
Decorate 15(g_sSamp) DescriptorSet 0
|
||||
|
|
@ -372,9 +376,10 @@ gl_FragCoord origin is upper left
|
|||
Decorate 106(g_tTexcdi4a) DescriptorSet 0
|
||||
Decorate 118(g_tTexcdu4a) DescriptorSet 0
|
||||
MemberDecorate 131(PS_OUTPUT) 1 BuiltIn FragDepth
|
||||
Decorate 141(@entryPointOutput) Location 0
|
||||
Decorate 144(g_tTex1df4) DescriptorSet 0
|
||||
Decorate 144(g_tTex1df4) Binding 0
|
||||
Decorate 146(Color) Location 0
|
||||
Decorate 148(Depth) BuiltIn FragDepth
|
||||
2: TypeVoid
|
||||
3: TypeFunction 2
|
||||
6: TypeFloat 32
|
||||
|
|
@ -448,6 +453,10 @@ gl_FragCoord origin is upper left
|
|||
140: TypePointer Output 131(PS_OUTPUT)
|
||||
141(@entryPointOutput): 140(ptr) Variable Output
|
||||
144(g_tTex1df4): 10(ptr) Variable UniformConstant
|
||||
145: TypePointer Output 130(fvec4)
|
||||
146(Color): 145(ptr) Variable Output
|
||||
147: TypePointer Output 6(float)
|
||||
148(Depth): 147(ptr) Variable Output
|
||||
4(main): 2 Function None 3
|
||||
5: Label
|
||||
8(txval10): 7(ptr) Variable Function
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue