I have a dataset of type citygml (*.gml). It includes information about buildings and their rooftypes.
you can find a sample file here: https://www.opengeodata.nrw.de/produkte/geobasis/3d-gm/3d-gm_lod2/
The information about the roof is given as the attribute roofType. CAD-Software is able to visualize the buildings from the *.gml-files including their roofs. I successfully opend the data with this freeware tool:
If i load the file in QGIS (3.0 Girona) i see the footprints of the files.
aim:
I want to convert this data into a raster DEM (digital elevation model). This could be for example the *.xyz-format where for each x/y coordinate there is information about the height of the building including the roof (z):
x;y;z
20;15;1
15;15;1
15;0;2
20;0;2
It has to be a raster format because the DEM will go as input data to a software that only understand raster-formats.
I have come so far: I rasterize the gml-file in QGIS using the building height from the attribute table. Then I get a DEM with cuboids with flat roofs.
here I get stuck: I don't have any idea how to do something similar including the heigths of the roof. Somehow I need to transform the roofType into information about the altering roof height over the building footprint. Also I don't know how i access information about the roof height in this data set. I'm sure it must be there. There is an attribute named consistsOfBuildingPart/BuildingPart/measuredHeight (sample value: 2:11.788,7.645) As I understand the information of the roof is saved as a BuildingPart for each Building.
alternatives?: I know how to convert the *.gml-data to *.stl or *.ifc format which are widely used for models of buildings e.g. in CAD-software. So if somebody knows how to rasterize those data-types instead of *.gml, hints would also be usefull.
prefered software: any freeware:
R, QGIS
Does anybody know how to rasterize the buildings in *.gml-format in QGIS? To me it seems like the web is full of descriptions convertig raster-dem to *.gml or different 3D-formats...