dForce - Start Here
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
- Panes (Tabs)
- Window
- Pane Group Tab Bar : Context Menu (right-click in an empty area)
- Add Pane (Tab)
- Simulation Settings
- Add Pane (Tab)
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
- dForce
- 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
- Geometry
- Create
- 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
- Geometry
- 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
- Geoemtry
- Object
- Create
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.
Comments
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:
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
...
Known Issues:
Global Properties
(Simulation Settings pane)
Environment
Environment/Advanced
Simulation/Initialization
Simulation/Duration
Simulation/Quality
Simulation/Collision
Node Properties
(Parameters pane)
General/Simulation
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.
Display/Simulation
Surface Properties
(Surfaces pane)
Simulation/Surface
Simulation/Structure
Simulation/Structure/Damping
Simulation/Collision
Simulation/Smoothing
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.