osmlove library (OSM maps in your Love2D projects)
Posted: Sun Apr 02, 2017 7:04 pm
Hi,
I have created a library that allows you to use geoJSON file (OSM XML to be implemented soon) and draw a map based on this.
Currently, only roads/streets/sidewalks/bridges (OSM type 'highways') are supported, but implementation of others is easy and will be coming. Custom rules can be defined regarding what to draw, what colors to use and parameters passed to draw only selected region based on lat/long coordinates or zoom to be used etc.
You can use it for backgrounds or e.g. drawing a map somewhere as a part of the game - picture on a wall, map on a table etc.
I am resolving some issues with the canvas caching, once it's ready, I'll publish it to github and link it here.
Screenshot of simplified map (b&w only, basic rules defined):
I have created a library that allows you to use geoJSON file (OSM XML to be implemented soon) and draw a map based on this.
Currently, only roads/streets/sidewalks/bridges (OSM type 'highways') are supported, but implementation of others is easy and will be coming. Custom rules can be defined regarding what to draw, what colors to use and parameters passed to draw only selected region based on lat/long coordinates or zoom to be used etc.
You can use it for backgrounds or e.g. drawing a map somewhere as a part of the game - picture on a wall, map on a table etc.
I am resolving some issues with the canvas caching, once it's ready, I'll publish it to github and link it here.
Screenshot of simplified map (b&w only, basic rules defined):