35#include "foundation/PxFoundation.h"
36#include "common/PxCoreUtilityTypes.h"
38#include "vehicle2/PxVehicleParams.h"
40#include "vehicle2/commands/PxVehicleCommandParams.h"
64 const PxReal scale = trgScale.
scale/srcScale.
scale;
71 PX_CHECK_AND_RETURN_VAL(
PxIsFinite(
maxResponse),
"PxVehicleDirectDriveThrottleCommandResponseParams.maxResponse must be a finite value",
false);
72 for (PxU32 i = 0; i < axleDesc.
nbWheels; i++)
109 const PxReal scale = trgScale.
scale/srcScale.
scale;
117 PX_CHECK_AND_RETURN_VAL(
maxResponse >= 0.0f,
"PxVehicleClutchCommandResponseParams.maxResponse must be greater than or equal to zero",
false);
185 PX_CHECK_AND_RETURN_VAL((PxVehicleClutchAccuracyMode::eBEST_POSSIBLE ==
accuracyMode) || ((PxVehicleClutchAccuracyMode::eESTIMATE ==
accuracyMode) && (
estimateIterations > 0)),
"PxVehicleClutchParams.estimateIterations must be greater than zero if PxVehicleClutchAccuracyMode::eESTIMATE is selected",
false);
198 eMAX_NB_ENGINE_TORQUE_CURVE_ENTRIES = 8
296 const PxReal scale = trgScale.
scale/srcScale.
scale;
297 r.
moi *= (scale*scale);
307 PX_CHECK_AND_RETURN_VAL(
moi > 0.0f,
"PxVehicleEngineParams.moi must be greater than zero",
false);
308 PX_CHECK_AND_RETURN_VAL(
peakTorque >= 0.0f,
"PxVehicleEngineParams.peakTorque must be greater than or equal to zero",
false);
309 PX_CHECK_AND_RETURN_VAL(
torqueCurve.isValid(),
"PxVehicleEngineParams.torqueCurve is invalid",
false);
310 PX_CHECK_AND_RETURN_VAL(
maxOmega >= 0.0f,
"PxVehicleEngineParams.maxOmega must be greater than or equal to zero",
false);
311 PX_CHECK_AND_RETURN_VAL(
idleOmega >= 0.0f,
"PxVehicleEngineParams.idleOmega must be greater or equal to zero",
false);
312 PX_CHECK_AND_RETURN_VAL(
dampingRateFullThrottle >= 0.0f,
"PxVehicleEngineParams.dampingRateFullThrottle must be greater than or equal to zero",
false);
313 PX_CHECK_AND_RETURN_VAL(
dampingRateZeroThrottleClutchEngaged >= 0.0f,
"PxVehicleEngineParams.dampingRateZeroThrottleClutchEngaged must be greater than or equal to zero",
false);
342 PxReal ratios[eMAX_NB_GEARS];
378 PX_CHECK_AND_RETURN_VAL(finalRatio > 0,
"PxVehicleGearboxParams.finalRatio must be greater than zero",
false);
379 PX_CHECK_AND_RETURN_VAL(nbRatios >= 1,
"PxVehicleGearboxParams.nbRatios must be greater than zero",
false);
380 PX_CHECK_AND_RETURN_VAL(nbRatios <= eMAX_NB_GEARS,
"PxVehicleGearboxParams.nbRatios must be less than or equal to eMAX_NB_GEARS",
false);
381 PX_CHECK_AND_RETURN_VAL(neutralGear < nbRatios,
"PxVehicleGearboxParams.neutralGear must be less than PxVehicleGearboxParams.nbRatios",
false);
382 PX_CHECK_AND_RETURN_VAL(switchTime >= 0.0f,
"PxVehicleGearboxParams.switchTime must be greater than or equal to zero",
false);
383 for(PxU32 i = 0; i < neutralGear; i++)
385 PX_CHECK_AND_RETURN_VAL(ratios[i] < 0.0f,
"Reverse gear ratios must be less than zero",
false);
388 PX_CHECK_AND_RETURN_VAL(ratios[neutralGear] == 0.0f,
"Neutral gear ratio must be equal to zero",
false);
390 for (PxU32 i = neutralGear + 1; i < nbRatios; i++)
392 PX_CHECK_AND_RETURN_VAL(ratios[i] > 0.0f,
"Forward gear ratios must be greater than zero",
false);
394 for (PxU32 i = neutralGear + 2; i < nbRatios; i++)
396 PX_CHECK_AND_RETURN_VAL(ratios[i] < ratios[i - 1],
"Forward gear ratios must be a descending sequence of gear ratios",
false);
415 PxReal upRatios[PxVehicleGearboxParams::eMAX_NB_GEARS];
425 PxReal downRatios[PxVehicleGearboxParams::eMAX_NB_GEARS];
451 if (!gearboxParams.isValid())
456 PX_CHECK_AND_RETURN_VAL(upRatios[i] >= 0.0f,
"PxVehicleAutoboxParams.upRatios must be greater than or equal to zero",
false);
460 PX_CHECK_AND_RETURN_VAL(downRatios[i] >= 0.0f,
"PxVehicleAutoboxParams.downRatios must be greater than or equal to zero",
false);
462 PX_CHECK_AND_RETURN_VAL(latency >= 0.0f,
"PxVehicleAutoboxParams.latency must be greater than or equal to zero",
false);
477 eDIFF_TYPE_LS_FRONTWD,
478 eDIFF_TYPE_LS_REARWD,
491 PxU32 frontWheelIds[2];
503 PxU32 rearWheelIds[2];
582 PX_CHECK_AND_RETURN_VAL((axleDesc.
getAxle(frontWheelIds[0]) != 0xffffffff) && (axleDesc.
getAxle(frontWheelIds[0])== axleDesc.
getAxle(frontWheelIds[1])),
"frontWheelIds[0] and frontWheelIds[1] must reference wheels on the same axle",
false);
583 PX_CHECK_AND_RETURN_VAL((axleDesc.
getAxle(rearWheelIds[0]) != 0xffffffff) && (axleDesc.
getAxle(rearWheelIds[0]) == axleDesc.
getAxle(rearWheelIds[1])),
"rearWheelIds[0] and rearWheelIds[1] must reference wheels on the same axle",
false);
584 PX_CHECK_AND_RETURN_VAL(frontRearSplit <= 1.0f && frontRearSplit >= 0.0f,
"PxVehicleLegacyFourWheelDriveDifferentialParams.frontRearSplit must be in range [0,1]",
false);
585 PX_CHECK_AND_RETURN_VAL(frontNegPosSplit <= 1.0f && frontNegPosSplit >= 0.0f,
"PxVehicleLegacyFourWheelDriveDifferentialParams.frontNegPosSplit must be in range [0,1]",
false);
586 PX_CHECK_AND_RETURN_VAL(rearNegPosSplit <= 1.0f && rearNegPosSplit >= 0.0f,
"PxVehicleLegacyFourWheelDriveDifferentialParams.rearNegPosSplit must be in range [0,1]",
false);
587 PX_CHECK_AND_RETURN_VAL(centerBias >= 1.0f,
"PxVehicleLegacyFourWheelDriveDifferentialParams.centerBias must be greater than or equal to 1.0f",
false);
588 PX_CHECK_AND_RETURN_VAL(frontBias >= 1.0f,
"PxVehicleLegacyFourWheelDriveDifferentialParams.frontBias must be greater than or equal to 1.0f",
false);
589 PX_CHECK_AND_RETURN_VAL(rearBias >= 1.0f,
"PxVehicleLegacyFourWheelDriveDifferentialParams.rearBias must be greater than or equal to 1.0f",
false);
590 PX_CHECK_AND_RETURN_VAL(type < PxVehicleFourWheelDriveDifferentialLegacyParams::eMAX_NB_DIFF_TYPES,
"PxVehicleLegacyFourWheelDriveDifferentialParams.type has illegal value",
false);
610 PxReal torqueRatios[PxVehicleLimits::eMAX_NB_WHEELS];
620 PxReal aveWheelSpeedRatios[PxVehicleLimits::eMAX_NB_WHEELS];
638 PX_FORCE_INLINE bool isValid(
const PxVehicleAxleDescription& axleDesc)
const
640 if (!axleDesc.isValid())
642 PxReal aveWheelSpeedSum = 0.0f;
643 PxReal torqueRatioSum = 0.0f;
644 for (PxU32 i = 0; i < axleDesc.nbWheels; i++)
646 const PxU32 wheelId = axleDesc.wheelIdsInAxleOrder[i];
647 PX_CHECK_AND_RETURN_VAL(
PxAbs(torqueRatios[wheelId]) <= 1.0f,
"PxVehicleMultiWheelDriveDifferentialParams.torqueRatios[i] must be in range [-1, 1] for all wheels connected to the differential",
false);
648 PX_CHECK_AND_RETURN_VAL(aveWheelSpeedRatios[wheelId] >= 0.0f && aveWheelSpeedRatios[wheelId] <= 1.0f,
"PxVehicleMultiWheelDriveDifferentialParams.aveWheelSpeedRatios[i] must be in range [0, 1] for all wheels connected to the differential",
false);
649 aveWheelSpeedSum += aveWheelSpeedRatios[wheelId];
650 torqueRatioSum +=
PxAbs(torqueRatios[wheelId]);
652 PX_CHECK_AND_RETURN_VAL(aveWheelSpeedSum >= 0.99f && aveWheelSpeedSum <= 1.01f,
"Sum of PxVehicleMultiWheelDriveDifferentialParams.aveWheelSpeedRatios[i] must be 1.0.",
false);
653 PX_CHECK_AND_RETURN_VAL(torqueRatioSum >= 0.99f && torqueRatioSum <= 1.01f,
"Sum of PxVehicleMultiWheelDriveDifferentialParams.torqueRatios[i] must be 1.0.",
false);
654 PX_UNUSED(aveWheelSpeedSum);
655 PX_UNUSED(torqueRatioSum);
663#define PX_VEHICLE_FOUR_WHEEL_DIFFERENTIAL_MAXIMUM_STRENGTH PX_MAX_F32
679 PxU32 frontWheelIds[2];
687 PxU32 rearWheelIds[2];
765 PxVehicleMultiWheelDriveDifferentialParams::setToDefault();
773 if (!PxVehicleMultiWheelDriveDifferentialParams::isValid(axleDesc))
776 PX_CHECK_AND_RETURN_VAL((0.0f == centerBias) ||
777 (centerBias > 1.0f &&
778 frontWheelIds[0] < axleDesc.
nbWheels && frontWheelIds[1] < axleDesc.
nbWheels &&
779 rearWheelIds[0] < axleDesc.
nbWheels && rearWheelIds[1] < axleDesc.
nbWheels),
780 "PxVehicleFourWheelDriveDifferentialParams:: centreBias is enabled but the frontWheelIds and rearWheelIds are not configured correctly.",
false);
781 PX_CHECK_AND_RETURN_VAL((0.0f == centerBias) ||
782 (centerBias > 1.0f &&
783 frontWheelIds[0] != frontWheelIds[1] && frontWheelIds[0] != rearWheelIds[0] && frontWheelIds[0] != rearWheelIds[1] &&
784 frontWheelIds[1] != rearWheelIds[0] && frontWheelIds[1] != rearWheelIds[1] &&
785 rearWheelIds[0] != rearWheelIds[1]),
786 "PxVehicleFourWheelDriveDifferentialParams:: centreBias is enabled but the frontWheelIds and rearWheelIds are not configured correctly.",
false);
787 PX_CHECK_AND_RETURN_VAL((0.0f == centerBias) ||
788 (centerBias > 1.0f &&
789 torqueRatios[frontWheelIds[0]] != 0.0f && torqueRatios[frontWheelIds[1]] != 0.0f && torqueRatios[rearWheelIds[0]] != 0.0f && torqueRatios[rearWheelIds[1]] != 0.0f),
790 "PxVehicleFourWheelDriveDifferentialParams:: centreBias is enabled but the front and rear wheels are not connected.",
false);
792 PX_CHECK_AND_RETURN_VAL((0.0f == rearBias) ||
793 (rearBias > 1.0f && rearWheelIds[0] < axleDesc.
nbWheels && rearWheelIds[1] < axleDesc.
nbWheels),
794 "PxVehicleFourWheelDriveDifferentialParams:: rearBias is enabled but the rearWheelIds are not configured correctly.",
false);
795 PX_CHECK_AND_RETURN_VAL((0.0f == rearBias) ||
796 (rearBias > 1.0f && rearWheelIds[0] != rearWheelIds[1]),
797 "PxVehicleFourWheelDriveDifferentialParams:: rearBias is enabled but the rearWheelIds are not configured correctly.",
false);
798 PX_CHECK_AND_RETURN_VAL((0.0f == centerBias) ||
799 (rearBias > 1.0f && torqueRatios[rearWheelIds[0]] != 0.0f && torqueRatios[rearWheelIds[1]] != 0.0f),
800 "PxVehicleFourWheelDriveDifferentialParams:: rearBias is enabled but the rear wheels are not connected.",
false);
802 PX_CHECK_AND_RETURN_VAL((0.0f == frontBias) ||
803 (frontBias > 1.0f && frontWheelIds[0] < axleDesc.
nbWheels && frontWheelIds[1] < axleDesc.
nbWheels),
804 "PxVehicleFourWheelDriveDifferentialParams:: frontBias is enabled but the frontWheelIds are not configured correctly.",
false);
805 PX_CHECK_AND_RETURN_VAL((0.0f == frontBias) ||
806 (frontBias > 1.0f && frontWheelIds[0] != frontWheelIds[1]),
807 "PxVehicleFourWheelDriveDifferentialParams:: frontBias is enabled but the frontWheelIds are not configured correctly.",
false);
808 PX_CHECK_AND_RETURN_VAL((0.0f == frontBias) ||
809 (frontBias > 1.0f && torqueRatios[frontWheelIds[0]] != 0.0f && frontWheelIds[frontWheelIds[1]]),
810 "PxVehicleFourWheelDriveDifferentialParams:: frontBias is enabled but the front wheels are not connected.",
false);
812 PX_CHECK_AND_RETURN_VAL(((0.0f == frontBias) && (0.0f == rearBias) && (0.0f == centerBias)) || (rate >= 0.0f),
813 "PxVehicleFourWheelDriveDifferentialParams:: strength must be greater than or equal to zero",
false);
815 PX_CHECK_AND_RETURN_VAL((0.0f == frontBias) || ((1.0f == frontTarget && 1.0f == rearTarget) || (frontTarget > 1.0f && frontTarget < frontBias)),
816 "PxVehicleFourWheelDriveDifferentialParams: frontBias is enabled but frontTarget not in range (1.0f, frontBias)",
false);
817 PX_CHECK_AND_RETURN_VAL((0.0f == rearBias) || ((1.0f == rearTarget && 1.0f == rearBias) || (rearTarget > 1.0f && rearTarget < rearBias)),
818 "PxVehicleFourWheelDriveDifferentialParams: rearBias is enabled but rearTarget not in range (1.0f, rearBias)",
false);
819 PX_CHECK_AND_RETURN_VAL((0.0f == centerBias) || ((1.0f == centerTarget && 1.0f == centerBias) || (centerTarget > 1.0f && centerTarget < centerBias)),
820 "PxVehicleFourWheelDriveDifferentialParams: centerBias is enabled but centerTarget not in range (1.0f, centerBias)",
false);
825 PX_FORCE_INLINE PxVehicleFourWheelDriveDifferentialParams transformAndScale(
826 const PxVehicleFrame& srcFrame,
const PxVehicleFrame& trgFrame,
const PxVehicleScale& srcScale,
const PxVehicleScale& trgScale)
const
832 PxVehicleFourWheelDriveDifferentialParams r = *
this;
833 static_cast<PxVehicleMultiWheelDriveDifferentialParams&
>(r) = PxVehicleMultiWheelDriveDifferentialParams::transformAndScale(srcFrame, trgFrame, srcScale, trgScale);
856 PxVehicleMultiWheelDriveDifferentialParams::setToDefault();
858 nbWheelsInTracks = 0;
867 void addTankTrack(
const PxU32 nbWheelsInTrackToAdd,
const PxU32*
const wheelIdsInTrackToAdd,
const PxU32 thrustControllerIndex)
869 PX_ASSERT((nbWheelsInTracks + nbWheelsInTrackToAdd) < PxVehicleLimits::eMAX_NB_WHEELS);
870 PX_ASSERT(nbTracks < PxVehicleLimits::eMAX_NB_WHEELS);
871 PX_ASSERT(thrustControllerIndex < 2);
872 nbWheelsPerTrack[nbTracks] = nbWheelsInTrackToAdd;
873 thrustIdPerTrack[nbTracks] = thrustControllerIndex;
874 trackToWheelIds[nbTracks] = nbWheelsInTracks;
875 for (PxU32 i = 0; i < nbWheelsInTrackToAdd; i++)
877 wheelIdsInTrackOrder[nbWheelsInTracks + i] = wheelIdsInTrackToAdd[i];
879 nbWheelsInTracks += nbWheelsInTrackToAdd;
901 return nbWheelsPerTrack[i];
911 return (wheelIdsInTrackOrder + trackToWheelIds[i]);
923 return wheelIdsInTrackOrder[trackToWheelIds[i] + j];
933 return thrustIdPerTrack[i];
948 PX_FORCE_INLINE bool isValid(
const PxVehicleAxleDescription& axleDesc)
const
950 if (!PxVehicleMultiWheelDriveDifferentialParams::isValid(axleDesc))
953 PX_CHECK_AND_RETURN_VAL(nbTracks <= PxVehicleLimits::eMAX_NB_WHEELS,
"PxVehicleTankDriveDifferentialParams.nbTracks must not exceed PxVehicleLimits::eMAX_NB_WHEELS",
false);
954 PX_CHECK_AND_RETURN_VAL(nbWheelsInTracks <= PxVehicleLimits::eMAX_NB_WHEELS,
"PxVehicleTankDriveDifferentialParams.nbWheelsInTracks must not exceed PxVehicleLimits::eMAX_NB_WHEELS",
false);
955 for (PxU32 i = 0; i < nbTracks; i++)
957 PX_CHECK_AND_RETURN_VAL(thrustIdPerTrack[i] < 2,
"PxVehicleTankDriveDifferentialParams.thrustId must be less than 2",
false);
958 PX_CHECK_AND_RETURN_VAL(getNbWheelsInTrack(i) >= 2,
"PxVehicleTankDriveDifferentialParams.nbWheelsPerTrack must be greater than or equal to 2",
false);
961 for (PxU32 i = 0; i < axleDesc.nbWheels; i++)
963 const PxU32 wheelId = axleDesc.wheelIdsInAxleOrder[i];
965 for (PxU32 j = 0; j < nbWheelsInTracks; j++)
967 if (wheelIdsInTrackOrder[j] == wheelId)
970 PX_CHECK_AND_RETURN_VAL(count <= 1,
"PxVehicleTankDriveDifferentialParams - a wheel cannot be in more than one tank track",
false);
976 PxU32 thrustIdPerTrack[PxVehicleLimits::eMAX_NB_WHEELS];
977 PxU32 nbWheelsPerTrack[PxVehicleLimits::eMAX_NB_WHEELS];
978 PxU32 trackToWheelIds[PxVehicleLimits::eMAX_NB_WHEELS];
980 PxU32 wheelIdsInTrackOrder[PxVehicleLimits::eMAX_NB_WHEELS];
Express a function as a sequence of points {(x, y)} that form a piecewise polynomial.
Definition PxVehicleParams.h:808
#define PX_FORCE_INLINE
Definition PxPreprocessor.h:335
#define PX_DEPRECATED
Definition PxPreprocessor.h:418
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
PX_CUDA_CALLABLE PX_FORCE_INLINE bool PxIsFinite(float f)
returns true if the passed number is a finite floating point number as opposed to INF,...
Definition PxMath.h:326
PX_FORCE_INLINE void * PxMemZero(void *dest, PxU32 count)
Sets the bytes of the provided buffer to zero.
Definition PxMemory.h:53
Definition PxVehicleDrivetrainParams.h:404
PxReal latency
Set the latency time of the autobox.
Definition PxVehicleDrivetrainParams.h:437
Definition PxVehicleParams.h:53
PxU32 wheelIdsInAxleOrder[PxVehicleLimits::eMAX_NB_WHEELS]
The list of all wheel ids on the vehicle.
Definition PxVehicleParams.h:149
PX_FORCE_INLINE PxU32 getAxle(const PxU32 wheelId) const
Return the axle of a specified wheel.
Definition PxVehicleParams.h:125
PxU32 nbWheels
The number of wheels on the vehicle.
Definition PxVehicleParams.h:150
Choose between a potentially more expensive but more accurate solution to the clutch model or a poten...
Definition PxVehicleDrivetrainParams.h:127
Specifies the maximum clutch strength that occurs when the clutch pedal is fully disengaged and the c...
Definition PxVehicleDrivetrainParams.h:84
PxReal maxResponse
Strength of clutch.
Definition PxVehicleDrivetrainParams.h:102
The clutch connects two plates together. One plate rotates with the speed of the engine....
Definition PxVehicleDrivetrainParams.h:141
PxVehicleClutchAccuracyMode::Enum accuracyMode
The engine and wheel rotation speeds that are coupled through the clutch can be updated by choosing o...
Definition PxVehicleDrivetrainParams.h:158
PxU32 estimateIterations
Tune the mathematical accuracy and computational cost of the computed estimate to the wheel and engin...
Definition PxVehicleDrivetrainParams.h:171
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
Distribute a throttle response to the wheels of a direct drive vehicle.
Definition PxVehicleDrivetrainParams.h:57
Definition PxVehicleDrivetrainParams.h:192
PxReal peakTorque
Maximum torque available to apply to the engine when the accelerator pedal is at maximum.
Definition PxVehicleDrivetrainParams.h:224
PxReal dampingRateFullThrottle
Damping rate of engine when full throttle is applied.
Definition PxVehicleDrivetrainParams.h:256
PxReal moi
Moment of inertia of the engine around the axis of rotation.
Definition PxVehicleDrivetrainParams.h:214
PxVehicleFixedSizeLookupTable< PxReal, eMAX_NB_ENGINE_TORQUE_CURVE_ENTRIES > torqueCurve
Graph of normalized torque (torque/peakTorque) against normalized engine speed ( engineRotationSpeed ...
Definition PxVehicleDrivetrainParams.h:206
PxReal idleOmega
Minimum rotation speed of the engine.
Definition PxVehicleDrivetrainParams.h:232
PxReal dampingRateZeroThrottleClutchDisengaged
Damping rate of engine when no throttle is applied and with disengaged clutch.
Definition PxVehicleDrivetrainParams.h:288
PxReal maxOmega
Maximum rotation speed of the engine.
Definition PxVehicleDrivetrainParams.h:240
PxReal dampingRateZeroThrottleClutchEngaged
Damping rate of engine when no throttle is applied and with engaged clutch.
Definition PxVehicleDrivetrainParams.h:272
Definition PxVehicleDrivetrainParams.h:471
Enum type
Type of differential.
Definition PxVehicleDrivetrainParams.h:567
PxReal rearBias
Maximum allowed ratio of rear-left and rear-right wheel rotation speeds. The differential will divert...
Definition PxVehicleDrivetrainParams.h:560
PxReal centerBias
Maximum allowed ratio of average front wheel rotation speed and rear wheel rotation speeds....
Definition PxVehicleDrivetrainParams.h:540
PxReal frontRearSplit
Ratio of torque split between front and rear wheels (>0.5 means more front, <0.5 means more to rear).
Definition PxVehicleDrivetrainParams.h:512
PxReal frontNegPosSplit
Ratio of torque split between front-negative and front-positive wheels (>0.5 means more to frontWheel...
Definition PxVehicleDrivetrainParams.h:521
PxReal frontBias
Maximum allowed ratio of front-left and front-right wheel rotation speeds. The differential will dive...
Definition PxVehicleDrivetrainParams.h:550
PxReal rearNegPosSplit
Ratio of torque split between rear-negative wheel and rear-positive wheels (>0.5 means more to rearWh...
Definition PxVehicleDrivetrainParams.h:530
PxVehicleFourWheelDriveDifferentialParams specifies the wheels that are to receive drive torque from ...
Definition PxVehicleDrivetrainParams.h:672
PxReal centerBias
The parameter centerBias specifies the maximum angular speed ratio of the sum of the two front wheels...
Definition PxVehicleDrivetrainParams.h:743
PxReal frontBias
The parameter frontBias specifies the maximum angular speed ratio of the two front wheels specified b...
Definition PxVehicleDrivetrainParams.h:700
PxReal rearBias
The parameter rearBias specifies the maximum angular speed ratio of the two rear wheels specified by ...
Definition PxVehicleDrivetrainParams.h:721
PxReal rate
The parameter rate specifies how quickly the ratio of rotational speeds approaches the target rotatio...
Definition PxVehicleDrivetrainParams.h:760
PxReal frontTarget
The parameter frontTarget specifies the target rotational speed ratio of the two front wheels in the ...
Definition PxVehicleDrivetrainParams.h:708
PxReal rearTarget
The parameter rearTarget specifies the target rotational speed ratio of the two rear wheels in the ev...
Definition PxVehicleDrivetrainParams.h:729
PxReal centerTarget
The parameter centerTarget specifies the target rotational speed ratio of the sum of the two front wh...
Definition PxVehicleDrivetrainParams.h:751
Definition PxVehicleParams.h:174
Definition PxVehicleDrivetrainParams.h:320
PxU32 neutralGear
The gear that denotes neutral gear.
Definition PxVehicleDrivetrainParams.h:326
PxU32 nbRatios
Number of gears (including reverse and neutral).
Definition PxVehicleDrivetrainParams.h:356
Enum
Maximum supported number of gears, including reverse and neutral.
Definition PxVehicleDrivetrainParams.h:332
PxReal finalRatio
Gear ratio applied is ratios[currentGear]*finalRatio.
Definition PxVehicleDrivetrainParams.h:349
PxReal switchTime
Time it takes to switch gear.
Definition PxVehicleDrivetrainParams.h:364
PxVehicleMultiWheelDriveDifferentialParams specifies the wheels that are to receive drive torque from...
Definition PxVehicleDrivetrainParams.h:600
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
A description of a tank differential.
Definition PxVehicleDrivetrainParams.h:853
void addTankTrack(const PxU32 nbWheelsInTrackToAdd, const PxU32 *const wheelIdsInTrackToAdd, const PxU32 thrustControllerIndex)
Add a tank track by specifying the number of wheels along the track track and an array of wheel ids s...
Definition PxVehicleDrivetrainParams.h:867
PX_FORCE_INLINE PxU32 getWheelInTrack(const PxU32 j, const PxU32 i) const
Return the wheel id of the jth wheel in the ith track.
Definition PxVehicleDrivetrainParams.h:921
PxU32 nbWheelsInTracks
The number of wheels in all tracks.
Definition PxVehicleDrivetrainParams.h:981
PX_FORCE_INLINE PxU32 getThrustControllerIndex(const PxU32 i) const
Return the index of the thrust controller that will control a specified track.
Definition PxVehicleDrivetrainParams.h:931
PxU32 nbTracks
The number of tracks.
Definition PxVehicleDrivetrainParams.h:975
PX_FORCE_INLINE const PxU32 * getWheelsInTrack(const PxU32 i) const
Return the array of all wheels in the ith track.
Definition PxVehicleDrivetrainParams.h:909
PX_FORCE_INLINE PxU32 getNbTracks() const
Return the number of tracks.
Definition PxVehicleDrivetrainParams.h:888
PX_FORCE_INLINE PxU32 getNbWheelsInTrack(const PxU32 i) const
Return the number of wheels in the ith track.
Definition PxVehicleDrivetrainParams.h:899