HLSL: Emulate write-to-output on return-from-entry-point, for return value.
This fixes issue #487 and #480. It also correctly handles output parameters from the entry point.
This commit is contained in:
parent
81cd764b5f
commit
6a70eb7161
91 changed files with 5158 additions and 4130 deletions
|
|
@ -139,8 +139,11 @@ gl_FragCoord origin is upper left
|
|||
0:41 1 (const int)
|
||||
0:41 Constant:
|
||||
0:41 1.000000
|
||||
0:43 Branch: Return with expression
|
||||
0:43 'psout' (temp structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
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' (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
|
||||
0:? 'g_sSamp' (layout(binding=0 ) uniform sampler)
|
||||
0:? 'g_tTex1df4a' (layout(binding=1 ) uniform texture1DArray)
|
||||
|
|
@ -298,8 +301,11 @@ gl_FragCoord origin is upper left
|
|||
0:41 1 (const int)
|
||||
0:41 Constant:
|
||||
0:41 1.000000
|
||||
0:43 Branch: Return with expression
|
||||
0:43 'psout' (temp structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
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' (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
|
||||
0:? 'g_sSamp' (layout(binding=0 ) uniform sampler)
|
||||
0:? 'g_tTex1df4a' (layout(binding=1 ) uniform texture1DArray)
|
||||
|
|
@ -315,7 +321,7 @@ gl_FragCoord origin is upper left
|
|||
|
||||
// Module Version 10000
|
||||
// Generated by (magic number): 80001
|
||||
// Id's are bound by 143
|
||||
// Id's are bound by 145
|
||||
|
||||
Capability Shader
|
||||
Capability Sampled1D
|
||||
|
|
@ -323,7 +329,7 @@ gl_FragCoord origin is upper left
|
|||
Capability ImageQuery
|
||||
1: ExtInstImport "GLSL.std.450"
|
||||
MemoryModel Logical GLSL450
|
||||
EntryPoint Fragment 4 "main"
|
||||
EntryPoint Fragment 4 "main" 141
|
||||
ExecutionMode 4 OriginUpperLeft
|
||||
Name 4 "main"
|
||||
Name 8 "txval10"
|
||||
|
|
@ -349,7 +355,8 @@ gl_FragCoord origin is upper left
|
|||
MemberName 131(PS_OUTPUT) 0 "Color"
|
||||
MemberName 131(PS_OUTPUT) 1 "Depth"
|
||||
Name 133 "psout"
|
||||
Name 142 "g_tTex1df4"
|
||||
Name 141 "@entryPointOutput"
|
||||
Name 144 "g_tTex1df4"
|
||||
Decorate 11(g_tTex1df4a) DescriptorSet 0
|
||||
Decorate 11(g_tTex1df4a) Binding 1
|
||||
Decorate 15(g_sSamp) DescriptorSet 0
|
||||
|
|
@ -363,8 +370,8 @@ 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 142(g_tTex1df4) DescriptorSet 0
|
||||
Decorate 142(g_tTex1df4) Binding 0
|
||||
Decorate 144(g_tTex1df4) DescriptorSet 0
|
||||
Decorate 144(g_tTex1df4) Binding 0
|
||||
2: TypeVoid
|
||||
3: TypeFunction 2
|
||||
6: TypeFloat 32
|
||||
|
|
@ -435,7 +442,9 @@ gl_FragCoord origin is upper left
|
|||
135: 130(fvec4) ConstantComposite 134 134 134 134
|
||||
136: TypePointer Function 130(fvec4)
|
||||
138: 23(int) Constant 1
|
||||
142(g_tTex1df4): 10(ptr) Variable UniformConstant
|
||||
140: TypePointer Output 131(PS_OUTPUT)
|
||||
141(@entryPointOutput): 140(ptr) Variable Output
|
||||
144(g_tTex1df4): 10(ptr) Variable UniformConstant
|
||||
4(main): 2 Function None 3
|
||||
5: Label
|
||||
8(txval10): 7(ptr) Variable Function
|
||||
|
|
@ -515,6 +524,7 @@ gl_FragCoord origin is upper left
|
|||
Store 137 135
|
||||
139: 7(ptr) AccessChain 133(psout) 138
|
||||
Store 139 134
|
||||
140:131(PS_OUTPUT) Load 133(psout)
|
||||
ReturnValue 140
|
||||
142:131(PS_OUTPUT) Load 133(psout)
|
||||
Store 141(@entryPointOutput) 142
|
||||
Return
|
||||
FunctionEnd
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue