Friction for each combination of driving surface type and tire type.
More...
#include <PxVehicleTireFriction.h>
|
| enum | { eMAX_NB_SURFACE_TYPES =256
} |
| |
|
|
class | VehicleSurfaceTypeHashTable |
| |
Friction for each combination of driving surface type and tire type.
- See also
- PxVehicleDrivableSurfaceType, PxVehicleTireData::mType
◆ allocate()
Allocate the memory for a PxVehicleDrivableSurfaceToTireFrictionPairs instance that can hold data for combinations of tire type and surface type with up to maxNbTireTypes types of tire and maxNbSurfaceTypes types of surface.
- Parameters
-
| [in] | maxNbTireTypes | is the maximum number of allowed tire types. |
| [in] | maxNbSurfaceTypes | is the maximum number of allowed surface types. Must be less than or equal to eMAX_NB_SURFACE_TYPES |
- Returns
- a PxVehicleDrivableSurfaceToTireFrictionPairs instance that can be reused later with new type and friction data.
- See also
- setup
◆ deserializeFromBinary()
◆ getMaxNbSurfaceTypes()
| PX_FORCE_INLINE PxU32 physx::PxVehicleDrivableSurfaceToTireFrictionPairs::getMaxNbSurfaceTypes |
( |
| ) |
const |
|
inline |
Return the maximum number of surface types.
- Returns
- The maximum number of surface types
- See also
- allocate
◆ getMaxNbTireTypes()
| PX_FORCE_INLINE PxU32 physx::PxVehicleDrivableSurfaceToTireFrictionPairs::getMaxNbTireTypes |
( |
| ) |
const |
|
inline |
Return the maximum number of tire types.
- Returns
- The maximum number of tire types
- See also
- allocate
◆ getSurfaceType()
| PxU32 physx::PxVehicleDrivableSurfaceToTireFrictionPairs::getSurfaceType |
( |
const PxMaterial & |
surfaceMaterial | ) |
const |
◆ getTypePairFriction() [1/2]
| PxReal physx::PxVehicleDrivableSurfaceToTireFrictionPairs::getTypePairFriction |
( |
const PxMaterial & |
surfaceMaterial, |
|
|
const PxU32 |
tireType |
|
) |
| const |
◆ getTypePairFriction() [2/2]
| PxReal physx::PxVehicleDrivableSurfaceToTireFrictionPairs::getTypePairFriction |
( |
const PxU32 |
surfaceType, |
|
|
const PxU32 |
tireType |
|
) |
| const |
◆ serializeToBinary()
◆ setTypePairFriction()
| void physx::PxVehicleDrivableSurfaceToTireFrictionPairs::setTypePairFriction |
( |
const PxU32 |
surfaceType, |
|
|
const PxU32 |
tireType, |
|
|
const PxReal |
value |
|
) |
| |
Set the friction for a specified pair of tire type and drivable surface type.
- Parameters
-
| [in] | surfaceType | describes the surface type |
| [in] | tireType | describes the tire type. |
| [in] | value | describes the friction coefficient for the combination of surface type and tire type. |
◆ setup()
| void physx::PxVehicleDrivableSurfaceToTireFrictionPairs::setup |
( |
const PxU32 |
nbTireTypes, |
|
|
const PxU32 |
nbSurfaceTypes, |
|
|
const PxMaterial ** |
drivableSurfaceMaterials, |
|
|
const PxVehicleDrivableSurfaceType * |
drivableSurfaceTypes |
|
) |
| |
Set up a PxVehicleDrivableSurfaceToTireFrictionPairs instance for combinations of nbTireTypes tire types and nbSurfaceTypes surface types.
- Parameters
-
| [in] | nbTireTypes | is the number of different types of tire. This value must be less than or equal to maxNbTireTypes specified in allocate(). |
| [in] | nbSurfaceTypes | is the number of different types of surface. This value must be less than or equal to maxNbSurfaceTypes specified in allocate(). |
| [in] | drivableSurfaceMaterials | is an array of PxMaterial pointers of length nbSurfaceTypes. |
| [in] | drivableSurfaceTypes | is an array of PxVehicleDrivableSurfaceType instances of length nbSurfaceTypes. |
- Note
- If the pointer to the PxMaterial that touches the tire is found in drivableSurfaceMaterials[x] then the surface type is drivableSurfaceTypes[x].mType and the friction is the value that is set with setTypePairFriction(drivableSurfaceTypes[x].mType, PxVehicleTireData::mType, frictionValue).
-
A friction value of 1.0 will be assigned as default to each combination of tire and surface type. To override this use setTypePairFriction.
- See also
- release, setTypePairFriction, getTypePairFriction, PxVehicleTireData.mType
The documentation for this class was generated from the following files:
- RavEngine/deps/physx/physx/include/vehicle/PxVehicleTireFriction.h
- RavEngine/deps/physx/physx/source/physxvehicle/src/PxVehicleTireFriction.cpp