34#include "foundation/PxFoundation.h"
36#include "vehicle2/PxVehicleParams.h"
38#include "vehicle2/commands/PxVehicleCommandParams.h"
71 if (!axleDesc.isValid())
73 for (PxU32 i = 0; i < axleDesc.
nbWheels; i++)
76 "PxVehicleSteerCommandResponseParams.maxResponse*PxVehicleSteerCommandResponseParams.wheelResponseMultipliers[i] must be in range [-Pi, Pi]",
false);
94 PX_CHECK_AND_RETURN_VAL(0.0f ==
strength ||
wheelIds[0] < axleDesc.
getNbWheels(),
"PxVehicleAckermannParams.wheelIds[0] must be valid wheel",
false);
95 PX_CHECK_AND_RETURN_VAL(0.0f ==
strength ||
wheelIds[1] < axleDesc.
getNbWheels(),
"PxVehicleAckermannParams.wheelIds[1] must be a valid wheel",
false);
96 PX_CHECK_AND_RETURN_VAL(0.0f ==
strength ||
wheelIds[0] !=
wheelIds[1],
"PxVehicleAckermannParams.wheelIds[0] and PxVehicleAckermannParams.wheelIds[1] must reference two different wheels",
false);
97 PX_CHECK_AND_RETURN_VAL(0.0f ==
strength ||
wheelBase > 0.0f,
"PxVehicleAckermannParams.wheelBase must be greater than zero",
false);
98 PX_CHECK_AND_RETURN_VAL(0.0f ==
strength ||
trackWidth > 0.0f,
"PxVehicleAckermannParams.trackWidth must be greater than zero",
false);
99 PX_CHECK_AND_RETURN_VAL(
strength >= 0.0f &&
strength <= 1.0f,
"PxVehicleAckermannParams.strength must be in range [0,1]",
false);
110 const PxReal scale = trgScale.
scale / srcScale.
scale;
#define PX_FORCE_INLINE
Definition PxPreprocessor.h:335
Sorts an array of objects in ascending order, assuming that the predicate implements the < operator:
Definition PxBoxController.h:39
PX_CUDA_CALLABLE PX_FORCE_INLINE float PxAbs(float a)
abs returns the absolute value of its argument.
Definition PxMath.h:109
A description of a single axle that is to be affected by Ackermann steer correction.
Definition PxVehicleSteeringParams.h:86
PxReal wheelBase
wheelBase is the longitudinal distance between the axle that is affected by Ackermann correction and ...
Definition PxVehicleSteeringParams.h:88
PxU32 wheelIds[2]
wheelIds[0] is the id of the wheel that is negative along the lateral axis, wheelIds[1] is the wheel ...
Definition PxVehicleSteeringParams.h:87
PxReal strength
is the strength of the correction with 0 denoting no correction and 1 denoting perfect correction.
Definition PxVehicleSteeringParams.h:90
PxReal trackWidth
trackWidth is the width of the axle specified by wheelIds
Definition PxVehicleSteeringParams.h:89
Definition PxVehicleParams.h:53
PX_FORCE_INLINE PxU32 getNbWheels() const
Return the number of wheels on the vehicle.
Definition PxVehicleParams.h:115
PxU32 wheelIdsInAxleOrder[PxVehicleLimits::eMAX_NB_WHEELS]
The list of all wheel ids on the vehicle.
Definition PxVehicleParams.h:149
PxU32 nbWheels
The number of wheels on the vehicle.
Definition PxVehicleParams.h:150
A description of the per wheel response to an input command.
Definition PxVehicleCommandParams.h:177
PxReal wheelResponseMultipliers[PxVehicleLimits::eMAX_NB_WHEELS]
A description of the per wheel response multiplier to an input command.
Definition PxVehicleCommandParams.h:187
PxF32 maxResponse
The maximum response that occurs when the wheel response multiplier has value 1.0 and nonlinearRespon...
Definition PxVehicleCommandParams.h:192
Definition PxVehicleParams.h:174
Definition PxVehicleParams.h:224
PxReal scale
The length scale used for the vehicle. For example, if 1.0 is considered meters, then 100....
Definition PxVehicleParams.h:225
Distribute a steer response to the wheels of a vehicle.
Definition PxVehicleSteeringParams.h:58