chore: clippy fixes
This commit is contained in:
committed by
Sébastien Crozet
parent
929aa6b925
commit
0a9153e273
@@ -178,10 +178,16 @@ impl IntegrationParameters {
|
||||
* self.joint_damping_ratio)
|
||||
}
|
||||
|
||||
/// Amount of penetration the engine won’t attempt to correct (default: `0.001` multiplied by
|
||||
/// [`Self::length_unit`]).
|
||||
pub fn allowed_linear_error(&self) -> Real {
|
||||
self.normalized_allowed_linear_error * self.length_unit
|
||||
}
|
||||
|
||||
/// Maximum amount of penetration the solver will attempt to resolve in one timestep.
|
||||
///
|
||||
/// This is equal to [`Self::normalized_max_penetration_correction`] multiplied by
|
||||
/// [`Self::length_unit`].
|
||||
pub fn max_penetration_correction(&self) -> Real {
|
||||
if self.normalized_max_penetration_correction != Real::MAX {
|
||||
self.normalized_max_penetration_correction * self.length_unit
|
||||
@@ -190,11 +196,13 @@ impl IntegrationParameters {
|
||||
}
|
||||
}
|
||||
|
||||
/// The maximal distance separating two objects that will generate predictive contacts
|
||||
/// (default: `0.002m` multiped by [`Self::length_unit`]).
|
||||
pub fn prediction_distance(&self) -> Real {
|
||||
self.normalized_prediction_distance * self.length_unit
|
||||
}
|
||||
|
||||
/// Initialize the simulation paramaters with settings matching the TGS-soft solver
|
||||
/// Initialize the simulation parameters with settings matching the TGS-soft solver
|
||||
/// with warmstarting.
|
||||
///
|
||||
/// This is the default configuration, equivalent to [`IntegrationParameters::default()`].
|
||||
|
||||
@@ -128,7 +128,7 @@ impl OneBodyConstraintBuilder {
|
||||
// Normal part.
|
||||
let normal_rhs_wo_bias;
|
||||
{
|
||||
let mut gcross2 = mprops2
|
||||
let gcross2 = mprops2
|
||||
.effective_world_inv_inertia_sqrt
|
||||
.transform_vector(dp2.gcross(-force_dir1));
|
||||
|
||||
|
||||
@@ -8,7 +8,6 @@ use crate::geometry::{ContactManifold, ContactManifoldIndex};
|
||||
use crate::math::{Isometry, Real, Vector, DIM, MAX_MANIFOLD_POINTS};
|
||||
use crate::utils::{self, SimdAngularInertia, SimdBasis, SimdCross, SimdDot};
|
||||
use na::{DVector, Matrix2};
|
||||
use num::Pow;
|
||||
|
||||
use super::{TwoBodyConstraintElement, TwoBodyConstraintNormalPart};
|
||||
|
||||
|
||||
@@ -1,11 +1,9 @@
|
||||
use crate::dynamics::integration_parameters::BLOCK_SOLVER_ENABLED;
|
||||
use crate::dynamics::solver::contact_constraint::OneBodyConstraintNormalPart;
|
||||
use crate::dynamics::solver::SolverVel;
|
||||
use crate::math::{AngVector, TangentImpulse, Vector, DIM};
|
||||
use crate::utils::{SimdBasis, SimdDot, SimdRealCopy};
|
||||
use na::{Matrix2, Vector2};
|
||||
use num::Zero;
|
||||
use simba::simd::{SimdPartialOrd, SimdValue};
|
||||
use na::Vector2;
|
||||
use simba::simd::SimdValue;
|
||||
|
||||
#[derive(Copy, Clone, Debug)]
|
||||
pub(crate) struct TwoBodyConstraintTangentPart<N: SimdRealCopy> {
|
||||
|
||||
@@ -14,7 +14,6 @@ use crate::math::{
|
||||
#[cfg(feature = "dim2")]
|
||||
use crate::utils::SimdBasis;
|
||||
use crate::utils::{self, SimdAngularInertia, SimdCross, SimdDot};
|
||||
use na::Matrix2;
|
||||
use num::Zero;
|
||||
use parry::math::SimdBool;
|
||||
use parry::utils::SdpMatrix2;
|
||||
|
||||
@@ -10,7 +10,6 @@ use crate::math::Real;
|
||||
use crate::prelude::RigidBodyVelocity;
|
||||
use crate::utils::SimdAngularInertia;
|
||||
use na::DVector;
|
||||
use ordered_float::OrderedFloat;
|
||||
|
||||
pub(crate) struct VelocitySolver {
|
||||
pub solver_bodies: Vec<SolverBody>,
|
||||
|
||||
Reference in New Issue
Block a user