Skip to main content

plan

Function plan 

Source
pub fn plan(
    sizes: &[(u32, u32)],
    layout: Layout,
    gap: u32,
) -> Result<Plan, String>
Expand description

Lays out pictures of these sizes (width, height), keeping the canvas within MAX_SIDE and MAX_PIXELS. Fails when there are no pictures, one has no pixels, or they can’t fit even at 1 px each.