2

I am building a map application with the silverlight bing maps control.

In the map control I want to show all of the subscribed customers. The amount of customers is somewhere between 5000 and 7000, this means I can't show them all at once. This would result in a crash I guess.

How would you solve this issue? I've read about events on zoomlevels etc. about tile layers about spatial sql but I have no idea what the right solution is in this situation and where to begin.

This seems like a pretty basic problem when working with maps but there is little to no information on how to handle lots of data when working with bing maps.

Can anyone explain or point me to a good tutorial?

BBQ
  • 618
  • 1
  • 7
  • 20

1 Answers1

2

You can use a space-filling-curve or a spatial-index to get those points nested with the zoom-level of your map application to achieve a cluster effect http://blog.notdot.net/2009/11/Damn-Cool-Algorithms-Spatial-indexing-with-Quadtrees-and-Hilbert-Curves. There are many implementation of sfc and hilbert-curves. I've uploaded my own at phpclasses.org (hilbert-curve, bsd licence) and with a quadkey function for a cluster function. I've succesful implemented it for some customers. The idea is to search for a quadkey from left to right to get only a portion of pois. www.maptiler.org uses a quadkey with a z-curve. Probably you are getting better answers at gis.stackexchange. A sfc has usually a constraint of power of 2.

Micromega
  • 12,486
  • 7
  • 35
  • 72
  • This seems like a complex, yet interesting topic. Since I have no experience with developing map applications reading beginning spatial with sql seems like a good start to fully understand these algorithms and how to implement them. Thanks for the information. – BBQ Aug 05 '11 at 08:29
  • @BBQ: Here is how you do it with MySQL http://stackoverflow.com/questions/6919661/select-within-20-kilometers-based-on-latitude-longitude/6919743#6919743. My solution is for hard-core coder or professionals. – Micromega Aug 05 '11 at 09:53