I’ve been trying to find a way too render OSM files in C++, have been googeling all over the place but cant seem to find any thing useful to help me.
I have tried using Mapnik, but cant find all the .h files it requires so that didn’t work.
Any one have an example app or any suggestions how to render OSM(or other map files) in C++ ??
I`ve looked at the renderers at wiki but only one who was almost sensible was the mapnik renderer, but as I mentioned in the fist post, I couldn’t use it because of many missing .h files.
To explain some more, what I’m trying to make is a simple map in my c++ app. that I can set points on click that returns the coordinates of that point.
It does not have to have a full world map only a regional, so I’m starting to wonder if the solution is to just use an image of the region instead of rendering maps out of the OSM files, the problem then is to get the coordinates right(I think, haven’t tried it yet). it would be much easer then building my own renderer would it not ?
Any one got any ideas how to match up the coords and map ?
You probably can use the OSM-Tiles as the Map (don’t forget caching!) or a pre-rendered map with you own style (from cloudmade maybe).
Then you could click on the map and if you know which are the bounds and the width/height of your map, you can calculate the coordinates from it. Shouldn’t be complicated. For the slippy map inside an Application see the download dialog in i.e. JOSM (Java) or Merkaartor (C++).
Where can i download/generate OSM Tiles, and what format do the tiles come in ??
Im currently using an image of an map but dont know how to get the coordinates for it right.