<div dir="ltr"><span style="font-family:arial,sans-serif;font-size:13px">I've talked about this idea with some of you at last SOTM and SOTM-EU.</span><div><font face="arial, sans-serif"><br></font></div><div><font face="arial, sans-serif">The idea is to have render_list taking advantage of disk cache by rendering tiles in a more "pyramidal" way than the actual full horizontal.</font></div>

<div><div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px">1) better use of disk cache to reduce disk I/O needs</div><div style="font-family:arial,sans-serif;font-size:13px">

<br></div><div style="font-family:arial,sans-serif;font-size:13px">Up to now, render_list renders a tile at zoom N but when getting to zoom N+1, most of the needed data are usually the same but not in the disk cache anymore causing a lot of I/O when rendering several zoom level.</div>

<div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px">With my changes, render_list immediately enqueue the 4 underlying N+1 tiles (at the top of the queue). This allows to reduce disk I/O by taking advantage of the caches still containing most of the needed data.</div>

<div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px">That's fine but where should be stop recursion ?</div><div style="font-family:arial,sans-serif;font-size:13px">

<br></div><div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px">2- pre-render only what's worth prerendering...<br clear="all"><div><br></div><div>

For this I've added a rendering time limit.</div><div><br></div><div>If a metatile takes less than this limit, it is not worth pre-rendering it as it will be quickly generated if requested.</div><div>This allows to limit recursion and at the same time pre-render what can be done fast enough upon request.<br>

</div><div><br></div><div><br></div><div>To use this new feature, I'v only added on option to render_list to control the rendering time limit (in ms). With it, its behavior is unchanged.</div><div><br></div><div><br>
</div>
<div>Example:</div><div>render_list -m osm -a -f -z 9 -Z 9 --max-time 5000</div><div><br></div><div><br></div><div>On my todo list:</div><div>- when rendering several zoom levels (example: -z 9 -Z 12), check if a metatile has not been already recursively rendered by comparing its timestamp to the render_list start time</div>

<div><br></div><div>- add a maximum zoom limit (for the moment recursion can go down to zoom 18)</div><div><br></div><div>My commit is on github, comments are welcome... before my first mod_tile pull request</div><div><div>

<br></div><div><a href="https://github.com/cquest/mod_tile/commit/652ec90c7d1293a4b049ee0b58be53c01a602e75" target="_blank">https://github.com/cquest/mod_tile/commit/652ec90c7d1293a4b049ee0b58be53c01a602e75</a></div></div>

<div class=""><div id=":5bx" class="" tabindex="0"><img class="" src="https://ssl.gstatic.com/ui/v1/icons/mail/images/cleardot.gif"></div></div></div><div><br></div>-- <br><div dir="ltr">Christian Quest - OpenStreetMap France</div>


</div></div>