DeepMerge merges samples from multiple deep images, so that each output pixel contains all of the samples from the same pixel in each input. You can also use it to holdout samples in the B input that are occluded by samples in the A input or plus overlapping samples from the A and B inputs.

Inputs and Controls

Connection Type

Connection Name



A, B

The deep images that you want to merge.

Control (UI)

Knob (Scripting)

Default Value


DeepMerge Tab




Sets how to merge the inputs:

combine - combine the samples from the A and B inputs.

holdout - hold out samples from the B input by the samples in the A input. This removes or fades out samples in input B that are occluded by samples in input A.

plus - adds A and B overlapping samples, which can be useful when recombining data after a holdout.

drop hidden samples



When enabled, samples that are completely obscured by other samples are discarded (that is, samples behind other samples that have an alpha of 1).

This control is only available when operation is set to combine.

drop zero threshold



Any samples whose alpha value falls below this threshold are discarded from the holdout. This can help filter out samples with very low alpha values caused by floating point inaccuracy.

This control is only available when operation is set to holdout.

metadata from



Sets which input’s metadata is passed down the node tree.

Note:  When metadata from is set to All and there are keys with the same name in both inputs, keys in B override keys in A.

volumetric holdout



Enable volumetric holdout if you want Nuke to calculate occlusion using the values of the holdout samples in front of samples from main. This is a more accurate representation of occlusion at depth, but can take longer to process.

For example:

M = main sample

H = holdout sample

M0 remains unchanged since there are no holdout samples before it. M2 is affected by the combined H0, H1, and H2 holdout samples and M4 is affected by all holdout samples.

You can now view the result, which is a holdout with red, green, blue, and alpha channels. Note that the output image is still a deep image.

Note:  When disabled, deep samples that coincide with a holdout are removed and everything 'deeper' is also removed.

Step-by-Step Guides

Merging Deep Images

Creating Holdouts with the DeepMerge Node