-
-
Notifications
You must be signed in to change notification settings - Fork 54
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
Non-building:part parts of buildings are not rendered #3
Comments
It's because of this Simple 3D Buildings rule (I found a more precise rule than the one I mentioned in #3):
|
This is a really deep problem. AFAIK, F4 Map has a unique way of handling On the other hand, other renderers such as OSMBuildings, OSM2World, OSM go don't do this. They certainly don't follow this subtraction approach. I think all three of them have no distinction between buildings and building parts and always render everything, though I might be wrong. When I initially did my research on how Simple 3D Buildings are supposed to work I haven't found that much information on F4 Maps approach of handling it. It seems like they've made it up and it doesn't follow the schema which is described on wiki. As @ivanbranco pointed out, on Simple 3D Buildings wikipage it's clearly stated that buildings intersecting building parts should not be rendered. I've implemented exactly this, and it seems to work, building outlines do get discarded correctly. Funnily enough, the same wikipage states that F4 Map has full schema support, which it clearly does not (if we consider what's described on that page the schema). But it seems like F4 Map's approach to handling outlines has had a strong impact on how people map 3D buildings, as it's the most popular renderer with such a wide Simple 3D Buildings schema support. So I wonder if the schema should be reviewed to reflect the way the most people actually map. |
As a second opinion, here’s how it is rendered in my project: https://beakerboy.github.io/OSMBuilding/index.html?id=26889368&info |
Yes I know the rule, but to be honest, most mappers and renderers handle it differently. They use building:parts to modify smaller blocks of the buildings on dedicated features, as this is the easiest way for little modifications and individualisation on buildings... Here are some of many broken buildings in Rostock: https://streets.gl/#54.07926,12.14431,51.00,343.50,391.47 P.S: Anyway a pretty astonishing visual imprettation of S3DB and micrommapped areas 🤯 Thats what I hoped that renderings would look like, when we started the united tagging schema! |
There is also the following errors with the building data:
|
I also do not like the subtraction approach. The mapper should be able to decide if the outline is rendered or not by adding building:part=yes to the outline. Unfortunately JOSM gives a warning in this case. |
Luckily I would say! As the Wiki says: "Note that building:part=* are optional areas used in addition to a building=* area." |
This building renders complete to almost complete in StreetComplete, OSM Building and F4Map. It uses the type=building relation, has an outline and building parts with layering https://www.openstreetmap.org/relation/12485899. This was mapped > 2 years ago, well prior to knowing of existence of OSM Buildings and F4Map, only having removed the height=0 tag recently on the outline that suppressed it causing rendering max height for the whole building after which it turned it into a whole 1 height blob in SC, where OSMB and F4Map were correctly discarding the outline height tag / building outline already. how it shows in StreetsGL, just the commercial ground floor. JOSM gave no warnings at all when I removed the height from the relation outline. Hope this helps |
because is the only building:part=yes, the other parts are mapped as building=yes with layers |
one problem is the members of the relation have the role “buildingpart” instead of just “part”. I suggest you look at the Burj Khalifa as a “gold standard” way to map building relations. |
Parts in this relation have roles |
@sekerob
|
Actually it's not the name, just an easy reference placeholder for recognition in ID Editor while working with relations, for building at corner Avezzano-Bologna. It shows up in the relations list of the area. Renderers ignore these as intended. |
It makes relatively little sense to discard a whole The only alternative in my mind is to move heaven and earth and dictate that This isn't your fault, of course, I just don't think the schema was thought out very well. The wiki page itself features the most contrived example of a building ever, of which maybe a dozen examples exist on the planet, while ignoring the much more ambiguous and important case of millions of buildings that are essentially rectangular with a flat or pitched roof and a box on top. Two examples: |
Originally, OSM2World actually supported subtraction of building parts from a building outline. But I quickly discovered that this only causes a different class of mapping errors to surface in the rendering. For example, when a mapper adds an entrance node and forgets to insert it into both the building:part and the building, rather than just one of them, you get a small triangle left over in the subtraction. There are also issues with indoor rendering (the subtraction approach implies a hole below the "box on the roof" which just happens to be invisible in an outdoor-only rendering) or ambiguity whether tags refer to the building as a whole or the building part. So I eventually dropped that from OSM2World, both because of the constant bugs related to it and to encourage clean mapping. And while I do still grudgingly support the "building:part tag on the building outline" hack, I'd be happy to get rid of that as well – it's inherently contradictory and an example of mapping for the renderer (probably F4, given its prominence). (By the way: Duplicating the outline can be quick with the right tools. For example, JOSM Shrinkwrap makes it a single key press. And the "follow" command often makes it quite easy in iD as well, at least for free-standing buildings.)
To the contrary, using the same element for the building and its largest part violates "one element per feature". This is apparent when you consider what the |
I will begrudgingly accept this logic but I will protest it until my dying days, and regardless the wiki needs to be made much more clear about these things. And yeah how to deal with things attached to that building outline like entrances is just one of the many issues. I don't like it, not one bit. Anyway this isn't StrandedKitty's problem they just have to deal with the fallout, so don't mind me. |
I'm thinking that it might be better to discard building outlines less agressively. Maybe only hide such building outlines that are mostly covered by building parts. Some sort of a threshold will have to be introduced -- lets say 90%, so that only outlines covered by 90%+ will not be rendered. This is a bit hacky, but I think this should fix the way a lot of buildings with parts are rendered. |
Makes sense to me @StrandedKitty. Afterall, the So if those |
Things are looking amazing now thanks! Sorry to be all ranty about standards. If you want to highlight the noncompliance, maybe outline the building in red with a popup or something to help people either adhere to the standard or make the standard usable |
I'm not sure how it could be other than the building not being rendered at all in case there are any building:parts present. The height of a building is the overall height including all (excluding antennas). How about this building: The overall building height therefore would have to be 60m (i.e. the height of the towers = overall height of building). I do not fully go with this definition, because a renderer unaware of building:parts that would render only the building, most building with bell-towers would look way too high. Therefore I decided (without a consistent reason) to set the height of the church building to the height of the main part, i.e. 30m. |
Someone in a chat room suggested that you could tag the outer building as For now the best solution I can think of for renderers is to do the best it can while calling slight attention to the nonstandard schema. |
@mnalis wrote:
I think this is exactly summing up the root of the mix-up. To my understanding, the An example of this is this building: https://www.openstreetmap.org/way/189668869#map=19/49.78869/9.93279 Where do you read the definition of building:part is a mere addition to an existing building? (It seems hard to believe this is a new discussion.) |
@kayD see building:part wiki, especially part with:
as well as simple 3D buildings wiki I linked to previously.
They should, yes. The issue is exactly what to do when then they don't define 100% of the building.
|
The main issue is legacy. There were Also, what is best height depends what is your use case. For 3D rendering, yeah, perhaps most common (median) height is most visually pleasing. But if you are doing drone collision-avoidance programming, you don't really care that it is just a bell tower part of the church that is 100m high, and majority of the building is only 20m high. Because, if you fly at 50m you will still crash. |
@mnalis good and concise summary. I think the first 3 items are completely valid, and the fourth is the one we are discussing. pro: If data "is like it is" and would not change, a heuristic to interpret erroneous data is best. It enables users to easily (sloppily) improve building geometry a bit. con: This behavior masks problems and causes people to become accustomed to viewing erroneous data as acceptable. This is bad for data quality in the future. Would it be a good idea to have two rendering modes:
or is even one of those not a use case at all? (Also: is there even a decent 3D building validator?) |
I'm completely with https://wiki.openstreetmap.org/wiki/Simple_3D_Buildings definition:
And it seems https://wiki.openstreetmap.org/wiki/Key:building:part the explaining paragraph should get edited to make it fit the "Simple 3D Building" so avoid the confusion. That way if someone edits something in 3d and checks afterwards and looks at the two sites it should be consistent. "Ah, i used
I think i will edit the wiki now. What would be nice?
To encourage a correct tagging. |
Could this be added as another check in osmose? |
When a building has building:parts only those are rendered, but the outline which doesn't have a part is not included.
Compare churches here.
https://demo.f4map.com/#lat=59.4362195&lon=24.7407079&zoom=18&camera.theta=54.454&camera.phi=6.302
https://streets.gl/#59.43631,24.74125,35.75,356.25,713.98
Even if the building's height's is set, it's still not rendered if there are any parts
https://www.openstreetmap.org/way/301781529
The text was updated successfully, but these errors were encountered: