<div dir="ltr">You might also consider incorporating the mbtiles implementation of a fork of gdal2tiles that can be found here:<div><br></div><div><a href="https://github.com/mj10777/gdal2mbtiles">https://github.com/mj10777/gdal2mbtiles</a><br></div><div><br></div><div>Here the goal was to also offer mbtiles as the output-format</div><div>- instead of a tiles-directory</div><div><br></div><div>It also offered options to use mbtiles as a source</div><div>- to create a tiles-directory</div><div><br></div><div>or</div><div><br></div><div>a tiles-directory to create a mbtiles file.</div><div><br></div><div>---</div><div>The created mbtiles file is based on the mbtiles-implementation of of the Geopaparazzi (Android) project</div><div>- that also reads/creates mbtiles</div><div><br></div><div><a href="https://github.com/geopaparazzi/geopaparazzi/wiki/mbtiles-Implementation">https://github.com/geopaparazzi/geopaparazzi/wiki/mbtiles-Implementation</a><br></div><div><br></div><div>A major goal of this implementation was to avoid the creation of  duplicate images inside the mbtiles file</div><div>- which, depending on the input files, could save a lot of space</div><div><br></div><div>The project itself was created so that the Geopaparazzi users could 'port' their tiles-directories to mbtiles</div><div>- since the space needed on sdcard's for tiles-directories is very high and slow</div><div><br></div><div>It was always the intention to incorporate this into gdal2tiles, but not being a Python expert/fan, I was always hoping that someone could take this over and maintain it.</div><div><br></div><div>Mark Johnson, Berlin Germany</div></div>