Shutter Type
Type seen through a rolling shutter, where whatever moves tears into sliding bands and whatever is still stays whole.
Two phrases share a 16:9 scene over a 68-frame loop, 2.72 seconds at 25 frames a second. "Design is thinking" jitters in and settles, the ground inverts from paper to sky blue, and the line swells a little and lifts away. A hard cut, and a stack of "made visual" scrolls up one row per beat.
How it works
Every slice, ghost and torn edge comes from one post-effect, a rolling shutter.
- A fixed stripe map. The frame is cut into horizontal stripes, 14 to 60 scene pixels tall. Each stripe lags the scene by up to 2.4 frames, quantised to five taps, and no two neighbours share a tap.
- Five taps a frame. The engine draws the clean scene five times, once per tap, into offscreen canvases, then copies each stripe from the canvas of its own lag.
- Still stays whole. Where nothing moves the taps agree and the copy is seamless. Where a word moves the stripes disagree and it tears.
- Hard cuts. A stripe's lag never reaches back past the start of its phrase, and the ground is drawn once from the present, so the inversion lands as one slap.
The first phrase arrives by jitter, not by easing. For about six frames each word sits at a fresh height within about 15px of home, then takes one larger kick and decays home. The push-in and the lift move the finished, shuttered picture, so the line leaves whole. The second phrase scrolls exactly one pitch every 14 frames, so the eye only ever sees the tearing mid-move.
Every word is measured from the live font and squeezed to its set width, so the spacing holds whichever grotesque draws it. It pauses off screen and on a hidden tab. Under reduced motion it draws frame 40 once, the stack at rest on paper. The canvas pixel ratio is capped at 2, and everything is cleaned up on unmount.
Installation
Usage
import ShutterType from "@/components/ui/shutter-type";
<div className="aspect-video">
<ShutterType paper="#f6f3ea" sky="#00afca" />
</div>;The effect fills its box and is drawn for 16:9. The words are part of the choreography, set in params.ts, so changing them means retiming the jitter tables. The type comes from --font-sans, and the layout is measured from the live font. A plain grotesque reads best.
| Prop | Default | What it changes |
|---|---|---|
paper | #f6f3ea | The ground for most of the loop, and the type on the inverted beats. |
sky | #00afca | The type for most of the loop, and the ground on the inverted beats. |
In params.ts, SKY_SPANS sets the frames on which the colours invert, STRIPE_LAG_MAX how far the bands tear, and STRIPE_SEED where the cuts fall.