Also clean vertices before cutting
This commit is contained in:
parent
a817bf6642
commit
01395134ee
1 changed files with 4 additions and 1 deletions
|
|
@ -186,7 +186,10 @@ class Polygon(Shape):
|
||||||
:return: List of Polygon objects
|
:return: List of Polygon objects
|
||||||
"""
|
"""
|
||||||
import float_raster
|
import float_raster
|
||||||
xy = (self.offset + self.vertices).T
|
xy_complex = self.vertices[:, 1] + 1j * self.vertices[:, 2]
|
||||||
|
xy_cleaned = _clean_complex_vertices(xy_complex)
|
||||||
|
xy = numpy.vstack((numpy.real(xy_cleaned)[None, :],
|
||||||
|
numpy.imag(xy_cleaned)[None, :]))
|
||||||
|
|
||||||
if cut_xs is None:
|
if cut_xs is None:
|
||||||
cut_xs = tuple()
|
cut_xs = tuple()
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue