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