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.1.tesc
Shader version: 450
vertices = 4
vertex spacing = equal_spacing
0:? Sequence
0:26 Function Definition: @main(struct-VS_OUT-vf31[4];u1; ( temp structure{ temp 3-component vector of float cpoint})
0:26 Function Parameters:
@@ -115,6 +116,7 @@ Linked tessellation control stage:
Shader version: 450
vertices = 4
vertex spacing = equal_spacing
0:? Sequence
0:26 Function Definition: @main(struct-VS_OUT-vf31[4];u1; ( temp structure{ temp 3-component vector of float cpoint})
0:26 Function Parameters:
@@ -232,6 +234,8 @@ vertices = 4
MemoryModel Logical GLSL450
EntryPoint TessellationControl 4 "main" 40 44 48 66 72 92
ExecutionMode 4 OutputVertices 4
ExecutionMode 4 Isolines
ExecutionMode 4 SpacingEqual
Name 4 "main"
Name 8 "VS_OUT"
MemberName 8(VS_OUT) 0 "cpoint"