This page may include unlocalized contents


Vector Change Range

In short, this node returns Input remapped from Old Range values to New Range values, with an optional clamp.

This can be used to adapt, to remap and even to clamp colors or other vector values. For example:
Input = 0.5, 1, 1
Old Range Min = 0, 0, 0
Old Range Max = 1, 1, 1
New Range Min = 0, 0, 0
New Range Max = 2, 0.5, 0.5

You can see that Input.x ist in the middle of the Old Range.x range, so the resulting x component is in the middle of the New Range.x range, which is 1.

The other two components for Input.y and Input.z are equal to the same Old Range Max components and therefore will be equal to the same New Range Max components, which both have a value of 0.5.
The resulting vector is 1, 0.5, 0.5 in this example. Using Input components that are not included in the Old Range will lead to results the are also outside of the New Range. For example using the Input 2, 1, 1 with the above settings would result in an output of 4, 0.5, 0.5, if Clamp To New Range is switched off. Switching this option on will limit the output values to what has been defined with New Range Min and New Range Max.