Struct ncollide2d::query::Contact[][src]

pub struct Contact<N: Real> {
    pub world1: Point<N>,
    pub world2: Point<N>,
    pub normal: Unit<Vector<N>>,
    pub depth: N,
}

Geometric description of a contact.

Fields

Position of the contact on the first object. The position is expressed in world space.

Position of the contact on the second object. The position is expressed in world space.

Contact normal

Penetration depth

Methods

impl<N: Real> Contact<N>
[src]

Creates a new contact.

Creates a new contact, computing automatically the penetration depth.

impl<N: Real> Contact<N>
[src]

Reverts the contact normal and swaps world1 and world2.

Trait Implementations

impl<N: Debug + Real> Debug for Contact<N>
[src]

Formats the value using the given formatter. Read more

impl<N: PartialEq + Real> PartialEq for Contact<N>
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

impl<N: Clone + Real> Clone for Contact<N>
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Auto Trait Implementations

impl<N> Send for Contact<N>

impl<N> Sync for Contact<N>