/// Consumes an iterator of points and converts them to an iterator yielding path events.
Consumes an iterator of points and converts them to an iterator yielding path events.
Consumes an iterator of points and converts them to an iterator yielding path events .
pub fn points<I>(self, ctxt: DrawingContext<S>, points: I) -> Polygon<S>
    where
        S: BaseFloat,
        I: IntoIterator,
        I::Item: Into<Point2<S>>,
    {
        let points = points.into_iter().map(|p| {
            let p: Point2<f32> = p.into().cast().expect("failed to cast point");
            p.into()
        });
        let close = true;
        let events = lyon::path::iterator::FromPolyline::new(close, points).path_events();
        self.events(ctxt, events)
    }
pub fn points < I > ( self , ctxt : DrawingContext < S > , points : I ) -> Polygon < S > where S : BaseFloat , I : IntoIterator , I :: Item : Into < Point2 < S > > , { let points = points . into_iter ( ) . map ( | p | { let p : Point2 < f32 > = p . into ( ) . cast ( ) . expect ( " " ) ; p . into ( ) } ) ; let close = true ; let events = lyon :: path :: iterator :: FromPolyline :: new ( close , points ) . path_events ( ) ; self . events ( ctxt , events ) }
Consumes an iterator of points and converts them to an iterator yielding path events.
Consumes an iterator of points and converts them to an iterator yielding path events .
self
ctxt
DrawingContext<S>
points
I