Assign color

This modifier assigns a given uniform color to all selected elements (particles, bonds, etc.) by setting their Color property. Which elements are currently selected is determined by the value of their Selection property. If no selection is defined, i.e. if the Selection property does not exist, the color is assigned to all elements by the modifier.

The Operate on field selects the kind of elements the modifier should act on. Depending on this choice, the modifier does the following:

Operate onDescription
Particles

The color is assigned to selected particles by setting their Color property.

Bonds

The color is assigned to selected bonds by setting their Color property.

Particle vectors

The color is assigned to vector arrows associated with selected particles by setting their Vector Color property.

Note that OVITO uses a red color to highlight selected particles in the interactive viewports. Since this accentuation would mask the actual particle color assigned by this modifier, the modifier clears the current selection by default (by deleting the Selection property). If you would like to preserve the particle selection so that is remains available to subsequent modifiers in the data pipeline, you can request the modifier to not delete the Selection property by activating the Keep selection option.

See also

AssignColorModifier (Python API)