Houdini 20.0 Nodes Geometry nodes

Agent Layer 2.0 geometry node

Adds new shapes and layers to an agent primitive.

On this page
Since 19.0

This node adds new shapes and layers to the agent definition. A layer contains one or more shape bindings, which reference a shape from the agent’s shape library and specify the deformer that should be used (or the joint to attach a static shape to). After populating the crowd, multiple layers can be assigned to each agent to create geometry variations.

Parameters

Group

The agents to be modified.

Shapes

Add Shapes by Name

Adds new shapes to the shape library from the second input’s geometry. For every unique value of the Shape Name Attribute, a shape will be added to the shape library using the primitives that have that attribute value.

If the shape is added to a layer and the boneCapture point attribute is present, the shape binding will use the linearskinning deformer by default. If the deformSkinMethod attribute is also present (as used by the Joint Deform SOP when Skinning Method is From Input Geometry ), the shape binding will use the specified skinning method.

If the shape geometry consists of a single packed primitive and its point is weighted to a single joint (i.e. describing a rigid deformation), this will be translated into a static shape binding.

The shape geometry may also contain blend shapes in the format of the Rest Geometry input for the Character Blend Shapes SOP

Shape Name Attribute

When Add Shapes by Name is enabled, specifies the primitive string attribute used to identify primitives belonging to each shape in the second input’s geometry.

Keep External References

When new shapes are being added to the shape library, a copy will first be made so that the modifications do not affect other agents that reference the original shape library (such as those in the input SOP’s geometry). If this option is enabled and the original shape library referenced a file on disk, the new shape library will be marked as including the original shape library. In this situation, when the agent is saved to a geometry file, the path to the original shape library is saved out along with any new shapes that were not included from the original library. Otherwise, the entire shape library will be saved to the geometry file and the original shape library file is not referenced.

Bounds Scale

Specifies a multiplier for the size of the shape’s bounding box when computing the layer’s bounds. See the Agent Primitive help page for more information on how an agent’s bounding box is computed.

Bounds Scale Mode

Specifies how the bounds scale is determined for each shape binding.

Bounds Scale Attribute

Overrides or multiplies the Bounds Scale with the value of a primitive attribute on the shape geometry. This can be used to specify a per-shape bounds scale when importing multiple shapes.

Shape Deformer

Overrides the binding’s shape deformer using this deformer name.

Shape Deformer Mode

Specifies how the shape deformer is determined for each shape binding.

Shape Deformer Attribute

Overrides the binding’s shape deformer using the deformer name specified by this string primitive attribute on the shape geometry.

Transform Name

Specifies which transform in the rig to attach the shape to. This is typically only used for binding rigid shapes.

Transform Name Mode

Specifies how the transform name is determined for each shape binding.

Transform Name Attribute

Overrides the transform in the agent’s rig that the shape will be attached to, using the value of a primitive attribute on the shape geometry.

Layers

Set Current Layers

If enabled, specifies which new layers should be displayed. This is done by modifying the agents' current layers.

Set Collision Layers

If enabled, specifies which new layers should be assigned to the agents' collision layers.

Layer Name Attribute

When Add Shapes by Name is enabled, this primitive string attribute (on the second input’s geometry) is used to specify which layer the shape should be added to. This can be useful for procedurally partitioning the new shapes into layers. For example, if the Layer Name Attribute is the same as the Shape Name Attribute, a separate layer will be created for each individual shape.

Number of Layers

Specifies the number of layers to create. When Use Layer Name Attribute is enabled, these layers are merged with the layers specified by the Layer Name Attribute.

Enable

Toggles whether the layer is created.

Layer Name

Specifies the name of the new layer.

Shapes

When Add Shapes by Name is enabled, specifies which new shapes should be added to this layer. The pattern follows the same syntax as the match VEX function.

Solo Layer

When enabled, only this layer will be displayed (overriding the Set Current Layers parameter). This can be useful to quickly visualize the shapes in a specific layer.

Source Layer

If Copy Source Layer is enabled, specifies the name of an existing layer to copy shape bindings from.

Filter by Transform

Specifies a pattern of transform names. Shape bindings that are attached to these transforms will be copied from the Source Layer. The pattern follows the same syntax as the match VEX function.

Filter by Shape

Specifies a pattern of shape names. Shape bindings that use these shapes (and also match the Source Layer Bindings pattern) will be copied from the Source Layer. The pattern follows the same syntax as the match VEX function.

Shape Bindings

Specifies the number of shape bindings to create from existing shapes.

Enable

Toggles whether the shape binding is created.

Shape Name

The name of a shape in the agent’s shape library.

Inputs

Agents

Agent primitives to be modified.

Shape Geometry

Optional input providing shapes to be imported when Add Shapes by Name is enabled.

Capture Pose

Optional input providing the character’s capture pose for skin deformation. This overrides the capture data stored in the shape geometry’s boneCapture attribute.

Each joint in the skeleton is represented by a point, where the P and transform (matrix3) attributes contain the joint’s transform. The point’s name attribute contains the joint’s name, and is matched up with the capture paths in the shape geometry’s boneCapture attribute. The skeleton’s hierarchy is represented by two-point polygons between the points for each child joint and its parent.

Outputs

Agents

The modified agent primitives.

Examples

LayerVariations Example for Agent Layer geometry node

This example demonstrates how to create several layers with different geometry variations and randomly assign those layers to agents.

See also

Geometry nodes