arnis icon indicating copy to clipboard operation
arnis copied to clipboard

[FEATURE] Displaying elevations for buildings with "Building Part" tags

Open mykhailo-25 opened this issue 1 year ago • 2 comments

Hello everyone, I apologize if this topic has already been discussed here. I really like Arnis, I already use Arnis to rebuild buildings created on its basis. But the height of buildings, when it is not indicated for the entire building by a single number, is quite poorly perceived now, especially starting from version 2.1.3.

In OSM, there are tags like "Building Part=yes" and "building=yes". When a building has a uniform height, it is represented as a single polygon with the “building” tag.

However, if the building has varying heights, a single “building” polygon is used to represent the entire structure, specifying the number of floors in the building and sometimes the height of the highest point. Over this “building” polygon, parts of the structure are drawn with the “Building Part” tag, where individual heights are specified for each part. This allows for a detailed and accurate 3D representation instead of just a simple cube.

Currently, Arnis supports constructing both types of polygons, but it builds them simultaneously. As a result, the output is often a cube with the actual building hidden inside. This problem did not exist before version 2.1.3.

It would be nice to improve the display of different heights. And also to add support for min_height and min_level for creating arches and transitions between buildings.

For example: in F4map, if a "Building Part" completely covers the "building" polygon, it ignores the height tag of the "building." (Sometimes, "Building Part" is created only for part of the building, while the other part is represented with just the "building" tag).

Here are some examples: Image

Side view ↑ Top view ↓

Image

This is how this building looks on the F4 map and in the OSM editor: Image

(BBox: 50.002112 36.223812 50.009118 36.238661) On the map, we see several sections of the "Derzhprom building" (white) and the “Projects Building” (yellow) with varying heights, arches, and inner courtyards. Starting with version 2.1.3, the courtyards of buildings marked in OSM with a single polygon began to be displayed only partially.

(BBox: 49.991953 36.234208 49.992836 36.235721) Using external tools, it is possible to remove the outer layer created by the “building” polygon to reveal the structure with different heights inside: Image

Image

(Bbox: 1: 50.004443 36.229284 50.007408 36.236408 , 2: 48.850767 2.275071 48.854028 2.281466):

Image

mykhailo-25 avatar Jan 25 '25 21:01 mykhailo-25

@benjamin051000 Hi, this might be a good thing to take a look at, in fact it is the one thing keeping me from using a generated map. The buildings look all weird when generated. I can't go back to 2.1.1 as many other things have been fixed.

GMart avatar Feb 21 '25 03:02 GMart

Thanks for all the examples! I am still learning the codebase, and honestly haven't even read the building generation logic yet. Right now as I learn, I am prioritizing cleaning up portions of the codebase, not fixing bugs. Once I feel I understand the code well, I will start looking into bugs like this one. Thanks for your patience, and I'm happy to review PRs if someone else fixes this before I get to it.

benjamin051000 avatar Feb 21 '25 20:02 benjamin051000