Bullet Collision Detection & Physics Library
|
Go to the documentation of this file.
11 #ifndef BT_RAYCASTVEHICLE_H
12 #define BT_RAYCASTVEHICLE_H
218 #endif //BT_RAYCASTVEHICLE_H
void setPitchControl(btScalar pitch)
virtual void * castRay(const btVector3 &from, const btVector3 &to, btVehicleRaycasterResult &result)
btAlignedObjectArray< btWheelInfo > m_wheelInfo
The btRigidBody is the main class for rigid body objects.
rayCast vehicle, very special constraint that turn a rigidbody into a vehicle.
int getUserConstraintType() const
backwards compatibility
btScalar m_maxSuspensionTravelCm
btDynamicsWorld * m_dynamicsWorld
btVehicleRaycaster is provides interface for between vehicle simulation and raycasting
float btScalar
The btScalar type abstracts floating point numbers, to easily switch between double and single floati...
btAlignedObjectArray< btScalar > m_forwardImpulse
btScalar getCurrentSpeedKmHour() const
Velocity of vehicle (positive if velocity vector has same direction as foward vector)
void setUserConstraintType(int userConstraintType)
btVector3 getForwardVector() const
Worldspace forward vector.
btScalar rayCast(btWheelInfo &wheel)
const btTransform & getChassisWorldTransform() const
btScalar m_suspensionStiffness
btAlignedObjectArray< btVector3 > m_forwardWS
int getUserConstraintId() const
The btDynamicsWorld is the interface class for several dynamics implementation, basic,...
void updateSuspension(btScalar deltaTime)
int m_userConstraintType
backwards compatibility
btRigidBody * getRigidBody()
int getForwardAxis() const
virtual void updateAction(btCollisionWorld *collisionWorld, btScalar step)
btActionInterface interface
btScalar m_suspensionDamping
btScalar m_maxSuspensionForce
The btIDebugDraw interface class allows hooking up a debug renderer to visually debug simulations.
void debugDraw(btIDebugDraw *debugDrawer)
btActionInterface interface
void updateWheelTransform(int wheelIndex, bool interpolatedTransform=true)
btRaycastVehicle(const btVehicleTuning &tuning, btRigidBody *chassis, btVehicleRaycaster *raycaster)
btScalar m_suspensionCompression
Basic interface to allow actions such as vehicles and characters to be updated inside a btDynamicsWor...
btVector3 can be used to represent 3D points and vectors.
btWheelInfo & addWheel(const btVector3 &connectionPointCS0, const btVector3 &wheelDirectionCS0, const btVector3 &wheelAxleCS, btScalar suspensionRestLength, btScalar wheelRadius, const btVehicleTuning &tuning, bool isFrontWheel)
btAlignedObjectArray< btVector3 > m_axle
btDefaultVehicleRaycaster(btDynamicsWorld *world)
void setUserConstraintId(int uid)
btScalar m_currentVehicleSpeedKmHour
void setBrake(btScalar brake, int wheelIndex)
virtual ~btRaycastVehicle()
virtual void updateFriction(btScalar timeStep)
const btRigidBody * getRigidBody() const
void setSteeringValue(btScalar steering, int wheel)
virtual void updateVehicle(btScalar step)
btAlignedObjectArray< btScalar > m_sideImpulse
virtual void setCoordinateSystem(int rightIndex, int upIndex, int forwardIndex)
CollisionWorld is interface and container for the collision detection.
void defaultInit(const btVehicleTuning &tuning)
const btWheelInfo & getWheelInfo(int index) const
btVehicleRaycaster * m_vehicleRaycaster
btWheelInfo contains information per wheel about friction and suspension.
void updateWheelTransformsWS(btWheelInfo &wheel, bool interpolatedTransform=true)
btRigidBody * m_chassisBody
btScalar getSteeringValue(int wheel) const
const btTransform & getWheelTransformWS(int wheelIndex) const
int size() const
return the number of elements in the array
void applyEngineForce(btScalar force, int wheel)