60. Script to Quickly Add Dynamic Modifier to an Object
If you do many simulations, the sequence of menu selections to add a dForce modifier can get tiresome. Here’s a modified Daz script that allows you to do it in one step.
b. Save it to your My Daz3D Library/Scripts folder.
c. If the Script IDE pane is not already open, choose Window/Panes (Tabs)/Script IDE from the main menu.
d. Using the Script IDE menu, select File/Open Script and open the downloaded script.
e. Near the bottom of the script you will find the lines (currently around line 73 but that could change if the script is ever updated):
// Define the classname of the action we want to invoke the execution of
var sAction = "DzRestoreShapeAction";
f. Replace DzRestoreShapeAction in the last line with DzAddDForceModifierDynamicSurfaceAction
g. Do the same replacement 4 lines lower.
h. Save the modified script with a name like Add dForce Dynamic Modifier.
i. Now when you want to add a dynamic modifier, select an object in the Scene pane, execute the script, and the modifier is added.
j. To make it even easier, go to the Content Library pane, navigate to the Scripts folder, find the icon for the newly saved script, right click and choose Create CustomAction. Now instead of using the Script IDE, go to the main DS menu, choose Scripts and click on the Add dForce Dynamic Modifier item.
k. Right after doing step j, close Daz Studio. That will save the new custom action in case DS crashes. It will then be readily available every time you use DS.
60. Script to Quickly Add Dynamic Modifier to an Object
If you do many simulations, the sequence of menu selections to add a dForce modifier can get tiresome. Here’s a modified Daz script that allows you to do it in one step.
b. Save it to your My Daz3D Library/Scripts folder.
c. If the Script IDE pane is not already open, choose Window/Panes (Tabs)/Script IDE from the main menu.
d. Using the Script IDE menu, select File/Open Script and open the downloaded script.
e. Near the bottom of the script you will find the lines (currently around line 73 but that could change if the script is ever updated):
// Define the classname of the action we want to invoke the execution of
var sAction = "DzRestoreShapeAction";
f. Replace DzRestoreShapeAction in the last line with DzAddDForceModifierDynamicSurfaceAction
g. Do the same replacement 4 lines lower.
h. Save the modified script with a name like Add dForce Dynamic Modifier.
i. Now when you want to add a dynamic modifier, select an object in the Scene pane, execute the script, and the modifier is added.
j. To make it even easier, go to the Content Library pane, navigate to the Scripts folder, find the icon for the newly saved script, right click and choose Create CustomAction. Now instead of using the Script IDE, go to the main DS menu, choose Scripts and click on the Add dForce Dynamic Modifier item.
k. Right after doing step j, close Daz Studio. That will save the new custom action in case DS crashes. It will then be readily available every time you use DS.
Here is a different way to make "Add dForce Modifier: Dynamic Surface" easily accessible. This doesn't require the Script IDE or any script editing.
Go to Menu Window/Workspace/Customize, or just hit the shortcut key F3.
A dialog window will open. In the Actions pane on the left, scroll to dForce Simulation and expand it with the arrow. In the expanded list of commands, you will see "Add dForce Modifier: Dynamic Surface".
In the pane on the right, click on the ToolBars tab and expand one of the toolbars that you want to add the "Add dForce Modifier: Dynamic Surface" to (for example, the Tools menu). When deciding what ToolBar to use, select one of the ToolBars that you have enabled and visible in your workspace.
Back in the left pane, left click on "Add dForce Modifier: Dynamic Surface" and drag it to the right pane, into the list of commands in the expanded ToolBar.
Click the Accept button.
At this point, you can close and reopen Daz Studio as Rich described or save a new Workspace that you can reload later at any time (Window/Workspace/Save Layout As... or shortcut key F4).
Now "Add dForce Modifier: Dynamic Surface" will appear in your toolbar and you can click on it like any other tool.
dForce ready clothes may have a hidden weight map on one or more sections (I have found this on some myself). To find out if that is the problem, select an item of clothing that is not falling completely and add a dForce weight node:
Select the object in the scene pane.
From the DS main menu, choose Create/New dForce Modifier Weight Node. A new child weight node will appear in the Scene pane under the selected object.
Select the new weight node object, and from the Tool Settings pane, select Node Weight Map Brush in the Active Tool drop-down box.
If there is a weight map, the object in the viewport will change into a red color with some areas that can range from gray to blue to purple. If that happens, there is a weight map so do the following:
In the lower section of the Tool Settings pane, choose dForce Simulation::Influence Weights in the unused Maps drop-down box then click on the Add Map button.
To delete the influence map, right-click on the map in the lower half of the Node Weight Map Brush pane and select remove map.
I've seen maps used to hold buttons in place, so you may find that they fall out of position if you remove the map. In that case, you can hide them, or instead of removing the map, just paint over the blue areas making them moving them towards a red color.
61. dForce Menu Addition. Building upon the comment made by barbult above, I modified the main Daz Studio menu to include a personalized dForce menu. Instead of remembering the many locations and menu/submenu combinations needed for various actions, I have those I use most often in one easy to access spot.
a. Below shows the modified main menu. The dForce choice is second from the right.
b. This is the structure I set up. The first three items are so I don’t have to open the Simulation Settings pane so often, the next four consolidate several Edit and Create Menu actions, then the last three are submenus for tools I frequently use together with dForce.
EDITED 10/2019: I have a new menu structure which is shown here. The details for creating are the same as shared in this post.
The image above also shows my most often used Geometry Editor actions. The image below shows the same for the Weight Brush tool. Although I can call the Weight Brush tool from this menu, I still have to go to the Tool Settings pane once to create the map.
This last image shows the Smoothing tools. This allows quicker access then using the typical menu/submenu navigation.
c. To create a similar menu for yourself, you have to first open the Customize tool. From the main menu, choose Window/Workspace/Customize.
d. You’ll see a pop-up that looks similar to below. In the right pane at the top, click on the Word Menus.
e. Right click on Main Menu in the right hand pane and Select Add Submenu. Type dForce.
f. Drag the word dForce down to your preferred location in the main menu.
g. To populate your menu, select actions in the Left Hand Actions pane and drag and drop them onto the dForce menu item in the right pane. The most recent added action will be at the top. You can later drag it down into position. You can also add a separator or sub-menu by right-clicking on the word dForce and selecting the desired action.
h. The hardest part in constructing the menu is finding the Actions in the left hand pane. The ones I used were found in:
dForce Simulation
Geometry Assignment
Geometry Editing
Geometry Selection
Geometry Visibility
Scene Hierarchy
Simulation
Viewport Tools
Weight Map Brush
i. After adding and moving the actions into position, accept the result. The new menu structure will now be in effect. You will lose this new menu if Daz Studio were to crash, so close DS and reopen before proceeding. Alternatively, you can save your layout by choosing from the main menu Window/Workspace/Save Layout As...
As this thread has gotten longer, it's harder to navigate and use. To help, I've now added a Subject Index to the very first post. That post has:
Links to the 3 PDF sections that have been published
Table of Content (same as before - it's a sequential listing of tutorials in order of posting)
Subject Index (organized by topic, links to some tutorials appear in multiple places, it also contains links to tips other people have posted in this thread)
I'll probably continue to refine the subject index, so let me know if you have any suggestions. As time permits, I also hope to add in links to helpful tips/tutorials found in other dForce threads
Can somebody, please, post screenshot with settings for thick fabric. For example, for skater denim or leather skirt that keeps its shape.
Thank you.
P.S.: I'm very surprised and dissapointed at the same time. Why dforce is so difficult for using? Max and min values of Stretch Stiffness doesn't affect on fabric stretching (I don't see difference). Density doing nothing too. But according to the logic I have to solve my problem with only these 2 settings. Bend Stiffness you said? Well, when I set it up to "1" it explodes the cloth. I remember Cloth Room in Poser. It was not so difficult in set up sloth materials. And no explosions at all.
And the last thing about terminology. I clearly understand the name "Dinamics Strength". "1" means full dimanic "0" is absent of dinamics. I can understand (with some effort) "Stretch Stiffness". It works vice versa as for "Dinamics Strength": 1 means absent of stretch and 0 - maximum stretching. Right? But why not using "Stretch Strength" instead of "Stretch Stiffness"? That name easy to understand. And the same for "Buckling Stiffness". When I trying to understand how to use it... the name of esoteric programming language created in 1993 by Urban Müller involuntarily pops up in my head. Sorry, but the work with dforce settings is just that language name. ;)
But anyway I can understand "Buckling Strength"...
Yes, I think the plan is to offer them in the store sometime after the webinar.I sure hope so since hubby and I have to be out of town for the weekend. Otherwise I wouldn't miss it for the world!
You can use "dforce10" at checkout for a discount.
I'm going to miss the first night, but will be there for the second. Can I do that? I'm so disappointed to miss the first half but something came up unexpectedly
I'm going to miss the first night, but will be there for the second. Can I do that? I'm so disappointed to miss the first half but something came up unexpectedly
I think that is fine. I'll be going over setting up more complex scenes on the second day.
P.S.: I'm very surprised and dissapointed at the same time. Why dforce is so difficult for using? Max and min values of Stretch Stiffness doesn't affect on fabric stretching (I don't see difference).
Are you sure it is stretching you are seeing? Quite a lot of cnforming items have a fair gap between the body and the cloth, if you simulate the mesh that gap will allow the cloth to drop quite a bit (as it's effectively baggy).
Density doing nothing too. But according to the logic I have to solve my problem with only these 2 settings. Bend Stiffness you said? Well, when I set it up to "1" it explodes the cloth. I remember Cloth Room in Poser. It was not so difficult in set up sloth materials. And no explosions at all.
The stiffer the cloth the more iterations it needs per sub-frame to reach soem kind of equilibrium, if it can't then the accumulate energy of the springs will indeed blast it apart (of course some items really will be hard-going-on-impossible to get to work, but adding sub-frame iterations is something to try).
Can somebody, please, post screenshot with settings for thick fabric. For example, for skater denim or leather skirt that keeps its shape.
Thank you.
P.S.: I'm very surprised and dissapointed at the same time. Why dforce is so difficult for using? Max and min values of Stretch Stiffness doesn't affect on fabric stretching (I don't see difference). Density doing nothing too. But according to the logic I have to solve my problem with only these 2 settings. Bend Stiffness you said? Well, when I set it up to "1" it explodes the cloth. I remember Cloth Room in Poser. It was not so difficult in set up sloth materials. And no explosions at all.
And the last thing about terminology. I clearly understand the name "Dinamics Strength". "1" means full dimanic "0" is absent of dinamics. I can understand (with some effort) "Stretch Stiffness". It works vice versa as for "Dinamics Strength": 1 means absent of stretch and 0 - maximum stretching. Right? But why not using "Stretch Strength" instead of "Stretch Stiffness"? That name easy to understand. And the same for "Buckling Stiffness". When I trying to understand how to use it... the name of esoteric programming language created in 1993 by Urban Müller involuntarily pops up in my head. Sorry, but the work with dforce settings is just that language name. ;)
But anyway I can understand "Buckling Strength"...
P.P.S: Don't forget about my request. ;)
Just so happens I've been working on a skirt series that tests various combinations of surface properties to affect the drape. I won't get it done until early next week though. In the meantime, for a thicker look try a low density (start at 50, and if no explosion go to 25, 10, 5, 2). Other dForce surface parameters can stay at default.
To me, I think about all the stiffness parameters in exactly the way the word means: high stiffness means less draping (jeans are stiff, silk is not). Set one or all of them higher and you will get a stiffer look (less draping). Set them all low and things will become very draped to the point of smoothness.
The one stiffness I don't change very often is Shear Stiffness. Low values lead to a stretching of the mesh and more explosions in my experience.
Buckling ratio works just the opposite of stiffness: set it high for a close drape, set it low for a less draped look.
If you have regions with triangular faces, they will often explode or fly away if the stretch and/or bend stiffness is greater than around 0.2. You can set the whole surface to those values or use a weight map to isolate it to the triangular faces.
None of these surface properties are independent variables: changing one affects how the others work. Also scale, mesh resolution, type of face, speed of animation all have an affect. One way to learn these is to set up a scene with two vertical 50-division planes with dForce dynamic modifiers. Stick a sphere with 16 segments and 16 sides in one upper corner to hold them in place. Leave one plane with all default settings while changing the other plane surfaces one by one to see the effect. Then start doing two-by-two combinations, etc.This is one of the exercises we will be doing in my seminar today.
None of these surface properties are independent variables: changing one affects how the others work. Also scale, mesh resolution, type of face, speed of animation all have an affect. One way to learn these is to set up a scene with two vertical 50-division planes with dForce dynamic modifiers. Stick a sphere with 16 segments and 16 sides in one upper corner to hold them in place. Leave one plane with all default settings while changing the other plane surfaces one by one to see the effect. Then start doing two-by-two combinations, etc.This is one of the exercises we will be doing in my seminar today.
This is such a simple and elegant solution to test things. And this is why I am so excited about your video. That and the part about the furniture indenting. I know ther eis a lot more with this and I know this is going to take things to a whole new level for me.
None of these surface properties are independent variables: changing one affects how the others work. Also scale, mesh resolution, type of face, speed of animation all have an affect. One way to learn these is to set up a scene with two vertical 50-division planes with dForce dynamic modifiers. Stick a sphere with 16 segments and 16 sides in one upper corner to hold them in place. Leave one plane with all default settings while changing the other plane surfaces one by one to see the effect. Then start doing two-by-two combinations, etc.This is one of the exercises we will be doing in my seminar today.
This is such a simple and elegant solution to test things. And this is why I am so excited about your video. That and the part about the furniture indenting. I know ther eis a lot more with this and I know this is going to take things to a whole new level for me.
It is, I agree. I think about it like curtains: the lower setting reminds me of a sheer curtain that blows in the breeze when you have a window open. The higher setting reminds me of heavy drapery fabric that doesn't move at all. Also that thick upolstery fabric that you see on sofas.
I have limited sketchy internet this weekend since we're out of town, but a very simple tutorial way back in the beginning #14 I believe was just using a cube and sphere to make a footstool with an indent in the middlle just right for a cat of course. Amazingly simple and opens worlds when you realize you can apply that concept to many other things.
Comments
True enough.
But the other killer is perfectly razor-sharp edges, straight or not.
60. Script to Quickly Add Dynamic Modifier to an Object
If you do many simulations, the sequence of menu selections to add a dForce modifier can get tiresome. Here’s a modified Daz script that allows you to do it in one step.
a. Download the basic script from here.
b. Save it to your My Daz3D Library/Scripts folder.
c. If the Script IDE pane is not already open, choose Window/Panes (Tabs)/Script IDE from the main menu.
d. Using the Script IDE menu, select File/Open Script and open the downloaded script.
e. Near the bottom of the script you will find the lines (currently around line 73 but that could change if the script is ever updated):
// Define the classname of the action we want to invoke the execution of
var sAction = "DzRestoreShapeAction";
f. Replace DzRestoreShapeAction in the last line with DzAddDForceModifierDynamicSurfaceAction
g. Do the same replacement 4 lines lower.
h. Save the modified script with a name like Add dForce Dynamic Modifier.
i. Now when you want to add a dynamic modifier, select an object in the Scene pane, execute the script, and the modifier is added.
j. To make it even easier, go to the Content Library pane, navigate to the Scripts folder, find the icon for the newly saved script, right click and choose Create CustomAction. Now instead of using the Script IDE, go to the main DS menu, choose Scripts and click on the Add dForce Dynamic Modifier item.
k. Right after doing step j, close Daz Studio. That will save the new custom action in case DS crashes. It will then be readily available every time you use DS.
thanks Robert and namffuak, plan to keep adding to it
Here is a different way to make "Add dForce Modifier: Dynamic Surface" easily accessible. This doesn't require the Script IDE or any script editing.
Now "Add dForce Modifier: Dynamic Surface" will appear in your toolbar and you can click on it like any other tool.
that's good to know barbult! thanks for sharing the alternate method
There's usually more than one way to skin a cat, as they say. Thanks for letting me contribute to your valuable thread.
Awesome thread!
Dear very knowledgeable people...
I have been trying to use dforce to simulate discarded clothing on a bedroom floor or maybe a mattress but somehow it doesn't work.
I tried using dforce ready clothing, but that maybe half draped or stopped falling half way to the ground and I am a bit confused.
Anybody got a clever idea how to go about this?
For non-dForce clothing, results will vary depend upon how the item was made. Be sure to read these two posts in this thread:
dForce ready clothes may have a hidden weight map on one or more sections (I have found this on some myself). To find out if that is the problem, select an item of clothing that is not falling completely and add a dForce weight node:
If there is a weight map, the object in the viewport will change into a red color with some areas that can range from gray to blue to purple. If that happens, there is a weight map so do the following:
I've seen maps used to hold buttons in place, so you may find that they fall out of position if you remove the map. In that case, you can hide them, or instead of removing the map, just paint over the blue areas making them moving them towards a red color.
Thank you so much!
61. dForce Menu Addition. Building upon the comment made by barbult above, I modified the main Daz Studio menu to include a personalized dForce menu. Instead of remembering the many locations and menu/submenu combinations needed for various actions, I have those I use most often in one easy to access spot.
a. Below shows the modified main menu. The dForce choice is second from the right.
b. This is the structure I set up. The first three items are so I don’t have to open the Simulation Settings pane so often, the next four consolidate several Edit and Create Menu actions, then the last three are submenus for tools I frequently use together with dForce.
EDITED 10/2019: I have a new menu structure which is shown here. The details for creating are the same as shared in this post.
The image above also shows my most often used Geometry Editor actions. The image below shows the same for the Weight Brush tool. Although I can call the Weight Brush tool from this menu, I still have to go to the Tool Settings pane once to create the map.
This last image shows the Smoothing tools. This allows quicker access then using the typical menu/submenu navigation.
c. To create a similar menu for yourself, you have to first open the Customize tool. From the main menu, choose Window/Workspace/Customize.
d. You’ll see a pop-up that looks similar to below. In the right pane at the top, click on the Word Menus.
e. Right click on Main Menu in the right hand pane and Select Add Submenu. Type dForce.
f. Drag the word dForce down to your preferred location in the main menu.
g. To populate your menu, select actions in the Left Hand Actions pane and drag and drop them onto the dForce menu item in the right pane. The most recent added action will be at the top. You can later drag it down into position. You can also add a separator or sub-menu by right-clicking on the word dForce and selecting the desired action.
h. The hardest part in constructing the menu is finding the Actions in the left hand pane. The ones I used were found in:
i. After adding and moving the actions into position, accept the result. The new menu structure will now be in effect. You will lose this new menu if Daz Studio were to crash, so close DS and reopen before proceeding. Alternatively, you can save your layout by choosing from the main menu Window/Workspace/Save Layout As...
As this thread has gotten longer, it's harder to navigate and use. To help, I've now added a Subject Index to the very first post. That post has:
I'll probably continue to refine the subject index, so let me know if you have any suggestions. As time permits, I also hope to add in links to helpful tips/tutorials found in other dForce threads
awesome work, thank you for your efforts, Hope to make use of the info soon
We're running our dForce live webinar classes this weekend (Saturday and Sunday) - so last few hours left to register!
https://digitalartlive.com/event/powerful-dforce-discoveries-and-solutions/
You can use "dforce10" at checkout for a discount.
Hello.
Can somebody, please, post screenshot with settings for thick fabric. For example, for skater denim or leather skirt that keeps its shape.
Thank you.
P.S.: I'm very surprised and dissapointed at the same time. Why dforce is so difficult for using? Max and min values of Stretch Stiffness doesn't affect on fabric stretching (I don't see difference). Density doing nothing too. But according to the logic I have to solve my problem with only these 2 settings. Bend Stiffness you said? Well, when I set it up to "1" it explodes the cloth. I remember Cloth Room in Poser. It was not so difficult in set up sloth materials. And no explosions at all.
And the last thing about terminology. I clearly understand the name "Dinamics Strength". "1" means full dimanic "0" is absent of dinamics. I can understand (with some effort) "Stretch Stiffness". It works vice versa as for "Dinamics Strength": 1 means absent of stretch and 0 - maximum stretching. Right? But why not using "Stretch Strength" instead of "Stretch Stiffness"? That name easy to understand. And the same for "Buckling Stiffness". When I trying to understand how to use it... the name of esoteric programming language created in 1993 by Urban Müller involuntarily pops up in my head. Sorry, but the work with dforce settings is just that language name. ;)
But anyway I can understand "Buckling Strength"...
P.P.S: Don't forget about my request. ;)
I sure hope so since hubby and I have to be out of town for the weekend. Otherwise I wouldn't miss it for the world!
Oh, that's good news!! As I stated, we'll be out of town, so will look forward to purchasing them.
I'm going to miss the first night, but will be there for the second. Can I do that? I'm so disappointed to miss the first half but something came up unexpectedly
I think that is fine. I'll be going over setting up more complex scenes on the second day.
I'm not sure how long it takes to get them published but that's the plan. Then I can answer questions on this thread after you see the videos.
thanks!
Are you sure it is stretching you are seeing? Quite a lot of cnforming items have a fair gap between the body and the cloth, if you simulate the mesh that gap will allow the cloth to drop quite a bit (as it's effectively baggy).
The stiffer the cloth the more iterations it needs per sub-frame to reach soem kind of equilibrium, if it can't then the accumulate energy of the springs will indeed blast it apart (of course some items really will be hard-going-on-impossible to get to work, but adding sub-frame iterations is something to try).
Just so happens I've been working on a skirt series that tests various combinations of surface properties to affect the drape. I won't get it done until early next week though. In the meantime, for a thicker look try a low density (start at 50, and if no explosion go to 25, 10, 5, 2). Other dForce surface parameters can stay at default.
To me, I think about all the stiffness parameters in exactly the way the word means: high stiffness means less draping (jeans are stiff, silk is not). Set one or all of them higher and you will get a stiffer look (less draping). Set them all low and things will become very draped to the point of smoothness.
The one stiffness I don't change very often is Shear Stiffness. Low values lead to a stretching of the mesh and more explosions in my experience.
Buckling ratio works just the opposite of stiffness: set it high for a close drape, set it low for a less draped look.
If you have regions with triangular faces, they will often explode or fly away if the stretch and/or bend stiffness is greater than around 0.2. You can set the whole surface to those values or use a weight map to isolate it to the triangular faces.
None of these surface properties are independent variables: changing one affects how the others work. Also scale, mesh resolution, type of face, speed of animation all have an affect. One way to learn these is to set up a scene with two vertical 50-division planes with dForce dynamic modifiers. Stick a sphere with 16 segments and 16 sides in one upper corner to hold them in place. Leave one plane with all default settings while changing the other plane surfaces one by one to see the effect. Then start doing two-by-two combinations, etc.This is one of the exercises we will be doing in my seminar today.
None of these surface properties are independent variables: changing one affects how the others work. Also scale, mesh resolution, type of face, speed of animation all have an affect. One way to learn these is to set up a scene with two vertical 50-division planes with dForce dynamic modifiers. Stick a sphere with 16 segments and 16 sides in one upper corner to hold them in place. Leave one plane with all default settings while changing the other plane surfaces one by one to see the effect. Then start doing two-by-two combinations, etc.This is one of the exercises we will be doing in my seminar today.
This is such a simple and elegant solution to test things. And this is why I am so excited about your video. That and the part about the furniture indenting. I know ther eis a lot more with this and I know this is going to take things to a whole new level for me.
It is, I agree. I think about it like curtains: the lower setting reminds me of a sheer curtain that blows in the breeze when you have a window open. The higher setting reminds me of heavy drapery fabric that doesn't move at all. Also that thick upolstery fabric that you see on sofas.
Low = Blow.
I have limited sketchy internet this weekend since we're out of town, but a very simple tutorial way back in the beginning #14 I believe was just using a cube and sphere to make a footstool with an indent in the middlle just right for a cat of course. Amazingly simple and opens worlds when you realize you can apply that concept to many other things.
Thanks for answer, RGcincy.
deleted
I"m getting a message that says the webinar starts tomorrow? The email says it starts today....
That's probably for part 2, we did part 1 today
I figured it out. Was hoping to catch at least part of it but its not a big deal, I will definitely be there tomorrow. Starts at 3pm EST? Or 4?
3 PM EDT (it was showing 4 but that's not right)