48 AUTO_GENERATE_NONE = 0x0,
52 AUTO_GENERATE_ALL = MASS | CM_OFFSET | INERTIA
71 bool setMass(
Real m,
bool autoGenerate =
false );
76 inline Real getMass()
const;
81 inline const Real& getInvMass()
const;
92 bool setInertiaTensor(
const SPDMatrix3x3& m,
bool autoGenerate =
false);
103 bool setInertiaTensor(
const Vec3& inertiaDiagonal,
bool autoGenerate =
false);
108 Vec3 getInvMassVector()
const;
128 void setAutoGenerateMask(uint32_t mask);
138 Vec3 getPrincipalInertiae()
const;
149 bool setMassCoefficients(
const Vec3& coefficients );
154 const Vec3& getMassCoefficients( )
const;
159 const Vec3& getEffectiveMass()
const;
170 bool setInertiaTensorCoefficients(
const Vec3& coefficients );
175 const Vec3& getInertiaTensorCoefficients()
const;
186 Vec3 getEffectiveInvMassVector()
const;
203 void setEffectiveMassTransformDiagonal(
const Vec3& effectiveMassTransformDiagonal );
208 const Vec3& getEffectiveMassTransformDiagonal()
const;
230 void setDefaultValues();
238 MassProperties(const MassProperties& copy);
244 agx::Physics::RigidBodyPtr m_entity;
254 Real xx, xy, xz, yz, yy, zz, xtx;
280 return m_entity.mass();
287 return m_entity.effectiveMass();
293 return m_entity.effectiveMassCoefficients();
299 return m_entity.effectiveInertiaCoefficients();
304 return m_autoGenerateMask;
310 return m_entity.inertia();
316 return m_entity.effectiveInertia();
322 return m_entity.effectiveMassTransformDiagonal();
329 return m_entity.inertia().getDiagonal();
335 return m_entity.invMass();
341 return Vec3(m_entity.invMass(), m_entity.invMass(), m_entity.invMass());
347 return SPDMatrix3x3(
Vec3(m_entity.invMass(), m_entity.invMass(), m_entity.invMass()) );
AutoGenerateFlags
Specifies a bit mask for controlling what should be automatically calculated when a body/geometry is ...
SPDMatrix3x3 getInvMassMatrix() const
Vec3 getPrincipalInertiae() const
Vec3T< Real > Vec3
The object holding 3 dimensional vectors and providing basic arithmetic.
const Vec3 & getEffectiveMassTransformDiagonal() const
const Vec3 & getEffectiveMass() const
const Real & getInvMass() const
#define AGXPHYSICS_EXPORT
const SPDMatrix3x3 & getEffectiveInertiaTensor() const
agx::UInt32 getAutoGenerateMask() const
const Vec3 & getMassCoefficients() const
Pointer to a entity instance of type Physics.RigidBody.
The agx namespace contains the dynamics/math part of the AGX Dynamics API.
Specialized type of matrices for holding symmetric positive definite matrices.
Class for rigid body inertia tensor and mass.
The rigid body class, combining a geometric model and a frame of reference.
const Vec3 & getInertiaTensorCoefficients() const
#define AGXSTREAM_DECLARE_SERIALIZABLE(T)
Use this in a Serializable class to add the required methods Important: Use full namespace in the dec...
This class is an abstract base class for all classes that can be stored and retrieved from an Archive...
Vec3 getInvMassVector() const
#define DOXYGEN_END_INTERNAL_BLOCK()
const SPDMatrix3x3 & getInertiaTensor() const
#define DOXYGEN_START_INTERNAL_BLOCK()