Calculate Mesh Tension

Calculates mesh tension and add it back onto input deforming mesh as primvar

Installation

To use this Node, you must enable omni.deform.tensionColor in the Extension Manager.

Inputs

Name

Type

Description

Default

frame

float

input frame

0

prim_path

string

input deforming mesh(es)

rest_prim

token

input rest mesh

Compression Color (tcolor_a)

colorf[3]

The Compression Color

[0, 0, 1]

Neutral Color (tcolor_b)

colorf[3]

The Neutral Color

[0, 1, 0]

Stretching Color (tcolor_c)

colorf[3]

The Stretching Color

[1, 0, 0]

Tension Multiplier (tcolor_m)

float

The Tension Multiplier

1.0

Tension Blur (tcolor_mean_blur)

bool

Blur tension

True

Tension Blur Count (tcolor_mean_blur_count)

int

Blur tension

1

execIn

execution

exec

Outputs

Name

Type

Description

Default

execOut

execution

exec

Example Usage

Here’s a sample tension node in action:

../../../../_images/ext_omnigraph-omni-deform-tensionColor-node-example-00-in-action.gif

In this case, blue is compression, and red is stretching.

How to Use

Enable the omni.deform.tensionColor:

../../../../_images/ext_omnigraph-omni-deform-tensionColor-node-example-00-ext-name.png

Select a rest (neutral) mesh. Then select a deforming mesh:

../../../../_images/ext_omnigraph-omni-deform-tensionColor-node-example-01-select-prims.png

Run the Animation > Deformer > Create Tension Color command:

../../../../_images/ext_omnigraph-omni-deform-tensionColor-node-example-02-command.png

The tension node with the necessary information will be created:

../../../../_images/ext_omnigraph-omni-deform-tensionColor-node-example-03-created-nodes.png

The tension node will add a primvars:omni:tensionColor primvar onto the deforming mesh:

../../../../_images/ext_omnigraph-omni-deform-tensionColor-node-example-04-primvar.png

To access the primvar in materials, add a Primvar Lookup Color node in MDL graph:

../../../../_images/ext_omnigraph-omni-deform-tensionColor-node-example-05-primvar-lookup.png

Make sure the primvar name set on the node is omni:tensionColor:

../../../../_images/ext_omnigraph-omni-deform-tensionColor-node-example-05-primvar-lookup-set.png

Then use the accessed primvar as color on materials:

../../../../_images/ext_omnigraph-omni-deform-tensionColor-node-example-06-primvar-lookup-usage.png