How to display/cover a map area by geo locations

This forum deals with any kind of web based client technology, whether it is the well known java script based Ajax servlet or the upcoming approaches such as Leaflet, OpenLayers and so on.
Post Reply
Prakash
Posts: 22
Joined: Mon Sep 14, 2015 5:21 am

How to display/cover a map area by geo locations

Post by Prakash »

Hi,

I am using Ajax Map and need to show all given geo locations covered in an area as below:
Expected map view, it should cover area within given region/country
Expected map view, it should cover area within given region/country
For now we are using Polygons to cover area/region but can't achieve/meet my expected result. Covered area is crossing border of other countries, you could see it in below image:
Covered area are intersecting other countries
Covered area are intersecting other countries
I have few cases/issues:
1) It should work with large set of data/geo locations.
2) Any other ways to achieve above requirement.

Please let me suggest, how can I get my expected outcome.

King regards,
Prakash
Prakash Kumar
Developer
Webdirekt India Pvt. Ltd.
User avatar
Bernd Welter
Site Admin
Posts: 2564
Joined: Mon Apr 14, 2014 10:28 am
Contact:

Re: How to display/cover a map area by geo locations

Post by Bernd Welter »

Hello Prakash,

I moved your topic to the PTV Webclients forum as it deals with a specific framework and requires a dedicated response.

Furthermore I'll forward the thread to the developer of the AJAXMAPS and ask him to provide a sample. From what I read in your statement you need a sample that demonstrates the selection of objects in a map, right?

Best regards,
Bernd
Bernd Welter
Technical Partner Manager Developer Components
PTV Logistics - Germany

Bernd at... The Forum,LinkedIn, Youtube, StackOverflow
I like the smell of PTV Developer in the morning... :twisted:
User avatar
Oliver Heilig
Posts: 154
Joined: Tue May 13, 2014 12:10 pm
Location: Karlsruhe, Germany
Contact:

Re: How to display/cover a map area by geo locations

Post by Oliver Heilig »

Hi Prarakash,

think this isn't a possible with the ajax control out-of-the-box. It seems you need some GIS methods for your task, i.e. intersect your polygon (which is a convex hull?) with the polygon of the country border. This means you also need those country borders as polygons plus a geometric library (for example the geo-functions of D3 https://d3js.org/).

Another solution for your problem could be the use of voronio-regions with d3-voronoi https://github.com/d3/d3-voronoi, see http://oliverheilig.github.io/voronoi-territories/

Oli
Oliver Heilig
Chief Developer Logistic Services
PTV GROUP - Germany

https://github.com/oliverheilig/
Post Reply