diff options
| author | Sébastien Crozet <sebcrozet@dimforge.com> | 2024-05-04 17:51:15 +0200 |
|---|---|---|
| committer | Sébastien Crozet <sebastien@crozet.re> | 2024-05-05 16:17:39 +0200 |
| commit | 7565e5e4efb56bb8ba987c251b932bffc15a40c8 (patch) | |
| tree | 037acb54bcb7384811214f966bb5e5680ac17d5c /src/pipeline | |
| parent | dbefeb04186226536ec7f4f248c71f056265916a (diff) | |
| download | rapier-7565e5e4efb56bb8ba987c251b932bffc15a40c8.tar.gz rapier-7565e5e4efb56bb8ba987c251b932bffc15a40c8.tar.bz2 rapier-7565e5e4efb56bb8ba987c251b932bffc15a40c8.zip | |
chore: update to the latest parry api
Diffstat (limited to 'src/pipeline')
| -rw-r--r-- | src/pipeline/query_pipeline.rs | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/src/pipeline/query_pipeline.rs b/src/pipeline/query_pipeline.rs index d98017b..f202107 100644 --- a/src/pipeline/query_pipeline.rs +++ b/src/pipeline/query_pipeline.rs @@ -9,12 +9,12 @@ use parry::query::details::{ NonlinearTOICompositeShapeShapeBestFirstVisitor, NormalConstraints, PointCompositeShapeProjBestFirstVisitor, PointCompositeShapeProjWithFeatureBestFirstVisitor, RayCompositeShapeToiAndNormalBestFirstVisitor, RayCompositeShapeToiBestFirstVisitor, - TOICompositeShapeShapeBestFirstVisitor, + ShapeCastOptions, TOICompositeShapeShapeBestFirstVisitor, }; use parry::query::visitors::{ BoundingVolumeIntersectionsVisitor, PointIntersectionsVisitor, RayIntersectionsVisitor, }; -use parry::query::{DefaultQueryDispatcher, NonlinearRigidMotion, QueryDispatcher, TOI}; +use parry::query::{DefaultQueryDispatcher, NonlinearRigidMotion, QueryDispatcher, ShapeCastHit}; use parry::shape::{FeatureId, Shape, TypedSimdCompositeShape}; use std::sync::Arc; @@ -679,10 +679,9 @@ impl QueryPipeline { shape_pos: &Isometry<Real>, shape_vel: &Vector<Real>, shape: &dyn Shape, - max_toi: Real, - stop_at_penetration: bool, + options: ShapeCastOptions, filter: QueryFilter, - ) -> Option<(ColliderHandle, TOI)> { + ) -> Option<(ColliderHandle, ShapeCastHit)> { let pipeline_shape = self.as_composite_shape(bodies, colliders, filter); let mut visitor = TOICompositeShapeShapeBestFirstVisitor::new( &*self.query_dispatcher, @@ -690,8 +689,7 @@ impl QueryPipeline { shape_vel, &pipeline_shape, shape, - max_toi, - stop_at_penetration, + options, ); self.qbvh.traverse_best_first(&mut visitor).map(|h| h.1) } @@ -725,7 +723,7 @@ impl QueryPipeline { end_time: Real, stop_at_penetration: bool, filter: QueryFilter, - ) -> Option<(ColliderHandle, TOI)> { + ) -> Option<(ColliderHandle, ShapeCastHit)> { let pipeline_shape = self.as_composite_shape(bodies, colliders, filter); let pipeline_motion = NonlinearRigidMotion::identity(); let mut visitor = NonlinearTOICompositeShapeShapeBestFirstVisitor::new( |
