diff options
| author | Crozet Sébastien <developer@crozet.re> | 2021-01-04 15:14:25 +0100 |
|---|---|---|
| committer | Crozet Sébastien <developer@crozet.re> | 2021-01-04 15:14:25 +0100 |
| commit | aa61fe65e3ff0289ecab57b4053a3410cf6d4a87 (patch) | |
| tree | a2ab513f43d779e4eb1c0edcd2a6e734b3fa4470 /src/dynamics/solver/joint_constraint/joint_constraint.rs | |
| parent | a1aa8855f76168d8af14244a54c9f28d15696342 (diff) | |
| download | rapier-aa61fe65e3ff0289ecab57b4053a3410cf6d4a87.tar.gz rapier-aa61fe65e3ff0289ecab57b4053a3410cf6d4a87.tar.bz2 rapier-aa61fe65e3ff0289ecab57b4053a3410cf6d4a87.zip | |
Add support of 64-bits reals.
Diffstat (limited to 'src/dynamics/solver/joint_constraint/joint_constraint.rs')
| -rw-r--r-- | src/dynamics/solver/joint_constraint/joint_constraint.rs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/dynamics/solver/joint_constraint/joint_constraint.rs b/src/dynamics/solver/joint_constraint/joint_constraint.rs index 8b1f8bf..ed6d758 100644 --- a/src/dynamics/solver/joint_constraint/joint_constraint.rs +++ b/src/dynamics/solver/joint_constraint/joint_constraint.rs @@ -17,6 +17,7 @@ use crate::dynamics::solver::DeltaVel; use crate::dynamics::{ IntegrationParameters, Joint, JointGraphEdge, JointIndex, JointParams, RigidBodySet, }; +use crate::math::Real; #[cfg(feature = "simd-is-enabled")] use crate::math::SIMD_WIDTH; @@ -220,7 +221,7 @@ impl AnyJointVelocityConstraint { } } - pub fn warmstart(&self, mj_lambdas: &mut [DeltaVel<f32>]) { + pub fn warmstart(&self, mj_lambdas: &mut [DeltaVel<Real>]) { match self { AnyJointVelocityConstraint::BallConstraint(c) => c.warmstart(mj_lambdas), AnyJointVelocityConstraint::BallGroundConstraint(c) => c.warmstart(mj_lambdas), @@ -254,7 +255,7 @@ impl AnyJointVelocityConstraint { } } - pub fn solve(&mut self, mj_lambdas: &mut [DeltaVel<f32>]) { + pub fn solve(&mut self, mj_lambdas: &mut [DeltaVel<Real>]) { match self { AnyJointVelocityConstraint::BallConstraint(c) => c.solve(mj_lambdas), AnyJointVelocityConstraint::BallGroundConstraint(c) => c.solve(mj_lambdas), |
