Public Member Functions | Protected Member Functions | Protected Attributes | Friends
b2WheelJoint Class Reference

#include <b2WheelJoint.h>

Inheritance diagram for b2WheelJoint:
Inheritance graph
[legend]

List of all members.

Public Member Functions

void Dump ()
 Dump to b2Log.
void EnableMotor (bool flag)
 Enable/disable the joint motor.
b2Vec2 GetAnchorA () const
 Get the anchor point on bodyA in world coordinates.
b2Vec2 GetAnchorB () const
 Get the anchor point on bodyB in world coordinates.
float32 GetJointSpeed () const
 Get the current joint translation speed, usually in meters per second.
float32 GetJointTranslation () const
 Get the current joint translation, usually in meters.
const b2Vec2GetLocalAnchorA () const
 The local anchor point relative to bodyA's origin.
const b2Vec2GetLocalAnchorB () const
 The local anchor point relative to bodyB's origin.
const b2Vec2GetLocalAxisA () const
 The local joint axis relative to bodyA.
float32 GetMaxMotorTorque () const
float32 GetMotorSpeed () const
 Get the motor speed, usually in radians per second.
float32 GetMotorTorque (float32 inv_dt) const
 Get the current motor torque given the inverse time step, usually in N-m.
b2Vec2 GetReactionForce (float32 inv_dt) const
 Get the reaction force on bodyB at the joint anchor in Newtons.
float32 GetReactionTorque (float32 inv_dt) const
 Get the reaction torque on bodyB in N*m.
float32 GetSpringDampingRatio () const
float32 GetSpringFrequencyHz () const
bool IsMotorEnabled () const
 Is the joint motor enabled?
void SetMaxMotorTorque (float32 torque)
 Set/Get the maximum motor force, usually in N-m.
void SetMotorSpeed (float32 speed)
 Set the motor speed, usually in radians per second.
void SetSpringDampingRatio (float32 ratio)
 Set/Get the spring damping ratio.
void SetSpringFrequencyHz (float32 hz)
 Set/Get the spring frequency in hertz. Setting the frequency to zero disables the spring.

Protected Member Functions

 b2WheelJoint (const b2WheelJointDef *def)
void InitVelocityConstraints (const b2SolverData &data)
bool SolvePositionConstraints (const b2SolverData &data)
void SolveVelocityConstraints (const b2SolverData &data)

Protected Attributes

b2Vec2 m_ax
b2Vec2 m_ay
float32 m_bias
float32 m_dampingRatio
bool m_enableMotor
float32 m_frequencyHz
float32 m_gamma
float32 m_impulse
int32 m_indexA
int32 m_indexB
float32 m_invIA
float32 m_invIB
float32 m_invMassA
float32 m_invMassB
b2Vec2 m_localAnchorA
b2Vec2 m_localAnchorB
b2Vec2 m_localCenterA
b2Vec2 m_localCenterB
b2Vec2 m_localXAxisA
b2Vec2 m_localYAxisA
float32 m_mass
float32 m_maxMotorTorque
float32 m_motorImpulse
float32 m_motorMass
float32 m_motorSpeed
float32 m_sAx
float32 m_sAy
float32 m_sBx
float32 m_sBy
float32 m_springImpulse
float32 m_springMass

Friends

class b2Joint

Detailed Description

A wheel joint. This joint provides two degrees of freedom: translation along an axis fixed in bodyA and rotation in the plane. In other words, it is a point to line constraint with a rotational motor and a linear spring/damper. This joint is designed for vehicle suspensions.

Definition at line 78 of file b2WheelJoint.h.


Constructor & Destructor Documentation

b2WheelJoint::b2WheelJoint ( const b2WheelJointDef def) [protected]

Definition at line 48 of file b2WheelJoint.cpp.


Member Function Documentation

void b2WheelJoint::Dump ( ) [virtual]

Dump to b2Log.

Reimplemented from b2Joint.

Definition at line 401 of file b2WheelJoint.cpp.

void b2WheelJoint::EnableMotor ( bool  flag)

Enable/disable the joint motor.

Definition at line 375 of file b2WheelJoint.cpp.

b2Vec2 b2WheelJoint::GetAnchorA ( ) const [virtual]

Get the anchor point on bodyA in world coordinates.

Implements b2Joint.

Definition at line 329 of file b2WheelJoint.cpp.

b2Vec2 b2WheelJoint::GetAnchorB ( ) const [virtual]

Get the anchor point on bodyB in world coordinates.

Implements b2Joint.

Definition at line 334 of file b2WheelJoint.cpp.

Get the current joint translation speed, usually in meters per second.

Definition at line 363 of file b2WheelJoint.cpp.

Get the current joint translation, usually in meters.

Definition at line 349 of file b2WheelJoint.cpp.

const b2Vec2& b2WheelJoint::GetLocalAnchorA ( ) const [inline]

The local anchor point relative to bodyA's origin.

Definition at line 88 of file b2WheelJoint.h.

const b2Vec2& b2WheelJoint::GetLocalAnchorB ( ) const [inline]

The local anchor point relative to bodyB's origin.

Definition at line 91 of file b2WheelJoint.h.

const b2Vec2& b2WheelJoint::GetLocalAxisA ( ) const [inline]

The local joint axis relative to bodyA.

Definition at line 94 of file b2WheelJoint.h.

Definition at line 185 of file b2WheelJoint.h.

Get the motor speed, usually in radians per second.

Definition at line 180 of file b2WheelJoint.h.

Get the current motor torque given the inverse time step, usually in N-m.

Definition at line 396 of file b2WheelJoint.cpp.

b2Vec2 b2WheelJoint::GetReactionForce ( float32  inv_dt) const [virtual]

Get the reaction force on bodyB at the joint anchor in Newtons.

Implements b2Joint.

Definition at line 339 of file b2WheelJoint.cpp.

float32 b2WheelJoint::GetReactionTorque ( float32  inv_dt) const [virtual]

Get the reaction torque on bodyB in N*m.

Implements b2Joint.

Definition at line 344 of file b2WheelJoint.cpp.

Definition at line 205 of file b2WheelJoint.h.

Definition at line 195 of file b2WheelJoint.h.

void b2WheelJoint::InitVelocityConstraints ( const b2SolverData data) [protected, virtual]

Implements b2Joint.

Definition at line 77 of file b2WheelJoint.cpp.

Is the joint motor enabled?

Definition at line 370 of file b2WheelJoint.cpp.

Set/Get the maximum motor force, usually in N-m.

Definition at line 389 of file b2WheelJoint.cpp.

Set the motor speed, usually in radians per second.

Definition at line 382 of file b2WheelJoint.cpp.

void b2WheelJoint::SetSpringDampingRatio ( float32  ratio) [inline]

Set/Get the spring damping ratio.

Definition at line 200 of file b2WheelJoint.h.

Set/Get the spring frequency in hertz. Setting the frequency to zero disables the spring.

Definition at line 190 of file b2WheelJoint.h.

bool b2WheelJoint::SolvePositionConstraints ( const b2SolverData data) [protected, virtual]

Implements b2Joint.

Definition at line 280 of file b2WheelJoint.cpp.

void b2WheelJoint::SolveVelocityConstraints ( const b2SolverData data) [protected, virtual]

Implements b2Joint.

Definition at line 216 of file b2WheelJoint.cpp.


Friends And Related Function Documentation

friend class b2Joint [friend]

Definition at line 134 of file b2WheelJoint.h.


Member Data Documentation

Definition at line 168 of file b2WheelJoint.h.

Definition at line 168 of file b2WheelJoint.h.

Definition at line 176 of file b2WheelJoint.h.

Definition at line 142 of file b2WheelJoint.h.

bool b2WheelJoint::m_enableMotor [protected]

Definition at line 156 of file b2WheelJoint.h.

Definition at line 141 of file b2WheelJoint.h.

Definition at line 177 of file b2WheelJoint.h.

Definition at line 150 of file b2WheelJoint.h.

Definition at line 159 of file b2WheelJoint.h.

Definition at line 160 of file b2WheelJoint.h.

Definition at line 165 of file b2WheelJoint.h.

Definition at line 166 of file b2WheelJoint.h.

Definition at line 163 of file b2WheelJoint.h.

Definition at line 164 of file b2WheelJoint.h.

Definition at line 145 of file b2WheelJoint.h.

Definition at line 146 of file b2WheelJoint.h.

Definition at line 161 of file b2WheelJoint.h.

Definition at line 162 of file b2WheelJoint.h.

Definition at line 147 of file b2WheelJoint.h.

Definition at line 148 of file b2WheelJoint.h.

Definition at line 172 of file b2WheelJoint.h.

Definition at line 154 of file b2WheelJoint.h.

Definition at line 151 of file b2WheelJoint.h.

Definition at line 173 of file b2WheelJoint.h.

Definition at line 155 of file b2WheelJoint.h.

Definition at line 169 of file b2WheelJoint.h.

Definition at line 170 of file b2WheelJoint.h.

Definition at line 169 of file b2WheelJoint.h.

Definition at line 170 of file b2WheelJoint.h.

Definition at line 152 of file b2WheelJoint.h.

Definition at line 174 of file b2WheelJoint.h.


The documentation for this class was generated from the following files:


mvsim
Author(s):
autogenerated on Thu Jun 6 2019 22:08:35