-
Notifications
You must be signed in to change notification settings - Fork 56
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
delaunay.find fails when i is a coincident point. #55
Labels
bug
Something isn't working
Comments
This is a bug. |
Any progress on solving this bug? |
If there were progress on solving this bug, you would see it here. |
This seems to be working:
It makes sure that from a coincident point i we jump to somewhere else than i, at random so it doesn't get stuck in an infinite loop. |
This was referenced May 21, 2019
Closed
@jens-ox let us know if you can confirm on your test case |
Fil
added a commit
that referenced
this issue
May 24, 2019
with a possibly superfluous test on i0 to avoid infinite looping if no point is regular fixes #55
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I'm working with a set of lines that sometimes have coincident start points. I use d3-delaunay to find the nearest point to the cursor in order to highlight the line this point belongs to.
If it occurs that there is a point coincident to the first point of the first line,
inedges[0]
will be -1. Therefore,find(x, y, i = 0)
will return -1 independent ofx
andy
(because of how the_step
function is implemented) — butfind(x, y, i = 1)
will not return -1 (or maybe only fori = 2, 3,...
).Question:
i
and callingfind(x, y, i)
) or by d3-delaunay?The text was updated successfully, but these errors were encountered: