.. _sec-zMaterial:
zMaterial
---------
The zMaterial node is used to assign material properties to the individual tissues and cloth in the system.
The zMaterial node is used for both tissues and cloth, but many attributes only apply to one or the other.
Attributes for Both Tissue and Cloth
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+--------------------------+--------------------------------------------------------------------------------+
| Attribute | Meaning |
| | |
+==========================+================================================================================+
| **envelope** | Attenuates the blend between this material and the material values that run |
| | into this node from upstream in the graph. |
| | It can be thought of as a material value “mix”. |
+--------------------------+--------------------------------------------------------------------------------+
| **restScale** | Scales the rest-shape of the body by this factor. |
| | Setting this to values less than 1.0 causes the body to shrink. |
| | For example, setting it to 0.9 causes it to try and shrink to 0.9 times |
| | its original size. |
| | This attribute is not keyable. |
| | Combine with zCloth.restScaleEnvelope or zTissue.restScaleEnvelope |
| | (depending if the zMaterial is applied to cloth or tissue) |
| | for time-dependent restScale effects. |
+--------------------------+--------------------------------------------------------------------------------+
| **pressure** | Adds an external pressure force to the body. |
| | Positive values push the body inward, along its normal. |
| | This attribute is not keyable. |
| | Combine with zCloth.pressureEnvelope or zTissue.pressureEnvelope |
| | (depending if the zMaterial is applied to cloth or tissue) |
| | for time-dependent pressure effects. |
| | The unit is :math:`N/m^2`. |
+--------------------------+--------------------------------------------------------------------------------+
| **surfaceTension** | Adds an external surface tension force to the body's triangle mesh. |
| | Surface tension can be understood as an elastic membrane that tries to shrink |
| | every surface triangle into a point (but usually cannot due to other forces). |
| | |
| | On tissues, this tends to make the surface rounder |
| | (a similar effect to what makes water droplets spherical). |
| | When a hollow body (either a tissue or a cloth) is in contact with other |
| | objects that are positioned inside of the cavity, surface tension helps the |
| | body to envelop the interior of the object. |
| | |
| | Positive values shrink the body and negative values expand the body. |
| | This attribute is not keyable. |
| | Combine with zCloth.surfaceTensionEnvelope or zTissue.surfaceTensionEnvelope |
| | (depending if the zMaterial is applied to cloth or tissue) |
| | for time-dependent surface tension effects. |
+--------------------------+--------------------------------------------------------------------------------+
| **weights** | Used to define spatially-varying materials (either for tissues or cloth). |
| | Default weight value is 1.0. |
| | |
| | These weights, along with the envelope, |
| | act just like alpha masks in layer compositing as in Photoshop. |
| | Weights of 1.0 allow the top material to overwrite the bottom material. |
| | Weights of 0.0 do nothing and keep the lower material layer as-is. |
| | Weights of 0.5 blend equally between this material and the lower material. |
| | The first material on each tissue must have uniform weights=1, |
| | as it acts like the 'background layer'. |
| | |
| | When multiple material nodes are stacked one on top of another, their values |
| | will blend with this weight mask in a manner that is semantically similar to |
| | how one might blend images when using an "over" operation in a compositing |
| | application. This process works as follows. Suppose the user has generated N |
| | :math:`N` material nodes, let’s call them :math:`1,...,N`. |
| | Suppose the material values (Young’s modulus, mass density, etc.) |
| | at each node are :math:`m_1, …, m_N`. |
| | Suppose the user has painted weights :math:`w_1, …, w_N` for a certain tet for |
| | each node. Then, the final material value :math:`M_N` for this tet is defined |
| | recursively, in terms of :math:`M_{N-1}`, as |
| | |
| | follows: :math:`M_N = w_N * m_N + (1 - w_N) * M_{N-1}` |
| | :math:`M_1 = m_1` |
| | |
| | In other words, one first determines the final value given materials |
| | :math:`1, …, N-1`, and then blends material N with this value using the weight |
| | :math:`w_N` of material :math:`N`. |
| | |
| | In practice, two cases are most common. The first common case is :math:`N=1` |
| | where the |
| | user has painted no weights. Because the default weight values are 1.0, the |
| | final value is then simply the value set in the attribute editor for this |
| | material. The second common case is where the user generates two materials. |
| | The weights on the first material are left at default (1.0). Suppose the weight|
| | on the second material is :math:`w`. Then, the final value is: |
| | |
| | :math:`w *` second material value + :math:`(1-w) *` first material value. |
| | This makes it possible to define non-homogeneous materials, by making two |
| | materials 1, 2, and blending between them with a spatially-varying weight |
| | :math:`w`. |
| | |
| | If localized material properties are needed, the tet mesh needs enough |
| | resolution to represent this. Otherwise, the material properties will be |
| | smoothed when applied to the tet mesh. |
+--------------------------+--------------------------------------------------------------------------------+
Attributes for Tissue Only
^^^^^^^^^^^^^^^^^^^^^^^^^^
+--------------------------+-----------------------------------------------------------------------------------------+
| Attribute | Meaning |
| | |
+==========================+=========================================================================================+
| **youngsModulus** | Controls the overall stiffness of the material. The default youngsModulus is |
| | equivalent to the stiffness of human muscle. |
| | The stiffness is affected by the solver scale, so be sure to synchronize the |
| | scale of your solver to the units in Maya, unless you want to simulate |
| | “cartoon physics”. The units of this attribute are :math:`N/m^2` |
| | (Newtons divided by meters squared). |
+--------------------------+-----------------------------------------------------------------------------------------+
| **youngsModulusExp** | The power by which the value of the **“youngsModulus”** is multiplied. Given |
| | that the range of valid Young’s moduli is in practice quite large, this makes |
| | it possible to easily specify Young’s modulus values at different orders of |
| | magnitude. |
+--------------------------+-----------------------------------------------------------------------------------------+
| **poissonsRatio** | Used to maintain local volume conservation under small deformations. Poisson's |
| | Ratio will transversely bulge/shrink an element when it is compressed / |
| | stretched. This value must be between -1.0 and 0.5 (although negative values |
| | are rarely used in practice). A Poisson's Ratio close to 0.5 can cause your |
| | tissue to "lock" - meaning not be able to deform because it doesn't have enough |
| | available degrees of freedom. This attribute is dimensionless. |
+--------------------------+-----------------------------------------------------------------------------------------+
| **volumeConservation** | Controls additional material stiffness due to volume change, but ignoring any |
| | shear or other deformations. This applies to local volume changes, not just |
| | global changes as in gas-pressure models. |
| | |
| | The units of this attribute are :math:`N/m^2`, same as Young’s Modulus. |
| | Typical values |
| | for this parameter range from zero up to 1000 times the Young’s modulus, or |
| | more. |
| | |
| | Compare and contrast this to zTissue.compressionResistance which permits |
| | expansion, but is less stable. |
+--------------------------+-----------------------------------------------------------------------------------------+
| **volumeConservationExp**| The power by which the value of the **“volumeConservation”** is multiplied. |
+--------------------------+-----------------------------------------------------------------------------------------+
| **massDensity** | Defines the mass density of the material. |
| | The unit is :math:`kg/m^3` |
+--------------------------+-----------------------------------------------------------------------------------------+
Attributes for Cloth Only
^^^^^^^^^^^^^^^^^^^^^^^^^
+--------------------------+----------------------------------------------------------------------------------------+
| Attribute | Meaning |
| | |
+==========================+========================================================================================+
| **tensileStiffness** | Controls how much the cloth resists tension/compression. |
+--------------------------+----------------------------------------------------------------------------------------+
| **tensileStiffnessExp** | The power by which the value of the tensileStiffness is multiplied. |
+--------------------------+----------------------------------------------------------------------------------------+
| **shearStiffness** | Controls how much the cloth resists shearing. |
+--------------------------+----------------------------------------------------------------------------------------+
| **shearStiffnessExp** | The power by which the value of the shearStiffness is multiplied. |
+--------------------------+----------------------------------------------------------------------------------------+
| **bendStiffness** | Controls how much the cloth resists bending. |
+--------------------------+----------------------------------------------------------------------------------------+
| **bendStiffnessExp** | The power by which the value of the “bendStiffness” is multiplied. |
+--------------------------+----------------------------------------------------------------------------------------+
| **clothMassDensity** | Defines the mass density of the material. |
| | The unit is :math:`kg/m^2`. |
+--------------------------+----------------------------------------------------------------------------------------+