@thatopen/components 2.1.14 → 2.1.15
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/dist/core/Components/index.d.ts +1 -1
- package/dist/ifc/IfcRelationsIndexer/src/types.d.ts +5 -1
- package/dist/index.cjs +5 -5
- package/dist/index.mjs +134 -116
- package/dist/namespace.d.ts +1489 -1485
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -5,7 +5,7 @@ import * as O from "three";
|
|
|
5
5
|
import { BufferAttribute as Pn, Vector3 as M, Vector2 as fe, Plane as Fi, Line3 as Lt, Triangle as ue, Sphere as Zn, Matrix4 as yt, Box3 as gt, BackSide as Qn, DoubleSide as Ln, FrontSide as wi, Mesh as v, Ray as jn, Raycaster as qn, Quaternion as Pt, Object3D as ri, Euler as Kn, MeshBasicMaterial as yn, LineBasicMaterial as $n, CylinderGeometry as ct, BoxGeometry as rt, BufferGeometry as Di, Float32BufferAttribute as Ui, OctahedronGeometry as Ze, Line as Dt, SphereGeometry as Jn, TorusGeometry as Re, PlaneGeometry as to } from "three";
|
|
6
6
|
import * as Vt from "@thatopen/fragments";
|
|
7
7
|
import { Serializer as eo } from "@thatopen/fragments";
|
|
8
|
-
import * as
|
|
8
|
+
import * as U from "web-ifc";
|
|
9
9
|
const Mn = 0, so = 1, io = 2, xi = 2, Ys = 1.25, bi = 1, Cs = 6 * 4 + 4 + 4, Us = 65535, no = Math.pow(2, -24), Vs = Symbol("SKIP_GENERATION");
|
|
10
10
|
function oo(l) {
|
|
11
11
|
return l.index ? l.index.count : l.attributes.position.count;
|
|
@@ -99,7 +99,7 @@ function Gs(l, s, t, e, i = null) {
|
|
|
99
99
|
g < o && (o = g), S > a && (a = S), C && p < d && (d = p), C && p > f && (f = p);
|
|
100
100
|
const _ = l[A + 2], N = l[A + 3], L = _ - N, D = _ + N;
|
|
101
101
|
L < n && (n = L), D > c && (c = D), C && _ < E && (E = _), C && _ > T && (T = _);
|
|
102
|
-
const y = l[A + 4],
|
|
102
|
+
const y = l[A + 4], x = l[A + 5], b = y - x, B = y + x;
|
|
103
103
|
b < r && (r = b), B > h && (h = B), C && y < u && (u = y), C && y > R && (R = y);
|
|
104
104
|
}
|
|
105
105
|
e[0] = o, e[1] = n, e[2] = r, e[3] = a, e[4] = c, e[5] = h, C && (i[0] = d, i[1] = E, i[2] = u, i[3] = f, i[4] = T, i[5] = R);
|
|
@@ -319,9 +319,9 @@ function mo(l, s) {
|
|
|
319
319
|
A(m + g), p.offset = m, p.count = g;
|
|
320
320
|
else {
|
|
321
321
|
p.splitAxis = N.axis;
|
|
322
|
-
const D = new qe(), y = m,
|
|
323
|
-
p.left = D, D.boundingData = new Float32Array(6), Gs(f, y,
|
|
324
|
-
const b = new qe(), B = L, H = g -
|
|
322
|
+
const D = new qe(), y = m, x = L - m;
|
|
323
|
+
p.left = D, D.boundingData = new Float32Array(6), Gs(f, y, x, D.boundingData, u), F(D, y, x, u, _ + 1);
|
|
324
|
+
const b = new qe(), B = L, H = g - x;
|
|
325
325
|
p.right = b, b.boundingData = new Float32Array(6), Gs(f, B, H, b.boundingData, u), F(b, B, H, u, _ + 1);
|
|
326
326
|
}
|
|
327
327
|
return p;
|
|
@@ -553,8 +553,8 @@ Ft.prototype.intersectsTriangle = function() {
|
|
|
553
553
|
if (g !== 2)
|
|
554
554
|
return !1;
|
|
555
555
|
if (d.delta(r), E.delta(a), r.dot(a) < 0) {
|
|
556
|
-
let
|
|
557
|
-
E.start = E.end, E.end =
|
|
556
|
+
let x = E.start;
|
|
557
|
+
E.start = E.end, E.end = x;
|
|
558
558
|
}
|
|
559
559
|
const S = d.start.dot(r), _ = d.end.dot(r), N = E.start.dot(r), L = E.end.dot(r), D = _ < N, y = S < L;
|
|
560
560
|
return S !== L && N !== _ && D === y ? !1 : (C && (c.subVectors(d.start, E.start), c.dot(r) > 0 ? C.start.copy(d.start) : C.start.copy(E.start), c.subVectors(d.end, E.end), c.dot(r) < 0 ? C.end.copy(d.end) : C.end.copy(E.end)), !0);
|
|
@@ -697,7 +697,7 @@ at.prototype.distanceToBox = function() {
|
|
|
697
697
|
for (let A = 0; A <= 1; A++) {
|
|
698
698
|
const F = (R + 1) % 3, p = (R + 2) % 3, m = C << F | A << p, g = 1 << R | C << F | A << p, S = u[m], _ = u[g];
|
|
699
699
|
s[T].set(S, _);
|
|
700
|
-
const L = l[R], D = l[F], y = l[p],
|
|
700
|
+
const L = l[R], D = l[F], y = l[p], x = t[T], b = x.start, B = x.end;
|
|
701
701
|
b[L] = d[L], b[D] = C ? d[D] : E[D], b[y] = A ? d[y] : E[D], B[L] = E[L], B[D] = C ? d[D] : E[D], B[y] = A ? d[y] : E[D], T++;
|
|
702
702
|
}
|
|
703
703
|
for (let R = 0; R <= 1; R++)
|
|
@@ -787,17 +787,17 @@ function ai(l, s, t, e, i = null, o = 0, n = 0) {
|
|
|
787
787
|
return K(l, r, Yt), e(E, u, !1, n, o + l, Yt);
|
|
788
788
|
} else {
|
|
789
789
|
let L = function(y) {
|
|
790
|
-
const { uint16Array:
|
|
790
|
+
const { uint16Array: x, uint32Array: b } = Z;
|
|
791
791
|
let B = y * 2;
|
|
792
|
-
for (; !Et(B,
|
|
792
|
+
for (; !Et(B, x); )
|
|
793
793
|
y = pt(y), B = y * 2;
|
|
794
794
|
return dt(y, b);
|
|
795
795
|
}, D = function(y) {
|
|
796
|
-
const { uint16Array:
|
|
796
|
+
const { uint16Array: x, uint32Array: b } = Z;
|
|
797
797
|
let B = y * 2;
|
|
798
|
-
for (; !Et(B,
|
|
798
|
+
for (; !Et(B, x); )
|
|
799
799
|
y = Ct(y, b), B = y * 2;
|
|
800
|
-
return dt(y, b) + ft(B,
|
|
800
|
+
return dt(y, b) + ft(B, x);
|
|
801
801
|
};
|
|
802
802
|
const E = pt(l), u = Ct(l, c);
|
|
803
803
|
let f = E, T = u, R, C, A, F;
|
|
@@ -936,8 +936,8 @@ function Do(l, s = null) {
|
|
|
936
936
|
let F = 1 / 0, p = 1 / 0, m = 1 / 0, g = -1 / 0, S = -1 / 0, _ = -1 / 0;
|
|
937
937
|
for (let N = 3 * C, L = 3 * (C + A); N < L; N++) {
|
|
938
938
|
let D = e[N];
|
|
939
|
-
const y = i.getX(D),
|
|
940
|
-
y < F && (F = y), y > g && (g = y),
|
|
939
|
+
const y = i.getX(D), x = i.getY(D), b = i.getZ(D);
|
|
940
|
+
y < F && (F = y), y > g && (g = y), x < p && (p = x), x > S && (S = x), b < m && (m = b), b > _ && (_ = b);
|
|
941
941
|
}
|
|
942
942
|
return a[E + 0] !== F || a[E + 1] !== p || a[E + 2] !== m || a[E + 3] !== g || a[E + 4] !== S || a[E + 5] !== _ ? (a[E + 0] = F, a[E + 1] = p, a[E + 2] = m, a[E + 3] = g, a[E + 4] = S, a[E + 5] = _, !0) : !1;
|
|
943
943
|
} else {
|
|
@@ -951,9 +951,9 @@ function Do(l, s = null) {
|
|
|
951
951
|
N && (D = d(A, u, m));
|
|
952
952
|
const y = L || D;
|
|
953
953
|
if (y)
|
|
954
|
-
for (let
|
|
955
|
-
const b = C +
|
|
956
|
-
a[E +
|
|
954
|
+
for (let x = 0; x < 3; x++) {
|
|
955
|
+
const b = C + x, B = A + x, H = a[b], q = a[b + 3], st = a[B], Q = a[B + 3];
|
|
956
|
+
a[E + x] = H < st ? H : st, a[E + x + 3] = q > Q ? q : Q;
|
|
957
957
|
}
|
|
958
958
|
return y;
|
|
959
959
|
}
|
|
@@ -1085,7 +1085,7 @@ function ko(l, s, t, e = {}, i = {}, o = 0, n = 1 / 0) {
|
|
|
1085
1085
|
intersectsRange: (_, N) => {
|
|
1086
1086
|
for (let L = _, D = _ + N; L < D; L++) {
|
|
1087
1087
|
tt(u, 3 * L, d, h), u.a.applyMatrix4(t), u.b.applyMatrix4(t), u.c.applyMatrix4(t), u.needsUpdate = !0;
|
|
1088
|
-
for (let y = m,
|
|
1088
|
+
for (let y = m, x = m + g; y < x; y++) {
|
|
1089
1089
|
tt(E, 3 * y, c, a), E.needsUpdate = !0;
|
|
1090
1090
|
const b = E.distanceToTriangle(u, f, R);
|
|
1091
1091
|
if (b < A && (T.copy(f), C && C.copy(R), A = b, F = y, p = L), b < o)
|
|
@@ -1125,9 +1125,9 @@ function Xo(l, s = null) {
|
|
|
1125
1125
|
for (let N = C, L = C + A; N < L; N++) {
|
|
1126
1126
|
const D = 3 * l.resolveTriangleIndex(N);
|
|
1127
1127
|
for (let y = 0; y < 3; y++) {
|
|
1128
|
-
let
|
|
1129
|
-
|
|
1130
|
-
const b = i.getX(
|
|
1128
|
+
let x = D + y;
|
|
1129
|
+
x = e ? e[x] : x;
|
|
1130
|
+
const b = i.getX(x), B = i.getY(x), H = i.getZ(x);
|
|
1131
1131
|
b < F && (F = b), b > g && (g = b), B < p && (p = B), B > S && (S = B), H < m && (m = H), H > _ && (_ = H);
|
|
1132
1132
|
}
|
|
1133
1133
|
}
|
|
@@ -1143,9 +1143,9 @@ function Xo(l, s = null) {
|
|
|
1143
1143
|
N && (D = d(A, u, m));
|
|
1144
1144
|
const y = L || D;
|
|
1145
1145
|
if (y)
|
|
1146
|
-
for (let
|
|
1147
|
-
const b = C +
|
|
1148
|
-
a[E +
|
|
1146
|
+
for (let x = 0; x < 3; x++) {
|
|
1147
|
+
const b = C + x, B = A + x, H = a[b], q = a[b + 3], st = a[B], Q = a[B + 3];
|
|
1148
|
+
a[E + x] = H < st ? H : st, a[E + x + 3] = q > Q ? q : Q;
|
|
1149
1149
|
}
|
|
1150
1150
|
return y;
|
|
1151
1151
|
}
|
|
@@ -1251,11 +1251,11 @@ function er(l, s, t, e = {}, i = {}, o = 0, n = 1 / 0) {
|
|
|
1251
1251
|
for (let L = _, D = _ + N; L < D; L++) {
|
|
1252
1252
|
const y = S.resolveTriangleIndex(L);
|
|
1253
1253
|
tt(u, 3 * y, d, h), u.a.applyMatrix4(t), u.b.applyMatrix4(t), u.c.applyMatrix4(t), u.needsUpdate = !0;
|
|
1254
|
-
for (let
|
|
1255
|
-
const B = l.resolveTriangleIndex(
|
|
1254
|
+
for (let x = m, b = m + g; x < b; x++) {
|
|
1255
|
+
const B = l.resolveTriangleIndex(x);
|
|
1256
1256
|
tt(E, 3 * B, c, a), E.needsUpdate = !0;
|
|
1257
1257
|
const H = E.distanceToTriangle(u, f, R);
|
|
1258
|
-
if (H < A && (T.copy(f), C && C.copy(R), A = H, F =
|
|
1258
|
+
if (H < A && (T.copy(f), C && C.copy(R), A = H, F = x, p = L), H < o)
|
|
1259
1259
|
return !0;
|
|
1260
1260
|
}
|
|
1261
1261
|
}
|
|
@@ -1268,8 +1268,8 @@ function er(l, s, t, e = {}, i = {}, o = 0, n = 1 / 0) {
|
|
|
1268
1268
|
for (let L = m, D = m + g; L < D; L++) {
|
|
1269
1269
|
const y = l.resolveTriangleIndex(L);
|
|
1270
1270
|
tt(E, 3 * y, c, a), E.needsUpdate = !0;
|
|
1271
|
-
const
|
|
1272
|
-
if (
|
|
1271
|
+
const x = E.distanceToTriangle(u, f, R);
|
|
1272
|
+
if (x < A && (T.copy(f), C && C.copy(R), A = x, F = L, p = _), x < o)
|
|
1273
1273
|
return !0;
|
|
1274
1274
|
}
|
|
1275
1275
|
}
|
|
@@ -1416,12 +1416,12 @@ function Tt(l, s, t, e, i, o = 0, n = 0, r = 0, a = 0, c = null, h = !1) {
|
|
|
1416
1416
|
else {
|
|
1417
1417
|
const y = vt.getPrimitive();
|
|
1418
1418
|
y.copy(Xs).applyMatrix4(t);
|
|
1419
|
-
const
|
|
1420
|
-
K(
|
|
1419
|
+
const x = pt(l), b = Ct(l, f);
|
|
1420
|
+
K(x, u, ae), K(b, u, ce);
|
|
1421
1421
|
const B = y.intersectsBox(ae), H = y.intersectsBox(ce);
|
|
1422
1422
|
S = B && Tt(
|
|
1423
1423
|
_,
|
|
1424
|
-
|
|
1424
|
+
x,
|
|
1425
1425
|
e,
|
|
1426
1426
|
t,
|
|
1427
1427
|
i,
|
|
@@ -1463,12 +1463,12 @@ function Tt(l, s, t, e, i, o = 0, n = 0, r = 0, a = 0, c = null, h = !1) {
|
|
|
1463
1463
|
else {
|
|
1464
1464
|
const y = vt.getPrimitive();
|
|
1465
1465
|
y.copy(Zs).applyMatrix4(t);
|
|
1466
|
-
const
|
|
1467
|
-
K(
|
|
1466
|
+
const x = pt(l), b = Ct(l, f);
|
|
1467
|
+
K(x, u, ae), K(b, u, ce);
|
|
1468
1468
|
const B = y.intersectsBox(ae), H = y.intersectsBox(ce);
|
|
1469
1469
|
S = B && Tt(
|
|
1470
1470
|
N,
|
|
1471
|
-
|
|
1471
|
+
x,
|
|
1472
1472
|
e,
|
|
1473
1473
|
t,
|
|
1474
1474
|
i,
|
|
@@ -2453,14 +2453,14 @@ function mr(l) {
|
|
|
2453
2453
|
g.elements[0] = R, g.elements[1] = C, g.elements[2] = A, g.elements[3] = C, g.elements[4] = F, g.elements[5] = p, g.elements[6] = A, g.elements[7] = p, g.elements[8] = m, Tr(g, e);
|
|
2454
2454
|
const S = e.unitary, _ = new O.Vector3(), N = new O.Vector3(), L = new O.Vector3();
|
|
2455
2455
|
S.extractBasis(_, N, L);
|
|
2456
|
-
let D = -1 / 0, y = -1 / 0,
|
|
2456
|
+
let D = -1 / 0, y = -1 / 0, x = -1 / 0, b = 1 / 0, B = 1 / 0, H = 1 / 0;
|
|
2457
2457
|
for (let it = 0, Xt = s.length; it < Xt; it++) {
|
|
2458
2458
|
const J = s[it];
|
|
2459
|
-
D = Math.max(_.dot(J), D), y = Math.max(N.dot(J), y),
|
|
2459
|
+
D = Math.max(_.dot(J), D), y = Math.max(N.dot(J), y), x = Math.max(L.dot(J), x), b = Math.min(_.dot(J), b), B = Math.min(N.dot(J), B), H = Math.min(L.dot(J), H);
|
|
2460
2460
|
}
|
|
2461
|
-
_.multiplyScalar(0.5 * (b + D)), N.multiplyScalar(0.5 * (B + y)), L.multiplyScalar(0.5 * (H +
|
|
2461
|
+
_.multiplyScalar(0.5 * (b + D)), N.multiplyScalar(0.5 * (B + y)), L.multiplyScalar(0.5 * (H + x));
|
|
2462
2462
|
const q = new O.Vector3(), st = new O.Vector3(), Q = new O.Matrix3();
|
|
2463
|
-
q.add(_).add(N).add(L), st.x = D - b, st.y = y - B, st.z =
|
|
2463
|
+
q.add(_).add(N).add(L), st.x = D - b, st.y = y - B, st.z = x - H, st.multiplyScalar(0.5), Q.copy(S);
|
|
2464
2464
|
const { x: Ht, y: Wt, z: kt } = st, ke = new O.Matrix4();
|
|
2465
2465
|
ke.makeScale(Ht * 2, Wt * 2, kt * 2);
|
|
2466
2466
|
const Te = new O.Matrix4();
|
|
@@ -3015,7 +3015,7 @@ const Fs = class Fs {
|
|
|
3015
3015
|
/**
|
|
3016
3016
|
* The version of the @thatopen/components library.
|
|
3017
3017
|
*/
|
|
3018
|
-
I(Fs, "release", "2.1.
|
|
3018
|
+
I(Fs, "release", "2.1.15");
|
|
3019
3019
|
let pi = Fs;
|
|
3020
3020
|
class Ar {
|
|
3021
3021
|
constructor(s) {
|
|
@@ -3497,8 +3497,8 @@ function rn(l, s, t, e, i = 1 / 0, o, n) {
|
|
|
3497
3497
|
h = l.x - u, d = l.y - f, E = l.z - T;
|
|
3498
3498
|
const g = (t.x + r * u) * o, S = (t.y + r * f) * o, _ = (t.z + r * T) * o;
|
|
3499
3499
|
t.x = (t.x - r * g) * c, t.y = (t.y - r * S) * c, t.z = (t.z - r * _) * c, n.x = h + (u + g) * c, n.y = d + (f + S) * c, n.z = E + (T + _) * c;
|
|
3500
|
-
const N = R - l.x, L = C - l.y, D = A - l.z, y = n.x - R,
|
|
3501
|
-
return N * y + L *
|
|
3500
|
+
const N = R - l.x, L = C - l.y, D = A - l.z, y = n.x - R, x = n.y - C, b = n.z - A;
|
|
3501
|
+
return N * y + L * x + D * b > 0 && (n.x = R, n.y = C, n.z = A, t.x = (n.x - R) / o, t.y = (n.y - C) / o, t.z = (n.z - A) / o), n;
|
|
3502
3502
|
}
|
|
3503
3503
|
function $s(l, s) {
|
|
3504
3504
|
s.set(0, 0), l.forEach((t) => {
|
|
@@ -3858,8 +3858,8 @@ class ot extends Or {
|
|
|
3858
3858
|
if ((this._state & P.TOUCH_DOLLY) === P.TOUCH_DOLLY || (this._state & P.TOUCH_ZOOM) === P.TOUCH_ZOOM || (this._state & P.TOUCH_DOLLY_TRUCK) === P.TOUCH_DOLLY_TRUCK || (this._state & P.TOUCH_ZOOM_TRUCK) === P.TOUCH_ZOOM_TRUCK || (this._state & P.TOUCH_DOLLY_OFFSET) === P.TOUCH_DOLLY_OFFSET || (this._state & P.TOUCH_ZOOM_OFFSET) === P.TOUCH_ZOOM_OFFSET || (this._state & P.TOUCH_DOLLY_ROTATE) === P.TOUCH_DOLLY_ROTATE || (this._state & P.TOUCH_ZOOM_ROTATE) === P.TOUCH_ZOOM_ROTATE) {
|
|
3859
3859
|
const _ = lt.x - this._activePointers[1].clientX, N = lt.y - this._activePointers[1].clientY, L = Math.sqrt(_ * _ + N * N), D = o.y - L;
|
|
3860
3860
|
o.set(0, L);
|
|
3861
|
-
const y = this.dollyToCursor ? (i.x - this._elementRect.x) / this._elementRect.width * 2 - 1 : 0,
|
|
3862
|
-
(this._state & P.TOUCH_DOLLY) === P.TOUCH_DOLLY || (this._state & P.TOUCH_DOLLY_ROTATE) === P.TOUCH_DOLLY_ROTATE || (this._state & P.TOUCH_DOLLY_TRUCK) === P.TOUCH_DOLLY_TRUCK || (this._state & P.TOUCH_DOLLY_OFFSET) === P.TOUCH_DOLLY_OFFSET ? (this._dollyInternal(D * Es, y,
|
|
3861
|
+
const y = this.dollyToCursor ? (i.x - this._elementRect.x) / this._elementRect.width * 2 - 1 : 0, x = this.dollyToCursor ? (i.y - this._elementRect.y) / this._elementRect.height * -2 + 1 : 0;
|
|
3862
|
+
(this._state & P.TOUCH_DOLLY) === P.TOUCH_DOLLY || (this._state & P.TOUCH_DOLLY_ROTATE) === P.TOUCH_DOLLY_ROTATE || (this._state & P.TOUCH_DOLLY_TRUCK) === P.TOUCH_DOLLY_TRUCK || (this._state & P.TOUCH_DOLLY_OFFSET) === P.TOUCH_DOLLY_OFFSET ? (this._dollyInternal(D * Es, y, x), this._isUserControllingDolly = !0) : (this._zoomInternal(D * Es, y, x), this._isUserControllingZoom = !0);
|
|
3863
3863
|
}
|
|
3864
3864
|
((this._state & P.TRUCK) === P.TRUCK || (this._state & P.TOUCH_TRUCK) === P.TOUCH_TRUCK || (this._state & P.TOUCH_DOLLY_TRUCK) === P.TOUCH_DOLLY_TRUCK || (this._state & P.TOUCH_ZOOM_TRUCK) === P.TOUCH_ZOOM_TRUCK) && (this._truckInternal(g, S, !1), this._isUserControllingTruck = !0), ((this._state & P.OFFSET) === P.OFFSET || (this._state & P.TOUCH_OFFSET) === P.TOUCH_OFFSET || (this._state & P.TOUCH_DOLLY_OFFSET) === P.TOUCH_DOLLY_OFFSET || (this._state & P.TOUCH_ZOOM_OFFSET) === P.TOUCH_ZOOM_OFFSET) && (this._truckInternal(g, S, !0), this._isUserControllingOffset = !0), this.dispatchEvent({ type: "control" });
|
|
3865
3865
|
}, C = () => {
|
|
@@ -5582,7 +5582,7 @@ class xr extends ri {
|
|
|
5582
5582
|
XYZ: [
|
|
5583
5583
|
[new v(new rt(0.2, 0.2, 0.2), e), [0, 0, 0]]
|
|
5584
5584
|
]
|
|
5585
|
-
},
|
|
5585
|
+
}, x = {
|
|
5586
5586
|
X: [
|
|
5587
5587
|
[new Dt(C, i.clone()), [-1e3, 0, 0], null, [1e6, 1, 1], "helper"]
|
|
5588
5588
|
],
|
|
@@ -5604,7 +5604,7 @@ class xr extends ri {
|
|
|
5604
5604
|
}
|
|
5605
5605
|
return H;
|
|
5606
5606
|
}
|
|
5607
|
-
this.gizmo = {}, this.picker = {}, this.helper = {}, this.add(this.gizmo.translate = b(m)), this.add(this.gizmo.rotate = b(_)), this.add(this.gizmo.scale = b(D)), this.add(this.picker.translate = b(g)), this.add(this.picker.rotate = b(L)), this.add(this.picker.scale = b(y)), this.add(this.helper.translate = b(S)), this.add(this.helper.rotate = b(N)), this.add(this.helper.scale = b(
|
|
5607
|
+
this.gizmo = {}, this.picker = {}, this.helper = {}, this.add(this.gizmo.translate = b(m)), this.add(this.gizmo.rotate = b(_)), this.add(this.gizmo.scale = b(D)), this.add(this.picker.translate = b(g)), this.add(this.picker.rotate = b(L)), this.add(this.picker.scale = b(y)), this.add(this.helper.translate = b(S)), this.add(this.helper.rotate = b(N)), this.add(this.helper.scale = b(x)), this.picker.translate.visible = !1, this.picker.rotate.visible = !1, this.picker.scale.visible = !1;
|
|
5608
5608
|
}
|
|
5609
5609
|
// updateMatrixWorld will update transformations and appearance of individual handles
|
|
5610
5610
|
updateMatrixWorld(s) {
|
|
@@ -6915,60 +6915,74 @@ class aa extends We {
|
|
|
6915
6915
|
}
|
|
6916
6916
|
const Zr = /* @__PURE__ */ new Map([
|
|
6917
6917
|
[
|
|
6918
|
-
|
|
6918
|
+
U.IFCRELAGGREGATES,
|
|
6919
6919
|
{
|
|
6920
6920
|
forRelating: "IsDecomposedBy",
|
|
6921
6921
|
forRelated: "Decomposes"
|
|
6922
6922
|
}
|
|
6923
6923
|
],
|
|
6924
6924
|
[
|
|
6925
|
-
|
|
6925
|
+
U.IFCRELASSOCIATESMATERIAL,
|
|
6926
6926
|
{
|
|
6927
6927
|
forRelating: "AssociatedTo",
|
|
6928
6928
|
forRelated: "HasAssociations"
|
|
6929
6929
|
}
|
|
6930
6930
|
],
|
|
6931
6931
|
[
|
|
6932
|
-
|
|
6932
|
+
U.IFCRELASSOCIATESCLASSIFICATION,
|
|
6933
6933
|
{
|
|
6934
6934
|
forRelating: "ClassificationForObjects",
|
|
6935
6935
|
forRelated: "HasAssociations"
|
|
6936
6936
|
}
|
|
6937
6937
|
],
|
|
6938
6938
|
[
|
|
6939
|
-
|
|
6939
|
+
U.IFCRELASSIGNSTOGROUP,
|
|
6940
6940
|
{
|
|
6941
6941
|
forRelating: "IsGroupedBy",
|
|
6942
6942
|
forRelated: "HasAssignments"
|
|
6943
6943
|
}
|
|
6944
6944
|
],
|
|
6945
6945
|
[
|
|
6946
|
-
|
|
6946
|
+
U.IFCRELDEFINESBYPROPERTIES,
|
|
6947
6947
|
{
|
|
6948
6948
|
forRelated: "IsDefinedBy",
|
|
6949
6949
|
forRelating: "DefinesOcurrence"
|
|
6950
6950
|
}
|
|
6951
6951
|
],
|
|
6952
6952
|
[
|
|
6953
|
-
|
|
6953
|
+
U.IFCRELDEFINESBYTYPE,
|
|
6954
6954
|
{
|
|
6955
6955
|
forRelated: "IsTypedBy",
|
|
6956
6956
|
forRelating: "Types"
|
|
6957
6957
|
}
|
|
6958
6958
|
],
|
|
6959
6959
|
[
|
|
6960
|
-
|
|
6960
|
+
U.IFCRELDEFINESBYTEMPLATE,
|
|
6961
6961
|
{
|
|
6962
6962
|
forRelated: "IsDefinedBy",
|
|
6963
6963
|
forRelating: "Defines"
|
|
6964
6964
|
}
|
|
6965
6965
|
],
|
|
6966
6966
|
[
|
|
6967
|
-
|
|
6967
|
+
U.IFCRELCONTAINEDINSPATIALSTRUCTURE,
|
|
6968
6968
|
{
|
|
6969
6969
|
forRelated: "ContainedInStructure",
|
|
6970
6970
|
forRelating: "ContainsElements"
|
|
6971
6971
|
}
|
|
6972
|
+
],
|
|
6973
|
+
[
|
|
6974
|
+
U.IFCRELFLOWCONTROLELEMENTS,
|
|
6975
|
+
{
|
|
6976
|
+
forRelated: "AssignedToFlowElement",
|
|
6977
|
+
forRelating: "HasControlElements"
|
|
6978
|
+
}
|
|
6979
|
+
],
|
|
6980
|
+
[
|
|
6981
|
+
U.IFCRELCONNECTSELEMENTS,
|
|
6982
|
+
{
|
|
6983
|
+
forRelated: "ConnectedFrom",
|
|
6984
|
+
forRelating: "ConnectedTo"
|
|
6985
|
+
}
|
|
6972
6986
|
]
|
|
6973
6987
|
]), Ve = class Ve extends et {
|
|
6974
6988
|
constructor(t) {
|
|
@@ -7010,17 +7024,21 @@ const Zr = /* @__PURE__ */ new Map([
|
|
|
7010
7024
|
"Types",
|
|
7011
7025
|
"Defines",
|
|
7012
7026
|
"ContainedInStructure",
|
|
7013
|
-
"ContainsElements"
|
|
7027
|
+
"ContainsElements",
|
|
7028
|
+
"HasControlElements",
|
|
7029
|
+
"AssignedToFlowElement",
|
|
7030
|
+
"ConnectedTo",
|
|
7031
|
+
"ConnectedFrom"
|
|
7014
7032
|
]);
|
|
7015
7033
|
I(this, "_ifcRels", [
|
|
7016
|
-
|
|
7017
|
-
|
|
7018
|
-
|
|
7019
|
-
|
|
7020
|
-
|
|
7021
|
-
|
|
7022
|
-
|
|
7023
|
-
|
|
7034
|
+
U.IFCRELAGGREGATES,
|
|
7035
|
+
U.IFCRELASSOCIATESMATERIAL,
|
|
7036
|
+
U.IFCRELASSOCIATESCLASSIFICATION,
|
|
7037
|
+
U.IFCRELASSIGNSTOGROUP,
|
|
7038
|
+
U.IFCRELDEFINESBYPROPERTIES,
|
|
7039
|
+
U.IFCRELDEFINESBYTYPE,
|
|
7040
|
+
U.IFCRELDEFINESBYTEMPLATE,
|
|
7041
|
+
U.IFCRELCONTAINEDINSPATIALSTRUCTURE
|
|
7024
7042
|
]);
|
|
7025
7043
|
I(this, "onFragmentsDisposed", (t) => {
|
|
7026
7044
|
delete this.relationMaps[t.groupID];
|
|
@@ -7893,11 +7911,11 @@ const vn = /* @__PURE__ */ new Set([
|
|
|
7893
7911
|
*/
|
|
7894
7912
|
async export(t, e, i = !1, o = !0) {
|
|
7895
7913
|
const n = {}, r = new Set(t.GetIfcEntityList(e)), a = /* @__PURE__ */ new Set([
|
|
7896
|
-
|
|
7897
|
-
|
|
7898
|
-
|
|
7899
|
-
|
|
7900
|
-
|
|
7914
|
+
U.IFCPROJECT,
|
|
7915
|
+
U.IFCSITE,
|
|
7916
|
+
U.IFCBUILDING,
|
|
7917
|
+
U.IFCBUILDINGSTOREY,
|
|
7918
|
+
U.IFCSPACE
|
|
7901
7919
|
]);
|
|
7902
7920
|
for (const c of a)
|
|
7903
7921
|
r.add(c);
|
|
@@ -9214,7 +9232,7 @@ const Bn = {
|
|
|
9214
9232
|
class Kt {
|
|
9215
9233
|
static async getUnits(s) {
|
|
9216
9234
|
var n, r, a;
|
|
9217
|
-
const { IFCUNITASSIGNMENT: t } =
|
|
9235
|
+
const { IFCUNITASSIGNMENT: t } = U, e = await s.getAllPropertiesOfType(t);
|
|
9218
9236
|
if (!e)
|
|
9219
9237
|
return 1;
|
|
9220
9238
|
const i = Object.keys(e), o = e[parseInt(i[0], 10)];
|
|
@@ -9265,19 +9283,19 @@ class Kt {
|
|
|
9265
9283
|
static async getQsetQuantities(s, t, e) {
|
|
9266
9284
|
const o = e ?? (() => {
|
|
9267
9285
|
}), n = await s.getProperties(t);
|
|
9268
|
-
return !n || n.type !==
|
|
9286
|
+
return !n || n.type !== U.IFCELEMENTQUANTITY ? null : (n.Quantities ?? [{}]).map((c) => (c.value && o(c.value), c.value)).filter((c) => c !== null);
|
|
9269
9287
|
}
|
|
9270
9288
|
static async getPsetProps(s, t, e) {
|
|
9271
9289
|
const o = e ?? (() => {
|
|
9272
9290
|
}), n = await s.getProperties(t);
|
|
9273
|
-
return !n || n.type !==
|
|
9291
|
+
return !n || n.type !== U.IFCPROPERTYSET ? null : (n.HasProperties ?? [{}]).map((c) => (c.value && o(c.value), c.value)).filter((c) => c !== null);
|
|
9274
9292
|
}
|
|
9275
9293
|
static async getPsetRel(s, t) {
|
|
9276
9294
|
var r;
|
|
9277
9295
|
if (!await s.getProperties(t))
|
|
9278
9296
|
return null;
|
|
9279
9297
|
const i = await s.getAllPropertiesOfType(
|
|
9280
|
-
|
|
9298
|
+
U.IFCRELDEFINESBYPROPERTIES
|
|
9281
9299
|
);
|
|
9282
9300
|
if (!i)
|
|
9283
9301
|
return null;
|
|
@@ -9368,7 +9386,7 @@ class jr {
|
|
|
9368
9386
|
try {
|
|
9369
9387
|
const e = s.GetLineIDsWithType(
|
|
9370
9388
|
0,
|
|
9371
|
-
|
|
9389
|
+
U.IFCUNITASSIGNMENT
|
|
9372
9390
|
).get(0), i = s.GetLine(0, e);
|
|
9373
9391
|
for (const o of i.Units) {
|
|
9374
9392
|
if (!o || o.value === null || o.value === void 0)
|
|
@@ -9415,11 +9433,11 @@ class Yn {
|
|
|
9415
9433
|
try {
|
|
9416
9434
|
const t = s.GetLineIDsWithType(
|
|
9417
9435
|
0,
|
|
9418
|
-
|
|
9419
|
-
), e = /* @__PURE__ */ new Set(), i = s.GetLineIDsWithType(0,
|
|
9436
|
+
U.IFCRELCONTAINEDINSPATIALSTRUCTURE
|
|
9437
|
+
), e = /* @__PURE__ */ new Set(), i = s.GetLineIDsWithType(0, U.IFCSPACE);
|
|
9420
9438
|
for (let c = 0; c < i.size(); c++)
|
|
9421
9439
|
e.add(i.get(c));
|
|
9422
|
-
const o = s.GetLineIDsWithType(0,
|
|
9440
|
+
const o = s.GetLineIDsWithType(0, U.IFCRELAGGREGATES), n = o.size();
|
|
9423
9441
|
for (let c = 0; c < n; c++) {
|
|
9424
9442
|
const h = o.get(c), d = s.GetLine(0, h);
|
|
9425
9443
|
if (!d || !d.RelatingObject || !d.RelatedObjects)
|
|
@@ -9482,14 +9500,14 @@ class Li {
|
|
|
9482
9500
|
* Generate the geometry for categories that are not included by default,
|
|
9483
9501
|
* like IFCSPACE.
|
|
9484
9502
|
*/
|
|
9485
|
-
I(this, "optionalCategories", [
|
|
9503
|
+
I(this, "optionalCategories", [U.IFCSPACE]);
|
|
9486
9504
|
/** Whether to use the coordination data coming from the IFC files. */
|
|
9487
9505
|
I(this, "coordinate", !0);
|
|
9488
9506
|
/** Path of the WASM for [web-ifc](https://github.com/ThatOpen/engine_web-ifc). */
|
|
9489
9507
|
I(this, "wasm", {
|
|
9490
9508
|
path: "",
|
|
9491
9509
|
absolute: !1,
|
|
9492
|
-
logLevel:
|
|
9510
|
+
logLevel: U.LogLevel.LOG_LEVEL_OFF
|
|
9493
9511
|
});
|
|
9494
9512
|
/** List of categories that won't be converted to fragments. */
|
|
9495
9513
|
I(this, "excludedCategories", /* @__PURE__ */ new Set());
|
|
@@ -9572,7 +9590,7 @@ class Vn {
|
|
|
9572
9590
|
class Gn {
|
|
9573
9591
|
getNameInfo(s) {
|
|
9574
9592
|
var d;
|
|
9575
|
-
const t = {}, { arguments: e } = s.GetHeaderLine(0,
|
|
9593
|
+
const t = {}, { arguments: e } = s.GetHeaderLine(0, U.FILE_NAME) || {};
|
|
9576
9594
|
if (!e)
|
|
9577
9595
|
return t;
|
|
9578
9596
|
const [
|
|
@@ -9593,7 +9611,7 @@ class Gn {
|
|
|
9593
9611
|
}
|
|
9594
9612
|
getDescriptionInfo(s) {
|
|
9595
9613
|
var n;
|
|
9596
|
-
const t = {}, { arguments: e } = s.GetHeaderLine(0,
|
|
9614
|
+
const t = {}, { arguments: e } = s.GetHeaderLine(0, U.FILE_DESCRIPTION) || {};
|
|
9597
9615
|
if (!e)
|
|
9598
9616
|
return t;
|
|
9599
9617
|
const [i, o] = e;
|
|
@@ -9607,15 +9625,15 @@ class Gn {
|
|
|
9607
9625
|
class zn {
|
|
9608
9626
|
static get(s, t) {
|
|
9609
9627
|
const e = [
|
|
9610
|
-
|
|
9611
|
-
|
|
9612
|
-
|
|
9613
|
-
|
|
9614
|
-
|
|
9615
|
-
|
|
9616
|
-
|
|
9617
|
-
|
|
9618
|
-
|
|
9628
|
+
U.IFCPROJECT,
|
|
9629
|
+
U.IFCSITE,
|
|
9630
|
+
U.IFCBUILDING,
|
|
9631
|
+
U.IFCBUILDINGSTOREY,
|
|
9632
|
+
U.IFCSPACE,
|
|
9633
|
+
U.IFCROAD,
|
|
9634
|
+
U.IFCFACILITY,
|
|
9635
|
+
U.IFCFACILITYPART,
|
|
9636
|
+
U.IFCBRIDGE
|
|
9619
9637
|
], i = s.data;
|
|
9620
9638
|
for (const o of e) {
|
|
9621
9639
|
const n = t.GetLineIDsWithType(0, o), r = n.size();
|
|
@@ -9647,7 +9665,7 @@ const Ge = class Ge extends et {
|
|
|
9647
9665
|
/**
|
|
9648
9666
|
* The instance of the Web-IFC library used for handling IFC data.
|
|
9649
9667
|
*/
|
|
9650
|
-
I(this, "webIfc", new
|
|
9668
|
+
I(this, "webIfc", new U.IfcAPI());
|
|
9651
9669
|
/** {@link Component.enabled} */
|
|
9652
9670
|
I(this, "enabled", !0);
|
|
9653
9671
|
I(this, "_material", new O.MeshLambertMaterial());
|
|
@@ -9660,7 +9678,7 @@ const Ge = class Ge extends et {
|
|
|
9660
9678
|
transparent: !0,
|
|
9661
9679
|
opacity: 0.5
|
|
9662
9680
|
}));
|
|
9663
|
-
this.components.add(Ge.uuid, this), this.settings.excludedCategories.add(
|
|
9681
|
+
this.components.add(Ge.uuid, this), this.settings.excludedCategories.add(U.IFCOPENINGELEMENT);
|
|
9664
9682
|
}
|
|
9665
9683
|
/** {@link Disposable.dispose} */
|
|
9666
9684
|
dispose() {
|
|
@@ -9755,7 +9773,7 @@ const Ge = class Ge extends et {
|
|
|
9755
9773
|
* ```
|
|
9756
9774
|
*/
|
|
9757
9775
|
cleanUp() {
|
|
9758
|
-
this.webIfc.Dispose(), this.webIfc = null, this.webIfc = new
|
|
9776
|
+
this.webIfc.Dispose(), this.webIfc = null, this.webIfc = new U.IfcAPI(), this._visitedFragments.clear(), this._fragmentInstances.clear();
|
|
9759
9777
|
}
|
|
9760
9778
|
async getAllGeometries() {
|
|
9761
9779
|
this._spatialTree.setUp(this.webIfc);
|
|
@@ -9770,7 +9788,7 @@ const Ge = class Ge extends et {
|
|
|
9770
9788
|
};
|
|
9771
9789
|
const i = [];
|
|
9772
9790
|
for (const n of t) {
|
|
9773
|
-
if (!this.webIfc.IsIfcElement(n) && n !==
|
|
9791
|
+
if (!this.webIfc.IsIfcElement(n) && n !== U.IFCSPACE || this.settings.excludedCategories.has(n))
|
|
9774
9792
|
continue;
|
|
9775
9793
|
const r = this.webIfc.GetLineIDsWithType(0, n), a = r.size();
|
|
9776
9794
|
for (let c = 0; c < a; c++) {
|
|
@@ -9972,7 +9990,7 @@ const Bt = class Bt extends et {
|
|
|
9972
9990
|
* @throws Will throw an error if no OwnerHistory is found in the model.
|
|
9973
9991
|
*/
|
|
9974
9992
|
async newPset(t, e, i) {
|
|
9975
|
-
const o = Bt.getIFCSchema(t), { ownerHistoryHandle: n } = await this.getOwnerHistory(t), r = this.newGUID(t), a = new
|
|
9993
|
+
const o = Bt.getIFCSchema(t), { ownerHistoryHandle: n } = await this.getOwnerHistory(t), r = this.newGUID(t), a = new U[o].IfcLabel(e), c = i ? new U[o].IfcText(i) : null, h = new U[o].IfcPropertySet(
|
|
9976
9994
|
r,
|
|
9977
9995
|
n,
|
|
9978
9996
|
a,
|
|
@@ -9980,13 +9998,13 @@ const Bt = class Bt extends et {
|
|
|
9980
9998
|
[]
|
|
9981
9999
|
);
|
|
9982
10000
|
h.expressID = this.increaseMaxID(t);
|
|
9983
|
-
const d = this.newGUID(t), E = new
|
|
10001
|
+
const d = this.newGUID(t), E = new U[o].IfcRelDefinesByProperties(
|
|
9984
10002
|
d,
|
|
9985
10003
|
n,
|
|
9986
10004
|
null,
|
|
9987
10005
|
null,
|
|
9988
10006
|
[],
|
|
9989
|
-
new
|
|
10007
|
+
new U.Handle(h.expressID)
|
|
9990
10008
|
);
|
|
9991
10009
|
return E.expressID = this.increaseMaxID(t), await this.setData(t, h, E), { pset: h, rel: E };
|
|
9992
10010
|
}
|
|
@@ -10005,7 +10023,7 @@ const Bt = class Bt extends et {
|
|
|
10005
10023
|
async removePset(t, ...e) {
|
|
10006
10024
|
for (const i of e) {
|
|
10007
10025
|
const o = await t.getProperties(i);
|
|
10008
|
-
if ((o == null ? void 0 : o.type) !==
|
|
10026
|
+
if ((o == null ? void 0 : o.type) !== U.IFCPROPERTYSET)
|
|
10009
10027
|
continue;
|
|
10010
10028
|
const n = await Kt.getPsetRel(t, i);
|
|
10011
10029
|
if (n && (await t.setProperties(n, null), this.registerChange(t, n)), o) {
|
|
@@ -10077,7 +10095,7 @@ const Bt = class Bt extends et {
|
|
|
10077
10095
|
*/
|
|
10078
10096
|
async removePsetProp(t, e, i) {
|
|
10079
10097
|
const o = await t.getProperties(e), n = await t.getProperties(i);
|
|
10080
|
-
!o || !n || o.type ===
|
|
10098
|
+
!o || !n || o.type === U.IFCPROPERTYSET && n && (o.HasProperties = o.HasProperties.filter((r) => r.value !== i), await t.setProperties(i, null), this.registerChange(t, e, i));
|
|
10081
10099
|
}
|
|
10082
10100
|
async addElementToPset(t, e, ...i) {
|
|
10083
10101
|
const o = await Kt.getPsetRel(t, e);
|
|
@@ -10087,7 +10105,7 @@ const Bt = class Bt extends et {
|
|
|
10087
10105
|
if (!n)
|
|
10088
10106
|
return;
|
|
10089
10107
|
for (const a of i) {
|
|
10090
|
-
const c = new
|
|
10108
|
+
const c = new U.Handle(a);
|
|
10091
10109
|
n.RelatedObjects.push(c), this.onElementToPset.trigger({
|
|
10092
10110
|
model: t,
|
|
10093
10111
|
psetID: e,
|
|
@@ -10118,7 +10136,7 @@ const Bt = class Bt extends et {
|
|
|
10118
10136
|
for (const n of i) {
|
|
10119
10137
|
if (o.HasProperties.includes(n))
|
|
10120
10138
|
continue;
|
|
10121
|
-
const r = new
|
|
10139
|
+
const r = new U.Handle(n);
|
|
10122
10140
|
o.HasProperties.push(r), this.onPropToPset.trigger({ model: t, psetID: e, propID: n });
|
|
10123
10141
|
}
|
|
10124
10142
|
this.registerChange(t, e);
|
|
@@ -10197,15 +10215,15 @@ const Bt = class Bt extends et {
|
|
|
10197
10215
|
}
|
|
10198
10216
|
newGUID(t) {
|
|
10199
10217
|
const e = Bt.getIFCSchema(t);
|
|
10200
|
-
return new
|
|
10218
|
+
return new U[e].IfcGloballyUniqueId(ze.create());
|
|
10201
10219
|
}
|
|
10202
10220
|
async getOwnerHistory(t) {
|
|
10203
10221
|
const e = await t.getAllPropertiesOfType(
|
|
10204
|
-
|
|
10222
|
+
U.IFCOWNERHISTORY
|
|
10205
10223
|
);
|
|
10206
10224
|
if (!e)
|
|
10207
10225
|
throw new Error("No OwnerHistory was found.");
|
|
10208
|
-
const i = Object.keys(e).map((r) => parseInt(r, 10)), o = e[i[0]], n = new
|
|
10226
|
+
const i = Object.keys(e).map((r) => parseInt(r, 10)), o = e[i[0]], n = new U.Handle(o.expressID);
|
|
10209
10227
|
return { ownerHistory: o, ownerHistoryHandle: n };
|
|
10210
10228
|
}
|
|
10211
10229
|
registerChange(t, ...e) {
|
|
@@ -10214,7 +10232,7 @@ const Bt = class Bt extends et {
|
|
|
10214
10232
|
this.changeMap[t.uuid].add(i), this.onDataChanged.trigger({ model: t, expressID: i });
|
|
10215
10233
|
}
|
|
10216
10234
|
async newSingleProperty(t, e, i, o) {
|
|
10217
|
-
const n = Bt.getIFCSchema(t), r = new
|
|
10235
|
+
const n = Bt.getIFCSchema(t), r = new U[n].IfcIdentifier(i), a = new U[n][e](o), c = new U[n].IfcPropertySingleValue(
|
|
10218
10236
|
r,
|
|
10219
10237
|
null,
|
|
10220
10238
|
a,
|
|
@@ -10761,7 +10779,7 @@ const ws = class ws extends et {
|
|
|
10761
10779
|
/**
|
|
10762
10780
|
* The WebIFC API instance used for IFC file processing.
|
|
10763
10781
|
*/
|
|
10764
|
-
I(this, "webIfc", new
|
|
10782
|
+
I(this, "webIfc", new U.IfcAPI());
|
|
10765
10783
|
I(this, "_spatialTree", new Yn());
|
|
10766
10784
|
I(this, "_metaData", new Gn());
|
|
10767
10785
|
I(this, "_visitedGeometries", /* @__PURE__ */ new Map());
|
|
@@ -10772,7 +10790,7 @@ const ws = class ws extends et {
|
|
|
10772
10790
|
I(this, "_groupSerializer", new Vt.Serializer());
|
|
10773
10791
|
I(this, "_assets", []);
|
|
10774
10792
|
I(this, "_meshesWithHoles", /* @__PURE__ */ new Set());
|
|
10775
|
-
this.components.add(ws.uuid, this), this.settings.excludedCategories.add(
|
|
10793
|
+
this.components.add(ws.uuid, this), this.settings.excludedCategories.add(U.IFCOPENINGELEMENT);
|
|
10776
10794
|
}
|
|
10777
10795
|
/** {@link Disposable.dispose} */
|
|
10778
10796
|
dispose() {
|
|
@@ -10833,7 +10851,7 @@ const ws = class ws extends et {
|
|
|
10833
10851
|
};
|
|
10834
10852
|
let r = 0, a = 0;
|
|
10835
10853
|
for (const T of i) {
|
|
10836
|
-
if (!this.webIfc.IsIfcElement(T) && T !==
|
|
10854
|
+
if (!this.webIfc.IsIfcElement(T) && T !== U.IFCSPACE || this.settings.excludedCategories.has(T))
|
|
10837
10855
|
continue;
|
|
10838
10856
|
const R = this.webIfc.GetLineIDsWithType(0, T), C = R.size();
|
|
10839
10857
|
for (let A = 0; A < C; A++) {
|
|
@@ -10869,7 +10887,7 @@ const ws = class ws extends et {
|
|
|
10869
10887
|
this.onIfcLoaded.trigger(f), n.dispose(!0);
|
|
10870
10888
|
}
|
|
10871
10889
|
cleanUp() {
|
|
10872
|
-
this.webIfc.Dispose(), this.webIfc = null, this.webIfc = new
|
|
10890
|
+
this.webIfc.Dispose(), this.webIfc = null, this.webIfc = new U.IfcAPI(), this._visitedGeometries.clear(), this._geometries.clear(), this._assets = [], this._meshesWithHoles.clear();
|
|
10873
10891
|
}
|
|
10874
10892
|
getMesh(t, e, i) {
|
|
10875
10893
|
const o = e.geometries.size(), n = e.expressID, r = { id: n, geometries: [] };
|
|
@@ -10974,7 +10992,7 @@ class $r extends et {
|
|
|
10974
10992
|
/**
|
|
10975
10993
|
* An instance of the IfcAPI class from the Web-IFC library, which provides methods for reading and processing IFC data.
|
|
10976
10994
|
*/
|
|
10977
|
-
I(this, "webIfc", new
|
|
10995
|
+
I(this, "webIfc", new U.IfcAPI());
|
|
10978
10996
|
}
|
|
10979
10997
|
/** {@link Disposable.dispose} */
|
|
10980
10998
|
async dispose() {
|
|
@@ -11008,11 +11026,11 @@ class $r extends et {
|
|
|
11008
11026
|
}
|
|
11009
11027
|
async streamAllProperties() {
|
|
11010
11028
|
const { propertiesSize: t } = this.settings, e = new Set(this.webIfc.GetIfcEntityList(0)), i = /* @__PURE__ */ new Set([
|
|
11011
|
-
|
|
11012
|
-
|
|
11013
|
-
|
|
11014
|
-
|
|
11015
|
-
|
|
11029
|
+
U.IFCPROJECT,
|
|
11030
|
+
U.IFCSITE,
|
|
11031
|
+
U.IFCBUILDING,
|
|
11032
|
+
U.IFCBUILDINGSTOREY,
|
|
11033
|
+
U.IFCSPACE
|
|
11016
11034
|
]);
|
|
11017
11035
|
for (const c of i)
|
|
11018
11036
|
e.add(c);
|
|
@@ -11056,7 +11074,7 @@ class $r extends et {
|
|
|
11056
11074
|
await this.onIndicesStreamed.trigger(a);
|
|
11057
11075
|
}
|
|
11058
11076
|
cleanUp() {
|
|
11059
|
-
this.webIfc.Dispose(), this.webIfc = null, this.webIfc = new
|
|
11077
|
+
this.webIfc.Dispose(), this.webIfc = null, this.webIfc = new U.IfcAPI();
|
|
11060
11078
|
}
|
|
11061
11079
|
}
|
|
11062
11080
|
/**
|