SPIRV-Cross/shaders-msl/comp/complex-composite-constant-array.comp
Hans-Kristian Arntzen db55d474f9 MSL: Do not declare complex composite array in main for non-inlined.
Need to consider that complex composite arrays may be used in leaf
functions, and avoid the MSL library link fix unless everything is
nicely inlined.
2019-10-24 11:12:01 +02:00

20 lines
214 B
Plaintext

#version 450
layout(std430, set = 0, binding = 0) buffer SSBO
{
mat4 a;
uint index;
};
const mat4 as[] = mat4[](mat4(1.0), mat4(2.0));
void write_global()
{
a = as[index];
}
void main()
{
write_global();
}