Documentation
    Preparing search index...

    Interface RevoluteJointDescriptor

    A hinge: one rotational degree of freedom about RevoluteJointDescriptor.axis (§28 "revolute/hinge"). Both dimensions.

    interface RevoluteJointDescriptor {
        anchorA?: Vector3Input;
        anchorB?: Vector3Input;
        axis?: Vector3Input;
        bodyA: PhysicsBodyHandle;
        bodyB: PhysicsBodyHandle;
        breakForce?: number;
        breakTorque?: number;
        collisionEnabled?: boolean;
        limits?: JointLimits;
        motor?: AngularJointMotor;
        type: "revolute";
    }

    Hierarchy (View Summary)

    Index
    anchorA?: Vector3Input

    Attachment point in bodyA's local frame. Defaults to its origin.

    anchorB?: Vector3Input

    Attachment point in bodyB's local frame. Defaults to its origin.

    Hinge axis in bodyA's local frame, resolved from the world-space axis the Joint class was given (see JointDescriptorBase).

    Required in a "3d" world — a hinge with no axis is not a hinge. In a "2d" world the axis must be along ±Z, the plane's only rotational freedom (§21), and defaults to +Z when omitted.

    First constrained body. Must differ from JointDescriptorBase.bodyB.

    Second constrained body.

    breakForce?: number

    Reaction force, in newtons, above which the joint breaks (§28 "break force"). Omitted means the joint never breaks under load.

    Enforced by PhysicsWorld, not by the solver (plan P6-2): the world reads the joint's reaction impulse after every fixed step, divides by the step delta, and destroys the joint when the magnitude exceeds this value — strictly, so a joint sitting exactly at its threshold survives. Requires an adapter that reports reactions (SolverJointAccess.reportsJointReactions); addJoint refuses a breakable joint on an adapter that does not, rather than accepting a threshold it can never enforce.

    breakTorque?: number

    Reaction torque, in newton-metres, above which the joint breaks (§28 "break torque"). See JointDescriptorBase.breakForce; either threshold alone is enough to break the joint.

    collisionEnabled?: boolean

    Whether the two jointed bodies still collide with each other (§28 "collision enable/disable"). Defaults to false, the usual choice for bodies that overlap by construction.

    limits?: JointLimits

    Angular travel in radians, or free rotation when omitted (§28 "limits").

    Velocity motor about the axis, or none when omitted (§28 "motors").

    type: "revolute"