@ifc-lite/export 2.4.0 → 2.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +12 -8
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# @ifc-lite/export
|
|
2
2
|
|
|
3
|
-
Export formats for IFClite. Writes Apache Parquet
|
|
3
|
+
Export formats for IFClite. Writes Apache Parquet (Arrow-based internally), IFC STEP (with mutations applied), IFC5 IFCX (JSON + USD geometry), and lightweight LOD0/LOD1 envelopes — all from a single parsed `IfcDataStore`.
|
|
4
4
|
|
|
5
5
|
> **glTF/GLB, CSV and JSON-LD moved to Rust.** They are now assembled by the `ifc-lite-export` crate and reached through `GeometryProcessor` in [`@ifc-lite/geometry`](../geometry); the standalone `GLTFExporter`/`CSVExporter`/`JSONLDExporter` classes were retired.
|
|
6
6
|
|
|
@@ -33,7 +33,7 @@ const url = URL.createObjectURL(new Blob([new Uint8Array(glb)], { type: 'model/g
|
|
|
33
33
|
import { exportToStep } from '@ifc-lite/export';
|
|
34
34
|
|
|
35
35
|
const stepText = exportToStep(store, {
|
|
36
|
-
schema: 'IFC4', // 'IFC2X3' | 'IFC4' | 'IFC4X3'
|
|
36
|
+
schema: 'IFC4', // 'IFC2X3' | 'IFC4' | 'IFC4X3' | 'IFC5'
|
|
37
37
|
applyMutations: true, // include edits from MutablePropertyView
|
|
38
38
|
visibleOnly: false, // export only entities visible in the renderer
|
|
39
39
|
});
|
|
@@ -49,12 +49,16 @@ const blob = new Blob([stepText], { type: 'application/x-step' });
|
|
|
49
49
|
```typescript
|
|
50
50
|
import { ParquetExporter } from '@ifc-lite/export';
|
|
51
51
|
|
|
52
|
-
const exporter = new ParquetExporter();
|
|
53
|
-
const entities = await exporter.exportEntities(parseResult);
|
|
54
|
-
const properties = await exporter.exportProperties(parseResult);
|
|
55
|
-
const quantities = await exporter.exportQuantities(parseResult);
|
|
52
|
+
const exporter = new ParquetExporter(store);
|
|
56
53
|
|
|
57
|
-
//
|
|
54
|
+
// One .bos archive (ZIP of Parquet tables: entities, properties, quantities, …)
|
|
55
|
+
const bos = await exporter.exportBOS();
|
|
56
|
+
|
|
57
|
+
// …or a single table on its own
|
|
58
|
+
// tableName ∈ entities|properties|quantities|relationships|strings|vertices|indices|meshes
|
|
59
|
+
const entities = await exporter.exportTable('entities');
|
|
60
|
+
|
|
61
|
+
// Each Parquet table is ~15–50× smaller than equivalent JSON
|
|
58
62
|
// Loadable directly from DuckDB, Polars, pandas, BigQuery, …
|
|
59
63
|
```
|
|
60
64
|
|
|
@@ -92,7 +96,7 @@ const lod0 = await generateLod0(bytes);
|
|
|
92
96
|
|
|
93
97
|
// LOD1 — meshes simplified to bounding boxes / convex hulls, returned as GLB
|
|
94
98
|
const lod1 = await generateLod1(bytes, { quality: 'medium' });
|
|
95
|
-
// { glb: Uint8Array, meta: { failedElements,
|
|
99
|
+
// { glb: Uint8Array, meta: { failedElements, mapping, ... } }
|
|
96
100
|
|
|
97
101
|
// Falls back gracefully to box geometry if a complex element fails to mesh
|
|
98
102
|
```
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ifc-lite/export",
|
|
3
|
-
"version": "2.4.
|
|
3
|
+
"version": "2.4.1",
|
|
4
4
|
"description": "Export formats for IFC-Lite",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -16,11 +16,11 @@
|
|
|
16
16
|
"parquet-wasm": "^0.7.1",
|
|
17
17
|
"apache-arrow": "^21.1.0",
|
|
18
18
|
"jszip": "^3.10.0",
|
|
19
|
-
"@ifc-lite/geometry": "^3.0.
|
|
19
|
+
"@ifc-lite/geometry": "^3.0.3",
|
|
20
20
|
"@ifc-lite/data": "^2.3.0",
|
|
21
21
|
"@ifc-lite/encoding": "^1.14.8",
|
|
22
22
|
"@ifc-lite/parser": "^3.5.2",
|
|
23
|
-
"@ifc-lite/mutations": "^1.17.
|
|
23
|
+
"@ifc-lite/mutations": "^1.17.1"
|
|
24
24
|
},
|
|
25
25
|
"devDependencies": {
|
|
26
26
|
"typescript": "^6.0.3",
|