1

I am new to mapping and displaying data on maps. I was trying to display markers on a map where each marker represents a point of interest on my map. Using leaflet it is quite straight forward to add such markers.

My concern is what happens if I have many (lets say 400,000) such points spread (or actually clustered) around the world.

I was thinking that it would be nice if I could get the data from my server based on tiles, i.e. if I could provide an API from my server that will return per tile (JSON) data and this data would be available for my to render on the map (or on the tile) using some form of "tileDataAdded" and "tileDataRemoved".

On the server side if the zoom level is too low I can just return the number of relevant points in the time (possibly with some average latlang) to allow some form of clustering display and if there is reasonable amount of data then it can be returned at its raw form.

Is there something like this that is already built or does my thinking that I should create some DataLayer class that implements ILayer makes some sense?

2
  • Welcome to GIS SE! However, our Q&A format works best with one question per question, as per the Tour, so as it stands I think it is too broad and needs to be revised to focus on your most important question.
    – PolyGeo
    Commented Jul 29, 2014 at 10:38
  • Hi @PolyGeo, feel free to focus on Q2 if you can help. Q1 and Q3 are just there to say that being new to this area I am just welcoming any level of answer. admitting that it is possible that I am totally off with my ideas.
    – epeleg
    Commented Aug 3, 2014 at 9:01

1 Answer 1

1

Because of points have mouse events, over 40,000 point of POI display will be very slow. For solve that type of problem, you have to use use utf-grid implemented by Mapbox(It also used in CartoDB).

This is the example.(link)

If you implement tile with a lot of point, you have generate tile image layer for each levels.

And you also need to dealing the mouse event for interaction.

http://ebrelsford.github.io/maps/leaflet/2014/03/06/too-many-points.html

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.