Radial Speedlines

What?! Radial speedlines?

This shader relies on a noise texture to generate the spikes. I suggest turning up persistence and lacunarity, whatever those things mean. Change sample_radius to animate the speedlines!

Shader code
shader_type canvas_item;

uniform vec2 center = vec2(0.5, 0.5);
uniform sampler2D noise;
uniform float sample_radius: hint_range(0.0, 1.0) = 0.5;
uniform vec4 line_color: hint_color = vec4(1.0);
uniform float center_radius: hint_range(0.0, 1.0) = 0.5;

const float pi = 3.14159265359;

void fragment() {
	vec2 dist = UV - center;
	float angle = atan(dist.y / dist.x);
	vec2 sample = vec2(sample_radius * cos(angle), sample_radius * sin(angle));
	float noise_value = texture(noise, sample).r;
	vec4 color = mix(line_color, vec4(0.0), noise_value);
	color = mix(color, vec4(0.0), 1.0 - length(dist) - center_radius);
	COLOR = color;
}
Tags
action line, action lines, actionlines, Anime, polar, polar coordinates, radial, speed line, speed lines, speedline, speedlines
The shader code and all code snippets in this post are under CC0 license and can be used freely without the author's permission. Images and videos, and assets depicted in those, do not fall under this license. For more info, see our License terms.

More from Exuin

Screentone – Black spaced pixels

Palette Swap (no recolor / recolor)

SPEEDLINES

Related shaders

SPEEDLINES

Smooth Radial Gradient

2D Radial Distortion – Fisheye/Barrel

guest

2 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
Henodude
Henodude
7 months ago

Nice! Thank you! Mind if I use this in my game?