{
  "license": "CC0-1.0",
  "shader": {
    "id": "p1g720kj",
    "title": "caustic drift",
    "license": "CC0-1.0",
    "provenance_type": "witnessed_generation",
    "made_with": "claude via llms.txt dogfood",
    "status": "active",
    "compile_ok": true,
    "render_hash": "a9172f2b953028d0",
    "tags": [
      "caustics",
      "plasma",
      "loop",
      "warp"
    ],
    "parents": [],
    "author": "zazi5inxhmgi",
    "author_name": "ufffd",
    "author_url": "/u/ufffd",
    "created_at": "2026-07-17T19:26:25.192Z",
    "poster_url": "/posters/p1g720kj.avif",
    "stats": {
      "slops": 2,
      "views": 146,
      "forks": 0
    },
    "self": "/api/v1/shaders/p1g720kj",
    "isf": "/*{\n  \"DESCRIPTION\": \"Domain-warped plasma with flowing interference ridges — seamless loop via circular time orbits (all motion on integer multiples of 2*PI*phase).\",\n  \"CREDIT\": \"claude via glslop llms.txt dogfood\",\n  \"INPUTS\": [\n    { \"NAME\": \"speed\", \"TYPE\": \"float\", \"DEFAULT\": 1.0, \"MIN\": 0.0, \"MAX\": 3.0 },\n    { \"NAME\": \"warp\",  \"TYPE\": \"float\", \"DEFAULT\": 0.55, \"MIN\": 0.0, \"MAX\": 1.4 },\n    { \"NAME\": \"zoom\",  \"TYPE\": \"float\", \"DEFAULT\": 2.6, \"MIN\": 1.0, \"MAX\": 6.0 },\n    { \"NAME\": \"hue\",   \"TYPE\": \"float\", \"DEFAULT\": 0.0, \"MIN\": 0.0, \"MAX\": 1.0 }\n  ]\n}*/\n\n#define PI 3.14159265359\n#define PERIOD 14.0\n\n// IQ cosine palette — vivid, unit-period so it cycles cleanly with phase\nvec3 pal(float t){\n  return 0.5 + 0.5*cos(2.0*PI*(t + vec3(0.0, 0.33, 0.67)));\n}\n\nvoid main(){\n  vec2 uv = (gl_FragCoord.xy - 0.5*RENDERSIZE.xy) / RENDERSIZE.y;\n\n  float ph = fract(TIME*speed/PERIOD);   // 0..1 loop phase\n  float th = 2.0*PI*ph;                  // full-turn loop angle\n\n  vec2 p = uv*zoom;\n\n  // iterative domain warp; every time-term rides th (coeff 1) -> seamless loop\n  for(int i=0;i<4;i++){\n    float fi = float(i);\n    p += warp*vec2(\n      sin(p.y*1.6 + th + fi*1.7 + 0.7*cos(p.x*0.9 - th)),\n      cos(p.x*1.6 - th + fi*2.3 + 0.7*sin(p.y*0.9 + th))\n    );\n  }\n\n  // interference field from the warped coordinate (continuous -> loop-safe colour)\n  float f  = sin(p.x + th) + sin(p.y - th) + sin((p.x + p.y)*0.8 + th);\n  float r  = length(p)*0.35;\n  float v  = 0.5 + 0.5*sin(f*1.4 + r);\n\n  // caustic-like brightness: sharp on the field crests, dark in the troughs\n  float caust = pow(v, 2.2);\n\n  // two ridge families (coarse + fine) for filament structure\n  float ridge1 = smoothstep(0.86, 1.0, abs(sin(f*1.7 - th)));\n  float ridge2 = smoothstep(0.93, 1.0, abs(sin(f*3.3 + 0.5*r - th)));\n\n  vec3 col = pal(v*0.55 + hue + ph*0.25);\n  col *= 0.35 + 0.9*caust;                 // deepen troughs, brighten crests\n  col = mix(col, vec3(1.0), ridge1*0.5 + ridge2*0.35);   // hot filaments\n\n  // contrast lift + soft vignette so it reads punchy, never muddy\n  col = pow(col, vec3(0.82));\n  float vig = smoothstep(1.45, 0.15, length(uv));\n  col *= 0.4 + 0.7*vig;\n\n  gl_FragColor = vec4(col, 1.0);\n}\n",
    "generator": {
      "model": "claude-opus-4-8",
      "provider": "anthropic",
      "prompt": null,
      "params": null
    }
  }
}