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
I ran into an issue with a polygon drawn around North America where one of the points west of Alaska overlapped past the -180 longitude boundary. The point appears to be placed correctly (i.e. where I would want it); however, it's defined in the positive space, and using it with other software (e.g. JTS results in the point being drawn with the point wrapping across the view. I'm not sure if there is a standard regarding global projection views (not sure if that's the correct terminology), but it seems like other software regards them differently. Here's a fiddle demonstrating the same JTS rendering using the OpenLayers API:
The same polygon is drawn differently in Wicket: POLYGON((172 57,-167 61,-167 52,172 57))
I haven't had time to look into how Wicket figures out where to draw the points, but it seems like it assumes the shortest longitudinal distance to the defined point within a +/-180 deg radius.
Thanks!
The text was updated successfully, but these errors were encountered:
Confirmed that the elongated triangle seen in the JS Fiddle example is reproduced in the Leaflet sandbox.
Just a quick note: Wicket doesn't "draw the points" so much as it creates a Leaflet/ Google Maps/ ArcGIS API object that represents the points and asks the corresponding framework to map it. I mean only to clarify--the solution is probably to be found in how to tell the mapping library to cross the -180 longitude boundary.
This also means solutions are going to specific to the mapping API (i.e., need a solution for the Google Maps 3 API, need a different solution for Leaflet, etc.). For instance, the Leaflet API in Wicket needs to be updated to support the new wrap functionality in Leaflet.
This issue is a little stale; closing for now but please re-open if the issue persists in 1.3.5. Again, it's not clear if this is within the scope of the Wicket library.
I ran into an issue with a polygon drawn around North America where one of the points west of Alaska overlapped past the -180 longitude boundary. The point appears to be placed correctly (i.e. where I would want it); however, it's defined in the positive space, and using it with other software (e.g. JTS results in the point being drawn with the point wrapping across the view. I'm not sure if there is a standard regarding global projection views (not sure if that's the correct terminology), but it seems like other software regards them differently. Here's a fiddle demonstrating the same JTS rendering using the OpenLayers API:
https://jsfiddle.net/borgille/bn4s8am1/1/
The same polygon is drawn differently in Wicket:
POLYGON((172 57,-167 61,-167 52,172 57))
I haven't had time to look into how Wicket figures out where to draw the points, but it seems like it assumes the shortest longitudinal distance to the defined point within a +/-180 deg radius.
Thanks!
The text was updated successfully, but these errors were encountered: