23btUniformScalingShape::~btUniformScalingShape()
27btVector3 btUniformScalingShape::localGetSupportingVertexWithoutMargin(
const btVector3& vec)
const
30 tmpVertex = m_childConvexShape->localGetSupportingVertexWithoutMargin(vec);
34void btUniformScalingShape::batchedUnitVectorGetSupportingVertexWithoutMargin(
const btVector3* vectors,
btVector3* supportVerticesOut,
int numVectors)
const
36 m_childConvexShape->batchedUnitVectorGetSupportingVertexWithoutMargin(vectors, supportVerticesOut, numVectors);
38 for (
i = 0;
i < numVectors;
i++)
47 tmpVertex = m_childConvexShape->localGetSupportingVertex(vec);
51void btUniformScalingShape::calculateLocalInertia(
btScalar mass,
btVector3& inertia)
const
55 m_childConvexShape->calculateLocalInertia(mass, tmpInertia);
86 for (
int i = 0;
i < 6;
i++)
88 _directions[
i] = _directions[
i] * t.getBasis();
93 btVector3 aabbMin1(0, 0, 0), aabbMax1(0, 0, 0);
95 for (
int i = 0;
i < 3; ++
i)
97 aabbMax1[
i] = t(_supporting[
i])[
i];
98 aabbMin1[
i] = t(_supporting[
i + 3])[
i];
101 aabbMin = aabbMin1 - marginVec;
102 aabbMax = aabbMax1 + marginVec;
107 for (
int i = 0;
i < 3;
i++)
113 aabbMax[
i] = tmp[
i] + margin;
117 aabbMin[
i] = tmp[
i] - margin;
123void btUniformScalingShape::setLocalScaling(
const btVector3& scaling)
125 m_childConvexShape->setLocalScaling(scaling);
128const btVector3& btUniformScalingShape::getLocalScaling()
const
130 return m_childConvexShape->getLocalScaling();
133void btUniformScalingShape::setMargin(
btScalar margin)
135 m_childConvexShape->setMargin(margin);
137btScalar btUniformScalingShape::getMargin()
const
142int btUniformScalingShape::getNumPreferredPenetrationDirections()
const
144 return m_childConvexShape->getNumPreferredPenetrationDirections();
147void btUniformScalingShape::getPreferredPenetrationDirection(
int index,
btVector3& penetrationVector)
const
149 m_childConvexShape->getPreferredPenetrationDirection(index, penetrationVector);
virtual btVector3 localGetSupportingVertex(const btVector3 &vec) const
virtual void batchedUnitVectorGetSupportingVertexWithoutMargin(const btVector3 *vectors, btVector3 *supportVerticesOut, int numVectors) const
@ UNIFORM_SCALING_SHAPE_PROXYTYPE
virtual btScalar getMargin() const =0
virtual void getAabbSlow(const btTransform &t, btVector3 &aabbMin, btVector3 &aabbMax) const
btConvexShape()
not supported on IBM SDK, until we fix the alignment of btVector3
float btScalar
The btScalar type abstracts floating point numbers, to easily switch between double and single floati...
btVector3
btVector3 can be used to represent 3D points and vectors. It has an un-used w component to suit 16-by...