AGX Dynamics 2.42.3.1
Loading...
Searching...
No Matches
agx::ConstraintAngleBasedData Class Reference

Basic data holder class for "angle based" (secondary) constraints. More...

#include <ElementaryConstraintData.h>

+ Inheritance diagram for agx::ConstraintAngleBasedData:

Public Member Functions

 ConstraintAngleBasedData ()
 Default constructor used during restore of this object.
 
 ConstraintAngleBasedData (const agx::AttachmentPair *ap, agx::Angle *angle)
 Construct given constraint attachment pair and the input angle for the elementary constraint to work on.
 
virtual ~ConstraintAngleBasedData ()
 Destructor.
 
const agx::Angle * getAngle () const
 
const agx::Vec3 & getDir1 () const
 
const agx::Vec3 & getDir2 () const
 
virtual void restore (agxStream::InputArchive &in) override
 Restore data from stream.
 
virtual void store (agxStream::OutputArchive &out) const override
 Store data to stream.
 
- Public Member Functions inherited from agx::ElementaryConstraintData
 ElementaryConstraintData ()
 Used during serialization restore.
 
 ElementaryConstraintData (const agx::AttachmentPair *ap)
 Construct given attachment pair.
 
virtual ~ElementaryConstraintData ()
 Destructor.
 
const agx::Attachment * getAttachment (agx::UInt index) const
 
const agx::AttachmentPair * getAttachmentPair () const
 
const agx::Vec3 & getCmToAnchorPosition (agx::UInt index) const
 
const agx::Vec3 & getSeparation () const
 
const agx::Vec3 & getWorldToAnchorPosition (agx::UInt index) const
 
virtual void restore (agxStream::InputArchive &in)
 Restore from stream.
 
virtual void set (const agx::AttachmentPair *ap)
 Assign new attachment pair.
 
virtual void store (agxStream::OutputArchive &out) const
 Store to stream.
 

Protected Attributes

AngleRef m_angle
 
- Protected Attributes inherited from agx::ElementaryConstraintData
const agx::AttachmentPair * m_ap
 

Detailed Description

Basic data holder class for "angle based" (secondary) constraints.

Definition at line 428 of file ElementaryConstraintData.h.

Constructor & Destructor Documentation

◆ ConstraintAngleBasedData() [1/2]

agx::ConstraintAngleBasedData::ConstraintAngleBasedData ( )

Default constructor used during restore of this object.

◆ ConstraintAngleBasedData() [2/2]

agx::ConstraintAngleBasedData::ConstraintAngleBasedData ( const agx::AttachmentPair *  ap,
agx::Angle *  angle 
)

Construct given constraint attachment pair and the input angle for the elementary constraint to work on.

Parameters
ap- constraint attachment pair
angle- input angle

◆ ~ConstraintAngleBasedData()

virtual agx::ConstraintAngleBasedData::~ConstraintAngleBasedData ( )
virtual

Destructor.

References agx::getAngle().

Member Function Documentation

◆ getAngle()

const Angle * agx::ConstraintAngleBasedData::getAngle ( ) const
Returns
the angle used by the elementary constraint

Definition at line 569 of file ElementaryConstraintData.h.

References m_angle.

◆ getDir1()

const Vec3 & agx::ConstraintAngleBasedData::getDir1 ( ) const
Returns
the world direction the angle is defined along or about for first attachment

Definition at line 574 of file ElementaryConstraintData.h.

References agxAssert, agx::Angle::getDir(), m_angle, and agx::ElementaryConstraintData::m_ap.

◆ getDir2()

const Vec3 & agx::ConstraintAngleBasedData::getDir2 ( ) const
Returns
the world direction the angle is defined along or about for second attachment

Definition at line 580 of file ElementaryConstraintData.h.

References agxAssert, agx::Angle::getDir(), m_angle, and agx::ElementaryConstraintData::m_ap.

◆ restore()

virtual void agx::ConstraintAngleBasedData::restore ( agxStream::InputArchive &  in)
overridevirtual

Restore data from stream.

Reimplemented from agx::ElementaryConstraintData.

Reimplemented in agx::ConeLimitData.

◆ store()

virtual void agx::ConstraintAngleBasedData::store ( agxStream::OutputArchive &  out) const
overridevirtual

Store data to stream.

Reimplemented from agx::ElementaryConstraintData.

Reimplemented in agx::ConeLimitData.

Member Data Documentation

◆ m_angle

AngleRef agx::ConstraintAngleBasedData::m_angle
protected

Definition at line 475 of file ElementaryConstraintData.h.

Referenced by getAngle(), getDir1(), and getDir2().


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