|
AGX Dynamics 2.41.3.0
|
Constraint attachment class for agx::RigidBody. More...
#include <Attachment.h>
Inheritance diagram for agx::RigidBodyAttachment:Public Member Functions | |
| RigidBodyAttachment (agx::RigidBody *rb, agx::Frame *relFrame) | |
| Construct given rigid body and relative frame. | |
| AGXSTREAM_DECLARE_SERIALIZABLE_BASE (agx::RigidBodyAttachment) | |
| virtual agx::Real | calculateAngularSpeed (const agx::Attachment *other) const override |
| virtual agx::Real | calculateDistance (const agx::Attachment *other) const override |
| virtual agx::Real | calculateLinearDistance (const agx::Attachment *other) const override |
| virtual agx::Real | calculateLinearSpeed (const agx::Attachment *other) const override |
| virtual agx::Vec3 | getAngularVelocity () const override |
| virtual agx::Vec3 | getLinearVelocity () const override |
| agx::RigidBody * | getRigidBody () const |
| virtual agx::Bool | objectDeleted () const override |
| void | setRigidBody (agx::RigidBody *rb) |
| Assign rigid body to this constraint frame. | |
| virtual void | transform () override |
| Transform given rigid body and frame. | |
| virtual agx::Bool | valid () const override |
Public Member Functions inherited from agx::Attachment | |
| Attachment (agx::Frame *relFrame) | |
| Construct given frame. | |
| AGXSTREAM_DECLARE_SERIALIZABLE_BASE (agx::Attachment) | |
| template<typename T > | |
| T * | as () |
Unsafe version, static cast of this to T. | |
| template<typename T > | |
| const T * | as () const |
Unsafe version, static cast of this to T. | |
| virtual agx::Real | calculateAngularSpeed (const agx::Attachment *other) const |
| virtual agx::Real | calculateDistance (const agx::Attachment *other) const |
| virtual agx::Real | calculateLinearDistance (const agx::Attachment *other) const |
| virtual agx::Real | calculateLinearSpeed (const agx::Attachment *other) const |
| const agx::Vec3 & | get (agx::Attachment::Transformed entry) const |
| virtual agx::Vec3 | getAngularVelocity () const |
| agx::Frame * | getFrame () const |
| virtual agx::Vec3 | getLinearVelocity () const |
| agx::Vec3 | getLocal (agx::Attachment::Transformed entry) const |
| template<typename T > | |
| agx::Bool | is () const |
| template<typename T > | |
| Bool | is () const |
| template<> | |
| Bool | is () const |
| virtual agx::Bool | objectDeleted () const |
| template<typename T > | |
| T * | safeAs () |
Dynamic cast of this to T. | |
| template<typename T > | |
| const T * | safeAs () const |
Dynamic cast of this to T. | |
| void | setFrame (agx::Frame *frame) |
| Assign a new frame - transformed data will be updated. | |
| virtual void | transform () |
| Subclass - implement this method! | |
| virtual agx::Bool | valid () const |
Public Member Functions inherited from agx::Referenced | |
| Referenced () | |
| Default constructor. | |
| Referenced (const Referenced &) | |
| template<typename T > | |
| T * | as () |
| Subclass casting. | |
| template<typename T > | |
| const T * | as () const |
| template<typename T > | |
| T * | asSafe () |
| Safe subclass casting, return nullptr if template type does not match. | |
| template<typename T > | |
| const T * | asSafe () const |
| int | getReferenceCount () const |
| template<typename T > | |
| bool | is () const |
| Subclass test. | |
| Referenced & | operator= (const Referenced &) |
| Assignment operator. Will increment the number of references to the referenced object. | |
| void | reference (void *ptr=nullptr) const |
| Explicitly increment the reference count by one, indicating that this object has another pointer which is referencing it. | |
| void | unreference (void *ptr=nullptr) const |
| Decrement the reference count by one, indicating that a pointer to this object is referencing it. | |
| void | unreference_nodelete () const |
| Decrement the reference count by one, indicating that a pointer to this object is referencing it. | |
Public Member Functions inherited from agxStream::Serializable | |
| virtual | ~Serializable () |
| Destructor for normal C++ use but hidden from SWIG bindings. | |
| virtual const char * | getClassName () const |
| bool | getEnableSerialization () const |
| bool | getEnableUuidGeneration () |
| agx::UInt32 | getIndex () const |
| This index is given at creation of this object. | |
| virtual StorageAgent * | getStorageAgent () const =0 |
| agx::Uuid | getUuid () const |
| bool | isFinished () const |
| void | setEnableSerialization (bool flag) |
| Set to false to disable serialization of this object. | |
| void | setFinished () |
| Tells this class that it is restored correctly and should not be deleted during destruction of an Archive. | |
| void | setUuid (const agx::Uuid &uuid) |
| Explicitly set a Uuid on a serializable object. | |
Static Public Member Functions | |
| static agxStream::Serializable * | create (agxStream::InputArchive &) |
Static Public Member Functions inherited from agx::Attachment | |
| static agxStream::Serializable * | create (agxStream::InputArchive &) |
| static void | createAttachmentBase (const agx::Vec3d &N, agx::Vec3d &U, agx::Vec3d &V) |
Given vector N, create orthonormal base. | |
| static void | createAttachmentBase (const agx::Vec3f &N, agx::Vec3f &U, agx::Vec3f &V) |
Static Public Member Functions inherited from agx::Referenced | |
| template<typename T > | |
| static bool | ValidateCast (const Referenced *object) |
Static Public Member Functions inherited from agxStream::Serializable | |
| static void | setEnableUuidGeneration (bool flag) |
| Specify if there should be UUID:s generated for each new Serializable object. By default it is enabled. | |
Protected Member Functions | |
| RigidBodyAttachment () | |
| Protected default constructor used by restore. | |
| virtual | ~RigidBodyAttachment () |
| Reference counted object, protected destructor. | |
Protected Member Functions inherited from agx::Attachment | |
| Attachment () | |
| Constructor to use during restore. | |
| virtual | ~Attachment () |
| Reference counted object, protected destructor. | |
| void | transform (const agx::AffineMatrix4x4 &cmTransform, const agx::Vec3 &cmToModel, const agx::AffineMatrix4x4 &localConstraintTransform) |
Fill Transformed data given center of mass transform and offset from model frame to center of mass frame (assumes not rotated relative each other). | |
Protected Member Functions inherited from agx::Referenced | |
| virtual | ~Referenced () |
| Destructor. | |
| void | allocateObserverVector () const |
| void | deleteUsingDeleteHandler () const |
Protected Member Functions inherited from agxStream::Serializable | |
| Serializable () | |
| Default constructor. | |
| Serializable (const Serializable &other) | |
| Copy constructor. | |
| void | generateUuid () |
Protected Attributes | |
| agx::Bool | m_hadValidRb |
| agx::RigidBodyObserver | m_rb |
Protected Attributes inherited from agx::Attachment | |
| agx::FrameRef | m_relFrame |
| agx::Vec3 | m_transformed [NUM_ELEMENTS] |
Protected Attributes inherited from agx::Referenced | |
| Mutex | m_mutex |
| ObserverContainer | m_observers |
| AtomicValue | m_refCount |
Additional Inherited Members | |
Public Types inherited from agx::Attachment | |
| enum | Transformed { U , V , N , ANCHOR_POS , CM_TO_ANCHOR_POS , NUM_ELEMENTS } |
| Data access enum. More... | |
Static Protected Member Functions inherited from agx::Referenced | |
| static DeleteHandler * | getDeleteHandler () |
| static void | setDeleteHandler (DeleteHandler *handler) |
| Internal: Set a DeleteHandler to which deletion of all referenced counted objects will be delegated to. | |
Constraint attachment class for agx::RigidBody.
Definition at line 208 of file agx/Attachment.h.
| agx::RigidBodyAttachment::RigidBodyAttachment | ( | agx::RigidBody * | rb, |
| agx::Frame * | relFrame | ||
| ) |
Construct given rigid body and relative frame.
| rb | - rigid body (0 if e.g., world frame or other type of static frame) |
| relFrame | - constraint attachment frame relative rb model frame |
|
protected |
Protected default constructor used by restore.
|
protectedvirtual |
Reference counted object, protected destructor.
| agx::RigidBodyAttachment::AGXSTREAM_DECLARE_SERIALIZABLE_BASE | ( | agx::RigidBodyAttachment | ) |
|
overridevirtual |
Reimplemented from agx::Attachment.
|
overridevirtual |
Reimplemented from agx::Attachment.
|
overridevirtual |
Reimplemented from agx::Attachment.
|
overridevirtual |
Reimplemented from agx::Attachment.
|
inlinestatic |
Definition at line 276 of file agx/Attachment.h.
|
overridevirtual |
Reimplemented from agx::Attachment.
|
overridevirtual |
Reimplemented from agx::Attachment.
| RigidBody * agx::RigidBodyAttachment::getRigidBody | ( | ) | const |
|
overridevirtual |
Reimplemented from agx::Attachment.
| void agx::RigidBodyAttachment::setRigidBody | ( | agx::RigidBody * | rb | ) |
Assign rigid body to this constraint frame.
| rb | - new rigid body |
|
overridevirtual |
Transform given rigid body and frame.
Reimplemented from agx::Attachment.
|
overridevirtual |
Reimplemented from agx::Attachment.
|
protected |
Definition at line 291 of file agx/Attachment.h.
|
protected |
Definition at line 290 of file agx/Attachment.h.
Referenced by getRigidBody().