Levels

Adjust image levels with input/output range, gamma, and per-channel control.

What it does

Levels remaps the tonal range of an image. Pull the input black and white points in to punch up contrast, push the output black and white points to flatten it, bend the midtones with Gamma. Channel Mode set to Per-Channel gives red, green, blue and alpha their own black point, white point and gamma curve instead of one shared curve.

The remap applies to the same colour values whether the input is a rendered raster, a filled shape, or colour carried on points, so the result matches wherever it is plugged in.

When to use it

ParameterTypeDefault
content_inOneOf([FieldOf(Color), Field, FieldOf(Volume), CollectionOf(Crc), Collection, GpuGeometry, CollectionOf(Geometry), Number, Vec2, Vec3, Color, NumberArray, ColorArray])
channel_modeString"Master"
in_blackNumber0
in_whiteNumber1
gammaNumber1
out_blackNumber0
out_whiteNumber1
r_in_blackNumber0
r_in_whiteNumber1
r_gammaNumber1
g_in_blackNumber0
g_in_whiteNumber1
g_gammaNumber1
b_in_blackNumber0
b_in_whiteNumber1
b_gammaNumber1
a_in_blackNumber0
a_in_whiteNumber1
a_gammaNumber1
auto_levelsBooleanfalse
auto_clipNumber0.100
pre_clampBooleantrue
post_clampBooleantrue
invertBooleanfalse
spatial_strengthField
strengthNumber1

Gotchas

Per-Channel is the only mode that touches alpha. In Master mode RGB share one curve and alpha passes through untouched, so reshaping the alpha channel requires Per-Channel.

Invert flips RGB only. Alpha is never inverted, in either channel mode.

Pre-Clamp and Post-Clamp default on, holding values inside 0–1 before and after the remap. Turn Pre-Clamp off when deliberately feeding out-of-range HDR values into the input curve.

Worked example

  1. Add a Levels node and feed it an image.

  2. Drag Input Black up and Input White down to increase contrast.

  3. Nudge Gamma below 1.0 to brighten midtones, or above 1.0 to darken them.

  4. Switch Channel Mode to Per-Channel and adjust the Blue row alone to cool the shadows without shifting red or green.

See also

Colour Correct · Channel · Color Space · Colour fields