17 #ifndef AGX_ELEMENTARYCONSTRAINTDATA_H
18 #define AGX_ELEMENTARYCONSTRAINTDATA_H
23 # pragma warning(push)
24 # pragma warning(disable: 6011) // Disable warningC6011: dereferencing nullptr pointer
512 return getAttachment( 0 )->get( m_dir1U );
520 return getAttachment( 0 )->get( m_dir1V );
528 return getAttachment( 0 )->get( m_dir1N );
536 return getAttachment( 1 )->get( m_dir2N );
629 return getAttachment( 0 )->get( m_dir1 );
637 return getAttachment( 1 )->get( m_dir2 );
649 # pragma warning(pop)
void setSlack(agx::Vec3 slack)
InputRef< T > in(const char *name, T &obj)
Create an object with a name and a reference to the object that should be restored (usually a pointer...
const agx::Vec3 & getDir1() const
virtual const agx::Vec3 & getDir(const agx::AttachmentPair &ap, agx::UInt index) const
Class to hold data for elementary constraints.
Data holder class for elementary constraint QuatLock.
const agx::Vec3 & getDir2() const
const agx::Vec3 & getDir1() const
OutputRef< Serializable > out(const char *name, const Serializable *obj)
Return an object that contain the name and the object that should be serialized to an archive...
agx::Attachment::Transformed m_dir1
agx::Attachment::Transformed m_dir
const agx::Vec3 & getDir() const
const agx::Vec3 & getDir2() const
agx::Attachment::Transformed m_dir1V
const agx::Vec3 & getDir2N() const
agx::Attachment::Transformed m_dir1U
void AGXCORE_EXPORT transform(void *target, const Format *targetFormat, const void *source, const Format *sourceFormat, size_t numElements)
Transform data between two buffers.
#define AGXPHYSICS_EXPORT
agx::Attachment::Transformed m_dir2
virtual agx::Int getReferenceBody() const
Basic data holder class for "angle based" (secondary) constraints.
const agx::Vec3 & getDir2() const
const agx::Vec3 & getWorldToAnchorPosition(agx::UInt index) const
Constraint attachment world position.
agx::Real getSlack() const
Custom data for separation pair.
agx::Real getSwingAngle() const
agx::Attachment::Transformed m_dir2N
Constraint attachment pair class.
agx::Attachment::Transformed m_dir1
const agx::Vec3 & getDir1U() const
Constraint attachment base class for any type of frame.
const agx::Vec3 getSlack() const
Data holder class for elementary swing constraint.
Data holder class for elementary constraint Twist.
Generic class for holding constraint data including 3 slack parameters.
Data holder class for elementary constraint Dot2.
agx::ref_ptr< QuatTransformer > QuatTransformerRef
agx::Real getSlack() const
agx::ref_ptr< const agx::Angle > AngleRefType
const agx::AttachmentPair * m_ap
const agx::Attachment * getAttachment(agx::UInt index) const
const agx::Angle * getAngle() const
Class for writing serialized data in binary format to a stream.
Data holder class for elementary constraint Dot2Slack.
QuatTransformerRef m_qTransformer
T1 clamp(T1 v, T2 minimum, T3 maximum)
Vec3T getPerpendicularUnitVector() const
Extended Dot1Data with additional slack parameter.
Separation vector, i.e., the vector from frame 2 to frame 1.
Data holder class for elementary constraint Dot1.
agx::Attachment::Transformed m_dir2
Transformed
Data access enum.
const agx::Vec3 & getDir1() const
const agx::Vec3 & getDir1V() const
Real getAngle(const Vec3 &a, const Vec3 &b, const Vec3 &c)
a and b should be orthogonal
const agx::Vec3 & getDir1N() const
void setSlack(agx::Real slack)
agx::Attachment::Transformed m_dir1N
const agx::Vec3 & getSeparation() const
agx::Vec3 getSwingAxis() const
Vector from center of mass (if moving) to anchor point given in world frame.
const agx::AttachmentPair * getAttachmentPair() const
void setSlack(agx::Real slack)
Set amount of slack in constraint.
const agx::Vec3 & getCmToAnchorPosition(agx::UInt index) const