-
Notifications
You must be signed in to change notification settings - Fork 59
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
GeoJson "right hand rule" listing longitude first (GeoFence.Point) #238
Comments
Hi Houston, I hope all is well with you. Just to make sure I understand the problem correctly.
If I am understanding this correctly, it may be best to place a method within I think this makes sense, and I am actually surprised it's never been asked as I can see how this would be convenient. Let me know if I am not understanding correctly though. |
That's a great description, and yes, that sounds pretty on-point. 👍 As a sidebar I also spotted that "outer" rings are enumerated counterclockwise and inner rings are clockwise (in terms of order of pairings) though I don't have any reference as to why that requirement exists. If there was ever an interest in building a helper that would provide a GeoJson object there's that little tidbit to consider. 🤔 |
Thanks for that tidbit. Looks like spec interprets the clockwise rings as holes so that it doesn't treat is as an overlapping boundary in a polygon collection I guess. Makes sense. The Lefthanded and Righthanded outputs should be easy. I will have to explore what going beyond that to have a GeoJson helper would entail. That would be a nice feature though. Thanks for the suggestion. |
Absolutely. I really appreciate your work. 🔧 😃 FWIW - the current application is to create these polygons to feed into the OpenWeatherMap "Trigger" API to set locale (and datetime) boundaries to evaluate for conditions and provide notifications for weather changes. In my immediate case it's for an #IoT device that senses rainfall/wind and triggers the state of an motorized awning - mainly to retract the awning via a hacked remote control. But in the bigger picture there's a handful of other state-related management tasks I'm considering. I may set the 10 foot X 20 foot awning to partially retract in order to reduce exposure and make the "final" retraction into the wall-mounted cassette take less time as local events dictate. Another application is to set triggers for parking a motor-positioned solar panel when wind exceeds a threshold. This too will be based on forecast - where the trigger is based on conditions existing before I take that protective action. And of course there's the situation of restoring the position of the panel (similarly with the awning) once the adverse conditions have cleared. It's been really rewarding to work with CoordinateSharp and the OpenWeatherMaps API in F#. 🚀 😁 |
We are getting close with the following features, we just need to build out documentation and unit tests.
Basically, the way it will work is, you will create your outer fence then inner fences as separate It will be limited to polygons for now, but will consider multipolygons once this has been tested for a bit to ensure simple polygons are behaving correctly. |
Is your feature request related to a problem? Please describe.
It would be nice to have a convenience feature to have a GeoFence.Point (or GeoFence.RightHandPoint) that would provide 'longitude, latitude' as a tuple for outer-bound GeoJson closed geometries.
Describe the solution you'd like
It was a little awkward getting a GeoJson object out of a list of GeoFence.Point s. I had to switch out to handling the individual fields, which is not a terrible inconvenience. However, it would be nice to have a means to get back a Point "right handed" for creating geo-plots
Describe alternatives you've considered
See the screenshot of my F# code. I created a "rightHandPoint" type with passed it around the functions.
Additional context
None
The text was updated successfully, but these errors were encountered: