Using clumping

Note

This tutorial is a detailed look into what goes on at the network level. An automatic way to create the same effect is to use the Paint Clumping tool on the shelf.

Using clumping with guides

This tutorial is a continuation of Using guide hairs.

The third input on the Fur SOP is for clump geometry. In order to use clumping, the fur will need a clumporigin attribute and another Fur SOP.

Note

When using guides with clumping, each guide hair is a clump.

  1. Insert an AttribCreate node in your network and connect the Grid SOP to its input.

  2. Change the Name parameter to clumporigin, set the Type to Vector, and set a Value.

    In this example, we will set the Value parameters to: $RESTX, $RESTY, and $RESTZ.

    Note

    When animating the skin of a character, do not animate the clumporigin.

  3. Insert a Rest SOP between the Grid SOP and the two AttribCreate nodes. This eliminates the problem of fur being added and subtracted when the skin is deformed during animation.

  4. Insert another Fur SOP after the clumporigin attribute and connect it to the third input of the Fur SOP you created in Basic fur setup.

    The Fur SOP picks up attributes from the clump geometry, then guide geometry, then skin geometry (from right to left). Therefore, you must clear the * from the Skin Attributes and Guide Attributes parameters in this node, and specify only the attributes that are required for clumping.

    (If you do not clear the * from the Skin Attributes and Guide Attributes parameters, the final Fur SOP will pick up the skin and guide attributes from the clump geometry instead of the skin and guide geometry.)

  5. Wire the GUIDE_OUT node to the guide geometry input (second input) of the Fur SOP you just created.

  6. Set the Skin Attributes parameter on the Fur SOP you just created to clumporigin.

  7. Double-click the SHOP network you created in Basic fur setup, and insert a Fur Style shader.

    For better visualization of the clumps, set the Randomize Length parameter on the Shape tab to 0, and the Amplitude parameter on the Frizz tab to 0.

    Note

    The Clump parameter on the Shape tab allows you to scale the amount of clumping. For example, a value of 1 will result in fur being fully clumped, and a value of 0 will result in no clumping.

  8. Click Fur in the path at the top of the network editor to return to the geometry level.

  9. On the Fur SOP you created in Basic fur setup, set the Guide Shader to the Fur Style shader by clicking the node chooser and selecting it from the tree. Also, increase the Density to 1000, because clumping will not work if you have the same amount of fur on both fur nodes.

  10. To better visualize the clumps, set the Display Ratio to 0.1 on both fur SOP nodes. This will only display 10% of the fur density in the viewport.

When clumping is used, each hair is associated with a clump, which is determined by the Clump Radius. If a hair is not close to a clump, it will be trimmed out. You can scale the Clump Radius on the Fur SOP to determine the size of the clump.

Remember, the Fur SOP should only be used for visualization in the viewport. In order to render, it is highly recommended that you use a fur procedural shader, which will delay the generation of fur until render time. For more information on setting this up, see Basic fur setup.

Using clumping without guides

This procedure is a continuation of Basic Fur Setup, which explains how to create some basic fur.

The third input on the Fur SOP is for clump geometry. In order to clump the fur will need a clumporigin attribute and another Fur SOP.

  1. Insert an AttribCreate node in your network.

  2. Change the Name parameter to clumporigin, set the Type to Vector, and set a Value.

    In this example, we will set the Value parameters to: $RESTX, $RESTY, and $RESTZ.

  3. Insert a Rest SOP between the Grid SOP and the two AttribCreate nodes. This eliminates the problem of fur being added and subtracted when the skin is deformed during animation.

  4. Insert another Fur SOP after the clumporigin attribute and connect it to the third input of the Fur SOP you created in Basic fur setup.

  5. Set the Skin Attributes parameter on the Fur SOP you just created to clumporigin and increase the Segments to 10.

  6. Double-click the SHOP network you created in Basic fur setup, and insert a Fur Style shader.

    For better visualization of the clumps, set the Randomize Length parameter on the Shape tab to 0, and the Amplitude parameter on the Frizz tab to 0.

    Note

    The Clump parameter on the Shape tab allows you to scale the amount of clumping. For example, a value of 1 will result in fur being fully clumped, and a value of 0 will result in no clumping.

  7. Click Fur in the path at the top of the network editor to return to the geometry level.

  8. On the Fur SOP you created in Basic fur setup, set the Guide Shader to the Fur Style shader by clicking the node chooser and selecting it from the tree. Also, set the Segments to 10, and the Density to 1000. Clumping will not work if you have the same amount of fur on both fur nodes.

  9. To better visualize the clumps, set the Display Ratio to 0.1 on both Fur SOPs. This will only display 10% of the fur density in the viewport.

It is important to note that when clump is used, each hair is associated with a clump, which is determined by the Clump Radius. If a hair is not close to a clump, it will be trimmed out. You can scale the Clump Radius on the Fur SOP to determine the size of the clump.

Remember, the Fur SOP should only be used for visualization in the viewport. In order to render, it is highly recommended that you use a fur procedural shader, which will delay the generation of fur until render time. For more information on setting this up, see Basic fur setup.

Shaping the clump

You can also shape the clumps by inserting a clumpshape attribute between the two Fur SOPs. This attribute works independently of guides, so you can use it for clumping with or without guides.

The default behavior of clumping is to simply pull the fur towards the clump. Using clumpshape allows you to specify exactly how the fur looks as it is being pulled towards the clump.

Change the Name parameter to clumpshape, set the Class to Vertex, and set a Value.

In this example, we will set the first Value parameter to: pow($VTX/($NVTX - 1), 2), which will cause the hairs to be relatively straight at the base and curve toward the clump at the tip.

Note

If you are using clumping with guides, in order for this attribute to work, your line (guide hair) must have more than 2 points.