[][src]Enum newton::joint::Joint

pub enum Joint<'a> {
    Ball(Ball<'a>),
    Slider(Slider<'a>),
    UpVector(UpVector<'a>),
    Hinge(Hinge<'a>),
    Corkscrew(Corkscrew<'a>),
    Universal(Universal<'a>),
    UserJoint(UserJoint<'a>),
}

Enum grouping all joint types.

Variants

Ball(Ball<'a>)Slider(Slider<'a>)UpVector(UpVector<'a>)Hinge(Hinge<'a>)Corkscrew(Corkscrew<'a>)Universal(Universal<'a>)UserJoint(UserJoint<'a>)

Methods

impl<'a> Joint<'a>[src]

pub unsafe fn from_raw(raw: *const NewtonJoint, owned: bool) -> Self[src]

pub fn ball(self) -> Option<Ball<'a>>[src]

pub fn is_ball(&self) -> bool[src]

pub fn slider(self) -> Option<Slider<'a>>[src]

pub fn is_slider(&self) -> bool[src]

pub fn up_vector(self) -> Option<UpVector<'a>>[src]

pub fn is_up_vector(&self) -> bool[src]

pub fn hinge(self) -> Option<Hinge<'a>>[src]

pub fn is_hinge(&self) -> bool[src]

pub fn corkscrew(self) -> Option<Corkscrew<'a>>[src]

pub fn is_corkscrew(&self) -> bool[src]

pub fn universal(self) -> Option<Universal<'a>>[src]

pub fn is_universal(&self) -> bool[src]

pub fn user_joint(self) -> Option<UserJoint<'a>>[src]

pub fn is_user_joint(&self) -> bool[src]

Trait Implementations

impl<'a> NewtonJoint for Joint<'a>[src]

fn into_raw(self) -> *const NewtonJoint where
    Self: Sized
[src]

fn name(&self) -> Option<&'static str>[src]

fn bodies<'a: 'b, 'b>(&'a self) -> (Body<'b>, Option<Body<'b>>)[src]

Returns the pair of bodies that are linked by this joint

fn collision_state(&self) -> CollisionState[src]

fn set_collision_state(&self, state: CollisionState)[src]

fn is_active(&self) -> bool[src]

fn stiffness(&self) -> f32[src]

fn set_stiffness(&self, stiff: f32)[src]

fn set_destroy_callback<F>(&self, callback: F) where
    F: FnMut() + Send + 'static, 
[src]

impl<'a> Debug for Joint<'a>[src]

Auto Trait Implementations

impl<'a> !Send for Joint<'a>

impl<'a> !Sync for Joint<'a>

Blanket Implementations

impl<T> From for T[src]

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom for T where
    T: From<U>, 
[src]

type Error = !

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

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

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

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> Any for T where
    T: 'static + ?Sized
[src]