2026-05-20 16:53:23 -04:00
|
|
|
<!DOCTYPE html>
|
|
|
|
|
<html>
|
|
|
|
|
<head><meta charset="UTF-8"><style>html,body{margin:0;background:#000}canvas{display:block}</style></head>
|
|
|
|
|
<body>
|
|
|
|
|
<canvas id="c"></canvas>
|
|
|
|
|
<script type="module">
|
|
|
|
|
import { generateScene } from '../src/scene/scene.js';
|
|
|
|
|
import { renderCanvasPhoto } from '../src/render/canvasPhoto.js';
|
Colour palettes, depth/exposure, disk & halo effects; stop tracking rasters
Generator
- Depth & exposure dynamics: per-track chamber depth (z) + event age drive
opacity, bubble size and defocus (depthFactors); depth/aging dials.
- Palette abstraction (src/render/palette.js) — one registry entry per "feel":
mono, charge, beta, kind, kindlife, kindrise, lifecycle, psychedelic,
cyanotype, magentarise. Per-track ink + per-bubble bubbleInk hooks.
- Global colour controls: saturation, hue shift; paper toning (cream/sepia/
selenium/cool/olive/neutral + brightness + gas-glow), bubble edge softness,
iridescent disk (spectral sunburst), chromatic halo. Ink blend chosen by
ground luminance so light-on-dark chemistries composite correctly.
- Tracks carry charge q; bubbles carry lifecycle position + local beta.
- All effects in raster + layered SVG + CMYK/OCG PDF; B&W remains the default.
Tooling & art
- tools/find-semicircle.mjs; render-svg/pdf --seed mode + k=v overrides.
- Curated vector SVG sets under output/ with browsable index.html.
Repo hygiene
- .gitignore: stop tracking generated rasters/PDFs (reproducible from seeds),
the reference image, and a stray db; keep curated SVGs + code + docs.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-21 15:55:03 -04:00
|
|
|
import { GROUPS, TOGGLES, SELECTS, FIXED, PRESETS } from '../src/ui/controls.js';
|
2026-05-20 16:53:23 -04:00
|
|
|
import { paramsFromSeed } from '../src/scene/params.js';
|
|
|
|
|
|
|
|
|
|
const q = new URLSearchParams(location.search);
|
|
|
|
|
|
|
|
|
|
// fromseed=1 : derive the ENTIRE parameter set deterministically from the seed
|
|
|
|
|
let params;
|
|
|
|
|
if (q.get('fromseed') === '1') {
|
|
|
|
|
params = { ...FIXED, ...paramsFromSeed(q.get('seed') || 'ENTROPY-001') };
|
|
|
|
|
} else {
|
|
|
|
|
params = { ...FIXED, seed: 'ENTROPY-001' };
|
|
|
|
|
for (const g of GROUPS) for (const c of g.controls) params[c.id] = c.value;
|
|
|
|
|
for (const t of TOGGLES) params[t.id] = t.value;
|
Colour palettes, depth/exposure, disk & halo effects; stop tracking rasters
Generator
- Depth & exposure dynamics: per-track chamber depth (z) + event age drive
opacity, bubble size and defocus (depthFactors); depth/aging dials.
- Palette abstraction (src/render/palette.js) — one registry entry per "feel":
mono, charge, beta, kind, kindlife, kindrise, lifecycle, psychedelic,
cyanotype, magentarise. Per-track ink + per-bubble bubbleInk hooks.
- Global colour controls: saturation, hue shift; paper toning (cream/sepia/
selenium/cool/olive/neutral + brightness + gas-glow), bubble edge softness,
iridescent disk (spectral sunburst), chromatic halo. Ink blend chosen by
ground luminance so light-on-dark chemistries composite correctly.
- Tracks carry charge q; bubbles carry lifecycle position + local beta.
- All effects in raster + layered SVG + CMYK/OCG PDF; B&W remains the default.
Tooling & art
- tools/find-semicircle.mjs; render-svg/pdf --seed mode + k=v overrides.
- Curated vector SVG sets under output/ with browsable index.html.
Repo hygiene
- .gitignore: stop tracking generated rasters/PDFs (reproducible from seeds),
the reference image, and a stray db; keep curated SVGs + code + docs.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-21 15:55:03 -04:00
|
|
|
for (const s of SELECTS) params[s.id] = s.value;
|
2026-05-20 16:53:23 -04:00
|
|
|
if (q.get('preset') && PRESETS[q.get('preset')]) Object.assign(params, PRESETS[q.get('preset')]);
|
|
|
|
|
}
|
|
|
|
|
if (q.get('seed')) params.seed = q.get('seed');
|
|
|
|
|
for (const [k, v] of q) {
|
|
|
|
|
if (k === 'seed' || k === 'preset' || k === 'size_px') continue;
|
|
|
|
|
if (k in params) params[k] = (v === 'true') ? true : (v === 'false') ? false : (isNaN(+v) ? v : +v);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
const SIZE = +(q.get('size_px') || 1200);
|
|
|
|
|
const c = document.getElementById('c');
|
|
|
|
|
c.width = c.height = SIZE;
|
|
|
|
|
const ctx = c.getContext('2d', { willReadFrequently: true });
|
|
|
|
|
const scene = generateScene(params);
|
|
|
|
|
renderCanvasPhoto(ctx, SIZE, SIZE, scene, params, { preview: q.get('hq') !== '1' });
|
|
|
|
|
document.title = 'done';
|
|
|
|
|
window.__done = true;
|
|
|
|
|
</script>
|
|
|
|
|
</body>
|
|
|
|
|
</html>
|