When to use building:part on split buildings

So I modded a building=yes to a lower base 4 floor commercial/retail section and mapped the top smaller outline section as building=apartments at layer=1 above with another N levels. Done. The 3D product mapped in it’s simplest form, no building encompassing outline added which has all the maxima tagged on i.e. a 3rd 'total 'element.

Another mapper comes in and changes building=apartments at layer=1 into building:part=apartments. Nothing changes.

Rereading the building:part wiki just can’t make sense of the whole thing as in what applies when. particularly the last sentence AFTER the introduction of the type=building relation

How to use

Main article: Simple 3D buildings

Use building:part=yes for parts of the building which only have different attributes (building:levels=* and height=*). Use building:part=(type of building) for parts of the building which have a different function and possibly attributes (e.g. building:part=roof, building:part=retail or building:part=barn).

In addition to the different ways tagged building:part=, there should be one area (closed way or multipolygon) marking the outline of the whole building, tagged with building=. For complex buildings it is also recommended to use a type=building relation to group together the outline way and the building:part=* ways.

Where a building has been split into parts, the whole building way should still have the tags building:levels= and height=*. These values should be the maximum of all the building parts. A building that has a three-story part and a six-story part is still a six-story building*

The question is: Does the italic/bolded apply when there’s a building relation only or also when done the KISS approach? If yes, then tagging the full levels/heights on the commercial block which has the building=commercial tag would just override the apartments topside. If not, it needs some clarifying as to what that last sentence applies and whether the apartment section should at all be building:part. Do 2D renderers need that all max 3rd part which in effect would be the same outer way as the commercial base which then consequently would require the commercial base be also made building:part. Right now it does not add up for me.

Edit: Do 3D renderers throw away the building=* when there’s building:part within the same area. If so I expect there only to appear the apartments outline (not tested).


PS tagging building=* + building:part=* on same way in past had QA go wild.

1 Like

They should do this, or at least handle cases where part of building is lower than correctly tagged maximum.

It always applies. Whether there’s a relation or not doesn’t make a difference in that regard.

No, it would not be the same way. It would be a second way that has the same shape, but different tags (different height/levels, and building vs. building:part).

A correctly implemented 3D renderer will throw away the building geometry on a correctly mapped 3D building that has building:part polygons inside.¹

Many 3D renderers will attempt various workarounds for common mapping errors, which will confuse you if you attempt to use such a renderer to “debug” your mapping. But you should not rely on these non-standard and renderer-specific behaviors.

Just construct the 3D geometry solely from building:part elements. And as a separate object, create a building that has all the tags which apply to the building as a whole so that applications which are not 3D renderers can ignore everything besides the building polygon.


¹ The 3D renderer should still use the building geometry to figure out which building:parts belong to the same building if there’s no relation, and may also take information such as building:colour from the building if it is absent from the building:part.


Interestingly just checked F4 and they throw away the building=* section that is below the apartment outline but retain the commercial layer which is not… floating apartments.

I’ll check a few more 3D players how they handle this halfway house state as it is now.

Edit: meantime change the base building too from building > building:part and added a 3rd element tagged as building with all the max measures. Of course JOSM does not understand and complains about 2 overlapping ways. Duly ignored. However small the element count, would still prefer creating a type=building relation for all the new and old to prevent easy deletion of the frame element.

The updated tags and the add of an overall outline has worked it’s way through a few renderer’s cycles. The result is that the building is now whole. Issue resolved.