Scalar fields

A formula that returns a single number at every point in space.

What it is

A scalar field is the simplest and most-wired kind of Fields. Ask it for a value anywhere, at a vertex, a pixel, or a point in a Collections, and it answers with one number.

That number means whatever you decide: a mask from 0 to 1, a height, a density, a displacement strength, an opacity, a temperature. Nothing is stored. The value is computed on demand, point by point, every time something samples the field.

When to use one

Use a scalar field where a parameter should change depending on position.

How to use it

Scalar fields come from several places.

Derive one from a field you already have. Derive runs an operator over its input and hands back the result: Gradient, Edges, Normal, Curvature and Laplacian from a scalar or distance field; Divergence, Curl and Magnitude from a vector field; Hue, Saturation and Luminance from a colour one. Disposition decides the shape of the answer. Replace gives you the operator's result on its own. Capture staples it onto the input as a named channel and keeps both, which is how a field grows into a multi-channel one.

Wire the field into whatever should respond: a displace node, an opacity slot, a material input, or any parameter that should vary across the canvas.

Run a scalar field through a Gradient to turn it into colour. The gradient maps each number to a colour, so a grey mask becomes a full spectrum.

Gotcha

A scalar field carries numbers, not colour. Feed one into a slot expecting colour and you get greyscale, the same number copied into red, green and blue. For real colour, convert through a Gradient or use a Colour fields.

Conversion between field kinds happens automatically where one exists, so a scalar field slots in wherever a number-at-every-point is expected. See Automatic conversion.

See also