Offline TiledMapProvider

6 posts, 0 answers
  1. Chris Johnson
    Chris Johnson avatar
    15 posts
    Member since:
    Feb 2006

    Posted 07 Oct 2011 Link to this post

    Hi Guys,

    We have a bunch of tiles from our own Map server and would like to make these available to the Map Control when there is no internet connection.

    Access to the local IIS server cannot be guaranteed, there may not even be one installed on the users machine, so following the logic in the Silverlight blog post about copying the tiles to the local server is not a solution.

    Is it possible to have a tiled map provider that reads its images from an assembly, zip file?  We would like to keep the tiles within a single source if possible, having a directory structure with thousands of tiles might work but is cumbersome to maintain and install 

    Regards

    John

  2. Andrey
    Admin
    Andrey avatar
    1681 posts

    Posted 11 Oct 2011 Link to this post

    Hello John Howe,

    Since your application is made under WPF you can read tiles right form the file system (this is not possible in Silverlight). Please find attached sample solution which demonstrates how this can be done.

    Greetings,
    Andrey Murzov
    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

  3. UI for WPF is Visual Studio 2017 Ready
  4. Chris Johnson
    Chris Johnson avatar
    15 posts
    Member since:
    Feb 2006

    Posted 11 Oct 2011 Link to this post

    Hi Andrey,

    Thanks for that.  We have already got the local file system stuff running, let me explain our objectives.

    We want to display a detailed marine map of the world’s coastlines.  That is not a problem when the user is connected to the internet and can easily be done using a WMS/WCF tiled service.

    Our problems are when the user does not have an internet connection.  The largest shape file we have been able to load and practically use (zooming and panning) is about 5 Mbytes and that took 96 seconds to load on a fast machine.  For offline usage we would look to cap the zoom level to a maximum of 7.  A shape file for that would be some 16 Mbytes, too slow to load and use.

    We have the tiles for the marine map from level 1 to level 7 produced; some 6,527 required tiles. Bear in mind that these 6,527 tiles only represent those tiles that have a coastline or island on them, the remaining 11,914  are those that have no features on them and are either pure sea or land and can be represented using just two tiles, one ocean coloured and one land coloured.  We have an indexing method that sorts out if a real or substitute tile is required.

    What we are looking for is a way to get the tiles into a single file, such as a zip file or an assembly in order not to have to install 6,000+ tiles on the user’s hard drive.

    Regards

    John
  5. Andrey
    Admin
    Andrey avatar
    1681 posts

    Posted 13 Oct 2011 Link to this post

    Hello John Howe,

    Please, find attached a sample solution which demonstrates how the tile images can be read from the resource assembly. It uses ability of the WPF version to read cached tiles from the stream. 

    Best wishes,
    Andrey Murzov
    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

  6. Vinay
    Vinay avatar
    2 posts
    Member since:
    Aug 2013

    Posted 25 Aug 2013 Link to this post

    Hello John,

    I am newbie in this.. can you help me on this. 
    i have dwld the maps from "Easy OpenstreetMap Downloader" but not able to display the data.

    please guide me. i have to display Honduras data zoom level 8 -12 

    Thanks in advance.. 
    Vinay Bansal

  7. Andrey
    Admin
    Andrey avatar
    1681 posts

    Posted 28 Aug 2013 Link to this post

    Hi Vinay,

    I have attached a sample solution which implements the open street map provider for tile images which are stored in file system. You can use it as a base. For correct work with your tiles you just should change the MainWindow constructor to specify the format of path to your images.

    Also you can restrict zoom level and region using the RadMap.MinZoomLevel, MaxZoomLevel, GeoBounds, GeoBoundsNW and GeoBoundsSE properties.
    For more information you can take a look at the following documentation topic:
    http://www.telerik.com/help/silverlight/radmap-howto-limit-panning-zooming-region.html

    Regards,
    Andrey Murzov
    Telerik
    TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WPF.
    Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
    Sign up for Free application insights >>
Back to Top
UI for WPF is Visual Studio 2017 Ready