Tips
 
 
 

This section provides tips that can help you better use nCloth in your work.

General Maya Nucleus solver and nCloth tips

The following is a general list of pointers that can help you use the Maya Nucleus solver and nCloth.

Dynamics

  • Dynamics are always calculated in meters. If you want to use centimeters in your scene, set the Space Scale (nucleus node) to 0.01.
  • Dynamics ignores scene units, so when possible, use the default units.

Gravity

  • nCloth in a scene with a high Gravity (nucleus node) value may require a higher Stretch Resistance (nCloth node).
  • Increase Max Collision Iterations (nucleus node) to resist the effects of a high Gravity value in your scene.

Collision iterations and substeps

  • Collision iterations are related to substeps: the minimum number of collision iterations is equal to the number of substeps. Collision iterations only have an effect when the number of collision iterations is higher than the number of substeps.
  • Denser meshes require more collision iterations to solve.
  • If you set a high Stretch Resistance value on an nCloth object, with a Maya Nucleus solver that has low substeps and iterations, the simulation may not be able to resolve stretch.

Space scales

  • World space takes into account the size of objects. For example, large objects stretch more.
  • Local space handles scenes with differently sized objects well.

Performance

  • Increasing the number of Substeps (nucleus node) can, in some cases, make your simulation faster.
  • Increasing the number of iterations helps to speed up simulation when using Trapped Check (nCloth node).
  • Using Rigidity or Deform Resistance, instead of a high Bend Resistance, can improve your nCloth’s playback speed.

Constraints

  • With a Point to Surface constraint, a high Strength value causes cloth to behave like bound skin. In addition, a Tangent Strength value greater than zero is required for the Point to Surface constraint to work as a collision.
  • The Spring constraint method is more difficult to stretch as it moves farther away. In addition, the power of its recoil increases with distance.
  • You can think of weight like the relative mass on either side of the constraint link.
  • Tangent Strength and Strength, in general, determine how much influence a constraint has. Too much Tangent Strength, or Strength on a constraint can push nCloth through a surface.
  • You can use Motion Drag instead of Strength when you want to constrain one object to another in order to make the objects move together.
  • The Slide on Surface constraint is updated per frame, in contrast to the Point on Surface constraint.
  • You can use the Strength Dropoff ramp to create a suction effect within a threshold on a constraint.

Resolving sharp edges or pointy corners

  • Increase the Self Collide Width Scale (nCloth node) to improve pointy corners.
  • Use Crossover Push to correct sharp edges, and edges that are crossed by pushing points out rather than in.

Improving scrubbing/rewinding nCloth animation after caching

Once you’ve finished caching your scene and you’re happy with the results of the simulation, you can disable the nucleus node. When the nucleus node is disabled no simulation occurs, allowing you to scrub through, or rewind through the cached animation more quickly.

To disable the nucleus node, in the Attribute Editor, turn off the Enable attribute.

nCloth thickness and self-collisions

With medium density meshes, you may find that the Thickness (nClothShape node) must be set to a high value to get the self-collisions you require. However, this often leaves your nCloth object looking bloated and disproportionate.

To remedy this, you can use the Self Collide Width Scale (nClothShape node), which allows you to scale an nCloth’s input and output meshes’ Thickness without bloating the nCloth object.

Constraints with Sets and Dependency Graph loops

Typically, constraints are created using vertices on the output nCloth mesh. This is not recommended for constraints using sets. When you create a dynamic constraint with the Use Sets option (in the Create Dynamic Constraint Options window) turned on, the sets must be created on the input mesh because they affect the behavior of the output mesh. If your sets are not created on the input mesh, you may create a Dependency Graph loop.

To hide the output mesh and edit the set, select nMesh > Display Input Mesh.

To edit constraint sets, use the nConstraint > Add Members, nConstraint > Remove Members and nConstraint > Replace Members menu items.

If you prefer to use the Sets Relationship Editor, be sure to add only input mesh elements of the same type (all vertices, faces, or edges).

Constraints with Sets and constraint membership

When you create a dynamic constraint with the Use Sets option (in the Create Dynamic Constraint Options window) turned on, many more nodes and connections are created. Currently, there are no restrictions on editing the sets to maintain valid membership in the nComponent node, thus allowing for errors.

Instead of using sets, you can modify constraint membership easily with the nConstraint > Add Members, nConstraint > Remove Members and nConstraint > Replace Members menu items.

Constraints with long links

Constraints that have long links (because the objects are far apart) may cause popping because small vibrations on the constraining surface are magnified on the target surface.

If you must have long constraint links, lower your Strength and Tangent Strength (dynamicConstraintShape node) settings. Lowering these settings will provide the constraint links some slack, which prevents popping.