RavEngine
Loading...
Searching...
No Matches
NpArticulationReducedCoordinate.h
1// Redistribution and use in source and binary forms, with or without
2// modification, are permitted provided that the following conditions
3// are met:
4// * Redistributions of source code must retain the above copyright
5// notice, this list of conditions and the following disclaimer.
6// * Redistributions in binary form must reproduce the above copyright
7// notice, this list of conditions and the following disclaimer in the
8// documentation and/or other materials provided with the distribution.
9// * Neither the name of NVIDIA CORPORATION nor the names of its
10// contributors may be used to endorse or promote products derived
11// from this software without specific prior written permission.
12//
13// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS ''AS IS'' AND ANY
14// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
15// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
16// PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
17// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
18// EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
19// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
20// PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
21// OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
22// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
23// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
24//
25// Copyright (c) 2008-2022 NVIDIA Corporation. All rights reserved.
26// Copyright (c) 2004-2008 AGEIA Technologies, Inc. All rights reserved.
27// Copyright (c) 2001-2004 NovodeX AG. All rights reserved.
28
29#ifndef NP_ARTICULATION_RC_H
30#define NP_ARTICULATION_RC_H
31
32#include "PxArticulationReducedCoordinate.h"
33
34#if PX_ENABLE_DEBUG_VISUALIZATION
35 #include "common/PxRenderOutput.h"
36#else
37 PX_CATCH_UNDEFINED_ENABLE_DEBUG_VISUALIZATION
38#endif
39
40#include "NpArticulationLink.h"
41#include "NpArticulationJointReducedCoordinate.h"
42#include "NpArticulationTendon.h"
43#include "ScArticulationCore.h"
44
45namespace physx
46{
47 class NpArticulationLink;
48 class NpScene;
49 class PxAggregate;
50 class PxConstraint;
51 class NpArticulationSpatialTendon;
52 class NpArticulationFixedTendon;
53 class NpArticulationSensor;
54
56 {
57 //= ATTENTION! =====================================================================================
58 // Changing the data layout of this class breaks the binary serialization format. See comments for
59 // PX_BINARY_SERIAL_VERSION. If a modification is required, please adjust the getBinaryMetaData
60 // function. If the modification is made on a custom branch, please change PX_BINARY_SERIAL_VERSION
61 // accordingly.
62 //==================================================================================================
63 public:
65
66 // PX_SERIALIZATION
69 NpBase(PxEmpty), mCore(PxEmpty),
70 mArticulationLinks(PxEmpty), mLoopJoints(PxEmpty), mSpatialTendons(PxEmpty), mFixedTendons(PxEmpty), mSensors(PxEmpty)
71 {
72 }
73
74 void preExportDataReset();
75 virtual void exportExtraData(PxSerializationContext& stream);
76 void importExtraData(PxDeserializationContext& context);
77 void resolveReferences(PxDeserializationContext& context);
78 virtual void requiresObjects(PxProcessPxBaseCallback& c);
79
80 static NpArticulationReducedCoordinate* createObject(PxU8*& address, PxDeserializationContext& context);
81 static void getBinaryMetaData(PxOutputStream& stream);
82 //~PX_SERIALIZATION
83
84 virtual void release();
85 //---------------------------------------------------------------------------------
86 // PxArticulationReducedCoordinate implementation
87 //---------------------------------------------------------------------------------
88 virtual PxScene* getScene() const { return NpBase::getNpScene(); }
89
90 virtual void setSleepThreshold(PxReal threshold);
91 virtual PxReal getSleepThreshold() const;
92
93 virtual void setStabilizationThreshold(PxReal threshold);
94 virtual PxReal getStabilizationThreshold() const;
95
96 virtual void setWakeCounter(PxReal wakeCounterValue);
97 virtual PxReal getWakeCounter() const;
98
99 virtual void setSolverIterationCounts(PxU32 positionIters, PxU32 velocityIters);// { mImpl.setSolverIterationCounts(positionIters, velocityIters); }
100 virtual void getSolverIterationCounts(PxU32 & positionIters, PxU32 & velocityIters) const;// { mImpl.getSolverIterationCounts(positionIters, velocityIters); }
101
102 virtual bool isSleeping() const;
103 virtual void wakeUp();
104 virtual void putToSleep();
105
106 virtual void setMaxCOMLinearVelocity(const PxReal maxLinearVelocity);
107 virtual PxReal getMaxCOMLinearVelocity() const;
108 virtual void setMaxCOMAngularVelocity(const PxReal maxAngularVelocity);
109 virtual PxReal getMaxCOMAngularVelocity() const;
110
111 virtual PxU32 getNbLinks() const;
112 virtual PxU32 getLinks(PxArticulationLink** userBuffer, PxU32 bufferSize, PxU32 startIndex) const;
113 /*{
114 return mImpl.getLinks(userBuffer, bufferSize, startIndex);
115 }
116*/
117 virtual PxU32 getNbShapes() const;
118
119 virtual PxBounds3 getWorldBounds(float inflation = 1.01f) const;
120
121 virtual PxAggregate* getAggregate() const;
122
123 // Debug name
124 virtual void setName(const char* name);
125 virtual const char* getName() const;
126
127 virtual PxArticulationLink* createLink(PxArticulationLink* parent, const PxTransform& pose);
128
129
130 virtual void setArticulationFlags(PxArticulationFlags flags);
131
132 virtual void setArticulationFlag(PxArticulationFlag::Enum flag, bool value);
133
135
136 virtual PxU32 getDofs() const;
137
138 virtual PxArticulationCache* createCache() const;
139
140 virtual PxU32 getCacheDataSize() const;
141
142 virtual void zeroCache(PxArticulationCache& cache) const;
143
144 virtual void applyCache(PxArticulationCache& cache, const PxArticulationCacheFlags flags, bool autowake);
145
146 virtual void copyInternalStateToCache(PxArticulationCache& cache, const PxArticulationCacheFlags flags) const;
147
148 virtual void packJointData(const PxReal* maximum, PxReal* reduced) const;
149
150 virtual void unpackJointData(const PxReal* reduced, PxReal* maximum) const;
151
152 virtual void commonInit() const;
153
154 virtual void computeGeneralizedGravityForce(PxArticulationCache& cache) const;
155
157
158 virtual void computeGeneralizedExternalForce(PxArticulationCache& cache) const;
159
160 virtual void computeJointAcceleration(PxArticulationCache& cache) const;
161
162 virtual void computeJointForce(PxArticulationCache& cache) const;
163
164
165 virtual void computeDenseJacobian(PxArticulationCache& cache, PxU32& nRows, PxU32& nCols) const;
166
167 virtual void computeCoefficientMatrix(PxArticulationCache& cache) const;
168
169 virtual bool computeLambda(PxArticulationCache& cache, PxArticulationCache& rollBackCache, const PxReal* const jointTorque, const PxU32 maxIter) const;
170
171 virtual void computeGeneralizedMassMatrix(PxArticulationCache& cache) const;
172
173 virtual void addLoopJoint(PxConstraint* joint);
174
175 virtual void removeLoopJoint(PxConstraint* constraint);
176
177 virtual PxU32 getNbLoopJoints() const;
178
179 virtual PxU32 getLoopJoints(PxConstraint** userBuffer, PxU32 bufferSize, PxU32 startIndex = 0) const;
180
181 virtual PxU32 getCoefficientMatrixSize() const;
182
183 virtual void setRootGlobalPose(const PxTransform& pose, bool autowake = true);
184
185 virtual PxTransform getRootGlobalPose() const;
186
187 virtual void setRootLinearVelocity(const PxVec3& velocity, bool autowake = true);
188 virtual void setRootAngularVelocity(const PxVec3& velocity, bool autowake = true);
189 virtual PxVec3 getRootLinearVelocity() const;
190 virtual PxVec3 getRootAngularVelocity() const;
191
192 virtual PxSpatialVelocity getLinkAcceleration(const PxU32 linkId);
193
194 virtual PxU32 getGpuArticulationIndex();
195
196 virtual const char* getConcreteTypeName() const { return "PxArticulationReducedCoordinate"; }
197
199
200 virtual PxU32 getSpatialTendons(PxArticulationSpatialTendon** userBuffer, PxU32 bufferSize, PxU32 startIndex) const;
201
202 virtual PxU32 getNbSpatialTendons();
203
204 NpArticulationSpatialTendon* getSpatialTendon(const PxU32 index) const;
205
207
208 virtual PxU32 getFixedTendons(PxArticulationFixedTendon** userBuffer, PxU32 bufferSize, PxU32 startIndex) const;
209
210 virtual PxU32 getNbFixedTendons();
211
212 NpArticulationFixedTendon* getFixedTendon(const PxU32 index) const;
213
214 virtual PxArticulationSensor* createSensor(PxArticulationLink* link, const PxTransform& relativePose);
215
216 virtual void releaseSensor(PxArticulationSensor& sensor);
217
218 virtual PxU32 getSensors(PxArticulationSensor** userBuffer, PxU32 bufferSize, PxU32 startIndex) const;
219
220 virtual PxU32 getNbSensors();
221
222 NpArticulationSensor* getSensor(const PxU32 index) const;
223
225
226 PX_FORCE_INLINE PxArray<NpArticulationSpatialTendon*>& getSpatialTendons() { return mSpatialTendons; }
227 PX_FORCE_INLINE PxArray<NpArticulationFixedTendon*>& getFixedTendons() { return mFixedTendons; }
228 PX_FORCE_INLINE PxArray<NpArticulationSensor*>& getSensors() { return mSensors; }
229
230 //---------------------------------------------------------------------------------
231 // Miscellaneous
232 //---------------------------------------------------------------------------------
233 NpArticulationReducedCoordinate();
234
235 virtual bool isKindOf(const char* name) const { return !::strcmp("PxArticulationReducedCoordinate", name) || PxBase::isKindOf(name); }
236
237 PxArticulationJointReducedCoordinate* createArticulationJoint(PxArticulationLink& parent,
238 const PxTransform& parentFrame,
239 PxArticulationLink& child,
240 const PxTransform& childFrame);
241
242 PX_INLINE void incrementShapeCount() { mNumShapes++; }
243 PX_INLINE void decrementShapeCount() { mNumShapes--; }
244
245 //---------------------------------------------------------------------------------
246 // Miscellaneous
247 //---------------------------------------------------------------------------------
248
249 PX_INLINE void addToLinkList(NpArticulationLink& link) { mArticulationLinks.pushBack(&link); mNumShapes += link.getNbShapes(); }
250 PX_INLINE bool removeLinkFromList(NpArticulationLink& link)
251 {
252 PX_ASSERT(mArticulationLinks.find(&link) != mArticulationLinks.end());
253 mTopologyChanged = true;
254 return mArticulationLinks.findAndReplaceWithLast(&link);
255 }
256 PX_FORCE_INLINE NpArticulationLink* const* getLinks() { return mArticulationLinks.begin(); }
257
258 NpArticulationLink* getRoot();
259 void setAggregate(PxAggregate* a);
260
261 void wakeUpInternal(bool forceWakeUp, bool autowake);
262 void autoWakeInternal();
263
264 void setGlobalPose();
265
266 PX_FORCE_INLINE Sc::ArticulationCore& getCore() { return mCore; }
267 PX_FORCE_INLINE const Sc::ArticulationCore& getCore() const { return mCore; }
268 static PX_FORCE_INLINE size_t getCoreOffset() { return PX_OFFSET_OF_RT(NpArticulationReducedCoordinate, mCore); }
269
270
271 PX_INLINE void scSetSolverIterationCounts(PxU16 v)
272 {
273 PX_ASSERT(!isAPIWriteForbidden());
274 mCore.setSolverIterationCounts(v);
275 UPDATE_PVD_PROPERTY
276 }
277
278 PX_INLINE void scSetSleepThreshold(const PxReal v)
279 {
280 PX_ASSERT(!isAPIWriteForbidden());
281 mCore.setSleepThreshold(v);
282 UPDATE_PVD_PROPERTY
283 }
284
285 PX_INLINE void scSetFreezeThreshold(const PxReal v)
286 {
287 PX_ASSERT(!isAPIWriteForbidden());
288 mCore.setFreezeThreshold(v);
289 UPDATE_PVD_PROPERTY
290 }
291
292 PX_INLINE void scSetWakeCounter(PxReal counter)
293 {
294 PX_ASSERT(!isAPIWriteForbiddenExceptSplitSim());
295 mCore.setWakeCounter(counter);
296 UPDATE_PVD_PROPERTY
297 }
298
299 PX_FORCE_INLINE void scSetArticulationFlags(PxArticulationFlags flags)
300 {
301 PX_ASSERT(!isAPIWriteForbidden());
302 mCore.setArticulationFlags(flags);
303 UPDATE_PVD_PROPERTY
304 }
305
306 PX_FORCE_INLINE void scWakeUpInternal(PxReal wakeCounter)
307 {
308 PX_ASSERT(getNpScene());
309 PX_ASSERT(!isAPIWriteForbiddenExceptSplitSim());
310 mCore.wakeUp(wakeCounter);
311 }
312
313 PX_FORCE_INLINE void scSetMaxLinearVelocity(PxReal maxLinearVelocity)
314 {
315 PX_ASSERT(!isAPIWriteForbidden());
316 mCore.setMaxLinearVelocity(maxLinearVelocity);
317 UPDATE_PVD_PROPERTY
318 }
319
320 PX_FORCE_INLINE void scSetMaxAngularVelocity(PxReal maxAngularVelocity)
321 {
322 PX_ASSERT(!isAPIWriteForbidden());
323 mCore.setMaxAngularVelocity(maxAngularVelocity);
324 UPDATE_PVD_PROPERTY
325 }
326
327 void recomputeLinkIDs();
328
329
330#if PX_ENABLE_DEBUG_VISUALIZATION
331public:
332 void visualize(PxRenderOutput& out, NpScene& scene, float scale) const;
333#else
334 PX_CATCH_UNDEFINED_ENABLE_DEBUG_VISUALIZATION
335#endif
336
337 Sc::ArticulationCore mCore;
338 NpArticulationLinkArray mArticulationLinks;
339 PxU32 mNumShapes;
340 NpAggregate* mAggregate;
341 const char* mName;
342 PxU32 mCacheVersion;
343 bool mTopologyChanged;
344
345 private:
346
347 void removeSpatialTendonInternal(NpArticulationSpatialTendon* tendon);
348 void removeFixedTendonInternal(NpArticulationFixedTendon* tendon);
349 void removeSensorInternal(NpArticulationSensor* sensor);
350
351 PxArray<NpConstraint*> mLoopJoints;
352 PxArray<NpArticulationSpatialTendon*> mSpatialTendons;
353 PxArray<NpArticulationFixedTendon*> mFixedTendons;
354 PxArray<NpArticulationSensor*> mSensors;
355
356 friend class NpScene;
357 };
358
359
360}
361
362#endif
Definition base.h:1940
Definition NpArticulationTendon.h:258
Definition NpArticulationReducedCoordinate.h:56
virtual void release()
Releases the articulation, and all its links and corresponding joints.
Definition NpArticulationReducedCoordinate.cpp:835
virtual void updateKinematic(PxArticulationKinematicFlags flags)
Update link velocities and/or positions in the articulation.
Definition NpArticulationReducedCoordinate.cpp:664
virtual PxVec3 getRootAngularVelocity() const
Gets the root link angular velocity.
Definition NpArticulationReducedCoordinate.cpp:487
virtual PxU32 getNbShapes() const
Returns the number of shapes in the articulation.
Definition NpArticulationReducedCoordinate.cpp:1150
virtual PxArticulationSensor * createSensor(PxArticulationLink *link, const PxTransform &relativePose)
Creates a force sensor attached to a link of the articulation.
Definition NpArticulationReducedCoordinate.cpp:575
virtual PxArticulationFlags getArticulationFlags() const
Returns the articulation's flags.
Definition NpArticulationReducedCoordinate.cpp:110
virtual void computeGeneralizedExternalForce(PxArticulationCache &cache) const
Computes the joint DOF forces required to counteract external spatial forces applied to articulation ...
Definition NpArticulationReducedCoordinate.cpp:249
virtual void copyInternalStateToCache(PxArticulationCache &cache, const PxArticulationCacheFlags flags) const
Copies internal data of the articulation to the cache.
Definition NpArticulationReducedCoordinate.cpp:191
virtual void computeJointForce(PxArticulationCache &cache) const
Computes the joint forces for the given articulation state and joint accelerations,...
Definition NpArticulationReducedCoordinate.cpp:271
virtual void getSolverIterationCounts(PxU32 &positionIters, PxU32 &velocityIters) const
Returns the solver iteration counts.
Definition NpArticulationReducedCoordinate.cpp:926
virtual PxU32 getNbSensors()
Returns the number of sensors in the articulation.
Definition NpArticulationReducedCoordinate.cpp:624
virtual PxArticulationSpatialTendon * createSpatialTendon()
Creates a spatial tendon to attach to the articulation with default attribute values.
Definition NpArticulationReducedCoordinate.cpp:519
virtual void setArticulationFlags(PxArticulationFlags flags)
Sets flags on the articulation.
Definition NpArticulationReducedCoordinate.cpp:81
virtual void unpackJointData(const PxReal *reduced, PxReal *maximum) const
Converts reduced-coordinate joint DOF data to maximal coordinates.
Definition NpArticulationReducedCoordinate.cpp:209
virtual void setMaxCOMAngularVelocity(const PxReal maxAngularVelocity)
Sets the limit on the magnitude of the angular velocity at the articulation's center of mass.
Definition NpArticulationReducedCoordinate.cpp:1121
virtual void addLoopJoint(PxConstraint *joint)
Adds a loop joint to the articulation system for inverse dynamics.
Definition NpArticulationReducedCoordinate.cpp:333
virtual PxReal getStabilizationThreshold() const
Returns the mass-normalized kinetic energy below which the articulation may participate in stabilizat...
Definition NpArticulationReducedCoordinate.cpp:998
virtual PxScene * getScene() const
Returns the scene which this articulation belongs to.
Definition NpArticulationReducedCoordinate.h:88
virtual void setRootGlobalPose(const PxTransform &pose, bool autowake=true)
Sets the root link transform (world to actor frame).
Definition NpArticulationReducedCoordinate.cpp:419
virtual void setRootAngularVelocity(const PxVec3 &velocity, bool autowake=true)
Sets the root link angular velocity.
Definition NpArticulationReducedCoordinate.cpp:459
virtual void packJointData(const PxReal *maximum, PxReal *reduced) const
Converts maximal-coordinate joint DOF data to reduced coordinates.
Definition NpArticulationReducedCoordinate.cpp:201
virtual void setStabilizationThreshold(PxReal threshold)
Sets the mass-normalized kinetic energy threshold below which the articulation may participate in sta...
Definition NpArticulationReducedCoordinate.cpp:987
virtual void setName(const char *name)
Sets a name string for the articulation that can be retrieved with getName().
Definition NpArticulationReducedCoordinate.cpp:1182
virtual void removeLoopJoint(PxConstraint *constraint)
Removes a loop joint from the articulation for inverse dynamics.
Definition NpArticulationReducedCoordinate.cpp:381
virtual PxTransform getRootGlobalPose() const
Returns the root link transform (world to actor frame).
Definition NpArticulationReducedCoordinate.cpp:431
virtual PxU32 getCacheDataSize() const
Returns the size of the articulation cache in bytes.
Definition NpArticulationReducedCoordinate.cpp:135
virtual PxVec3 getRootLinearVelocity() const
Gets the root link center-of-mass linear velocity.
Definition NpArticulationReducedCoordinate.cpp:476
virtual PxArticulationLink * createLink(PxArticulationLink *parent, const PxTransform &pose)
Adds a link to the articulation with default attribute values.
Definition NpArticulationReducedCoordinate.cpp:875
virtual PxU32 getLinks(PxArticulationLink **userBuffer, PxU32 bufferSize, PxU32 startIndex) const
Returns the set of links in the articulation in the order that they were added to the articulation us...
Definition NpArticulationReducedCoordinate.cpp:1144
virtual void computeCoriolisAndCentrifugalForce(PxArticulationCache &cache) const
Computes the joint DOF forces required to counteract Coriolis and centrifugal forces for the given ar...
Definition NpArticulationReducedCoordinate.cpp:238
virtual void wakeUp()
Wakes up the articulation if it is sleeping.
Definition NpArticulationReducedCoordinate.cpp:1072
virtual void zeroCache(PxArticulationCache &cache) const
Zeroes all data in the articulation cache, except user-provided and scratch memory,...
Definition NpArticulationReducedCoordinate.cpp:142
virtual void computeGeneralizedGravityForce(PxArticulationCache &cache) const
Computes the joint DOF forces required to counteract gravitational forces for the given articulation ...
Definition NpArticulationReducedCoordinate.cpp:227
virtual PxArticulationCache * createCache() const
Creates an articulation cache that can be used to read and write internal articulation data.
Definition NpArticulationReducedCoordinate.cpp:123
virtual void computeCoefficientMatrix(PxArticulationCache &cache) const
Computes the coefficient matrix for contact forces.
Definition NpArticulationReducedCoordinate.cpp:293
virtual void setRootLinearVelocity(const PxVec3 &velocity, bool autowake=true)
Sets the root link linear center-of-mass velocity.
Definition NpArticulationReducedCoordinate.cpp:442
virtual PxReal getMaxCOMAngularVelocity() const
Gets the limit on the magnitude of the angular velocity at the articulation's center of mass.
Definition NpArticulationReducedCoordinate.cpp:1132
virtual void commonInit() const
Prepares common articulation data based on articulation pose for inverse dynamics calculations.
Definition NpArticulationReducedCoordinate.cpp:217
virtual PxReal getWakeCounter() const
Returns the wake counter of the articulation in seconds.
Definition NpArticulationReducedCoordinate.cpp:1020
virtual void applyCache(PxArticulationCache &cache, const PxArticulationCacheFlags flags, bool autowake)
Applies the data in the cache to the articulation.
Definition NpArticulationReducedCoordinate.cpp:152
virtual bool isSleeping() const
Returns true if this articulation is sleeping.
Definition NpArticulationReducedCoordinate.cpp:960
virtual PxU32 getCoefficientMatrixSize() const
Returns the required size of the coefficient matrix in the articulation.
Definition NpArticulationReducedCoordinate.cpp:410
virtual const char * getName() const
Returns the name string set with setName().
Definition NpArticulationReducedCoordinate.cpp:1188
virtual void setWakeCounter(PxReal wakeCounterValue)
Sets the wake counter for the articulation in seconds.
Definition NpArticulationReducedCoordinate.cpp:1004
virtual PxReal getSleepThreshold() const
Returns the mass-normalized energy below which the articulation may go to sleep.
Definition NpArticulationReducedCoordinate.cpp:981
virtual PxU32 getDofs() const
Returns the total number of joint degrees-of-freedom (DOFs) of the articulation.
Definition NpArticulationReducedCoordinate.cpp:116
virtual const char * getConcreteTypeName() const
Returns string name of dynamic type.
Definition NpArticulationReducedCoordinate.h:196
virtual void computeJointAcceleration(PxArticulationCache &cache) const
Computes the joint accelerations for the given articulation state and joint forces.
Definition NpArticulationReducedCoordinate.cpp:260
virtual PxU32 getNbLoopJoints() const
Returns the number of loop joints in the articulation for inverse dynamics.
Definition NpArticulationReducedCoordinate.cpp:396
virtual PxU32 getNbLinks() const
Returns the number of links in the articulation.
Definition NpArticulationReducedCoordinate.cpp:1138
virtual PxU32 getNbFixedTendons()
Returns the number of fixed tendons in the articulation.
Definition NpArticulationReducedCoordinate.cpp:654
virtual PxU32 getGpuArticulationIndex()
Returns the GPU articulation index.
Definition NpArticulationReducedCoordinate.cpp:509
virtual PxAggregate * getAggregate() const
Returns the aggregate the articulation might be a part of.
Definition NpArticulationReducedCoordinate.cpp:1176
virtual PxU32 getSensors(PxArticulationSensor **userBuffer, PxU32 bufferSize, PxU32 startIndex) const
Returns the sensors attached to the articulation.
Definition NpArticulationReducedCoordinate.cpp:619
virtual PxArticulationFixedTendon * createFixedTendon()
Creates a fixed tendon to attach to the articulation with default attribute values.
Definition NpArticulationReducedCoordinate.cpp:544
virtual void setArticulationFlag(PxArticulationFlag::Enum flag, bool value)
Raises or clears a flag on the articulation.
Definition NpArticulationReducedCoordinate.cpp:92
virtual PxU32 getLoopJoints(PxConstraint **userBuffer, PxU32 bufferSize, PxU32 startIndex=0) const
Returns the set of loop constraints (i.e. joints) in the articulation.
Definition NpArticulationReducedCoordinate.cpp:403
virtual void setMaxCOMLinearVelocity(const PxReal maxLinearVelocity)
Sets the limit on the magnitude of the linear velocity of the articulation's center of mass.
Definition NpArticulationReducedCoordinate.cpp:1104
virtual bool computeLambda(PxArticulationCache &cache, PxArticulationCache &rollBackCache, const PxReal *const jointTorque, const PxU32 maxIter) const
Computes the lambda values when the test impulse is 1.
Definition NpArticulationReducedCoordinate.cpp:307
virtual void computeGeneralizedMassMatrix(PxArticulationCache &cache) const
Compute the joint-space inertia matrix that maps joint accelerations to joint forces: forces = M * ac...
Definition NpArticulationReducedCoordinate.cpp:322
virtual void setSleepThreshold(PxReal threshold)
Sets the mass-normalized energy threshold below which the articulation may go to sleep.
Definition NpArticulationReducedCoordinate.cpp:970
virtual void computeDenseJacobian(PxArticulationCache &cache, PxU32 &nRows, PxU32 &nCols) const
Compute the dense Jacobian for the articulation in world space, including the DOFs of a potentially f...
Definition NpArticulationReducedCoordinate.cpp:282
virtual PxBounds3 getWorldBounds(float inflation=1.01f) const
Returns the axis-aligned bounding box enclosing the articulation.
Definition NpArticulationReducedCoordinate.cpp:1156
virtual void putToSleep()
Forces the articulation to sleep.
Definition NpArticulationReducedCoordinate.cpp:1088
virtual bool isKindOf(const char *name) const
Returns whether a given type name matches with the type of this instance.
Definition NpArticulationReducedCoordinate.h:235
virtual PxReal getMaxCOMLinearVelocity() const
Gets the limit on the magnitude of the linear velocity of the articulation's center of mass.
Definition NpArticulationReducedCoordinate.cpp:1115
virtual PxSpatialVelocity getLinkAcceleration(const PxU32 linkId)
Returns the (classical) link acceleration in world space for the given low-level link index.
Definition NpArticulationReducedCoordinate.cpp:498
virtual void setSolverIterationCounts(PxU32 positionIters, PxU32 velocityIters)
Sets the solver iteration counts for the articulation.
Definition NpArticulationReducedCoordinate.cpp:911
virtual PxU32 getNbSpatialTendons()
Returns the number of spatial tendons in the articulation.
Definition NpArticulationReducedCoordinate.cpp:639
Definition NpArticulationSensor.h:44
Definition NpArticulationTendon.h:150
Definition NpBase.h:167
Class to aggregate actors into a single broad-phase entry.
Definition PxAggregate.h:98
Definition PxArray.h:53
PX_INLINE Iterator find(const T &a)
Definition PxArray.h:272
PX_FORCE_INLINE ConstIterator end() const
Definition PxArray.h:192
PX_FORCE_INLINE ConstIterator begin() const
Definition PxArray.h:176
PX_FORCE_INLINE T & pushBack(const T &a)
Definition PxArray.h:296
PX_INLINE bool findAndReplaceWithLast(const T &a)
Definition PxArray.h:368
Data structure used to read and write internal articulation data.
Definition PxArticulationReducedCoordinate.h:99
A fixed tendon that can be used to link multiple degrees of freedom of multiple articulation joints v...
Definition PxArticulationTendon.h:478
A joint between two links in an articulation.
Definition PxArticulationJointReducedCoordinate.h:49
A tree structure of bodies connected by joints that is treated as a unit by the dynamics solver....
Definition PxArticulationReducedCoordinate.h:448
A force sensor that can be attached to articulation links to measure spatial force.
Definition PxArticulationReducedCoordinate.h:313
A spatial tendon that attaches to an articulation.
Definition PxArticulationTendon.h:413
virtual bool isKindOf(const char *superClass) const
Returns whether a given type name matches with the type of this instance.
Definition PxBase.h:179
Class representing 3D range or axis aligned bounding box.
Definition PxBounds3.h:58
A plugin class for implementing constraints.
Definition PxConstraint.h:100
Binary deserialization context class.
Definition PxSerialFramework.h:174
Output stream class for I/O.
Definition PxIO.h:114
Callback class used to process PxBase objects.
Definition PxSerialFramework.h:81
A scene is a collection of bodies and constraints which can interact.
Definition PxScene.h:178
Binary serialization context class.
Definition PxSerialFramework.h:99
class representing a rigid euclidean transform as a quaternion and a vector
Definition PxTransform.h:49
3 Element vector class.
Definition PxVec3.h:50
#define PX_FORCE_INLINE
Definition PxPreprocessor.h:335
#define PX_INLINE
Definition PxPreprocessor.h:320
Sorts an array of objects in ascending order, assuming that the predicate implements the < operator:
Definition PxBoxController.h:39
Enum
Definition PxSolverDefs.h:294
Data structure to represent spatial velocities.
Definition PxArticulationReducedCoordinate.h:66