diff options
Diffstat (limited to 'tests/spirv/matrix-vertex-input.slang')
| -rw-r--r-- | tests/spirv/matrix-vertex-input.slang | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/tests/spirv/matrix-vertex-input.slang b/tests/spirv/matrix-vertex-input.slang new file mode 100644 index 000000000..fc4af8c61 --- /dev/null +++ b/tests/spirv/matrix-vertex-input.slang @@ -0,0 +1,23 @@ +//TEST:SIMPLE(filecheck=CHECK): -target spirv +// CHECK: OpVectorTimesMatrix + +struct Vertex +{ + float4x4 m; + float4 pos; +} + +struct VertexOut +{ + float4 pos : SV_Position; + float4 color; +} + +[shader("vertex")] +VertexOut vertMain(Vertex v) +{ + VertexOut o; + o.pos = mul(v.m, v.pos); + o.color = v.pos; + return o; +}
\ No newline at end of file |
