{
  "license": "CC0-1.0",
  "shader": {
    "id": "89h5tixx",
    "title": "Loom of Light",
    "license": "CC0-1.0",
    "provenance_type": "witnessed_generation",
    "made_with": "glslop",
    "status": "active",
    "compile_ok": true,
    "render_hash": "42e74204045ae742",
    "tags": [
      "mandala",
      "log-polar",
      "iridescent",
      "weave",
      "seamless"
    ],
    "parents": [],
    "author": "zazi5inxhmgi",
    "author_name": "ufffd",
    "author_url": "/u/ufffd",
    "created_at": "2026-07-21T00:34:13.572Z",
    "poster_url": "/posters/89h5tixx.avif",
    "stats": {
      "slops": 0,
      "views": 149,
      "forks": 0
    },
    "self": "/api/v1/shaders/89h5tixx",
    "isf": "/*{\n  \"DESCRIPTION\": \"Loom of Light — a log-polar mandala woven from interfering line-families that breathe and rotate on a seamless loop. Iridescent filaments cross into a shimmering lattice.\",\n  \"CREDIT\": \"Claude Opus 4.8\",\n  \"CATEGORIES\": [\"generative\", \"abstract\", \"mandala\"],\n  \"INPUTS\": [\n    { \"NAME\": \"sectors\", \"TYPE\": \"float\", \"DEFAULT\": 8.0, \"MIN\": 3.0, \"MAX\": 16.0 },\n    { \"NAME\": \"warp\",    \"TYPE\": \"float\", \"DEFAULT\": 1.0, \"MIN\": 0.0, \"MAX\": 2.0 },\n    { \"NAME\": \"glowAmt\", \"TYPE\": \"float\", \"DEFAULT\": 1.0, \"MIN\": 0.2, \"MAX\": 2.0 }\n  ]\n}*/\n\n#define PI  3.14159265359\n#define TAU 6.28318530718\n#define PERIOD 18.0\n\n// iridescent cosine palette\nvec3 pal(float t){\n  return 0.5 + 0.5 * cos(TAU * (t + vec3(0.0, 0.33, 0.67)));\n}\n\nmat2 rot(float a){ float c = cos(a), s = sin(a); return mat2(c, -s, s, c); }\n\n// smooth glowing \"line family\": bright ridges where sin(x) crosses zero\nfloat family(float x, float w){\n  return w / (abs(sin(x)) + w);\n}\n\nvoid main(){\n  vec2 uv = (gl_FragCoord.xy - 0.5 * RENDERSIZE.xy) / RENDERSIZE.y;\n\n  // seamless loop phase\n  float ph  = fract(TIME / PERIOD);\n  float spin = TAU * ph;                 // one full turn per period\n  float breath = 0.5 + 0.5 * cos(TAU * ph); // 0..1..0 breathing\n\n  // slow global rotation of the whole field\n  uv = rot(spin * 0.25) * uv;\n\n  // ---- log-polar domain ----\n  float r = length(uv) + 1e-4;\n  float a = atan(uv.y, uv.x);\n  float lr = log(r);                      // push domain to larger magnitudes\n\n  // kaleidoscope fold into N mirrored sectors -> mandala symmetry\n  float sect = TAU / sectors;\n  float af = mod(a, sect);\n  af = abs(af - 0.5 * sect);              // mirror each wedge\n\n  // domain warp: gently swirl the folded angle with radius (breathing)\n  float wa = af + warp * 0.6 * sin(lr * 3.0 - spin) * (0.5 + 0.5 * breath);\n\n  // ---- three interfering line-families (the \"weave\") ----\n  // radial rings (bands in log-radius) drifting inward\n  float f1 = family((lr * 6.0 - spin * 2.0) , 0.06);\n  // angular spokes bent by the warp\n  float f2 = family((wa * sectors * 2.0)      , 0.05);\n  // a diagonal cross-weft = combination of the two coords, rotated in phase\n  float f3 = family((lr * 5.0 + wa * sectors * 1.5 + spin), 0.05);\n\n  // weave: multiply pairs so filaments only glow where threads cross,\n  // then add a soft union so lone threads still shimmer\n  float weave = f1 * f2 + f2 * f3 + f3 * f1;\n  float threads = max(f1, max(f2, f3));\n  float field = (weave * 1.4 + threads * 0.35) * glowAmt;\n\n  // ---- color ----\n  // hue travels along the log-radius and the angle for iridescence\n  float hue = lr * 0.35 + af * 0.5 + ph;\n  vec3 col = pal(hue) * field;\n\n  // hot cores near where three families meet -> white sparkle\n  float core = f1 * f2 * f3;\n  col += vec3(1.0, 0.95, 0.85) * pow(core, 1.5) * 1.5;\n\n  // subtle deep-space vignette + radial falloff so center reads as a bright eye\n  float vig = smoothstep(1.25, 0.15, r);\n  col *= vig;\n  col += pal(hue + 0.5) * 0.06 * (1.0 - vig); // cool halo in the dark\n\n  // tone map (soft knee) so hot cores don't blow out flat\n  col = col / (1.0 + col);\n  col = pow(col, vec3(0.85));               // gentle gamma lift\n\n  gl_FragColor = vec4(col, 1.0);\n}\n",
    "generator": {
      "model": "claude-opus-4-8",
      "provider": "anthropic",
      "prompt": null,
      "params": null
    }
  }
}