[OSM-talk] Mapping canals

Gervase Markham gerv-gmane at gerv.net
Tue Jan 22 22:35:36 GMT 2008


Dave Stubbs wrote:
> But some of them will be incorrect. And how do I now make a renderer 
> that gives the speed limit in the unit it's actually specified?

We seem to have a choice between:

1) Making renderers which need to understand the units they want to 
render on the map, and are capable of converting values in a single 
standard unit into that rendered unit and rounding appropriately:
48.28 -> 29.999mph -> "30mph"

2) Making renderers which need to understand all possible units anyone 
might use, and how to convert them into the units they want to render on 
the map (which may or may not be the units encoded).
50kph -> 31.07mph -> "30mph"
45mph -> 45mph -> "45mph"
73000furlongsperfortnight -> 27.16kph -> "28kph"

I opt for 1). I think it's reasonable to ask renderers to know about 
units they want to render. I don't think it's reasonable to ask them all 
to know about all possible units anyone might want to stick in the database.

Gerv





More information about the talk mailing list