4 struct mystruct { float2 a; };
6 { 1, 2, }, // test trailing commas in list
14 // { { 5, 6, } }, // TODO: test unneeded levels
17 float test4 = { 7, } ; // test scalar initialization
19 struct mystruct2 { float a; float b; float c; };
20 mystruct2 test5 = { {8,}, {9,}, {10}, };
21 const mystruct2 constTest5 = { {8,}, {9,}, {10}, };
24 const float step = 1.f;
\r
26 const float3 a[8] = {
\r
27 normalize(float3(1, 1, 1)) * (n += step),
\r
28 normalize(float3(-1, -1, -1)) * (n += step),
\r
29 normalize(float3(-1, -1, 1)) * (n += step),
\r
30 normalize(float3(-1, 1, -1)) * (n += step),
\r
31 normalize(float3(-1, 1, 1)) * (n += step),
\r
32 normalize(float3(1, -1, -1)) * (n += step),
\r
33 normalize(float3(1, -1, 1)) * (n += step),
\r
34 normalize(float3(1, 1, -1)) * (n += step) };
36 const struct one { float3 a; } oneNonConst = { normalize(float3(-1, 1, 1)) * (n += step) };
37 const struct two { float3 a;
38 float3 b; } twoNonConst = { normalize(float3(-1, 1, 1)) * (n += step),
39 normalize(float3(-1, 1, 1)) * (n += step) };
42 struct PS_OUTPUT { float4 color : SV_Target0; };
49 ps_output.color = 1.0;