Use local OSM tile server

May 5, 2010 at 11:05 PM


I've implemented my own OSM tile server as we don't expect to have internet access when we want to use our application.

How can i point the control at the local OSM tile server rather than the internet one?



May 6, 2010 at 6:20 AM
Edited May 6, 2010 at 6:21 AM
  • Create new map type in GMap.NET.Core\GMap.NET\MapType.cs
  • Handle url generation in GMap.NET.Core\GMap.NET\GMaps.cs at MakeImageUrl by creating new case with your new map type(http://{0}{1}/{2}/{3}.png)
  • Engage! ;}

p.s. while testing i recommend to set temporally MainMap.Manager.Mode = AccessMode.ServerOnly, to keep your local cache clean if you made mistake somewhere