In Blender's Keying node, what exactly do the Tweak (black/white level, garbage and core matte) and Edge stages and the Postprocess stages do, in what order, and what do their parameters mean at the boundary values?
Blender's Keying node runs in a fixed order: optional chroma blur of the input, matte computation, a tweak stage, then optional blur, dilate/erode and feather of the matte, then the despilled image. In the tweak stage a pixel is an 'edge' when fewer than 90% of its (2r+1)^2 neighbours are within the edge tolerance (strict less-than). Non-edge pixels are remapped by black/white level, the garbage matte is subtracted, and the core matte is applied last, so core wins over garbage. The Edges output comes from that stage, before blur, dilate and feather. Edge Tolerance 0 makes every pixel an edge, which disables level remapping. A defect (in the commit read and still on main on 2026-10-22) sets the white level from the black-level input, so the shortcut that should skip the tweak at default levels never fires. By curator reading this wastes an extra full-image pass rather than changing the result (not run).
Structured fields
{
"citations": [
{
"url": "https://github.com/blender/blender/blob/f46990f5f55e36cc771b0ce476512b89ecfcea23/source/blender/compositor/shaders/compositor_keying_tweak_matte.glsl",
"note": "compositor_keying_tweak_matte.glsl @f46990f L28-60; node_composite_keying.cc @f46990f L191-212, L479-498, L560-606; node_composite_keying.cc on main (2026-10-22) L483-492"
},
{
"url": "https://github.com/blender/blender/blob/f46990f5f55e36cc771b0ce476512b89ecfcea23/source/blender/nodes/composite/nodes/node_composite_keying.cc",
"note": "compositor_keying_tweak_matte.glsl @f46990f L28-60; node_composite_keying.cc @f46990f L191-212, L479-498, L560-606; node_composite_keying.cc on main (2026-10-22) L483-492"
}
]
}Evidence claims
- [sourced_fact] Blender's Keying node runs in a fixed order: optional chroma blur of the input, matte computation, a tweak stage, then optional blur, dilate/erode and feather of the matte, then the despilled image. In the tweak stage a pixel is an 'edge' when fewer than 90% of its (2r+1)^2 neighbours are within the edge tolerance (strict less-than). Non-edge pixels are remapped by black/white level, the garbage matte is subtracted, and the core matte is applied last, so core wins over garbage. The Edges output comes from that stage, before blur, dilate and feather. Edge Tolerance 0 makes every pixel an edge, which disables level remapping. A defect (in the commit read and still on main on 2026-10-22) sets the white level from the black-level input, so the shortcut that should skip the tweak at default levels never fires. By curator reading this wastes an extra full-image pass rather than changing the result (not run). · locator: compositor_keying_tweak_matte.glsl @f46990f L28-60; node_composite_keying.cc @f46990f L191-212, L479-498, L560-606; node_composite_keying.cc on main (2026-10-22) L483-492 source
Rights
| component | license | hosting | redistribution | modification | training | Evidence and notes |
|---|---|---|---|---|---|---|
| documentation | unknown | permitted | permitted | unknown | unknown | Applies to this original summary only, not to the cited sources. |
Linked records
- cites → https://github.com/blender/blender/blob/f46990f5f55e36cc771b0ce476512b89ecfcea23/source/blender/compositor/shaders/compositor_keying_tweak_matte.glsl
- cites → https://github.com/blender/blender/blob/f46990f5f55e36cc771b0ce476512b89ecfcea23/source/blender/nodes/composite/nodes/node_composite_keying.cc