Calculate required tiles
Closed this issue · 2 comments
Hi,
I'm using your stunning library and while it was hard work to get started, it's well worth the effort!
I'd like to pre-load and cache tiles (I'm using mapbox) to try and get the maps to renderer faster.
Is there anything in your code that could give me a list of all the URLS for required tiles based on limits so I could start downloading them while the user is doing something else?
hi bknill,
basicaly the implementation for generating image url from x/y/z for each particular tile/partition is inside the Partition class ( this one is for bing https://github.com/jozefchutka/YCanvas/blob/master/ApplicationMap/src/main/actionscript/sk/yoz/ycanvas/map/demo/partition/CustomPartition.as ). You can move the algorithm anywhere so then you can modify it to produce urls by custom params. There is also an option to increase value here https://github.com/jozefchutka/YCanvas/blob/master/YCanvasLibrary/src/main/actionscript/sk/yoz/ycanvas/AbstractYCanvas.as#L46 so even the invisible tiles around your current viewport would get preloaded
Awesome thanks