finds.dev

commenthol/gdal2tiles-leaflet

Generate raster image tiles for use with leaflet.

View on GitHubHomepage ↗

★ 504PythonMITupdated Oct 2021

// the take

A patched version of GDAL's gdal2tiles.py that flips the tile origin to the upper-left corner so raster images (non-geographic maps, game maps, floor plans) work correctly in Leaflet. The companion plugin leaflet-rastercoords handles the coordinate math on the browser side. Aimed at anyone needing to make a zoomable, pan-able viewer for a large image that isn't a real map.

The core patch is small and targeted — just origin flipping and raster profile support, no bloat. Multicore tile generation is included via a second script, which matters when you're tiling a 20,000px image. The test directory gives a working end-to-end example with real image and shell script, not just a stub. The README accurately explains the minimum zoom level constraint with a concrete calculation example.

Abandoned since 2021 and based on a GDAL version from 2013 — the upstream gdal2tiles.py has changed substantially and modern GDAL (3.x) ships its own Python 3 version, so this fork diverges from a moving target. No pip package, no versioned releases, just a raw script you copy into your project. The setup.py exists but installing it puts an old frozen script on your PATH, which is worse than not installing it. No tests for the actual tile output correctness — just a manual shell script.

We read the README, the directory tree and a key source file in June 2026. Nobody pays to be listed. How we judge →

// at a glance

Stars
504
Forks
128
Language
Python
License
MIT
Last commit
30 Oct 2021

// nearby

If gdal2tiles-leaflet isn't quite it.

All repos →