xeokit / xeokit-xkt-utils

Deprecated JavaScript tools to generate .XKT files; replaced by https://github.com/xeokit/xeokit-convert
Other
10 stars 9 forks source link

Support conversion of CityGML to XKT #6

Open xeolabs opened 3 years ago

Amoki commented 3 years ago

Hi Lindsay! Do you plan to develop many converters to XKT? In my point of view, converting only geometries to a non-standard format doesn't add much value. Converting to glTF for sharing and compatibility then converting the glTF to XKT with current tools has more value. But without meta-data (properties, relationships, etc), it will be hard to build a useful tool :/

If you want XKT files from cityGML for examples or demo, we can provide you plenty! :)

xeolabs commented 3 years ago

Hi @Amoki , at this stage it's experimental. Possibly converting to intermediate glTF is the way to go.

Since CityGML/CityJSON is a very simple format to parse, I'm thinking of adding a loadCityJSONIntoXKTModel() function to xeokit-xkt-utils , to start with.

I was planning to create a xeokit-cityjson-to-xkt tool, which would output both an .XKT geometry file and a JSON metadata file.

Yes please, any XKT files from CityGML would be super useful for examples and demos, if you can share them that would be great.

xeolabs commented 3 years ago

BTW @Amoki I forget - was it a proprietary tool you used to convert CityGML to glTF?

Amoki commented 3 years ago

Yep, we convert CityGML to IFC files with our own tool, then process the IFC file like every other IFC files. This allows opening CityGML with any IFC tool and open building models in their environment.

Here is our city, Lyon, district by district. Lyon1.zip Lyon2.zip Lyon3.zip Lyon4.zip Lyon5.zip Lyon6.zip Lyon7.zip Lyon8.zip Lyon9.zip

xeolabs commented 3 years ago

Thanks!

Unless sensitive info, were there any open source CityGML -> IFC tools you'd considered (eg. https://github.com/tudelft3d/ifc2citygml)?

I'm guessing IFC4 support was the reason you guys made your own converter?

Francois-Thierry commented 3 years ago

Hello Lindsay,

I developed the CityGML -> IFC conversion tool to be able to integrate BIM with SIG models (retaining data and ADEs).

I'm guessing IFC4 support was the reason you guys made your own converter?

You guessed correct ! We convert to IFC4X3 to be able to use IfcBridge, IfcRoad etc.. In addition we wanted to have the hand on the whole process because none of the available software are correct/performant. A good review of the state of the art developments in this domain is the GeoBIM Benchmark from TUDelft (link). I will implement the IFC -> CityGML bits next month to have the complete workflow: having CityGML in BIMData (and xeokit ;), adding BIM Models into the city, and/or alter the properties then export the updated unified model back to CityGML.

It is not a trivial task to be able to handle properly all the XML/GML informations in the different configurations, what use do you plan to have with xeokit-cityjson-to-xkt ? Do you want to do something similar to ninja ?

On another topic, some CityGML files use lines (on LOD 0 mostly). Do you plan to handle them in xeokit? (cf https://github.com/xeokit/xeokit-sdk/issues/364).

I am open to discuss this subject with you if you want.

Have a nice day !

Francois-Thierry commented 3 years ago

PS: the performances in xeokit for viewing city models are already great, I just saw https://github.com/xeokit/xeokit-sdk/issues/254#issuecomment-751697148, that should improve further the rendering for CityGMLs in our xeokit viewer :+1: thanks !

xeolabs commented 3 years ago

Hi @Francois-Thierry

at this stage I'm just experimenting with CityGML/CityJSON in xeokit, so no concrete plans there yet.

I found that converting CityJSON geometry into XKT is quite straightforward, so I might create an experimental cityjson-to-xkt tool. Parsing the CityJSON is quite simple, and yeah I'm using ninja as a guide to that.

BTW, I'm finding the Lyon XKT models valuable for testing/benchmarking/tuning xeokit for large models. I can see a couple of things that I may be able to improve in loading and rendering, (eg. memory footprint and logarithmic clipping).

If you like, let's have a meeting in 2021 to discuss?

Would you be able to share the IFC models for the Lyon XKT models?

Francois-Thierry commented 3 years ago

If you like, let's have a meeting in 2021 to discuss?

Gladly !

BTW, I'm finding the Lyon XKT models valuable for testing/benchmarking/tuning xeokit for large models. I can see a couple of things that I may be able to improve in loading and rendering, (eg. memory footprint and logarithmic clipping). Would you be able to share the IFC models for the Lyon XKT models?

Yes sure, I will send them to you later this afternoon. Also what can be valuable from a discussion with you is that I can optimize the way the geometry is described in IFC and therefore in the GLTF then the XKT ouput (I already tested some possible improvements ;) But besides the impossible tradeoffs for the data structure to be fully usable there is room for improvements, and you can surely provide me with some useful tips in order to make the most of our generated IFCs inside xeokit !