polygons_union

Function polygons_union 

Source
pub fn polygons_union<P: FullXY>(
    vector_polygons: &[Vec<Vec<P>>],
) -> Option<(Vec<Vec<Vec<P>>>, BBox)>
Expand description

Given a collection of polygons, if any of the polygons interact/overlap eachother, merge them.

§Parameters

  • polygons: the collection of polygons to apply a union to. The points in the polygons are expected to implement the trait FullXY which extends [GetXY] and [NewXY]

§Returns

A union of polygons should a union exist.