Cell Portrait
- group .........
- Galleries and grids
- source ........
- https://ui.aryank.space/components/cell-portrait
- markdown ......
- /lab/cell-portrait.md
- human .........
- /lab/cell-portrait
── WHAT_IT_IS ────────────────────────────────────────────────────────────────────────────────
A portrait drawn as a grid of circles that join into capsules and thin bridges. The cells shrink from 36px to 7px while the joins reshuffle every 133ms, then the image colors in and the loop runs back out. Dark areas hold the most circles, so a face reads before any color arrives. Canvas 2D and GSAP, timed frame by frame against the reference recording.
── BEHAVIOUR ────────────────────────────────────────────────────────────────────────────────
* Source mechanism
Measured frame by frame from the reference recording: circles of radius cell/3, thin bridges cell/6 wide, 42% of neighbors joined, cells shrinking from 36px to 7px on a log scale with sine.inOut, and a new layout every 133ms. Darker cells are likelier to draw a circle, and cells above 70% luma never do.
* Images
A transparent PNG keeps its own alpha. On an opaque image the most common border color is keyed out, along with enclosed pockets larger than 0.4% of the image. Smaller regions such as eye whites stay.
* Edges
Only whole cells are drawn, so no circle is cut by the frame and the silhouette outline always closes inside it.
* Motion and cost
Reduced motion holds the full-color frame with no reshuffle. The loop pauses offscreen and resamples on resize. Sampling runs at 540px on the shorter side, so cost stays flat as the component grows.