Volumes Of Fun

Page 1 of 1

Author:  pheres [ Thu Dec 02, 2010 12:41 pm ]
Post subject:  Physics

I was trying to link the voxel world with Bullet Physics.
My first approach was to load the extracted meshes to Bullet. This looks nice until I activate the physics on my character.
It becomes so slow that I can't even move.
I thought this would be a problem for bullet. Surely it doesn't test for collision with all meshes, right?
I have a polyvox world of 256x256 with regions of 64x64.

I tried to look in Thermite source code for the physics, since I read somewhere it was using bullet as well, but I wasn't able to find out anything.

Just wondering if this is the right approach? (loading all the meshes into bullet world)


Author:  pheres [ Thu Dec 02, 2010 5:44 pm ]
Post subject:  Re: Physics

I found the problem :oops:

First the conclusion:
It's better to have bigger meshes instead of many small ones.

And my problem was that my character capsule was huge and lead to too many contact points. :oops:

Author:  David Williams [ Thu Dec 02, 2010 8:03 pm ]
Post subject:  Re: Physics

Great, I'm glad you sorted it. Thermite3D did indeed use Bullet for physics (as seen in the physics tech demo) and it worked nicely... but I didn't need the physics since and it was getting in the way of refactoring the code, so it came out. I do intend to put it back in, but not in the immediate future. If you want to see what I was doing then you'll need the SVN revision from a couple of years ago. Let me know if you want it but can't find it.

I should point out that a better approach may be to perform collision detection directly against the volume, but this is a lot more work and needs some research. I haven't looked into it.

Page 1 of 1 All times are UTC
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group