On 1/7/07, <b class="gmail_sendername">Johann Gail</b> <<a href="mailto:johann.gail@gmx.de">johann.gail@gmx.de</a>> wrote:<div><span class="gmail_quote"></span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hi to the osmarender team.<br><br>I've just detected the tag osmarender:nameDirection='-1'.<br>Is this tag really neccessary?<br>I think, the orientation of the naming should be done by the rendering<br>tool automatically, in this case osmarender.
<br>osmarender should compare the lat coordinates of the beginnign of a way<br>with the end of a way and then ensure the reading direction from left to<br>right.<br>If the beginning of a way/segment lays more left then the end, all is okay.
<br>If the beginning lays more right than the end, then the direction is<br>wrong and should be reversed, as it is done by the keyword now.<br>How do you think about this?</blockquote><div><br><br>This is not always the case.  For example, with very winding roads.
<br><br> </div><br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">I've done some programming work an tested it.<br>If you enter the lines
<br>                <xsl:when test='tag[@k="name_direction"]/@v="-1"<br>                    or tag[@k="osmarender:nameDirection"]/@v="-1"<br>                    or<br>(key("nodeById",key("segmentById",seg[1]/@id)/@from)/@lon &gt;
<br>key("nodeById",key("segmentById",seg[last()]/@id)/@to)/@lon)'><br>in generateWayPath<br>respective<br>                <xsl:when test='tag[@k="name_direction"]/@v="-1"
<br>                    or tag[@k="osmarender:nameDirection"]/@v="-1"<br>                    or (key("nodeById",@from)/@lon &gt;<br>key("nodeById",@to)/@lon)'><br>in generateSegmentPath,
<br><br>then the Direction is always from left to right.<br><br><br>--<br>_______________________________________________________________________<br>Dipl. Ing. (FH) ... Johann Gail (Fröhlicher Hans)<br>Fern-Schall ....... 08254/534
<br>Fax ............... 01212/525142758<br>Elektro-Post ...... <a href="mailto:johann.gail@gmx.de">johann.gail@gmx.de</a><br>Der Weg zu mir .... <a href="http://mail.map24.com/johann.gail">http://mail.map24.com/johann.gail
</a><br><br><br><br>_______________________________________________<br>dev mailing list<br><a href="mailto:dev@openstreetmap.org">dev@openstreetmap.org</a><br><a href="http://lists.openstreetmap.org/cgi-bin/mailman/listinfo/dev">
http://lists.openstreetmap.org/cgi-bin/mailman/listinfo/dev</a><br></blockquote></div><br>