StrandedKitty / streets-gl

🗺 OpenStreetMap 3D renderer powered by WebGL2
http://streets.gl
MIT License
598 stars 44 forks source link

Sloped terrain destroys detailed mapping #58

Open ivanbranco opened 1 year ago

ivanbranco commented 1 year ago

As @endim8 wrote in 48:

i think this is because each building part gets its own offset from the sloped terrain, as opposed to getting one offset from the main building area and using it for all the contained building parts. But it's best to make a new issue for this :)

Examples: https://streets.gl/#51.51475,-0.09843,20.50,354.50,415.75 image image image

It also make difficult to QA (maybe a solution could be the one mentioned in #7) the 3d mapping because you don't understand if you messed up some min_heights/heights of it's the sloped terrain fault.

sekerob commented 1 year ago

There's multiple topics that seem strongly related, such as https://github.com/StrandedKitty/streets-gl/issues/35 and a comment elsewhere of 'eaten buildings' on hilly terrain. The second pic in issue 35 shows that phenomena at left. The mapped industrial area was actually levelled. Why the small substation floats is a true puzzle. But the building discussed with the missing building parts shows same, but it's on flat terrain. Elements on layer 2-3 such as the penthouse are floating as well. The heights of the parts definitely tie.

Edit: A sample of a truely eaten industrial building on a levelled area. The roof is flat though tagged as gabled_row, across

image

ivanbranco commented 1 year ago

I asked in #59 how type=building relations are used. I wonder if "gluing" all the members of a type=building relation is doable, that would fix this problem maybe.

StrandedKitty commented 1 year ago

I've added a toggle to disable terrain height. It should help with validation, but obviously most users aren't going to disable it, so they will observe broken detailed mapping.

Probably, it is possible to combine building parts into a single entity and apply elevation offset to this whole entity at once. It's straightforward for type=building relations, but for 3D buildings that don't use relations it might be tricky.

Kovoschiz commented 1 year ago

Yes, I suggested #7 as I suspect this is the cause. For the user experience, it should be noted F4Maps has terrain disabled by default, although I wonder whether that's for performance reason. type=building is not mandatory, so building= is what's supposedly used for base elevation for the whole building.

ivanbranco commented 1 year ago

I've added a toggle to disable terrain height. It should help with validation, but obviously most users aren't going to disable it, so they will observe broken detailed mapping.

Yep, I was able to find some missing min_height, now is perfect 🐱

image

Thank you!

sekerob commented 1 year ago

OK, excellent, hit Ctrl F5 to get the settings updated and disabled terrain elevation and even for flat terrain building complexes the hovering of parts has disappaered, now it looks truly as mapped.

image

Still have to figure out what's up with the roofgarden..

janusbenissa commented 1 year ago

Screenshot 2023-05-21 at 16-23-44 Streets GL

On a flat terrain it looks very good but in the hills :-( Hopefully you find a solution.

sanketgarade commented 1 year ago

I found similar problem for this fort wall on a mountain. The render makes it look as tall as the mountain in some places and non existent in some places.

Also to note that the other wall close to it, and having the same tags (barrier=wall and building=yes) renders properly.

street gl link for quick reference.

image

image

Mahabarata commented 2 months ago

There is a problem with slopes and building:parts when all tags are the same but roof:direction (rendering is ok with terrain elevation disabled)

2024-04-20_152053

https://streets.gl/#45.71968,6.07378,24.75,331.75,55.74

The ways of the 2 offset roofs : https://www.openstreetmap.org/way/1061501830 and https://www.openstreetmap.org/way/1061501829