Extending distributed tile format |
Distributed tiles support multiple formats: FastDFS, MongoDB, MBTiles, SMTiles, SVTiles. And it support the extension tile format. This example shows a new method to extend a map tile format, namely, extend the tiles in "Geographic Information Public Service Platform-Electronic Map Data Specification".
In the services of distributed tiles, extending a custom map tile format needs extending the following aspects:
Extend TileSourceInfo. This class defines the tile storage path, tile set type, detailed tile storage type and so on. For example, the map tile type is "image".
When implementing the custom map tile, it needs to extend the AbstractImageTileset class. It should define the tile storage and organization way, including the scale, tile separation, content organization, name and so on.
Extend the AbstractTileSourceProvider class. Encapsulate above custom tile format to the tile source provider, including new and loading tile set, which can be saved as this extension format when tiling.
Extension example: Support the tiles in "Geographic Information Public Service Platform-Electronic Map Data Specification". The download link of this specification is: http://files.ngcc.sbsm.gov.cn/www/201206/20120611090020330.pdf.