# Class JointData

- Defined in dynamics/impulse_joint.d.ts:159

#####
Index

### Constructors

constructor

### Properties

anchor1
anchor2
axesMask
axis
damping
frame1
frame2
jointType
length
limits
limitsEnabled
stiffness

### Methods

intoRaw
fixed
prismatic
revolute
rope
spring

## Constructors

### `Private` constructor

- new JointData(): JointData

- #### Returns JointData

  - Defined in dynamics/impulse_joint.d.ts:172

## Properties

### anchor1

anchor1: Vector

- Defined in dynamics/impulse_joint.d.ts:160

### anchor2

anchor2: Vector

- Defined in dynamics/impulse_joint.d.ts:161

### axesMask

axesMask: JointAxesMask

- Defined in dynamics/impulse_joint.d.ts:168

### axis

axis: Vector

- Defined in dynamics/impulse_joint.d.ts:162

### damping

damping: number

- Defined in dynamics/impulse_joint.d.ts:170

### frame1

frame1: number

- Defined in dynamics/impulse_joint.d.ts:163

### frame2

frame2: number

- Defined in dynamics/impulse_joint.d.ts:164

### jointType

jointType: JointType

- Defined in dynamics/impulse_joint.d.ts:165

### length

length: number

- Defined in dynamics/impulse_joint.d.ts:171

### limits

limits: number[]

- Defined in dynamics/impulse_joint.d.ts:167

### limitsEnabled

limitsEnabled: boolean

- Defined in dynamics/impulse_joint.d.ts:166

### stiffness

stiffness: number

- Defined in dynamics/impulse_joint.d.ts:169

## Methods

### intoRaw

- intoRaw(): RawGenericJoint

- #### Returns RawGenericJoint

  - Defined in dynamics/impulse_joint.d.ts:215

### `Static` fixed

- fixed(anchor1, frame1, anchor2, frame2): JointData

- 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

  - Defined in dynamics/impulse_joint.d.ts:186

### `Static` prismatic

- prismatic(anchor1, anchor2, axis): 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

  - Defined in dynamics/impulse_joint.d.ts:214

### `Static` revolute

- revolute(anchor1, anchor2): 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

  - Defined in dynamics/impulse_joint.d.ts:201

### `Static` rope

- rope(length, anchor1, anchor2): JointData

- #### Parameters

  - length: number
  - anchor1: Vector
  - anchor2: Vector

  #### Returns JointData

  - Defined in dynamics/impulse_joint.d.ts:188

### `Static` spring

- spring(rest_length, stiffness, damping, anchor1, anchor2): JointData

- #### Parameters

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

  #### Returns JointData

  - Defined in dynamics/impulse_joint.d.ts:187