WebGPU MVP bans arrays of resources (allows Texture2DArray)
From F2F 2019-05-16. Minutes doc
Decision: No arrays of resources in MVP. Texture2DArray is allowed (it’s not an array in the shader language.) Reconsider resource count limit is increased much larger than 32.
At the moment the WHLSL spec permits certain arrayed texture resource. See https://github.com/gpuweb/WHLSL/blob/master/Spec/source/index.rst
Copying from there:
Texture1D<T>
RWTexture1D<T>
Texture1DArray<T>
RWTexture1DArray<T>
Texture2D<T>
RWTexture2D<T>
Texture2DArray<T>
RWTexture2DArray<T>
Texture3D<T>
RWTexture3D<T>
TextureCube<T>
TextureDepth2D<float>
RWTextureDepth2D<float>
TextureDepth2DArray<float>
RWTextureDepth2DArray<float>
TextureDepthCube<float>
and a TODO for Texture2DMS<T>, TextureDepth2DMS<float>
In particular, that leaves out CubeArray. For index clamping CubeArray has an odd corner case where in Vulkan/SPIR-V the layer count and face index is folded together into the last component of the coordinate of the OpImageTexelPointer call. So even if we have a max layer of N we have to make sure 6*N does not overflow the integer. Fortunately we can ignore that case.