I have defined two polygons and I can find whether they intersect or not. I need to find the intersection vertices if they intersect or not ?
How can I do that ?
p1 = Polygon([(0,0), (1,1), (1,0)])
p2 = Polygon([(0,1), (1,0), (1,1)])
print(p1.intersects(p2))
This gives whether the polygons intersect but how to find the intersection vertex. I tried the following but it gave an error:
print(p1.intersects(p2).coords)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
AttributeError: 'bool' object has no attribute 'coords'