Skip to main content
Solved

IFC to CityGML, set coordinates and coordinate system (georeferencing)


Hello FME Community,

 

I am currently translating IFC to CityGML using one of the tutorial workbenches (https://knowledge.safe.com/articles/1025/bim-to-gis-intermediate-ifc-lod-300-to-lod-4-cityg.html). This is working mostly fine.

I want to import the model in 3D CityDB using the Importer/Exporter tool. It needs to be georeferenced, so I can later export it to KML and COLLADA. My question is: How can i add the correct coordinates and coordinate system (UTM32) to the resulting CityGML model)

 

Thanks in advance and best regards

Tobias

Best answer by virtualcitymatt

Hi @tobiasp,

This can be a tricky process, however it's still achievable in FME

If you have offset x, y (and z), rotation and scale information you can use these in FME to get your result. Likely you won't need to scale, however, if your model was created with a mm (or cm) scale then you will need to scale it. If you don't have this information you will have to figure it out. If it's just one model you can probably do it fairly quickly manually.

Once you have that info you can Use the 'Scaler' to Scale, 'Rotator' to Rotate and 'Offsetter' to Offset. If you're brave you can try the 3DAffiner which is essentially performing all three operations with a matrix.

 

 

You may need to play around with the origin of the model to get everything working. I've found that for rotating it's easiest if the origin of the model is a the center point (x,y) of the model. This means you can simply rotate around the z axis and not worry about custom rotation axis.

 

For scaling it's similar - Scale while your model is still at the origin, of you offset it first you may run into headaches.

 

Then you can perform your offset to the correct X and Y. Once you're happy with the location you can write it out to CityGML - just be sure to specify the correct coordinate system on the writer.

It can be quite the trial and error process so I would suggest using only a subset of the data to start with. Perhaps a floor plan if you have one. When the floor plan fits you can be fairly confident the rest of your model will be correct.

 

 

Here's some other related material with other tips which might server you better.

 

https://www.safe.com/blog/2010/05/how-to-defeat-common-barriers-to-georeferencing/

 

https://knowledge.safe.com/questions/56592/how-do-i-georeference-an-autocad-file-with-no-real.html

 

Happy FMEing!

View original
Did this help you find an answer to your question?

2 replies

virtualcitymatt
Celebrity
Forum|alt.badge.img+34

Hi @tobiasp,

This can be a tricky process, however it's still achievable in FME

If you have offset x, y (and z), rotation and scale information you can use these in FME to get your result. Likely you won't need to scale, however, if your model was created with a mm (or cm) scale then you will need to scale it. If you don't have this information you will have to figure it out. If it's just one model you can probably do it fairly quickly manually.

Once you have that info you can Use the 'Scaler' to Scale, 'Rotator' to Rotate and 'Offsetter' to Offset. If you're brave you can try the 3DAffiner which is essentially performing all three operations with a matrix.

 

 

You may need to play around with the origin of the model to get everything working. I've found that for rotating it's easiest if the origin of the model is a the center point (x,y) of the model. This means you can simply rotate around the z axis and not worry about custom rotation axis.

 

For scaling it's similar - Scale while your model is still at the origin, of you offset it first you may run into headaches.

 

Then you can perform your offset to the correct X and Y. Once you're happy with the location you can write it out to CityGML - just be sure to specify the correct coordinate system on the writer.

It can be quite the trial and error process so I would suggest using only a subset of the data to start with. Perhaps a floor plan if you have one. When the floor plan fits you can be fairly confident the rest of your model will be correct.

 

 

Here's some other related material with other tips which might server you better.

 

https://www.safe.com/blog/2010/05/how-to-defeat-common-barriers-to-georeferencing/

 

https://knowledge.safe.com/questions/56592/how-do-i-georeference-an-autocad-file-with-no-real.html

 

Happy FMEing!


  • Author
  • October 21, 2019
virtualcitymatt wrote:

Hi @tobiasp,

This can be a tricky process, however it's still achievable in FME

If you have offset x, y (and z), rotation and scale information you can use these in FME to get your result. Likely you won't need to scale, however, if your model was created with a mm (or cm) scale then you will need to scale it. If you don't have this information you will have to figure it out. If it's just one model you can probably do it fairly quickly manually.

Once you have that info you can Use the 'Scaler' to Scale, 'Rotator' to Rotate and 'Offsetter' to Offset. If you're brave you can try the 3DAffiner which is essentially performing all three operations with a matrix.

 

 

You may need to play around with the origin of the model to get everything working. I've found that for rotating it's easiest if the origin of the model is a the center point (x,y) of the model. This means you can simply rotate around the z axis and not worry about custom rotation axis.

 

For scaling it's similar - Scale while your model is still at the origin, of you offset it first you may run into headaches.

 

Then you can perform your offset to the correct X and Y. Once you're happy with the location you can write it out to CityGML - just be sure to specify the correct coordinate system on the writer.

It can be quite the trial and error process so I would suggest using only a subset of the data to start with. Perhaps a floor plan if you have one. When the floor plan fits you can be fairly confident the rest of your model will be correct.

 

 

Here's some other related material with other tips which might server you better.

 

https://www.safe.com/blog/2010/05/how-to-defeat-common-barriers-to-georeferencing/

 

https://knowledge.safe.com/questions/56592/how-do-i-georeference-an-autocad-file-with-no-real.html

 

Happy FMEing!

Sorry for the late accept. This was very helpful for my project and I could achieve my goals, thank you very much!


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings