Convert several models at once
Batch converts every model file in a folder without opening them one by one: FBX, OBJ, 3DS, glTF, GLB and CMIF files. It looks in that folder only, not in the folders inside it, and writes CityJSON and CityGML.
To convert a folder of models:
- Choose ConvertOutput settings…, then click Batch at the bottom of the list.
- Under Input, click Browse and choose the folder that holds the models. Files found lists the files that will be converted.
- Under Folder, click Browse and choose where the results go.
- Under Output mode, click Separate for one set of files per model, or Merged for one set made from all of them.
- Under Version, choose the CityGML version: 2.0, 3.0 or Both.
- Click Convert. The box on the right ticks off the models one by one, and Stop ends the run.
OBJ and 3DS files store no unit and no up axis. When the folder holds any, Convert first asks for the Unit and the Up axis, once for the OBJ files and once for the 3DS files.
| Field | What it does |
|---|---|
| Merged name | With Merged, the name of the merged files. Left empty, it is the name of the input folder. |
| Spreadsheet, Mapping | One spreadsheet and its mapping, used for every model. Make the mapping once in the mapping window, see Map the spreadsheet columns. Leave both empty to convert the geometry only. |
| Layer rule | Takes the layer from each object name, like the Layer name rule asked for when you open a file, see Open a model file. Files that carry no layers need it, or they fail with Layer - None · name rule. |
| CRS | The EPSG code of the model coordinates, for every model. |
| Intermediate CMIF | Insula3D turns each model file into a CMIF file first and keeps it with the results. Select Delete when done to remove it after the run. |
With Separate, each model gets a folder of its own in the output folder, named after the file, with its CityJSON, its CityGML and the reports. A model that fails does not stop the others: the box counts Done and Failed and gives the reason for each failure.
With Merged, all the models become one set of files in the output folder. A name used in more than one file, for an object or a layer, gets the file name in front, such as Tower A:A-101. With a spreadsheet, these objects still find their rows under their original names.
Models in different coordinate systems or around different origins would land in the wrong places once merged, so the merge stops instead, and so does a file that cannot be read. The box shows Merge stopped and says why. Click Force merge to merge anyway: the models as they are, without the files that could not be read.
Note:Batch uses the settings of the Layers panel: a layer in any of the models gets the settings of the layer with the same name there. Layers the panel does not list, such as those of models that are not open, get the defaults: Surfaces, LOD 2 and the Building class. To change them, open one of the models and set its layers before you run the batch.
To look at a result, choose FileOpen… and pick its CityJSON or CityGML file. The CityGML files end in _v2.gml and _v3.gml.
Parent topic: Converting