[OSM-talk] Osmarender, additions

David Svantesson david at oxtract.se
Thu Feb 5 23:50:48 GMT 2009


Hello,

I have for my own needs made some additions to Osmarender. I post my file
and the changes here if it would be to any use within OSM or for someone
else who wants to render a map.

My additions:
 - If a node have a direction:[0-360] key/value pair, the symbol rendered
will be rotated the same number of degrees (where 0 is north). Could for
examble be used if someone wants to render the opening of a cavern or show
the direction of a overlook.
- If an area is rendered with a pattern, and the way have a
direction:[0-360] key/value pair, the pattern will be rotated this amount.
The pattern must be specified with the fill attribute
(fill="url(#pattern-url)" ), not in the style part. I don't have a good
example right now of where this could be useful.
- Added a new instruction <lineMarker startOffset=".." distance=".."
class="...">, which is similar to <wayMarker> but the markers will be placed
with a fixed distance apart instead of at each node. Parameter startOffset
will offset the first marker and distance specify the distance between
markers. While this could be used e.g for displaying arrows to show driving
direction, the great benefit is that this allows for non-symmetric way
features, e.g. avenues (trees) on one side of the road. Unfortunately still
not usable for linear asymmetrics as sidewalk on one side of a street, I
might consider if this is possible to do in some way.

Feel free to use it if you find it useful, here is the xsl file with my
changes:
http://como.oxtract.se/osmarender_new090205.xsl

//David Svantesson
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/talk/attachments/20090206/c1d35fb0/attachment.html>


More information about the talk mailing list