[mapserver-users] mapcache geopackage

Travis Kirstine traviskirstine at gmail.com
Thu Jun 1 08:19:50 PDT 2017


Would it be possible to use a geopackage raster table as pre-seeded cache
using a sqlite custom schema?  Something like this:


<cache name="geopackage_cache" type="sqlite3">
   <grid out-of-zoom-strategy="reassemble" max-cached-zoom="19"
restricted_extent="-12401894.016627 7433994.554222 -12279219.263349
7477845.977589">gmaps</grid>
   <dbfile>/tmp/sqlitefile.db</dbfile>
   <queries>
     <exists>select 1 from user_data_pyramid tile_column=:x and tile_row=:y
and zoom_level=:z</exists>
     <get>select tile_data from user_data_pyramid where tile_column=:x and
tile_row=:y and zoom_level=:z</get>
   </queries>
</cache>


   <grid name="gmaps">
      <metadata>
         <title>GoogleMapsCompatible</title>

 <WellKnownScaleSet>urn:ogc:def:wkss:OGC:1.0:GoogleMapsCompatible</WellKnownScaleSet>
      </metadata>
      <extent>-20037508.3427892480 -20037508.3427892480 20037508.3427892480
20037508.3427892480</extent>
      <srs>EPSG:3857</srs>
      <srsalias>EPSG:900913</srsalias>
      <units>m</units>
      <size>256 256</size>
      <resolutions>156543.0339280410 78271.51696402048 39135.75848201023
19567.87924100512 9783.939620502561 4891.969810251280 2445.984905125640
1222.992452562820 611.4962262814100 305.7481131407048 152.8740565703525
76.43702828517624 38.21851414258813 19.10925707129406 9.554628535647032
4.777314267823516 2.388657133911758 1.194328566955879 0.5971642834779395
0.29858214173896975 0.149291070869484875 0.0746455354347424375</resolutions>
   </grid>


Where the geopackage was created with GDAL

$ gdal_translate -of GPKG byte.tif byte.gpkg -co
RASTER_TABLE=user_data_pyramid -co TILING_SCHEME=GoogleMapsCompatible


Thanks
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20170601/4d9e1725/attachment.html>


More information about the mapserver-users mailing list