[josm-dev] Paint two direction path for a way
julien houllier
j.houllier at gmail.com
Fri Feb 19 15:03:54 GMT 2010
Hi,
It's my first post, and i hope it was the good place to ask help.
I actually developt a plugin for traffic flow, and i have to represents on
JOSM, states of roads in two-way. I use an private vectorial database,
which describe juste a way for roads.
The solution, i started to investigate, was to create subways from road's
way, then add an tag on them, and with custom elements styles colored the
subway (grey,green,orange,red acoording to the flow traffic). i use a
extends of OsmDataLayer which convert my private data in osm data.
it works good, but my problem is i want to could color an part of the road
in two differents colors according to which direction it goes.
I make an algorythm who take a path of Java Point, and create two paralleles
path, but i doesn't be effective in JOSM because, JOSM draw himself the node
and way according to their coordinates dynamicly, and my algorithm doesn't
work on coordinates.
Should i override paint method for my custom Layer, and use an custom
PaintVisitor.
JOSM shouldn't offer the possibily to customize the PaintVisitor impl, other
than SimplePaintVisitor and MapPaintVisitor
Is there a way to calcule two directions way corrdinates ?
Julien
--
Julien Houllier
42 rue Martin Feuillée
35000 Rennes
More information about the josm-dev
mailing list