[GIS] Importing 3D geometries (Collada DAE) into PostGIS

3dimportpostgis

I have been trying to import some 3D geometries (from Blender, Meshlab or Sketchup ) into PostgreSQL Database (with PostGIS extension). I found this similar unanswered question – Importing 3D geometries from DXF, VRML or X3D into PostGIS? – which led me to this PostGIS & 3D blog post.

I found this method to export X3D files to postGIS but I get this error:

Error : Command not found

I have a sample file in COLLADA (COLLAborative Design Activity)'s format (.dae) extension: https://transferxl.com/08vMDqqmtsWg6N

How can I import 3D geometries, specifically Collada DAE format, into PostGIS?

Best Answer

As far as I know you can not currently do this. There are numerious mentions of collada2pgsql on a dated blog called "PostGIS & 3D" last published in 2007 that mention a tool that would facilitate this, but no one knows where the tool is currently available (if anywhere).

I was able to find this service which is powered by Cesium

This tool converts COLLADA (.dae) models or OBJ models to glTF for use with Cesium. Upload your model by using the Choose Files button to select it and any associated textures. You can also select a single zip file containing both model and textures or drag and drop them together onto the canvas below. Once uploaded, a self-contained glTF file will be downloaded and a model preview will be shown below.

The timeout limit is 2 minutes and the maximum file size is 10 MB. To run the converters locally without limits check out the following projects

But the service failed for me.

You can find the source for the backend for the service Cesium service on a project called COLLADA2GLTF which seems to be reasonably maintained. However, even if it worked I'm unsure of how to get the GL Transmission Format (gLTF) that it produces into PostGIS. The Java project importer-exporter claims to support PostGIS and gLTF.

Currently it seems like you'd have to have Collada2GLFT and then the import-exporter to get this to work.