#define AGXSTREAM_DECLARE_SERIALIZABLE(T)
Use this in a Serializable class to add the required methods Important: Use full namespace in the dec...
The rotational has one rotational degree of freedom.
A rotational unit has one degree of freedom.
virtual agx::Vec3 getDirection() const
returns a vector in world coordinates that defines the rotational axis of the rotational unit.
virtual bool postUpdate(agx::Real timeStep) override
virtual agx::Real getDeliveredTorque() const
returns the amount of torque delivered from the rotational dimension
virtual bool store(agxStream::StorageStream &str) const override
Stores internal data into stream.
agxPowerLine::RotationalDimension * getRotationalDimension() const
returns a pointer to the rotational dimension
virtual ~RotationalUnit()
static agx::Real convertRPMtoAngularVelocity(const agx::Real rpm)
RotationalUnit()
Create a rotational unit.
static agx::Real convertAngularVelocityToRPM(const agx::Real angVel)
Convert between m/s and rpm.
RotationalUnit(agx::RigidBody *body, agx::UInt8 slot)
agx::Real getRPM() const
returns the number of revolutions per minute
virtual bool preUpdate(agx::Real timeStep) override
virtual bool restore(agxStream::StorageStream &str) override
Restores internal data from stream.
virtual void setInertia(agx::Real inertia)
set the inertia for the rotational dimension of the rotational unit.
void setAngularVelocityDamping(agx::Real damping)
set the angular velocity damping around the local axis (direction)
RotationalDimensionRef m_rotationalDimension
agx::Real getAngularVelocity() const
returns the number of radians per second
agx::Real getAngle() const
virtual agx::Real getInertia() const
Abstract base class for storing/restoring a line/drums with version control.
The rigid body class, combining a geometric model and a frame of reference.
agxPowerLine contains a collection of connected components that transport power across a system.
agx::ref_ptr< RotationalUnit > RotationalUnitRef