Clamp Node

Access: Nodes > Filters > Clamp

The Clamp node is often used for tech fixes and debugging issues in a scene. The node will take values outside of the Min and Max that you set and clamp them to that range. This is useful if you have erroneous values, for example data going over 1 which are causing you errors.

Tip:  Some nodes, such as Levels, include clamping options.

Using a Clamp node to clamp down the max value of this texture

By default the node will clamp from 0-1, visually causing so change, but you can also play with the properties to remove values, say for example you had a bump map with too many peaks, you could use a clamp to bring them down to a more standardized value.

Clamp Node Inputs

Input: Tells the node what the Clamp node will change and adjust.

Clamp Node Properties

Min

text field, slider

Default: 0.00

Defines the bottom end value to clamp. Values below the minimum are raised to the Min value, causing blacks to be lifted and appear grey.

Max

text field, slider

Default: 1.00

Defines the top end value to clamp. Values above the maximum will be lowered to the Max value, causing whites to be lowered and appear gray.

Components

Red, Green, Blue, Alpha

checkbox

By enabling or disabling the checkboxes you tell the node which color channels of your Input you want to adjust.

By default, adjustments affect the red, green and blue channel, but if you wanted to include the alpha or disable any of the others you can do so with these checkboxes.

Clamp Node Workflow Example

Example - Fixing Erroneous Values with the Clamp Node

Unexpected results from a Merge node can be the result of data outside of the 0-1 range. Depending on the blend mode math of the merge, you may be seeing results that don’t seem right.

In the example, the tiled texture is contrasted to a value of 1.3 using a high pivot of 0.8. This is causing some values to go over 1.

The values overlay another tiled texture using a Cloud node as the mask. However, the merge does not appear to be working properly and still merging in areas that are not white in the mask. There is also unexpected extra contrast added to the image. In the image below, after using a Clamp node, the final output texture is different.

The difference with and without a Clamp node.

It is not always obvious that your values are going over 1, but if you are doing some major color corrects, placing a Clamp node can tell you if the image is doing any operations incorrectly.

Related Nodes