From OpenStreetMap Wiki
< JOSM‎ | Plugins
Jump to navigation Jump to search

Splinex JOSM plugin is based on the idea of Spline-drawing-tool, but allows to fully edit a spline like as in vector graphics editors before converting it to a way.


  • Click+drag on free ares to add new nodes and set control points of Bézier curve.
  • Click+drag existing nodes or control points to move them.
  • Double click on the resulting spline to finish.
  • Double click on the first point of the spline to close it.
  • Backspace one step back.
  • L is JOSM tastature shortcut.

Ctrl does the following:

  • Disables snap to existing nodes
  • Disables automatic movement of counterparts when dragging control points
  • Sets new control points when dragging a node (useful to convert sharp corners to curves)
  • Press the F12 button to open preferences window. Then scroll in this window down to the Splinex button.

You can decide how exactly spline shall be recalculated to the polygon. Default value is 10.


Green lines are tangents with control points at ends, red line is the resulting spline:


Note: Keeping ctrl button pressed you can modify the tangents. Point nr 1 in example below has different angles and lenghts left and right Point nr 2 two different lenghts left and right:

Splinex use of tangents modification with ctrl.JPG

Splines can be useful for drawing tunnels: on the satellite you can see only entrance and exit, GPS doesn't work at tunnels either. One can approximate tunnel path by aligning tangents along entrance and exit roads:


Good practice

Using Splinex the number of points needed for street curve approximation might be reduced by increased quality of way midline approximation. Splinex generates a lot of poits so it is important to reduce it in JOSM using Tools -> "Simplify way" (Shortcut: Shift + Y). The value for simplification depends on the case, for instance midline of one river might be maximum error in meters = 0,7 or 0,8m midline of one curvy way in mountains might be 0,25m.

Try to use al less control points as possible. After changing spline in polygon you might have unnecessary points in the final curve in areas close to the control points.

Example after "plain" rendering (just double click after end of painting):

Splinex result after plain rendering.JPG

The same polyline after removing of points with simplify way tool with 25 cm tolerance:

Splinex result after removing of points with 25 cm tolerance.JPG


Only three points with different length and rotation angle of arms at the anchor points

Other examples

Komplex way examples

Splinex use with 3 anchor points 11.JPG

1. Just complicated way

Splinex Example place in forest.JPG

2. Only few anchor points needed

Splinex place in forest after generalization factor 25cm.JPG

3. the same area after generalization with factor 25cm


  • Virtual nodes to add new segments in the middle of the spline
  • Angle snapping
  • Adaptive subdivision
  • Modeful drawing -- implement two different mapmodes to draw and to edit splines. Currently only modeless Potlach-like drawing is possible.
  • Ability to set control points without click+drag
  • Statusbar hints