This project has moved and is read-only. For the latest updates, please go here.

rendering style of overpass linestrings

Topics: SharpMap v0.9 / v1.x
Oct 6, 2011 at 9:52 AM

How to render custom style for overpass streets ( don't join outline because over pass at there)?. Plelase view Ex :


Oct 6, 2011 at 11:10 AM
Edited Oct 6, 2011 at 11:11 AM

Hello TrieuVy,

you can't achive that with pen styles.

I'd do the following:

  1. Add a ZOrder column to the linestring table, default it to 0.
    • -1 ... underground
    • 0 ... ground
    • > 0 above ground level
  2. Create a view on the postgis database, that queries all possible intersectionpoints between linestrings that have
    a ZOrder value >= 0 and return the intersection point, (possibly) the id of linestring with higher ZOrder value and the orientation at the intersection point.
  3. Create a layer based on that view to render bridge symbols with the given orientation.

Btw, your map looks nice!

Hth FObermaier

Oct 10, 2011 at 3:34 AM

Thanks FObermaier!

I will try


Oct 10, 2011 at 6:05 AM

Hi FObermaier,

I created new layer for above ground level ( bridges ). The result :

Endcap and start cap not ok ( OSM and google map style can join end cap and start cap of line OK.

How can we create a good style in this case? I can sort  rendering  geometries by "ZOrder" column in the same layer. But joining outlines seem have some problem by sharpmap's core.



Oct 10, 2011 at 7:05 AM

The problem is that you have a seperate layer for the bridges. If you leave them all on one layer but


you should be all set.

Nice solution, though!