Houdini 20.5 Nodes Geometry nodes

Attribute Paint geometry node

Interactively paint point attributes, such as color or deformation mask values, directly on geometry.

On this page
Since 18.0

How to

To...Do this

Resize the brush

Hold ⌃ Ctrl + ⇧ Shift and drag with or ⌃ Ctrl + ⇧ Shift and use the scroll wheel on the mouse.

Undo a brush stroke

Press ⌃ Ctrl + Z.

Tips

  • This node can only create/edit point attributes.

  • This node replaces the old Paint SOP. It is much faster and has more features.

  • The painted attributes are stored along with a mask of where they were painted, allowing the attributes to be re-applied to deforming geometry. (This requires point numbers to remain consistent.)

  • The paint operations can be played back using the Recache Strokes option.

Parameters

Group

A space-separated list of points and/or point group names (see group syntax). Interactive paint strokes will only affect these points. If this is blank, the node affects all points.

You can change the group between strokes to vary what is masked. Changing this group does not affect previous strokes.

When playing back strokes, the node re-uses the stored groups. If you want playback to be geometry-independent, do not select individual points by number here.

Display Group

Visualize the unpaintable regions of the geometry in red in the viewport.

Paint on Displayed Node

Controls the geometry that is painted on. This geometry is used for brush intersection. Normally, the geometry is the input to the Attribute Paint SOP, but if you are painting on the input to a deformer, you may want to view and paint on the result of the deformation rather than on the original un-deformed geometry. To do this, turn on this option and ensure that the point numbers between the Attribute Paint SOP and the displayed SOP match.

Attribute

The attribute to paint with the next stroke. The menu of choices is taken from the attributes you set up in the Attributes tab.

Reset All Changes

Delete any changes made by this node so far.

Brush

LMB Operation

Sets the action for when you drag on the surface. You can choose different actions for , ⇧ Shift + , and ⌃ Ctrl + .

Paint FG

Sets/adds to the attribute value in the painted points with the foreground paint value. See Paint Mode for how a stroke affects the attribute values.

Smooth

Blurs together attribute values in the painted points.

This may bake the current background value of the geometry into the saved stencil, so it may not have the expected behavior if the underlying attribute is animated.

Erase

Erases changes made in this node, restoring the original attribute values.

Sample FG

Copies the raw attribute value at the clicked location into the foreground paint value.

Paint BG

Sets/adds to the attribute value in the painted points with the background paint value. See Paint Mode for how a stroke affects the attribute values.

Sample BG

Copies the raw attribute value at the clicked location into the background paint value.

MMB Operation

Sets the action for when you drag on the surface. You can choose different actions for , ⇧ Shift + , and ⌃ Ctrl + .

Paint FG

Sets/adds to the attribute value in the painted points with the foreground paint value. See Paint Mode for how a stroke affects the attribute values.

Smooth

Blurs together attribute values in the painted points.

This may bake the current background value of the geometry into the saved stencil, so it may not have the expected behavior if the underlying attribute is animated.

Erase

Erases changes made in this node, restoring the original attribute values.

Sample FG

Copies the raw attribute value at the clicked location into the foreground paint value.

Paint BG

Sets/adds to the attribute value in the painted points with the background paint value. See Paint Mode for how a stroke affects the attribute values.

Sample BG

Copies the raw attribute value at the clicked location into the background paint value.

Paint Mode

How the new value you paint interacts with any existing value. This acts component-wise for colors.

Over

Replace the old value with the new value.

Add

Add the new value to the old value.

Maximum

Use whichever is higher.

Minimum

Use whichever is lower.

Multiply

Multiply the paint color with the old value.

Shape

The shape and behavior of the brush.

Volume

Affects all points in a sphere. This will affect points whether or not they are connected topologically, so it is often paired with the Visible Only, Connected Only, or Front Face Only restrictions.

Surface

Affects all points in a circle along the surface of the geometry. The points must be connected to the main intersection point.

Screen

Affects all points in a circle in screen space. All points that would draw in that part of the screen will be affected, whether or not they are connected.

Fill

Affects all points in the geometry. The connectivity options can be used to apply this to only connected components.

Nearest Point

Affects only the nearest point to the targeted location. This is useful for making changes to low resolution geometry where it can be hard to capture a point precisely.

FG Color

For color attributes, the color to be applied on strokes.

BG Color

For color attributes, the color to be applied on strokes.

FG Float

For float attributes, the floating point value to be applied on strokes.

BG Float

For float attributes, the floating point value to be applied on strokes.

FG Integer

For integer attributes, the integer value to be applied on strokes.

BG Integer

For integer attributes, the integer value to be applied on strokes.

Radius

The radius of the brush, when Shape is set to Volume or Surface.

Spray Size

The size in pixels used by the Screen Brush.

Opacity

The opacity of the paint applied on the next stroke. An opacity value of 1 will apply the full effect of the stroke, while an opacity of 0 will have no effect.

Soft Edge

The brush is drawn with a solid core that drops off to zero. The soft edge controls the percentage of the brush that is in the drop off. A soft edge of 0 will make a hard edge, and a soft edge of 1 will have a smooth fall off from the core.

Connected Only

Only affect the points which are within the same connected component as the primary hit point.

Front Face Only

Only affect the points whose normals are facing the viewer in the same way as the primary hit point.

This provides a faster way to avoid having brushes wrap to the hidden part of the geometry. This does not work with the Surface shape.

Visible Only

Only affect the points that are visible from the viewer.

This requires sending rays to validate the points, so it can be expensive.

Visibility Bias

The amount the positions of points should be biased towards the camera before sending self-intersection rays to determine visibility.

If Visible Only is turned on, but the paint still affects points which are not visible, you may need to decrease this value to avoid skipping over collisions. If some points are being marked invisible despite being visible, they may be self-shadowed, and this number may need to be increased.

Opacity Pressure

How much the stroke pressure affects the opacity. If this is 0, the opacity will be independent of how hard you press. If this is 1, the opacity will scale to zero as the stylus pressure scales to zero.

Radius Pressure

How much the stroke pressure affects the brush radius. If this is 0, the radius will be independent of how hard you press on a tablet. If this is 1, the radius will scale to zero as the stylus pressure scales to zero.

Show Brush Path

Displays the current stroke’s path as guide geometry.

Attributes

The set of attributes to paint on. If these do not exist, they will be created. As you paint on an attribute, the effect of your painting will be cached so that it can be re-applied.

Changing these attributes after creating them will leave the old effect cached internally, and this may lead to unexpected results. For example, renaming mask to fuel after painting will not cause the painted mask to become fuel, because it stored the fact that you painted on mask. The Attribute Swap SOP is a useful tool for renaming attributes afterward.

Attribute Name

The name of the attribute. If no attribute exists, it is created. Colors are created with a default (1, 1, 1), float attributes with 0, and integer attributes with 0.

Attribute Type

The type of the attribute.

Float attribute are simple scalar attributes like mask or fuel. They are displayed with a 0-1 visualization when the painting is active.

Color attributes are three-float attributes. They will be displayed as RGB colors when the painting is active.

Integer attributes are a distinct integer value for each point. They are displayed as random colors for each integer value when painting is active. Note that integer attributes are not blended. It is assumed that they refer to named regions, so mixing does not make sense.

Symmetry

Enable Mirroring

Every brush stroke is reflected around the provided mirror and applied a second time. This allows a preservation of mirror symmetry. Note that changing this setting only affects new brush strokes.

Note

Each mouse operation is mirrored in the plane and applied, so cumulative operations like Add and Multiply may be double applied when the brush overlaps. This is especially apparent with fill modes.

Origin

The center of the mirror plane.

Direction

The normal of the mirroring plane.

Recache

Recache Method

When playing back the paint strokes when recaching or bypassing the point cache, there are several options for how to apply the stored strokes to the current geometry.

Original Values

The hit locations recorded when initially drawing the strokes will be used for playing back the strokes. This works well for volume brushes if re-applying to a point cloud that might not be collidable.

Re-Send Rays

Rays will be re-sent from the original screen locations and will intersect the current geometry. This works well if the geometry has been re-topologized but is roughly the same shape.

Primitive UV

The hit primitive and barycentric locations on that primitive will be used to update the stroke position. If the topology is unchanging, this will stick the strokes to animated geometry.

Texture UV

The uv attribute value of the original hit will be used to locate. This is useful if the model has been re-topologized and moved, but has a uv layout that has been preserved.

Recache Strokes

Reapply the strokes. This replays all the strokes on the new input geometry so it may take a long time, but it allows the transfer to new geometry with mismatched point values.

Note that if groups depended on point numbers, the resulting re-application may not work.

Save Point Cache to Hip File

Controls if the cached paint is saved to the hip file. Saving may bloat the hip file, but not saving will slow down loading, as the entire cache process has to be played back, and will risk that the behavior will not be the same.

Changes to this option will only take effect with the next recache or stroke drawn.

Bypass Point Cache

This toggle will bypass the cache of point attributes and instead reapply all the strokes from scratch. This can be useful to procedurally apply to changing point counts.

Update Point Cache on Stroke

Re-applying the strokes every time you paint will become increasingly slow and untenable for large geometry. Turning on this option will cache the changed point values so that only the latest stroke needs to be applied.

If turned off, Bypass Point Cache should be turned on, and Bypass Point Cache will not reset when new strokes are painted.

Clear Stroke History

Erases the stored cache of all the strokes drawn. After doing this, the Bypass Point Cache and Recache Strokes options will not work, as they will no longer have a record of the earlier strokes.

In cases where procedural application is not desired, this can avoid the cost of saving a long paint session.

Stroke Geometry

Hidden attribute: The complete set of strokes drawn so far.

Intersect Geometry

Hidden attribute: The geometry on which intersections are calculated. This is used to allow the painting of displayed geometry other than the output of this node. However, the displayed geometry should match point counts with this node’s input.

Active Stroke Stencil

Hidden attribute: While painting a stroke, only the most recent mouse motions are recomputed. This stores the stencil mask of the previous mouse motions to allow this optimization.

Baked Geometry

Hidden attribute: The cache of attribute value changes for each point.

Snapshot

Move Stash to New File

Saves the data parameter into a new file, updates the geometry file to point to the new file, and clears the data parameter. This will externalize the geometry and reduce the size of the .hip file at the cost of having to manage an external file.

The default name and path are controlled by the HOUDINI_STASH_DIR and HOUDINI_STASH_FILENAME environment variables.

Load Stash from File

Explicitly loads the specified geometry file and stores it in the data parameter. This internalizes the stash file. The external file could be deleted after this, as the authoritative copy is now in the data parameter.

Strokes File

File path to store the brush strokes of the paint operation.

Baked Geometry File

File path to store the result of the painting operation.

Examples

PaintingAttributes Example for Attribute Paint geometry node

This Attribute Paint examples demonstrates mirror painting, painting on a low-res surface and transferring it to a hi-res surface, and performance adjustments you can make while painting on a hi-res surface.

See also

Geometry nodes