[OSM-talk] I've removed segments from the map features wiki page

Matthew Newton matthew-osm at newtoncomputing.co.uk
Mon Jul 9 22:56:15 BST 2007


On Mon, Jul 09, 2007 at 03:23:37PM +0100, David Earl wrote:
> On 09/07/2007 15:00, Matthias Julius wrote:
> >> Ok, but how renderers, editors and other softwares may recombine them?
> > 
> > Unfortunately, they don't.  That is the problem that superways or
> > advanced relationships are supposed to solve.
> 
> I think Mapnik does. At least the way the names are rendered once when 
> there are multiple pieces suggests that to me. Artem? Certainly it is 
> not to hard to see how an algorithm would do that, though for osmarender 
> it is harder because it is rule based.

osmps (my PostScript renderer) does this fine. Ironically it actually
treats all ways as a a grouping of segments and pushes the way data
down on to the segments. It then scraps the ways and joins up any
segments with identical tags into paths. It is then the paths that
are drawn. Quite a simple method but works nicely.

The only gotcha is that it ruby seems to ensure non-determinism in
hashes (that's fine - they are supposed to be unordered). This means
that road names etc may appear in different places after each run for
the same input.

I need to find more time to work on osmps. It was working really well
when I last looked at it a few months ago and only needs a bit more
tweaking to make it ready for real use :-(.

-- 
Matthew




More information about the talk mailing list