[josm-dev] JOSM extension for orthogonalizing ways
Harald Kucharek
harald.kucharek at gmx.net
Fri Oct 31 10:30:08 GMT 2008
-------- Original-Nachricht --------
> Datum: Fri, 31 Oct 2008 08:28:52 +0100
> Von: Frederik Ramm <frederik at remote.org>
> An: harald.kucharek at gmx.net
> CC: josm-dev at openstreetmap.org
> Betreff: Re: [josm-dev] JOSM extension for orthogonalizing ways
> Hi,
>
> Harald Kucharek wrote:
> > Now, my question is: Is there interest by the maintainers of JOSM to put
> > my function into JOSM, maybe replacing the current "aligning nodes in a
> > rectangle" function of JOSM?
>
> Sure, sounds great. I assume if used on a 5-node way it will roughly do
> the same as the current align-in-rectangle, right?
Yes. We have different approaches, so results differ slightly. What gives the better result depends on what you want to align and how you expect the outcome. While I use the weighted average of directions as the orientation of the grid, you look for the edge closest to the average and take its orientation. And you use a different approach to orient the other segments.
>
> I did the align-in-recangle initially, and I have been asked by users
> whether it would be possible to, instead of have the algorithm compute
> the general direction, pre-select one edge somehow for all others to
> follow. I haven't had the time to look into that though, maybe it is
> something you want to tackle on your next holiday ;-)
In holiday I map. Programming is for the rainy season ;-)
As - if I understand correctly - it is not possible in JOSM to select just a segemt of a way, I only have two sponaneous ideas:
-the collection must also contain two nodes that would establish the direction
-the collection must also contain one way constisting of only two nodes, which would establish the direction
This would also allow to draw a larger "helpline" just for orientation and then align the other objects to it. Then the helpline can be deleted.
>
> I'll look at the patch and apply it if I don't see a major problem.
>
> Bye
> Frederik
>
> --
> Frederik Ramm ## eMail frederik at remote.org ## N49°00'09" E008°23'33"
Almost neighbours. I live Südstadt, near Werderplatz.
--
Harald Kucharek | harald.kucharek at gmx.net
Werderstrasse 24 | FON:+49(721)389566
76137 Karlsruhe | FAX/VoiceMail:+49(12120) 211259
Germany | Mobile:+49(174)2458743
More information about the josm-dev
mailing list