From e231bacec608fa5efd24f7a876572927dbd6c9c4 Mon Sep 17 00:00:00 2001 From: Crozet Sébastien Date: Thu, 17 Dec 2020 10:24:36 +0100 Subject: Move all the contact manifold computations out of Rapier. --- src/geometry/proximity.rs | 43 ------------------------------------------- 1 file changed, 43 deletions(-) delete mode 100644 src/geometry/proximity.rs (limited to 'src/geometry/proximity.rs') diff --git a/src/geometry/proximity.rs b/src/geometry/proximity.rs deleted file mode 100644 index d3e0dc4..0000000 --- a/src/geometry/proximity.rs +++ /dev/null @@ -1,43 +0,0 @@ -use crate::geometry::proximity_detector::ProximityPhase; -use crate::geometry::{ColliderPair, Proximity}; -use std::any::Any; - -#[cfg_attr(feature = "serde-serialize", derive(Serialize, Deserialize))] -/// The description of the proximity of two colliders. -pub struct ProximityPair { - /// The pair of collider involved. - pub pair: ColliderPair, - /// The state of proximity between the two colliders. - pub proximity: Proximity, - #[cfg_attr(feature = "serde-serialize", serde(skip))] - pub(crate) detector: Option, - #[cfg_attr(feature = "serde-serialize", serde(skip))] - pub(crate) detector_workspace: Option>, -} - -// TODO: use the `derive(Clone)` instead? -impl Clone for ProximityPair { - fn clone(&self) -> Self { - ProximityPair { - pair: self.pair.clone(), - proximity: self.proximity.clone(), - detector: None, - detector_workspace: None, - } - } -} - -impl ProximityPair { - pub(crate) fn new( - pair: ColliderPair, - detector: ProximityPhase, - detector_workspace: Option>, - ) -> Self { - Self { - pair, - proximity: Proximity::Disjoint, - detector: Some(detector), - detector_workspace, - } - } -} -- cgit