Blender V2.61 - r43446
|
#include <btIDebugDraw.h>
Public Types | |
enum | DebugDrawModes { DBG_NoDebug = 0, DBG_DrawWireframe = 1, DBG_DrawAabb = 2, DBG_DrawFeaturesText = 4, DBG_DrawContactPoints = 8, DBG_NoDeactivation = 16, DBG_NoHelpText = 32, DBG_DrawText = 64, DBG_ProfileTimings = 128, DBG_EnableSatComparison = 256, DBG_DisableBulletLCP = 512, DBG_EnableCCD = 1024, DBG_DrawConstraints = (1 << 11), DBG_DrawConstraintLimits = (1 << 12), DBG_FastWireframe = (1<<13), DBG_MAX_DEBUG_DRAW_MODE } |
Public Member Functions | |
virtual | ~btIDebugDraw () |
virtual void | drawLine (const btVector3 &from, const btVector3 &to, const btVector3 &color)=0 |
virtual void | drawLine (const btVector3 &from, const btVector3 &to, const btVector3 &fromColor, const btVector3 &toColor) |
virtual void | drawSphere (btScalar radius, const btTransform &transform, const btVector3 &color) |
virtual void | drawSphere (const btVector3 &p, btScalar radius, const btVector3 &color) |
virtual void | drawTriangle (const btVector3 &v0, const btVector3 &v1, const btVector3 &v2, const btVector3 &, const btVector3 &, const btVector3 &, const btVector3 &color, btScalar alpha) |
virtual void | drawTriangle (const btVector3 &v0, const btVector3 &v1, const btVector3 &v2, const btVector3 &color, btScalar) |
virtual void | drawContactPoint (const btVector3 &PointOnB, const btVector3 &normalOnB, btScalar distance, int lifeTime, const btVector3 &color)=0 |
virtual void | reportErrorWarning (const char *warningString)=0 |
virtual void | draw3dText (const btVector3 &location, const char *textString)=0 |
virtual void | setDebugMode (int debugMode)=0 |
virtual int | getDebugMode () const =0 |
virtual void | drawAabb (const btVector3 &from, const btVector3 &to, const btVector3 &color) |
virtual void | drawTransform (const btTransform &transform, btScalar orthoLen) |
virtual void | drawArc (const btVector3 ¢er, const btVector3 &normal, const btVector3 &axis, btScalar radiusA, btScalar radiusB, btScalar minAngle, btScalar maxAngle, const btVector3 &color, bool drawSect, btScalar stepDegrees=btScalar(10.f)) |
virtual void | drawSpherePatch (const btVector3 ¢er, const btVector3 &up, const btVector3 &axis, btScalar radius, btScalar minTh, btScalar maxTh, btScalar minPs, btScalar maxPs, const btVector3 &color, btScalar stepDegrees=btScalar(10.f)) |
virtual void | drawBox (const btVector3 &bbMin, const btVector3 &bbMax, const btVector3 &color) |
virtual void | drawBox (const btVector3 &bbMin, const btVector3 &bbMax, const btTransform &trans, const btVector3 &color) |
virtual void | drawCapsule (btScalar radius, btScalar halfHeight, int upAxis, const btTransform &transform, const btVector3 &color) |
virtual void | drawCylinder (btScalar radius, btScalar halfHeight, int upAxis, const btTransform &transform, const btVector3 &color) |
virtual void | drawCone (btScalar radius, btScalar height, int upAxis, const btTransform &transform, const btVector3 &color) |
virtual void | drawPlane (const btVector3 &planeNormal, btScalar planeConst, const btTransform &transform, const btVector3 &color) |
The btIDebugDraw interface class allows hooking up a debug renderer to visually debug simulations. Typical use case: create a debug drawer object, and assign it to a btCollisionWorld or btDynamicsWorld using setDebugDrawer and call debugDrawWorld. A class that implements the btIDebugDraw interface has to implement the drawLine method at a minimum. For color arguments the X,Y,Z components refer to Red, Green and Blue each in the range [0..1]
Definition at line 28 of file btIDebugDraw.h.
Definition at line 32 of file btIDebugDraw.h.
virtual btIDebugDraw::~btIDebugDraw | ( | ) | [inline, virtual] |
Definition at line 52 of file btIDebugDraw.h.
virtual void btIDebugDraw::draw3dText | ( | const btVector3 & | location, |
const char * | textString | ||
) | [pure virtual] |
Referenced by btSoftBodyHelpers::Draw(), and btSoftBodyHelpers::DrawInfos().
virtual void btIDebugDraw::drawAabb | ( | const btVector3 & | from, |
const btVector3 & | to, | ||
const btVector3 & | color | ||
) | [inline, virtual] |
Definition at line 118 of file btIDebugDraw.h.
References drawLine(), and i.
Referenced by btCollisionWorld::debugDrawWorld(), btCompoundLeafCallback::Process(), and btCompoundLeafCallback::ProcessChildShape().
virtual void btIDebugDraw::drawArc | ( | const btVector3 & | center, |
const btVector3 & | normal, | ||
const btVector3 & | axis, | ||
btScalar | radiusA, | ||
btScalar | radiusB, | ||
btScalar | minAngle, | ||
btScalar | maxAngle, | ||
const btVector3 & | color, | ||
bool | drawSect, | ||
btScalar | stepDegrees = btScalar(10.f) |
||
) | [inline, virtual] |
Definition at line 155 of file btIDebugDraw.h.
References angle(), btCos(), btSin(), drawLine(), i, next, SIMD_RADS_PER_DEG, and step().
Referenced by btDiscreteDynamicsWorld::debugDrawConstraint(), drawCone(), and drawCylinder().
virtual void btIDebugDraw::drawBox | ( | const btVector3 & | bbMin, |
const btVector3 & | bbMax, | ||
const btVector3 & | color | ||
) | [inline, virtual] |
Definition at line 282 of file btIDebugDraw.h.
References drawLine().
Referenced by btDiscreteDynamicsWorld::debugDrawConstraint(), and btCollisionWorld::debugDrawObject().
virtual void btIDebugDraw::drawBox | ( | const btVector3 & | bbMin, |
const btVector3 & | bbMax, | ||
const btTransform & | trans, | ||
const btVector3 & | color | ||
) | [inline, virtual] |
Definition at line 297 of file btIDebugDraw.h.
References drawLine().
virtual void btIDebugDraw::drawCapsule | ( | btScalar | radius, |
btScalar | halfHeight, | ||
int | upAxis, | ||
const btTransform & | transform, | ||
const btVector3 & | color | ||
) | [inline, virtual] |
Definition at line 313 of file btIDebugDraw.h.
References MakeCursor::color, drawLine(), drawSphere(), btTransform::getBasis(), btTransform::getOrigin(), and transform().
Referenced by btCollisionWorld::debugDrawObject().
virtual void btIDebugDraw::drawCone | ( | btScalar | radius, |
btScalar | height, | ||
int | upAxis, | ||
const btTransform & | transform, | ||
const btVector3 & | color | ||
) | [inline, virtual] |
Definition at line 375 of file btIDebugDraw.h.
References MakeCursor::color, drawArc(), drawLine(), btTransform::getBasis(), btTransform::getOrigin(), and SIMD_2_PI.
Referenced by btCollisionWorld::debugDrawObject().
virtual void btIDebugDraw::drawContactPoint | ( | const btVector3 & | PointOnB, |
const btVector3 & | normalOnB, | ||
btScalar | distance, | ||
int | lifeTime, | ||
const btVector3 & | color | ||
) | [pure virtual] |
Referenced by btCollisionWorld::debugDrawWorld().
virtual void btIDebugDraw::drawCylinder | ( | btScalar | radius, |
btScalar | halfHeight, | ||
int | upAxis, | ||
const btTransform & | transform, | ||
const btVector3 & | color | ||
) | [inline, virtual] |
Definition at line 356 of file btIDebugDraw.h.
References MakeCursor::color, drawArc(), drawLine(), btTransform::getBasis(), btTransform::getOrigin(), and SIMD_2_PI.
Referenced by btCollisionWorld::debugDrawObject().
virtual void btIDebugDraw::drawLine | ( | const btVector3 & | from, |
const btVector3 & | to, | ||
const btVector3 & | fromColor, | ||
const btVector3 & | toColor | ||
) | [inline, virtual] |
Definition at line 56 of file btIDebugDraw.h.
References drawLine().
virtual void btIDebugDraw::drawLine | ( | const btVector3 & | from, |
const btVector3 & | to, | ||
const btVector3 & | color | ||
) | [pure virtual] |
Referenced by btPerturbedContactResult::addContactPoint(), btMinkowskiPenetrationDepthSolver::calcPenDepth(), btRaycastVehicle::debugDraw(), btDiscreteDynamicsWorld::debugDrawConstraint(), btCollisionWorld::debugDrawObject(), btSoftBodyHelpers::Draw(), drawAabb(), drawArc(), drawBox(), drawBox(), drawCapsule(), drawCone(), drawCylinder(), btSoftBodyHelpers::DrawFrame(), drawLine(), drawPlane(), drawSphere(), drawSpherePatch(), drawTransform(), drawTriangle(), drawVertex(), DebugDrawcallback::processTriangle(), btSoftBodyTriangleCallback::processTriangle(), and btConvexTriangleCallback::processTriangle().
virtual void btIDebugDraw::drawPlane | ( | const btVector3 & | planeNormal, |
btScalar | planeConst, | ||
const btTransform & | transform, | ||
const btVector3 & | color | ||
) | [inline, virtual] |
Definition at line 400 of file btIDebugDraw.h.
References btPlaneSpace1(), and drawLine().
Referenced by btCollisionWorld::debugDrawObject().
virtual void btIDebugDraw::drawSphere | ( | const btVector3 & | p, |
btScalar | radius, | ||
const btVector3 & | color | ||
) | [inline, virtual] |
Definition at line 89 of file btIDebugDraw.h.
References drawSphere(), btTransform::setIdentity(), and btTransform::setOrigin().
virtual void btIDebugDraw::drawSphere | ( | btScalar | radius, |
const btTransform & | transform, | ||
const btVector3 & | color | ||
) | [inline, virtual] |
Definition at line 62 of file btIDebugDraw.h.
References drawLine(), btTransform::getBasis(), and btTransform::getOrigin().
Referenced by btPerturbedContactResult::addContactPoint(), btContinuousConvexCollision::calcTimeOfImpact(), btCollisionWorld::debugDrawObject(), drawCapsule(), and drawSphere().
virtual void btIDebugDraw::drawSpherePatch | ( | const btVector3 & | center, |
const btVector3 & | up, | ||
const btVector3 & | axis, | ||
btScalar | radius, | ||
btScalar | minTh, | ||
btScalar | maxTh, | ||
btScalar | minPs, | ||
btScalar | maxPs, | ||
const btVector3 & | color, | ||
btScalar | stepDegrees = btScalar(10.f) |
||
) | [inline, virtual] |
Definition at line 180 of file btIDebugDraw.h.
References btCos(), btSin(), drawLine(), i, SIMD_HALF_PI, SIMD_PI, SIMD_RADS_PER_DEG, and step().
Referenced by btDiscreteDynamicsWorld::debugDrawConstraint().
virtual void btIDebugDraw::drawTransform | ( | const btTransform & | transform, |
btScalar | orthoLen | ||
) | [inline, virtual] |
Definition at line 147 of file btIDebugDraw.h.
References drawLine(), btTransform::getBasis(), and btTransform::getOrigin().
Referenced by btDiscreteDynamicsWorld::debugDrawConstraint(), btCollisionWorld::debugDrawObject(), and btConvexConvexAlgorithm::processCollision().
virtual void btIDebugDraw::drawTriangle | ( | const btVector3 & | v0, |
const btVector3 & | v1, | ||
const btVector3 & | v2, | ||
const btVector3 & | , | ||
const btVector3 & | , | ||
const btVector3 & | , | ||
const btVector3 & | color, | ||
btScalar | alpha | ||
) | [inline, virtual] |
Definition at line 97 of file btIDebugDraw.h.
Referenced by btSoftBodyHelpers::Draw().
virtual void btIDebugDraw::drawTriangle | ( | const btVector3 & | v0, |
const btVector3 & | v1, | ||
const btVector3 & | v2, | ||
const btVector3 & | color, | ||
btScalar | |||
) | [inline, virtual] |
Definition at line 101 of file btIDebugDraw.h.
References drawLine().
virtual int btIDebugDraw::getDebugMode | ( | ) | const [pure virtual] |
Referenced by btDiscreteDynamicsWorld::debugDrawConstraint(), btDiscreteDynamicsWorld::debugDrawWorld(), btCollisionWorld::debugDrawWorld(), btSoftRigidDynamicsWorld::debugDrawWorld(), CcdPhysicsEnvironment::debugDrawWorld(), btCompoundLeafCallback::Process(), btCompoundLeafCallback::ProcessChildShape(), btSoftBodyTriangleCallback::processTriangle(), btConvexTriangleCallback::processTriangle(), and btDiscreteDynamicsWorld::stepSimulation().
virtual void btIDebugDraw::reportErrorWarning | ( | const char * | warningString | ) | [pure virtual] |
Referenced by btCollisionWorld::updateSingleAabb().
virtual void btIDebugDraw::setDebugMode | ( | int | debugMode | ) | [pure virtual] |
Referenced by CcdPhysicsEnvironment::setDebugMode().