Afterimage

Loren Bednar · 2023

A dark, moody square of deep crimson-red and near-black. Soft blurred concentric arcs form eye- or lens-like negative shapes at left and right, crossed by a black diagonal wedge — atmospheric, glowing and out-of-focus, red bleeding into shadow.
Loren Bednar · via Art Blocks ↗ · © the artist

A dynamic generative work by Loren Bednar filled with blended, changing colours, exploring the edge between what is seen and what was just seen — an attempt to capture the fleeting persistence of an optical afterimage.

How it works

An animated multi-pass fragment-shader system. Token-randomised concentric and radial colour bands are distorted by colour-keyed mirroring, then blended 95% with the previous frame — a feedback loop that leaves the persistent trails of an optical afterimage — and finally folded kaleidoscopically.

A token-seeded sfc32 `Random` first assembles the piece's parameters, then five WebGL fragment-shader passes ping-pong between offscreen textures each frame (`render()` = rf0→rf4). **Pass 0** is the generator: per pixel it computes distances to a few fixed centres and an index `idx` from an **equation assembled out of randomly-chosen GLSL snippets** — the concentric/directional term (`cncpA/B`), the modulation term (`aM0/1`, `mvOA`) are each picked from arrays, so every token gets a different distance/modulo pattern — animated by `tick` and an eased ping-pong phase. `idx` is quantised and run through a generated if/else ladder that assigns one of the palette's colours (drawn from **24 hard-coded 5-colour palettes**, expanded with repeats and sorted/reversed/shuffled) plus a "gloss" value. **Pass 1** reprocesses: pixels near palette colour c0 flip vertically, pixels near c1 get a striped horizontal mirror (one of three `bldT` modes), and the result is scaled by a randomly-chosen distance "lens" (`lsA`). **Passes 2–3** are the afterimage core: the reprocessed frame is `mix`ed **0.95 with the previous composited frame** and copied back — a feedback loop whose long tail is the optical-afterimage persistence the title names. **Pass 4** displays it: optional kaleidoscopic axis flips (`xF/xF1/yF/yF1`), an offset + point-reflected sample mixed by an eased interpolation, and a brightness adjust. This decomposition is grounded in the actual on-chain generator script (sha-256 e599fa9ce386cc50…): the JS glue is minified and the exact per-pass GLSL maths are summarised, not reproduced — but the pass pipeline, the random snippet-selection and the 0.95 feedback are read directly from the shader source, not inferred.

Details

Runtimes
Browser (Canvas / 2D), On-chain Deterministic
Movement
Long-form Generative Art
Medium
On-chain generative edition
Relations
released-on (2023-07) → art-blocks
On-chain
arbitrum · 0x47a91457a3a1f700097199fd63c039c4784384ab · #3

View generator ↗ · Art Blocks ↗

Sources

Last updated 2026-07-16