Separating foreground from background—typically greenscreen, then green channel keyed out and new background composited in. Edit or live camera.
Keying / Compositing Layer
You're sitting in front of the grading suite, and the editor shows you the first rough cut: an actor stands in front of a green screen, and a gothic cathedral is supposed to be behind them. The green screen disappears, the cathedral comes in — that's keying. It's the procedural core of compositing: you separate a color or a brightness value from the image and make that area transparent, so that something else appears underneath or behind it.
In practice, it works like this: You have a clean green or blue wall (greenscreen/bluescreen) behind your subject. The key effect in the NLE or compositing program — whether DaVinci, Nuke, or After Effects — identifies this color pixel by pixel and assigns it an alpha channel (transparency). Threshold and feathering play a role here: keyed too sharply, the edges look like paper cutouts. Too soft, and you lose details in the hair or on thin objects. The trick is always not to be too aggressive in the keying itself — it's better to rework it later in roto than to make half of the actor's forehead transparent along with their hair.
Practical Variants: The chromakey works with color (green or blue) and is standard for studio shoots. The luminance key separates by brightness — useful when shooting against a black background or when you want to isolate an explosion. With a difference matte, two shots are compared (one without, one with the object), and the difference is isolated. In live television, for weather forecasts or talk shows, keying runs in real-time — the hardware solution has to get it right a thousand times per second, otherwise, it flickers and looks like the 90s.
On set itself, you need stable lighting on the greenscreen: no wrinkles in the fabric, no hot spots, consistently evenly lit. Distance between the actor and the screen helps minimize spill (the green reflected back onto the actor from the screen). In editing: If your key isn't clean, despill tools are your second tool — they remove the green/blue tint that still clings to the edges. And the new background must match the isolated subject in terms of sharpness, perspective, and, above all, lighting — otherwise, the composite will look like a photo montage from 2003.