JointSlider
The JointSlider class represents a slider connection between bodies in the Scene. It provides a single translational degree of freedom along the Z axis. The Joint can operate as a servo motor with a specified linear velocity.
#include <scene/TellusimJointSlider.h>
Inheritance
- Inherits from Joint
Constructors
explicit JointSlider(const char *name = nullptr)
explicit JointSlider(Body &body, const char *name = nullptr)
JointSlider(Body &body_0, Body &body_1, const char *name = nullptr)
Methods
Linear servo flag.
void setServo(bool servo)
bool isServo() const
Current linear position.
void setPosition(float32_t position)
float32_t getPosition() const
Current linear velocity.
void setVelocity(float32_t velocity)
float32_t getVelocity() const
Linear friction.
void setFriction(float32_t friction)
float32_t getFriction() const
Linear restitution.
void setRestitution(float32_t restitution)
float32_t getRestitution() const
Linear stiffness.
void setStiffness(float32_t stiffness)
float32_t getStiffness() const
Linear damping.
void setDamping(float32_t damping)
float32_t getDamping() const
Linear position range.
void setMinPosition(float32_t min_position)
void setMaxPosition(float32_t max_position)
void setPositionRange(float32_t min_position, float32_t max_position)
float32_t getMinPosition() const
float32_t getMaxPosition() const
bool hasPositionRange() const
Servo motor position.
void setMotorPosition(float32_t position)
float32_t getMotorPosition() const
Motor velocity.
void setMotorVelocity(float32_t velocity)
float32_t getMotorVelocity() const
Motor force.
void setMotorForce(float32_t force)
float32_t getMotorForce() const
Motor stiffness.
void setMotorStiffness(float32_t stiffness)
float32_t getMotorStiffness() const
Motor damping.
void setMotorDamping(float32_t damping)
float32_t getMotorDamping() const
Updated flags.
bool isFrictionUpdated() const
bool isLimitsUpdated() const
bool isMotorUpdated() const