You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

16 lines
293 B

#version 330 core
in vec4 color;
in float dist;
uniform vec2 u_resolution;
uniform float u_dashSize;
uniform float u_gapSize;
out vec4 FragColor;
void main()
{
if (fract(dist / (u_dashSize + u_gapSize)) > u_dashSize/(u_dashSize + u_gapSize))
discard;
FragColor = color;
}