You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The way SphericalPolygonSet (and presumably PolygonSet) implement the checkPoint(...) method can lead to points arbitrarily far away from the center-line of the boundary being considered part of the boundary. This means that points inside a region and far a way from the center-line of the boundary may be considered to be part of the boundary. Similarly points outside the region and far away from it may be considered to be part of the boundary. Here "far" means the tolerance multiplied by some large number.
The article in 1 provides a good description of the issue. Hipparchus is currently using a mitre (at left) which leads to very long points. Using a round (middle) or bevel (right) would fix the issue. I think a round join is the most intuitive meaning for tolerance.
I don't know if this is worth fixing or if this is merely a theoretical problem. Maps (one of the use cases for SphericalPolygonSet) tend to have some very strange boundaries.
I've used the code below with a tolerance of 1e-3 to produce the "Hipparchus" points in the plot below. As you can see, even though a point is several orders of magnitude further away from the center-line of the boundary it can still be considered part of the boundary.
I think this should be worth fixing, but fear it is difficult. I agree the round join is better, it is more compliant with the semantics of the tolerance.
The same problem probably also appears in 3D polyhedrons set.
SphericalPolygonSet.projectToBoundary(point).getOffset() seems to compute the offset from the center-line of the boundary and could be used to implement round corners.
The way
SphericalPolygonSet
(and presumablyPolygonSet
) implement thecheckPoint(...)
method can lead to points arbitrarily far away from the center-line of the boundary being considered part of the boundary. This means that points inside a region and far a way from the center-line of the boundary may be considered to be part of the boundary. Similarly points outside the region and far away from it may be considered to be part of the boundary. Here "far" means the tolerance multiplied by some large number.The article in 1 provides a good description of the issue. Hipparchus is currently using a mitre (at left) which leads to very long points. Using a round (middle) or bevel (right) would fix the issue. I think a round join is the most intuitive meaning for tolerance.
I don't know if this is worth fixing or if this is merely a theoretical problem. Maps (one of the use cases for SphericalPolygonSet) tend to have some very strange boundaries.
I've used the code below with a tolerance of
1e-3
to produce the "Hipparchus" points in the plot below. As you can see, even though a point is several orders of magnitude further away from the center-line of the boundary it can still be considered part of the boundary.The text was updated successfully, but these errors were encountered: