RavEngine
Loading...
Searching...
No Matches
physx::PxArticulationSpatialTendon Class Referenceabstract

A spatial tendon that attaches to an articulation. More...

#include <PxArticulationTendon.h>

Inheritance diagram for physx::PxArticulationSpatialTendon:
[legend]
Collaboration diagram for physx::PxArticulationSpatialTendon:
[legend]

Public Member Functions

virtual PxArticulationAttachment * createAttachment (PxArticulationAttachment *parent, const PxReal coefficient, const PxVec3 relativeOffset, PxArticulationLink *link)=0
 Creates an articulation attachment and adds it to the list of children in the parent attachment.
 
virtual PxU32 getAttachments (PxArticulationAttachment **userBuffer, PxU32 bufferSize, PxU32 startIndex=0) const =0
 Fills a user-provided buffer of attachment pointers with the set of attachments.
 
virtual PxU32 getNbAttachments () const =0
 Returns the number of attachments in the tendon.
 
virtual const char * getConcreteTypeName () const
 Returns the string name of the dynamic type.
 
- Public Member Functions inherited from physx::PxArticulationTendon
virtual void setStiffness (const PxReal stiffness)=0
 Sets the spring stiffness term acting on the tendon length.
 
virtual PxReal getStiffness () const =0
 Gets the spring stiffness of the tendon.
 
virtual void setDamping (const PxReal damping)=0
 Sets the damping term acting both on the tendon length and tendon-length limits.
 
virtual PxReal getDamping () const =0
 Gets the damping term acting both on the tendon length and tendon-length limits.
 
virtual void setLimitStiffness (const PxReal stiffness)=0
 Sets the limit stiffness term acting on the tendon's length limits.
 
virtual PxReal getLimitStiffness () const =0
 Gets the limit stiffness term acting on the tendon's length limits.
 
virtual void setOffset (const PxReal offset, bool autowake=true)=0
 Sets the length offset term for the tendon.
 
virtual PxReal getOffset () const =0
 Gets the length offset term for the tendon.
 
virtual PxArticulationReducedCoordinate * getArticulation () const =0
 Gets the articulation that the tendon is a part of.
 
virtual void release ()=0
 Releases a tendon to remove it from the articulation and free its associated memory.
 
- Public Member Functions inherited from physx::PxBase
template<class T >
T * is ()
 
template<class T >
const T * is () const
 
PX_FORCE_INLINE PxType getConcreteType () const
 Returns concrete type of object.
 
PX_FORCE_INLINE void setBaseFlag (PxBaseFlag::Enum flag, bool value)
 Set PxBaseFlag

 
PX_FORCE_INLINE void setBaseFlags (PxBaseFlags inFlags)
 Set PxBaseFlags

 
PX_FORCE_INLINE PxBaseFlags getBaseFlags () const
 Returns PxBaseFlags.
 
virtual bool isReleasable () const
 Whether the object is subordinate.
 

Protected Member Functions

PX_INLINE PxArticulationSpatialTendon (PxType concreteType, PxBaseFlags baseFlags)
 
PX_INLINE PxArticulationSpatialTendon (PxBaseFlags baseFlags)
 
- Protected Member Functions inherited from physx::PxArticulationTendon
PX_INLINE PxArticulationTendon (PxType concreteType, PxBaseFlags baseFlags)
 
PX_INLINE PxArticulationTendon (PxBaseFlags baseFlags)
 
- Protected Member Functions inherited from physx::PxBase
PX_INLINE PxBase (PxType concreteType, PxBaseFlags baseFlags)
 Constructor setting concrete type and base flags.
 
PX_INLINE PxBase (PxBaseFlags baseFlags)
 Deserialization constructor setting base flags.
 
virtual ~PxBase ()
 Destructor.
 
virtual bool isKindOf (const char *superClass) const
 Returns whether a given type name matches with the type of this instance.
 
template<class T >
bool typeMatch () const
 

Additional Inherited Members

- Public Attributes inherited from physx::PxArticulationTendon
void * userData
 user can assign this to whatever, usually to create a 1:1 relationship with a user object.
 
- Protected Attributes inherited from physx::PxBase
PxType mConcreteType
 
PxBaseFlags mBaseFlags
 
PxU32 mBuiltInRefCount
 

Detailed Description

A spatial tendon that attaches to an articulation.

A spatial tendon attaches to multiple links in an articulation using a set of PxArticulationAttachments. The tendon is defined as a tree of attachment points, where each attachment can have an arbitrary number of children. Each leaf of the attachment tree defines a subtendon between itself and the root attachment. The subtendon then applies forces at the leaf, and an equal but opposing force at the root, in order to satisfy the spring-damper and limit constraints that the user sets up. Attachments in between the root and leaf do not exert any force on the articulation, but define the geometry of the tendon from which the length is computed together with the attachment coefficients.

Member Function Documentation

◆ createAttachment()

virtual PxArticulationAttachment * physx::PxArticulationSpatialTendon::createAttachment ( PxArticulationAttachment *  parent,
const PxReal  coefficient,
const PxVec3  relativeOffset,
PxArticulationLink *  link 
)
pure virtual

Creates an articulation attachment and adds it to the list of children in the parent attachment.

Creating an attachment is not allowed while the articulation is in a scene. In order to add the attachment, remove and then re-add the articulation to the scene.

Parameters
[in]parentThe parent attachment. Can be NULL for the root attachment of a tendon.
[in]coefficientA user-defined scale that the accumulated length is scaled by.
[in]relativeOffsetAn offset vector in the link's actor frame to the point where the tendon attachment is attached to the link.
[in]linkThe link that this attachment is associated with.
Returns
The newly-created attachment if creation was successful, otherwise a null pointer.
See also
releaseAttachment()

Implemented in physx::NpArticulationSpatialTendon.

◆ getAttachments()

virtual PxU32 physx::PxArticulationSpatialTendon::getAttachments ( PxArticulationAttachment **  userBuffer,
PxU32  bufferSize,
PxU32  startIndex = 0 
) const
pure virtual

Fills a user-provided buffer of attachment pointers with the set of attachments.

Parameters
[in]userBufferThe user-provided buffer.
[in]bufferSizeThe size of the buffer. If this is not large enough to contain all the pointers to attachments, only as many as can fit are written. Use getNbAttachments to size for all attachments.
[in]startIndexIndex of first attachment pointer to be retrieved.
Returns
The number of attachments that were filled into the user buffer.
See also
getNbAttachments

Implemented in physx::NpArticulationSpatialTendon.

◆ getConcreteTypeName()

virtual const char * physx::PxArticulationSpatialTendon::getConcreteTypeName ( ) const
inlinevirtual

Returns the string name of the dynamic type.

Returns
The string name.

Implements physx::PxBase.

◆ getNbAttachments()

virtual PxU32 physx::PxArticulationSpatialTendon::getNbAttachments ( ) const
pure virtual

Returns the number of attachments in the tendon.

Returns
The number of attachments.

Implemented in physx::NpArticulationSpatialTendon.


The documentation for this class was generated from the following file: