{"id":15641324,"url":"https://github.com/jahed/maptiles","last_synced_at":"2025-03-15T22:07:05.509Z","repository":{"id":49354902,"uuid":"51008699","full_name":"jahed/maptiles","owner":"jahed","description":"Map tile generator. Converts an image into map tiles using ImageMagick. Map tiles can be used in Google Maps, Leaflet, FrontierNav, and other map rendering software.","archived":false,"fork":false,"pushed_at":"2024-09-10T03:41:13.000Z","size":169,"stargazers_count":78,"open_issues_count":0,"forks_count":14,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-02-28T12:31:15.057Z","etag":null,"topics":["bash","frontiernav","imagemagick","leaflet","map","map-tiles","mapping","maps","openlayers"],"latest_commit_sha":null,"homepage":"https://jahed.dev","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"agpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jahed.png","metadata":{"files":{"readme":"README","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2016-02-03T15:25:12.000Z","updated_at":"2025-02-08T08:56:00.000Z","dependencies_parsed_at":"2024-10-22T22:57:10.306Z","dependency_job_id":null,"html_url":"https://github.com/jahed/maptiles","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jahed%2Fmaptiles","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jahed%2Fmaptiles/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jahed%2Fmaptiles/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jahed%2Fmaptiles/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jahed","download_url":"https://codeload.github.com/jahed/maptiles/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243796720,"owners_count":20349263,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bash","frontiernav","imagemagick","leaflet","map","map-tiles","mapping","maps","openlayers"],"created_at":"2024-10-03T11:42:12.252Z","updated_at":"2025-03-15T22:07:05.486Z","avatar_url":"https://github.com/jahed.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"NAME\n  maptiles - converts an image to map tiles\n\nSYNOPSIS\n  ./maptiles \u003cinput_image\u003e [\u003coptions\u003e] \u003coutput_directory\u003e\n\nDESCRIPTION\n  Converts an image to map tiles to be used in Google Maps, Leaflet and other\n  map rendering software.\n\n  Version:   v4.0.1\n  Homepage:  https://github.com/jahed/maptiles\n  Donate:    https://jahed.dev/donate\n\nOPTIONS\n  \u003cinput_image\u003e\n    Image to convert into tiles. Must exist. Must be square, otherwise\n    see --square option.\n\n  \u003coutput_directory\u003e\n    Output directory. Must NOT exist, to avoid polluting existing directories.\n\n  -f, --format \u003cformat\u003e\n    Tile format (e.g. 'png'). Defaults to \u003cinput_image\u003e file extension.\n\n  -b, --background \u003cbackground\u003e\n    Can be any ImageMagick-compatible colour. Defaults to 'none' (transparent).\n    See: https://imagemagick.org/script/color.php\n\n  -o, --optimise (lossy|lossless)\n    Optimises tiles depending on the \u003cformat\u003e.\n    * png uses pngquant (lossy) or optipng (lossless)\n    * jpg uses jpegtran (lossless)\n    Lossy optimisations may cause a size increase depending on each tile's\n    complexity. Only use it for maps which store a lot of detail per tile.\n\n  -s, --square\n    Converts a non-square \u003cinput_image\u003e into a square one, using whichever\n    dimension is largest and centering the image.\n\n  -j, --json \u003cbase\u003e\n    Creates a TileJSON v2.2.0 file. \u003cbase\u003e is used to create the tiles URL:\n      \u003cbase\u003e\u003coutput_directory\u003e/{z}/{x}/{y}.\u003cformat\u003e\n    Use a placeholder such as '{b}' or '' to complete the URL later.\n    See: https://github.com/mapbox/tilejson-spec/tree/master/2.2.0\n\n  -h, --help\n    Prints this help message.\n\n  --version\n    Prints the name and version.\n\nOUTPUT\n  Tiles in the \u003coutput_directory\u003e will take the format of:\n    \u003coutput_directory\u003e/{z}/{x}/{y}.\u003cformat\u003e\n\n  {z} will start at 0 and go up to the maximum zoom possible for the\n  \u003cinput_image\u003e rounding up to the next zoom level. An \u003cinput_image\u003e with\n  dimensions 2048x2048 will go up to 4 whereas an image with 3000x3000 will go\n  up to 5. This is done to make the most out of the level of detail in the image\n  without enlargening too much.\n\n  Each tile has a dimension of 256x256 and each {z} goes up in\n  dimensions of 2 to the power of {z} (i.e. 1x1, 2x2, 4x4, 8x8, etc.).\n  So overall, for each zoom level, the resulting map resolution will be 256x256,\n  512x512, 1024x1024, 2048x2048 and so on.\n\n  If you're using Leaflet, I suggest you set this maximum zoom as your\n  map.maxNativeZoom so you can have higher zoom levels without the need to\n  download larger, low quality, upscaled tiles. Alternatively, use the TileJSON.\n\nEXAMPLES\n  Take a detailed image and create optimised tiles to save space.\n    ./maptiles detailed_map.png --optimise lossy ./tiles\n\n  Take an image, square it with a red background and output it as JPG tiles.\n    ./maptiles map.png --square --format jpg --background #ff0000 ./tiles\n\nDEPENDENCIES\n  Required\n    ImageMagick  https://www.imagemagick.org\n    Bash         https://en.wikipedia.org/wiki/Bash_%28Unix_shell%29\n\n  Optional\n    pngquant    https://pngquant.org/\n    optipng     http://optipng.sourceforge.net/\n    jpegtran    https://jpegclub.org/jpegtran/\n\nCOPYRIGHT\n  Copyright (C) 2024 Jahed Ahmed\n\n  This program is free software: you can redistribute it and/or modify\n  it under the terms of the GNU Affero General Public License as published by\n  the Free Software Foundation, either version 3 of the License, or any later version.\n\n  This program is distributed in the hope that it will be useful,\n  but WITHOUT ANY WARRANTY; without even the implied warranty of\n  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n  GNU Affero General Public License for more details.\n\n  You should have received a copy of the GNU Affero General Public License\n  along with this program.  If not, see \u003chttps://www.gnu.org/licenses/\u003e.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjahed%2Fmaptiles","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjahed%2Fmaptiles","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjahed%2Fmaptiles/lists"}