Skip to main content

JointBall

The JointBall class represents a ball-and-socket connection between bodies in the Scene. It provides rotational degrees of freedom with swing and twist components. The twist axis is aligned with the Z axis.

#include <scene/TellusimJointBall.h>

Inheritance

Constructors

explicit JointBall(const char *name = nullptr)
explicit JointBall(Body &body, const char *name = nullptr)
JointBall(Body &body_0, Body &body_1, const char *name = nullptr)

Methods

Current swing rotation.

void setSwingRotation(Vector2f rotation)
const Vector2f getSwingRotation() const

Current twist rotation.

void setTwistRotation(float32_t rotation)
float32_t getTwistRotation() const

Angular friction.

void setFriction(float32_t friction)
float32_t getFriction() const

Angular restitution.

void setRestitution(float32_t restitution)
float32_t getRestitution() const

Angular stiffness.

void setStiffness(float32_t stiffness)
float32_t getStiffness() const

Angular damping.

void setDamping(float32_t damping)
float32_t getDamping() const

Swing rotation range.

void setMinSwingRotation(float32_t min_rotation)
void setMaxSwingRotation(float32_t max_rotation)
void setSwingRotationRange(float32_t min_rotation, float32_t max_rotation)
float32_t getMinSwingRotation() const
float32_t getMaxSwingRotation() const
bool hasSwingRotationRange() const

Twist rotation range.

void setMinTwistRotation(float32_t min_rotation)
void setMaxTwistRotation(float32_t max_rotation)
void setTwistRotationRange(float32_t min_rotation, float32_t max_rotation)
float32_t getMinTwistRotation() const
float32_t getMaxTwistRotation() const
bool hasTwistRotationRange() const

Updated flags.

bool isFrictionUpdated() const
bool isLimitsUpdated() const