Trait mgf::LocalContacts[][src]

pub trait LocalContacts<RHS> {
    fn local_contacts<F: FnMut(LocalContact)>(
        &self,
        rhs: &RHS,
        callback: F
    ) -> bool; fn last_local_contact(&self, rhs: &RHS) -> Option<LocalContact> { ... } }

A type that can produce a point of contact with another and convert it to local coordinates.

Because the points in a Contact are global at the time of collision, they are not immediately useful to physics resolution. Upon being translated to local coordinates, which refer to the points as if the origin was the center of the object they belong to.

Required Methods

Calls the closure for each contact found. Returns true if any contact was found.

Provided Methods

Returns the last contact found, if one exists.

Implementors