Keying
Pull a key that survives the edge: the keyer family, in the order that works.
A key does three separate jobs, and the keyers keep them separate so you can fix one without breaking the others:
- The matte - how much of each pixel is foreground.
- Despill - taking the screen's colour off the foreground, which is a colour fix and has nothing to do with the matte.
- The edge - the mixed pixels where foreground and background meet: hair, motion blur, soft focus.
Every keyer works in scene-linear float and never clips inside the key, so bright highlights and values below zero survive. A keyer's alpha is straight until you Premult.
Which keyer
| Node | Use it for |
|---|---|
| KeyerScreen | the daily green or blue screen: sample the backing, get a matte and despilled colour together |
| KeyerScreenClean | a badly or unevenly lit screen: it keys against a clean plate of the empty screen, pixel by pixel - the one for hair on a patchy backing |
| CleanScreen | builds that clean plate from the shot itself, to feed KeyerScreenClean |
| KeyerSample | arm 🎯 and click: screen samples say what leaves, foreground samples say what stays - an uneven screen from a few clicks |
| KeyerChroma | a quick key by distance from one sampled colour |
| Keyer | brightness or one channel: skies, windows, simple extractions |
| KeyerML | a learned matte for hair and edges the samplers struggle with; refine it with the others |
| Crucible | a subject that is not on a screen at all - see the Crucible page |
Each keyer has a status view (black, white and grey for "in", "out" and "in between"), and inside / outside masks that force alpha to 1 or 0 after the key, the same way on every keyer.
The supporting nodes
- SpillKill - removes green or blue spill from the foreground while keeping its brightness. Run it on the colour, separately from the matte, and judge it with the alpha at 1.
- Despot - fills pinholes in the core and removes specks in the background.
- EdgeBlur - blurs only the matte's edge.
- Erode / FilterErode - shrink or grow a matte.
- CrucibleRefine - finishing for any matte: clean black and white, shift the edge without losing its softness, grow or shrink only the core.
- BS_LightWrap and EdgeMix - let the background's light into the foreground's edge, and blend the edge into the plate.
A key that holds up
The arrangement that works on hard shots splits the matte in two:
- Garbage roto to throw away what can never be foreground.
- A core matte - hard, clipped, eroded a little: its only job is to be solid.
- An edge matte - gentle and never clipped: it carries the hair and the blur.
- Put them together (the core, plus the edge, inside the garbage, minus any holdout).
- Despill the colour on its own branch.
- Premult, merge over the background, then light wrap and the edge blend.
The edge matte is never clipped. If the edge looks crunchy, the edge matte is being clipped somewhere; if the core has holes, it is the core matte that needs work, not the edge.
