Edited by Medo3337, 27 October 2012 - 08:08 AM.
6 replies to this topic
#1 Members - Reputation: 356
Posted 27 October 2012 - 08:04 AM
I have created a plane in 3Ds max and 2 boxes, I am loading the three .x files into DirectX, so I have LPD3DXMESH, I am trying to load LPD3DXMESH information into Bullet Physics so I can get the two boxes to act like in physical world on the plane, how can I do so?
Ad:
#2 Members - Reputation: 677
Posted 27 October 2012 - 01:23 PM
Bullet physics has many shapes. Boxes, spheres, cylinders, convex meshes, and more. You are going to have to store somewhere what shapes each object has. And load that separately. For simple objects such as boxes and spheres creating the shapes is very simple. For more complicated shapes you can combine multiple simple shapes such as a box with half a sphere protruding out of one end. Or you can use what is called a convex hull. Bullet can build that for you. HullLibrary
You could just use the convex hull for all objects. That would be easier to make, but the convex hull takes more processing time than simpler shapes. For simple scenes you should be fine doing this.
You could just use the convex hull for all objects. That would be easier to make, but the convex hull takes more processing time than simpler shapes. For simple scenes you should be fine doing this.
#4 Members - Reputation: 677
Posted 27 October 2012 - 05:55 PM
I would recommend you start here
Physics Simulation Wiki
And specifically start with the user manual
Look at the getting started section.
Physics Simulation Wiki
And specifically start with the user manual
Look at the getting started section.
#5 Members - Reputation: 356
Posted 27 October 2012 - 10:44 PM
I am already reading in the user manual, but I would like to know if convex hull can be a possible and good to choice to use on all meshes in First Person Shooter game, or I should use primitives instead? box, sphere, etc...
Edited by Medo3337, 28 October 2012 - 05:45 AM.
#6 Crossbones+ - Reputation: 910
Posted 28 October 2012 - 04:44 AM
I am already ready in the user manual, but I would like to know if convex hull can be a possible and good to choice to use on all meshes in First Person Shooter game, or I should use primitives instead? box, sphere, etc...
Generally you do not want to use a generic convex hull for the physical representation of all meshes in a game. The computation is expensive so you would generally use the simplest representation you can.
-Josh






