PROJ.4 is a cartographic projections library written in C, originally written by Gerald Evenden (at that time at the USGS). It is in active use by quite a lot of applications, like QuantumGIS [http://www.qgis.org/], GRASS GIS [http://grass.itc.it/], MapServer, PostGIS, and many others. More information can be found here: http://trac.osgeo.org/proj/ **Tcl binding for proj.4** [TR] (2010-06-10) It turned out, that making a Tcl binding to proj.4 was quite simple. It just took a few days to get all things right. There is a more or less well-defined API [http://trac.osgeo.org/proj/wiki/ProjAPI], that can be used and what I am currently coming up with is a new Tcl package with the main command proj::project. It works like this: ====== package require tclproj # give an input coordinate system in proj.4 format, # an output coordinate system, # and a list of x/y coordinate pairs in a list: proj::project "+proj=latlong +ellps=clrk66" "+proj=merc +ellps=clrk66 +lat_ts=33" {-16 20.25} -1495284.21147 1920596.78992 proj::project "+proj=latlong +ellps=WGS84" "+proj=merc +ellps=WGS84 +lat_ts=33" {-16 20.25 10.33 54.55 9.23433 55.01132} -1495251.43594 1920692.42348 965371.708328 6078165.01069 862977.824527 6152753.87339 ====== As of now, there is basic error checking, and some other commands already, but the heart is the proj::project command. The extension can be built with the proj.4 library statically linked in, so there is no need of seperately installing proj.4 on your system. My test system is a Mac right now, but my build script should also work nicely on Unix. I don't about Windows yet. It would be fairly easy to also add commands that correspond to the ones used in the [tcllib] module [mapproj]. If there is an interest for this work within the Tcl community, I can try to set up a place where you can download the source and maybe some binaries ... just drop me a line. ---- Related topics: [geodesy] <>Category Geography