Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | Friends | List of all members
PxVehicleWheelsDynData Class Reference

Data structure with instanced dynamics data for wheels. More...

#include <PxVehicleWheels.h>

Public Member Functions

 PxVehicleWheelsDynData ()
 
 ~PxVehicleWheelsDynData ()
 
void setToRestState ()
 Set all wheels to their rest state. More...
 
void setTireForceShaderFunction (PxVehicleComputeTireForce tireForceShaderFn)
 Set the tire force shader function. More...
 
void setTireForceShaderData (const PxU32 tireId, const void *tireForceShaderData)
 Set the tire force shader data for a specific tire. More...
 
const void * getTireForceShaderData (const PxU32 tireId) const
 Get the tire force shader data for a specific tire. More...
 
void setWheelRotationSpeed (const PxU32 wheelIdx, const PxReal speed)
 Set the wheel rotation speed (radians per second) about the rolling axis for the specified wheel. More...
 
PxReal getWheelRotationSpeed (const PxU32 wheelIdx) const
 Return the rotation speed about the rolling axis of a specified wheel . More...
 
void setWheelRotationAngle (const PxU32 wheelIdx, const PxReal angle)
 Set the wheel rotation angle (radians) about the rolling axis of the specified wheel. More...
 
PxReal getWheelRotationAngle (const PxU32 wheelIdx) const
 Return the rotation angle about the rolling axis for the the specified wheel. More...
 
void setUserData (const PxU32 tireIdx, void *userData)
 Set the user data pointer for the specified wheel It has a default value of NULL. More...
 
void * getUserData (const PxU32 tireIdx) const
 Get the user data pointer that was set for the specified wheel. More...
 
void copy (const PxVehicleWheelsDynData &src, const PxU32 srcWheel, const PxU32 trgWheel)
 Copy the dynamics data of a single wheel unit (wheel, suspension, tire) from srcWheel of src to trgWheel. More...
 
PxU32 getNbWheelRotationSpeed () const
 
PxU32 getNbWheelRotationAngle () const
 
PxVehicleWheels4DynData * getWheel4DynData () const
 

Static Public Member Functions

static void getBinaryMetaData (PxOutputStream &stream)
 

Private Member Functions

bool isValid () const
 Test if wheel dynamics data have legal values. More...
 

Private Attributes

PxVehicleWheels4DynData * mWheels4DynData
 Dynamics data arranged in blocks of 4 wheels. More...
 
PxVehicleTireForceCalculator * mTireForceCalculators
 Shader data and function for tire force calculations. More...
 
void ** mUserDatas
 A userData pointer can be stored for each wheel. More...
 
PxU32 mNbWheels4
 Number of blocks of 4 wheels. More...
 
PxU32 mNbActiveWheels
 Number of wheels (mNbActiveWheels <= (mNbWheels4*4)) More...
 
PxU32 mPad [3]
 

Friends

class PxVehicleWheels
 
class PxVehicleDrive4W
 
class PxVehicleDriveTank
 
class PxVehicleUpdate
 

Detailed Description

Data structure with instanced dynamics data for wheels.

Constructor & Destructor Documentation

PxVehicleWheelsDynData::PxVehicleWheelsDynData ( )
inline
PxVehicleWheelsDynData::~PxVehicleWheelsDynData ( )
inline

Member Function Documentation

void PxVehicleWheelsDynData::copy ( const PxVehicleWheelsDynData src,
const PxU32  srcWheel,
const PxU32  trgWheel 
)

Copy the dynamics data of a single wheel unit (wheel, suspension, tire) from srcWheel of src to trgWheel.

Parameters
[in]srcis the data to be copied.
[in]srcWheelis the wheel whose data will be copied from src.
[in]trgWheelis the wheel that will be assigned the copied data.
static void PxVehicleWheelsDynData::getBinaryMetaData ( PxOutputStream stream)
static
PxU32 PxVehicleWheelsDynData::getNbWheelRotationAngle ( ) const
inline
PxU32 PxVehicleWheelsDynData::getNbWheelRotationSpeed ( ) const
inline
const void* PxVehicleWheelsDynData::getTireForceShaderData ( const PxU32  tireId) const

Get the tire force shader data for a specific tire.

void* PxVehicleWheelsDynData::getUserData ( const PxU32  tireIdx) const

Get the user data pointer that was set for the specified wheel.

PxVehicleWheels4DynData* PxVehicleWheelsDynData::getWheel4DynData ( ) const
inline
PxReal PxVehicleWheelsDynData::getWheelRotationAngle ( const PxU32  wheelIdx) const

Return the rotation angle about the rolling axis for the the specified wheel.

PxReal PxVehicleWheelsDynData::getWheelRotationSpeed ( const PxU32  wheelIdx) const

Return the rotation speed about the rolling axis of a specified wheel .

bool PxVehicleWheelsDynData::isValid ( ) const
private

Test if wheel dynamics data have legal values.

void PxVehicleWheelsDynData::setTireForceShaderData ( const PxU32  tireId,
const void *  tireForceShaderData 
)

Set the tire force shader data for a specific tire.

Parameters
[in]tireIdis the wheel index
[in]tireForceShaderDatais the data describing the tire.
void PxVehicleWheelsDynData::setTireForceShaderFunction ( PxVehicleComputeTireForce  tireForceShaderFn)

Set the tire force shader function.

Parameters
[in]tireForceShaderFnis the shader function that will be used to compute tire forces.
void PxVehicleWheelsDynData::setToRestState ( )

Set all wheels to their rest state.

See Also
setup
void PxVehicleWheelsDynData::setUserData ( const PxU32  tireIdx,
void *  userData 
)

Set the user data pointer for the specified wheel It has a default value of NULL.

Parameters
[in]tireIdxis the wheel index
[in]userDatais the data to be associated with the wheel.
void PxVehicleWheelsDynData::setWheelRotationAngle ( const PxU32  wheelIdx,
const PxReal  angle 
)

Set the wheel rotation angle (radians) about the rolling axis of the specified wheel.

Parameters
[in]wheelIdxis the wheel index
[in]angleis the rotation angle to be applied to the wheel.
void PxVehicleWheelsDynData::setWheelRotationSpeed ( const PxU32  wheelIdx,
const PxReal  speed 
)

Set the wheel rotation speed (radians per second) about the rolling axis for the specified wheel.

Parameters
[in]wheelIdxis the wheel index
[in]speedis the rotation speed to be applied to the wheel.

Friends And Related Function Documentation

friend class PxVehicleDrive4W
friend
friend class PxVehicleDriveTank
friend
friend class PxVehicleUpdate
friend
friend class PxVehicleWheels
friend

Member Data Documentation

PxU32 PxVehicleWheelsDynData::mNbActiveWheels
private

Number of wheels (mNbActiveWheels <= (mNbWheels4*4))

PxU32 PxVehicleWheelsDynData::mNbWheels4
private

Number of blocks of 4 wheels.

PxU32 PxVehicleWheelsDynData::mPad[3]
private
PxVehicleTireForceCalculator* PxVehicleWheelsDynData::mTireForceCalculators
private

Shader data and function for tire force calculations.

void** PxVehicleWheelsDynData::mUserDatas
private

A userData pointer can be stored for each wheel.

See Also
setUserData, getUserData
PxVehicleWheels4DynData* PxVehicleWheelsDynData::mWheels4DynData
private

Dynamics data arranged in blocks of 4 wheels.


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


Copyright © 2008-2015 NVIDIA Corporation, 2701 San Tomas Expressway, Santa Clara, CA 95050 U.S.A. All rights reserved. www.nvidia.com