15 #include "bulletCylinderShape.h"
25 BulletCylinderShape(
const LVector3 &half_extents, BulletUpAxis up) {
27 btVector3 btHalfExtents = LVecBase3_to_btVector3(half_extents);
31 _shape =
new btCylinderShapeX(btHalfExtents);
34 _shape =
new btCylinderShape(btHalfExtents);
37 _shape =
new btCylinderShapeZ(btHalfExtents);
40 bullet_cat.error() <<
"invalid up-axis:" << up << endl;
44 _shape->setUserPointer(
this);
53 BulletCylinderShape(PN_stdfloat radius, PN_stdfloat height, BulletUpAxis up) {
57 _shape =
new btCylinderShapeX(btVector3(0.5 * height, radius, radius));
60 _shape =
new btCylinderShape(btVector3(radius, 0.5 * height, radius));
63 _shape =
new btCylinderShapeZ(btVector3(radius, radius, 0.5 * height));
66 bullet_cat.error() <<
"invalid up-axis:" << up << endl;
70 _shape->setUserPointer(
this);
78 btCollisionShape *BulletCylinderShape::
This is a three-component vector distance (as opposed to a three-component point, which represents a ...
TypeHandle is the identifier used to differentiate C++ class types.