I just downloaded the Bullet API today, so I am very new to the library and its capabilities.
Summary of my issue/question:
- I am having trouble deciding which collision shape (or maybe a soft body would be better?) to use for approximating a trimesh human head with individually animated vertices (the head trimesh is not animated using transformation matrices)
- I don't want this collision shape to be affected by anything other than the movement of the head trimesh (i.e. it should not deform or move when hit)
- However, I do want to be able to throw objects at the head/shape and have them bounce off realistically (realistically in the sense that a cube collision shape would not do the trick, because it isn't very good at approximating the lumpy geometry of a human head)
Read on if you are interested...
Specific details:
I am interested in using a collision shape to approximate an animated trimesh (specifically a human head that will make nodding movements). Since each vertex in the animated head could potentially change positions between time steps, I think I would need to use a dynamic collision shape.
According to the Bullet wiki, my options are either:
- a compound collision shape comprised of multiple primitives (I would probably use spheres) or btConvexHulls
- a single btConvexHull
- a single btConvexTriangleMeshShape
But since the collision shape would have to be driven by the vertex positions of the trimesh head that it encapsulates, I am wondering where this leaves me in terms of options. I have read through the User Manual, but have not found any information pertaining to changing (at each time step) the individual vertices of a btConvexHull after it has been created (i.e. driving the shape of a collision shape with vertex keyframe data).
On the other hand, since I don't what the collision shape to be influenced by any external forces (I want to instead collide objects against it), perhaps I should make it a static collision shape and not a dynamic one.
Thank you so much for your help, even if it is just pointing me to the right class or to a different physics library altogether.
--Leezer
