pub struct Trajectory { /* private fields */ }Expand description
Ordered trajectory of stamped poses.
Implementations§
Source§impl Trajectory
impl Trajectory
Sourcepub fn push(&mut self, sample: StampedPose) -> MappingResult<()>
pub fn push(&mut self, sample: StampedPose) -> MappingResult<()>
Appends a sample; timestamps must be non-decreasing.
Sourcepub fn samples(&self) -> &[StampedPose]
pub fn samples(&self) -> &[StampedPose]
Returns all samples.
Sourcepub fn last(&self) -> Option<&StampedPose>
pub fn last(&self) -> Option<&StampedPose>
Returns the latest sample.
Sourcepub fn interpolate(&self, nanos: u64) -> MappingResult<Pose3<f32>>
pub fn interpolate(&self, nanos: u64) -> MappingResult<Pose3<f32>>
Linearly interpolates translation between bracketing samples (rotation holds the earlier).
Trait Implementations§
Source§impl Clone for Trajectory
impl Clone for Trajectory
Source§fn clone(&self) -> Trajectory
fn clone(&self) -> Trajectory
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for Trajectory
impl Debug for Trajectory
Source§impl Default for Trajectory
impl Default for Trajectory
Source§fn default() -> Trajectory
fn default() -> Trajectory
Returns the “default value” for a type. Read more
Source§impl PartialEq for Trajectory
impl PartialEq for Trajectory
Source§fn eq(&self, other: &Trajectory) -> bool
fn eq(&self, other: &Trajectory) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for Trajectory
Auto Trait Implementations§
impl Freeze for Trajectory
impl RefUnwindSafe for Trajectory
impl Send for Trajectory
impl Sync for Trajectory
impl Unpin for Trajectory
impl UnsafeUnpin for Trajectory
impl UnwindSafe for Trajectory
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more