claude boundary expression

GLSL shader by scry · created 2026-01-17 · 10s loop · 2 passes

"Show the boundary between noise and meaning. That moment where pattern emerges from randomness. The edge where signal becomes something. Use comments to describe what's happening."

This page opens the shader in the ShaderKit browser GLSL editor: edit it live, fork it, or render it to video, GIF or images up to 8K. Also available as a full-screen view and an embeddable player.

Shader source (GLSL)

Common

#define pi acos(-1.)
#define deg pi/180.  //1 degree
#define time iTime*2.*pi/10. //sin(time) loops 10 seconds
#define R iResolution.xy //shorthand
#define ar R.x/R.y //aspect ratio
#define M iMouse //shorthand
#define xm (M.xy/R) //normalized mouse
#define nm ((xm.xy-0.5)*vec2(ar,1.)+0.5) //aspect ratio correction
vec3 cs = vec3(1.,2.,3.);
mat2 r2d(float a) {
    return mat2(cos(a),sin(a),-sin(a),cos(a));
}

Buffer A (iChannel0)

// Hash function for pseudo-random noise
float hash(vec2 p) {
    return fract(sin(dot(p, vec2(127.1, 311.7))) * 43758.5453);
}

// Smooth noise with interpolation
float noise(vec2 p) {
    vec2 i = floor(p);
    vec2 f = fract(p);
    // Smooth interpolation curve
    vec2 u = f * f * (3.0 - 2.0 * f);
    // Sample four corners and blend
    return mix(mix(hash(i), hash(i + vec2(1.0, 0.0)), u.x),
               mix(hash(i + vec2(0.0, 1.0)), hash(i + vec2(1.0, 1.0)), u.x), u.y);
}

// Fractal Brownian Motion - layered noise creating structure from chaos
float fbm(vec2 p) {
    float value = 0.0;
    float amplitude = 0.5;
    // Each octave adds finer detail - meaning emerges from accumulation
    for (int i = 0; i < 5; i++) {
        value += amplitude * noise(p);
        p *= 2.0;           // Double frequency
        amplitude *= 0.5;   // Halve amplitude
    }
    return value;
}

void mainImage(out vec4 fragColor, in vec2 fragCoord) {
    vec2 uv = fragCoord.xy / iResolution.xy;
    uv -= 0.5;
    uv.x *= ar;
    uv *= 2.;
    // The threshold - a breathing boundary between order and chaos
    float threshold = 0.5 + 0.15 * sin(time);
    
    // Pure randomness - the primordial chaos
    float pureNoise = hash(uv * 100.0 + iTime * 0.1);
    
    // Structured noise - pattern emerging from randomness
    float structured = fbm(uv * 4.0 + time * 0.3);
    
    // The edge detector - where does meaning begin?
    // This gradient represents the transition zone
    float edgeZone = smoothstep(-0.3, 0.3, uv.x);
    
    // Blend between chaos and structure based on position
    float field = mix(pureNoise, structured, edgeZone);
    
    // The moment of emergence - thresholding creates discrete meaning
    float emerged = smoothstep(threshold - 0.05, threshold + 0.05, field);
    
    // Color the boundary - the liminal space glows
    float atBoundary = 1.0 - abs(field - threshold) * 4.0;
    atBoundary = max(0.0, atBoundary);
    
    // Final composition: dark chaos, bright meaning, golden edge
    vec3 col = mix(vec3(0.02, 0.02, 0.05), vec3(0.9, 0.95, 1.0), emerged);
    col += vec3(1.0, 0.6, 0.2) * atBoundary * 0.8; // The edge glows amber
    
    fragColor = vec4(col, 1.0);
}

Image

Not used

More shaders by scry

Browse all public shaders · All shaders by scry · ShaderKit home

Vibe Mode BETA
💰 ~0 credits
Uniforms
FPS: 0
Time: 0
Resolution: 0 x 0

Account

FPS: -- Time: -- --×-- 1x