Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Render embankment=yes in addition to man_made=embankment #791

Open
matthijsmelissen opened this issue Jul 28, 2014 · 34 comments
Open

Render embankment=yes in addition to man_made=embankment #791

matthijsmelissen opened this issue Jul 28, 2014 · 34 comments

Comments

@matthijsmelissen
Copy link
Collaborator

The following issue has been moved over from trac:

Mapnik renders embankments only when tagged as man_made=embankment, but Map Features page say embankment=yes should be used. man_made=embankment is not documented anywhere on wiki except natural=cliff.

I suggest to change rendering rules to render embankment=yes (and maybe remove man_made=embankment).

@matkoniecz
Copy link
Contributor

@matkoniecz
Copy link
Contributor

see also https://josm.openstreetmap.de/ticket/10313 - it would be a good idea to keep wiki, JOSM and default style synchronised

@AndiG88
Copy link

AndiG88 commented Jul 30, 2014

This is outdated

While it is now documented, embankment=yes is still used 8x more. Although supporting man_made=embankment would be easier as the man_made Key is already in the DB.

@matthijsmelissen
Copy link
Collaborator Author

the man_made Key is already in the DB.

So is the embankment key.

@AndiG88
Copy link

AndiG88 commented Jul 30, 2014

So is the embankment key.

I meant the one carto uses. Or tables. (Not a programmer^^) At least with public_transport I was always told the issue was we were using buy=yes so I guess it's the same problem here.

@matthijsmelissen
Copy link
Collaborator Author

No, for some reason the embankment key is there even though we don't currently use it.

Here you can find the list of keys we have in the database: https://github.com/gravitystorm/openstreetmap-carto/blob/master/openstreetmap-carto.style

@sb12
Copy link
Contributor

sb12 commented Jul 30, 2014

Note that embankment=yes and man_made=embankment are used differently:
embankment=yes says that a highway or railway is on an embankment and is used similar to bridge=yes and tunnel=yes
man_made=embankment is for mapping exact dimensions of an embankment and is used similar to natural=cliff

@dieterdreist
Copy link

Il giorno 30/lug/2014, alle ore 17:26, sb12 notifications@github.com ha scritto:

Note that embankment=yes and man_made=embankment are used differently:

+1, the former is an attribute, the latter a feature

@Rovastar
Copy link
Contributor

But I presume they are to be rendered the same?

@sb12
Copy link
Contributor

sb12 commented Jul 30, 2014

No, I think they need to be rendered differently:

embankment=yes and highway=tertiary
tertiary_embankment

(Both sides of the embankment are shown)

man_made=embankment:
manmade_embankment

(Only one side of the embankment is shown)

@daganzdaanda
Copy link

I agree with @sb12 about the rendering.
Would it be possible to render embankment=yes also when the feature is not rendered? Thinking of railway=abandoned or dismantled...

We should also think about cutting=yes. It could be the same just with the triangles pointing inwards.

@matkoniecz
Copy link
Contributor

Is it possible to have properly looking map and render both man_made=embankment and embankment=yes? In case that it is not possible I think that more detailed tagging (man_made=embankment) should be encouraged.

@matthijsmelissen
Copy link
Collaborator Author

It seems the only way to render embankment=yes as an attribute of roads correctly is to set up similar code as for bridges, i.e. let the separating distance of the embankment lines depend on the size of the bridges. However, that will lead to a lot of extra code for a relatively minor gain. Ideas?

@daganzdaanda
Copy link

let the separating distance of the embankment lines depend on the size of the bridges.

How about a fixed distance (widest road width)?
Narrower roads would have a bit of space, but that's really no problem, IMHO.

@matthijsmelissen matthijsmelissen added this to the New features milestone Aug 18, 2014
@Zecke64
Copy link

Zecke64 commented Aug 29, 2014

I agree it would make sense to have embankment as an attribute. Anyway it will be necessary to be able to specify whether it is on both sides or only on one side. So, embankment=yes/left/right would do the trick (yes means on both sides).

@dieterdreist
Copy link

both should be rendered, embankments are features on their own (man_made) but can also be attributes to other features like highways and railways

@Zecke64
Copy link

Zecke64 commented Aug 29, 2014

Yes and if they're attributes to other features they can have three flavours: left side, right side and both sides.

@pnorman
Copy link
Collaborator

pnorman commented Aug 29, 2014

embankment=* usage is 68k yes, 4.7k no, 362 left, 142 right.

If it's significantly harder to render one-sided embankments, we might have to only do yes initially.

My initial thought is that it should be under the road layers, but above water and landuse. Perhaps stick it adjacent to the cliff/embankment layer?

@Zecke64
Copy link

Zecke64 commented Aug 29, 2014

Is it really harder? Should'nt it be the same quality as natural=cliff or man_made=embankment, both having one-sided slopes?

@pnorman
Copy link
Collaborator

pnorman commented Aug 29, 2014

I was thinking of using a technique similar to one-way arrows with a set of dasharray, which wouldn't work for only one side easily. I'm not sure how the cliff technique of a line-pattern-file would work with an image with significant height for the transparent area, or if it could be offset.

@matkoniecz
Copy link
Contributor

Is there any way to render it sensibly with multiple objects on one embankment? For example several railway=rail with embankment=yes? man_made=embankment works fine in that situation, I see no way to render embankment=yes properly.

@a01020304uk
Copy link

any update to this as really need to show embankments on a map

@dieterdreist
Copy link

dieterdreist commented Jun 21, 2017 via email

@polarbearing
Copy link
Contributor

Could somebody change the title, removing the 'instead'? We apparently need both, feature and attribute.

@imagico
Copy link
Collaborator

imagico commented Jun 21, 2017

@a01020304uk - this requires someone to develop a good solution for this - which is not trivial to implement in a way that works reasonably well is all the different cases like junctions, curves etc.

@imagico imagico changed the title Render embankment=yes instead of man_made=embankment Render embankment=yes in addition to man_made=embankment Jun 21, 2017
@matkoniecz
Copy link
Contributor

matkoniecz commented Nov 2, 2017

I am considering closing it, as I consider unfeasible to reliably avoid without very complicated code, duplicate rendering caused by

  • rendering embankment=yes on linear feature and man_made=embankment tagged separately
  • rendering multiple embankment=yes from linear features on a single embankment (for example railway tracks)

@pnorman
Copy link
Collaborator

pnorman commented Feb 25, 2018

Closed for reasons listed above and no one showing a way to do it without very complicated code.

@pnorman pnorman closed this as completed Feb 25, 2018
@SomeoneElseOSM
Copy link
Contributor

SomeoneElseOSM commented Feb 25, 2018

If anyone still fancies having a go, here's how I did it in a different OSM Carto-based style:

  1. Split the features we're interested into "standalone" embankments and "others" in lua.

  2. Render "standalone" ones as regular features (2-sided cliffs, actually) and the others as modifiers to the main feature (highway, railway, etc.) in the same way that "bridge" is.

The result looks like this. I'm not convinced that the "visual weight" of the modifier is correct for all features yet, but you can get the idea.

@imagico
Copy link
Collaborator

imagico commented Feb 25, 2018

Indeed a bridge like depiction of embankments on roads and railways seems feasible. What i had been contemplating is if there is a way to distinguish between cutting and embankment in an intuitive way using that approach.

@jeisenbe
Copy link
Collaborator

jeisenbe commented Nov 7, 2019

This issue was closed due to problems with:

  1. rendering embankment=yes on linear feature and man_made=embankment tagged separately
  2. rendering multiple embankment=yes from linear features on a single embankment (for example railway tracks)
  1. Could be considered not the best mapping practice: should both features be tagged at the same time?

But if this happens and we are going to support one way of tagging, adding embankment=yes to the highway/railroad/waterway allows correct rendering at all zoom levels and is easier for mappers than micro-mapping the lines of the embankments separately.

Right now this style is encouraging mappers to not add cutting=yes or embankment=yes to linear features, since this is not rendered, which suggests that this way of mapping is not correct, when in fact it's a good way of representing these features.

  1. can be solved by rendering embankments in a similar style to bridges, I believe.

I'd be interested in reopening this. There are 2 examples of how the rendering could be done (with simple or more complex code) at http://blog.imagico.de/rendering-implicit-embankments/

@imagico
Copy link
Collaborator

imagico commented Apr 23, 2020

Reopening because there have been several ideas demonstrated (in AJT-style and ac-style) how this can be done. There does not appear to be consensus not to render embankment/cutting=yes and given the popularity among mappers rendering man_made=embankment but not embankment/cutting=yes appears to be a serious issue w.r.t. the goals of this style (providing constructive mapper feedback).

@jeisenbe
Copy link
Collaborator

Re: AJT-style, is that referring to https://github.com/SomeoneElseOSM/openstreetmap-carto-AJT perhaps?

@imagico
Copy link
Collaborator

imagico commented Apr 26, 2020

Yes.

@ppete2
Copy link

ppete2 commented Jun 8, 2023

I think it would be a good idea to render embankment/cutting=yes cause both tags are well documented https://wiki.openstreetmap.org/wiki/Key:embankment and also often used.
I also like the rendering examples demonstrated in http://blog.imagico.de/rendering-implicit-embankments/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests