I want to create boxes by simply extruding polygons but with special "floors". I've been able to find several existing solutions for the extrusion problem. The remaining problem is that the "floor" of my boxes do not fit with the altitude modes provided by the KML reference. I want to be able to create floors with specifications like "max (100m absolute, 50m above ground)".
I don't see any simple solutions. I could do a grid sampling to get ground altitude (I'm already doing this for something else) and generate only absolute altitude. But I'm afraid that I will have problems in areas with too many mountains if the sampling is too sparse, or I will have a huge KML file if the sampling is too dense.