SPIRV-Cross/reference/shaders-msl/vert/layer.msl11.invalid.vert

25 lines
406 B
GLSL

#include <metal_stdlib>
#include <simd/simd.h>
using namespace metal;
struct main0_out
{
float4 gl_Position [[position]];
uint gl_Layer [[render_target_array_index]];
};
struct main0_in
{
float4 coord [[attribute(0)]];
};
vertex main0_out main0(main0_in in [[stage_in]])
{
main0_out out = {};
out.gl_Position = in.coord;
out.gl_Layer = uint(int(in.coord.z));
return out;
}