Page 1 of 2

MB_dynamicaUI - an extended Dynamica toolset

Posted: Sun Aug 29, 2010 7:45 am
by mBakr
EDIT: revised version further down the thread

UPDATE: the latest tools have been integrated into the Dynamica source and should be available in the next build (v 2.78). Documentation will *hopefully* follow soon...

All,

Attached is an extended Dynamica toolset designed for pre-shatter (voronoi) rigid body workflows. Here's a quick summary of the extended features - Build, Activate, and Bake:

- Build: Create rigid bodies of the Hull or Mesh type from an arbitrary number of source meshes - with a user specified collision margin.
- Activate: Create complex rigid body activation effects using Axis Gradients, Radial Gradients, and 3D Textures.
- Bake: Store simulations as clean optimized keyframe sequences for the next phase of production.

The attachment below contains a mel script (MB_dynamicaUI.mel) and a text file (MB_dynamicaUI_notes.txt) with installation instructions, details, and a mini-tutorial. An advanced workflow example will be available soon.

*Special thanks to user RBD for sharing tools and info

Comments are welcome :)

Screenshot:
MB_dynamicaUI_Grab.jpg
MB_dynamicaUI_Grab.jpg (50.34 KiB) Viewed 50401 times

Re: MB_dynamicaUI - an extended Dynamica toolset

Posted: Mon Aug 30, 2010 4:56 pm
by ErikJE
Will try it out. Especially custom collision margin sounds nice. At the moment everything explodes very easy.

Re: MB_dynamicaUI - an extended Dynamica toolset

Posted: Mon Aug 30, 2010 9:09 pm
by mBakr
dRigidBodies push away from each other within a collision margin of approx 0.04 units - if I remember correctly. Surface points that intersect within this range repel each other which can cause the (sometimes desired) exploding effect.

Re: MB_dynamicaUI - an extended Dynamica toolset

Posted: Tue Aug 31, 2010 8:43 pm
by Erwin Coumans
mBakr wrote: Attached is an extended Dynamica toolset designed for pre-shatter (voronoi) rigid body workflows. Here's a quick summary of the extended features - Build, Activate, and Bake:
That looks great. Can we include your contribution under the ZLib license into the latest Dynamica from http://dynamica.googlecode.com?
ErikJE wrote:Will try it out. Especially custom collision margin sounds nice. At the moment everything explodes very easy.
Could you describe how things explode exactly? There is some option called 'split impulse', it could help avoiding high velocities due to penetrations. Not sure if this option has been exposed to the GUI already.
Thanks,
Erwin

Re: MB_dynamicaUI - an extended Dynamica toolset

Posted: Wed Sep 01, 2010 9:53 pm
by mBakr
Erwin Coumans wrote: That looks great. Can we include your contribution under the ZLib license into the latest Dynamica from http://dynamica.googlecode.com?
Hi Erwin!

Sounds great. It could use a round or two of debugging/optimization, but it's more or less production ready. Are you looking for another contributor? - I have a few more features under development...

Thanks,
m

Re: MB_dynamicaUI - an extended Dynamica toolset

Posted: Thu Sep 02, 2010 9:43 pm
by ErikJE
Tried it out today. Works great.
Not having to deal with keyframing mass is great and also the bake works much better than the one in RBDTools. With RBDTools my objects that where keyframed as inactive with mass where not moving when simulating but started jiggling in the baked sim for some reason. Never had the time to investigate why.

Re: MB_dynamicaUI - an extended Dynamica toolset

Posted: Sat Sep 04, 2010 4:35 am
by mBakr
ErikJE wrote:Tried it out today. Works great.
Not having to deal with keyframing mass is great and also the bake works much better than the one in RBDTools. With RBDTools my objects that where keyframed as inactive with mass where not moving when simulating but started jiggling in the baked sim for some reason. Never had the time to investigate why.
Good news. Did you follow the included tutorial or build your own sim? If you continue to use it, post back with more comments!

I am currently working on a few additional features including a deactivation button (for easier resetting), dRigidBody deletion, activation tolerance, and a mesh cutting utility. oh ya, and a few bug fixes...;)

Re: MB_dynamicaUI - an extended Dynamica toolset

Posted: Sat Sep 04, 2010 6:39 am
by mBakr
mBakr wrote:
Erwin Coumans wrote: That looks great. Can we include your contribution under the ZLib license into the latest Dynamica from http://dynamica.googlecode.com?
Hi Erwin!

Sounds great. It could use a round or two of debugging/optimization, but it's more or less production ready. Are you looking for another contributor? - I have a few more features under development...

Thanks,
m
Erwin, I can submit as an enhancement issue for now via the googlecode page, unless there is another preferred method. When is the next planned release? I am building new features and fixes at the moment.

Re: MB_dynamicaUI - an extended Dynamica toolset

Posted: Sat Sep 04, 2010 1:23 pm
by ErikJE
mBakr wrote:
ErikJE wrote:Tried it out today. Works great.
Not having to deal with keyframing mass is great and also the bake works much better than the one in RBDTools. With RBDTools my objects that where keyframed as inactive with mass where not moving when simulating but started jiggling in the baked sim for some reason. Never had the time to investigate why.
Good news. Did you follow the included tutorial or build your own sim? If you continue to use it, post back with more comments!

I am currently working on a few additional features including a deactivation button (for easier resetting), dRigidBody deletion, activation tolerance, and a mesh cutting utility. oh ya, and a few bug fixes...;)
I like manuals, tutorials and references so i read it.

I am having some problems with the baking at the moment tho. When baking is done in the new scene it do not remove the rigidbodies and also not selected rigid bodies are still present. I use bake only selected objects.

Got any idea if i could be doing something wrong?

EDIT: Also it would be great if the build option worked on groups of objects. When there is like group -> objecttranssform -> object shape

EDIT2: Asking if to save old scene before opening baked scene would be a good thing also. Easy to lose changes otherwise.

Re: MB_dynamicaUI - an extended Dynamica toolset

Posted: Sun Sep 05, 2010 3:07 am
by mBakr
ErikJE wrote:
mBakr wrote:
ErikJE wrote:Tried it out today. Works great.
Not having to deal with keyframing mass is great and also the bake works much better than the one in RBDTools. With RBDTools my objects that where keyframed as inactive with mass where not moving when simulating but started jiggling in the baked sim for some reason. Never had the time to investigate why.
Good news. Did you follow the included tutorial or build your own sim? If you continue to use it, post back with more comments!

I am currently working on a few additional features including a deactivation button (for easier resetting), dRigidBody deletion, activation tolerance, and a mesh cutting utility. oh ya, and a few bug fixes...;)
I like manuals, tutorials and references so i read it.

I am having some problems with the baking at the moment tho. When baking is done in the new scene it do not remove the rigidbodies and also not selected rigid bodies are still present. I use bake only selected objects.

Got any idea if i could be doing something wrong?

EDIT: Also it would be great if the build option worked on groups of objects. When there is like group -> objecttranssform -> object shape

EDIT2: Asking if to save old scene before opening baked scene would be a good thing also. Easy to lose changes otherwise.
re: baking - Could you post the offending Maya scene here?

Interesting idea for the Build function - maybe an option to build from a group could be added.

Good idea about prompting to save old scene.

Keep em coming...

Re: MB_dynamicaUI - an extended Dynamica toolset

Posted: Sun Sep 05, 2010 10:21 pm
by ErikJE
mBakr wrote: re: baking - Could you post the offending Maya scene here?

Interesting idea for the Build function - maybe an option to build from a group could be added.

Good idea about prompting to save old scene.

Keep em coming...
Nevermind with the stuff not being removed, it is. Dont know what i was doing/thinking at that moment.

Another (non)problem i found is that the shapes after baking are not selectable through the viewport only through the outliner.

More small stuff is that if you move your rigid bodies with their group node in your scene that translate is not taken into consideration when simulating. So if you move all your fractured pieces up a bit it will think it collides with the plane above where the actual plane is.

Here is a broken elephant. http://www.youtube.com/watch?v=cTcES3eUU74&hd=1

Re: MB_dynamicaUI - an extended Dynamica toolset

Posted: Mon Sep 06, 2010 7:06 am
by mBakr
ErikJE wrote:
mBakr wrote: re: baking - Could you post the offending Maya scene here?

Interesting idea for the Build function - maybe an option to build from a group could be added.

Good idea about prompting to save old scene.

Keep em coming...
Nevermind with the stuff not being removed, it is. Dont know what i was doing/thinking at that moment.

Another (non)problem i found is that the shapes after baking are not selectable through the viewport only through the outliner.

More small stuff is that if you move your rigid bodies with their group node in your scene that translate is not taken into consideration when simulating. So if you move all your fractured pieces up a bit it will think it collides with the plane above where the actual plane is.

Here is a broken elephant. http://www.youtube.com/watch?v=cTcES3eUU74&hd=1
Post baking shapes remain on the display layer DynamicaMeshes - which is set to Reference mode - and are thus not selectable in the viewport. Baked dRBs should probably be moved to a new layer - "DynamicaBaked" perhaps...

transforming the group node will indeed break the sim - and many other types of transform hierarchies. The group is an organizational device - meant to keep the outliner clean.

nice elephant!

I implemented a fix to the baking issue - re not saving current scene...but it's not right yet. A new version will be available soon - perhaps tomorrow...

Re: MB_dynamicaUI - an extended Dynamica toolset

Posted: Tue Sep 07, 2010 2:53 am
by tkdmatt
Hi mBakr, really liking the toolset. I couldn't get it to work for a while, I found the rbds would snap to the origin, and I had this problem with the rbdtools too.

I found it was because I set production scenes to 25fps (I'm in a PAL region), if I set it back to 24fps it's fine, and this is a viable workaround for now. Is it possible for you to look into this?

Matt

Re: MB_dynamicaUI - an extended Dynamica toolset

Posted: Tue Sep 07, 2010 6:06 am
by mBakr
tkdmatt wrote:Hi mBakr, really liking the toolset. I couldn't get it to work for a while, I found the rbds would snap to the origin, and I had this problem with the rbdtools too.

I found it was because I set production scenes to 25fps (I'm in a PAL region), if I set it back to 24fps it's fine, and this is a viable workaround for now. Is it possible for you to look into this?

Matt
Could be something at the plugin level - not sure why framerate would affect anything. The source meshes are snapped to the origin before each dRB is assigned, and then transformed back to their original locations. This is a limitation within the plugin for which the tools compensate (when they work properly).

I will test various framerates and report back...

Glad you like the toolset, check the next post for an update.

Re: MB_dynamicaUI - an extended Dynamica toolset

Posted: Tue Sep 07, 2010 6:14 am
by mBakr
UPDATE: Bake was broken, download MB_dynamicaUI.0.9.2a.zip to fix the problem. It is attached below.

MB_dynamicaUI v0.9.2:

attached is an updated version of the toolset. It includes a reworked bake function which allows the current scene to be saved before baking, and an option to overwrite previously baked scenes (which supports iterative processing - saving memory usage etc.). A Deactivate Dynamica Rigid Bodies button is now present under the Activate tab - it will set the activateFrame to 0 - effectively disabling activation - useful if you need to "reset" the sim. It also includes a new tool: PolyCutter. PolyCutter cuts polygon meshes along a NURBS surface - you can draw a curve along a desired fault line, loft it, and run PolyCutter to slice the meshes along the NURBS surface.

Screenie:
MB_dynamicaUI_Grab2.jpg
MB_dynamicaUI_Grab2.jpg (44.38 KiB) Viewed 50251 times
PolyCutter results:
MB_dynamicaUI_Grab2a.jpg
MB_dynamicaUI_Grab2a.jpg (56.65 KiB) Viewed 50250 times