Re: Mapping geographic data

Hi Johannes,


> Now I wonder how to transform from the longitude/latitude
> coordinate system into the pixel based coordinate system used by SVG.

Note that SVG coordinate system [1] is not "pixel"-based, although it
may appear so using default values [2]. ;-)


> Any suggestions?

Naively, the only thing left to be done is find a reasonable
conversion from the longitude/latitude coordinates to the target map
user units used to draw the map.

When drawing a new map, the user units magnitude can even be
arbitrarily chosen (although it's advised that it's within reasonable
values in order be handled in hardware restricted devices such as
mobile terminals), and the viewport [3] can be later adjusted. :-)

Also, the section on "Geographic Coordinate Systems" [4] of the 1.1
specification and/or the "The 'svg:transform' attribute" [5] of the
Tiny 1.2 specification can be of use. ;-)


> regards,
> Johannes

Hope this helps,
 Helder


[1] http://www.w3.org/TR/SVG/coords.html
[2] http://www.w3.org/TR/SVG/coords.html#InitialCoordinateSystem
[3] http://www.w3.org/TR/SVG/coords.html#ViewBoxAttribute
[4] http://www.w3.org/TR/SVG/coords.html#GeographicCoordinates
[5] http://www.w3.org/TR/SVGTiny12/coords.html#SVGGlobalTransformAttribute

Received on Thursday, 25 June 2009 13:20:25 UTC