ANR Tools

ANR Adaptive Light Matcher

Keeps a comped element's light in step with the plate: when the wall behind it brightens, darkens or flickers, the element changes the same way.

  • Comp
  • Comp & Depth pack
  • 4 inputs
  • 12 controls

Overview

Adaptive Light Matcher watches the plate behind your element. On the Reference Frame, the frame where you graded the element to sit right, nothing changes. On every other frame, each Foreground pixel changes by what the wall point behind it changed since the Reference Frame: a passing shadow, a flicker, a light switched off.

The node follows the wall point behind the element by itself, from the element's own motion (for example the CornerPin that places it), or from a tracker connected to the Track input. Light Size ignores the wall's own detail, such as a window frame or a sign, so it does not print through the element, while shadow edges stay sharp.

To match the element's black and white levels to the plate's as well, use ANR Adaptive Grade Matcher with it.

Inputs

ForegroundBackgroundMaskTrackAdaptive Light MatcherOutput
  1. Foregroundrequired

    The element you are compositing (a patch, a sign, a CG render), already placed where it sits on the plate. Its alpha says where it is.

  2. Backgroundrequired

    The plate the element sits on. Its change since the Reference Frame is what the node applies to the Foreground.

  3. Maskoptional

    Limits where the change is applied. Invert Mask applies it outside the mask instead.

  4. Trackoptional

    A Tracker, CornerPin, Transform or moving 3D card setup that moves with the element. When it is connected, the node follows the wall behind the Foreground with it; otherwise it uses the Foreground's own motion.

Output. The Foreground with the plate's light change applied, ready to merge over the plate. Output can also show the change on its own or the reference plate, for checking.

Quick start

  1. Place your element over the plate as usual, and grade it so it sits right on one frame.
  2. Add ANR Adaptive Light Matcher. Connect the placed element to Foreground and the plate to Background.
  3. Go to the frame you graded on and press Set Reference Frame To Current. On that frame the Foreground passes through unchanged.
  4. Play the shot: the element now follows the plate's light. Choose a Change mode: Difference for flicker on a bright wall, Ratio when the light multiplies the surface, Gain + Offset for black-outs, shadows and haze.
  5. If the wall's own pattern shows through the element, raise Light Size; if a small patch of light or shadow is missed, lower it.
  6. Merge the result over the plate as before.

The panel

The node's panel as Nuke shows it, with the values of a new node. Click any control to see what it does; tabs and sections work as in Nuke.

ANR_Adaptive_Light_Matcher1
StatusFrame 0: no change. After it: Foreground x (background now / background on frame 0), at the same point of the wall.
Reference Frame0
Set Reference Frame To Current
Recalculate
ChangeRatio
OutputResult
Light Size35
Use GPU
Strength1
Invert Mask
Mix1
Follow Points Off Frame

All controls

ANR Adaptive Light Matcher12 controls
StatusStatusstatus

What the node does.

A one-line summary of what the node is doing with the current settings.

Reference FrameSliderlmReferenceFrame

The frame the Foreground was matched on. Nothing changes on it.

Default: 0

Set Reference Frame To CurrentButtonlmSetReferenceFrame

Make the frame you are on the Reference Frame.

RecalculateButtonlmRecalculate

Read the Foreground on the Reference Frame again, from the frame you are on. Press it after you change the Foreground: its roto, its mask, or anything above it.

ChangeMenulmChange

Difference: adds the background's change: Foreground + (background now - background then). A darker background takes the same amount off every Foreground pixel, so bright parts stay above black.
Ratio: multiplies by it: Foreground x (background now / background then). A background gone black makes the Foreground black.
Gain + Offset: fits now = gain x then + offset from the background at the same wall points, and grades the Foreground the same way: a black-out, a shadow, and a lifted black level (haze, flare) all carry across.

Default: RatioOptions: Difference Ratio Gain + Offset

OutputMenulmOutput

Result: the Foreground with the change applied.
Change: the change itself.
Reference Plate: the plate on the Reference Frame, moved with the Foreground to now. Inside the Foreground it should show the same wall as the plate now: check the following here.

Default: ResultOptions: Result Change Reference Plate

Light SizeSliderlmLightSize

How big a piece of the wall's own picture to ignore -- a window frame, glass, a sign -- in pixels of the Reference Frame; it grows with the wall as the camera comes closer. Shadow edges stay sharp at any size: the change is a median, not a blur. A patch of light or shadow narrower than this is ignored too, so lower it for small ones. 0 is every pixel on its own, and then the wall's detail shows through. Nothing changes on the Reference Frame, whatever it is.

Default: 35

Use GPUCheckboxlmUseGpu

Uses the graphics card for the Light Size step when one is free, otherwise the processor. The result is the same either way. The status line says which one the last frame used. Untick to always use the processor.

Default: on

StrengthSliderlmStrength

How much of the change to apply.

Default: 1

Invert MaskCheckboxlmInvertMask

Apply outside the Mask instead.

Default: off

MixSliderlmMix

Blend the result over the unchanged Foreground.

Default: 1

Follow Points Off FrameCheckboxlmFollowOffFrame

With a Tracker or ANR AI Point Tracker in Track: also use a point on the frames the Tracker switched it off, while it is switched on on the other one (this frame or the Reference Frame), at the position the Tracker keeps for it. The ANR AI Point Tracker switches a point off while it is outside the frame or hidden, and keeps following it there: with this on, a Foreground that goes partly or wholly out of the frame keeps following its wall. Off: only points switched on on both frames are used.

Default: on

Tips

  • Set Output to Change to see only what the node adds, and check that it comes from the right place on the wall.
  • Output > Reference Plate shows the plate of the Reference Frame moved to now. Inside the Foreground it should show the same wall as the plate now; if it slides, connect a tracker to Track.
  • Strength scales the change; Mix blends the result with the untouched Foreground.

Good to know

  • It works from the frame you add it on: it reads the Reference Frame as soon as it is set or a Foreground is connected, whatever frame you are on.
  • Track takes an ANR AI Point Tracker, an ANR AI Planar Tracker, an ANR Tracker to STMap or an ST map image, as well as a Nuke Tracker.
  • Nothing changes on the Reference Frame, by design: that is the frame you matched by eye.
  • With Ratio, a background that goes fully black makes the Foreground black. Gain + Offset handles black-outs and lifted blacks more naturally.
  • The node follows the Foreground from what it read on the Reference Frame. After you change the Foreground (its roto, its mask, or anything above it), press Recalculate: it reads the Foreground on the Reference Frame again, from the frame you are on, and the Track input too. If it cannot, Status says so: go to the Reference Frame and press it there.
  • When the element goes partly out of the frame, the part still in the frame keeps matching. With a tracker on Track, Follow Points Off Frame (on for a new node) also uses its points on the frames they are switched off outside the frame, as the AI Point Tracker exports them; comps made before keep it off.

Something unclear or missing? Write to [email protected].