# [−][src]Struct nphysics3d::joint::HelicalJoint

`pub struct HelicalJoint<N: RealField> { /* fields omitted */ }`

A joint that allows one degree of freedom between two multibody links.

The degree of freedom is the combination of a rotation and a translation along the same axis. Both rotational and translational motions are coupled to generate a screw motion.

## Methods

### `impl<N: RealField> HelicalJoint<N>`[src]

#### `pub fn new(axis: Unit<Vector3<N>>, pitch: N, angle: N) -> Self`[src]

Create an helical joint with the given axis and initial angle.

The `pitch` controls how much translation is generated for how much rotation. In particular, the translational displacement along `axis` is given by `angle * pitch`.

#### `pub fn offset(&self) -> N`[src]

The translational displacement along the joint axis.

#### `pub fn angle(&self) -> N`[src]

The rotational displacement along the joint axis.

### `impl<N: RealField> HelicalJoint<N>`[src]

#### `pub fn min_angle(&self) -> Option<N>`[src]

The lower limit of the rotation angle.

#### `pub fn max_angle(&self) -> Option<N>`[src]

The upper limit of the rotation angle.

#### `pub fn disable_min_angle(&mut self)`[src]

Disable the lower limit of the rotation angle.

#### `pub fn disable_max_angle(&mut self)`[src]

Disable the upper limit of the rotation angle.

#### `pub fn enable_min_angle(&mut self, limit: N)`[src]

Enable and set the lower limit of the rotation angle.

#### `pub fn enable_max_angle(&mut self, limit: N)`[src]

Enable and set the upper limit of the rotation angle.

#### `pub fn is_angular_motor_enabled(&self) -> bool`[src]

Return `true` if the angular motor of this joint is enabled.

#### `pub fn enable_angular_motor(&mut self)`[src]

Enable the angular motor of this joint.

#### `pub fn disable_angular_motor(&mut self)`[src]

Disable the angular motor of this joint.

#### `pub fn desired_angular_motor_velocity(&self) -> N`[src]

The desired angular velocity of the joint motor.

#### `pub fn set_desired_angular_motor_velocity(&mut self, vel: N)`[src]

Set the desired angular velocity of the joint motor.

#### `pub fn max_angular_motor_torque(&self) -> N`[src]

The maximum torque that can be delivered by the joint motor.

#### `pub fn set_max_angular_motor_torque(&mut self, torque: N)`[src]

Set the maximum torque that can be delivered by the joint motor.

## Blanket Implementations

### `impl<T> Same<T> for T`

#### `type Output = T`

Should always be `Self`

### `impl<T> ToOwned for T where    T: Clone, `[src]

#### `type Owned = T`

The resulting type after obtaining ownership.

### `impl<T, U> TryFrom<U> for T where    U: Into<T>, `[src]

#### `type Error = Infallible`

The type returned in the event of a conversion error.

### `impl<T, U> TryInto<U> for T where    U: TryFrom<T>, `[src]

#### `type Error = <U as TryFrom<T>>::Error`

The type returned in the event of a conversion error.