pub struct PairSection3 {
pub first: Carrier,
pub second: Carrier,
pub nodes: Vec<PairNode>,
}Expand description
A stretch of the curve where two surfaces meet. The parameter runs over
[0, nodes.len() - 1], one unit per chord.
Fields§
§first: CarrierThe first surface.
second: CarrierThe second surface.
nodes: Vec<PairNode>Nodes on both, in order along the curve.
Implementations§
Source§impl PairSection3
impl PairSection3
Sourcepub fn solve(&self, t: f64) -> Option<(DVec2, DVec2, DVec3)>
pub fn solve(&self, t: f64) -> Option<(DVec2, DVec2, DVec3)>
The parameters on both surfaces at t, and the point.
Sourcepub fn rates(&self, t: f64) -> Option<(DVec2, DVec2, DVec3)>
pub fn rates(&self, t: f64) -> Option<(DVec2, DVec2, DVec3)>
The rates of both surfaces’ parameters and of the point at t:
from S1_a a' - S2_b b' = 0 and d . S1_a a' = |d|^2.
Sourcepub fn second_rates(&self, t: f64) -> Option<(DVec2, DVec2, DVec3)>
pub fn second_rates(&self, t: f64) -> Option<(DVec2, DVec2, DVec3)>
The second rates of both surfaces’ parameters and of the point at
t, by central differences of Self::rates inside the chord.
Sourcepub fn side(&self, carrier: &Carrier) -> Option<bool>
pub fn side(&self, carrier: &Carrier) -> Option<bool>
Which of the two surfaces carrier is: Some(true) for the first,
Some(false) for the second.
Sourcepub fn sub(&self, t0: f64, t1: f64) -> Option<PairSection3>
pub fn sub(&self, t0: f64, t1: f64) -> Option<PairSection3>
The stretch from t0 to t1 (t0 < t1) as a curve of its own over
[0, nodes]: the nodes between, and new end nodes solved at t0 and
t1.
Sourcepub fn reversed(&self) -> PairSection3
pub fn reversed(&self) -> PairSection3
The same curve run backwards.
Sourcepub fn parameter_of(&self, p: DVec3) -> Option<f64>
pub fn parameter_of(&self, p: DVec3) -> Option<f64>
The parameter of a point on the curve: the chord nearest it, the plane across that chord through the point, then Newton along the curve’s tangent within the chord.
Trait Implementations§
Source§impl Clone for PairSection3
impl Clone for PairSection3
Source§fn clone(&self) -> PairSection3
fn clone(&self) -> PairSection3
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for PairSection3
impl Debug for PairSection3
Source§impl PartialEq for PairSection3
impl PartialEq for PairSection3
impl StructuralPartialEq for PairSection3
Auto Trait Implementations§
impl Freeze for PairSection3
impl RefUnwindSafe for PairSection3
impl Send for PairSection3
impl Sync for PairSection3
impl Unpin for PairSection3
impl UnwindSafe for PairSection3
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
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>
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>
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