![]() |
Trax3 3.1.0
trax track library
|
A Gestalt is a Body with a Shape. More...
#include <C:/Trend/Development/Trax3/Code/trax/rigid/Gestalt.h>

Public Member Functions | |
| virtual void | SetName (const char *name) noexcept=0 |
| Sets the name of the Gestalt. | |
| virtual const char * | GetName () const noexcept=0 |
| virtual void | SetFrame (const spat::Frame< Length, One > &frame) noexcept=0 |
| Sets position and orientation (pose) in global coordinates. | |
| virtual void | GetFrame (spat::Frame< Length, One > &frame) const noexcept=0 |
| Gets the pose in global coordinates. | |
| virtual int | Attach (std::unique_ptr< Geom > pGeom, Mass mass)=0 |
| Attach a Geom with a dedicated mass to the Gestalt. | |
| virtual Mass | GeomMass (int idx=0) const =0 |
| virtual int | Attach (std::unique_ptr< Geom > pGeom)=0 |
| Attach a Geom to the Shape. | |
| virtual int | Attach (std::vector< std::unique_ptr< Geom > > &geoms)=0 |
| Public Member Functions inherited from trax::Body | |
| virtual void | WakeUp ()=0 |
| Wakes the Body if it was deactivated due to not being in move. | |
| virtual bool | IsSleeping () const noexcept=0 |
| Is the body deactivated? | |
| virtual void | SetSleepDelay (Time threshold)=0 |
| virtual Time | GetSleepDelay () const noexcept=0 |
| virtual void | SetSleepThreshold (decltype(Velocity{} *Velocity{}) threshold)=0 |
| virtual decltype(Velocity{} *Velocity{}) | GetSleepThreshold () const noexcept=0 |
| virtual void | SetMass (Mass mass)=0 |
| Sets the mass of the Body. | |
| virtual Mass | GetMass () const noexcept=0 |
| virtual void | CenterOfMass (const spat::Position< Length > &pos) noexcept=0 |
| Sets the center of mass in Body space. | |
| virtual spat::Position< Length > | CenterOfMass () const noexcept=0 |
| virtual void | InertiaTensor (const spat::SquareMatrix< Area, 3 > &specificInertiaTensor)=0 |
| Sets the specific inertia tensor of the Body. | |
| virtual spat::SquareMatrix< Area, 3 > | InertiaTensor () const =0 |
| virtual void | SetLinearVelocity (const spat::Vector< Velocity > &v)=0 |
| Sets the velocity of the barycenter of this Body. | |
| virtual void | GetLinearVelocity (spat::Vector< Velocity > &v) const =0 |
| Gets the velocity of the barycenter of this Body. | |
| virtual void | SetAngularVelocity (const spat::Vector< AngularVelocity > &w)=0 |
| Sets the rotational velocity around the barycenter of this Body. | |
| virtual void | GetAngularVelocity (spat::Vector< AngularVelocity > &w) const =0 |
| Sets the rotational velocity around the barycenter of this Body. | |
| Public Member Functions inherited from trax::Shape | |
| virtual spat::Box< Length > | GetExtent () const noexcept=0 |
| Gets the minimum axis aligned box that includes the the Geoms completely. | |
| virtual std::unique_ptr< Geom > | Remove (int idx)=0 |
| Removes the Geom with index idx from the Shape. | |
| virtual void | Clear () noexcept=0 |
| Remove all Geoms from the Shape. | |
| virtual int | Count () const =0 |
| virtual Geom & | Get (int idx=0) const =0 |
A Gestalt is a Body with a Shape.
A Gestalt combines the physical properties of a Body with the geometric properties of a Shape. The latter combines multiple Geoms into a single collision shape.
|
virtual |
This will be used for collision testing. The Geom carries a frame of reference to specify it's pose relative to the Shape's pose.
Implements trax::Shape.
Attach a Geom with a dedicated mass to the Gestalt.
This will be used for collision testing. The Geom carries a frame of reference to specify it's pose relative to the Body's pose.
| pGeom | A Geom to be attached to the Body. |
| mass | A mass to be used when calculating the mass properties for the Body by CalculateMassPropertiesFromShapes(). |
|
virtual |
| geoms | A list of Geoms to be attached to the Shape. |
Implements trax::Shape.
|
pure virtual |
|
pure virtualnoexcept |
Gets the pose in global coordinates.
Implements trax::Body.
|
pure virtualnoexcept |
Implements trax::Body.
|
pure virtualnoexcept |
Sets position and orientation (pose) in global coordinates.
This will set the position and orientation of the Gestalt in global simulation space.
| frame | Frame of reference. Must be orthonormal. |
Implements trax::Body.
|
pure virtualnoexcept |
Sets the name of the Gestalt.
This is for debug purposes; the string is not copied, only the pointer is stored.
Implements trax::Body.