perform boolean operations on arbitrary polygons in 2d