[ https://issues.apache.org/jira/browse/LUCENE-8280?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16457557#comment-16457557 ]
Karl Wright commented on LUCENE-8280: ------------------------------------- Hmm, [~ivera], I've concluded that the flaw is really more subtle. Effectively, it is not possible to count crossings starting on an edge and come up with a good number. It's straightforward to prove this, in retrospect -- which is probably why I created the DualCrossingIterator in the first place, because it doesn't suffer from this problem, because we can guarantee that neither the start point nor the end point is on a polygon edge. Of course, the reason that I got rid of the DualCrossingIterator was because it cannot be readily modified to allow travel on any one leg of a full 180 degrees, so it has its own problems. The good news is that we can readily detect when we've picked a bad choice for travel planes. The bad news is that there is no guarantee we can find a *good* choice. As far as a strategy going forward, here's my thought: - Basic strategy: Try a number of approaches, and hope that one eventually succeeds. - When we try an approach, we throw IllegalArgumentException if we find ourselves with a bad intersection point. - With two test points, there are two choices of intersection point immediately available. But if we restructure the code a bit, there are at least three choices available per test point, barring those excluded because they are too close to the world edge. - We can also resurrect the DualCrossingIterator, to include as part of our "strategy mix", provided it knows how to error out of someone tries to use it for too big a leg. > Repeatable failure for GeoConvexPolygons > ---------------------------------------- > > Key: LUCENE-8280 > URL: https://issues.apache.org/jira/browse/LUCENE-8280 > Project: Lucene - Core > Issue Type: Bug > Components: modules/spatial3d > Reporter: Karl Wright > Assignee: Karl Wright > Priority: Major > > Reproduce with: > {code} > ant test -Dtestcase=TestGeo3DPoint -Dtests.method=testGeo3DRelations > -Dtests.seed=1F49469C1989BC0 -Dtests.slow=true -Dtests.badapples=true > -Dtests.locale=fr-BE -Dtests.timezone=Europe/Malta -Dtests.asserts=true > -Dtests.file.encoding=Cp1252 > {code} -- This message was sent by Atlassian JIRA (v7.6.3#76005) --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org