Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

In Boost v1.87 boost::geometry::intersection can fail if the two polygons share some identical vertices #998

Open
sbarkby opened this issue Jan 15, 2025 · 0 comments

Comments

@sbarkby
Copy link

sbarkby commented Jan 15, 2025

Godbolt example

Image

Two polygons are specified in the example above that almost completely overlap. However calling boost::geometry::intersection() on these two polygons in Boost v1.87 does not register as an intersection, whereas it gave the correct result before in Boost v.186 and earlier.

I have found that adding a small 1e-12 perturbation to the vertices of one of the polygons in this example results in the intersection being correctly calculated in v.187, leading me to believe that the vulnerability here occurs when both polygons in the calculation share one or more identical vertices.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant