First I want to congratulate Arno the author of scenProc for his powerfull tool. And thanks him to have extended it with AFS features knowing it was initialy a tool focused on FSX/P3D.
I am particularly attached to the building generation because it is for me a crucial point to be able to generate realistic scenes.
And in th generation of buildings an essential point is to be able to have the heights of buildings closest to reality.
That is why some time ago I put a lot of effort in the information of the heights of buildings in OSM. At the time, I developed scritps allowing the automatic import of these data into OSM. My scripts were based on DEM + DSM sources available in open data and by doing the subtraction I managed to determine a maximum height for each building already imported into OSM (thanks to the cadastre). There were some difficulties to manage like trees or antennae that had to be ignored to not have false values. But in the end it worked pretty well and I managed to inform the heights for all the buildings of the cities of Nice and Montpellier in France. I had also done a script that had allowed me to fill the height on almost half of the Parisian buildings, in this case it was the number of floors and not the height that I filled.
The good news is that sceneProc is able to handle the height attribute in addition to the building: levels attribute by using a scale ratio of 0.3 (assuming that a floor is about 3 meters high).
On the other hand, it implies having to split all the building rules in sceneProc. There is already a doubling of rules to manage the existence or not of the attribute building: levels, but we must add another one to also manage the existence or not of the attribute height.
If we consider the following rule:
CreateAF2Building | building = "apartments" And FAREARAT> 0.7 And FAREA> = 700 | building_levels | 1 | gable | residential | 0
It becomes:
CreateAF2Building | building = "apartments" And FAREARAT> 0.7 And building_levels = "*" And FAREA> = 700 | building_levels | 1 | gable | residential | 0
CreateAF2Building | building = "apartments" And FAREARAT> 0.7 And NOT building_levels = "*" And height = "*" And FAREA> = 700 | height | 0.3 | gable | residential | 0
CreateAF2Building | building = "apartments" And FAREARAT> 0.7 And NOT building_levels = "*" And NOT height = "*" And FAREA> = 700 | 3; 6 | 1 | gable | residential | 0
But at the end it makes a lot of rules and it's not very readable. Would not there be a better way?
Also if sceneProc could have a mode that would prevent it from working twice on the same OSM entity it would also simplify the rules (no need to add the conditions "And Not XXX").
Another question if Arno read that thread: no plan to support "generic" buildings ? By generic I mean buildings which can adapt to any footprint and any height. Of course this is not a trivial point and it will be difficult to have buildings as pretty as those that are "pre-calculated" but at least we would have all buildings that exist in AFS even when their shape / footprint is not standard (ie. rectangular). So we could have in our AFS sceneries ALL the buildings that exist in the real world (well, in OSM) and with the correct shape and correct height! But currently a lot of them are ignored because they have a non rectangular footprint (I guess that most of us use the FAREARAT>0.7 condition).
Otherwise I noticed a strange behavior: the swimming pools in OSM generate buildings ! The pools have nothing to do with the buildings (there is just leisure = swimming_pool, no building tag) so it really looks like a bug.
Otherwise I noticed a strange behavior: the swimming pools in OSM generate buildings ! The pools have nothing to do with the buildings (there is just leisure = swimming_pool, no building tag) so it really looks like a bug.
I can see the same issue with playgrounds (leisure=pitch) but only for certain sports such as tennis or beach volley (not for other such as football, athletics..)