summaryrefslogtreecommitdiffstats
path: root/tests/metal/simple-vertex-position-return-value-and-out.slang
blob: f150eef20afe515dd0a92301b4871d6d52a0bb7b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
//TEST:SIMPLE(filecheck=METAL): -target metal -stage vertex -entry vertexMain
//TEST:SIMPLE(filecheck=METALLIB): -target metallib -stage vertex -entry vertexMain

//METAL: [position]]
//METAL: [user(AA)]]
//METALLIB: @vertexMain

// Vertex Shader which writes to position in a returned value (as metal expects), and as an out parameter which it doesn't
float4 vertexMain(out uint aa : AA) : SV_Position
{
    aa = 0;
    return float4(1,2,3,4);
}