PxVehicleSDK.h
Go to the documentation of this file.
1 //
2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions
4 // are met:
5 // * Redistributions of source code must retain the above copyright
6 // notice, this list of conditions and the following disclaimer.
7 // * Redistributions in binary form must reproduce the above copyright
8 // notice, this list of conditions and the following disclaimer in the
9 // documentation and/or other materials provided with the distribution.
10 // * Neither the name of NVIDIA CORPORATION nor the names of its
11 // contributors may be used to endorse or promote products derived
12 // from this software without specific prior written permission.
13 //
14 // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS ''AS IS'' AND ANY
15 // EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
16 // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
17 // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
18 // CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
19 // EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
20 // PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
21 // PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
22 // OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23 // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
24 // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25 //
26 // Copyright (c) 2008-2021 NVIDIA Corporation. All rights reserved.
27 // Copyright (c) 2004-2008 AGEIA Technologies, Inc. All rights reserved.
28 // Copyright (c) 2001-2004 NovodeX AG. All rights reserved.
29 
30 #ifndef PX_VEHICLE_SDK_H
31 #define PX_VEHICLE_SDK_H
32 
36 #include "foundation/Px.h"
37 #include "common/PxTypeInfo.h"
38 
39 #if !PX_DOXYGEN
40 namespace physx
41 {
42 #endif
43 
44 class PxPhysics;
46 
60 PX_C_EXPORT bool PX_CALL_CONV PxInitVehicleSDK(PxPhysics& physics, PxSerializationRegistry* serializationRegistry = NULL);
61 
62 
75 PX_C_EXPORT void PX_CALL_CONV PxCloseVehicleSDK(PxSerializationRegistry* serializationRegistry = NULL);
76 
77 
81 #define PX_MAX_NB_WHEELS (20)
82 
83 
89 #define PX_DEBUG_VEHICLE_ON (1)
90 
91 
96 {
97  enum Enum
98  {
99  eDRIVE4W=0,
106  eMAX_NB_VEHICLE_TYPES
107  };
108 };
109 
110 
117 {
118  enum Enum
119  {
123  eVehicleDriveTank
124  };
125 };
126 
127 
135 void PxVehicleSetBasisVectors(const PxVec3& up, const PxVec3& forward);
136 
137 
142 {
143  enum Enum
144  {
146  eACCELERATION
147  };
148 };
149 
150 
162 void PxVehicleSetUpdateMode(PxVehicleUpdateMode::Enum vehicleUpdateMode);
163 
216 void PxVehicleSetSweepHitRejectionAngles(const PxF32 pointRejectAngle, const PxF32 normalRejectAngle);
217 
218 
230 void PxVehicleSetMaxHitActorAcceleration(const PxF32 maxHitActorAcceleration);
231 
232 #if !PX_DOXYGEN
233 } // namespace physx
234 #endif
235 
237 #endif //PX_VEHICLE_SDK_H
Definition: GuContactBuffer.h:37
PX_C_EXPORT void PX_CALL_CONV PxCloseVehicleSDK(PxSerializationRegistry *serializationRegistry=NULL)
Shut down the PhysXVehicle library.
Definition: PxVehicleSDK.h:141
void PxVehicleSetSweepHitRejectionAngles(const PxF32 pointRejectAngle, const PxF32 normalRejectAngle)
Set threshold angles that are used to determine if a wheel hit is to be resolved by vehicle suspensio...
Class serving as a registry for XML (RepX) and binary serializable types.
Definition: PxSerialFramework.h:290
float PxF32
Definition: PxSimpleTypes.h:76
Definition: PxVehicleSDK.h:105
Enum
Definition: PxVehicleSDK.h:97
#define PX_C_EXPORT
Definition: Pxc.h:54
#define PX_CALL_CONV
Definition: PxPreprocessor.h:315
Enum
Definition: PxVehicleSDK.h:143
void PxVehicleSetMaxHitActorAcceleration(const PxF32 maxHitActorAcceleration)
Determine the maximum acceleration experienced by PxRigidDynamic instances that are found to be in co...
void PxVehicleSetUpdateMode(PxVehicleUpdateMode::Enum vehicleUpdateMode)
Set the effect of PxVehicleUpdates to be either to modify each vehicle's rigid body actor...
Definition: PxVehicleSDK.h:95
Definition: PxVehicleSDK.h:145
Definition: PxVehicleSDK.h:103
Definition: PxVehicleSDK.h:104
Definition: PxVehicleSDK.h:121
Definition: PxVehicleSDK.h:122
Definition: PxVehicleSDK.h:100
Enum
Definition: PxVehicleSDK.h:118
Definition: PxVehicleSDK.h:102
Definition: PxVehicleSDK.h:101
PX_C_EXPORT bool PX_CALL_CONV PxInitVehicleSDK(PxPhysics &physics, PxSerializationRegistry *serializationRegistry=NULL)
Initialize the PhysXVehicle library.
Definition: PxTypeInfo.h:80
Abstract singleton factory class used for instancing objects in the Physics SDK.
Definition: PxPhysics.h:71
An enumeration of concrete vehicle classes inheriting from PxBase.
Definition: PxVehicleSDK.h:116
3 Element vector class.
Definition: PxVec3.h:49
void PxVehicleSetBasisVectors(const PxVec3 &up, const PxVec3 &forward)
Set the basis vectors of the vehicle simulation.