Having some fun with old maps

While relaxing after the hard-working period that was the GSoC, I came across a comment left by Torsten Rahn of the marble team. He wondered whether it would be possible to adapt image warping functionality so that it can be used to morph some old maps.

Apparently, they would like to add historical maps to Marble. Unfortunately, these maps are most of the time not "plate carrée projections" of the globe, which is a requirement for Marble. Hence they use xmorph to convert those maps "by hand" into plate carrée projections.

Of course, it would be too long and too hard for me to do something like xmorph. Though, after taking a look at some of these old maps and searching on wikipedia, I became pretty sure these were some kind of stereographic projections (actually two stereographic projections : each one representing a half of the globe).
So, I did the maths and wrote a simple command-line program to convert automatically stereographic projections to plate carrée projections.

I was quite convinced the result would be bad, but actually it turned out quite well :). My program takes a .ppm square image of a semi stereographic projection (rightly centered, etc..) and converts it to a .ppm square image of a semi plate carree projection (the plate carree projection of the corresponding half of the globe).

I tried it with a map that had already been converted by the marble team, in order to see if I obtained the right result.
Here is the original map :

And the expected result :

Here is what I gave to my program (the stereographic projection of one half of the globe, cut from the original map, and scale a bit to make it a perfect circle) :

And here is what I obtained (the operation took about 2 seconds) :

Torsten Rahn told me the result looks very similar to what they obtain with xmorph :). They also had distortions appearing on the edges, which needed to be fixed by hand.

For fun, I wanted to try it with a map that hadn't been converted yet :

Here is what I obtained quickly (just the time to cut the two halves of the globe, give them to my program, and merge them properly) :

For those who are interested, here are the sources. It's written in pure C99, and under LGPL.

Now, back to Krita. I was a bit lazy the past few weeks, since I merely fixed 2 or 3 bugs related the transform worker. And now that I am back to school, I will have even less time to work on Krita. Anyway, even if it is at a lower pace, I will still find time to contribute, and maybe even blog ;).


Hi, thanks a lot for this nice contribution,

Now this is a topic where people can help Marble without coding skills:

We'd like to have such historic maps provided in Marble via GHNS!

Problem is we need some people who help the Marble project to accomplish this:

* Search for maps (you'll find lots of them on Wikipedia ( or Library of Congress (
* Check their "license" (We need something that is public domain or BSD style licensed. We don't want imagery where some people claim copyright due to image processing or scanning which is often the case with museums)
* Either use the tool mentioned above or follow the instructions at: for other projections.
* If you have a graphics designer at hand then you might want to retouch the map so that e.g. the region around the poles looks better. But we will also accept maps which are not retouched
* Create a matching DGML file for Marble ( A proper DGML file should also have a nice legend and explanations what the map is about. See the Schagen1689 map as an example.
* Optional: Create a webpage which has more information about the map and puts it into historical context.
* Inform us about it: send us an email: [email protected]

If you need help you can also reach us via IRC #marble on freenode.

By Torsten Rahn at Sat, 09/11/2010 - 09:04

I'd also like to add that similar kinds of maps also exist for Mars and the sky (ancient maps of constellations). Of course we'd love to add those, too. So if you have some time at hand this would really be a great contribution. In the Marble project we are very very busy with coding, marketing and administration already. So every kind of help and contribution from new people getting involved would be very much appreciated!

By Torsten Rahn at Sat, 09/11/2010 - 09:12