Skip to main content

Hello everyone,

my current project is to generate a citygml model from CAD data, point cloud and DTM. The building model has LoD0 and LoD1 ready, I'm working on LoD2 now. I followed some tutorials and the OGC documentation in CityGML, however, the representation of the buildings is not coming out correctly. Here are some steps that I followed and can be seen in the wokspace print:

 

- I separated the solids on surfaces (deaggregator), storing the gml_id of the original solid (parent_id);

 

- identified the surfaces that were shared by two buildings;

 

- removed the geometry of the original solids (geometryRemover);

 

- In solids, I created the list with the IDs of the surfaces that composes the solids "citygml_bounded_By. {} Xlink_href" (matcher);

 

- For solids, I set LoD name = LoD2Solid and Feature Role = cityObjectMember;

 

- I separated the surfaces in Roof, Walls and Ground by normal (PlanarityFilter);

 

- And for surfaces, I set LoD name = LoD2multiSurface and Feature Role = BoundedBy;

 

 

Comparing the output file in the text editor with the example of LoD2 OGC building (PDF pg 293), I noticed some differences:

 

- In the example, xlinks_href are part of a composite surface as a surface member (<gml: CompositeSurface>

 

<gml: surfaceMember xlink: href = "# gml_4e7123df-b10c-416e-b580-5847d376474c" />) and in the output as boundedBy (bldg: boundedBy xlink: href = "# gml_4e7123df-b10c-416e-b580-5847d376474c" )

 

- And in the example, the ID indicated in the link belongs to a polygon, not a surface.

 

 

I manually edited a building from my output in the text editor to make it look like the model. The preview of this building appears correctly.

 

 

Attached is the extract of that building in gml of my original output (output.gml) and the edits I made manually in that same building are in the correct.gml.Could someone point me the changes I should make to the workspace so the output comes out according to the example of OGC.

 

 

My thanks in advance for the attention and time.

 

If someone is facing the same problem, @virtualcitymatt shared the workspace below that was very helpfull to me.

https://hub.safe.com/publishers/con-terra/templates/citygml-create-building-lod-2-using-xlinks

 

Hope it helps!

If someone is facing the same problem, @virtualcitymatt shared the workspace below that was very helpfull to me.

https://hub.safe.com/publishers/con-terra/templates/citygml-create-building-lod-2-using-xlinks

 

Hope it helps!

This solution works very well for CityGML 2, but I couldn't implement it for CityGML 3.0 using the GML writer. I changed the transformers and tried different approaches, none of them worked! I will appreciate any help and suggestion :)


Reply