[][src]Struct math2d::BezierSegment

#[repr(C)]
pub struct BezierSegment { pub p1: Point2f, pub p2: Point2f, pub p3: Point2f, }

Represents a cubic bezier segment drawn between two points. The first point in the bezier segment is implicitly the end point of the previous segment.

Fields

p1: Point2f

The first control point

p2: Point2f

The second control point

p3: Point2f

The end point

Methods

impl BezierSegment[src]

pub fn new(
    p1: impl Into<Point2f>,
    p2: impl Into<Point2f>,
    p3: impl Into<Point2f>
) -> BezierSegment
[src]

Construct the segment from its parts, conveniently converting types like float tuples into points.

Trait Implementations

impl Copy for BezierSegment[src]

impl PartialEq<BezierSegment> for BezierSegment[src]

impl Default for BezierSegment[src]

impl<P1, P2, P3> From<(P1, P2, P3)> for BezierSegment where
    P1: Into<Point2f>,
    P2: Into<Point2f>,
    P3: Into<Point2f>, 
[src]

impl Clone for BezierSegment[src]

fn clone_from(&mut self, source: &Self)
1.0.0
[src]

Performs copy-assignment from source. Read more

impl Debug for BezierSegment[src]

impl Serialize for BezierSegment[src]

impl<'de> Deserialize<'de> for BezierSegment[src]

Auto Trait Implementations

Blanket Implementations

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

impl<T> From for T[src]

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: Deserialize<'de>, 
[src]