-
Notifications
You must be signed in to change notification settings - Fork 57
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
"ForEachVoronoiCell" and "ForEachVoronoiEdge" yield inconsistent drawing results. #23
Comments
Hey, thanks for pointing this out! To help check out the issue, could you share a minimal example, mainly the list of points you're using? That would make it easier to reproduce the problem with ForEachVoronoiCell and ForEachVoronoiEdge and see what’s going on. Thanks! |
Thank you for your reply, I am using this library in Unity.
|
Unfortunately, I couldn't find a solution to this problem. I suspect it might be related to LINK I've committed an update to the WPF example, where I recreated a minimal case. The issue occurs for DrawVoronoi > ForEachVoronoiCell > cell.Index == 3. If anyone can find a solution, contributions are welcome. |
These crossing Voronoi edges are happening because the default behaviour is to draw the voronoi diagram using the triangle centroids (not the circumcenters) as the voronoi diagram's nodes. The true voronoi diagram uses circumcenters (which is in the library but it is not the default behaviour). I was about to post a v similar issue and saw this one. Changing lines 556 & 573 to: |
Ah, you just gave me flashbacks to the past! I totally forgot this was discussed in previous issue |
Hello, I used the ForEachVoronoiCell method to draw all the edges of the cells, and the result is inconsistent with using ForEachVoronoiEdge. There are overlapping parts in ForEachVoronoiCell. I found that there is also this situation in the example of the documentation.
The text was updated successfully, but these errors were encountered: