pub struct RoutePath {
pub chain: Chain<NurbCurve3D>,
pub places: Vec<String>,
}Expand description
A route: a chain of lines and arcs through waypoints, named for the
solid swept along it — w{i} the i-th waypoint, m{i} where the two
arcs between it and the next meet, a{i} the arc from w{i} to m{i}
(or the line from w{i} to w{i+1}, if both are straight) and b{i}
the arc from m{i} on.
Fields§
§chain: Chain<NurbCurve3D>§places: Vec<String>Where each curve of the chain lies, as the route says it:
between point 1 (…) and point 2 (…).
Implementations§
Source§impl RoutePath
impl RoutePath
Sourcepub fn through(waypoints: &[Waypoint]) -> GeopResult<Self>
pub fn through(waypoints: &[Waypoint]) -> GeopResult<Self>
The route through waypoints, in order (see the module docs). Where
a waypoint leaves the direction free, the route chooses it: in
between, it turns as much before as after, along the bisector of the
chords to its neighbours; at an end, it bends into the next
waypoint’s direction in one arc — or runs straight, between two free
ends.
Sourcepub fn measure(&self) -> GeopResult<Measure>
pub fn measure(&self) -> GeopResult<Measure>
How long the route is and where it bends how tightly. Its curves are
lines and arcs — what RoutePath::through builds; a chain with
any other curve is not measured.