Class JointData

Hierarchy

  • JointData

Constructors

Properties

anchor1: Vector
anchor2: Vector
axesMask: JointAxesMask
axis: Vector
damping: number
frame1: number
frame2: number
jointType: JointType
length: number
limits: number[]
limitsEnabled: boolean
stiffness: number

Methods

  • Returns RawGenericJoint

  • Creates a new joint descriptor that builds a Fixed joint.

    A fixed joint removes all the degrees of freedom between the affected bodies, ensuring their anchor and local frames coincide in world-space.

    Parameters

    • anchor1: Vector

      Point where the joint is attached on the first rigid-body affected by this joint. Expressed in the local-space of the rigid-body.

    • frame1: number

      The reference orientation of the joint wrt. the first rigid-body.

    • anchor2: Vector

      Point where the joint is attached on the second rigid-body affected by this joint. Expressed in the local-space of the rigid-body.

    • frame2: number

      The reference orientation of the joint wrt. the second rigid-body.

    Returns JointData

  • Creates a new joint descriptor that builds a Prismatic joint.

    A prismatic joint removes all the degrees of freedom between the affected bodies, except for the translation along one axis.

    Parameters

    • anchor1: Vector

      Point where the joint is attached on the first rigid-body affected by this joint. Expressed in the local-space of the rigid-body.

    • anchor2: Vector

      Point where the joint is attached on the second rigid-body affected by this joint. Expressed in the local-space of the rigid-body.

    • axis: Vector

      Axis of the joint, expressed in the local-space of the rigid-bodies it is attached to.

    Returns JointData

  • Create a new joint descriptor that builds revolute joints.

    A revolute joint allows three relative rotational degrees of freedom by preventing any relative translation between the anchors of the two attached rigid-bodies.

    Parameters

    • anchor1: Vector

      Point where the joint is attached on the first rigid-body affected by this joint. Expressed in the local-space of the rigid-body.

    • anchor2: Vector

      Point where the joint is attached on the second rigid-body affected by this joint. Expressed in the local-space of the rigid-body.

    Returns JointData

  • Parameters

    • rest_length: number
    • stiffness: number
    • damping: number
    • anchor1: Vector
    • anchor2: Vector

    Returns JointData

Generated using TypeDoc