Question

How to implement XLink:href for referencing geometries (spaces and space boundaries) in CityGML 3.0?

  • 13 December 2022
  • 1 reply
  • 37 views

I want to implement referencing geometries of spaces and space boundaries using XLink:href. I found this solution (https://hub.safe.com/publishers/con-terra/templates/citygml-create-building-lod-2-using-xlinks). 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 (considering the "boundary" relation in CityGML 3.0), none of them worked! I will appreciate any help and suggestion 🙂


1 reply

Badge +6

FME's CityGML2 R/W has special configuration and functionality built into it to handle xlinked geometry. There is also some basic support for certain types of xlinked geometry in the GML core reader / writer. However, any behavior specific to CityGML such as the use of special citygml format attributes citygml_feature_role or citygml_lod_name will not be automatically handled or mapped by the generic GML writer. Rather, the behaviour of the GML R/W is directly driven by the application schemas you give it. As it is, our support for CityGML3 using the generic GML reader/writer is only partial. There are special features of CityGML such as appearances that go beyond the GML standard specification that are not supported.

 

That said, we do support reading and writing xlink:hrefs properties in general. So there is nothing to say that you cannot read them and write them to the appropriate features. But in that case you would have to do the relationship and geometry management yourself. This may mean you need to create the appropriate xlinks and write them to xlink:hrefs, and then have a reference feature with the correct referenced gml_ids that you write the actual geometry to. In some cases, if the geometry is too complex, or contains unsupported elements such as appearances, you may need to compose the geometry xml/gml fragment yourself and write the gml blob to the relevant xml_geometry field (which can accept FME geometries with the same name as the attribute, or XML fragments in a field with the same name).

 

If all this sounds too complex, I would strongly suggest just waiting till our new CityGML3 reader / writer is available in an upcoming 2023 beta. We have been working on this already for some time and should have something available for testing in the coming months. If you would like to be notified when this is available, or you need help configuring the GML reader / writer for a specific use case, please contact Support at: https://community.safe.com/s/submit-case

Reply