After experimenting on this OSM 3d building "stuff" for a while, I decided to make an app out of it and release this to the iOS appstore! You can check this out here: Appstore Link. This app allows you to take your workouts from Strava and view them in a 3D Environment. It uses OSM… Continue reading ReRun is in the appstore!
Here is what open street map data looks like when viewed through Google Cardboard. This was recorded on my iPhone 5S (ancient technology I know!). It is a block of data around Glasgow. The keen eyed of you may recognise the Glasgow City Chambers building at around 25 seconds in. You should be able to… Continue reading Google Cardboard and OpenStreetMap
Rendering Polylines In part 1 I learned how to identify polylines and came up with a simple visual representation by drawing the polylines using the OpenGL "GL_LINES" primitive. This led to a network of lines representing the centres of roads/rivers/railway lines etc. Extracting the data To allow us to render the roads with some proper "width"… Continue reading OSM Renderer – Polylines part 2
Line Based Objects As you may have read in previous posts - a lot of the objects in open street map are represented as polygons, however, many other objects are represented as polylines. A polyline is simply a collection of points which together represent straight line segments. When chained together these line segments work together to… Continue reading OSM Renderer – Polylines part 1
We have heights! To improve the realism of the building/city rendering the next step I took was to parse the building heights from the Open Street map objects. The height tag is described on the OSM Wiki here. The main points are as following: the "height" tag of the way returns the maximum height of the… Continue reading Building Heights!
Lighting Basics The next step I took to improve the rendering was to add in lighting. Until now I had just gave everything a normal of "up". This meant that every surface of the building had the same brightness as the normal represents the direction the surface is facing. Basic is lighting is done by… Continue reading Calculating normals + lighting
Now that we have the walls complete, I thought it would be a good time to move onto rendering the rooftops! Instead of having to triangulate the polygons myself, I looked online to find a triangular to do it for me. I stumbled across an old flipcode article that had a triangular in it. I simply… Continue reading Rendering Rooftops – Triangulating polygons