Green-screen keyer · Channel editor

Split video into channels. Key it. Composite it.

Prism separates any clip into its R, G, B and alpha channels, removes a background with a professional multi-sample keyer, drops a new image or video behind it, and exports — with audio, every frame and true alpha preserved. It runs in your browser and can be driven end-to-end by an AI agent.

Everything you need to cut a subject out — and put it anywhere

Built for real footage, not just a perfect studio screen.

Channel separation

Edit R, G, B and alpha independently over a timeline of ranges — hide, fade, offset or gain any channel across selected frames.

Pro green-screen keyer

Sample multiple key colors, each with its own tolerance, softness and spill. Hue-aware and luma-adaptive, with a matte view to tune against.

🖼

Background replacement

Composite the keyed subject over an image or video, with aspect-cover fit plus zoom and pan — baked into the export.

Nothing is lost

Sound is kept, every frame is preserved, and keyed exports carry real alpha (VP9 WebM). Composited exports are clean MP4.

🤖

Agent-ready (MCP)

A Model Context Protocol server exposes the whole editor — import, key, composite, export — so an LLM can do it all for you.

🔒

Private by design

No account. Each upload gets its own access token, is visible only to you, and auto-deletes after 24 hours of inactivity.

Retouch & reshape

A manual beauty toolkit — 50+ region tools for reshape, skin, makeup, hair and body, with on-canvas placement and keyframes that track a moving subject. The preview and the export run the exact same math.

Interactive demo

Try Prism right here

A real clip, split into its channels in your browser. Toggle R, G, B and alpha, click the preview to key out the sky, and build a timeline — every edit runs client-side. This demo is read-only: no uploads, no export. Want the full thing? Open the workspace →

Bonus demo — motion tracking: a subject walking left → right, with a concave retouch region keyframed to follow it

No AI — just keyframes. The region is placed at a few frames and Prism interpolates its position every frame, so a manual edit stays locked onto a moving subject. The dashed box is the live tracked region; it runs entirely in your browser.

Under the hood

Technical details

Prism isn't a filter on top of a video — it introduces its own channel-separated container, Prism T1 (the .prism format), and a keyer whose preview and export run the exact same math. Here's what's actually happening.

The .prism container Prism T1 · magic PRSM · little-endian
// .prism = one file: RGBA split into
// independent channels + an edit timeline

  [ header | meta | ch0 | ch1 | … ]

header  magic PRSM · v2 · flags
        w · h · fps · frameCount · metaLen
meta    { codec, alphaModel,
          channels[], timeline }
clips   grayscale per channel (H.264/VP9),
        packed in order · zero-copy reads
The keying & recombine math preview shader ≡ server exporter
// alpha: a pixel is cut if it matches ANY sample
dist  = ‖ YCbCr(px) − YCbCr(keyᵢ) ‖  // chroma-weighted
lumaW = 1 − 0.9·smoothstep(0.03, 0.16, chroma(keyᵢ))
αᵢ    = smoothstep(tolᵢ, tolᵢ+softᵢ, dist)
alpha = min(α₀ … α₇)  // up to 8 samples
despill: pull kept chroma off the key hue by spillᵢ

// timeline recombine (per channel, per frame)
value' = clamp((value·gain + offset·255)·opacity)
hidden ⇒ 0

PxC1 — our own codec

A from-scratch lossless codec for channel frames: a reversible color transform + MED / temporal prediction + an adaptive range coder. Hit Lossless .pxc in the workspace (or the prism_archive agent tool) to pack a clip bit-exact — smaller than raw, beats zlib on real frames, and needs no ffmpeg to read back, so re-edits never lose a generation.

Channel model

RGBA is separated into either shared (4 channels: R, G, B, A) or perChannel (6: R, G, B, Ar, Ag, Ab, where the single alpha splits per color). Each channel is a real grayscale track you can edit on its own.

Timeline engine

Non-linear ranges carry per-channel hidden / opacity / offset / gain. resolveAt(frame) merges defaults with every overlapping range (later wins) into one resolved state per channel, evaluated per frame at composite/export time.

Chroma key

Per-sample YCbCr distance with an adaptive luma weight, min-combined across up to 8 samples, so a tight key and a loose one coexist without bleeding. Per-sample tolerance, softness and spill; YCbCr despill on kept pixels.

Encode pipeline

Native ffmpeg splits planes (extractplanes) on import; a WebGL2, premultiplied-alpha shader previews. A keyed export becomes VP9 WebM with real alpha (alpha_mode=1); over a background it's an opaque H.264 MP4. Audio and exact frame counts are preserved.

Jobs that outlive the tab

Encoding runs server-side on a persistent job queue with progress over SSE — close the browser and the render keeps going. A restart re-queues anything mid-flight.

One core, three surfaces

A single TypeScript core drives the browser preview, the Node + ffmpeg server (REST + SSE), and a stdio MCP server of 16 self-describing tools — the web UI and an AI agent call the exact same ops.

How it works

Import

Upload a clip. The server splits it into channel planes on native ffmpeg — the job survives even if you close the tab.

Key

Click the colors to remove. Add several samples and tune each one's tolerance, softness and spill until the matte is clean.

Composite

Preview over a checkerboard, a solid color, or drop in a background image/video and frame it with zoom and pan.

Export

Render to MP4 — or WebM with true alpha when there's no background — and download. Audio and frame count intact.

For developers & agents

Drive Prism from an LLM over MCP

Every capability — prism_import, channel edits, prism_chroma_add_sample, prism_set_background, prism_export and more — is a self-describing MCP tool. Point your agent at the server and it can cut and composite video on its own.