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
Hi, I found a case where I have two geometries, created with a PrecisionModel with scale 10000, and the intersecting geometry result have some coordinates with more decimals than it should have (4).
I have problems with those coordinates later in my code when using the equals() between the ones with the not rounded x value and the rounded ones, as they are not equal anymore.
For example here ((Polygon) intersection).getExteriorRing().getPointN(128) and reader.read("POINT (19035.0404 5362.0221)") they are both POINT (19035.0404 5362.0221), but they are not equal to each other.
I think this is a very uncommon case because I use the intersection operation extensively and this is the first time I have found this issue. Also it seems like it only affects the x value of the coordinate and not the y.
The text was updated successfully, but these errors were encountered:
Hi, I found a case where I have two geometries, created with a
PrecisionModel
with scale 10000, and the intersecting geometry result have some coordinates with more decimals than it should have (4).I replicated it in a unit test:
This test fails because the intersection geometry has these coordinates with the x value not being rounded to 4 decimal places:
I have problems with those coordinates later in my code when using the
equals()
between the ones with the not rounded x value and the rounded ones, as they are not equal anymore.For example here
((Polygon) intersection).getExteriorRing().getPointN(128)
andreader.read("POINT (19035.0404 5362.0221)")
they are bothPOINT (19035.0404 5362.0221)
, but they are not equal to each other.I think this is a very uncommon case because I use the intersection operation extensively and this is the first time I have found this issue. Also it seems like it only affects the x value of the coordinate and not the y.
The text was updated successfully, but these errors were encountered: