Squigglevision
Per-object Squigglevision, also known as shimmer or boiling lines. Helps emulate a hand drawn, frame-by-frame look.
Noise should be a seamless grayscale texture. The shader uses world space coordinates for consistency across objects.
Shader code
shader_type canvas_item;
render_mode world_vertex_coords;
group_uniforms Squiggle;
/**
* Noise texture scale
* By default, the noise texture's size in world coordinates is set by its resolution
*/
uniform vec2 scale = vec2(1.0, 1.0);
uniform float strength = 1.0;
/**
* Number of squiggle frames per second
*/
uniform float fps = 6.0;
uniform sampler2D noise : filter_linear, repeat_enable;
group_uniforms;
varying vec4 modulate;
varying vec2 noise_uv;
void vertex() {
modulate = COLOR;
// Use world coordinates for scale-independent squiggles, offset by position to keep pattern attached to object
noise_uv = (VERTEX - MODEL_MATRIX[3].xy) / (vec2(textureSize(noise, 0)) * scale);
}
// Use irrational constants for unique squiggles every frame
#define offset_multiplier vec2(PI, E)
void fragment() {
vec2 noise_offset = vec2(floor(TIME * fps)) * offset_multiplier;
float noise_sample = texture(noise, noise_uv + noise_offset).r * 4.0 * PI;
vec2 direction = vec2(cos(noise_sample), sin(noise_sample));
vec2 squiggle_uv = UV + direction * strength * 0.005;
COLOR = texture(TEXTURE, squiggle_uv) * modulate;
}


Nice shader, can you share the original noise?
Sure, it’s just the default 512×512 NoiseTexture2D with 1.0 seamless blend skirt.
That’s so coooool!!!
I adore this shader, thank you!
Really nice!
How would you adapt this shader to use it on an entire scene?
For a whole scene, you’d have to apply the shader to every object. You could get a similar effect if you adapted it to a screen-reading shader, it wouldn’t look great for dynamic objects though since the distortion would change as they move around. Actually, might make sense to apply screen-space distortion to static/background objects and per-object distortion to everything else…🤔
amazing
Would it be possible to convert this shader to a spatial shader?
You could apply the same math to surface textures or vertex positions, or use it as a post-process on the whole screen.
really cool, just uses a lot of memory on web… any way to fix that?
I haven’t done any testing but if you’re having memory problems you could try swapping out the texture read for procedural noise calculated in the shader itself
just me or doesnt work the same duirng runtime?
I am having a problem like this also
What version are you on? I’m not seeing any discrepancies in 4.6