About six months ago I posted a video showing a GPS track with 7,000 points in a slippy map control called DeepEarth. If you watch the video you can see that the track lags behind the map a little and I think I was at the limit of what was usable.

Yesterday I wrote about my new C# based slippy map control for Silverlight and Moonlight that can display 50,000 map markers and I wanted to see what it’s performance was like for a GPS track. I created a random track with 50,000 points in it to simulate a track from a GPS unit. Here is the result.

Both videos were made on the same cheap Core 2 Duo laptop while running off the battery. As you can see there is no lag while panning and only a small delay when zooming in and out.

For anyone interested here is how I generated the test track.

Random Rand = new Random();
Line Track = new Line();
LonLat Point = new LonLat((Rand.NextDouble() * 0.1) - 1.0, (Rand.NextDouble() * 0.1) + 53.0);
for (int i = 0; i < 50000; i++)
{
    Point = new LonLat(Point.Longitude + ((Rand.NextDouble() - 0.5) * 0.001),
        Point.Latitude + ((Rand.NextDouble() - 0.5) * 0.001));
    Track.Points.Add(Point);
}
LineLayer TrackLayer = new LineLayer("Tracks", Colors.Orange, 3.0, 0.75);
TrackLayer.Lines.Add(Track);
SlippyMap.AddLayer(TrackLayer);