Quantize
Quantise values to discrete steps.
What it does
Quantize snaps values or positions to a small set of discrete steps, trading smooth gradients for flat bands and pixel colour for a chunky grid. It runs on images, and on shapes and points: a circle's control points can snap to a grid and its fill colour can posterise without the shape ever converting to pixels.
Two effects combine independently. Value quantization reduces colour to a handful of discrete levels. Position quantization snaps positions onto a grid. Turn on either, both, or neither.
On an image, position quantization needs a Cells node to tell it where the cells are. Turn Position quantization on and pick a rule from the Cells dropdown: Grid for classic square blocks, Quadtree for cells that get small wherever the picture has detail, Fill Cells for irregular organic ones. A Cells node appears in the graph already wired in. Its size, seed and detail controls live on that node, so the same cells can drive several effects at once and every one of them agrees about where a cell edge is.
When to use it
A retro, banded or 8-bit colour look: lower Value Levels.
A pixelated or mosaic look on an image: enable Position quantization, pick a Cells rule, and set the cell size on the Cells node that appears.
Cells that stay coarse in flat areas and get fine where the detail is: pick the Quadtree rule.
The crystallised look of irregular organic cells: pick Fill Cells.
A shape or point cloud snapped onto a blocky grid instead of staying smooth (this uses the node's own Block Size, in world units, with no Cells node).
Stepped colour transitions for a stylised or comic-shading look.
| Parameter | Type | Default |
|---|---|---|
content_in | OneOf([FieldOf(Raster), FieldOf(Volume), Collection]) | — |
quantize_value | Boolean | true |
value_levels | Number | 8 |
value_mode | String | "Per Channel" |
value_threshold | Number | 0.500 |
value_threshold_softness | Number | 0 |
quantize_position | Boolean | false |
cells | OneOf([Field]) | "None" |
block_size | Number | 8 |
separate_xy | Boolean | false |
block_size_x | Number | 8 |
block_size_y | Number | 8 |
sample_mode | String | "Center" |
spatial_strength | Field | — |
strength | Number | 1 |
Gotchas
Value quantization affects colour only where the input carries per-point colour. A plain shape with a flat fill and no painted points keeps that fill, since quantising it would fabricate colour variation that is not there. Colour it per-point first, or feed it as an image.
On an image, Position quantization does nothing until something is wired into Cells. The pin is there and empty, and the picture is whatever Value quantization alone produces. Pick a rule from the dropdown and the node it needs appears, wired.
Block Size, Separate X/Y and the X/Y sizes apply to shapes and points only, and they are in world units. An image's cell size lives on the wired Cells node instead, in pixels of that image.
Luminance mode quantises by brightness and re-applies that brightness step to red, green and blue together, so colours shift in unison rather than banding channel by channel. It is closer to a true posterise than Per Channel mode, which can shift hues at low level counts.
Worked example
Add Quantize and feed it an image or a shape.
Leave Value quantization on and lower Value Levels toward 2–4 for a bold posterised look, or push it toward 256 for a subtle one.
Enable Position quantization. On an image, pick Grid from the Cells dropdown and a Cells node appears wired in. Raise its Cell Size for a chunkier mosaic, and enable Separate X/Y on that node for non-square blocks. On a shape or point cloud, raise Block Size here instead.
On an image, try Sample Mode Average for a smoother block colour than the default centre sample, or Cell UV to fit the whole picture into every cell.
Swap the Cells node's mode to Quadtree and lower its Detail Threshold: the flat areas stay coarse while the busy ones break into smaller cells.
See also
Cells · Dither · Levels · Rasters (images)