diff options
| author | Bruce Mitchener <bruce.mitchener@gmail.com> | 2024-05-05 16:41:38 +0630 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-05-05 12:11:38 +0200 |
| commit | 7375a691e232bb59033980dc09c7179bc16e377f (patch) | |
| tree | 1713a55a9c8a4199292c4668c950404ba1e033c1 /src | |
| parent | 1b05b2ebfac63034d3dd14a7a5b9b87c59377529 (diff) | |
| download | rapier-7375a691e232bb59033980dc09c7179bc16e377f.tar.gz rapier-7375a691e232bb59033980dc09c7179bc16e377f.tar.bz2 rapier-7375a691e232bb59033980dc09c7179bc16e377f.zip | |
Fix some typos. (#620)
Diffstat (limited to 'src')
| -rw-r--r-- | src/control/character_controller.rs | 2 | ||||
| -rw-r--r-- | src/counters/mod.rs | 6 | ||||
| -rw-r--r-- | src/counters/stages_counters.rs | 2 | ||||
| -rw-r--r-- | src/data/graph.rs | 2 | ||||
| -rw-r--r-- | src/data/pubsub.rs | 2 | ||||
| -rw-r--r-- | src/dynamics/rigid_body.rs | 2 | ||||
| -rw-r--r-- | src/dynamics/rigid_body_components.rs | 2 | ||||
| -rw-r--r-- | src/dynamics/rigid_body_set.rs | 2 | ||||
| -rw-r--r-- | src/dynamics/solver/solver_constraints_set.rs | 2 | ||||
| -rw-r--r-- | src/geometry/broad_phase.rs | 2 | ||||
| -rw-r--r-- | src/geometry/collider.rs | 2 | ||||
| -rw-r--r-- | src/pipeline/query_pipeline.rs | 2 | ||||
| -rw-r--r-- | src/utils.rs | 2 |
13 files changed, 15 insertions, 15 deletions
diff --git a/src/control/character_controller.rs b/src/control/character_controller.rs index ca088b2..cc12bd8 100644 --- a/src/control/character_controller.rs +++ b/src/control/character_controller.rs @@ -18,7 +18,7 @@ pub enum CharacterLength { /// for a shape with an height equal to 20.0 will result in a maximum step height /// of `0.1 * 20.0 = 2.0`. Relative(Real), - /// The length is specified as an aboslute value, independent from the character shape’s size. + /// The length is specified as an absolute value, independent from the character shape’s size. /// /// For example setting `CharacterAutostep::max_height` to `CharacterLength::Relative(0.1)` /// for a shape with an height equal to 20.0 will result in a maximum step height diff --git a/src/counters/mod.rs b/src/counters/mod.rs index e707025..99a627a 100644 --- a/src/counters/mod.rs +++ b/src/counters/mod.rs @@ -17,7 +17,7 @@ mod timer; /// Aggregation of all the performances counters tracked by rapier. #[derive(Clone, Copy)] pub struct Counters { - /// Whether thi counter is enabled or not. + /// Whether this counter is enabled or not. pub enabled: bool, /// Timer for a whole timestep. pub step_time: Timer, @@ -69,7 +69,7 @@ impl Counters { } } - /// Notfy that the time-step has finished. + /// Notify that the time-step has finished. pub fn step_completed(&mut self) { if self.enabled { self.step_time.pause(); @@ -88,7 +88,7 @@ impl Counters { } } - /// Notfy that the custom operation has finished. + /// Notify that the custom operation has finished. pub fn custom_completed(&mut self) { if self.enabled { self.custom.pause(); diff --git a/src/counters/stages_counters.rs b/src/counters/stages_counters.rs index 7e3198a..3134986 100644 --- a/src/counters/stages_counters.rs +++ b/src/counters/stages_counters.rs @@ -21,7 +21,7 @@ pub struct StagesCounters { } impl StagesCounters { - /// Create a new counter intialized to zero. + /// Create a new counter initialized to zero. pub fn new() -> Self { StagesCounters { update_time: Timer::new(), diff --git a/src/data/graph.rs b/src/data/graph.rs index 6a3ba15..6c701e4 100644 --- a/src/data/graph.rs +++ b/src/data/graph.rs @@ -370,7 +370,7 @@ impl<N, E> Graph<N, E> { // indices. let edge = self.edges.swap_remove(e.index()); let swap = match self.edges.get(e.index()) { - // no elment needed to be swapped. + // no element needed to be swapped. None => return Some(edge.weight), Some(ed) => ed.node, }; diff --git a/src/data/pubsub.rs b/src/data/pubsub.rs index 619521e..d595e03 100644 --- a/src/data/pubsub.rs +++ b/src/data/pubsub.rs @@ -103,7 +103,7 @@ impl<T> PubSub<T> { subscription } - /// Read the i-th message not yet read by the given subsciber. + /// Read the i-th message not yet read by the given subscriber. pub fn read_ith(&self, sub: &Subscription<T>, i: usize) -> Option<&T> { let cursor = &self.cursors[sub.id as usize]; self.messages.get(cursor.next(self.deleted_messages) + i) diff --git a/src/dynamics/rigid_body.rs b/src/dynamics/rigid_body.rs index 7f95a31..b822aa9 100644 --- a/src/dynamics/rigid_body.rs +++ b/src/dynamics/rigid_body.rs @@ -443,7 +443,7 @@ impl RigidBody { self.ccd.ccd_enabled = enabled; } - /// Is CCD (continous collision-detection) enabled for this rigid-body? + /// Is CCD (continuous collision-detection) enabled for this rigid-body? pub fn is_ccd_enabled(&self) -> bool { self.ccd.ccd_enabled } diff --git a/src/dynamics/rigid_body_components.rs b/src/dynamics/rigid_body_components.rs index f5698a4..a391feb 100644 --- a/src/dynamics/rigid_body_components.rs +++ b/src/dynamics/rigid_body_components.rs @@ -595,7 +595,7 @@ impl RigidBodyVelocity { } /// Integrate the velocities in `self` to compute obtain new positions when moving from the given - /// inital position `init_pos`. + /// initial position `init_pos`. #[must_use] pub fn integrate( &self, diff --git a/src/dynamics/rigid_body_set.rs b/src/dynamics/rigid_body_set.rs index 2356364..a7d2ec3 100644 --- a/src/dynamics/rigid_body_set.rs +++ b/src/dynamics/rigid_body_set.rs @@ -209,7 +209,7 @@ impl RigidBodySet { /// Update colliders positions after rigid-bodies moved. /// /// When a rigid-body moves, the positions of the colliders attached to it need to be updated. - /// This update is generally automatically done at the beggining and the end of each simulation + /// This update is generally automatically done at the beginning and the end of each simulation /// step with `PhysicsPipeline::step`. If the positions need to be updated without running a /// simulation step (for example when using the `QueryPipeline` alone), this method can be called /// manually. diff --git a/src/dynamics/solver/solver_constraints_set.rs b/src/dynamics/solver/solver_constraints_set.rs index 4259098..1161c55 100644 --- a/src/dynamics/solver/solver_constraints_set.rs +++ b/src/dynamics/solver/solver_constraints_set.rs @@ -96,7 +96,7 @@ impl<Constraints: ConstraintTypes> SolverConstraintsSet<Constraints> { } } - #[allow(dead_code)] // Useful for debuging. + #[allow(dead_code)] // Useful for debugging. pub fn print_counts(&self) { println!("Solver constraints:"); println!( diff --git a/src/geometry/broad_phase.rs b/src/geometry/broad_phase.rs index ea7c774..836ebc8 100644 --- a/src/geometry/broad_phase.rs +++ b/src/geometry/broad_phase.rs @@ -8,7 +8,7 @@ pub type BroadPhaseProxyIndex = u32; /// Trait implemented by broad-phase algorithms supported by Rapier. /// /// The task of a broad-phase algorithm is to detect potential collision pairs, usually based on -/// bounding volumes. The pairs must be concervative: it is OK to create a collision pair if +/// bounding volumes. The pairs must be conservative: it is OK to create a collision pair if /// two objects don’t actually touch, but it is incorrect to remove a pair between two objects /// that are still touching. In other words, it can have false-positive (though these induce /// some computational overhead on the narrow-phase), but cannot have false-negative. diff --git a/src/geometry/collider.rs b/src/geometry/collider.rs index e02b0f2..dfa532c 100644 --- a/src/geometry/collider.rs +++ b/src/geometry/collider.rs @@ -302,7 +302,7 @@ impl Collider { } } - /// Sets the rotational part of this collider's rotaiton relative to its parent rigid-body. + /// Sets the rotational part of this collider's rotation relative to its parent rigid-body. pub fn set_rotation_wrt_parent(&mut self, rotation: AngVector<Real>) { if let Some(parent) = self.parent.as_mut() { self.changes.insert(ColliderChanges::PARENT); diff --git a/src/pipeline/query_pipeline.rs b/src/pipeline/query_pipeline.rs index bca0cc4..d98017b 100644 --- a/src/pipeline/query_pipeline.rs +++ b/src/pipeline/query_pipeline.rs @@ -100,7 +100,7 @@ impl QueryFilterFlags { } } -/// A filter tha describes what collider should be included or excluded from a scene query. +/// A filter that describes what collider should be included or excluded from a scene query. #[derive(Copy, Clone, Default)] pub struct QueryFilter<'a> { /// Flags indicating what particular type of colliders should be excluded from the scene query. diff --git a/src/utils.rs b/src/utils.rs index 6521b0f..5025744 100644 --- a/src/utils.rs +++ b/src/utils.rs @@ -647,7 +647,7 @@ impl SimdAngularInertia<SimdReal> for SdpMatrix3<SimdReal> { } // This is an RAII structure that enables flushing denormal numbers -// to zero, and automatically reseting previous flags once it is dropped. +// to zero, and automatically resetting previous flags once it is dropped. #[derive(Clone, Debug, PartialEq, Eq)] pub(crate) struct FlushToZeroDenormalsAreZeroFlags { original_flags: u32, |
