#version 450 // Pulses running from the modulator to the carrier, soft at the edges. layout(location = 0) in vec4 color; layout(location = 1) in vec2 along; layout(location = 2) flat in float time; layout(location = 0) out vec4 out_color; void main() { float pulse = 0.5 + 0.5 * sin(along.x * 0.25 - time * 9.0); float edge = 1.0 - along.y * along.y; out_color = color * edge * (0.3 + 0.7 * pulse * pulse); }