PxVehicleDrive4W Class Reference
[Vehicle]
Data structure with instanced dynamics data and configuration data of a vehicle with up to 4 driven wheels.
More...
#include <PxVehicleDrive4W.h>


Public Types | |
enum | eWheelOrdering { eFRONT_LEFT_WHEEL = 0, eFRONT_RIGHT_WHEEL, eREAR_LEFT_WHEEL, eREAR_RIGHT_WHEEL } |
The ordering of the driven and steered wheels. More... | |
enum | { eANALOG_INPUT_ACCEL = PxVehicleDriveDynData::eANALOG_INPUT_ACCEL, eANALOG_INPUT_BRAKE, eANALOG_INPUT_HANDBRAKE, eANALOG_INPUT_STEER_LEFT, eANALOG_INPUT_STEER_RIGHT, eMAX_NUM_DRIVE4W_ANALOG_INPUTS } |
Public Member Functions | |
void | free () |
Deallocate a PxVehicleDrive4W instance. | |
void | setup (PxPhysics *physics, PxRigidDynamic *vehActor, const PxVehicleWheelsSimData &wheelsData, const PxVehicleDriveSimData4W &driveData, const PxU32 numNonDrivenWheels) |
Set up a vehicle with. | |
void | setToRestState () |
Set a vehicle to its rest state. | |
Static Public Member Functions | |
static PxVehicleDrive4W * | allocate (const PxU32 numWheels) |
Allocate a PxVehicleDrive4W instance for a 4WDrive vehicle with numWheels (= num driven wheels + num undriven wheels). | |
static PxVehicleDrive4W * | create (PxPhysics *physics, PxRigidDynamic *vehActor, const PxVehicleWheelsSimData &wheelsData, const PxVehicleDriveSimData4W &driveData, const PxU32 numNonDrivenWheels) |
Set up a vehicle with. | |
Public Attributes | |
PxVehicleDriveSimData4W | mDriveSimData |
Simulation data that models vehicle components. | |
Private Member Functions | |
PxVehicleDrive4W () | |
~PxVehicleDrive4W () | |
bool | isValid () const |
Test if the instanced dynamics and configuration data has legal values. | |
Friends | |
class | PxVehicleUpdate |
Detailed Description
Data structure with instanced dynamics data and configuration data of a vehicle with up to 4 driven wheels.and up to 16 non-driven wheels.
Member Enumeration Documentation
anonymous enum |
Constructor & Destructor Documentation
PxVehicleDrive4W::PxVehicleDrive4W | ( | ) | [inline, private] |
PxVehicleDrive4W::~PxVehicleDrive4W | ( | ) | [inline, private] |
Member Function Documentation
static PxVehicleDrive4W* PxVehicleDrive4W::allocate | ( | const PxU32 | numWheels | ) | [static] |
Allocate a PxVehicleDrive4W instance for a 4WDrive vehicle with numWheels (= num driven wheels + num undriven wheels).
static PxVehicleDrive4W* PxVehicleDrive4W::create | ( | PxPhysics * | physics, | |
PxRigidDynamic * | vehActor, | |||
const PxVehicleWheelsSimData & | wheelsData, | |||
const PxVehicleDriveSimData4W & | driveData, | |||
const PxU32 | numNonDrivenWheels | |||
) | [static] |
Set up a vehicle with.
(i) a PxPhysics instance - needed to setup special vehicle constraints maintained by the vehicle. (ii) a PxRigidDynamic instance - the rigid body representation of the vehicle in the physx sdk. (iii) a PxVehicleWheelsSimData instance describing the wheel/suspension/tires - the vehicle instance takes a copy of this input data. (iv) a PxVehicle4WDriveSimData instance describing the drive data (engine/Ackermann steer correction/differential etc) - the vehicle instance takes a copy of this input data. (v) the number of non-driven wheels (it is assumed that the vehicle has up to 4 wheels that could be driven by the engine). (vi) it is assumed that the first shapes of the actor are the wheel shapes, followed by the chassis shapes. (viii)it is assumed that the front-left wheel shape is shape 0 of the actor (ix) it is assumed that the front-right wheel shape is shape 1 of the actor (x) it is assumed that the rear-left wheel shape is shape 2 of the actor (xi) it is assumed that the rear-right wheel shape is shape 3 of the actor (xii) it is assumed that the N non-driven wheel shapes are shapes 4 -> 4+N-1 of the actor. (xiii)it is assumed that the wheel shapes ordered in the actor match the wheels specified in PxVehicleWheelsSimData. (xiv) to break assumptions (vi)-(xiii) and have arbitary shape ordering see PxVehicleWheels::setWheelShapeMapping (xv) only the first four wheels (the driven wheels) are connected to the steering.
- See also:
- free, setToRestState, setup, eWheelOrdering
void PxVehicleDrive4W::free | ( | ) |
bool PxVehicleDrive4W::isValid | ( | ) | const [private] |
Test if the instanced dynamics and configuration data has legal values.
Reimplemented from PxVehicleDrive.
void PxVehicleDrive4W::setToRestState | ( | ) |
void PxVehicleDrive4W::setup | ( | PxPhysics * | physics, | |
PxRigidDynamic * | vehActor, | |||
const PxVehicleWheelsSimData & | wheelsData, | |||
const PxVehicleDriveSimData4W & | driveData, | |||
const PxU32 | numNonDrivenWheels | |||
) |
Set up a vehicle with.
(i) a PxPhysics instance - needed to setup special vehicle constraints maintained by the vehicle. (ii) a PxRigidDynamic instance - the rigid body representation of the vehicle in the physx sdk. (iii) a PxVehicleWheelsSimData instance describing the wheel/suspension/tires - the vehicle instance takes a copy of this input data. (iv) a PxVehicle4WDriveSimData instance describing the drive data (engine/Ackermann steer correction/differential etc) - the vehicle instance takes a copy of this input data. (v) the number of non-driven wheels (it is assumed that the vehicle has up to 4 wheels that could be driven by the engine). (vi) it is assumed that the first shapes of the actor are the wheel shapes, followed by the chassis shapes. (viii)it is assumed that the front-left wheel shape is shape 0 of the actor (ix) it is assumed that the front-right wheel shape is shape 1 of the actor (x) it is assumed that the rear-left wheel shape is shape 2 of the actor (xi) it is assumed that the rear-right wheel shape is shape 3 of the actor (xii) it is assumed that the N non-driven wheel shapes are shapes 4 -> 4+N-1 of the actor. (xiii)it is assumed that the wheel shapes ordered in the actor match the wheels specified in PxVehicleWheelsSimData. (xiv) to break assumptions (vi)-(xiii) and have arbitary shape ordering see PxVehicleWheels::setWheelShapeMapping (xiv) only the first four wheels (the driven wheels) are connected to the steering.
- See also:
- allocate, free, setToRestState, eWheelOrdering
Friends And Related Function Documentation
friend class PxVehicleUpdate [friend] |
Reimplemented from PxVehicleDrive.
Member Data Documentation
The documentation for this class was generated from the following file:
Copyright © 2008-2012 NVIDIA Corporation, 2701 San Tomas Expressway, Santa Clara, CA 95050 U.S.A. All rights reserved. www.nvidia.com