Skip to main content

render_with_clip

Function render_with_clip 

Source
fn render_with_clip(
    level: Level,
    temp_storage: &mut StripStorage,
    strip_storage: &mut StripStorage,
    clip_path: Option<PathDataRef<'_>>,
    render_fn: impl FnOnce(&mut Vec<Strip>, &mut Vec<u8>),
)
Expand description

Render strips via render_fn with optional clip intersection.

When clip_path is Some, strips are rendered into temp_storage first, then intersected with the clip mask into strip_storage. Otherwise strips are rendered directly into strip_storage.