Struct nphysics2d::detection::joint::BallInSocket
[−]
[src]
pub struct BallInSocket<N: Real> { /* fields omitted */ }
A ball-in-socket joint.
This is usually used to create ragdolls.
Methods
impl<N: Real> BallInSocket<N>
[src]
fn new(
anchor1: Anchor<N, Point<N>>,
anchor2: Anchor<N, Point<N>>
) -> BallInSocket<N>
[src]
anchor1: Anchor<N, Point<N>>,
anchor2: Anchor<N, Point<N>>
) -> BallInSocket<N>
Creates a ball-in-socket joint.
fn up_to_date(&self) -> bool
[src]
Tells if this joint has been modified by the user.
fn set_local1(&mut self, local1: Point<N>)
[src]
Sets the the second anchor position.
The position is expressed in the second attached body’s local coordinates.
fn set_local2(&mut self, local2: Point<N>)
[src]
Sets the the second anchor position.
The position is expressed in the second attached body’s local coordinates.
Trait Implementations
impl<N: Real> Joint<N, Point<N>> for BallInSocket<N>
[src]
fn anchor1(&self) -> &Anchor<N, Point<N>>
[src]
The first anchor affected by this joint.
fn anchor2(&self) -> &Anchor<N, Point<N>>
[src]
The second anchor affected by this joint.
fn anchor1_pos(&self) -> Point<N>
[src]
The first attach point in global coordinates.
fn anchor2_pos(&self) -> Point<N>
[src]
The second attach point in global coordinates.