pub struct Polyline<P> {
pub points: Vec<P>,
pub closed: bool,
}Expand description
Piecewise-linear curve preserving source vertex order.
Its native parameter is one unit per segment, not arc length and not a
normalised (0, 1): an open n-point polyline spans (0, n - 1) and a
closed one (0, n). A trim or profile-segment domain of (0, 1) on a
multi-segment polyline therefore selects only its first edge; the scalar
flattener in axiolid-evaluate refuses that rather than silently dropping
the remaining vertices.
Fields§
§points: Vec<P>Ordered control points.
closed: boolWhether the final point connects back to the first.
Trait Implementations§
Source§impl<'de, P> Deserialize<'de> for Polyline<P>where
P: Deserialize<'de>,
impl<'de, P> Deserialize<'de> for Polyline<P>where
P: Deserialize<'de>,
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<Polyline<P>, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<Polyline<P>, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl<P> Serialize for Polyline<P>where
P: Serialize,
impl<P> Serialize for Polyline<P>where
P: Serialize,
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl<P> StructuralPartialEq for Polyline<P>where
P: PartialEq,
Auto Trait Implementations§
impl<P> Freeze for Polyline<P>
impl<P> RefUnwindSafe for Polyline<P>where
P: RefUnwindSafe,
impl<P> Send for Polyline<P>where
P: Send,
impl<P> Sync for Polyline<P>where
P: Sync,
impl<P> Unpin for Polyline<P>where
P: Unpin,
impl<P> UnsafeUnpin for Polyline<P>
impl<P> UnwindSafe for Polyline<P>where
P: UnwindSafe,
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