<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);"><span style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);">Steve,</span></div>
<div style="color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);"><br>
</div>
<div style="color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);"><span style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);">It is what I supposed, but when I've generated the
 tiles 512x512 using the default resolution GoogleMapCompatible, with the cache template </span><span style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);">{z}/{x}/{y}.{ext} and loaded
 it in OpenLayers using ol.source.XYZ, I've noticied that the x tile being tried to load was not in the good range.</span></div>
<div style="color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);"><br>
</div>
<div style="color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);"><span style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);">z/x/-y.png</span></div>
<div style="color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);"><br>
</div>
<div style="color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);"><span style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);">Tiles generated:</span></div>
<div style="color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);"><span style="text-align: left; font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0); background-color: rgb(255, 255, 255); display: inline !important;">...</span><span style="text-align: left; font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0); background-color: rgb(255, 255, 255); display: inline !important;">/8/37
 and 38/64 and 65.png</span></div>
<div style="color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);"><span style="text-align: left; display: inline !important;"><span style="display: inline !important;"><br>
</span></span></div>
<div style="color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);"><span style="text-align: left; display: inline !important;"><span style="display: inline !important;">
<div style="color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);"><span style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);">Tiles loaded by OpenLayers (with error 404):</span></div>
<div style="color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);"><span style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0); background-color: rgb(255, 255, 255); display: inline !important;">...</span><span style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0); background-color: rgb(255, 255, 255); display: inline !important;">/8/73
 to 77/130 and 131.png</span></div>
<br>
</span></span></div>
<div style="color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);"><span style="text-align: left; display: inline !important;"><span style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0); background-color: rgb(255, 255, 255); display: inline !important;">Thanks,</span></span></div>
<div id="appendonsend"></div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>De :</b> mapserver-users <mapserver-users-bounces@lists.osgeo.org> de la part de Stephen Woodbridge <stephenwoodbridge37@gmail.com><br>
<b>Envoyé :</b> 9 mars 2020 14:56<br>
<b>À :</b> mapserver-users@lists.osgeo.org <mapserver-users@lists.osgeo.org><br>
<b>Objet :</b> Re: [mapserver-users] MapCache Larger tiles, reduce number of files</font>
<div> </div>
</div>
<div class="BodyFragment"><font size="2"><span style="font-size:11pt;">
<div class="PlainText">Jean-Philippe,<br>
<br>
I don't think it works like that. Resolution is determined by zoom <br>
factor so you generate  metatile at that resolution then you chop that <br>
metatile in tiles of whatever size you specify. So resolution is <br>
controled by zoom not tile size.<br>
<br>
-Steve W<br>
<br>
On 3/9/2020 2:45 PM, Jean-Philippe Chenel wrote:<br>
> Hi,<br>
><br>
> With MapCache, I want to generate the tiles that will be copied to a <br>
> mobile device, on a viewer created with OpenLayers.<br>
><br>
> When generating a large extent, with multiple levels of zoom, the <br>
> files count is really big, so I want to reduce the number of files by <br>
> increasing the tile size. I've made a test with tiles 512x512, but <br>
> I've realized that the resolution must be changed when changing tiles <br>
> size. So, the tiles are bigger, but changing the resolution make <br>
> generating the same number of files.<br>
><br>
> I'm open for workaround and other tricks.<br>
><br>
> mapcache.xml<br>
><br>
> <grid name="GoogleMaps512"><br>
> <metadata><br>
> <title>GoogleMaps512</title><br>
> </metadata><br>
> <extent>-20037508.3427892480 -20037508.3427892480 20037508.3427892480 <br>
> 20037508.3427892480</extent><br>
> <srs>EPSG:3857</srs><br>
> <srsalias>EPSG:900913</srsalias><br>
> <units>m</units><br>
> <size>512 512</size><br>
> <resolutions>156543.0339280410 78271.51696402048 39135.75848201023 <br>
> 19567.87924100512 9783.939620502561 4891.969810251280 <br>
> 2445.984905125640 1222.992452562820 611.4962262814100 <br>
> 305.7481131407048 152.8740565703525 76.43702828517624 <br>
> 38.21851414258813 19.10925707129406 9.554628535647032 <br>
> 4.777314267823516 2.388657133911758 1.194328566955879 <br>
> 0.5971642834779395</resolutions><br>
> </grid><br>
><br>
> <cache name="tmpl_xyz" type="disk" layout="template"><br>
> <template>/data/mapcache/tiles/{tileset}/{grid}/{z}/{x}/{y}.{ext}</template><br>
> </cache><br>
><br>
> <tileset name="OpenStreetMap"><br>
> <source>vmap0</source><br>
> <cache>tmpl_xyz</cache><br>
> <grid>GoogleMaps512</grid><br>
> <format>PNG</format><br>
> </tileset><br>
><br>
> With best regards,<br>
><br>
> _______________________________________________<br>
> mapserver-users mailing list<br>
> mapserver-users@lists.osgeo.org<br>
> <a href="https://lists.osgeo.org/mailman/listinfo/mapserver-users">https://lists.osgeo.org/mailman/listinfo/mapserver-users</a><br>
<br>
_______________________________________________<br>
mapserver-users mailing list<br>
mapserver-users@lists.osgeo.org<br>
<a href="https://lists.osgeo.org/mailman/listinfo/mapserver-users">https://lists.osgeo.org/mailman/listinfo/mapserver-users</a></div>
</span></font></div>
</body>
</html>