HLSL: pass tessellation execution modes through to SPIR-V

The SPIR-V generator had assumed tessellation modes such as
primitive type and vertex order would only appear in tess eval
(domain) shaders.  SPIR-V allows either, and HLSL allows and
possibly requires them to be in the hull shader.

This change:

1. Passes them through for either tessellation stage, and,

2. Does not set up defaults in the domain stage for HLSl compilation,
to avoid conflicting definitions.
This commit is contained in:
steve-lunarg
2017-03-23 11:56:07 -06:00
parent e752f463c5
commit e741249b72
12 changed files with 476 additions and 13 deletions

View File

@@ -1,6 +1,7 @@
hlsl.hull.void.tesc
Shader version: 450
vertices = 3
vertex spacing = fractional_even_spacing
0:? Sequence
0:26 Function Definition: @main(struct-VS_OUT-vf31[3]; ( temp structure{ temp 3-component vector of float cpoint})
0:26 Function Parameters:
@@ -55,6 +56,7 @@ Linked tessellation control stage:
Shader version: 450
vertices = 3
vertex spacing = fractional_even_spacing
0:? Sequence
0:26 Function Definition: @main(struct-VS_OUT-vf31[3]; ( temp structure{ temp 3-component vector of float cpoint})
0:26 Function Parameters:
@@ -112,6 +114,8 @@ vertices = 3
MemoryModel Logical GLSL450
EntryPoint TessellationControl 4 "main" 33 37 39
ExecutionMode 4 OutputVertices 3
ExecutionMode 4 Triangles
ExecutionMode 4 SpacingFractionalEven
Name 4 "main"
Name 8 "VS_OUT"
MemberName 8(VS_OUT) 0 "cpoint"