Houdini 20.0 Nodes Dynamics nodes

Wire Object dynamics node

Creates a Wire Object from SOP Geometry.

On this page

The Wire Object DOP creates a Wire Object inside the DOP simulation. It creates a new object and attaches the subdata required for it to be a properly conforming Wire Object.

The SOP geometry used to define wire objects are expected to contain a set of curves. These curves may be closed curves (eg. polygons) and will be connected if multiple curves share a common point. This lets wire objects describe structures such as ropes, trees, bridges, and spider webs.

Using Wire Object

  1. Select the objects to convert to wire objects and press Enter to confirm your selection.

  2. Click the Wire Object tool from the Wires tab.

Attributes

You can create attributes on the wire object’s RestGeometry to influence its behavior. Most of these attributes allow fine-tuning of the wire by scaling values set in this node. Point, primitive, or detail attributes of the same name will be used if the vertex attributes are not present.

Name Class Type Description Scaling Factor
width Edge (vertex) Float Width of each edge. Yes
density Point Float Density of each point. Yes
orient Point Float4

Initial orientation of each point. This value is stored as a quaternion.

No
v Point Vector Initial velocity of each point. No
w Point Vector

Initial angular velocity of each point measured in radians per second.

No
friction Point Float Friction of each point. Yes
dynamicfriction Point Float Defines how much to scale the friction value when there is motion at the point of contact. Yes
klinear Edge (vertex) Float Defines how strongly the wire resists stretching. Yes
damplinear Edge (vertex) Float

Defines how strongly the wire resists oscillation due to stretching forces.

Yes
kangular Edge (vertex) Float Defines how strongly the wire resists bending. Yes
dampangular Edge (vertex) Float

Defines how strongly the wire resists oscillation due to bending forces.

Yes
targetstiffness Point Float Defines how strongly the wire resists deforming from the animated position. Yes
targetdamping Point Float Defines how strongly the wire resists oscillation relative to the animated position. Yes
normaldrag Point Float The component of drag in the directions normal to the wire. Increasing this will make the wire go along with any wind that blows normal to the wire. Yes
tangentdrag Point Float The component of drag in the direction tangent to the wire. Increasing this will make the wire go along with any wind that blows tangent to the wire. Yes
nocollide Edge (vertex) Float or Integer Collision detection for the edge is disabled if either of the points defining the edge have values greater than 0.5. This attribute is only used when the Wire Solver’s Collision Handling parameter is set to SDF. No
restP Point Vector Rest position of each point. No
restorient Point Float4 Rest orientation of each point. No
gluetoanimation Point Float or Integer Values greater than 0.5 cause a point’s position and orientation to be constrained to the input geometry. No
pintoanimation Point Float or Integer Values greater than 0.5 cause a point’s position to be constrained to the input geometry. No
animationP Point Vector Target position of each point. No
animationorient Point Float4 Target orientation of each point. No
animationv Point Vector Target velocity of each point. No
animationw Point Vector Target angular velocity of each point. No
independentcollisionallowed Point Integer A value of 0 disables the external collisions for the point. A value of 1 enables external collisions. This attribute is only used when the Wire Solver’s Collision Handling parameter is set to Local Geometric or Global Geometric. No
independentcollisionresolved Point Integer A value of 0 temporarily disables external collisions for the point, indicating that the collision was not properly resolved. This is updated each step. This attribute is only used when the Wire Solver’s Collision Handling parameter is set to Local Geometric or Global Geometric. No
codependentcollisionallowed Point Integer A value of 0 disables the soft body (objects solved by the same solver) collisions for the point. A value of 1 enables soft body collisions. This attribute is only used when the Wire Solver’s Collision Handling parameter is set to Local Geometric or Global Geometric. No
codependentcollisionresolved Point Integer A value of 0 temporarily disables soft body (objects solved by the same solver) collisions for the point, indicating that the collision was not properly resolved. This is updated each step. This attribute is only used when the Wire Solver’s Collision Handling parameter is set to Local Geometric or Global Geometric. No
selfcollisionallowed Point Integer A value of 0 disables the self collisions for the point. A value of 1 enables self collisions. This attribute is only used when the Wire Solver’s Collision Handling parameter is set to Local Geometric or Global Geometric. No
selfcollisionresolved Point Integer A value of 0 temporarily disables self collisions for the point, indicating that the collision was not properly resolved. This is updated each step. This attribute is only used when the Wire Solver’s Collision Handling parameter is set to Local Geometric or Global Geometric. No

Tip

Mass is distributed to the points of a wire object according to the width and length of each segment.

Both the Mass and Density parameters let you adjust the total mass of the object. Density is the default method, since it lets you have consistent behavior regardless of the volume of wires you give it. For example, if you make a wire twice as long, it will become twice as heavy.

Tip

The default value of 1000 is the density of water. Try a lighter value, such as 600 for hair.

Note

When the Wire Solver’s Collision Handling parameter is set to SDF, it uses an alternate method for detection and processing collisions. With this alternate method, the nocollide attribute should be used instead of selfcollisionsallowed.

Parameters

Creation Frame Specifies Simulation Frame

Determines if the creation frame refers to global Houdini frames ($F) or to simulation specific frames ($SF). The latter is affected by the offset time and scale time at the DOP network level.

Creation Frame

The frame number on which the object will be created. The object is created only when the current frame number is equal to this parameter value. This means the DOP Network must evaluate a timestep at the specified frame, or the object will not be created.

For example, if this value is set to 3.5, the Timestep parameter of the DOP Network must be changed to 1/(2*$FPS) to ensure the DOP Network has a timestep at frame 3.5.

Number of Objects

Instead of making a single object, you can create a number of identical objects. You can set each object’s parameters individually by using the $OBJID expression.

Object Name

The name for the created object. This is the name that shows up in the details view, and is used to reference this object externally.

Note

It is possible to have many objects with the same name, but this complicates writing references, so it is recommended to use something like $OBJID in the name.

Solve On Creation Frame

When turned on, newly created objects are solved by the solver on the timestep in which it was created.

This parameter is usually turned on if this node is creating objects in the middle of a simulation rather than creating objects for the initial state of the simulation.

Allow Caching

By preventing a large object from being cached, you can ensure there is enough room in the cache for the previous frames of its collision geometry.

This option should only be set when you are working with a very large sim. It is much better just to use a larger memory cache if possible.

Use Object Transform

The transform of the object containing the chosen SOP is applied to the geometry.

SOP Path

Initial State

The path to a SOP (or an Object, in which case the display SOP is used) which will be the initial pose for this simulation object.

Position

Initial position in world space of the object.

Rotation

Initial orientation of the object. This is in RX/RY/RZ format.

Pivot

Local space position around which rotation is applied.

Velocity

Initial velocity of the object.

Angular Velocity

Initial angular velocity of the object.

Geometry

Import Rest Geometry

Causes the Rest Geometry to be re-evaluated each frame.

Rest Geometry

The path to a SOP (or an Object, in which case the display SOP is used) which will be the rest geometry for this object.

Import Target Geometry

Causes the Target Geometry to be re-evaluated each frame.

Target Geometry

The path to a SOP (or an Object, in which case the display SOP is used) which will be the target geometry for this object.

Target Stiffness

This parameter defines how strongly the wire resists deforming from the animated position.

Target Damping

This parameter defines how strongly the wire resists oscillation relative to the animated position.

Material

Physical

Compute Mass

Determines if the mass will be calculated automatically from the object’s density and volume.

Density

The mass of a wire object is its volume times its density. The volume is affected by the width parameter.

Mass

The absolute mass of the object.

Width

The width of the wire object defines the diameter of each cylindrical section.

Friction

The coefficient of friction of the object. A value of 0 means the object is frictionless. This governs how much the tangential velocity is affected by collisions.

Dynamic Friction Scale

An object sliding may have a lower friction coefficient than an object at rest. This is the scale factor that relates the two. It is not a friction coefficient, but a scale between zero and one.

A value of one means that dynamic friction is equal to static friction. A scale of zero means that as soon as static friction is overcome the object acts without friction.

Elasticity

Linear Spring Constant

This parameter defines how strongly the wire resists stretching.

Linear Damping Constant

This parameter defines how strongly the wire resists oscillation due to stretch forces.

Angular Spring Constant

This parameter defines how strongly the wire resists bending.

Angular Damping Constant

This parameter defines how strongly the wire resists oscillation due to bending forces.

Adjust For Length

Enabling this parameter will adjust spring and damper strengths according to segment lengths. This allows wire flexibility behavior to be independent of segment resolution.

Adjust For Mass

Enabling this parameter will adjust spring and damper strengths according to segment masses. This allows wire flexibility behavior to be independent of mass.

Plasticity

Stretch Threshold

This parameter defines the amount of stretching allowed before the wire is permanently stretched.

Stretch Rate

This parameter defines how quickly a wire’s permanent shape becomes stretched.

Stretch Hardening

This parameter defines how a wire becomes stiffer (if greater than 1) or weaker (if less than 1) when permanently stretched.

Bend Threshold

This parameter defines the amount of bending allowed before the wire is permanently bent.

Bend Rate

This parameter defines how quickly a wire’s permanent shape becomes bent.

Bend Hardening

This parameter defines how a wire becomes stiffer (if greater than 1) or weaker (if less than 1) when permanently bent.

Fracturing

Enable Fracturing

Fracture Threshold

This is the amount of relative stretch that will cause the geometry to break up into separate parts during the simulation. For example, if the threshold is set to 0.1, then the geometry may break in places where there is more than 10% stretch compared to the rest geometry.

Collisions

Collide Independent

If enabled, the wire object will be prevented from touching or passing through any affectors that have a Volume collider label (e.g., RBD Objects or the ground plane). This can make the simulation slower.

Collide Codependent

If enabled, the wire object will be prevented from touching or passing through all of its wire affectors. This can make the simulation much slower.

Collide Self

If enabled, the wire object will be prevented from touching or passing through itself. This can make the simulation much slower.

Repulsion

A repulsion force is applied to gently push apart these pieces of geometry when the two pieces of geometry overlap (including overlap of the collision width). This parameter controls the strength of the force.

Collision Width

The width that is used to calculate whether the wire object has collided. This is scaled by the same point attributes as the width found in the Physical tab. This width acts as a diameter, creating a cylinder of this diameter between the end points of a wire segment.

When a wire object collides with a cloth object, the Cloth Thickness parameter in the cloth object will be used (it is used in the same way as described by the cloth object).

When a wire object collides with a non-wire, non-cloth object, then only the wire object will have a film around it (the polygons in the non-wire object will be treated as having a thickness of zero).

Drag

Normal Drag

The component of drag in the directions normal to the wire. Increasing this will make the wire go along with any wind that blows against it. For realistic wire-wind interaction, the Normal Drag should be chosen larger (about 10 times larger) than the tangent drag.

Tangent Drag

The component of drag in the direction tangent to the wire. Increasing this will make the wire go along with any wind that blows tangent to the wire.

External Velocity Field

The name of the external velocity fields on affectors that the wire will respond to. The default is vel, which will make the wire react to fluids and smoke when the Tangent Drag and the Normal Drag have been chosen sufficiently large. The Tangent Drag and Normal Drag forces are computed by comparing the wire’s velocity with the external velocity.

External Velocity Offset

This offset is added to any velocity that’s read from the velocity field. When there’s no velocity field, then the offset can be used to create a wind force which has constant velocity everywhere. This wind effect is more realistic and more accurate than the wind that is generated by DOP Forces.

Visualization

Width

Turn this on to visualize the wire’s collision width in the viewport.

Width Color

Penetration

Turn this on to visualize the parts of the wire object which have collided, but which did not have the collision resolved.

Penetration Color

Use this parameter to choose the color for visualizing the wire’s width in the viewport.

Force Scale

This is used to define the scale of the force lines drawn in the viewport. Use a small value if the lines are too long and distracting, and a large value if you can’t see any lines.

Torque Scale

This is used to define the scale of the torque lines drawn in the viewport. Use a small value if the lines are too long and distracting, and a large value if you can’t see any lines.

External Force

Turn this on to see external forces, applied by DOPs Force nodes (such as the Fan DOP).

External Force Color

Use this parameter to choose the color for external forces in the viewport.

External Torque

Turn this on to see external torques, applied by DOPs Force nodes (such as the Drag DOP).

External Torque Color

Use this parameter to choose the color for external torques in the viewport.

Internal Force

Turn this on to see internal forces generated by a Wire Solver to resist stretching.

Internal Force Color

Use this parameter to choose the color for internal forces in the viewport.

Internal Torque

Turn this on to see internal torques generated by a Wire Solver to resist bending.

Internal Torque Color

Use this parameter to choose the color for internal torques in the viewport.

Collision Force

Turn this on to see the force preventing collisions in the viewport. This includes wire/volume collisions, wire/wire collisions and self-collisions.

Collision Force Color

Use this parameter to choose the color for collision forces in the viewport.

Constraint Force

Turn this on to see forces generated by a Wire Solver to satisfy constraints.

Constraint Force Color

Use this parameter to choose the color for constraint forces in the viewport.

Constraint Torque

Turn this on to see torques generated by a Wire Solver to satisfy constraints.

Constraint Torque Color

Use this parameter to choose the color for constraint torques in the viewport.

Impacts

Turn this on to see impacts in the viewport. The impacts may appear in strange locations: they are shown at the position where a collision would have happened.

Impacts Scale

This is used to define the scale of the lines drawn in the viewport to show impacts.

Use a small value if the lines are too long and distracting, and a large value if you can’t see the lines.

Impacts Color

Use this parameter to choose the color for impacts in the viewport.

Show Substep Impacts

Use this to show all impacts during a DOPs step. The wire solver takes many substeps per DOPs step. If this is cleared, only the impacts for the current substep are shown.

Axis

Turn this on to see each point’s orientation.

Axis Scale

This is used to define the scale of the axis lines drawn in the viewport. Use a small value if the lines are too long and distracting, and a large value if you can’t see any lines.

X Axis Color

Use this parameter to choose the color for local x-axis.

Y Axis Color

Use this parameter to choose the color for local y-axis.

Z Axis Color

Use this parameter to choose the color for local z-axis.

Tip

There is no bounciness parameter on wires. However, an external force could be applied to mimic bounciness.

Outputs

First

The wire object created by this node is sent through the single output.

Locals

ST

The simulation time for which the node is being evaluated.

Depending on the settings of the DOP Network Offset Time and Scale Time parameters, this value may not be equal to the current Houdini time represented by the variable T.

ST is guaranteed to have a value of zero at the start of a simulation, so when testing for the first timestep of a simulation, it is best to use a test like $ST == 0, rather than $T == 0 or $FF == 1.

SF

The simulation frame (or more accurately, the simulation time step number) for which the node is being evaluated.

Depending on the settings of the DOP Network parameters, this value may not be equal to the current Houdini frame number represented by the variable F. Instead, it is equal to the simulation time (ST) divided by the simulation timestep size (TIMESTEP).

TIMESTEP

The size of a simulation timestep. This value is useful for scaling values that are expressed in units per second, but are applied on each timestep.

SFPS

The inverse of the TIMESTEP value. It is the number of timesteps per second of simulation time.

SNOBJ

The number of objects in the simulation. For nodes that create objects such as the Empty Object DOP, SNOBJ increases for each object that is evaluated.

A good way to guarantee unique object names is to use an expression like object_$SNOBJ.

NOBJ

The number of objects that are evaluated by the current node during this timestep. This value is often different from SNOBJ, as many nodes do not process all the objects in a simulation.

NOBJ may return 0 if the node does not process each object sequentially (such as the Group DOP).

OBJ

The index of the specific object being processed by the node. This value always runs from zero to NOBJ-1 in a given timestep. It does not identify the current object within the simulation like OBJID or OBJNAME; it only identifies the object’s position in the current order of processing.

This value is useful for generating a random number for each object, or simply splitting the objects into two or more groups to be processed in different ways. This value is -1 if the node does not process objects sequentially (such as the Group DOP).

OBJID

The unique identifier for the object being processed. Every object is assigned an integer value that is unique among all objects in the simulation for all time. Even if an object is deleted, its identifier is never reused. This is very useful in situations where each object needs to be treated differently, for example, to produce a unique random number for each object.

This value is also the best way to look up information on an object using the dopfield expression function.

OBJID is -1 if the node does not process objects sequentially (such as the Group DOP).

ALLOBJIDS

This string contains a space-separated list of the unique object identifiers for every object being processed by the current node.

ALLOBJNAMES

This string contains a space-separated list of the names of every object being processed by the current node.

OBJCT

The simulation time (see variable ST) at which the current object was created.

To check if an object was created on the current timestep, the expression $ST == $OBJCT should always be used.

This value is zero if the node does not process objects sequentially (such as the Group DOP).

OBJCF

The simulation frame (see variable SF) at which the current object was created. It is equivalent to using the dopsttoframe expression on the OBJCT variable.

This value is zero if the node does not process objects sequentially (such as the Group DOP).

OBJNAME

A string value containing the name of the object being processed.

Object names are not guaranteed to be unique within a simulation. However, if you name your objects carefully so that they are unique, the object name can be a much easier way to identify an object than the unique object identifier, OBJID.

The object name can also be used to treat a number of similar objects (with the same name) as a virtual group. If there are 20 objects named “myobject”, specifying strcmp($OBJNAME, "myobject") == 0 in the activation field of a DOP will cause that DOP to operate on only those 20 objects.

This value is the empty string if the node does not process objects sequentially (such as the Group DOP).

DOPNET

A string value containing the full path of the current DOP network. This value is most useful in DOP subnet digital assets where you want to know the path to the DOP network that contains the node.

Note

Most dynamics nodes have local variables with the same names as the node’s parameters. For example, in a Position DOP, you could write the expression:

$tx + 0.1

…to make the object move 0.1 units along the X axis at each timestep.

Examples

CompressedSpring Example for Wire Object dynamics node

This example demonstrates how an initial pose may be specified for a wire object.

See also

Dynamics nodes