Struct lyon_tessellation::EventQueue

source ·
pub struct EventQueue { /* private fields */ }
Expand description

A queue of sorted events for the fill tessellator’s sweep-line algorithm.

Implementations§

source§

impl EventQueue

source

pub fn new() -> Self

source

pub fn with_capacity(cap: usize) -> Self

source

pub fn reset(&mut self)

source

pub fn from_path( tolerance: f32, path: impl IntoIterator<Item = PathEvent> ) -> Self

Creates an EventQueue from an iterator of path event and a tolerance threshold.

The tolerance threshold is used for curve flattening approximation. See the Flattening and tolerance section of the crate documentation.

source

pub fn from_path_with_ids( tolerance: f32, sweep_orientation: Orientation, path: impl IntoIterator<Item = IdEvent>, positions: &impl PositionStore ) -> Self

Creates an EventQueue from an an iterator over endpoint and control point ids, storage for the positions and, optionally, storage for custom endpoint attributes.

The tolerance threshold is used for curve flattening approximation. See the Flattening and tolerance section of the crate documentation.

source

pub fn into_builder(self, tolerance: f32) -> EventQueueBuilder

source

pub fn reserve(&mut self, n: usize)