pub struct LinearSegment {
pub start: Pose,
pub length: f64,
}Available on crate feature
path-traits only.Expand description
A straight-line segment starting at start with given length.
The heading stays constant along the segment.
Fields§
§start: PoseStarting pose (position and heading).
length: f64Arc-length of the segment.
Trait Implementations§
Source§impl Clone for LinearSegment
impl Clone for LinearSegment
Source§fn clone(&self) -> LinearSegment
fn clone(&self) -> LinearSegment
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Curved for LinearSegment
impl Curved for LinearSegment
Source§impl Debug for LinearSegment
impl Debug for LinearSegment
Source§impl FrenetFrame for LinearSegment
impl FrenetFrame for LinearSegment
Source§impl Heading for LinearSegment
impl Heading for LinearSegment
Source§impl ParametricPath for LinearSegment
impl ParametricPath for LinearSegment
Source§impl Path for LinearSegment
impl Path for LinearSegment
Source§type Error = PathError<f64>
type Error = PathError<f64>
The error type for fallible operations. Must be convertible from
PathError<Self::Scalar>.Source§fn sample_at(&self, s: f64) -> Result<Self::Point, Self::Error>
fn sample_at(&self, s: f64) -> Result<Self::Point, Self::Error>
Sample the path at arc-length
s ∈ [0, length]. Read moreSource§fn start(&self) -> Result<Self::Point, Self::Error>
fn start(&self) -> Result<Self::Point, Self::Error>
The start point of the path, equivalent to
sample_at(0).Source§fn end(&self) -> Result<Self::Point, Self::Error>
fn end(&self) -> Result<Self::Point, Self::Error>
The end point of the path, equivalent to
sample_at(length).Source§fn domain(&self) -> RangeInclusive<Self::Scalar>
fn domain(&self) -> RangeInclusive<Self::Scalar>
The valid domain for arc-length sampling:
[0, length].Source§impl Project for LinearSegment
impl Project for LinearSegment
Source§impl Tangent for LinearSegment
impl Tangent for LinearSegment
impl Copy for LinearSegment
impl PathSegment for LinearSegment
Auto Trait Implementations§
impl Freeze for LinearSegment
impl RefUnwindSafe for LinearSegment
impl Send for LinearSegment
impl Sync for LinearSegment
impl Unpin for LinearSegment
impl UnsafeUnpin for LinearSegment
impl UnwindSafe for LinearSegment
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