SPIRV-Cross/reference/shaders/asm/vert/uint-vertex-id-instance-id.asm.vert
2018-06-22 11:30:56 +02:00

19 lines
327 B
GLSL

#version 450
uniform int SPIRV_Cross_BaseInstance;
vec4 _main(uint vid, uint iid)
{
return vec4(float(vid + iid));
}
void main()
{
uint vid = uint(gl_VertexID);
uint iid = uint((gl_InstanceID + SPIRV_Cross_BaseInstance));
uint param = vid;
uint param_1 = iid;
gl_Position = _main(param, param_1);
}