Home · Lessons

Matching blacks and whites

Far things sit in haze, so their black is not 0

Lesson 03 · Free · ~7 min · Unit: Colour and air

1 The idea

The air between the camera and an object adds a thin haze, so the darkest part of a far mountain is brighter than the black of the ground up close, and it carries the haze colour. The black point is a colour per region, not one number for the whole frame.

The CG tower below was rendered with pure black (0), but it stands on a far hill. Lift its blacks to match the hill next to it, then press "gamma up" in the viewer to check, the way compositors really do it.

Grade lift: out = x·(1−b) + b (lift 0.1: 4.5 → 4.15)

2 Try it

Press gamma ↑ first, every time: wrong blacks jump out

Viewer1 · Lesson 03rgba · 1001

3 Deep dive

What sets a black

The black point is the colour a perfectly black object would show at that spot. Air between camera and object raises it, lens flare raises it, and nearby coloured light tints it.

You can read this from the plate: if blacks rise with distance, that is atmosphere. If near and far are lifted equally, that is usually flare.

Rules that keep depth believable

These rules keep the CG sitting at the right distance, not popping forward or sinking back.

RuleWhy
Near blacks ≤ far blacksLess air sits in front of near things
Two depths never share one blackOtherwise the eye loses the distance
No pure 0 in CGReal cameras almost never record that
Sample black beside it, at the same depthNot the darkest pixel in the frame
Keep the black’s tintThe tint is part of the mood

Toe vs Grade lift

Measured in Nuke 17: Grade lift pivots at 1, so it raises the mids and pulls HDR highlights down. Toe only touches values below twice the lift and leaves the rest alone. (This is Nuke’s Toe node; the toe in the lesson above is a simpler teaching curve that reaches up to 0.4.)

InGrade lift 0.1Toe lift 0.1
00.100.10
0.10.190.125
0.20.280.20
0.50.550.50
4.54.154.50

CG often has highlights above 1: lift blacks with Toe, not Grade lift

Where the black match goes

The black match is the last colour step on the element, on its own node. Any grade after it would shift the matched black every time you touch it.

Painted shadows and local darkening go before this node, so they pick up the right lifted black automatically.

  1. 1Unpremult
  2. 2Grade (white point)
  3. 3Toe (black, last)
  4. 4Premult
  5. 5Merge over

Checking like a pro

Push the Viewer gain up, push the gamma up, then pull the gain down. Some problems show in only one of these. While matching blacks, keep the viewer pushed up the whole time.

Do the white point first, the same way: sample a neutral, diffuse CG area (not a highlight) into whitepoint, the matching plate area into gain, then change brightness with multiply only.

4 In real work

In Nuke

  1. Unpremult under the CG Read
  2. Grade: a neutral CG area into whitepoint, the matching plate area into gain
  3. Toe: the plate black beside the object (same depth) into lift, as the last colour node
  4. Premult → Merge over the plate
  5. Viewer: gain up, gamma up, gain down, then compare blacks zone by zone

Common mistakes → the fix

  • ✗ Using Grade lift on CG with HDR highlights✓ The highlights get pulled down (4.5 → 4.15). Use Toe, which only touches the darks.
  • ✗ Matching blacks first, then grading more after it✓ Move the black match to the very end.
  • ✗ One black value for the whole frame✓ Black is a colour per zone. Split the Toe by depth or by object.
  • ✗ Sampling the near ground’s black for a far tower✓ The tower pops forward. Sample something at the same depth.
  • ✗ Neutralising the black to a colourless grey✓ Keep the plate’s tint, such as a bluish black in haze.

Before you send the shot

  • CG black sits close to the plate black at the same depth
  • Nothing near is more lifted than something far
  • No pure 0 in the CG
  • Toe is the last colour node before the Premult
  • Checked with gain up, gamma up and gain down

5 Check yourself

One question to check yourself

A CG building stands far away in hazy air. What should its darkest value be?

What you learned

🔒 Answer the question above and this card opens

More questions

1. Why lift the blacks of HDR CG with Toe rather than Grade lift?

2. In the plate, a near rock has a black of 0.02 and a far hill 0.06. The CG tower stands between them in depth. What should its black be?

Where the numbers come from: Grade lift 0.1 turns 4.5 into 4.15 (checked in Nuke 17). The "toe" in this lesson is an example curve that only touches values below 0.4; it is not the exact Toe2 formula.