← Fusion node reference
Keying & MatteIntermediate

DifferenceKeyer

Key from a clean background reference

Creates a matte by comparing a foreground image to a clean or reference background and isolating the pixels that differ.

DifferenceKeyer
DaVinci Resolve · Fusion

DifferenceKeyer is useful when a stable clean plate exists and color-based chroma keying is not the best way to separate the subject.

Overview

What DifferenceKeyer does

DifferenceKeyer compares the current foreground frame against a background reference. Areas that match the reference are treated as background; significant differences become the subject matte.

This works best with a locked or well-aligned camera, stable lighting and a genuinely representative clean plate. Shadows, exposure changes and camera motion can create false differences.

After the initial separation, matte filters, blur, Contract/Expand and Gamma refine the result. Solid and Garbage mattes are often useful for areas that the comparison cannot resolve cleanly.

Mental model

Think of DifferenceKeyer as asking: “what changed compared with the empty background?” Everything sufficiently different becomes foreground.

Common uses

Remove a static background using a clean plate
Create a motion/change matte
Extract a subject without green screen
Build a technical difference mask
Support set cleanup and compositing

Flow anatomy

Inputs & outputs

The port structure shows how this node fits into a Fusion graph.

Foreground

Image containing the subject.

Background

Clean plate or reference background for comparison.

DifferenceKeyer
Fusion node

Output

Image/matte produced from the foreground-background difference.

Inspector

Important parameters

Start with these controls before reaching for more complicated workarounds.

Low / High

Defines how much difference is required to become matte.

Set the thresholds so the subject is retained while normal background variation disappears.

Filter

Smooths and stabilizes the difference matte.

Fast Gaussian is a practical choice when a soft stable result is needed.

Blur

Softens the matte edge.

Use only enough to reduce chatter; excessive blur disconnects the matte from the subject.

Clipping Mode

Selects the Clipping Mode used by DifferenceKeyer.

Contract / Expand

Shrinks or grows the matte.

Useful for removing edge contamination or recovering a slightly tight key.

Gamma

Controls the density of intermediate matte values.

Helpful for preserving semi-transparent edge detail before clipping.

Solid Matte / Garbage Matte

Combines solid and garbage mattes with the Difference Keyer result.

Post Multiply Image

Multiplies image RGB by the generated alpha.

Useful when preparing the extracted foreground for normal compositing.

Practical setup

A reliable workflow

  1. 1

    Prepare or reconstruct a clean background plate.

  2. 2

    Align the clean plate with the foreground frame.

  3. 3

    Connect foreground and background to DifferenceKeyer.

  4. 4

    Tune Low/High while viewing the matte.

  5. 5

    Refine with Filter, Gamma and small Contract/Expand adjustments.

  6. 6

    Add Solid/Garbage mattes for local problems.

  7. 7

    Finish with MatteControl and Despill/color work if needed.

Typical node chain
Foreground + Clean Plate
DifferenceKeyer
MatteControl
Merge

Examples

Where this node fits in real work

Locked-off actor extraction

An actor is isolated by comparison with the empty set.

ForegroundCleanPlateDifferenceKeyerMatteControlMerge

Change detection

The difference matte becomes a technical mask.

Reference frameCurrent frameDifferenceKeyerBitmap / ColorCorrector

Troubleshooting

Common mistakes

Using the technique with an unaligned moving camera.
Using a clean plate captured under different lighting.
Pushing thresholds so hard that subject detail disappears.
Ignoring shadows that are legitimate differences from the clean plate.

Production notes

Practical tips

Stabilize or align sources before difference keying when necessary.
Inspect the clean plate and difference matte separately.
Local helper mattes are usually better than globally destructive thresholds.

Related nodes