I was testing the new layer of buildings added to Cesium Ion, and I was wondering how the buildings can be adapted when we change the terrain (Add or remove cesiumTerrainProvider).
Cesium OSM Buildings are clamped to Cesium World Terrain, so using it on other terrain is going to present issues as mentioned here https://github.com/CesiumGS/cesium-ion-community/issues/321 and moving the entire tileset won’t be correct because the individual buildings need to be clamped to the new terrain.
But if we take the land away, the buildings are floating.
It’s easy to reproduce it. We load OSM buildings with the ion ground and then remove the ground, the buildings float.
Can you adapt the height like the before samples?
You are correct that you currently must use Cesium OSM Buildings with Cesium World Terrain to get the correct results. It doesn’t yet support switching to other terrain providers.
It is possible to move the entire 3D Tileset (here’s an example Sandcastle) but this is not a correct solution because each individual building needs to be moved depending on the new underlying terrain.
I know this topic is quite old, and I’m sure that over the past 4 years, you have found a solution. Is it now possible to clamp OSM buildings onto a custom terrain?