How to increase the quality of physics for IPO baking ?

Physics APIs, Physics file formats, Maya, Max, XSI, Cinema 4D, Lightwave, Blender, thinkingParticles™ and other simulation tools, exporters and importers
3delic
Posts: 2
Joined: Sat Feb 17, 2007 2:11 pm

How to increase the quality of physics for IPO baking ?

Post by 3delic »

How to increase the quality of physics for IPO baking ?

I saw somewhere there is a steps parameter which increases the quality of simulation, but cant find the link anymore . And I didn't understood where to write the line ...

Thanks
User avatar
Erwin Coumans
Site Admin
Posts: 4221
Joined: Sun Jun 26, 2005 6:43 pm
Location: California, USA

Post by Erwin Coumans »

See http://www.continuousphysics.com/mediaw ... ysics_Tips

You probably need Blender 2.42 for this to work. Then attach a python script in the game engine, and run those lines:

Code: Select all

import PhysicsConstraints
PhysicsConstraints.setNumTimeSubSteps(2)
You can increase that number for higher quality. Also read the other Physics Tips in above link.

After 2.43 we hopefully have time to improve physics baking, with more options as buttons.

Hope this helps,
Erwin
3delic
Posts: 2
Joined: Sat Feb 17, 2007 2:11 pm

Post by 3delic »

Thanks.

Can I attach the script with a logice brick and an alway sensor ?
User avatar
Erwin Coumans
Site Admin
Posts: 4221
Joined: Sun Jun 26, 2005 6:43 pm
Location: California, USA

Post by Erwin Coumans »

I just committed the fix that enables increased simulation quality by subdividing the timestep. This should go in version 2.44 of Blender.

Code: Select all

import PhysicsConstraints 
PhysicsConstraints.setNumTimeSubSteps(2) 
You can also use higher numbers then 2 obviously.

Also the random seed used inside the simulation is now reset after simulation restart. So hopefully that makes the simulation more deterministic (one one platform).

Hope this helps,
Erwin