bullet physics + MD3 models

jmonk123
Posts: 1
Joined: Sat Apr 11, 2009 1:32 am

bullet physics + MD3 models

Post by jmonk123 »

Hi,

I'm new to physics api's in general so please forgive me if what I'm asking is obvious. I'm hoping someone can point me in the right direction.

I've been developing an application that loads and renders Q3 BSP and MD3 models. I got the rendering portion working pretty good so I decided to try integrating a physics api into the program. After doing some research I found bullet and I started integrating it into my app. I used the bsp loading demo to load my bsp models into the physics api and I used the btRigidBody combined with a btBoxShape for the md3 model. Now, I just hardcoded a big bounding box around the model. For testing purposes, it works great. My model falls and then stops falling when the box that surrounds it hits the floor.

This is the point that I'm stuck at. Character models based on md3 files are usually defined by 3 nodes. Each node has several frames of animation that would cause the bounding box around each node to be changed. Also, each node is translated/rotated into a position/orientation depending on the animation frame. I don't think a btRigidBody with a btBoxShape is what I need to represent this model. I was playing with the idea of using a tree made up of btCompoundShape & btBoxShape objects but does the btBoxShape allow the modification of it's dimensions while it's in use? I don't think I should use soft body dynamics/objects, but then again I'm very new to physics programming/theory.

Any recommendations/tips are greatly appreciated.