문제

I have a Google map (API 3) with fusion table polygons (showing only 1 polygon at the time using object FusionTablesLayer).

For the view-port, i am retrieving some specific data from a "WFS" which result in multiple polygon coordinates.

i would like to determine whether each of the WFS polygons fall (partially) within the plotted fusion tables polygon. I yes, it should count the WFS polygons which are within the fusion tables polygon.

How do i approach/achieve this?

도움이 되었습니까?

해결책

I found the solution myself. The maps api v3 has the solution already.

From the fusion tables, I created a google.maps.Polygon using gviz and geoxml3. Then I looped each WFS polygon, and looped those coordinates through the method google.maps.geometry.poly.containsLocation()

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top