Skip to main content

IntrinsicPositions

Struct IntrinsicPositions 

Source
pub struct IntrinsicPositions { /* private fields */ }
Expand description

Certified positions of an intrinsic curve: the unit tangent of its closed-form heading integrated by the composite midpoint rule, each point with a certified bound on its error (the remainder w^3 / 24 (|k'| + k^2) per panel, panels split at seams, and the heading’s, the sums’ and the placement’s rounding).

Implementations§

Source§

impl IntrinsicPositions

Source

pub fn new2(curve: &Intrinsic2, error: f64) -> Option<IntrinsicPositions>

Positions of a 2D intrinsic curve within about error, half of it spent on the midpoint remainders; None for a non-positive or non-finite error or length, a law with no closed-form bound, or more than MAX_POSITION_PANELS panels.

Source

pub fn new3(curve: &Intrinsic3, error: f64) -> Option<IntrinsicPositions>

Positions of a planar space curve (its torsion law identically zero, Intrinsic3::is_planar); None as for Self::new2, or for a curve with torsion.

Source

pub fn point2(&mut self, s: f64) -> Option<(DVec2, f64)>

The point at arc length s of a 2D curve and a certified bound on its distance from the exact point; None outside [0, length], for a law that does not integrate there, or for a space curve.

Source

pub fn point3(&mut self, s: f64) -> Option<(DVec3, f64)>

Self::point2 for a planar space curve.

Source

pub fn offset_point2(&mut self, s: f64, distance: f64) -> Option<(DVec2, f64)>

The point at arc length s of the 2D curve’s offset by distance to its left (the curve of super::offset_point2) and a certified bound on its distance from the exact one: the point’s, plus |d| times the turn of the left normal by the heading’s rounding through the start frame (its stretch squared over its determinant bounds its condition) and the normalisation’s rounding.

Trait Implementations§

Source§

impl Clone for IntrinsicPositions

Source§

fn clone(&self) -> IntrinsicPositions

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for IntrinsicPositions

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.