This is a migrated thread and some comments may be shown as answers.

Offline TiledMapProvider

5 Answers 373 Views
Map
This is a migrated thread and some comments may be shown as answers.
Chris Johnson
Top achievements
Rank 1
Chris Johnson asked on 07 Oct 2011, 09:39 AM
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

5 Answers, 1 is accepted

Sort by
0
Andrey
Telerik team
answered on 11 Oct 2011, 04:05 PM
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 >>

0
Chris Johnson
Top achievements
Rank 1
answered on 11 Oct 2011, 05:21 PM
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
0
Andrey
Telerik team
answered on 13 Oct 2011, 03:56 PM
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 >>

0
Vinay
Top achievements
Rank 1
answered on 25 Aug 2013, 09:21 PM
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

0
Andrey
Telerik team
answered on 28 Aug 2013, 01:11 PM
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 >>
Tags
Map
Asked by
Chris Johnson
Top achievements
Rank 1
Answers by
Andrey
Telerik team
Chris Johnson
Top achievements
Rank 1
Vinay
Top achievements
Rank 1
Share this question
or