[][src]Type Definition nannou::draw::primitive::polygon::DrawingPolygonInit

type DrawingPolygonInit<'a, S = Default> = Drawing<'a, PolygonInit<S>, S>;

Initialised drawing state for a polygon.

Methods

impl<'a, S> DrawingPolygonInit<'a, S> where
    S: BaseFloat
[src]

pub fn stroke<C>(self, color: C) -> Self where
    C: IntoLinSrgba<ColorScalar>, 
[src]

Stroke the outline with the given color.

pub fn events<I>(self, events: I) -> DrawingPolygon<'a, S> where
    S: BaseFloat,
    I: IntoIterator<Item = PathEvent>, 
[src]

Describe the polygon with a sequence of path events.

pub fn points<I>(self, points: I) -> DrawingPolygon<'a, S> where
    S: BaseFloat,
    I: IntoIterator,
    I::Item: Into<Point2<S>>, 
[src]

Describe the polygon with a sequence of points.

pub fn points_colored<I, P, C>(self, points: I) -> DrawingPolygon<'a, S> where
    S: BaseFloat,
    I: IntoIterator<Item = (P, C)>,
    P: Into<Point2<S>>,
    C: IntoLinSrgba<ColorScalar>, 
[src]

Consumes an iterator of points and converts them to an iterator yielding path events.

pub fn points_textured<I, P, T>(
    self,
    view: &dyn ToTextureView,
    points: I
) -> DrawingPolygon<'a, S> where
    S: BaseFloat,
    I: IntoIterator<Item = (P, T)>,
    P: Into<Point2<S>>,
    T: Into<TexCoords<S>>, 
[src]

Describe the polygon with an iterator yielding textured poings.