[−][src]Struct ncollide3d::query::ContactManifold
A contact manifold.
A contact manifold is a set of contacts between two shapes. If the shapes are convex, then the convex hull of those contacts are often interpreted as surface. This structure is responsible for matching new contacts with old ones in order to perform an approximate tracking of the contact points.
Methods
impl<N: RealField> ContactManifold<N>
[src]
pub fn new() -> Self
[src]
Initializes a contact manifold without any contact.
The default contact tracking mode is set to ContactTrackingMode::DistanceBased(0.02)
.
pub fn len(&self) -> usize
[src]
The number of contacts contained by this manifold.
pub fn contacts(&self) -> impl Iterator<Item = &TrackedContact<N>>
[src]
All the contact tracked by this manifold.
pub fn contacts_mut(&mut self) -> impl Iterator<Item = &mut TrackedContact<N>>
[src]
Mutable reference to all the contact tracked by this manifold.
pub fn deepest_contact(&self) -> Option<&TrackedContact<N>>
[src]
The contact of this manifold with the deepest penetration depth.
pub fn clear(&mut self)
[src]
Empty the manifold as well as its cache.
pub fn tracking_mode(&self) -> ContactTrackingMode<N>
[src]
Gets the technique currently used for tracking contacts.
pub fn set_tracking_mode(&mut self, mode: ContactTrackingMode<N>)
[src]
Sets the technique used for tracking contacts.
If the selected method is different from the current one, the current contact cache is cleared.
pub fn save_cache_and_clear(&mut self)
[src]
Save the contacts to a cache and empty the manifold.
pub fn push(
&mut self,
contact: Contact<N>,
kinematic: ContactKinematic<N>,
tracking_pt: Point<N>,
preprocessor1: Option<&dyn ContactPreprocessor<N>>,
preprocessor2: Option<&dyn ContactPreprocessor<N>>
) -> bool
[src]
&mut self,
contact: Contact<N>,
kinematic: ContactKinematic<N>,
tracking_pt: Point<N>,
preprocessor1: Option<&dyn ContactPreprocessor<N>>,
preprocessor2: Option<&dyn ContactPreprocessor<N>>
) -> bool
Add a new contact to the manifold.
The manifold will attempt to match this contact with another one
previously added and added to the cache by the last call to
save_cache_and_clear
. The matching is done by spacial proximity, i.e.,
two contacts that are sufficiently close will be given the same identifier.
Trait Implementations
impl<N: Clone + RealField> Clone for ContactManifold<N>
[src]
fn clone(&self) -> ContactManifold<N>
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl<N: Debug + RealField> Debug for ContactManifold<N>
[src]
Auto Trait Implementations
impl<N> RefUnwindSafe for ContactManifold<N> where
N: RefUnwindSafe + Scalar,
N: RefUnwindSafe + Scalar,
impl<N> Send for ContactManifold<N> where
N: Scalar,
N: Scalar,
impl<N> Sync for ContactManifold<N> where
N: Scalar,
N: Scalar,
impl<N> Unpin for ContactManifold<N> where
N: Scalar + Unpin,
N: Scalar + Unpin,
impl<N> UnwindSafe for ContactManifold<N> where
N: Scalar + UnwindSafe,
N: Scalar + UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Downcast for T where
T: Any,
T: Any,
fn into_any(self: Box<T>) -> Box<dyn Any + 'static>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
fn as_any(&self) -> &(dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
impl<T> DowncastSync for T where
T: Send + Sync + Any,
T: Send + Sync + Any,
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<SS, SP> SupersetOf<SS> for SP where
SS: SubsetOf<SP>,
SS: SubsetOf<SP>,
fn to_subset(&self) -> Option<SS>
fn is_in_subset(&self) -> bool
unsafe fn to_subset_unchecked(&self) -> SS
fn from_subset(element: &SS) -> SP
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,