58 vtx = pos +vec*(radius) - vec *
getMargin();
59 newDot = vec.dot(vtx);
70 vtx = pos +vec*(radius) - vec *
getMargin();
71 newDot = vec.dot(vtx);
89 for (
int j=0;j<numVectors;j++)
99 vtx = pos +vec*(radius) - vec *
getMargin();
100 newDot = vec.dot(vtx);
104 supportVerticesOut[j] = vtx;
110 vtx = pos +vec*(radius) - vec *
getMargin();
111 newDot = vec.dot(vtx);
115 supportVerticesOut[j] = vtx;
133 btVector3 halfExtents(radius,radius,radius);
146 inertia[0] = scaledmass * (y2+z2);
147 inertia[1] = scaledmass * (x2+z2);
148 inertia[2] = scaledmass * (x2+y2);
btCapsuleShapeX(btScalar radius, btScalar height)
#define CONVEX_DISTANCE_MARGIN
The CONVEX_DISTANCE_MARGIN is a default collision margin for convex collision shapes derived from btC...
void setValue(const btScalar &_x, const btScalar &_y, const btScalar &_z)
The btConvexInternalShape is an internal base class, shared by most convex shape implementations.
btScalar btSqrt(btScalar y)
btScalar getRadius() const
virtual btScalar getMargin() const
btVector3 m_implicitShapeDimensions
btCapsuleShapeZ(btScalar radius, btScalar height)
virtual void calculateLocalInertia(btScalar mass, btVector3 &inertia) const
CollisionShape Interface.
btCapsuleShape()
only used for btCapsuleShapeZ and btCapsuleShapeX subclasses.
btVector3 can be used to represent 3D points and vectors.
btScalar length2() const
Return the length of the vector squared.
virtual void batchedUnitVectorGetSupportingVertexWithoutMargin(const btVector3 *vectors, btVector3 *supportVerticesOut, int numVectors) const
virtual btVector3 localGetSupportingVertexWithoutMargin(const btVector3 &vec) const
btConvexShape Interface
btScalar getHalfHeight() const
float btScalar
The btScalar type abstracts floating point numbers, to easily switch between double and single floati...