summaryrefslogtreecommitdiff
path: root/thirdparty/bullet/BulletDynamics/Vehicle/btWheelInfo.h
diff options
context:
space:
mode:
Diffstat (limited to 'thirdparty/bullet/BulletDynamics/Vehicle/btWheelInfo.h')
-rw-r--r--thirdparty/bullet/BulletDynamics/Vehicle/btWheelInfo.h107
1 files changed, 51 insertions, 56 deletions
diff --git a/thirdparty/bullet/BulletDynamics/Vehicle/btWheelInfo.h b/thirdparty/bullet/BulletDynamics/Vehicle/btWheelInfo.h
index f991a57b69..af88b8ff83 100644
--- a/thirdparty/bullet/BulletDynamics/Vehicle/btWheelInfo.h
+++ b/thirdparty/bullet/BulletDynamics/Vehicle/btWheelInfo.h
@@ -18,20 +18,19 @@ class btRigidBody;
struct btWheelInfoConstructionInfo
{
- btVector3 m_chassisConnectionCS;
- btVector3 m_wheelDirectionCS;
- btVector3 m_wheelAxleCS;
- btScalar m_suspensionRestLength;
- btScalar m_maxSuspensionTravelCm;
- btScalar m_wheelRadius;
-
- btScalar m_suspensionStiffness;
- btScalar m_wheelsDampingCompression;
- btScalar m_wheelsDampingRelaxation;
- btScalar m_frictionSlip;
- btScalar m_maxSuspensionForce;
+ btVector3 m_chassisConnectionCS;
+ btVector3 m_wheelDirectionCS;
+ btVector3 m_wheelAxleCS;
+ btScalar m_suspensionRestLength;
+ btScalar m_maxSuspensionTravelCm;
+ btScalar m_wheelRadius;
+
+ btScalar m_suspensionStiffness;
+ btScalar m_wheelsDampingCompression;
+ btScalar m_wheelsDampingRelaxation;
+ btScalar m_frictionSlip;
+ btScalar m_maxSuspensionForce;
bool m_bIsFrontWheel;
-
};
/// btWheelInfo contains information per wheel about friction and suspension.
@@ -40,51 +39,50 @@ struct btWheelInfo
struct RaycastInfo
{
//set by raycaster
- btVector3 m_contactNormalWS;//contactnormal
- btVector3 m_contactPointWS;//raycast hitpoint
- btScalar m_suspensionLength;
- btVector3 m_hardPointWS;//raycast starting point
- btVector3 m_wheelDirectionWS; //direction in worldspace
- btVector3 m_wheelAxleWS; // axle in worldspace
- bool m_isInContact;
- void* m_groundObject; //could be general void* ptr
+ btVector3 m_contactNormalWS; //contactnormal
+ btVector3 m_contactPointWS; //raycast hitpoint
+ btScalar m_suspensionLength;
+ btVector3 m_hardPointWS; //raycast starting point
+ btVector3 m_wheelDirectionWS; //direction in worldspace
+ btVector3 m_wheelAxleWS; // axle in worldspace
+ bool m_isInContact;
+ void* m_groundObject; //could be general void* ptr
};
- RaycastInfo m_raycastInfo;
+ RaycastInfo m_raycastInfo;
- btTransform m_worldTransform;
-
- btVector3 m_chassisConnectionPointCS; //const
- btVector3 m_wheelDirectionCS;//const
- btVector3 m_wheelAxleCS; // const or modified by steering
- btScalar m_suspensionRestLength1;//const
- btScalar m_maxSuspensionTravelCm;
+ btTransform m_worldTransform;
+
+ btVector3 m_chassisConnectionPointCS; //const
+ btVector3 m_wheelDirectionCS; //const
+ btVector3 m_wheelAxleCS; // const or modified by steering
+ btScalar m_suspensionRestLength1; //const
+ btScalar m_maxSuspensionTravelCm;
btScalar getSuspensionRestLength() const;
- btScalar m_wheelsRadius;//const
- btScalar m_suspensionStiffness;//const
- btScalar m_wheelsDampingCompression;//const
- btScalar m_wheelsDampingRelaxation;//const
- btScalar m_frictionSlip;
- btScalar m_steering;
- btScalar m_rotation;
- btScalar m_deltaRotation;
- btScalar m_rollInfluence;
- btScalar m_maxSuspensionForce;
-
- btScalar m_engineForce;
-
- btScalar m_brake;
-
+ btScalar m_wheelsRadius; //const
+ btScalar m_suspensionStiffness; //const
+ btScalar m_wheelsDampingCompression; //const
+ btScalar m_wheelsDampingRelaxation; //const
+ btScalar m_frictionSlip;
+ btScalar m_steering;
+ btScalar m_rotation;
+ btScalar m_deltaRotation;
+ btScalar m_rollInfluence;
+ btScalar m_maxSuspensionForce;
+
+ btScalar m_engineForce;
+
+ btScalar m_brake;
+
bool m_bIsFrontWheel;
-
- void* m_clientInfo;//can be used to store pointer to sync transforms...
+
+ void* m_clientInfo; //can be used to store pointer to sync transforms...
btWheelInfo() {}
btWheelInfo(btWheelInfoConstructionInfo& ci)
{
-
m_suspensionRestLength1 = ci.m_suspensionRestLength;
m_maxSuspensionTravelCm = ci.m_maxSuspensionTravelCm;
@@ -104,18 +102,15 @@ struct btWheelInfo
m_rollInfluence = btScalar(0.1);
m_bIsFrontWheel = ci.m_bIsFrontWheel;
m_maxSuspensionForce = ci.m_maxSuspensionForce;
-
}
- void updateWheel(const btRigidBody& chassis,RaycastInfo& raycastInfo);
+ void updateWheel(const btRigidBody& chassis, RaycastInfo& raycastInfo);
- btScalar m_clippedInvContactDotSuspension;
- btScalar m_suspensionRelativeVelocity;
+ btScalar m_clippedInvContactDotSuspension;
+ btScalar m_suspensionRelativeVelocity;
//calculated by suspension
- btScalar m_wheelsSuspensionForce;
- btScalar m_skidInfo;
-
+ btScalar m_wheelsSuspensionForce;
+ btScalar m_skidInfo;
};
-#endif //BT_WHEEL_INFO_H
-
+#endif //BT_WHEEL_INFO_H