dForce - Start Here

rbtwhizrbtwhiz Posts: 2,178
edited May 2018 in Daz Studio Discussion

What is dForce?

dForce is a physics simulation engine that is included with Daz Studio 4.10.0.x. Over time the dForce engine will continue to evolve and become capable of even more, but the first thing we are introducing with this new engine is the simulation of cloth.

With a 4.10.0.x or newer build of Daz Studio you have access to a new pane labeled "Simulation Settings." This pane is intended to be the centralized location within the User Interface (UI) for accessing the global settings on the active simulation engine (e.g., dForce). The design of this pane is intentionally very similar to that of the Render Settings pane, except that it is targeted specifically at simulation instead of rendering. The Simulation Settings pane has been added to a couple of the default layouts (e.g., City Limits, City Limits Lite), but not necessarily all of them (yet?). If you are using one of these default layouts, you can simply reapply the layout and the new pane should appear docked in one of the existing pane groups. If you are using a layout that hasn't been updated or doesn't already have the new pane docked, you can cause the pane to be displayed by clicking one of the following actions:

  • Main Menu Bar
    • Window
      • Panes (Tabs)
        • Simulation Settings
  • Pane Group Tab Bar : Context Menu (right-click in an empty area)
    • Add Pane (Tab)
      • Simulation Settings

The options menu for the Simulation Settings pane includes a few general purpose actions that provide functionality very similar to corresponding actions in the options menu for the Render Settings pane (among others) except these are targeted specifically at the active simulation engine or the Simulation Settings pane:

  • Simulation Settings : Option Menu (right-click the pane label)
    • Show Hidden Properties
    • Restore Simulation Setting Defaults
    • ---
    • Simulate
    • Clear Simulation Data

The dForce engine provides several additional actions that are specific to the way that it functions. Default layouts have been updated to include these actions in familiar menus:

  • Simulation Settings : Option Menu (right-click the pane label)
    • dForce
      • Add dForce Modifier: Static Surface
      • Add dForce Modifier: Dynamic Surface
      • Add dForce Modifier: Dynamic Surface Add-On
      • Remove dForce Modifier
      • Clear dForce Simulation from Selected Item(s)
      • Select dForce Starting Collision Veritices
  • Scene : Option Menu (right-click the pane label)
    • Create
      • New dForce Wind Node...
      • New dForce Modifier Weight Node...
    • Edit
      • Geometry
        • dForce Surface Adjuster...
        • Add dForce Modifier: Static Surface
        • Add dForce Modifier: Dynamic Surface
        • Add dForce Modifier: Dynamic Surface Add-On
        • Remove dForce Modifier
        • Clear dForce Simulation from Selected Item(s)
        • Select dForce Starting Collision Veritices
  • Main Menu Bar
    • Create
      • New dForce Wind Node...
      • New dForce Modifier Weight Node...
    • Edit
      • Object
        • Geometry
          • dForce Surface Adjuster...
          • Add dForce Modifier: Static Surface
          • Add dForce Modifier: Dynamic Surface
          • Add dForce Modifier: Dynamic Surface Add-On
          • Remove dForce Modifier
          • Clear dForce Simulation from Selected Item(s)
          • Select dForce Starting Collision Veritices
      • Figure
        • Geoemtry
          • dForce Surface Adjuster...
          • Add dForce Modifier: Static Surface
          • Add dForce Modifier: Dynamic Surface
          • Add dForce Modifier: Dynamic Surface Add-On
          • Remove dForce Modifier
          • Clear dForce Simulation from Selected Item(s)
          • Select dForce Starting Collision Veritices

 


Are there any dependencies that I need to be aware of?

Yes, there is. The dForce engine utilizes OpenCL 1.2 to perform simulations. If you do not have a driver already installed that supports at least OpenCL 1.2, you will need to install one. The more recent driver packages from NVIDIA and AMD typically include a suitable driver. In the case of older cards (e.g., GTS 250), the NVIDIA drivers do not support OpenCL 1.2 and so the driver for the CPU must be installed:

Intel GPU/CPU Driver Packages

Intel CPU-only Runtime Packages

You may want to install the CPU driver anyway if you want/need to be able to use your CPU for running simulations.

 


How do I get started?

Before we jump in with both feet and expect to start draping cloth all over everything imaginable, it is critical that you understand a few basic concepts. The first is that the dForce engine does not inherently know how to treat the various objects that may exist within a scene. The second is that each object is individually responsible for describing its role within a simulation: i.e., whether it participates as a mesh that is simulated and can be modified (a "simulated object" or "sim object"), whether it participates as a mesh that can be collided against but is not itself simulated (a "collider"), or whether it participates in the simulation at all. The third is that each "simulated object" is inherently a "collider" (meaning, it can be collided against by its own simulated mesh as well as the mesh of other simulated objects) but not all colliders are "simulated objects." Lastly, with the exception of a couple of specific types, an object must provide it's own mesh to be considered during a simulation.

To give an object the ability to be simulated, select the object and click the Add dForce Modifier: Dynamic Surface action. This will add a "dForce Modifier" to the selected objects and give them dynamic capabilities along with "Surface Simulation Settings" that control how each surface on those objects behave during the simulation (for each surface that exists on the object at the moment the action is invoked). The "dForce Modifier" adds a few properties that are displayed on the node, accessible via the Parameters pane (see Node Properties below). The "Surface Simulation Settings" are exposed as a collection of properties that are accessible from the Surfaces pane (see Surface Properties below). Global settings for the dForce engine itself can be accessed on the Simulation Settings pane (see Global Properties below).

By default, all objects in the scene that have a mesh are considered "colliders" by the engine (see Known Issues below). This can be controlled for individual objects by toggling the Visible in Simulation property on the node. Finer grained control can be accessed through an identically named property on each surface of the object (for any object that has had a "dForce Modifier" added to it).

Giving an object the ability to affect the simulation via "Surface Simulation Settings," but not be simulated itself, is accomplished by selecting the object and clicking the Add dForce Modifier: Static Surface action. This will add a "dForce Modifier" (in a disabled state) to the selected object and give all of the surfaces that exist on that object, at that moment, the properties that control how each surface participates in a simulation. If an object does not have explicit "Surface Simulation Settings" for a given surface (the default), default values will be used in their absence.

While a simulation is running, any object that has a "dForce Modifier" (and which has not been effectively disabled by the current values of the Visible in Simulation, Freeze Simulation, or Dynamics Strength properties) will be evaluated as a dynamic mesh and may collide with any (mesh) object/surface that is Visible in Simulation.

Once you have set up which objects/surfaces are simulated, which ones are colliders, which ones do not participate, and the global settings... click the Simulate button in the top-right corner of the Simulation Settings pane (or bind a shortcut to the Simulate action and press the chosen key combination).

Note: For an interactive tutorial that walks you through the basics, the Tips page in the Information Panel area at the bottom of the Simulation Settings pane provides a tip with a link that, when clicked, will launch an Interactive Lesson that guides you through the basic steps involved.

 


Can I have dynamic areas and non-dynamic areas within the same object?

Yes, you can. In addition to being able to toggle Visible in Simulation for individual surfaces via the Surfaces pane, you can also paint a weight map that controls the amount of a simulation that can be applied to each vertex of the mesh (see Known Issues below).

In order to access/enable this weight map, you first need to select the object that you want to add the map to (or access an existing map from). If the object does not already have a dForce modifier, it will need to be added (see above). With the object selected, click the Create > New dForce Modifier Weight Node... action and then click "Accept" on the dialog that appears; the default values are already configured correctly. Select the Node Weight Brush Tool and open the Tool Settings pane. On the "Weight Maps" sub-page will be a drop-down button labeled "Unused Maps :" that contains the list of maps that can be added. If it hasn't been added already, select "dForce Simulation::Influence Weights" from the list and click the "Add Map" button; the map will be flood-filled with full values on all vertices of the mesh by default. Now, with the "dForce Simulation > Influence Weights" weight map selected, use the Node Weight Brush Tool in the viewport to paint the desired weight for the vertices of the mesh (see Known Issues below). Expect to run (and clear) the simulation numerous times as you fine-tune the weight map. Once you are satisfied with the weight map, you can delete the dForce Modifier Weight Node; its only purpose is to provide access to weight maps provided by the dForce modifier.

Note: Each of the weight maps, when added, are used to attentuate (reduce) the value of a corresponding property on the surface. If a vertex on a weight map is assigned a full weight but the surface that the vertex participates in has a corresponding property that is assigned a value of zero, the vertex will behave as though it is assigned a value of zero; 100 x 0 = 0. If a vertex participates in multiple surfaces (i.e., on a surface boundary), the final value is determined by averaging the contribution from each surface it participates in.

 


Does mesh resolution affect how a simulated object will bend and fold?

Yes, it does. The way the mesh moves/folds is very closely related to the size and spacing of its faces. Larger faces (or "lower density meshes") tend toward larger folds and smaller faces (or "higher density meshes") tend toward smaller folds. The Stiffness and Buckling "Surface Simulation Settings" determine how strongly the mesh resists stretching/shearing/bending.

Take a look at the dForce Primitive Flag Test Sample Scene to help visualize this. Run the simulation and then playback the animation to get a feel for how the mesh density affects simulation.

 


Can I make anything I want dynamic, including existing rigged clothing?

Yes, you can. In fact, most (if not all) of the dForce compliant clothing items that customers will able to purchase from the Daz store will be both rigged and dynamic at the same time. The dForce engine has been built with specific consideration for this use case in mind.

That being said, it is not without additional work that these objects possess this ability. In many cases, given the way the geometry of some objects are built, simply applying a dForce modifier to an object won't (at least initially) yield the best (or even desirable) results. Many existing rigged clothing objects are simply not built with dynamics in mind; e.g., they contain what appear to be seams that are not welded, or they contain floating islands of geometry, or they are impractical designs that defy the laws of physics, and they ultimately end up dropping like a loose piece of cloth (or "exploding") when simulated.

The manner in which rigged objects are made to be dForce compliant varies depending on a case-by-case basis. In some cases refining the "Surface Simulation Settings" on the various surfaces for the object will be enough. In other cases a weight map will be used to keep certain vertices in place while other vertices are allowed to simulate freely (see above). In either case the use of "at rest" edge length morphs can be used to pre-load energy into the mesh so that it tends to behave a certain way when the simulation begins (see below).

 


How do I save my work?

With the exception of one additional preset type (i.e., Simulation Settings Preset) the information that pertains to dForce is saved in much the same way similar information in the respective area is saved; we've purposefully done a bit of work to integrate dForce into the workflows that you already know.

"Surface Simulation Settings" for a given object can be saved in Scenes, Scene Subsets, Character Presets, Wearable(s) Presets, Properties Presets, Hierarchical Material(s) Presets, Material(s) Presets, Shader Presets and Support Assets. When saved into the types of presets that do not load an object into the scene (e.g., Properties Presets, Material(s) Presets, Shader Presets, etc.), applying the preset will not add the "Surface Simulation Settings" to an object/surface that does not already have them. In order for an object/surface to load with the "Surface Simulation Settings" already available and set to specific values, the object/surface must be delivered in a form that includes the object/surface definition (e.g., Scene, Scene Subset, Wearable(s) Preset, Support Asset, etc.). (see Known Issues below)

A "dForce Modifier" for a given object can be saved in Scenes, Scene Subsets, Character Presets, Wearable(s) Presets and most preferably as Support Assets. Any weight maps that are defined for a "dForce Modifier" are saved with that modifier (which mimics, exactly, weight maps defined for skin binding and how/where they are saved). In keeping consistency with the saving of data that has not first been explicitly saved to a Support Asset, any modified data for the "dForce Modifier" will be embed in a Scene, Scene Subset, Wearable(s) Preset, Character Presets. (see Known Issues below)

The values of properties made available on the node to control the "dForce Modifier" can be saved to Properties Presets. (see Known Issues below)

The global settings found on the Simulation Settings pane can be saved to Scenes and a Simulation Settings Preset.

 

Post edited by rbtwhiz on

Comments

  • rbtwhizrbtwhiz Posts: 2,178

     

    Sample Scenes - dForce Starter Essentials:

    dForce Blocking Fan Scene

    ...

     

    dForce Primitive Flag Test

    This scene consists of several "flags" (configured primitive objects) that show the impact of several attributes at once.

    Each "flag" is a 1 meter square plane. The different colors in the flags themselves indicate a difference in mesh resolution:

    • Red = 128 divisions (16,384 facets, 16,641 vertices)
    • Yellow = 96 divisions (9,216 facets, 9,409 vertices)
    • Cyan = 64 divisions (4,096 facets, 4,225 vertices)
    • Blue = 48 divisions (2,304 facets, 2,401 vertices)
    • Purple = 32 divisions (1,024 facets, 1,089 vertices)
    • Magenta = 16 divisions (256 facets, 289 vertices)

    The center column, along the Z axis, each have the same Surface Simulation Settings; the only difference is mesh resolution. Within a given row, along the X axis of a given mesh resolution, are variations on Buckling Stiffness and Buckling Ratio. The grayscale value of each "pole" indicates whether the corresponding flag's Buckling Stiffness is Hi (light) or Lo (dark). The grayscale value of each "ball" indicates whether the corresponding flag's Buckling Ratio is Hi (light) or Lo (dark).

    The 4 blue flags off to the side are used to show the effect of Density (GSM) in combination with buckling; the two in front each having a low Density, and the two behind having a high Density.

     

    dForce Simple Sheet Drop

    ...

  • rbtwhizrbtwhiz Posts: 2,178
    edited May 2018

    Known Issues:

    • Geometry
      • Instances and/or Instance Groups do not have their own geometry and so are not considered collision objects.
    • Surfaces
      • The only values for the Simulation > Structure > Dynamics Strength property on a surface and the "dForce Simulation::Influence Weights" weight map that we are confident will continue to mean the same thing are 0 (0%) and 1 (100%); the meaning of every other value between 0 and 1 is subject to change.
      • The Simulation > Collision > Collision Layer property on a surface currently only works between separate objects when the Simulation > Collision > Collision Mode property on the Simulation Settings pane is set to "Good - Discrete : Swept Vertex". When the Collision Mode property is set to either of the "CCD" options (e.g., Better or Best), the Collision Layer property has no effect.
    • Animation
      • aniMate and aniBlocks do not use the scene timeline in quite the same way as everything else. As such, aniBlocks need to be baked to the timeline in order to be used in a dForce simulation.
    • Saving
      • "Surface Simulation Settings" are not saved to Character Presets.
      • "Surface Simulation Settings" for the target figure are not saved to Wearable(s) Presets.
      • A "dForce Modifier" is not saved to Character Presets.

     

    Post edited by rbtwhiz on
  • rbtwhizrbtwhiz Posts: 2,178

    Global Properties

    (Simulation Settings pane)

     

    Environment

    • Gravity
      • Type: Float
      • Default Value: 1.0
      • Default Range: [-2.0, 2.0]
      • Notes:
        • Describes the natural phenomenon by which simulated objects are drawn to other objects (e.g., an apple “falling” toward Earth)
        • A value of 1 .0 approximates the force of gravity typically experienced on Earth; i.e., 9.807 m/s^2, or 490.335 cm/s^2
        • Values < 0.0 will produce “anti-gravity” effects
        • Values > 1.0 can yield deliberately heavy, fast moving results
    • Air Resistance
      • Type: Float
      • Default Value: 0.15
      • Default Range: [0, 1]
      • Notes:
        • Describes the amount of resistance a simulated object has to the density of air in the atmosphere
        • Loosely based on pressure per square meter, where 1.0 approximates the conditions on Earth at sea level
        • At lower and near-zero values, materials will move as if in a vacuum, governed largely by gravity and their inertial forces
        • At higher values, materials will move more slowly relative to their Mass
        • Higher values can be used to achieve broader clothing folds and more pronounced billowing behaviors

    Environment/Advanced

    • Velocity Limit
      • Type: Float
      • Default Value: 32.2
      • Default Range: Limitless
      • Notes:
        • Hidden
        • Damping should typically prevent vertices from achieving too much velocity, making this parameter a failsafe.

    Simulation/Initialization

    • Initialization Time
      • Type: Float
      • Default Value: 0.0
      • Default Range: [0.0, 10.0]
      • Notes:
        • Describes the number of seconds to allow the mesh to equalize (the point at which it would naturally rest) at the start of each simulation
        • The number of frames (seconds * FPS) required for a mesh to achieve its resting position is affected by the resolution of the mesh
        • Provides the mesh time to find this resting position before outputting final results to an animation
    • Start Bones From Memorized Pose
      • Type: Bool
      • Default Value: true
      • Notes:
        • Describes whether or not the simulation should start from the “memorized pose” of articulated objects (i.e., figures) in order to address cases where complex poses adversely affect the starting shape of the simulated object such that it will not provide realistic results when simulated
        • When enabled, articulated objects that are participating in the simulation will begin in their respective default poses and gradually move into their respective target poses, allowing the simulation to better represent the original dimensions of the simulated object
    • Pose Transition Time
      • Type: Float
      • Default Value: 1.0
      • Default Range: Limitless; uses absolute (unsigned) value
      • Notes:
        • Dynamically Hidden; shown when “Start Bones From Memorized Pose” is true
        • Describes the number of frames (seconds * FPS) through which the bones of a figure will transition when “Start Bones From Memorized Pose” is enabled

    Simulation/Duration

    • Frame(s) to Simulate
      • Type: Enum
      • Default Value: 0 ("Current Frame")
      • Enumerated Values:
        • 0 - "Current Frame"
        • 1 - "Animated (Use Timeline Play Range)"
        • 2 - "Animated (Custom)"
    • Stabilization Time
      • Type: Float
      • Default Value: 1.0
      • Default Range: Limitless; uses absolute (unsigned) value
      • Notes:
        • Dynamically Hidden; shown when Frame(s) to Simulate is “Current Frame”
        • Describes the number of frames (seconds * FPS), beyond the "Frame(s) to Simulate", to continue simulating
    • Start / End Frame
      • Type: Int2
      • Default Value: 0 / 30
      • Default Range: Limitless; uses absolute (unsigned) value
      • Notes:
        • Dynamically Hidden; shown when Frame(s) to Simulate is “Animated (Custom)”

    Simulation/Quality

    • Frames Per Second (FPS) Multiplier
      • Type: Int
      • Default Value: 2
      • Default Range: Limitless; uses absolute (unsigned) value
      • Notes:
        • Causes simulation to be calculated at a higher frame rate than the animation/scene frame rate
    • Subframes
      • Type: Int
      • Default Value: 8
      • Default Range: Limitless
      • Notes:
        • Describes the number of times a scene will be updated and collision will be attempted within each frame of animation
        • Lower values can greatly improve simulation speed
        • Higher values can improve animation collisions as well as overall result quality
        • Recommended values are within the [4, 16] range; although higher/lower values are possible, they may not provide optimal results
    • Iterations (Per Subframe)
      • Type: Int
      • Default Value: 32
      • Default Range: Limitless
      • Notes:
        • Describes the number of times a simulation kernel is executed per subframe.
        • Describes the number of times during each Subframe that connections between mesh vertices will be calculated
        • Lower values can improve simulation performance
        • Higher values will improve shape retention and prevent surfaces from sagging
        • Higher polygon-count items will typically require a higher number of iterations to fully resolve their shape
        • Recommended values are within the [8, 32] range
        • Higher values may produce improved results in very high polygon-count items, though will not be required for most items
        • Affected by Subframe; the number of iterations calculated each frame is Subframes x Iterations

    Simulation/Collision

    • Collision Mesh Resolution
      • Type: Enum
      • Default Value: 0 ("Base")
      • Enumerated Values:
        • 0 - "Base"
          • For non-SubDivision meshes, this value and the "Viewport" value are synonymous
          • For SubDivision meshes, this represents the "Cage" mesh
        • 1 - "Viewport"
          • For non-SubDivision meshes, this value and the "Base" value are synonymous
          • For SubDivision meshes, "Viewport" uses whatever mesh is displayed in the viewport as a result of the value for "View SubD Level" property on the node being collided against
      • Notes:
        • Describes the mesh resolution of the objects being collided against
    • Collision Mode
      • Type: Enum
      • Default Value: 1 ("Better - Continuous : CCD Vertex-Face")
      • Enumerated Values:
        • 0 - "Best - Continuous : CCD"
          • Performs a continuous vertex to face check of the dynamic vertices against each (visible in simulation) face for each dynamic vertex in a triangle (3), performs a continuous (visible in simulation) face to dynamic vertex check for each dynamic vertex in a triangle (3), and performs additional edge to edge checks (9 - each edge of one face to each edge of the other face)
          • Typically slower than CCD Vertex-Face and Swept Vertex (it is doing significantly more work)
          • Most accurate (detects collisions that CCD Vertex-Face is intentionally skipping and Swept Vertex is incapable of)
        • 1 - "Better - Continuous : CCD Vertex-Face"
          • Performs a continuous vertex to face check of the dynamic vertices against each (visible in simulation) face for each dynamic vertex in a triangle (3) and performs a continuous (visible in simulation) face to dynamic vertex check for each dynamic vertex in a triangle (3)
          • Typically faster than full CCD (roughly ~1/2 the time), but slower than Swept Vertex (it is doing significantly more work)
          • More accurate than Swept Vertex, but less accurate than full CCD (detects collisions that Swept Vertex is incapable of and skips the edge to edge checks that are present in full CCD)
        • 2 - "Good - Discrete : Swept Vertex"
          • Performs a discrete vertex to face check for each dynamic vertex in a triangle (3) against each face that is visible in the simulation
          • Performs a discrete check from one perspective of a potential collision; given the position of a dynamic vertex (a vertex that is moving) at the current time, this option creates an imaginary "line" (vector) between that position and the position of the vertex at the previous time (the "timestep") and then checks if said line intersects a given facet at the end of the timestep
          • Typically faster than CCD Vertex-Face and full CCD (it is doing significantly less work)
          • Least accurate (incapable of detecting collisions that CCD does/can)
    • Collision Iterations (Per Subframe)
      • Type: Int
      • Default Value: 4
      • Default Range: Limitless
      • Notes:
        • Describes the number of times during each Subframe that items will be checked for collision
        • Typically only 1 collision iteration is required
        • Higher values can improve self-collision performance but are not required for most item

     

  • rbtwhizrbtwhiz Posts: 2,178
    edited October 2017

    Node Properties

    (Parameters pane)

     

    General/Simulation

    • Simulation Object Type
      • Type: Enum
      • Default Value: 0 ("Static Surface")
      • Enumerated Values:
        • 0 - "Static Surface"
          • Causes the geometry of "this" object to be seen by the engine as non-simulating; the engine will not cause "this" mesh to deform
          • Enables Surface Properties that control how simulated objects in the scene see the surface(s) of "this" object; properties such as Visible in Simulation, Friction, Collision Layer and Collision Offset
          • The surface of "this" object is considered during collision detection of simulated objects unless Visible in Simulation is disabled
        • 1 - "Dynamic Surface"
          • Causes the geometry of "this" object to be seen by the engine as simulating unless Visible in Simulation is disabled; the engine can cause "this" mesh to deform as though it is a network of interconnected springs; a spring-mass system
          • In addition to the properties that control how simulated objects in the scene see the surface(s) of "this" object, this type enables properties that control how the structure of each surface on "this" object is impacted by forces of physics
          • The surface of "this" object is considered during collision detection unless Visible in Simulation is disabled
        • 2 - "Dynamic Surface Add-On"
          • Objects of this type have all of the same qualities as a Dynamic Surface, with the exception that its faces do not participate in collision (but its vertices do), its faces are not wind blocking, and it has the ability to attach/graft/weld to a Dynamic Surface object
          • The purpose of this type is to provide "scaffolding" (additional springs) that supports the Dynamic Surface object it is parented to
          • The vertices of "this" object that coincide with the vertices of the object it is supporting (parented to), in their respective base shapes, is where the "scaffolding" attaches/grafts/welds
          • The mesh should be whatever network of springs (polygons/edges) supports the object that it is an Add-On for, in whatever way it should support it; the mesh can be as simple or as complex as you like, so long as you realize that you are defining a network of springs; if the structure of the springs and their respective surface settings are such that they hold their shape, so too will they help hold the shape of the object they are attached to, at the point(s) in which they are attached
      • Notes:
        • ...
    • Simulation Base Shape
      • Type: Enum
      • Default Value: 0 ("Use Simulation Start Frame")
      • Enumerated Values:
        • 0 - "Use Simulation Start Frame"
          • Causes either the current frame (when Simulation Settings : Simulation > Duration > "Frames To Simulate" is set to "Current Frame"), or the first frame of the simulated range (when Simulation Settings : Simulation > Duration > "Frames To Simulate" is set to "Animated (Use Timeline Play Range)" or "Animated (Custom)") to be used for defining edge rest lengths
        • 1 - "Use Scene Frame 0"
          • Causes the very first frame on the timeline, frame 0, to be used for defining edge rest lengths
        • 2 - "Use Shape from Simulation Start Frame"
          • The same as the "Use Simulation Start Frame" option, but with the additions described in the notes below
        • 3 - "Use Shape from Scene Frame 0"
          • The same as the "Use Scene Frame 0" option, but with the additions described in the notes below
      • Notes:
        • Describes which frame to use for determining the "at rest" edge length (the length of an edge in it's completely at rest state) for each edge of the mesh being simulated
        • The "Use Shape from ..." options:

          • These options use the names of morphs on the object and their respective types such that if the object has a morph that has been assigned the "Modifier/Simulation/Base" type and its name matches the pattern "SimulationBase_[ObjectSelfName]", it is the morph/ERC-driven-pose that defines the "at rest" edge lengths (the size that each edge wants to return to) when the object is not fit to a figure (this also works to set the "at rest" edge lengths for a prop, which has no ability to be "fit to" anything).

          • If the object is one that is fit to another figure and the object has a morph that is assigned the "Modifier/Simulation/Base" type and that morph's name matches the pattern "SimulationBase_[FitToFigureName]", then that morph/ERC-driven-pose becomes the one used to establish "at rest" edge lengths; this allows an object to have custom "at rest" edge lengths (sizes) for different figures. If no morph that matches this criteria is found, but the "SimulationBase_[ObjectSelfName]" morph is found, it will serve as the fallback.

          • For any morphs on the object that are projected from the figure that the object is fit to, if the object has a morph that has been assigned the "Modifier/Simulation/Shape" type and that morph's name matches the pattern "SimulationShape_[MorphName]", that morph will be combined with the "SimulationBase_" morph to establish the "at rest" edge lengths.

    • Freeze Simulation
      • Type: Bool
      • Default Value: false
      • Notes:
        • Describes whether or not the mesh associated with the node participates in the simulation as a simulated mesh
        • Can be used to temporarily cause a simulated object to behave as a collision object

     

    Display/Simulation

    • Visible in Simulation
      • Type: Bool
      • Default Value: true
      • Notes:
        • Describes whether or not the mesh associated with the node is considered by the engine during the simulation (at all - even as a collision object)
    Post edited by rbtwhiz on
  • rbtwhizrbtwhiz Posts: 2,178
    edited May 2018

    Surface Properties

    (Surfaces pane)

     

    Simulation/Surface

    • Visible in Simulation
      • Type: Bool
      • Default Value: true
      • Notes:
        • Describes whether or not the mesh associated with the surface is considered by the engine during the simulation
        • Dynamically hides/shows all other Simulation properties
    • Friction
      • Type: Float
      • Default Value: 0.4
      • Default Range: [0.001, 0.999]
      • Notes:
        • Describes the resistance that one surface encounters when moving across another
          • Inherently involves two (2) surfaces
          • Each surface describes its own contribution
          • Total friction between two surfaces is calculated as the average of both surfaces (this is an approximation, it is not physically correct)
        • Lower values allow vertices to move more freely, approximating “slick” materials like silk and satin
        • Higher values approximate materials which tend to slide less along the body, such as leather and denim

    Simulation/Structure

    • Dynamics Strength (see Known Issues)
      • Type: Float
      • Default Value: 1.0
      • Default Range: [0.0, 1.0]
      • Notes:
        • Describes the amount of deviation (relative to the unsimulated mesh) that a vertex is allowed
        • A value of 1.0 allows vertices to move freely as a result of simulation forces
        • A value of 0.0 prevents vertices from moving away from their unsimulated positions
        • Useful for keeping a surface in-place while still permitting it to respond to the simulation
        • Recommended that fabrics be set to 1.0, while attached accessories such as belts, buckles, and buttons may provide better results at interim values
        • The Influence Weights map provides the ability to attenuate (reduce via multiplication) the effect that this property has on specific verticies of the mesh
    • Stretch Stiffness
      • Type: Float
      • Default Value: 0.8
      • Default Range: [0.01, 1.0]
      • Notes:
        • Describes the strength of a connection between each vertex in a mesh and the immediate neighboring vertices that the vertex shares an edge with (see image below)
        • Controls the amount of resistance to extension of an edge that is directly connected to a given vertex
        • The higher the value, the less a mesh will stretch in response to forces
        • Lower values, in combination with the Contraction-Expansion Ratio parameter, can be used to approximate “stretchy” materials such as elastic waistbands and spandex fabrics
        • Depends on the value of the global “Iterations” property; a higher number of iterations will result in firmer, stiffer materials
        • The Stetch Stiffness Weights map provides the ability to attenuate (reduce via multiplication) the effect that this property has on specific verticies of the mesh
    • Shear Stiffness (Quads)
      • Type: Float
      • Default Value: 0.2
      • Default Range: [0.01, 1.0]
      • Notes:
        • Describes the strength of an imaginary connection between each vertex in a mesh and the immediate neighboring vertices that the vertex does not share an edge with (see image below)
        • Controls the amount of resistance to lateral shifting and twisting of a given quadrangle
        • Only has an impact on quadrangles within a given mesh; has no impact on triangles (it would be redundant with Stretch Stiffness)
        • The Shear Stiffness Weights map provides the ability to attenuate (reduce via multiplication) the effect that this property has on specific verticies of the mesh
    • Bend Stiffness
      • Type: Float
      • Default Value: 0.5
      • Default Range: [0.01, 1.0]
      • Notes:
        • Describes the strength of an imaginary connection between each vertex in a mesh and the neighboring vertices of immediate neighbors that the vertex shares an edge with (see image below)
        • Controls the amount of resistance to extension of the imaginary connection described above
        • Higher values will result in broader folds and shapes which adhere more closely to their initial form
        • Lower values approximate thin and flexible materials which are able to change more dramatically from their initial shape
        • Depends on the value of the global “Iterations” property; a higher number of iterations will result in firmer, stiffer materials
        • The Bend Stiffness Weights map provides the ability to attenuate (reduce via multiplication) the effect that this property has on specific verticies of the mesh
    • Buckling Stiffness
      • Type: Float
      • Default Value: 0.05 (5%)
      • Default Range: [0.0, 1.0]
      • Notes:
        • Describes the amount of Bend Stiffness to use for resisting compression of the imaginary connection between each vertex in a mesh and neighboring vertices of immediate neighbors that the vertex shares an edge with (see image below)
        • Controls the amount of resistance to compression of the imaginary connection described above
        • The Buckling Stiffness Weights map provides the ability to attenuate (reduce via multiplication) the effect that this property has on specific verticies of the mesh
    • Buckling Ratio
      • Type: Float
      • Default Value: 0.7 (70%)
      • Default Range: [0.0, 1.0]
      • Notes:
        • Higher values result in materials that bend easily; e.g., silk
        • Lower values result in materials that attempt to maintain their initial form; e.g., denim
        • The Buckling Ratio Weights map provides the ability to attenuate (reduce via multiplication) the effect that this property has on specific verticies of the mesh
    • Density (GSM)
      • Type: Float
      • Default Value: 180.0
      • Default Range: Limitless
      • Notes:
        • Describes the weight (grams per square meter) for the associated mesh
          • Lightweight fabric (e.g., chiffon, linen, cheesecloth, lace, mesh, etc) is typically between 30-150 GSM
          • Medium weight fabric (e.g., sateen, oxford, velvet, taffeta, etc) is typically between 150-350 GSM
          • Heavyweight fabric (e.g., upholstery fabric, canvas, brocade, poplin, denim, etc) is typically 350+ GSM
        • Higher values will be less affected by air resistance and will impart more force onto collided and connected surfaces
        • The Mass Density Weights map provides the ability to attenuate (reduce via multiplication) the effect that this property has on specific verticies of the mesh
    • Contraction-Expansion Ratio
      • Type: Float
      • Default Value: 1.0
      • Default Range: [0.00001, 2.0]
      • Notes:
        • Describes the ratio that governs whether the edge rest lengths are biased toward contracting or expanding
        • > 1.0 will cause the associated mesh to expand/grow
        • < 1.0 will cause the associated mesh to contract/shrink
        • Values < 1.0 can approximate very form-fitting clothing; applying a value < 1.0 to a waistband or shirt cuff can cause that material to cinch around a figure more tightly
        • When combined with lower Stretch Stiffness, Shear Stiffness and Bend Stiffness values, lower values of this parameter can approximate spandex and other stretchy materials
        • Lowering this value a bit below 1.0 can greatly improve shape retention and reduce stretch in high polygon-count clothing, especially at lower Iteration counts

    Simulation/Structure/Damping

    • Damping
      • Type: Float
      • Default Value: 0.1
      • Default Range: [0.0, 1.0]
      • Notes:
        • Used to reduce/prevent unwanted chaotic motion/oscillation (rabid wobbling of two vertices toward/away from each other) in all springs of a surface
        • Higher values can "calm" the motion of vertices during simulation, at the potential cost of realism
        • Scales the values of Stretch Damping, Shear Damping and Bend Damping
    • Stretch Damping
      • Type: Float
      • Default Value: 0.1
      • Default Range: [0.0, 1.0]
      • Notes:
        • Used to reduce/prevent unwanted chaotic motion/oscillation in the direction of Stretch springs
        • Scaled by the value of Damping
    • Shear Damping
      • Type: Float
      • Default Value: 0.1
      • Default Range: [0.0, 1.0]
      • Notes:
        • Used to reduce/prevent unwanted chaotic motion/oscillation in the direction of Shear springs
        • Scaled by the value of Damping
    • Bend Damping
      • Type: Float
      • Default Value: 0.1
      • Default Range: [0.0, 1.0]
      • Notes:
        • Used to reduce/prevent unwanted chaotic motion/oscillation in the direction of Bend springs
        • Scaled by the value of Damping

    Simulation/Collision

    • Collision Layer (see Known Issues)
      • Type: Int
      • Default Value: 0
      • Default Range: [0, 100]
      • Notes:
        • Describes an ordering of surfaces for the purpose of collision detection, whereby a surface assigned to a layer with a higher value collides with the outside of surfaces assigned to a layer with a lower value, where a surface assigned to a layer with a lower value collides with the inside of surfaces assigned to a layer with a higher value, and where surfaces assigned to a layer with the same value collide with both the inside and outside of surfaces assigned to a layer with the same value
        • In cases that involve clothing colliding with a figure, the figure should typically be assigned to the lowest value in the stack (i.e., 0, default) and the value assigned to clothing items should increase as the distance from the body increases
    • Collide (for testing purposes only)
      • Type: Bool
      • Default Value: true
      • Notes:
        • Hidden
        • Controls whether or not the surface will be evaluated for collisions
    • Self Collide
      • Type: Bool
      • Default Value: true
      • Notes:
        • Dynamically hidden/shown based on value of "Collide"
        • Controls whether or not the surface will be evaluated for collisions within the same surface
    • Collision Offset
      • Type: Float
      • Default Value: 0.2
      • Default Range: Limitless
      • Notes:
        • Dynamically hidden/shown based on value of "Collide"
        • Describes the distance (in centimeters) that separates a simulated vertex and a collider
        • For example, a value of 0.5 will cause a clothing item to sit one half of a centimeter away from a figure
        • Lower values can produce more form-fitting results
        • Higher values can help prevent clipping between objects

    Simulation/Smoothing

    • Velocity Smoothing
      • Type: Float
      • Default Value: 0.0
      • Default Range: [0.0, 1.0]
      • Notes:
        • Applies Laplacian smoothing to velocity vectors of each vertex that participates in the facets assigned to the surface
        • The range of this property represents the difference between the simulated velocity vector for a given vertex at the start of each subframe (0.0) and the smoothed velocity vector (1.0)
        • The Velocity Smoothing Weights map provides the ability to attenuate (reduce via multiplication) the effect that this property has on specific verticies of the mesh
    • Velocity Smoothing Iterations
      • Type: Int
      • Default Value: 0
      • Default Range: [0, 5]
      • Notes:
        • Specifies how many iterations of the Laplacian smoothing algorithm to perform
        • Smoothing operations are performed at the start of each collision iteration; so that the collision operation can attempt to correct any issues that are created by smoothing

     

    Springs.png
    771 x 408 - 23K
    Post edited by rbtwhiz on
  • rbtwhizrbtwhiz Posts: 2,178

    Simulation Pipeline : Event Timing / Global Property Relationships

     

    Below is a high-level view of events in the simulation pipeline. Integrated within it is a view of the hierarchical relationships between global simulation properties and the downstream impact they each have.

    • Simulation Time/Frames - The total number of frames to simulate is determined by a combination of the Frame(s) To Simulate property and either the playhead displayed on the Timeline pane, the play-range displayed on the Timeline pane, or the Start/End Frame property depending on the current value. The events/relationships described below also exist for each span of time described by the Initialization Time, Pose Transition Time, and Stabilization Time properties when they are visible/enabled.
      • Scene/Animation FPS - This value is set using the FPS field on the Timeline pane. It describes the frame rate (the number of frames within 1 second) for animations/renders. With regard to the simulation pipeline, it also determines the rate that simulation data will be sampled and recorded to the dForce modifier.
        • Frames Per Second (FPS) Multiplier - (see property description above)
          • For each frame in the Simulation Time/Frames described above:
            • Create a snapshot of the scene vertex positions
            • Split the frame into Subframes (smaller divisions of time)
            • For each Subframe:
              • Interpolate between adjacent snapshots of scene vertex positions
              • Perform n simulation iterations; where n = Iterations (Per Subframe)
              • Perform n collision iterations; where n = Collision Iterations (Per Subframe)
                • At the start of each collision iteration:
                  • Perform n smoothing iterations; where n = Velocity Smoothing Iterations (per surface)
                  • Perform collision detection/correction
This discussion has been closed.