Rendering a map
-
I'm looking for the best way to render a map in WPF. The map is 29952x11520 pixels, hence it is too large to simply store into memory. It is divided into blocks of 32x32 pixels, and these blocks are compressed, but can be decompressed to draw the blocks when necessary. The map should be scrollable. What is the best way to allow the map to scroll quickly, without taking up over a gigabyte of memory?
-
I'm looking for the best way to render a map in WPF. The map is 29952x11520 pixels, hence it is too large to simply store into memory. It is divided into blocks of 32x32 pixels, and these blocks are compressed, but can be decompressed to draw the blocks when necessary. The map should be scrollable. What is the best way to allow the map to scroll quickly, without taking up over a gigabyte of memory?
Silverlight has the MultiScaleImage aka DeepZoom which would do all the hard work for you, this is not available in WPF and I'm not sure if/when it will be added. If you want to do it in WPF you'll have to do it yourself, maybe the projects below could help although they use different technologies. Depending on whether you need to support zooming you may need to have different sets of tiles depending on the zoom level, even though the image would be cut into many pieces to zoom out all the way you would still need every tile. You might want to research image formats that support progressive loading, It would seem using Silverlight would be your best bet. http://iipimage.sourceforge.net/ http://www.codeplex.com/silverzoom/Release/ProjectReleases.aspx?ReleaseId=8783
-
I'm looking for the best way to render a map in WPF. The map is 29952x11520 pixels, hence it is too large to simply store into memory. It is divided into blocks of 32x32 pixels, and these blocks are compressed, but can be decompressed to draw the blocks when necessary. The map should be scrollable. What is the best way to allow the map to scroll quickly, without taking up over a gigabyte of memory?
The normal way of doing this is to load the tiles around the area you are viewing and, when you scroll, load in the tiles you need in that particular direction.
Deja View - the feeling that you've seen this post before.