Function union_soup

Source
pub fn union_soup(
    rings: &[Ring],
    tolerance: Tolerance,
) -> Result<Vec<Polygon>, OverlayError>
Expand description

Union a set of individually-valid rings that may overlap each other.

overlay rejects a self-intersecting operand, which is correct for a boolean between two shapes but wrong for a union of a triangle soup: a projected mesh routinely overlaps itself, and mutual overlap is exactly what a union is for. Each ring is still validated on its own, so malformed geometry is refused rather than absorbed.