gpxsolar — free tool to generate sun/shadow overlays from a GPX track (MBTiles)

Started by nico579, Today at 20:01:42

0 Members and 1 Guest are viewing this topic.

nico579

    Hi all,

    freischneider kindly pointed me here from the ideas site — this is the right board for it.

    I made gpxsolar, a free open-source tool (GPLv3) that computes where sun and shadow fall along a GPX track at a given date and time, using elevation data and the terrain horizon. It exports a map overlay you can load directly in Locus Map.

    Why it's useful on the trail: on a summer hike you want to know which sections will be in shade at 2 p.m.; in winter, where the sun still reaches; for photography, where the light hits. The overlay shows it at a glance.



    Same track, three times of day — the cast shadow moves across the terrain.

    How to use it in Locus Map:
    [list=1]
    • Load the generated MBTiles as a map overlay (Settings → Maps → overlay).
    • Import the colored track KML as a regular track (the overlay is a raster, so the track comes separately).
    • Keep the overlay opacity at 100%. The semi-transparency is already baked into the tiles — if you lower Locus's layer opacity, Locus re-composites the tiles and faint seams appear between them. At 100% it's seamless.

    Outputs: KMZ (Google Earth), MBTiles (Locus / OsmAnd overlay), colored track KML. Input is a GPX + a date/time. Runs on Windows / Linux / macOS, GUI or CLI.

    Repo (code, build, docs): https://github.com/nico579/gpxsolar

    It's a hobby project — feedback very welcome, especially from people who load custom overlays in Locus.
    •