Attribute Assign

Write attribute values to points and shapes.

What it does

Attribute Assign writes a value onto every point or shape in a collection as a named attribute, readable anywhere downstream. A single number, vector, or colour broadcasts the same value to every element. A per-element array, from Noise, Flood Fill, or similar, paints a different value onto each one.

A weight input restricts or softens the write: wire in a weight array, name a selection attribute, or both. They multiply together, and an element picks up the new value only where its combined weight is above zero. A Curve wired into Values authors a ramp along an analytic shape's length, sampling the curve and multiplying it into the named attribute per anchor.

When to use it

ParameterTypeDefault
collection_inOneOf([Collection])
valuesOneOf([Number, Vec3, Color, NumberArray, Vec3Array, ColorArray, Curve])
mask_weightsOneOf([Number, NumberArray])
attribute_nameString"weight"
clampBooleanfalse
maskString""
strengthNumber1

Gotchas

Clamp affects the direct value-assignment path only. When Values is a Curve, the result is left unclamped deliberately, so the ramp's shape is not flattened.

The Curve input for Values drives a ramp on analytic shapes only, sampling the curve along the shape and multiplying it into the attribute. On plain point collections a wired Curve has nothing to walk along, so use a Number, Vec3, Color, or array input there.

Naming a Mask attribute that does not exist on the collection is a silent no-op: nothing is written. Check that the name in Mask matches an attribute present upstream, for example the "selected" weight from a selection node, or clear it back to empty to write everywhere.

Worked example

  1. Add Attribute Assign and wire a collection of points or shapes into Collection In.

  2. Wire a Noise or Flood Fill array into Values, and set Attribute Name to something descriptive like "density".

  3. To restrict the write, wire a weight array into Mask Weights, or type the name of an existing selection attribute into Mask.

  4. Enable Clamp to hold the written values to 0–1.

  5. Read the collection downstream. The new attribute is available on every element.

See also

Point · Scatter · Edit · Attributes