0

I a question regarding the GEO Extension 'within' function. I have multiple event streams, which contain sensor information, including the location of each sensor (in geographical coordinates, and elevation).
Furthermore, I have a Polygon (example below, which contains the coordinates of each point). I would like to check if it's possible to determine whether the sensors are within the boundaries of this polygon, in the 3 dimensional space.

Example of the Polygon in JSON format:

    [
     {
       "long": 172.638741916196,
       "lat": -43.5276386362,
       "height": 18.72534752
     },
     {
       "long": 172.638741916196,
       "lat": -43.5276386362,
       "height": 19.65877151
     },
     {
       "long": 172.638753420325,
       "lat": -43.527638471272,
       "height": 18.72242355
     },
     {
       "long": 172.638753420325,
       "lat": -43.527638471272,
       "height": 18.72242355
     }
    ]

Is there a way to determine which sensors (defined in the event streams) are within the boundaries of the 3D Polygon?
I have read the documentation regarding Siddhi extension GEO (extension), and specifically the function “geo:within”, but the example is related to a 2D Polygon.

I would be very grateful if somebody could help me on this matter.

Thanks!

Community
  • 1
  • 1
fay
  • 49
  • 1
  • 7

1 Answers1

0

Mentioned geo extensions accept geoJSONGeometryFence input in GeoJson format. Please find [1] which describes the geoJson format. So you need to provide the corresponding polygon in said format. If GeoJson supports 3d structure then it should work.

[1]http://www.macwright.org/2015/03/23/geojson-second-bite.html

dnWick
  • 393
  • 3
  • 14