SPIRV-Cross/shaders-msl/vert/clip-distance-block.no-user-varying.vert
Hans-Kristian Arntzen ebf463674d MSL: Allow removing clip distance user varyings.
Only safe if user knows that subsequent shader stage will not read clip
distance.
2020-04-20 09:58:40 +02:00

16 lines
240 B
GLSL

#version 450
layout(location = 0) in vec4 Position;
out gl_PerVertex
{
vec4 gl_Position;
float gl_ClipDistance[2];
};
void main()
{
gl_Position = Position;
gl_ClipDistance[0] = Position.x;
gl_ClipDistance[1] = Position.y;
}