@ifc-lite/viewer 1.25.2 → 1.26.0
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/.turbo/turbo-build.log +30 -27
- package/CHANGELOG.md +81 -0
- package/dist/assets/{basketViewActivator-CTgyKI3U.js → basketViewActivator-ZpTYWE3K.js} +6 -6
- package/dist/assets/{bcf-7jQby1qi.js → bcf-Ctcu_Sc2.js} +5 -5
- package/dist/assets/{deflate-Cfp9t1Df.js → deflate-Cnx0il6E.js} +1 -1
- package/dist/assets/{exporters-DfSvJPi4.js → exporters-DSq76AVM.js} +272 -245
- package/dist/assets/geometry.worker-0Q9qEa6p.js +1 -0
- package/dist/assets/{geotiff-xZoE8BkO.js → geotiff-A5UjhI6L.js} +10 -10
- package/dist/assets/{ids-Cu73hD0Y.js → ids-DiLcGTer.js} +21 -21
- package/dist/assets/{ifc-lite_bg-ksLBP5cA.wasm → ifc-lite_bg-CEZnhM2e.wasm} +0 -0
- package/dist/assets/index-B9Ug2EqU.css +1 -0
- package/dist/assets/{index-WSbA5iy6.js → index-BAH8IJVR.js} +35946 -33456
- package/dist/assets/{jpeg-DhwFEbqb.js → jpeg-BzSkwo5D.js} +1 -1
- package/dist/assets/{lerc-Dz6BXOVb.js → lerc-Cg2Rz-D5.js} +1 -1
- package/dist/assets/{lzw-C9z0fG2o.js → lzw-BBPPLW-0.js} +1 -1
- package/dist/assets/{native-bridge-RvDmzO-2.js → native-bridge-CPojOeGE.js} +1 -1
- package/dist/assets/{packbits-jfwifz7C.js → packbits-yLSpjW-V.js} +1 -1
- package/dist/assets/{parser.worker-C594dWxH.js → parser.worker-8md211IW.js} +2 -2
- package/dist/assets/raw-BQrAgxwT.js +1 -0
- package/dist/assets/{sandbox-DDSZ7rek.js → sandbox-CsRXlgCO.js} +4102 -2658
- package/dist/assets/{server-client-Ctk8_Bof.js → server-client-Bk4c1CPO.js} +1 -1
- package/dist/assets/{webimage-XFHVyVtC.js → webimage-YafxjjGr.js} +1 -1
- package/dist/assets/{zstd-3q5qcl5V.js → zstd-CkSLOiuu.js} +1 -1
- package/dist/index.html +7 -7
- package/package.json +7 -6
- package/src/components/extensions/FlavorDialog.tsx +18 -2
- package/src/components/extensions/FlavorListView.tsx +12 -3
- package/src/components/viewer/ClashBcfExportDialog.tsx +271 -0
- package/src/components/viewer/ClashPanel.tsx +370 -0
- package/src/components/viewer/ClashSettingsDialog.tsx +407 -0
- package/src/components/viewer/CommandPalette.tsx +14 -15
- package/src/components/viewer/MainToolbar.tsx +155 -175
- package/src/components/viewer/ViewerLayout.tsx +5 -0
- package/src/components/viewer/Viewport.tsx +49 -9
- package/src/components/viewer/ViewportContainer.tsx +45 -3
- package/src/components/viewer/bcf/BCFOverlay.tsx +5 -4
- package/src/components/viewer/useGeometryStreaming.ts +21 -1
- package/src/hooks/ingest/streamCleanup.test.ts +41 -0
- package/src/hooks/ingest/streamCleanup.ts +45 -0
- package/src/hooks/ingest/viewerModelIngest.ts +64 -42
- package/src/hooks/ingest/watchedGeometryStream.test.ts +78 -0
- package/src/hooks/ingest/watchedGeometryStream.ts +76 -0
- package/src/hooks/useAlignmentLines3D.ts +164 -0
- package/src/hooks/useClash.ts +420 -0
- package/src/hooks/useIfcFederation.ts +16 -2
- package/src/hooks/useIfcLoader.ts +5 -7
- package/src/lib/clash/persistence.ts +308 -0
- package/src/lib/geo/effective-georef.test.ts +66 -0
- package/src/services/extensions/host.ts +13 -0
- package/src/store/constants.ts +33 -25
- package/src/store/index.ts +29 -8
- package/src/store/slices/clashSlice.ts +251 -0
- package/src/store/slices/visibilitySlice.test.ts +23 -5
- package/src/store/slices/visibilitySlice.ts +18 -8
- package/dist/assets/geometry.worker-Cyn5BybV.js +0 -1
- package/dist/assets/index-Bws3UAkj.css +0 -1
- package/dist/assets/raw-R2QfzPAR.js +0 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/native-bridge-
|
|
2
|
-
import {
|
|
3
|
-
let rs, is, Le, as, qn,
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/native-bridge-CPojOeGE.js","assets/sandbox-CsRXlgCO.js","assets/lens-PYsLu_MA.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import { U as Ge, _ as $e, aP as nt, a7 as Ve, a8 as ze, k as tt, l as Ct, aS as Me, E as ke, ai as ee, am as Ye, aj as We, aK as je, W as He, j as ne, i as Xe, __tla as __tla_0 } from "./sandbox-CsRXlgCO.js";
|
|
3
|
+
let rs, is, Le, as, qn, Be, ss, In, cs, ie, os, ns;
|
|
4
4
|
let __tla = Promise.all([
|
|
5
5
|
(()=>{
|
|
6
6
|
try {
|
|
@@ -9,21 +9,21 @@ let __tla = Promise.all([
|
|
|
9
9
|
})()
|
|
10
10
|
]).then(async ()=>{
|
|
11
11
|
let c;
|
|
12
|
-
function
|
|
13
|
-
St ===
|
|
12
|
+
function B(r) {
|
|
13
|
+
St === ot.length && ot.push(ot.length + 1);
|
|
14
14
|
const t = St;
|
|
15
|
-
return St =
|
|
15
|
+
return St = ot[t], ot[t] = r, t;
|
|
16
16
|
}
|
|
17
17
|
function qe(r) {
|
|
18
18
|
if (kt == 1) throw new Error("out of js stack");
|
|
19
|
-
return
|
|
19
|
+
return ot[--kt] = r, kt;
|
|
20
20
|
}
|
|
21
21
|
const de = typeof FinalizationRegistry > "u" ? {
|
|
22
22
|
register: ()=>{},
|
|
23
23
|
unregister: ()=>{}
|
|
24
24
|
} : new FinalizationRegistry((r)=>r.dtor(r.a, r.b));
|
|
25
25
|
function Qe(r) {
|
|
26
|
-
r < 132 || (
|
|
26
|
+
r < 132 || (ot[r] = St, St = r);
|
|
27
27
|
}
|
|
28
28
|
function se(r, t) {
|
|
29
29
|
return r = r >>> 0, Ke().subarray(r / 4, r / 4 + t);
|
|
@@ -32,11 +32,11 @@ let __tla = Promise.all([
|
|
|
32
32
|
return r = r >>> 0, Ze().subarray(r / 8, r / 8 + t);
|
|
33
33
|
}
|
|
34
34
|
function xe(r, t) {
|
|
35
|
-
return r = r >>> 0,
|
|
35
|
+
return r = r >>> 0, Pe().subarray(r / 4, r / 4 + t);
|
|
36
36
|
}
|
|
37
|
-
let
|
|
37
|
+
let gt = null;
|
|
38
38
|
function A() {
|
|
39
|
-
return (
|
|
39
|
+
return (gt === null || gt.buffer.detached === !0 || gt.buffer.detached === void 0 && gt.buffer !== c.memory.buffer) && (gt = new DataView(c.memory.buffer)), gt;
|
|
40
40
|
}
|
|
41
41
|
let Tt = null;
|
|
42
42
|
function Ke() {
|
|
@@ -50,26 +50,26 @@ let __tla = Promise.all([
|
|
|
50
50
|
return r = r >>> 0, nn(r, t);
|
|
51
51
|
}
|
|
52
52
|
let Ft = null;
|
|
53
|
-
function
|
|
53
|
+
function Pe() {
|
|
54
54
|
return (Ft === null || Ft.byteLength === 0) && (Ft = new Uint32Array(c.memory.buffer)), Ft;
|
|
55
55
|
}
|
|
56
56
|
let Rt = null;
|
|
57
57
|
function Nt() {
|
|
58
58
|
return (Rt === null || Rt.byteLength === 0) && (Rt = new Uint8Array(c.memory.buffer)), Rt;
|
|
59
59
|
}
|
|
60
|
-
function
|
|
61
|
-
return
|
|
60
|
+
function W(r) {
|
|
61
|
+
return ot[r];
|
|
62
62
|
}
|
|
63
63
|
function Xt(r, t) {
|
|
64
64
|
try {
|
|
65
65
|
return r.apply(this, t);
|
|
66
66
|
} catch (e) {
|
|
67
|
-
c.__wbindgen_export(
|
|
67
|
+
c.__wbindgen_export(B(e));
|
|
68
68
|
}
|
|
69
69
|
}
|
|
70
|
-
let
|
|
71
|
-
|
|
72
|
-
let St =
|
|
70
|
+
let ot = new Array(128).fill(void 0);
|
|
71
|
+
ot.push(void 0, null, !0, !1);
|
|
72
|
+
let St = ot.length;
|
|
73
73
|
function $t(r) {
|
|
74
74
|
return r == null;
|
|
75
75
|
}
|
|
@@ -95,16 +95,16 @@ let __tla = Promise.all([
|
|
|
95
95
|
}
|
|
96
96
|
function ft(r, t) {
|
|
97
97
|
const e = t(r.length * 4, 4) >>> 0;
|
|
98
|
-
return
|
|
98
|
+
return Pe().set(r, e / 4), $ = r.length, e;
|
|
99
99
|
}
|
|
100
|
-
function
|
|
100
|
+
function It(r, t) {
|
|
101
101
|
const e = t(r.length * 1, 1) >>> 0;
|
|
102
|
-
return Nt().set(r, e / 1),
|
|
102
|
+
return Nt().set(r, e / 1), $ = r.length, e;
|
|
103
103
|
}
|
|
104
|
-
function
|
|
104
|
+
function ut(r, t, e) {
|
|
105
105
|
if (e === void 0) {
|
|
106
106
|
const a = At.encode(r), l = t(a.length, 1) >>> 0;
|
|
107
|
-
return Nt().subarray(l, l + a.length).set(a),
|
|
107
|
+
return Nt().subarray(l, l + a.length).set(a), $ = a.length, l;
|
|
108
108
|
}
|
|
109
109
|
let n = r.length, s = t(n, 1) >>> 0;
|
|
110
110
|
const i = Nt();
|
|
@@ -119,11 +119,11 @@ let __tla = Promise.all([
|
|
|
119
119
|
const a = Nt().subarray(s + o, s + n), l = At.encodeInto(r, a);
|
|
120
120
|
o += l.written, s = e(s, n, o, 1) >>> 0;
|
|
121
121
|
}
|
|
122
|
-
return
|
|
122
|
+
return $ = o, s;
|
|
123
123
|
}
|
|
124
124
|
let kt = 128;
|
|
125
|
-
function
|
|
126
|
-
const t =
|
|
125
|
+
function V(r) {
|
|
126
|
+
const t = W(r);
|
|
127
127
|
return Qe(r), t;
|
|
128
128
|
}
|
|
129
129
|
let Yt = new TextDecoder("utf-8", {
|
|
@@ -147,13 +147,15 @@ let __tla = Promise.all([
|
|
|
147
147
|
written: e.length
|
|
148
148
|
};
|
|
149
149
|
});
|
|
150
|
-
let
|
|
150
|
+
let $ = 0;
|
|
151
151
|
function sn(r, t, e) {
|
|
152
|
-
c.
|
|
152
|
+
c.__wasm_bindgen_func_elem_593(r, t, B(e));
|
|
153
153
|
}
|
|
154
154
|
function rn(r, t, e, n) {
|
|
155
|
-
c.
|
|
155
|
+
c.__wasm_bindgen_func_elem_627(r, t, B(e), B(n));
|
|
156
156
|
}
|
|
157
|
+
typeof FinalizationRegistry > "u" || new FinalizationRegistry((r)=>c.__wbg_clashrunresult_free(r >>> 0, 1));
|
|
158
|
+
typeof FinalizationRegistry > "u" || new FinalizationRegistry((r)=>c.__wbg_clashsession_free(r >>> 0, 1));
|
|
157
159
|
const fe = typeof FinalizationRegistry > "u" ? {
|
|
158
160
|
register: ()=>{},
|
|
159
161
|
unregister: ()=>{}
|
|
@@ -195,38 +197,42 @@ let __tla = Promise.all([
|
|
|
195
197
|
c.__wbg_ifcapi_free(t, 0);
|
|
196
198
|
}
|
|
197
199
|
buildPrePassFast(t) {
|
|
198
|
-
const e =
|
|
199
|
-
return
|
|
200
|
+
const e = It(t, c.__wbindgen_export3), n = $, s = c.ifcapi_buildPrePassFast(this.__wbg_ptr, e, n);
|
|
201
|
+
return V(s);
|
|
200
202
|
}
|
|
201
203
|
buildPrePassOnce(t) {
|
|
202
|
-
const e =
|
|
203
|
-
return
|
|
204
|
+
const e = It(t, c.__wbindgen_export3), n = $, s = c.ifcapi_buildPrePassOnce(this.__wbg_ptr, e, n);
|
|
205
|
+
return V(s);
|
|
204
206
|
}
|
|
205
207
|
processGeometryBatch(t, e, n, s, i, o, a, l, d, u, f, p) {
|
|
206
|
-
const _ =
|
|
208
|
+
const _ = It(t, c.__wbindgen_export3), h = $, y = ft(e, c.__wbindgen_export3), m = $, b = ft(l, c.__wbindgen_export3), w = $, v = ft(d, c.__wbindgen_export3), L = $, j = ft(u, c.__wbindgen_export3), O = $, U = ft(f, c.__wbindgen_export3), C = $, N = It(p, c.__wbindgen_export3), F = $, E = c.ifcapi_processGeometryBatch(this.__wbg_ptr, _, h, y, m, n, s, i, o, a, b, w, v, L, j, O, U, C, N, F);
|
|
207
209
|
return Ot.__wrap(E);
|
|
208
210
|
}
|
|
209
211
|
buildPrePassStreaming(t, e, n) {
|
|
210
212
|
try {
|
|
211
|
-
const a = c.__wbindgen_add_to_stack_pointer(-16), l =
|
|
213
|
+
const a = c.__wbindgen_add_to_stack_pointer(-16), l = It(t, c.__wbindgen_export3), d = $;
|
|
212
214
|
c.ifcapi_buildPrePassStreaming(a, this.__wbg_ptr, l, d, qe(e), n);
|
|
213
215
|
var s = A().getInt32(a + 0, !0), i = A().getInt32(a + 4, !0), o = A().getInt32(a + 8, !0);
|
|
214
|
-
if (o) throw
|
|
215
|
-
return
|
|
216
|
+
if (o) throw V(i);
|
|
217
|
+
return V(s);
|
|
216
218
|
} finally{
|
|
217
|
-
c.__wbindgen_add_to_stack_pointer(16),
|
|
219
|
+
c.__wbindgen_add_to_stack_pointer(16), ot[kt++] = void 0;
|
|
218
220
|
}
|
|
219
221
|
}
|
|
222
|
+
parseAlignmentLines(t) {
|
|
223
|
+
const e = ut(t, c.__wbindgen_export3, c.__wbindgen_export4), n = $, s = c.ifcapi_parseAlignmentLines(this.__wbg_ptr, e, n);
|
|
224
|
+
return V(s);
|
|
225
|
+
}
|
|
220
226
|
extractProfiles(t, e) {
|
|
221
|
-
const n =
|
|
227
|
+
const n = ut(t, c.__wbindgen_export3, c.__wbindgen_export4), s = $, i = c.ifcapi_extractProfiles(this.__wbg_ptr, n, s, e);
|
|
222
228
|
return Mt.__wrap(i);
|
|
223
229
|
}
|
|
224
230
|
getMemory() {
|
|
225
231
|
const t = c.ifcapi_getMemory(this.__wbg_ptr);
|
|
226
|
-
return
|
|
232
|
+
return V(t);
|
|
227
233
|
}
|
|
228
234
|
setEntityIndex(t, e, n) {
|
|
229
|
-
const s = ft(t, c.__wbindgen_export3), i =
|
|
235
|
+
const s = ft(t, c.__wbindgen_export3), i = $, o = ft(e, c.__wbindgen_export3), a = $, l = ft(n, c.__wbindgen_export3), d = $;
|
|
230
236
|
c.ifcapi_setEntityIndex(this.__wbg_ptr, s, i, o, a, l, d);
|
|
231
237
|
}
|
|
232
238
|
setMergeLayers(t) {
|
|
@@ -254,31 +260,31 @@ let __tla = Promise.all([
|
|
|
254
260
|
return c.ifcapi_is_ready(this.__wbg_ptr) !== 0;
|
|
255
261
|
}
|
|
256
262
|
parseStreaming(t, e) {
|
|
257
|
-
const n =
|
|
258
|
-
return
|
|
263
|
+
const n = ut(t, c.__wbindgen_export3, c.__wbindgen_export4), s = $, i = c.ifcapi_parseStreaming(this.__wbg_ptr, n, s, B(e));
|
|
264
|
+
return V(i);
|
|
259
265
|
}
|
|
260
266
|
scanEntitiesFast(t) {
|
|
261
|
-
const e =
|
|
262
|
-
return
|
|
267
|
+
const e = ut(t, c.__wbindgen_export3, c.__wbindgen_export4), n = $, s = c.ifcapi_scanEntitiesFast(this.__wbg_ptr, e, n);
|
|
268
|
+
return V(s);
|
|
263
269
|
}
|
|
264
270
|
scanEntitiesFastBytes(t) {
|
|
265
|
-
const e =
|
|
266
|
-
return
|
|
271
|
+
const e = It(t, c.__wbindgen_export3), n = $, s = c.ifcapi_scanEntitiesFastBytes(this.__wbg_ptr, e, n);
|
|
272
|
+
return V(s);
|
|
267
273
|
}
|
|
268
274
|
scanGeometryEntitiesFast(t) {
|
|
269
|
-
const e =
|
|
270
|
-
return
|
|
275
|
+
const e = ut(t, c.__wbindgen_export3, c.__wbindgen_export4), n = $, s = c.ifcapi_scanGeometryEntitiesFast(this.__wbg_ptr, e, n);
|
|
276
|
+
return V(s);
|
|
271
277
|
}
|
|
272
278
|
scanRelevantEntitiesFastBytes(t) {
|
|
273
|
-
const e =
|
|
274
|
-
return
|
|
279
|
+
const e = It(t, c.__wbindgen_export3), n = $, s = c.ifcapi_scanRelevantEntitiesFastBytes(this.__wbg_ptr, e, n);
|
|
280
|
+
return V(s);
|
|
275
281
|
}
|
|
276
282
|
parse(t) {
|
|
277
|
-
const e =
|
|
278
|
-
return
|
|
283
|
+
const e = ut(t, c.__wbindgen_export3, c.__wbindgen_export4), n = $, s = c.ifcapi_parse(this.__wbg_ptr, e, n);
|
|
284
|
+
return V(s);
|
|
279
285
|
}
|
|
280
286
|
parseSymbolicRepresentations(t) {
|
|
281
|
-
const e =
|
|
287
|
+
const e = ut(t, c.__wbindgen_export3, c.__wbindgen_export4), n = $, s = c.ifcapi_parseSymbolicRepresentations(this.__wbg_ptr, e, n);
|
|
282
288
|
return Dt.__wrap(s);
|
|
283
289
|
}
|
|
284
290
|
};
|
|
@@ -390,11 +396,11 @@ let __tla = Promise.all([
|
|
|
390
396
|
}
|
|
391
397
|
get indices() {
|
|
392
398
|
const t = c.meshdatajs_indices(this.__wbg_ptr);
|
|
393
|
-
return
|
|
399
|
+
return V(t);
|
|
394
400
|
}
|
|
395
401
|
get normals() {
|
|
396
402
|
const t = c.meshdatajs_normals(this.__wbg_ptr);
|
|
397
|
-
return
|
|
403
|
+
return V(t);
|
|
398
404
|
}
|
|
399
405
|
get ifcType() {
|
|
400
406
|
let t, e;
|
|
@@ -409,7 +415,7 @@ let __tla = Promise.all([
|
|
|
409
415
|
}
|
|
410
416
|
get positions() {
|
|
411
417
|
const t = c.meshdatajs_positions(this.__wbg_ptr);
|
|
412
|
-
return
|
|
418
|
+
return V(t);
|
|
413
419
|
}
|
|
414
420
|
}
|
|
415
421
|
Symbol.dispose && (Lt.prototype[Symbol.dispose] = Lt.prototype.free);
|
|
@@ -455,22 +461,22 @@ let __tla = Promise.all([
|
|
|
455
461
|
}
|
|
456
462
|
get holeCounts() {
|
|
457
463
|
const t = c.profileentryjs_holeCounts(this.__wbg_ptr);
|
|
458
|
-
return
|
|
464
|
+
return V(t);
|
|
459
465
|
}
|
|
460
466
|
get holePoints() {
|
|
461
467
|
const t = c.profileentryjs_holePoints(this.__wbg_ptr);
|
|
462
|
-
return
|
|
468
|
+
return V(t);
|
|
463
469
|
}
|
|
464
470
|
get modelIndex() {
|
|
465
471
|
return c.profileentryjs_modelIndex(this.__wbg_ptr) >>> 0;
|
|
466
472
|
}
|
|
467
473
|
get outerPoints() {
|
|
468
474
|
const t = c.profileentryjs_outerPoints(this.__wbg_ptr);
|
|
469
|
-
return
|
|
475
|
+
return V(t);
|
|
470
476
|
}
|
|
471
477
|
get extrusionDir() {
|
|
472
478
|
const t = c.profileentryjs_extrusionDir(this.__wbg_ptr);
|
|
473
|
-
return
|
|
479
|
+
return V(t);
|
|
474
480
|
}
|
|
475
481
|
get extrusionDepth() {
|
|
476
482
|
return c.profileentryjs_extrusionDepth(this.__wbg_ptr);
|
|
@@ -488,14 +494,14 @@ let __tla = Promise.all([
|
|
|
488
494
|
}
|
|
489
495
|
get transform() {
|
|
490
496
|
const t = c.profileentryjs_transform(this.__wbg_ptr);
|
|
491
|
-
return
|
|
497
|
+
return V(t);
|
|
492
498
|
}
|
|
493
499
|
}
|
|
494
500
|
Symbol.dispose && (xt.prototype[Symbol.dispose] = xt.prototype.free);
|
|
495
|
-
class
|
|
501
|
+
class Pt {
|
|
496
502
|
static __wrap(t) {
|
|
497
503
|
t = t >>> 0;
|
|
498
|
-
const e = Object.create(
|
|
504
|
+
const e = Object.create(Pt.prototype);
|
|
499
505
|
return e.__wbg_ptr = t, ge.register(e, e.__wbg_ptr, e), e;
|
|
500
506
|
}
|
|
501
507
|
__destroy_into_raw() {
|
|
@@ -553,11 +559,11 @@ let __tla = Promise.all([
|
|
|
553
559
|
return c.symboliccircle_endAngle(this.__wbg_ptr);
|
|
554
560
|
}
|
|
555
561
|
}
|
|
556
|
-
Symbol.dispose && (
|
|
557
|
-
class
|
|
562
|
+
Symbol.dispose && (Pt.prototype[Symbol.dispose] = Pt.prototype.free);
|
|
563
|
+
class Bt {
|
|
558
564
|
static __wrap(t) {
|
|
559
565
|
t = t >>> 0;
|
|
560
|
-
const e = Object.create(
|
|
566
|
+
const e = Object.create(Bt.prototype);
|
|
561
567
|
return e.__wbg_ptr = t, _e.register(e, e.__wbg_ptr, e), e;
|
|
562
568
|
}
|
|
563
569
|
__destroy_into_raw() {
|
|
@@ -588,7 +594,7 @@ let __tla = Promise.all([
|
|
|
588
594
|
}
|
|
589
595
|
get holesOffsets() {
|
|
590
596
|
const t = c.symbolicfillarea_holesOffsets(this.__wbg_ptr);
|
|
591
|
-
return
|
|
597
|
+
return V(t);
|
|
592
598
|
}
|
|
593
599
|
get repIdentifier() {
|
|
594
600
|
let t, e;
|
|
@@ -621,7 +627,7 @@ let __tla = Promise.all([
|
|
|
621
627
|
}
|
|
622
628
|
get points() {
|
|
623
629
|
const t = c.symbolicfillarea_points(this.__wbg_ptr);
|
|
624
|
-
return
|
|
630
|
+
return V(t);
|
|
625
631
|
}
|
|
626
632
|
get worldY() {
|
|
627
633
|
return c.symbolicfillarea_worldY(this.__wbg_ptr);
|
|
@@ -638,7 +644,7 @@ let __tla = Promise.all([
|
|
|
638
644
|
}
|
|
639
645
|
}
|
|
640
646
|
}
|
|
641
|
-
Symbol.dispose && (
|
|
647
|
+
Symbol.dispose && (Bt.prototype[Symbol.dispose] = Bt.prototype.free);
|
|
642
648
|
class Ut {
|
|
643
649
|
static __wrap(t) {
|
|
644
650
|
t = t >>> 0;
|
|
@@ -672,7 +678,7 @@ let __tla = Promise.all([
|
|
|
672
678
|
}
|
|
673
679
|
get points() {
|
|
674
680
|
const t = c.symbolicpolyline_points(this.__wbg_ptr);
|
|
675
|
-
return
|
|
681
|
+
return V(t);
|
|
676
682
|
}
|
|
677
683
|
get worldY() {
|
|
678
684
|
return c.symboliccircle_worldY(this.__wbg_ptr);
|
|
@@ -712,7 +718,7 @@ let __tla = Promise.all([
|
|
|
712
718
|
}
|
|
713
719
|
getCircle(t) {
|
|
714
720
|
const e = c.symbolicrepresentationcollection_getCircle(this.__wbg_ptr, t);
|
|
715
|
-
return e === 0 ? void 0 :
|
|
721
|
+
return e === 0 ? void 0 : Pt.__wrap(e);
|
|
716
722
|
}
|
|
717
723
|
get textCount() {
|
|
718
724
|
return c.symbolicrepresentationcollection_textCount(this.__wbg_ptr) >>> 0;
|
|
@@ -742,7 +748,7 @@ let __tla = Promise.all([
|
|
|
742
748
|
}
|
|
743
749
|
getFill(t) {
|
|
744
750
|
const e = c.symbolicrepresentationcollection_getFill(this.__wbg_ptr, t);
|
|
745
|
-
return e === 0 ? void 0 :
|
|
751
|
+
return e === 0 ? void 0 : Bt.__wrap(e);
|
|
746
752
|
}
|
|
747
753
|
getText(t) {
|
|
748
754
|
const e = c.symbolicrepresentationcollection_getText(this.__wbg_ptr, t);
|
|
@@ -876,27 +882,27 @@ let __tla = Promise.all([
|
|
|
876
882
|
const r = {};
|
|
877
883
|
return r.wbg = {}, r.wbg.__wbg_Error_52673b7de5a0ca89 = function(t, e) {
|
|
878
884
|
const n = Error(J(t, e));
|
|
879
|
-
return
|
|
885
|
+
return B(n);
|
|
880
886
|
}, r.wbg.__wbg___wbindgen_is_function_8d400b8b1af978cd = function(t) {
|
|
881
|
-
return typeof
|
|
887
|
+
return typeof W(t) == "function";
|
|
882
888
|
}, r.wbg.__wbg___wbindgen_is_undefined_f6b95eab589e0269 = function(t) {
|
|
883
|
-
return
|
|
889
|
+
return W(t) === void 0;
|
|
884
890
|
}, r.wbg.__wbg___wbindgen_memory_a342e963fbcabd68 = function() {
|
|
885
891
|
const t = c.memory;
|
|
886
|
-
return
|
|
892
|
+
return B(t);
|
|
887
893
|
}, r.wbg.__wbg___wbindgen_throw_dd24417ed36fc46e = function(t, e) {
|
|
888
894
|
throw new Error(J(t, e));
|
|
889
895
|
}, r.wbg.__wbg__wbg_cb_unref_87dfb5aaa0cbcea7 = function(t) {
|
|
890
|
-
|
|
896
|
+
W(t)._wbg_cb_unref();
|
|
891
897
|
}, r.wbg.__wbg_call_3020136f7a2d6e44 = function() {
|
|
892
898
|
return Xt(function(t, e, n) {
|
|
893
|
-
const s =
|
|
894
|
-
return
|
|
899
|
+
const s = W(t).call(W(e), W(n));
|
|
900
|
+
return B(s);
|
|
895
901
|
}, arguments);
|
|
896
902
|
}, r.wbg.__wbg_call_abb4ff46ce38be40 = function() {
|
|
897
903
|
return Xt(function(t, e) {
|
|
898
|
-
const n =
|
|
899
|
-
return
|
|
904
|
+
const n = W(t).call(W(e));
|
|
905
|
+
return B(n);
|
|
900
906
|
}, arguments);
|
|
901
907
|
}, r.wbg.__wbg_error_7534b8e9a36f1ab4 = function(t, e) {
|
|
902
908
|
let n, s;
|
|
@@ -906,16 +912,16 @@ let __tla = Promise.all([
|
|
|
906
912
|
c.__wbindgen_export2(n, s, 1);
|
|
907
913
|
}
|
|
908
914
|
}, r.wbg.__wbg_info_ce6bcc489c22f6f0 = function(t) {
|
|
909
|
-
console.info(
|
|
915
|
+
console.info(W(t));
|
|
910
916
|
}, r.wbg.__wbg_new_1ba21ce319a06297 = function() {
|
|
911
917
|
const t = new Object;
|
|
912
|
-
return
|
|
918
|
+
return B(t);
|
|
913
919
|
}, r.wbg.__wbg_new_25f239778d6112b9 = function() {
|
|
914
920
|
const t = new Array;
|
|
915
|
-
return
|
|
921
|
+
return B(t);
|
|
916
922
|
}, r.wbg.__wbg_new_8a6f238a6ece86ea = function() {
|
|
917
923
|
const t = new Error;
|
|
918
|
-
return
|
|
924
|
+
return B(t);
|
|
919
925
|
}, r.wbg.__wbg_new_ff12d2b041fb48f1 = function(t, e) {
|
|
920
926
|
try {
|
|
921
927
|
var n = {
|
|
@@ -931,100 +937,100 @@ let __tla = Promise.all([
|
|
|
931
937
|
}
|
|
932
938
|
};
|
|
933
939
|
const i = new Promise(s);
|
|
934
|
-
return
|
|
940
|
+
return B(i);
|
|
935
941
|
} finally{
|
|
936
942
|
n.a = n.b = 0;
|
|
937
943
|
}
|
|
938
944
|
}, r.wbg.__wbg_new_from_slice_41e2764a343e3cb1 = function(t, e) {
|
|
939
945
|
const n = new Float32Array(se(t, e));
|
|
940
|
-
return
|
|
946
|
+
return B(n);
|
|
941
947
|
}, r.wbg.__wbg_new_from_slice_db0691b69e9d3891 = function(t, e) {
|
|
942
948
|
const n = new Uint32Array(xe(t, e));
|
|
943
|
-
return
|
|
949
|
+
return B(n);
|
|
944
950
|
}, r.wbg.__wbg_new_no_args_cb138f77cf6151ee = function(t, e) {
|
|
945
951
|
const n = new Function(J(t, e));
|
|
946
|
-
return
|
|
952
|
+
return B(n);
|
|
947
953
|
}, r.wbg.__wbg_new_with_length_202b3db94ba5fc86 = function(t) {
|
|
948
954
|
const e = new Uint32Array(t >>> 0);
|
|
949
|
-
return
|
|
955
|
+
return B(e);
|
|
950
956
|
}, r.wbg.__wbg_new_with_length_806b9e5b8290af7c = function(t) {
|
|
951
957
|
const e = new Float64Array(t >>> 0);
|
|
952
|
-
return
|
|
958
|
+
return B(e);
|
|
953
959
|
}, r.wbg.__wbg_new_with_length_aa5eaf41d35235e5 = function(t) {
|
|
954
960
|
const e = new Uint8Array(t >>> 0);
|
|
955
|
-
return
|
|
961
|
+
return B(e);
|
|
956
962
|
}, r.wbg.__wbg_queueMicrotask_9b549dfce8865860 = function(t) {
|
|
957
|
-
const e =
|
|
958
|
-
return
|
|
963
|
+
const e = W(t).queueMicrotask;
|
|
964
|
+
return B(e);
|
|
959
965
|
}, r.wbg.__wbg_queueMicrotask_fca69f5bfad613a5 = function(t) {
|
|
960
|
-
queueMicrotask(
|
|
966
|
+
queueMicrotask(W(t));
|
|
961
967
|
}, r.wbg.__wbg_resolve_fd5bfbaa4ce36e1e = function(t) {
|
|
962
|
-
const e = Promise.resolve(
|
|
963
|
-
return
|
|
968
|
+
const e = Promise.resolve(W(t));
|
|
969
|
+
return B(e);
|
|
964
970
|
}, r.wbg.__wbg_set_3f1d0b984ed272ed = function(t, e, n) {
|
|
965
|
-
|
|
971
|
+
W(t)[V(e)] = V(n);
|
|
966
972
|
}, r.wbg.__wbg_set_781438a03c0c3c81 = function() {
|
|
967
973
|
return Xt(function(t, e, n) {
|
|
968
|
-
return Reflect.set(
|
|
974
|
+
return Reflect.set(W(t), W(e), W(n));
|
|
969
975
|
}, arguments);
|
|
970
976
|
}, r.wbg.__wbg_set_7df433eea03a5c14 = function(t, e, n) {
|
|
971
|
-
|
|
977
|
+
W(t)[e >>> 0] = V(n);
|
|
972
978
|
}, r.wbg.__wbg_set_index_021489b2916af13e = function(t, e, n) {
|
|
973
|
-
|
|
979
|
+
W(t)[e >>> 0] = n;
|
|
974
980
|
}, r.wbg.__wbg_set_index_04c4b93e64d08a52 = function(t, e, n) {
|
|
975
|
-
|
|
981
|
+
W(t)[e >>> 0] = n;
|
|
976
982
|
}, r.wbg.__wbg_set_index_42abe35f117e614e = function(t, e, n) {
|
|
977
|
-
|
|
983
|
+
W(t)[e >>> 0] = n >>> 0;
|
|
978
984
|
}, r.wbg.__wbg_stack_0ed75d68575b0f3c = function(t, e) {
|
|
979
|
-
const n =
|
|
985
|
+
const n = W(e).stack, s = ut(n, c.__wbindgen_export3, c.__wbindgen_export4), i = $;
|
|
980
986
|
A().setInt32(t + 4, i, !0), A().setInt32(t + 0, s, !0);
|
|
981
987
|
}, r.wbg.__wbg_static_accessor_GLOBAL_769e6b65d6557335 = function() {
|
|
982
988
|
const t = typeof global > "u" ? null : global;
|
|
983
|
-
return $t(t) ? 0 :
|
|
989
|
+
return $t(t) ? 0 : B(t);
|
|
984
990
|
}, r.wbg.__wbg_static_accessor_GLOBAL_THIS_60cf02db4de8e1c1 = function() {
|
|
985
991
|
const t = typeof globalThis > "u" ? null : globalThis;
|
|
986
|
-
return $t(t) ? 0 :
|
|
992
|
+
return $t(t) ? 0 : B(t);
|
|
987
993
|
}, r.wbg.__wbg_static_accessor_SELF_08f5a74c69739274 = function() {
|
|
988
994
|
const t = typeof self > "u" ? null : self;
|
|
989
|
-
return $t(t) ? 0 :
|
|
995
|
+
return $t(t) ? 0 : B(t);
|
|
990
996
|
}, r.wbg.__wbg_static_accessor_WINDOW_a8924b26aa92d024 = function() {
|
|
991
997
|
const t = typeof window > "u" ? null : window;
|
|
992
|
-
return $t(t) ? 0 :
|
|
998
|
+
return $t(t) ? 0 : B(t);
|
|
993
999
|
}, r.wbg.__wbg_then_4f95312d68691235 = function(t, e) {
|
|
994
|
-
const n =
|
|
995
|
-
return
|
|
1000
|
+
const n = W(t).then(W(e));
|
|
1001
|
+
return B(n);
|
|
996
1002
|
}, r.wbg.__wbg_warn_6e567d0d926ff881 = function(t) {
|
|
997
|
-
console.warn(
|
|
1003
|
+
console.warn(W(t));
|
|
998
1004
|
}, r.wbg.__wbindgen_cast_2241b6af4c4b2941 = function(t, e) {
|
|
999
1005
|
const n = J(t, e);
|
|
1000
|
-
return
|
|
1006
|
+
return B(n);
|
|
1001
1007
|
}, r.wbg.__wbindgen_cast_4625c577ab2ec9ee = function(t) {
|
|
1002
1008
|
const e = BigInt.asUintN(64, t);
|
|
1003
|
-
return
|
|
1004
|
-
}, r.wbg.__wbindgen_cast_89b0435615caf0ab = function(t, e) {
|
|
1005
|
-
const n = tn(t, e, c.__wasm_bindgen_func_elem_1684, sn);
|
|
1006
|
-
return P(n);
|
|
1009
|
+
return B(e);
|
|
1007
1010
|
}, r.wbg.__wbindgen_cast_d6cd19b81560fd6e = function(t) {
|
|
1008
|
-
return
|
|
1011
|
+
return B(t);
|
|
1012
|
+
}, r.wbg.__wbindgen_cast_e7ad0d7b317830d5 = function(t, e) {
|
|
1013
|
+
const n = tn(t, e, c.__wasm_bindgen_func_elem_592, sn);
|
|
1014
|
+
return B(n);
|
|
1009
1015
|
}, r.wbg.__wbindgen_object_clone_ref = function(t) {
|
|
1010
|
-
const e =
|
|
1011
|
-
return
|
|
1016
|
+
const e = W(t);
|
|
1017
|
+
return B(e);
|
|
1012
1018
|
}, r.wbg.__wbindgen_object_drop_ref = function(t) {
|
|
1013
|
-
|
|
1019
|
+
V(t);
|
|
1014
1020
|
}, r;
|
|
1015
1021
|
}
|
|
1016
1022
|
function ln(r, t) {
|
|
1017
|
-
return c = r.exports,
|
|
1023
|
+
return c = r.exports, Be.__wbindgen_wasm_module = t, gt = null, Tt = null, wt = null, Ft = null, Rt = null, c.__wbindgen_start(), c;
|
|
1018
1024
|
}
|
|
1019
|
-
|
|
1025
|
+
Be = async function(r) {
|
|
1020
1026
|
if (c !== void 0) return c;
|
|
1021
|
-
typeof r < "u" && (Object.getPrototypeOf(r) === Object.prototype ? { module_or_path: r } = r : console.warn("using deprecated parameters for the initialization function; pass a single object instead")), typeof r > "u" && (r = new URL("/assets/ifc-lite_bg-
|
|
1027
|
+
typeof r < "u" && (Object.getPrototypeOf(r) === Object.prototype ? { module_or_path: r } = r : console.warn("using deprecated parameters for the initialization function; pass a single object instead")), typeof r > "u" && (r = new URL("/assets/ifc-lite_bg-CEZnhM2e.wasm", import.meta.url));
|
|
1022
1028
|
const t = cn();
|
|
1023
1029
|
(typeof r == "string" || typeof Request == "function" && r instanceof Request || typeof URL == "function" && r instanceof URL) && (r = fetch(r));
|
|
1024
1030
|
const { instance: e, module: n } = await an(await r, t);
|
|
1025
1031
|
return ln(e, n);
|
|
1026
1032
|
};
|
|
1027
|
-
const
|
|
1033
|
+
const rt = Ge("Geometry"), dn = "IFC-Lite WASM cannot recover from a fatal runtime error within the same document lifetime. Reload the page or recreate the worker process before calling init() again.";
|
|
1028
1034
|
let Qt = null;
|
|
1029
1035
|
class fn {
|
|
1030
1036
|
ifcApi = null;
|
|
@@ -1040,9 +1046,9 @@ let __tla = Promise.all([
|
|
|
1040
1046
|
if (!this.initialized) {
|
|
1041
1047
|
if (Qt) throw Qt;
|
|
1042
1048
|
try {
|
|
1043
|
-
await
|
|
1049
|
+
await Be(), rt.debug("Geometry processing: single-threaded WASM (N-worker pool handles parallelism)"), this.ifcApi = new ie, this.applyMergeLayers(), this.initialized = !0, rt.info("WASM geometry engine initialized");
|
|
1044
1050
|
} catch (t) {
|
|
1045
|
-
throw
|
|
1051
|
+
throw rt.error("Failed to initialize WASM geometry engine", t, {
|
|
1046
1052
|
operation: "init"
|
|
1047
1053
|
}), this.isWasmRuntimeError(t) ? this.markFatalWasmRuntimeError() : this.reset(), t;
|
|
1048
1054
|
}
|
|
@@ -1055,11 +1061,11 @@ let __tla = Promise.all([
|
|
|
1055
1061
|
if (!this.ifcApi) throw new Error("IFC-Lite not initialized. Call init() first.");
|
|
1056
1062
|
try {
|
|
1057
1063
|
const e = this.ifcApi.parseSymbolicRepresentations(t);
|
|
1058
|
-
return
|
|
1064
|
+
return rt.debug(`Parsed ${e.totalCount} symbolic items (${e.polylineCount} polylines, ${e.circleCount} circles)`, {
|
|
1059
1065
|
operation: "parseSymbolicRepresentations"
|
|
1060
1066
|
}), e;
|
|
1061
1067
|
} catch (e) {
|
|
1062
|
-
throw
|
|
1068
|
+
throw rt.error("Failed to parse symbolic representations", e, {
|
|
1063
1069
|
operation: "parseSymbolicRepresentations",
|
|
1064
1070
|
data: {
|
|
1065
1071
|
contentLength: t.length
|
|
@@ -1067,15 +1073,31 @@ let __tla = Promise.all([
|
|
|
1067
1073
|
}), this.isWasmRuntimeError(e) && this.markFatalWasmRuntimeError(), e;
|
|
1068
1074
|
}
|
|
1069
1075
|
}
|
|
1076
|
+
parseAlignmentLines(t) {
|
|
1077
|
+
if (!this.ifcApi) throw new Error("IFC-Lite not initialized. Call init() first.");
|
|
1078
|
+
try {
|
|
1079
|
+
const e = this.ifcApi.parseAlignmentLines(t);
|
|
1080
|
+
return rt.debug(`Parsed ${e.length / 3} alignment line vertices`, {
|
|
1081
|
+
operation: "parseAlignmentLines"
|
|
1082
|
+
}), e;
|
|
1083
|
+
} catch (e) {
|
|
1084
|
+
throw rt.error("Failed to parse alignment lines", e, {
|
|
1085
|
+
operation: "parseAlignmentLines",
|
|
1086
|
+
data: {
|
|
1087
|
+
contentLength: t.length
|
|
1088
|
+
}
|
|
1089
|
+
}), this.isWasmRuntimeError(e) && this.markFatalWasmRuntimeError(), e;
|
|
1090
|
+
}
|
|
1091
|
+
}
|
|
1070
1092
|
extractProfiles(t, e = 0) {
|
|
1071
1093
|
if (!this.ifcApi) throw new Error("IFC-Lite not initialized. Call init() first.");
|
|
1072
1094
|
try {
|
|
1073
1095
|
const n = this.ifcApi.extractProfiles(t, e);
|
|
1074
|
-
return
|
|
1096
|
+
return rt.debug(`Extracted ${n.length} profiles`, {
|
|
1075
1097
|
operation: "extractProfiles"
|
|
1076
1098
|
}), n;
|
|
1077
1099
|
} catch (n) {
|
|
1078
|
-
throw
|
|
1100
|
+
throw rt.error("Failed to extract profiles", n, {
|
|
1079
1101
|
operation: "extractProfiles",
|
|
1080
1102
|
data: {
|
|
1081
1103
|
contentLength: t.length
|
|
@@ -1103,7 +1125,7 @@ let __tla = Promise.all([
|
|
|
1103
1125
|
if (!this.ifcApi) return;
|
|
1104
1126
|
const t = this.ifcApi;
|
|
1105
1127
|
if (typeof t.setMergeLayers != "function") {
|
|
1106
|
-
|
|
1128
|
+
rt.warn("setMergeLayers not present on WASM API — flag tracked but suppression is a no-op until WASM is rebuilt", {
|
|
1107
1129
|
operation: "setMergeLayers",
|
|
1108
1130
|
data: {
|
|
1109
1131
|
requested: this.mergeLayers
|
|
@@ -1111,7 +1133,7 @@ let __tla = Promise.all([
|
|
|
1111
1133
|
});
|
|
1112
1134
|
return;
|
|
1113
1135
|
}
|
|
1114
|
-
t.setMergeLayers(this.mergeLayers),
|
|
1136
|
+
t.setMergeLayers(this.mergeLayers), rt.debug(`mergeLayers=${this.mergeLayers}`, {
|
|
1115
1137
|
operation: "setMergeLayers"
|
|
1116
1138
|
});
|
|
1117
1139
|
}
|
|
@@ -1122,7 +1144,7 @@ let __tla = Promise.all([
|
|
|
1122
1144
|
async function un() {
|
|
1123
1145
|
if (Ue()) {
|
|
1124
1146
|
const { NativeBridge: r } = await $e(async ()=>{
|
|
1125
|
-
const { NativeBridge: t } = await import("./native-bridge-
|
|
1147
|
+
const { NativeBridge: t } = await import("./native-bridge-CPojOeGE.js").then(async (m)=>{
|
|
1126
1148
|
await m.__tla;
|
|
1127
1149
|
return m;
|
|
1128
1150
|
});
|
|
@@ -1616,9 +1638,9 @@ let __tla = Promise.all([
|
|
|
1616
1638
|
let i;
|
|
1617
1639
|
const o = r.buffer;
|
|
1618
1640
|
n && n.byteLength === r.byteLength ? i = n : typeof SharedArrayBuffer < "u" && o instanceof SharedArrayBuffer && r.byteOffset === 0 && r.byteLength === o.byteLength ? i = o : (i = new SharedArrayBuffer(r.byteLength), new Uint8Array(i).set(r));
|
|
1619
|
-
const a = ()=>new Worker(new URL("/assets/geometry.worker-
|
|
1641
|
+
const a = ()=>new Worker(new URL("/assets/geometry.worker-0Q9qEa6p.js", import.meta.url), {
|
|
1620
1642
|
type: "module"
|
|
1621
|
-
}), l = ()=>new Worker(new URL("/assets/geometry.worker-
|
|
1643
|
+
}), l = ()=>new Worker(new URL("/assets/geometry.worker-0Q9qEa6p.js", import.meta.url), {
|
|
1622
1644
|
type: "module"
|
|
1623
1645
|
}), d = [];
|
|
1624
1646
|
let u = null;
|
|
@@ -1629,8 +1651,8 @@ let __tla = Promise.all([
|
|
|
1629
1651
|
const j = [];
|
|
1630
1652
|
let O = !1, U = !1;
|
|
1631
1653
|
const C = [], N = (M, X)=>{
|
|
1632
|
-
M.onmessage = (
|
|
1633
|
-
const x =
|
|
1654
|
+
M.onmessage = (P)=>{
|
|
1655
|
+
const x = P.data;
|
|
1634
1656
|
if (x.type === "ready") {
|
|
1635
1657
|
console.log(`[stream] worker[${X}] WASM ready @ ${Q()}ms`);
|
|
1636
1658
|
return;
|
|
@@ -1674,8 +1696,8 @@ let __tla = Promise.all([
|
|
|
1674
1696
|
m = new Error(`Geometry worker error: ${x.message}`), b++, M.terminate(), f();
|
|
1675
1697
|
return;
|
|
1676
1698
|
}
|
|
1677
|
-
}, M.onerror = (
|
|
1678
|
-
m = new Error(`Geometry worker failed: ${
|
|
1699
|
+
}, M.onerror = (P)=>{
|
|
1700
|
+
m = new Error(`Geometry worker failed: ${P.message}`), b++, M.terminate(), f();
|
|
1679
1701
|
};
|
|
1680
1702
|
}, F = typeof navigator < "u" ? navigator.hardwareConcurrency ?? 2 : 2, E = typeof navigator < "u" ? navigator.deviceMemory ?? 8 : 8, g = r.byteLength / (1024 * 1024), T = Math.max(1, Math.ceil(g * 100)), I = _n({
|
|
1681
1703
|
fileSizeMB: g,
|
|
@@ -1686,11 +1708,11 @@ let __tla = Promise.all([
|
|
|
1686
1708
|
for(let M = 0; M < I; M++){
|
|
1687
1709
|
const X = a();
|
|
1688
1710
|
R.push(X), N(X, M);
|
|
1689
|
-
const
|
|
1711
|
+
const P = s?.wasmUrls?.wasm;
|
|
1690
1712
|
X.postMessage({
|
|
1691
1713
|
type: "init",
|
|
1692
|
-
...
|
|
1693
|
-
wasmUrl:
|
|
1714
|
+
...P ? {
|
|
1715
|
+
wasmUrl: P
|
|
1694
1716
|
} : {}
|
|
1695
1717
|
}), X.postMessage({
|
|
1696
1718
|
type: "set-merge-layers",
|
|
@@ -1709,69 +1731,69 @@ let __tla = Promise.all([
|
|
|
1709
1731
|
}, G = ()=>{
|
|
1710
1732
|
if (L || !p) return;
|
|
1711
1733
|
L = !0;
|
|
1712
|
-
const M = e != null, X = M ? e.x : p.rtcOffset[0],
|
|
1734
|
+
const M = e != null, X = M ? e.x : p.rtcOffset[0], P = M ? e.y : p.rtcOffset[1], x = M ? e.z : p.rtcOffset[2], q = M ? !0 : p.needsShift;
|
|
1713
1735
|
d.push({
|
|
1714
1736
|
type: "rtcOffset",
|
|
1715
1737
|
rtcOffset: {
|
|
1716
1738
|
x: X,
|
|
1717
|
-
y:
|
|
1739
|
+
y: P,
|
|
1718
1740
|
z: x
|
|
1719
1741
|
},
|
|
1720
1742
|
hasRtc: q
|
|
1721
1743
|
}), f();
|
|
1722
|
-
const D = new Uint32Array(0),
|
|
1723
|
-
for (const
|
|
1744
|
+
const D = new Uint32Array(0), st = new Uint8Array(0);
|
|
1745
|
+
for (const pt of R)pt.postMessage({
|
|
1724
1746
|
type: "stream-start",
|
|
1725
1747
|
sharedBuffer: i,
|
|
1726
1748
|
unitScale: p.unitScale,
|
|
1727
1749
|
rtcX: X,
|
|
1728
|
-
rtcY:
|
|
1750
|
+
rtcY: P,
|
|
1729
1751
|
rtcZ: x,
|
|
1730
1752
|
needsShift: q,
|
|
1731
1753
|
voidKeys: D,
|
|
1732
1754
|
voidCounts: D,
|
|
1733
1755
|
voidValues: D,
|
|
1734
1756
|
styleIds: D,
|
|
1735
|
-
styleColors:
|
|
1757
|
+
styleColors: st
|
|
1736
1758
|
});
|
|
1737
1759
|
};
|
|
1738
|
-
function
|
|
1760
|
+
function z(M) {
|
|
1739
1761
|
if (R.length === 0 || M.length === 0) return;
|
|
1740
1762
|
const X = Math.floor(M.length / 3);
|
|
1741
1763
|
if (X === 0) return;
|
|
1742
|
-
const
|
|
1764
|
+
const P = Math.ceil(X / R.length);
|
|
1743
1765
|
try {
|
|
1744
1766
|
for(let x = 0; x < R.length; x++){
|
|
1745
|
-
const q = x *
|
|
1767
|
+
const q = x * P * 3, D = Math.min(q + P * 3, M.length);
|
|
1746
1768
|
if (q >= D) continue;
|
|
1747
|
-
const
|
|
1769
|
+
const st = M.slice(q, D);
|
|
1748
1770
|
R[x].postMessage({
|
|
1749
1771
|
type: "stream-chunk",
|
|
1750
|
-
jobsFlat:
|
|
1772
|
+
jobsFlat: st
|
|
1751
1773
|
}, [
|
|
1752
|
-
|
|
1774
|
+
st.buffer
|
|
1753
1775
|
]);
|
|
1754
1776
|
}
|
|
1755
1777
|
} catch (x) {
|
|
1756
1778
|
m = new Error(`Failed to dispatch jobs chunk: ${x instanceof Error ? x.message : String(x)}`), f();
|
|
1757
1779
|
}
|
|
1758
1780
|
}
|
|
1759
|
-
const
|
|
1781
|
+
const k = (M)=>{
|
|
1760
1782
|
if (!L || !O || !U) {
|
|
1761
1783
|
j.push(M);
|
|
1762
1784
|
return;
|
|
1763
1785
|
}
|
|
1764
|
-
|
|
1786
|
+
z(M);
|
|
1765
1787
|
}, H = ()=>{
|
|
1766
|
-
if (!(!L || !O || !U)) for(; j.length > 0;)
|
|
1767
|
-
},
|
|
1788
|
+
if (!(!L || !O || !U)) for(; j.length > 0;)z(j.shift());
|
|
1789
|
+
}, Y = performance.now(), Q = ()=>Math.round(performance.now() - Y);
|
|
1768
1790
|
console.log(`[stream] processParallel start, fileSizeMB=${g.toFixed(1)} workerCount=${I}`);
|
|
1769
1791
|
const K = l();
|
|
1770
1792
|
s?.wasmUrls?.wasm && K.postMessage({
|
|
1771
1793
|
type: "init",
|
|
1772
1794
|
wasmUrl: s.wasmUrls.wasm
|
|
1773
1795
|
});
|
|
1774
|
-
let
|
|
1796
|
+
let at = 0, ht = 0, it = -1;
|
|
1775
1797
|
K.onmessage = (M)=>{
|
|
1776
1798
|
const X = M.data;
|
|
1777
1799
|
if (X.type === "prepass-progress") {
|
|
@@ -1782,21 +1804,21 @@ let __tla = Promise.all([
|
|
|
1782
1804
|
return;
|
|
1783
1805
|
}
|
|
1784
1806
|
if (X.type === "prepass-stream") {
|
|
1785
|
-
const
|
|
1786
|
-
if (
|
|
1787
|
-
unitScale:
|
|
1788
|
-
rtcOffset:
|
|
1789
|
-
needsShift:
|
|
1790
|
-
buildingRotation:
|
|
1807
|
+
const P = X.event;
|
|
1808
|
+
if (P.type === "meta") p = {
|
|
1809
|
+
unitScale: P.unitScale,
|
|
1810
|
+
rtcOffset: P.rtcOffset,
|
|
1811
|
+
needsShift: P.needsShift,
|
|
1812
|
+
buildingRotation: P.buildingRotation ?? null
|
|
1791
1813
|
}, console.log(`[stream] meta @ ${Q()}ms unitScale=${p.unitScale} rtc=[${p.rtcOffset[0].toFixed(0)},${p.rtcOffset[1].toFixed(0)},${p.rtcOffset[2].toFixed(0)}]`), G(), f();
|
|
1792
|
-
else if (
|
|
1793
|
-
const x =
|
|
1794
|
-
|
|
1795
|
-
} else if (
|
|
1796
|
-
const x =
|
|
1814
|
+
else if (P.type === "jobs") {
|
|
1815
|
+
const x = P.jobs, q = Math.floor(x.length / 3);
|
|
1816
|
+
at++, ht += q, it < 0 && (it = Q(), console.log(`[stream] first jobs chunk @ ${it}ms (${q} jobs)`)), (at % 10 === 1 || q < 1e3) && console.log(`[stream] chunk #${at} @ ${Q()}ms (+${q} jobs, total ${ht})`), k(x);
|
|
1817
|
+
} else if (P.type === "styles") {
|
|
1818
|
+
const x = P.styleIds, q = P.styleColors, D = P.voidKeys, st = P.voidCounts, pt = P.voidValues;
|
|
1797
1819
|
console.log(`[stream] styles @ ${Q()}ms (${x.length} styled, ${D.length} void hosts), draining ${j.length} queued chunks`);
|
|
1798
1820
|
for (const Ht of R)try {
|
|
1799
|
-
const dt = x.slice(), yt = q.slice(), Et = D.slice(), mt =
|
|
1821
|
+
const dt = x.slice(), yt = q.slice(), Et = D.slice(), mt = st.slice(), Gt = pt.slice();
|
|
1800
1822
|
Ht.postMessage({
|
|
1801
1823
|
type: "set-styles",
|
|
1802
1824
|
styleIds: dt,
|
|
@@ -1815,10 +1837,10 @@ let __tla = Promise.all([
|
|
|
1815
1837
|
console.warn("[stream] set-styles dispatch failed:", dt);
|
|
1816
1838
|
}
|
|
1817
1839
|
O = !0, H();
|
|
1818
|
-
} else if (
|
|
1819
|
-
const x =
|
|
1840
|
+
} else if (P.type === "entity-index") {
|
|
1841
|
+
const x = P.ids, q = P.starts, D = P.lengths;
|
|
1820
1842
|
if (console.log(`[stream] entity-index @ ${Q()}ms (${x.length} entries)`), typeof SharedArrayBuffer < "u") {
|
|
1821
|
-
const
|
|
1843
|
+
const st = x.byteLength, pt = q.byteLength, Ht = D.byteLength, dt = new SharedArrayBuffer(st), yt = new SharedArrayBuffer(pt), Et = new SharedArrayBuffer(Ht);
|
|
1822
1844
|
new Uint32Array(dt).set(x), new Uint32Array(yt).set(q), new Uint32Array(Et).set(D);
|
|
1823
1845
|
for (const mt of R)try {
|
|
1824
1846
|
mt.postMessage({
|
|
@@ -1836,24 +1858,24 @@ let __tla = Promise.all([
|
|
|
1836
1858
|
console.warn("[stream] onEntityIndex callback failed:", mt);
|
|
1837
1859
|
}
|
|
1838
1860
|
} else {
|
|
1839
|
-
for (const
|
|
1840
|
-
|
|
1861
|
+
for (const st of R)try {
|
|
1862
|
+
st.postMessage({
|
|
1841
1863
|
type: "set-entity-index",
|
|
1842
1864
|
ids: x.slice(),
|
|
1843
1865
|
starts: q.slice(),
|
|
1844
1866
|
lengths: D.slice()
|
|
1845
1867
|
});
|
|
1846
|
-
} catch (
|
|
1847
|
-
console.warn("[stream] set-entity-index dispatch failed:",
|
|
1868
|
+
} catch (pt) {
|
|
1869
|
+
console.warn("[stream] set-entity-index dispatch failed:", pt);
|
|
1848
1870
|
}
|
|
1849
1871
|
if (s?.onEntityIndex) try {
|
|
1850
1872
|
s.onEntityIndex(x.slice(), q.slice(), D.slice());
|
|
1851
|
-
} catch (
|
|
1852
|
-
console.warn("[stream] onEntityIndex callback failed:",
|
|
1873
|
+
} catch (st) {
|
|
1874
|
+
console.warn("[stream] onEntityIndex callback failed:", st);
|
|
1853
1875
|
}
|
|
1854
1876
|
}
|
|
1855
1877
|
U = !0, H();
|
|
1856
|
-
} else
|
|
1878
|
+
} else P.type === "complete" && (_ = P.totalJobs, console.log(`[stream] prepass complete @ ${Q()}ms totalJobs=${_} chunks=${at}`), ct || (ct = !0, lt()));
|
|
1857
1879
|
return;
|
|
1858
1880
|
}
|
|
1859
1881
|
if (X.type === "error") {
|
|
@@ -1871,7 +1893,7 @@ let __tla = Promise.all([
|
|
|
1871
1893
|
sharedBuffer: i,
|
|
1872
1894
|
chunkSize: 5e4
|
|
1873
1895
|
});
|
|
1874
|
-
let
|
|
1896
|
+
let ct = !1;
|
|
1875
1897
|
for(;;){
|
|
1876
1898
|
for(; d.length > 0;)yield d.shift();
|
|
1877
1899
|
if (m) {
|
|
@@ -2181,12 +2203,17 @@ let __tla = Promise.all([
|
|
|
2181
2203
|
}
|
|
2182
2204
|
parseSymbolicRepresentations(t) {
|
|
2183
2205
|
if (!this.bridge || !this.bridge.isInitialized()) return null;
|
|
2184
|
-
const e =
|
|
2206
|
+
const e = nt(t);
|
|
2185
2207
|
return this.bridge.parseSymbolicRepresentations(e);
|
|
2186
2208
|
}
|
|
2209
|
+
parseAlignmentLines(t) {
|
|
2210
|
+
if (!this.bridge || !this.bridge.isInitialized()) return null;
|
|
2211
|
+
const e = nt(t);
|
|
2212
|
+
return this.bridge.parseAlignmentLines(e);
|
|
2213
|
+
}
|
|
2187
2214
|
extractProfiles(t, e = 0) {
|
|
2188
2215
|
if (!this.bridge || !this.bridge.isInitialized()) return null;
|
|
2189
|
-
const n =
|
|
2216
|
+
const n = nt(t);
|
|
2190
2217
|
return this.bridge.extractProfiles(n, e);
|
|
2191
2218
|
}
|
|
2192
2219
|
dispose() {}
|
|
@@ -2263,36 +2290,36 @@ let __tla = Promise.all([
|
|
|
2263
2290
|
for(let I = 0; I < e.length; I++){
|
|
2264
2291
|
const R = e[I];
|
|
2265
2292
|
if (!d(R)) continue;
|
|
2266
|
-
const S = R.positions, G = R.normals,
|
|
2267
|
-
if (!S.length || !G.length ||
|
|
2268
|
-
let
|
|
2293
|
+
const S = R.positions, G = R.normals, z = R.indices;
|
|
2294
|
+
if (!S.length || !G.length || !z.length || S.length % 3 !== 0 || G.length % 3 !== 0 || S.length !== G.length) continue;
|
|
2295
|
+
let k = S[0], H = S[1], Y = S[2], Q = S[0], K = S[1], at = S[2];
|
|
2269
2296
|
for(let it = 3; it < S.length; it += 3){
|
|
2270
|
-
const lt = S[it],
|
|
2271
|
-
lt <
|
|
2297
|
+
const lt = S[it], ct = S[it + 1], _t = S[it + 2];
|
|
2298
|
+
lt < k && (k = lt), lt > Q && (Q = lt), ct < H && (H = ct), ct > K && (K = ct), _t < Y && (Y = _t), _t > at && (at = _t);
|
|
2272
2299
|
}
|
|
2273
|
-
const
|
|
2300
|
+
const ht = u(R);
|
|
2274
2301
|
y.push({
|
|
2275
2302
|
meshIndex: I,
|
|
2276
2303
|
posCount: S.length,
|
|
2277
2304
|
normCount: G.length,
|
|
2278
|
-
idxCount:
|
|
2305
|
+
idxCount: z.length,
|
|
2279
2306
|
posByteOffset: m * 4,
|
|
2280
2307
|
normByteOffset: b * 4,
|
|
2281
2308
|
idxByteOffset: w * 4,
|
|
2282
2309
|
bounds: {
|
|
2283
2310
|
min: [
|
|
2284
|
-
|
|
2311
|
+
k,
|
|
2285
2312
|
H,
|
|
2286
|
-
|
|
2313
|
+
Y
|
|
2287
2314
|
],
|
|
2288
2315
|
max: [
|
|
2289
2316
|
Q,
|
|
2290
2317
|
K,
|
|
2291
|
-
|
|
2318
|
+
at
|
|
2292
2319
|
]
|
|
2293
2320
|
},
|
|
2294
|
-
materialIdx:
|
|
2295
|
-
}), m += S.length, b += G.length, w +=
|
|
2321
|
+
materialIdx: ht ? h(ht) : void 0
|
|
2322
|
+
}), m += S.length, b += G.length, w += z.length;
|
|
2296
2323
|
}
|
|
2297
2324
|
if (m === 0 || b === 0 || w === 0) throw new Error("Cannot export GLB: no valid geometry data found");
|
|
2298
2325
|
const v = new Float32Array(m), L = new Float32Array(b), j = new Uint32Array(w);
|
|
@@ -2319,7 +2346,7 @@ let __tla = Promise.all([
|
|
|
2319
2346
|
count: I.normCount / 3,
|
|
2320
2347
|
type: "VEC3"
|
|
2321
2348
|
});
|
|
2322
|
-
const
|
|
2349
|
+
const z = f.accessors.length;
|
|
2323
2350
|
f.accessors.push({
|
|
2324
2351
|
bufferView: 2,
|
|
2325
2352
|
byteOffset: I.idxByteOffset,
|
|
@@ -2327,7 +2354,7 @@ let __tla = Promise.all([
|
|
|
2327
2354
|
count: I.idxCount,
|
|
2328
2355
|
type: "SCALAR"
|
|
2329
2356
|
});
|
|
2330
|
-
const
|
|
2357
|
+
const k = f.meshes.length;
|
|
2331
2358
|
f.meshes.push({
|
|
2332
2359
|
primitives: [
|
|
2333
2360
|
{
|
|
@@ -2335,22 +2362,22 @@ let __tla = Promise.all([
|
|
|
2335
2362
|
POSITION: S,
|
|
2336
2363
|
NORMAL: G
|
|
2337
2364
|
},
|
|
2338
|
-
indices:
|
|
2365
|
+
indices: z,
|
|
2339
2366
|
...I.materialIdx !== void 0 ? {
|
|
2340
2367
|
material: I.materialIdx
|
|
2341
2368
|
} : {}
|
|
2342
2369
|
}
|
|
2343
2370
|
]
|
|
2344
2371
|
});
|
|
2345
|
-
const H = f.nodes.length,
|
|
2346
|
-
mesh:
|
|
2372
|
+
const H = f.nodes.length, Y = {
|
|
2373
|
+
mesh: k
|
|
2347
2374
|
};
|
|
2348
|
-
t.includeMetadata && R.expressId !== void 0 && (
|
|
2375
|
+
t.includeMetadata && R.expressId !== void 0 && (Y.extras = R.modelIndex !== void 0 ? {
|
|
2349
2376
|
expressId: R.expressId,
|
|
2350
2377
|
modelIndex: R.modelIndex
|
|
2351
2378
|
} : {
|
|
2352
2379
|
expressId: R.expressId
|
|
2353
|
-
}), f.nodes.push(
|
|
2380
|
+
}), f.nodes.push(Y), N.push(H);
|
|
2354
2381
|
}
|
|
2355
2382
|
f.scenes[0].nodes = N, _.length > 0 && (f.materials = _, f.extensionsUsed = [
|
|
2356
2383
|
"KHR_materials_unlit"
|
|
@@ -2388,8 +2415,8 @@ let __tla = Promise.all([
|
|
|
2388
2415
|
else if (I.type === "VEC2") G = 2;
|
|
2389
2416
|
else if (I.type === "SCALAR") G = 1;
|
|
2390
2417
|
else throw new Error(`Unsupported accessor type: ${I.type}`);
|
|
2391
|
-
const
|
|
2392
|
-
if (
|
|
2418
|
+
const z = I.count * G * S, k = (I.byteOffset || 0) + z;
|
|
2419
|
+
if (k > R.byteLength) throw new Error(`Accessor exceeds bufferView bounds: accessor byteOffset=${I.byteOffset || 0}, length=${z}, bufferView byteLength=${R.byteLength}, end=${k}`);
|
|
2393
2420
|
}
|
|
2394
2421
|
return {
|
|
2395
2422
|
json: f,
|
|
@@ -2585,7 +2612,7 @@ let __tla = Promise.all([
|
|
|
2585
2612
|
return t.join(e);
|
|
2586
2613
|
}
|
|
2587
2614
|
};
|
|
2588
|
-
const
|
|
2615
|
+
const Pn = 35, zt = 48, Fe = 57, Bn = new Set([
|
|
2589
2616
|
"IFCOWNERHISTORY",
|
|
2590
2617
|
"IFCAPPLICATION",
|
|
2591
2618
|
"IFCPERSON",
|
|
@@ -2833,7 +2860,7 @@ let __tla = Promise.all([
|
|
|
2833
2860
|
function Wt(r, t, e, n) {
|
|
2834
2861
|
const s = t + e;
|
|
2835
2862
|
let i = t;
|
|
2836
|
-
for(; i < s;)if (r[i] ===
|
|
2863
|
+
for(; i < s;)if (r[i] === Pn) {
|
|
2837
2864
|
if (i++, i < s && r[i] >= zt && r[i] <= Fe) {
|
|
2838
2865
|
let o = r[i] - zt;
|
|
2839
2866
|
for(i++; i < s && r[i] >= zt && r[i] <= Fe;)o = o * 10 + (r[i] - zt), i++;
|
|
@@ -2864,7 +2891,7 @@ let __tla = Promise.all([
|
|
|
2864
2891
|
const n = new Set, s = new Set;
|
|
2865
2892
|
for (const [i, o] of r.entityIndex.byId){
|
|
2866
2893
|
const a = o.type.toUpperCase();
|
|
2867
|
-
if (
|
|
2894
|
+
if (Bn.has(a)) {
|
|
2868
2895
|
n.add(i);
|
|
2869
2896
|
continue;
|
|
2870
2897
|
}
|
|
@@ -3546,31 +3573,31 @@ let __tla = Promise.all([
|
|
|
3546
3573
|
const E = this.buildRelDefinesByPropertiesIndex();
|
|
3547
3574
|
for (const [g, T] of N){
|
|
3548
3575
|
d.add(g), u.set(g, T), s++;
|
|
3549
|
-
const R = this.mutationView.getForEntity(g).filter((
|
|
3576
|
+
const R = this.mutationView.getForEntity(g).filter((z)=>T.has(z.name)), S = new Set;
|
|
3550
3577
|
R.length > 0 && p.push({
|
|
3551
3578
|
entityId: g,
|
|
3552
3579
|
psets: R
|
|
3553
3580
|
});
|
|
3554
3581
|
const G = E.get(g);
|
|
3555
|
-
if (G) for (const { relId:
|
|
3556
|
-
const H = this.getPropertySetName(
|
|
3582
|
+
if (G) for (const { relId: z, psetId: k } of G){
|
|
3583
|
+
const H = this.getPropertySetName(k);
|
|
3557
3584
|
if (H && S.add(H), H && T.has(H)) {
|
|
3558
|
-
v.add(
|
|
3559
|
-
const
|
|
3560
|
-
for (const Q of
|
|
3585
|
+
v.add(z), w.add(k);
|
|
3586
|
+
const Y = this.getPropertyIdsInSet(k);
|
|
3587
|
+
for (const Q of Y)w.add(Q);
|
|
3561
3588
|
}
|
|
3562
3589
|
}
|
|
3563
3590
|
if (this.isTypeEntity(g)) {
|
|
3564
|
-
const
|
|
3565
|
-
for (const H of
|
|
3566
|
-
const
|
|
3567
|
-
if (!
|
|
3568
|
-
|
|
3591
|
+
const z = this.getTypeOwnedHasPropertySetIds(g), k = new Set;
|
|
3592
|
+
for (const H of z){
|
|
3593
|
+
const Y = this.getPropertySetName(H);
|
|
3594
|
+
if (!Y || !T.has(Y)) continue;
|
|
3595
|
+
k.add(Y), w.add(H);
|
|
3569
3596
|
const Q = this.getPropertyIdsInSet(H);
|
|
3570
3597
|
for (const K of Q)w.add(K);
|
|
3571
3598
|
}
|
|
3572
|
-
for (const H of T)S.has(H) ||
|
|
3573
|
-
|
|
3599
|
+
for (const H of T)S.has(H) || k.add(H);
|
|
3600
|
+
k.size > 0 && (h.set(g, k), y.set(g, z), m.add(g));
|
|
3574
3601
|
}
|
|
3575
3602
|
}
|
|
3576
3603
|
t.includeQuantities === !1 && F.clear();
|
|
@@ -3582,12 +3609,12 @@ let __tla = Promise.all([
|
|
|
3582
3609
|
qsets: R
|
|
3583
3610
|
});
|
|
3584
3611
|
const S = E.get(g);
|
|
3585
|
-
if (S) for (const { relId: G, psetId:
|
|
3586
|
-
const
|
|
3587
|
-
if (
|
|
3588
|
-
v.add(G), w.add(
|
|
3589
|
-
const H = this.getPropertyIdsInSet(
|
|
3590
|
-
for (const
|
|
3612
|
+
if (S) for (const { relId: G, psetId: z } of S){
|
|
3613
|
+
const k = this.getElementQuantityName(z);
|
|
3614
|
+
if (k && T.has(k)) {
|
|
3615
|
+
v.add(G), w.add(z);
|
|
3616
|
+
const H = this.getPropertyIdsInSet(z);
|
|
3617
|
+
for (const Y of H)w.add(Y);
|
|
3591
3618
|
}
|
|
3592
3619
|
}
|
|
3593
3620
|
}
|
|
@@ -3615,18 +3642,18 @@ let __tla = Promise.all([
|
|
|
3615
3642
|
T.eastings !== void 0 && (g.set("Eastings", String(T.eastings)), I = !0), T.northings !== void 0 && (g.set("Northings", String(T.northings)), I = !0), T.orthogonalHeight !== void 0 && (g.set("OrthogonalHeight", String(T.orthogonalHeight)), I = !0), T.xAxisAbscissa !== void 0 && (g.set("XAxisAbscissa", String(T.xAxisAbscissa)), I = !0), T.xAxisOrdinate !== void 0 && (g.set("XAxisOrdinate", String(T.xAxisOrdinate)), I = !0), T.scale !== void 0 && (g.set("Scale", String(T.scale)), I = !0), I && !d.has(E) && (d.add(E), s++);
|
|
3616
3643
|
}
|
|
3617
3644
|
if (C.projectedCRS && !N?.length) {
|
|
3618
|
-
const E = C.projectedCRS, g = this.nextExpressId++, T = E.name ? `'${et(String(E.name))}'` : "$", I = E.description ? `'${et(String(E.description))}'` : "$", R = E.geodeticDatum ? `'${et(String(E.geodeticDatum))}'` : "$", S = E.verticalDatum ? `'${et(String(E.verticalDatum))}'` : "$", G = E.mapProjection ? `'${et(String(E.mapProjection))}'` : "$",
|
|
3619
|
-
L.push(`#${g}=IFCPROJECTEDCRS(${T},${I},${R},${S},${G},${
|
|
3645
|
+
const E = C.projectedCRS, g = this.nextExpressId++, T = E.name ? `'${et(String(E.name))}'` : "$", I = E.description ? `'${et(String(E.description))}'` : "$", R = E.geodeticDatum ? `'${et(String(E.geodeticDatum))}'` : "$", S = E.verticalDatum ? `'${et(String(E.verticalDatum))}'` : "$", G = E.mapProjection ? `'${et(String(E.mapProjection))}'` : "$", z = E.mapZone ? `'${et(String(E.mapZone))}'` : "$", k = E.mapUnit ? `#${this.resolveMapUnitReference(String(E.mapUnit), L)}` : "$";
|
|
3646
|
+
L.push(`#${g}=IFCPROJECTEDCRS(${T},${I},${R},${S},${G},${z},${k});`), n++;
|
|
3620
3647
|
const H = this.findPreferredGeometricRepresentationContextId();
|
|
3621
3648
|
if (H) {
|
|
3622
|
-
const
|
|
3623
|
-
L.push(`#${Q}=IFCMAPCONVERSION(#${H},#${g},${K},${
|
|
3649
|
+
const Y = C.mapConversion || {}, Q = this.nextExpressId++, K = Z(Number(Y.eastings) || 0), at = Z(Number(Y.northings) || 0), ht = Z(Number(Y.orthogonalHeight) || 0), it = Y.xAxisAbscissa !== void 0 ? Z(Number(Y.xAxisAbscissa)) : "$", lt = Y.xAxisOrdinate !== void 0 ? Z(Number(Y.xAxisOrdinate)) : "$", ct = Y.scale !== void 0 ? Z(Number(Y.scale)) : "$";
|
|
3650
|
+
L.push(`#${Q}=IFCMAPCONVERSION(#${H},#${g},${K},${at},${ht},${it},${lt},${ct});`), n++;
|
|
3624
3651
|
} else console.warn("[StepExporter] Cannot create IfcMapConversion: no IfcGeometricRepresentationContext found in source file");
|
|
3625
3652
|
} else if (C.mapConversion && !F?.length && N?.length) {
|
|
3626
3653
|
const E = this.findPreferredGeometricRepresentationContextId();
|
|
3627
3654
|
if (E) {
|
|
3628
|
-
const g = C.mapConversion, T = this.nextExpressId++, I = Z(Number(g.eastings) || 0), R = Z(Number(g.northings) || 0), S = Z(Number(g.orthogonalHeight) || 0), G = g.xAxisAbscissa !== void 0 ? Z(Number(g.xAxisAbscissa)) : "$",
|
|
3629
|
-
L.push(`#${T}=IFCMAPCONVERSION(#${E},#${N[0]},${I},${R},${S},${G},${
|
|
3655
|
+
const g = C.mapConversion, T = this.nextExpressId++, I = Z(Number(g.eastings) || 0), R = Z(Number(g.northings) || 0), S = Z(Number(g.orthogonalHeight) || 0), G = g.xAxisAbscissa !== void 0 ? Z(Number(g.xAxisAbscissa)) : "$", z = g.xAxisOrdinate !== void 0 ? Z(Number(g.xAxisOrdinate)) : "$", k = g.scale !== void 0 ? Z(Number(g.scale)) : "$";
|
|
3656
|
+
L.push(`#${T}=IFCMAPCONVERSION(#${E},#${N[0]},${I},${R},${S},${G},${z},${k});`), n++;
|
|
3630
3657
|
} else console.warn("[StepExporter] Cannot create IfcMapConversion: no IfcGeometricRepresentationContext found in source file");
|
|
3631
3658
|
}
|
|
3632
3659
|
}
|
|
@@ -3657,7 +3684,7 @@ END-ISO-10303-21;
|
|
|
3657
3684
|
if (N && typeof this.mutationView.isDeleted == "function" && this.mutationView.isDeleted(F) || E.byteLength === 0 || E.byteOffset < 0 || O !== null && !O.has(F) || w.has(F) || v.has(F) || m.has(F)) continue;
|
|
3658
3685
|
const g = E.type.toUpperCase();
|
|
3659
3686
|
if (t.includeGeometry === !1 && this.isGeometryEntity(g)) continue;
|
|
3660
|
-
const T =
|
|
3687
|
+
const T = nt(C, E.byteOffset, E.byteOffset + E.byteLength);
|
|
3661
3688
|
let I = f.has(F) ? this.applyAttributeMutations(T, g, f.get(F)) : T;
|
|
3662
3689
|
const R = N && typeof this.mutationView.getPositionalMutationsForEntity == "function" ? this.mutationView.getPositionalMutationsForEntity(F) : null;
|
|
3663
3690
|
if (R && R.size > 0 && (I = this.applyPositionalMutations(I, R), d.has(F) || (d.add(F), s++)), a) {
|
|
@@ -3924,7 +3951,7 @@ END-ISO-10303-21;
|
|
|
3924
3951
|
getRelatedEntities(t) {
|
|
3925
3952
|
const e = this.dataStore.entityIndex.byId.get(t);
|
|
3926
3953
|
if (!e || !this.dataStore.source) return [];
|
|
3927
|
-
const s =
|
|
3954
|
+
const s = nt(this.dataStore.source, e.byteOffset, e.byteOffset + e.byteLength).match(/\(([^)]+)\)\s*,\s*#(\d+)\s*\)\s*;/);
|
|
3928
3955
|
if (!s) return [];
|
|
3929
3956
|
const i = s[1], o = [], a = i.matchAll(/#(\d+)/g);
|
|
3930
3957
|
for (const l of a)o.push(parseInt(l[1], 10));
|
|
@@ -3933,25 +3960,25 @@ END-ISO-10303-21;
|
|
|
3933
3960
|
getRelatedPropertySet(t) {
|
|
3934
3961
|
const e = this.dataStore.entityIndex.byId.get(t);
|
|
3935
3962
|
if (!e || !this.dataStore.source) return null;
|
|
3936
|
-
const s =
|
|
3963
|
+
const s = nt(this.dataStore.source, e.byteOffset, e.byteOffset + e.byteLength).match(/,\s*#(\d+)\s*\)\s*;$/);
|
|
3937
3964
|
return s ? parseInt(s[1], 10) : null;
|
|
3938
3965
|
}
|
|
3939
3966
|
getPropertySetName(t) {
|
|
3940
3967
|
const e = this.dataStore.entityIndex.byId.get(t);
|
|
3941
3968
|
if (!e || !this.dataStore.source) return null;
|
|
3942
|
-
const s =
|
|
3969
|
+
const s = nt(this.dataStore.source, e.byteOffset, e.byteOffset + e.byteLength).match(/IFCPROPERTYSET\s*\([^,]*,[^,]*,'([^']*)'/i);
|
|
3943
3970
|
return s ? s[1] : null;
|
|
3944
3971
|
}
|
|
3945
3972
|
getElementQuantityName(t) {
|
|
3946
3973
|
const e = this.dataStore.entityIndex.byId.get(t);
|
|
3947
3974
|
if (!e || !this.dataStore.source) return null;
|
|
3948
|
-
const s =
|
|
3975
|
+
const s = nt(this.dataStore.source, e.byteOffset, e.byteOffset + e.byteLength).match(/IFCELEMENTQUANTITY\s*\([^,]*,[^,]*,'([^']*)'/i);
|
|
3949
3976
|
return s ? s[1] : null;
|
|
3950
3977
|
}
|
|
3951
3978
|
getPropertyIdsInSet(t) {
|
|
3952
3979
|
const e = this.dataStore.entityIndex.byId.get(t);
|
|
3953
3980
|
if (!e || !this.dataStore.source) return [];
|
|
3954
|
-
const s =
|
|
3981
|
+
const s = nt(this.dataStore.source, e.byteOffset, e.byteOffset + e.byteLength).match(/\(\s*(#[^)]+)\s*\)\s*\)\s*;$/);
|
|
3955
3982
|
if (!s) return [];
|
|
3956
3983
|
const i = s[1], o = [], a = i.matchAll(/#(\d+)/g);
|
|
3957
3984
|
for (const l of a)o.push(parseInt(l[1], 10));
|
|
@@ -3985,7 +4012,7 @@ END-ISO-10303-21;
|
|
|
3985
4012
|
replaceEntityAttribute(t, e, n) {
|
|
3986
4013
|
const s = this.dataStore.entityIndex.byId.get(t);
|
|
3987
4014
|
if (!s || !this.dataStore.source) return null;
|
|
3988
|
-
const o =
|
|
4015
|
+
const o = nt(this.dataStore.source, s.byteOffset, s.byteOffset + s.byteLength).match(/^(#\d+\s*=\s*\w+\()([\s\S]*)(\)\s*;)\s*$/);
|
|
3989
4016
|
if (!o) return null;
|
|
3990
4017
|
const [, a, l, d] = o, u = Xn(l);
|
|
3991
4018
|
return e >= u.length ? null : (u[e] = n, `${a}${u.join(",")}${d}`);
|
|
@@ -4064,7 +4091,7 @@ END-ISO-10303-21;
|
|
|
4064
4091
|
}
|
|
4065
4092
|
for (const [j, O] of y.dataStore.entityIndex.byId){
|
|
4066
4093
|
if (w !== null && !w.has(j) || L.has(j)) continue;
|
|
4067
|
-
const U =
|
|
4094
|
+
const U = nt(b, O.byteOffset, O.byteOffset + O.byteLength);
|
|
4068
4095
|
let C;
|
|
4069
4096
|
m === 0 && v.size === 0 ? C = U : C = this.remapEntityText(U, m, v);
|
|
4070
4097
|
const N = y.dataStore.schemaVersion || "IFC4";
|
|
@@ -4148,7 +4175,7 @@ END-ISO-10303-21;
|
|
|
4148
4175
|
let C = 0;
|
|
4149
4176
|
for (const [N, F] of w.dataStore.entityIndex.byId){
|
|
4150
4177
|
if (j !== null && !j.has(N) || U.has(N)) continue;
|
|
4151
|
-
const E =
|
|
4178
|
+
const E = nt(L, F.byteOffset, F.byteOffset + F.byteLength);
|
|
4152
4179
|
let g;
|
|
4153
4180
|
v === 0 && O.size === 0 ? g = E : g = this.remapEntityText(E, v, O);
|
|
4154
4181
|
const T = w.dataStore.schemaVersion || "IFC4";
|
|
@@ -4305,7 +4332,7 @@ END-ISO-10303-21;
|
|
|
4305
4332
|
if (!s) return null;
|
|
4306
4333
|
const i = e.entityIndex.byId.get(t);
|
|
4307
4334
|
if (!i) return null;
|
|
4308
|
-
const o =
|
|
4335
|
+
const o = nt(s, i.byteOffset, i.byteOffset + i.byteLength), a = o.indexOf("(");
|
|
4309
4336
|
if (a === -1) return null;
|
|
4310
4337
|
let l = 0, d = 0, u = a + 1, f = !1;
|
|
4311
4338
|
for(let p = a + 1; p < o.length; p++){
|
|
@@ -4657,4 +4684,4 @@ END-ISO-10303-21;
|
|
|
4657
4684
|
return n.startsWith("ifc") ? "Ifc" + n.charAt(3).toUpperCase() + n.slice(4) : r;
|
|
4658
4685
|
}
|
|
4659
4686
|
});
|
|
4660
|
-
export { rs as C, is as G, Le as I, as as M, qn as S,
|
|
4687
|
+
export { rs as C, is as G, Le as I, as as M, qn as S, Be as _, ss as a, In as b, cs as c, ie as d, os as e, ns as g, __tla };
|