Skip to main content

vArrayRampMap

Turns a number per point into a color from a ramp of four color stops.

IntermediateMograph / ArrayArrayScriptValJSON
vArrayRampMap node

vArrayRampMap reads a value for each index from the index, a scalar array, a point coordinate or the distance to a center, and outputs a list of RGBA colors from a four-stop ramp. Curve shapes the transition.

Parameters​

ParameterTypeDefaultDescription
SourceDropdownIndexIndex (default), Scalar Input, Position X, Position Y, Position Z or Distance From Center. Position and distance sources give 0 without Points.
Auto RangeInteger1.0Uses the smallest and largest value as the range when on (default).
RangeMinFloat0Low end of the manual range. Used when Auto Range is off. Default 0.
RangeMaxFloat1High end of the manual range. Used when Auto Range is off. Default 1.
CurveDropdownLinearLinear (default), Smooth or Power.
+29 more parameters
ParameterTypeDefaultDescription
PowerFloat1Exponent for the Power curve. Range 0.001 to 10, default 1.
Clamp 0-1Integer1.0Limits the position to 0 to 1 when on (default).
InvertInteger0.0Reverses the ramp when on. Default off.
Fallback CountInteger100Number of colors when neither Points nor Scalars are connected. Range 1 to 1000, default 100.
Center XFloat0X of the center for Distance From Center. Default 0.
Center YFloat0Y of the center for Distance From Center. Default 0.
Center ZFloat0Z of the center for Distance From Center. Default 0.
PosFloat0.0Position of stop A on the ramp, 0 to 1. Default 0.
RedFloat0.05Red of stop A. Default 0.05.
GreenFloat0.10Green of stop A. Default 0.1.
BlueFloat0.35Blue of stop A. Default 0.35.
AlphaFloat1.0Alpha of stop A. Default 1.
PosFloat0.33Position of stop B on the ramp, 0 to 1. Default 0.33.
RedFloat0.10Red of stop B. Default 0.1.
GreenFloat0.55Green of stop B. Default 0.55.
BlueFloat0.85Blue of stop B. Default 0.85.
AlphaFloat1.0Alpha of stop B. Default 1.
PosFloat0.66Position of stop C on the ramp, 0 to 1. Default 0.66.
RedFloat0.95Red of stop C. Default 0.95.
GreenFloat0.72Green of stop C. Default 0.72.
BlueFloat0.20Blue of stop C. Default 0.2.
AlphaFloat1.0Alpha of stop C. Default 1.
PosFloat1.0Position of stop D on the ramp, 0 to 1. Default 1.
RedFloat1.00Red of stop D. Default 1.
GreenFloat0.20Green of stop D. Default 0.2.
BlueFloat0.10Blue of stop D. Default 0.1.
AlphaFloat1.0Alpha of stop D. Default 1.
PointsINPUT_DATATYPE—Optional points. They set the count and feed the position and distance sources.
ScalarsINPUT_DATATYPE—Optional numbers. They feed the Scalar Input source.
Read the full description

The number of colors is the number of Points, else the number of Scalars, else Fallback Count (default 100). Source picks the value: the index, the Scalar Input value, Position X, Y or Z, or the distance to Center X, Y and Z. With Auto Range on, the smallest and largest value are the range, otherwise Range Min and Max are.

The position t is (value - min) / (max - min), clamped to 0 to 1 if Clamp 0-1 is on (default), flipped by Invert, then shaped by Curve: Linear, Smooth (smoothstep) or Power (t ^ Power). Each color is found on the ramp of stops A to D, which sit at Pos A to Pos D (defaults 0, 0.33, 0.66, 1). Below the first stop the color is A, above the last it is D, and in between it is blended linearly.

Example Connections​

vArrayPointsOnGrid.Output -> vArrayRampMap.Points
vArrayPointsOnGrid.Output -> vArrayCameraProjection.ArrayA
vArrayCameraProjection.Output -> vArrayShapeRender.ArrayPoint
vArrayRampMap.Output -> vArrayShapeRender.JSONCustomColor
Background.Output -> vArrayShapeRender.Input