Remap Value
 
 
 

Remaps a scalar input to both scalar and color outputs. The scalar output is remapped with a scalar gradient, and the color output is remapped using a color gradient.

You can remap color and alpha values and control each of them separately. So, for example, you can define mappings where the alpha is the inverse of the color, or where they have different ranges.

Find this utility in the Create Bar (see Hide, resize or customize the Create bar).

To use this utility, see Use the Remap Color, Remap Hsv, or Remap Value utilities.

Usage

How you use Remap Value depends on what you want to remap.

For example you can vary reflectivity based on the facingRatio in either of the following ways:

Initially the part of the surface facing the view will be more reflective, but you can reverse this by reversing the gradient (make the value gradient go down to the right, or if you mapped the outColor make the color gradient become darker to the right).

Input and Output ranges

The input attributes index into the gradient controls, which define a new output value. Usually, you connect a varying attribute of some sort (such as values from the sampler info node, texture/shader outColors, or object position) to the input connection.

inputMin, inputMax

Define the values that remap into the left and the right of the gradient controls.

For example, if your input attribute varied between -1 and 1 you can set the inputMin to -1 and the inputMax to 1. This way your minimum values result in the values defined at the left of the ramp and the maximum map to the right. Values outside the min/max range will be clipped to the value at the edges of the gradient.

outputMin, outputMax

Determine the range of the output attribute. These attributes represent the top (max) and bottom (min) values of the gradients, or (in the case of a color gradient control) the displayed white (max) and black (min) output.

In some cases, you may want the outputMin/Max to match the inputMin/Max. For example if you are remapping the cameraNormalY to object color using a remapValue node, because the camera normal varies between -1 and 1, the inputMin/Max would be set to these values. However we do not want black to be -1,-1,-1, so it would make sense for the outputMin/Max to be 0 to 1.