PxArticulation.h
Go to the documentation of this file.00001 // This code contains NVIDIA Confidential Information and is disclosed to you 00002 // under a form of NVIDIA software license agreement provided separately to you. 00003 // 00004 // Notice 00005 // NVIDIA Corporation and its licensors retain all intellectual property and 00006 // proprietary rights in and to this software and related documentation and 00007 // any modifications thereto. Any use, reproduction, disclosure, or 00008 // distribution of this software and related documentation without an express 00009 // license agreement from NVIDIA Corporation is strictly prohibited. 00010 // 00011 // ALL NVIDIA DESIGN SPECIFICATIONS, CODE ARE PROVIDED "AS IS.". NVIDIA MAKES 00012 // NO WARRANTIES, EXPRESSED, IMPLIED, STATUTORY, OR OTHERWISE WITH RESPECT TO 00013 // THE MATERIALS, AND EXPRESSLY DISCLAIMS ALL IMPLIED WARRANTIES OF NONINFRINGEMENT, 00014 // MERCHANTABILITY, AND FITNESS FOR A PARTICULAR PURPOSE. 00015 // 00016 // Information and code furnished is believed to be accurate and reliable. 00017 // However, NVIDIA Corporation assumes no responsibility for the consequences of use of such 00018 // information or for any infringement of patents or other rights of third parties that may 00019 // result from its use. No license is granted by implication or otherwise under any patent 00020 // or patent rights of NVIDIA Corporation. Details are subject to change without notice. 00021 // This code supersedes and replaces all information previously supplied. 00022 // NVIDIA Corporation products are not authorized for use as critical 00023 // components in life support devices or systems without express written approval of 00024 // NVIDIA Corporation. 00025 // 00026 // Copyright (c) 2008-2012 NVIDIA Corporation. All rights reserved. 00027 // Copyright (c) 2004-2008 AGEIA Technologies, Inc. All rights reserved. 00028 // Copyright (c) 2001-2004 NovodeX AG. All rights reserved. 00029 00030 00031 #ifndef PX_PHYSICS_NX_ARTICULATION 00032 #define PX_PHYSICS_NX_ARTICULATION 00033 00036 #include "PxPhysX.h" 00037 #include "common/PxSerialFramework.h" 00038 00039 #ifndef PX_DOXYGEN 00040 namespace physx 00041 { 00042 #endif 00043 00044 class PxArticulationLink; 00045 00054 class PxArticulationDriveCache; 00055 00067 class PxArticulation : public PxSerializable 00068 { 00069 public: 00077 virtual void release() = 0; 00078 00086 virtual PxScene* getScene() const = 0; 00087 00088 00101 virtual void setMaxProjectionIterations(PxU32 iterations) = 0; 00102 00111 virtual PxU32 getMaxProjectionIterations() const = 0; 00112 00124 virtual void setSeparationTolerance(PxReal tolerance) = 0; 00125 00134 virtual PxReal getSeparationTolerance() const = 0; 00135 00136 00149 virtual void setInternalDriveIterations(PxU32 iterations) = 0; 00150 00159 virtual PxU32 getInternalDriveIterations() const = 0; 00160 00161 00175 virtual void setExternalDriveIterations(PxU32 iterations) = 0; 00176 00185 virtual PxU32 getExternalDriveIterations() const = 0; 00186 00187 00188 00203 virtual void setSolverIterationCounts(PxU32 minPositionIters, PxU32 minVelocityIters = 1) = 0; 00204 00210 virtual void getSolverIterationCounts(PxU32 & minPositionIters, PxU32 & minVelocityIters) const = 0; 00211 00226 virtual bool isSleeping() const = 0; 00227 00237 virtual void setSleepThreshold(PxReal threshold) = 0; 00238 00246 virtual PxReal getSleepThreshold() const = 0; 00247 00258 virtual void wakeUp(PxReal wakeCounterValue=PX_SLEEP_INTERVAL) = 0; 00259 00269 virtual void putToSleep() = 0; 00270 00271 00272 00285 virtual PxArticulationLink* createLink(PxArticulationLink* parent, const PxTransform& pose) = 0; 00286 00287 00292 virtual PxU32 getNbLinks() const = 0; 00293 00306 virtual PxU32 getLinks(PxArticulationLink** userBuffer, PxU32 bufferSize) const = 0; 00307 00318 virtual void setName(const char* name) = 0; 00319 00327 virtual const char* getName() const = 0; 00328 00336 virtual PxBounds3 getWorldBounds() const = 0; 00337 00345 virtual PxAggregate* getAggregate() const = 0; 00346 00361 virtual PxArticulationDriveCache* 00362 createDriveCache(PxReal compliance, PxU32 driveIterations) const = 0; 00363 00371 virtual void releaseDriveCache(PxArticulationDriveCache& driveCache) const = 0; 00372 00386 virtual void applyImpulse(PxArticulationLink* link, 00387 const PxArticulationDriveCache& driveCache, 00388 const PxVec3& linearImpulse, 00389 const PxVec3& angularImpulse) = 0; 00390 00408 virtual void computeImpulseResponse(PxArticulationLink*link, 00409 PxVec3& linearResponse, 00410 PxVec3& angularResponse, 00411 const PxArticulationDriveCache& driveCache, 00412 const PxVec3& linearImpulse, 00413 const PxVec3& angularImpulse) const = 0; 00414 00415 00416 //public variables: 00417 void* userData; 00418 00419 virtual const char* getConcreteTypeName() const { return "PxArticulation"; } 00420 00421 protected: 00422 PxArticulation(PxRefResolver& v) : PxSerializable(v) {} 00423 PX_INLINE PxArticulation() {} 00424 virtual ~PxArticulation() {} 00425 virtual bool isKindOf(const char* name) const { return !strcmp("PxArticulation", name) || PxSerializable::isKindOf(name); } 00426 00427 00428 }; 00429 00430 #ifndef PX_DOXYGEN 00431 } // namespace physx 00432 #endif 00433 00435 #endif
Copyright © 2008-2012 NVIDIA Corporation, 2701 San Tomas Expressway, Santa Clara, CA 95050 U.S.A. All rights reserved. www.nvidia.com