HLSL: allow multi-dimensional arrays

All the underpinnings are there; this just parses multiple array dimensions
and passes them through to the existing mechanisms.

Also, minor comment fixes, and add a new test for multi-dim arrays.
This commit is contained in:
steve-lunarg
2016-10-13 12:26:18 -06:00
parent e3aa654c4b
commit 7b211a370b
5 changed files with 261 additions and 25 deletions

View File

@@ -0,0 +1,20 @@
float float_array[5][4][3];
struct PS_OUTPUT
{
float4 Color : SV_Target0;
};
PS_OUTPUT main()
{
float4 float4_array_1[2][3];
float4 float4_array_2[5][3];
float4_array_1[1][2] = float_array[2][3][1];
float4_array_2[1] = float4_array_1[0];
PS_OUTPUT psout;
psout.Color = float4_array_1[1][2];
return psout;
}