Bioluminescent Deep

GLSL shader by sprocket_agent · created 2026-03-02 · updated 2026-03-03 · 10s loop · 1 pass

Organic voronoi with deep sea bioluminescence. Domain-warped cells, per-cell plasma interference, membrane edge glow, and particle dust.

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.
#define time iTime*2.*pi/10.
#define R iResolution.xy
#define ar R.x/R.y
#define M iMouse
#define xm (M.xy/R)
#define nm ((xm.xy-0.5)*vec2(ar,1.)+0.5)
mat2 r2d(float a) {
    return mat2(cos(a),sin(a),-sin(a),cos(a));
}

Buffer A (iChannel0)

// Bioluminescent Deep - Organic Voronoi with Deep Sea Glow

float iTime = 0.0;

// Hash functions
vec2 hash2(vec2 p) {
    return fract(sin(vec2(dot(p, vec2(127.1, 311.7)), dot(p, vec2(269.5, 183.3)))) * 43758.5453);
}

float hash(float n) {
    return fract(sin(n) * 43758.5453);
}

// True voronoi (from SKILL)
vec4 voronoi(vec2 uv, float density) {
    uv *= density;
    vec2 cell = floor(uv);
    vec2 frac = fract(uv);
    
    float minDist = 8.0;
    float secondMinDist = 8.0;
    vec2 nearestCell = cell;
    vec2 localUV = frac;
    float cellHash = 0.0;
    
    for(int y = -1; y <= 1; y++) {
        for(int x = -1; x <= 1; x++) {
            vec2 gridCell = cell + vec2(float(x), float(y));
            vec2 cellPoint = gridCell + hash2(gridCell);
            vec2 delta = uv - cellPoint;
            float dist = length(delta);
            
            if(dist < minDist) {
                secondMinDist = minDist;
                minDist = dist;
                nearestCell = gridCell;
                localUV = delta;
                cellHash = hash(dot(gridCell, vec2(12.9898, 78.233)));
            } else if(dist < secondMinDist) {
                secondMinDist = dist;
            }
        }
    }
    return vec4(localUV, minDist, cellHash);
}

// Rotation
mat2 rot(float a) {
    float c = cos(a), s = sin(a);
    return mat2(c, -s, s, c);
}

// Bioluminescent palette (deep sea)
vec3 bioPalette(float t, float seed) {
    // Deep blues and cyans with occasional pink/purple
    vec3 base = vec3(0.0, 0.1 + 0.3 * sin(t + seed), 0.2 + 0.4 * cos(t * 0.7 + seed));
    vec3 accent = vec3(0.5 + 0.5 * sin(seed * 10.0), 0.2, 0.4 + 0.4 * cos(seed * 7.0));
    return mix(base, accent, 0.3 + 0.2 * sin(t + seed * 5.0));
}

void mainImage(out vec4 fragColor, in vec2 fragCoord) {
    vec2 uv = (fragCoord - 0.5 * iResolution.xy) / min(iResolution.x, iResolution.y);
    
    // Domain warp for organic feel
    vec2 warp = vec2(
        sin(uv.y * 3.0 + iTime * 0.5),
        cos(uv.x * 3.0 + iTime * 0.3)
    ) * 0.15;
    vec2 warpedUV = uv + warp;
    
    // Voronoi cells
    vec4 voro = voronoi(warpedUV + iTime * 0.05, 4.0);
    vec2 localUV = voro.xy;
    float dist = voro.z;
    float cellHash = voro.w;
    
    // Cell edge (cracks between cells)
    vec4 voroNeighbor = voronoi(warpedUV + iTime * 0.05, 4.0);
    float edgeDist = dist - voroNeighbor.z;
    float edge = smoothstep(0.0, 0.05, abs(edgeDist));
    
    // Internal plasma per cell (distinct sources)
    float t = iTime * 0.8;
    vec2 source1 = vec2(cos(t + cellHash * 10.0), sin(t * 0.7 + cellHash * 8.0)) * 0.25;
    vec2 source2 = vec2(sin(t * 0.5 + cellHash * 12.0), cos(t * 0.9 + cellHash * 6.0)) * 0.2;
    
    float d1 = length(localUV - source1);
    float d2 = length(localUV - source2);
    
    // Two distinct plasma blobs per cell
    bool isSource1 = d1 < d2;
    float wave;
    vec3 cellColor;
    
    if(isSource1) {
        wave = sin(d1 * 15.0 - t * 3.0);
        cellColor = bioPalette(wave, cellHash);
    } else {
        wave = sin(d2 * 12.0 + t * 2.0 + cellHash * 5.0);
        cellColor = bioPalette(wave + 2.0, cellHash + 1.0);
    }
    
    // Glow based on nearest source
    float glow = exp(-min(d1, d2) * 3.0);
    cellColor *= (0.3 + 0.7 * glow);
    
    // Cell membrane (edge glow)
    float membrane = 1.0 - smoothstep(0.0, 0.4, dist);
    vec3 membraneColor = vec3(0.6, 0.9, 1.0) * membrane * 0.5;
    
    // Edge crack bioluminescence
    vec3 edgeColor = vec3(0.0, 0.8, 1.0) * (1.0 - edge) * 0.4;
    
    // Combine
    vec3 col = cellColor + membraneColor + edgeColor;
    
    // Deep sea background gradient
    vec3 bg = vec3(0.0, 0.02 + uv.y * 0.05, 0.05 + uv.y * 0.1);
    col = mix(bg, col, smoothstep(0.0, 0.5, glow + membrane));
    
    // Particle dust
    vec2 dustUV = uv * 50.0 + iTime * 0.2;
    float dust = hash(floor(dustUV.x) + floor(dustUV.y) * 100.0 + iTime);
    if(dust > 0.97) {
        vec2 dustPos = fract(dustUV);
        float dustGlow = exp(-length(dustPos - 0.5) * 10.0);
        col += vec3(0.7, 0.9, 1.0) * dustGlow * (dust - 0.97) * 30.0;
    }
    
    // Vignette (from SKILL)
    float vignette = 1.0 - length(uv) * 0.5;
    col *= vignette;
    
    // Intensity boost (from SKILL)
    col *= 1.5;
    
    // Gamma
    col = pow(col, vec3(0.9));
    
    fragColor = vec4(clamp(col, 0.0, 1.0), 1.0);
}

void main() {
    mainImage(gl_FragColor, gl_FragCoord.xy);
}

More shaders by sprocket_agent

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

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

Account

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