@thatopen/components 2.1.16 → 2.1.17
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/core/Types/src/data-map.d.ts +42 -0
- package/dist/core/Types/src/data-set.d.ts +38 -0
- package/dist/fragments/FragmentsManager/index.d.ts +13 -5
- package/dist/index.cjs +5 -5
- package/dist/index.mjs +383 -301
- package/dist/namespace.d.ts +2335 -2247
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -1,39 +1,39 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var I = (l, s, t) => (
|
|
1
|
+
var Xn = Object.defineProperty;
|
|
2
|
+
var Zn = (l, s, t) => s in l ? Xn(l, s, { enumerable: !0, configurable: !0, writable: !0, value: t }) : l[s] = t;
|
|
3
|
+
var I = (l, s, t) => (Zn(l, typeof s != "symbol" ? s + "" : s, t), t);
|
|
4
4
|
import * as O from "three";
|
|
5
|
-
import { BufferAttribute as
|
|
5
|
+
import { BufferAttribute as Ln, Vector3 as M, Vector2 as fe, Plane as Fi, Line3 as Lt, Triangle as ue, Sphere as Qn, Matrix4 as yt, Box3 as gt, BackSide as jn, DoubleSide as yn, FrontSide as wi, Mesh as v, Ray as qn, Raycaster as Kn, Quaternion as Pt, Object3D as ri, Euler as $n, MeshBasicMaterial as Mn, LineBasicMaterial as Jn, CylinderGeometry as ct, BoxGeometry as rt, BufferGeometry as Di, Float32BufferAttribute as Ui, OctahedronGeometry as Ze, Line as Dt, SphereGeometry as to, TorusGeometry as Re, PlaneGeometry as eo } from "three";
|
|
6
6
|
import * as Vt from "@thatopen/fragments";
|
|
7
|
-
import { Serializer as
|
|
7
|
+
import { Serializer as so } from "@thatopen/fragments";
|
|
8
8
|
import * as U from "web-ifc";
|
|
9
|
-
const
|
|
10
|
-
function
|
|
9
|
+
const wn = 0, io = 1, no = 2, xi = 2, Ys = 1.25, bi = 1, Cs = 6 * 4 + 4 + 4, Us = 65535, oo = Math.pow(2, -24), Vs = Symbol("SKIP_GENERATION");
|
|
10
|
+
function ro(l) {
|
|
11
11
|
return l.index ? l.index.count : l.attributes.position.count;
|
|
12
12
|
}
|
|
13
13
|
function Ce(l) {
|
|
14
|
-
return
|
|
14
|
+
return ro(l) / 3;
|
|
15
15
|
}
|
|
16
|
-
function
|
|
16
|
+
function ao(l, s = ArrayBuffer) {
|
|
17
17
|
return l > 65535 ? new Uint32Array(new s(4 * l)) : new Uint16Array(new s(2 * l));
|
|
18
18
|
}
|
|
19
|
-
function
|
|
19
|
+
function co(l, s) {
|
|
20
20
|
if (!l.index) {
|
|
21
|
-
const t = l.attributes.position.count, e = s.useSharedArrayBuffer ? SharedArrayBuffer : ArrayBuffer, i =
|
|
22
|
-
l.setIndex(new
|
|
21
|
+
const t = l.attributes.position.count, e = s.useSharedArrayBuffer ? SharedArrayBuffer : ArrayBuffer, i = ao(t, e);
|
|
22
|
+
l.setIndex(new Ln(i, 1));
|
|
23
23
|
for (let o = 0; o < t; o++)
|
|
24
24
|
i[o] = o;
|
|
25
25
|
}
|
|
26
26
|
}
|
|
27
|
-
function
|
|
27
|
+
function Dn(l) {
|
|
28
28
|
const s = Ce(l), t = l.drawRange, e = t.start / 3, i = (t.start + t.count) / 3, o = Math.max(0, e), n = Math.min(s, i) - o;
|
|
29
29
|
return [{
|
|
30
30
|
offset: Math.floor(o),
|
|
31
31
|
count: Math.floor(n)
|
|
32
32
|
}];
|
|
33
33
|
}
|
|
34
|
-
function
|
|
34
|
+
function Un(l) {
|
|
35
35
|
if (!l.groups || !l.groups.length)
|
|
36
|
-
return
|
|
36
|
+
return Dn(l);
|
|
37
37
|
const s = [], t = /* @__PURE__ */ new Set(), e = l.drawRange, i = e.start / 3, o = (e.start + e.count) / 3;
|
|
38
38
|
for (const r of l.groups) {
|
|
39
39
|
const a = r.start / 3, c = (r.start + r.count) / 3;
|
|
@@ -49,10 +49,10 @@ function Dn(l) {
|
|
|
49
49
|
}
|
|
50
50
|
return s;
|
|
51
51
|
}
|
|
52
|
-
function
|
|
52
|
+
function lo(l) {
|
|
53
53
|
if (l.groups.length === 0)
|
|
54
54
|
return !1;
|
|
55
|
-
const s = Ce(l), t =
|
|
55
|
+
const s = Ce(l), t = Un(l).sort((o, n) => o.offset - n.offset), e = t[t.length - 1];
|
|
56
56
|
e.count = Math.min(s - e.offset, e.count);
|
|
57
57
|
let i = 0;
|
|
58
58
|
return t.forEach(({ count: o }) => i += o), s !== i;
|
|
@@ -60,7 +60,7 @@ function co(l) {
|
|
|
60
60
|
function K(l, s, t) {
|
|
61
61
|
return t.min.x = s[l], t.min.y = s[l + 1], t.min.z = s[l + 2], t.max.x = s[l + 3], t.max.y = s[l + 4], t.max.z = s[l + 5], t;
|
|
62
62
|
}
|
|
63
|
-
function
|
|
63
|
+
function ho(l) {
|
|
64
64
|
l[0] = l[1] = l[2] = 1 / 0, l[3] = l[4] = l[5] = -1 / 0;
|
|
65
65
|
}
|
|
66
66
|
function vi(l) {
|
|
@@ -104,7 +104,7 @@ function Gs(l, s, t, e, i = null) {
|
|
|
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);
|
|
106
106
|
}
|
|
107
|
-
function
|
|
107
|
+
function Eo(l, s, t, e) {
|
|
108
108
|
let i = 1 / 0, o = 1 / 0, n = 1 / 0, r = -1 / 0, a = -1 / 0, c = -1 / 0;
|
|
109
109
|
for (let h = s * 6, d = (s + t) * 6; h < d; h += 6) {
|
|
110
110
|
const E = l[h + 0];
|
|
@@ -116,8 +116,8 @@ function ho(l, s, t, e) {
|
|
|
116
116
|
}
|
|
117
117
|
e[0] = i, e[1] = o, e[2] = n, e[3] = r, e[4] = a, e[5] = c;
|
|
118
118
|
}
|
|
119
|
-
function
|
|
120
|
-
|
|
119
|
+
function uo(l, s) {
|
|
120
|
+
ho(s);
|
|
121
121
|
const t = l.attributes.position, e = l.index ? l.index.array : null, i = Ce(l), o = new Float32Array(i * 6), n = t.normalized, r = t.array, a = t.offset || 0;
|
|
122
122
|
let c = 3;
|
|
123
123
|
t.isInterleavedBufferAttribute && (c = t.data.stride);
|
|
@@ -134,25 +134,25 @@ function Eo(l, s) {
|
|
|
134
134
|
let g = A;
|
|
135
135
|
F > g && (g = F), p > g && (g = p);
|
|
136
136
|
const S = (g - m) / 2, _ = C * 2;
|
|
137
|
-
o[u + _ + 0] = m + S, o[u + _ + 1] = S + (Math.abs(m) + S) *
|
|
137
|
+
o[u + _ + 0] = m + S, o[u + _ + 1] = S + (Math.abs(m) + S) * oo, m < s[C] && (s[C] = m), g > s[C + 3] && (s[C + 3] = g);
|
|
138
138
|
}
|
|
139
139
|
}
|
|
140
140
|
return o;
|
|
141
141
|
}
|
|
142
|
-
const Mt = 32,
|
|
142
|
+
const Mt = 32, Io = (l, s) => l.candidate - s.candidate, Ut = new Array(Mt).fill().map(() => ({
|
|
143
143
|
count: 0,
|
|
144
144
|
bounds: new Float32Array(6),
|
|
145
145
|
rightCacheBounds: new Float32Array(6),
|
|
146
146
|
leftCacheBounds: new Float32Array(6),
|
|
147
147
|
candidate: 0
|
|
148
148
|
})), je = new Float32Array(6);
|
|
149
|
-
function
|
|
149
|
+
function fo(l, s, t, e, i, o) {
|
|
150
150
|
let n = -1, r = 0;
|
|
151
|
-
if (o ===
|
|
151
|
+
if (o === wn)
|
|
152
152
|
n = vi(s), n !== -1 && (r = (s[n] + s[n + 3]) / 2);
|
|
153
|
-
else if (o ===
|
|
154
|
-
n = vi(l), n !== -1 && (r =
|
|
155
|
-
else if (o ===
|
|
153
|
+
else if (o === io)
|
|
154
|
+
n = vi(l), n !== -1 && (r = po(t, e, i, n));
|
|
155
|
+
else if (o === no) {
|
|
156
156
|
const a = Ae(l);
|
|
157
157
|
let c = Ys * i;
|
|
158
158
|
const h = e * 6, d = (e + i) * 6;
|
|
@@ -174,7 +174,7 @@ function Io(l, s, t, e, i, o) {
|
|
|
174
174
|
_[N] = 1 / 0, _[N + 3] = -1 / 0, S[N] = 1 / 0, S[N + 3] = -1 / 0, g[N] = 1 / 0, g[N + 3] = -1 / 0;
|
|
175
175
|
Qe(p, t, g);
|
|
176
176
|
}
|
|
177
|
-
C.sort(
|
|
177
|
+
C.sort(Io);
|
|
178
178
|
let F = i;
|
|
179
179
|
for (let p = 0; p < F; p++) {
|
|
180
180
|
const m = C[p];
|
|
@@ -234,7 +234,7 @@ function Io(l, s, t, e, i, o) {
|
|
|
234
234
|
console.warn(`MeshBVH: Invalid build strategy value ${o} used.`);
|
|
235
235
|
return { axis: n, pos: r };
|
|
236
236
|
}
|
|
237
|
-
function
|
|
237
|
+
function po(l, s, t, e) {
|
|
238
238
|
let i = 0;
|
|
239
239
|
for (let o = s, n = s + t; o < n; o++)
|
|
240
240
|
i += l[o * 6 + e * 2];
|
|
@@ -244,7 +244,7 @@ class qe {
|
|
|
244
244
|
constructor() {
|
|
245
245
|
}
|
|
246
246
|
}
|
|
247
|
-
function
|
|
247
|
+
function Co(l, s, t, e, i, o) {
|
|
248
248
|
let n = e, r = e + i - 1;
|
|
249
249
|
const a = o.pos, c = o.axis * 2;
|
|
250
250
|
for (; ; ) {
|
|
@@ -266,7 +266,7 @@ function po(l, s, t, e, i, o) {
|
|
|
266
266
|
return n;
|
|
267
267
|
}
|
|
268
268
|
}
|
|
269
|
-
function
|
|
269
|
+
function To(l, s, t, e, i, o) {
|
|
270
270
|
let n = e, r = e + i - 1;
|
|
271
271
|
const a = o.pos, c = o.axis * 2;
|
|
272
272
|
for (; ; ) {
|
|
@@ -286,19 +286,19 @@ function Co(l, s, t, e, i, o) {
|
|
|
286
286
|
return n;
|
|
287
287
|
}
|
|
288
288
|
}
|
|
289
|
-
function
|
|
289
|
+
function mo(l, s) {
|
|
290
290
|
const t = (l.index ? l.index.count : l.attributes.position.count) / 3, e = t > 2 ** 16, i = e ? 4 : 2, o = s ? new SharedArrayBuffer(t * i) : new ArrayBuffer(t * i), n = e ? new Uint32Array(o) : new Uint16Array(o);
|
|
291
291
|
for (let r = 0, a = n.length; r < a; r++)
|
|
292
292
|
n[r] = r;
|
|
293
293
|
return n;
|
|
294
294
|
}
|
|
295
|
-
function
|
|
295
|
+
function Ro(l, s) {
|
|
296
296
|
const t = l.geometry, e = t.index ? t.index.array : null, i = s.maxDepth, o = s.verbose, n = s.maxLeafTris, r = s.strategy, a = s.onProgress, c = Ce(t), h = l._indirectBuffer;
|
|
297
297
|
let d = !1;
|
|
298
|
-
const E = new Float32Array(6), u = new Float32Array(6), f =
|
|
298
|
+
const E = new Float32Array(6), u = new Float32Array(6), f = uo(t, E), T = s.indirect ? To : Co, R = [], C = s.indirect ? Dn(t) : Un(t);
|
|
299
299
|
if (C.length === 1) {
|
|
300
300
|
const p = C[0], m = new qe();
|
|
301
|
-
m.boundingData = E,
|
|
301
|
+
m.boundingData = E, Eo(f, p.offset, p.count, u), F(m, p.offset, p.count, u), R.push(m);
|
|
302
302
|
} else
|
|
303
303
|
for (let p of C) {
|
|
304
304
|
const m = new qe();
|
|
@@ -311,7 +311,7 @@ function mo(l, s) {
|
|
|
311
311
|
function F(p, m, g, S = null, _ = 0) {
|
|
312
312
|
if (!d && _ >= i && (d = !0, o && (console.warn(`MeshBVH: Max depth of ${i} reached when generating BVH. Consider increasing maxDepth.`), console.warn(t))), g <= n || _ >= i)
|
|
313
313
|
return A(m + g), p.offset = m, p.count = g, p;
|
|
314
|
-
const N =
|
|
314
|
+
const N = fo(p.boundingData, S, f, m, g, r);
|
|
315
315
|
if (N.axis === -1)
|
|
316
316
|
return A(m + g), p.offset = m, p.count = g, p;
|
|
317
317
|
const L = T(h, e, f, m, g, N);
|
|
@@ -327,12 +327,12 @@ function mo(l, s) {
|
|
|
327
327
|
return p;
|
|
328
328
|
}
|
|
329
329
|
}
|
|
330
|
-
function
|
|
330
|
+
function Ao(l, s) {
|
|
331
331
|
const t = l.geometry;
|
|
332
|
-
s.indirect && (l._indirectBuffer =
|
|
332
|
+
s.indirect && (l._indirectBuffer = mo(t, s.useSharedArrayBuffer), lo(t) && !s.verbose && console.warn(
|
|
333
333
|
'MeshBVH: Provided geometry contains groups that do not fully span the vertex contents while using the "indirect" option. BVH may incorrectly report intersections on unrendered portions of the geometry.'
|
|
334
|
-
)), l._indirectBuffer ||
|
|
335
|
-
const e =
|
|
334
|
+
)), l._indirectBuffer || co(t, s);
|
|
335
|
+
const e = Ro(l, s);
|
|
336
336
|
let i, o, n;
|
|
337
337
|
const r = [], a = s.useSharedArrayBuffer ? SharedArrayBuffer : ArrayBuffer;
|
|
338
338
|
for (let d = 0; d < e.length; d++) {
|
|
@@ -401,7 +401,7 @@ wt.prototype.setFromBox = function() {
|
|
|
401
401
|
this.min = n, this.max = r;
|
|
402
402
|
};
|
|
403
403
|
}();
|
|
404
|
-
const
|
|
404
|
+
const Fo = function() {
|
|
405
405
|
const l = new M(), s = new M(), t = new M();
|
|
406
406
|
return function(i, o, n) {
|
|
407
407
|
const r = i.start, a = l, c = o.start, h = s;
|
|
@@ -413,7 +413,7 @@ const Ao = function() {
|
|
|
413
413
|
}(), gi = function() {
|
|
414
414
|
const l = new fe(), s = new M(), t = new M();
|
|
415
415
|
return function(i, o, n, r) {
|
|
416
|
-
|
|
416
|
+
Fo(i, o, l);
|
|
417
417
|
let a = l.x, c = l.y;
|
|
418
418
|
if (a >= 0 && a <= 1 && c >= 0 && c <= 1) {
|
|
419
419
|
i.at(a, n), o.at(c, r);
|
|
@@ -439,7 +439,7 @@ const Ao = function() {
|
|
|
439
439
|
}
|
|
440
440
|
}
|
|
441
441
|
};
|
|
442
|
-
}(),
|
|
442
|
+
}(), go = function() {
|
|
443
443
|
const l = new M(), s = new M(), t = new Fi(), e = new Lt();
|
|
444
444
|
return function(o, n) {
|
|
445
445
|
const { radius: r, center: a } = o, { a: c, b: h, c: d } = n;
|
|
@@ -453,16 +453,16 @@ const Ao = function() {
|
|
|
453
453
|
}
|
|
454
454
|
return !1;
|
|
455
455
|
};
|
|
456
|
-
}(),
|
|
456
|
+
}(), Oo = 1e-15;
|
|
457
457
|
function zs(l) {
|
|
458
|
-
return Math.abs(l) <
|
|
458
|
+
return Math.abs(l) < Oo;
|
|
459
459
|
}
|
|
460
460
|
class Ft extends ue {
|
|
461
461
|
constructor(...s) {
|
|
462
|
-
super(...s), this.isExtendedTriangle = !0, this.satAxes = new Array(4).fill().map(() => new M()), this.satBounds = new Array(4).fill().map(() => new wt()), this.points = [this.a, this.b, this.c], this.sphere = new
|
|
462
|
+
super(...s), this.isExtendedTriangle = !0, this.satAxes = new Array(4).fill().map(() => new M()), this.satBounds = new Array(4).fill().map(() => new wt()), this.points = [this.a, this.b, this.c], this.sphere = new Qn(), this.plane = new Fi(), this.needsUpdate = !0;
|
|
463
463
|
}
|
|
464
464
|
intersectsSphere(s) {
|
|
465
|
-
return
|
|
465
|
+
return go(s, this);
|
|
466
466
|
}
|
|
467
467
|
update() {
|
|
468
468
|
const s = this.a, t = this.b, e = this.c, i = this.points, o = this.satAxes, n = this.satBounds, r = o[0], a = n[0];
|
|
@@ -733,12 +733,12 @@ class Oi {
|
|
|
733
733
|
this._primitives.push(s);
|
|
734
734
|
}
|
|
735
735
|
}
|
|
736
|
-
class
|
|
736
|
+
class So extends Oi {
|
|
737
737
|
constructor() {
|
|
738
738
|
super(() => new Ft());
|
|
739
739
|
}
|
|
740
740
|
}
|
|
741
|
-
const It = /* @__PURE__ */ new
|
|
741
|
+
const It = /* @__PURE__ */ new So();
|
|
742
742
|
function Et(l, s) {
|
|
743
743
|
return s[l + 15] === 65535;
|
|
744
744
|
}
|
|
@@ -754,10 +754,10 @@ function pt(l) {
|
|
|
754
754
|
function Ct(l, s) {
|
|
755
755
|
return s[l + 6];
|
|
756
756
|
}
|
|
757
|
-
function
|
|
757
|
+
function xn(l, s) {
|
|
758
758
|
return s[l + 7];
|
|
759
759
|
}
|
|
760
|
-
class
|
|
760
|
+
class _o {
|
|
761
761
|
constructor() {
|
|
762
762
|
this.float32Array = null, this.uint16Array = null, this.uint32Array = null;
|
|
763
763
|
const s = [];
|
|
@@ -769,10 +769,10 @@ class So {
|
|
|
769
769
|
};
|
|
770
770
|
}
|
|
771
771
|
}
|
|
772
|
-
const Z = new
|
|
772
|
+
const Z = new _o();
|
|
773
773
|
let Yt, Ie;
|
|
774
774
|
const Jt = [], Ke = /* @__PURE__ */ new Oi(() => new gt());
|
|
775
|
-
function
|
|
775
|
+
function No(l, s, t, e, i, o) {
|
|
776
776
|
Yt = Ke.getPrimitive(), Ie = Ke.getPrimitive(), Jt.push(Yt, Ie), Z.setBuffer(l._roots[s]);
|
|
777
777
|
const n = ai(0, l.geometry, t, e, i, o);
|
|
778
778
|
Z.clearBuffer(), Ke.releasePrimitive(Yt), Ke.releasePrimitive(Ie), Jt.pop(), Jt.pop();
|
|
@@ -844,7 +844,7 @@ function ai(l, s, t, e, i = null, o = 0, n = 0) {
|
|
|
844
844
|
}
|
|
845
845
|
}
|
|
846
846
|
const Fe = /* @__PURE__ */ new M(), Hs = /* @__PURE__ */ new M();
|
|
847
|
-
function
|
|
847
|
+
function Po(l, s, t = {}, e = 0, i = 1 / 0) {
|
|
848
848
|
const o = e * e, n = i * i;
|
|
849
849
|
let r = 1 / 0, a = null;
|
|
850
850
|
if (l.shapecast(
|
|
@@ -863,16 +863,16 @@ function No(l, s, t = {}, e = 0, i = 1 / 0) {
|
|
|
863
863
|
return t.point ? t.point.copy(Hs) : t.point = Hs.clone(), t.distance = c, t.faceIndex = a, t;
|
|
864
864
|
}
|
|
865
865
|
const te = /* @__PURE__ */ new M(), ee = /* @__PURE__ */ new M(), se = /* @__PURE__ */ new M(), $e = /* @__PURE__ */ new fe(), Je = /* @__PURE__ */ new fe(), ts = /* @__PURE__ */ new fe(), Vi = /* @__PURE__ */ new M(), Gi = /* @__PURE__ */ new M(), zi = /* @__PURE__ */ new M(), es = /* @__PURE__ */ new M();
|
|
866
|
-
function
|
|
866
|
+
function Lo(l, s, t, e, i, o) {
|
|
867
867
|
let n;
|
|
868
|
-
return o ===
|
|
868
|
+
return o === jn ? n = l.intersectTriangle(e, t, s, !0, i) : n = l.intersectTriangle(s, t, e, o !== yn, i), n === null ? null : {
|
|
869
869
|
distance: l.origin.distanceTo(i),
|
|
870
870
|
point: i.clone()
|
|
871
871
|
};
|
|
872
872
|
}
|
|
873
|
-
function
|
|
873
|
+
function yo(l, s, t, e, i, o, n, r, a) {
|
|
874
874
|
te.fromBufferAttribute(s, o), ee.fromBufferAttribute(s, n), se.fromBufferAttribute(s, r);
|
|
875
|
-
const c =
|
|
875
|
+
const c = Lo(l, te, ee, se, es, a);
|
|
876
876
|
if (c) {
|
|
877
877
|
e && ($e.fromBufferAttribute(e, o), Je.fromBufferAttribute(e, n), ts.fromBufferAttribute(e, r), c.uv = ue.getInterpolation(es, te, ee, se, $e, Je, ts, new fe())), i && ($e.fromBufferAttribute(i, o), Je.fromBufferAttribute(i, n), ts.fromBufferAttribute(i, r), c.uv1 = ue.getInterpolation(es, te, ee, se, $e, Je, ts, new fe())), t && (Vi.fromBufferAttribute(t, o), Gi.fromBufferAttribute(t, n), zi.fromBufferAttribute(t, r), c.normal = ue.getInterpolation(es, te, ee, se, Vi, Gi, zi, new M()), c.normal.dot(l.direction) > 0 && c.normal.multiplyScalar(-1));
|
|
878
878
|
const h = {
|
|
@@ -891,7 +891,7 @@ function xs(l, s, t, e, i) {
|
|
|
891
891
|
let n = o + 0, r = o + 1, a = o + 2;
|
|
892
892
|
const c = l.index;
|
|
893
893
|
l.index && (n = c.getX(n), r = c.getX(r), a = c.getX(a));
|
|
894
|
-
const { position: h, normal: d, uv: E, uv1: u } = l.attributes, f =
|
|
894
|
+
const { position: h, normal: d, uv: E, uv1: u } = l.attributes, f = yo(t, h, d, E, u, n, r, a, s);
|
|
895
895
|
return f ? (f.faceIndex = e, i && i.push(f), f) : null;
|
|
896
896
|
}
|
|
897
897
|
function tt(l, s, t, e) {
|
|
@@ -899,12 +899,12 @@ function tt(l, s, t, e) {
|
|
|
899
899
|
let r = s, a = s + 1, c = s + 2;
|
|
900
900
|
t && (r = t.getX(r), a = t.getX(a), c = t.getX(c)), i.x = e.getX(r), i.y = e.getY(r), i.z = e.getZ(r), o.x = e.getX(a), o.y = e.getY(a), o.z = e.getZ(a), n.x = e.getX(c), n.y = e.getY(c), n.z = e.getZ(c);
|
|
901
901
|
}
|
|
902
|
-
function
|
|
902
|
+
function Mo(l, s, t, e, i, o) {
|
|
903
903
|
const { geometry: n, _indirectBuffer: r } = l;
|
|
904
904
|
for (let a = e, c = e + i; a < c; a++)
|
|
905
905
|
xs(n, s, t, a, o);
|
|
906
906
|
}
|
|
907
|
-
function
|
|
907
|
+
function wo(l, s, t, e, i) {
|
|
908
908
|
const { geometry: o, _indirectBuffer: n } = l;
|
|
909
909
|
let r = 1 / 0, a = null;
|
|
910
910
|
for (let c = e, h = e + i; c < h; c++) {
|
|
@@ -913,7 +913,7 @@ function Mo(l, s, t, e, i) {
|
|
|
913
913
|
}
|
|
914
914
|
return a;
|
|
915
915
|
}
|
|
916
|
-
function
|
|
916
|
+
function Do(l, s, t, e, i, o, n) {
|
|
917
917
|
const { geometry: r } = t, { index: a } = r, c = r.attributes.position;
|
|
918
918
|
for (let h = l, d = s + l; h < d; h++) {
|
|
919
919
|
let E;
|
|
@@ -922,7 +922,7 @@ function wo(l, s, t, e, i, o, n) {
|
|
|
922
922
|
}
|
|
923
923
|
return !1;
|
|
924
924
|
}
|
|
925
|
-
function
|
|
925
|
+
function Uo(l, s = null) {
|
|
926
926
|
s && Array.isArray(s) && (s = new Set(s));
|
|
927
927
|
const t = l.geometry, e = t.index ? t.index.array : null, i = t.attributes.position;
|
|
928
928
|
let o, n, r, a, c = 0;
|
|
@@ -963,14 +963,14 @@ const Hi = /* @__PURE__ */ new gt();
|
|
|
963
963
|
function Gt(l, s, t, e) {
|
|
964
964
|
return K(l, s, Hi), t.intersectBox(Hi, e);
|
|
965
965
|
}
|
|
966
|
-
function
|
|
966
|
+
function xo(l, s, t, e, i, o) {
|
|
967
967
|
const { geometry: n, _indirectBuffer: r } = l;
|
|
968
968
|
for (let a = e, c = e + i; a < c; a++) {
|
|
969
969
|
let h = r ? r[a] : a;
|
|
970
970
|
xs(n, s, t, h, o);
|
|
971
971
|
}
|
|
972
972
|
}
|
|
973
|
-
function
|
|
973
|
+
function bo(l, s, t, e, i) {
|
|
974
974
|
const { geometry: o, _indirectBuffer: n } = l;
|
|
975
975
|
let r = 1 / 0, a = null;
|
|
976
976
|
for (let c = e, h = e + i; c < h; c++) {
|
|
@@ -979,7 +979,7 @@ function xo(l, s, t, e, i) {
|
|
|
979
979
|
}
|
|
980
980
|
return a;
|
|
981
981
|
}
|
|
982
|
-
function
|
|
982
|
+
function vo(l, s, t, e, i, o, n) {
|
|
983
983
|
const { geometry: r } = t, { index: a } = r, c = r.attributes.position;
|
|
984
984
|
for (let h = l, d = s + l; h < d; h++) {
|
|
985
985
|
let E;
|
|
@@ -989,14 +989,14 @@ function bo(l, s, t, e, i, o, n) {
|
|
|
989
989
|
return !1;
|
|
990
990
|
}
|
|
991
991
|
const Wi = /* @__PURE__ */ new M();
|
|
992
|
-
function
|
|
992
|
+
function Bo(l, s, t, e, i) {
|
|
993
993
|
Z.setBuffer(l._roots[s]), ci(0, l, t, e, i), Z.clearBuffer();
|
|
994
994
|
}
|
|
995
995
|
function ci(l, s, t, e, i) {
|
|
996
996
|
const { float32Array: o, uint16Array: n, uint32Array: r } = Z, a = l * 2;
|
|
997
997
|
if (Et(a, n)) {
|
|
998
998
|
const h = dt(l, r), d = ft(a, n);
|
|
999
|
-
|
|
999
|
+
Mo(s, t, e, h, d, i);
|
|
1000
1000
|
} else {
|
|
1001
1001
|
const h = pt(l);
|
|
1002
1002
|
Gt(h, o, e, Wi) && ci(h, s, t, e, i);
|
|
@@ -1004,8 +1004,8 @@ function ci(l, s, t, e, i) {
|
|
|
1004
1004
|
Gt(d, o, e, Wi) && ci(d, s, t, e, i);
|
|
1005
1005
|
}
|
|
1006
1006
|
}
|
|
1007
|
-
const ki = /* @__PURE__ */ new M(),
|
|
1008
|
-
function
|
|
1007
|
+
const ki = /* @__PURE__ */ new M(), Yo = ["x", "y", "z"];
|
|
1008
|
+
function Vo(l, s, t, e) {
|
|
1009
1009
|
Z.setBuffer(l._roots[s]);
|
|
1010
1010
|
const i = li(0, l, t, e);
|
|
1011
1011
|
return Z.clearBuffer(), i;
|
|
@@ -1015,9 +1015,9 @@ function li(l, s, t, e) {
|
|
|
1015
1015
|
let r = l * 2;
|
|
1016
1016
|
if (Et(r, o)) {
|
|
1017
1017
|
const c = dt(l, n), h = ft(r, o);
|
|
1018
|
-
return
|
|
1018
|
+
return wo(s, t, e, c, h);
|
|
1019
1019
|
} else {
|
|
1020
|
-
const c =
|
|
1020
|
+
const c = xn(l, n), h = Yo[c], E = e.direction[h] >= 0;
|
|
1021
1021
|
let u, f;
|
|
1022
1022
|
E ? (u = pt(l), f = Ct(l, n)) : (u = Ct(l, n), f = pt(l));
|
|
1023
1023
|
const R = Gt(u, i, e, ki) ? li(u, s, t, e) : null;
|
|
@@ -1034,7 +1034,7 @@ function li(l, s, t, e) {
|
|
|
1034
1034
|
}
|
|
1035
1035
|
}
|
|
1036
1036
|
const ss = /* @__PURE__ */ new gt(), ie = /* @__PURE__ */ new Ft(), ne = /* @__PURE__ */ new Ft(), ge = /* @__PURE__ */ new yt(), Xi = /* @__PURE__ */ new at(), is = /* @__PURE__ */ new at();
|
|
1037
|
-
function
|
|
1037
|
+
function Go(l, s, t, e) {
|
|
1038
1038
|
Z.setBuffer(l._roots[s]);
|
|
1039
1039
|
const i = hi(0, l, t, e);
|
|
1040
1040
|
return Z.clearBuffer(), i;
|
|
@@ -1066,12 +1066,12 @@ function hi(l, s, t, e, i = null) {
|
|
|
1066
1066
|
return K(h, o, ss), !!(i.intersectsBox(ss) && hi(h, s, t, e, i) || (K(d, o, ss), i.intersectsBox(ss) && hi(d, s, t, e, i)));
|
|
1067
1067
|
}
|
|
1068
1068
|
}
|
|
1069
|
-
const ns = /* @__PURE__ */ new yt(), Ws = /* @__PURE__ */ new at(), Oe = /* @__PURE__ */ new at(),
|
|
1070
|
-
function
|
|
1069
|
+
const ns = /* @__PURE__ */ new yt(), Ws = /* @__PURE__ */ new at(), Oe = /* @__PURE__ */ new at(), zo = /* @__PURE__ */ new M(), Ho = /* @__PURE__ */ new M(), Wo = /* @__PURE__ */ new M(), ko = /* @__PURE__ */ new M();
|
|
1070
|
+
function Xo(l, s, t, e = {}, i = {}, o = 0, n = 1 / 0) {
|
|
1071
1071
|
s.boundingBox || s.computeBoundingBox(), Ws.set(s.boundingBox.min, s.boundingBox.max, t), Ws.needsUpdate = !0;
|
|
1072
1072
|
const r = l.geometry, a = r.attributes.position, c = r.index, h = s.attributes.position, d = s.index, E = It.getPrimitive(), u = It.getPrimitive();
|
|
1073
|
-
let f =
|
|
1074
|
-
i && (R =
|
|
1073
|
+
let f = zo, T = Ho, R = null, C = null;
|
|
1074
|
+
i && (R = Wo, C = ko);
|
|
1075
1075
|
let A = 1 / 0, F = null, p = null;
|
|
1076
1076
|
return ns.copy(t).invert(), Oe.matrix.copy(ns), l.shapecast(
|
|
1077
1077
|
{
|
|
@@ -1110,7 +1110,7 @@ function ko(l, s, t, e = {}, i = {}, o = 0, n = 1 / 0) {
|
|
|
1110
1110
|
}
|
|
1111
1111
|
), It.releasePrimitive(E), It.releasePrimitive(u), A === 1 / 0 ? null : (e.point ? e.point.copy(T) : e.point = T.clone(), e.distance = A, e.faceIndex = F, i && (i.point ? i.point.copy(C) : i.point = C.clone(), i.point.applyMatrix4(ns), T.applyMatrix4(ns), i.distance = T.sub(i.point).length(), i.faceIndex = p), e);
|
|
1112
1112
|
}
|
|
1113
|
-
function
|
|
1113
|
+
function Zo(l, s = null) {
|
|
1114
1114
|
s && Array.isArray(s) && (s = new Set(s));
|
|
1115
1115
|
const t = l.geometry, e = t.index ? t.index.array : null, i = t.attributes.position;
|
|
1116
1116
|
let o, n, r, a, c = 0;
|
|
@@ -1152,14 +1152,14 @@ function Xo(l, s = null) {
|
|
|
1152
1152
|
}
|
|
1153
1153
|
}
|
|
1154
1154
|
const Zi = /* @__PURE__ */ new M();
|
|
1155
|
-
function
|
|
1155
|
+
function Qo(l, s, t, e, i) {
|
|
1156
1156
|
Z.setBuffer(l._roots[s]), Ei(0, l, t, e, i), Z.clearBuffer();
|
|
1157
1157
|
}
|
|
1158
1158
|
function Ei(l, s, t, e, i) {
|
|
1159
1159
|
const { float32Array: o, uint16Array: n, uint32Array: r } = Z, a = l * 2;
|
|
1160
1160
|
if (Et(a, n)) {
|
|
1161
1161
|
const h = dt(l, r), d = ft(a, n);
|
|
1162
|
-
|
|
1162
|
+
xo(s, t, e, h, d, i);
|
|
1163
1163
|
} else {
|
|
1164
1164
|
const h = pt(l);
|
|
1165
1165
|
Gt(h, o, e, Zi) && Ei(h, s, t, e, i);
|
|
@@ -1167,8 +1167,8 @@ function Ei(l, s, t, e, i) {
|
|
|
1167
1167
|
Gt(d, o, e, Zi) && Ei(d, s, t, e, i);
|
|
1168
1168
|
}
|
|
1169
1169
|
}
|
|
1170
|
-
const Qi = /* @__PURE__ */ new M(),
|
|
1171
|
-
function
|
|
1170
|
+
const Qi = /* @__PURE__ */ new M(), jo = ["x", "y", "z"];
|
|
1171
|
+
function qo(l, s, t, e) {
|
|
1172
1172
|
Z.setBuffer(l._roots[s]);
|
|
1173
1173
|
const i = di(0, l, t, e);
|
|
1174
1174
|
return Z.clearBuffer(), i;
|
|
@@ -1178,9 +1178,9 @@ function di(l, s, t, e) {
|
|
|
1178
1178
|
let r = l * 2;
|
|
1179
1179
|
if (Et(r, o)) {
|
|
1180
1180
|
const c = dt(l, n), h = ft(r, o);
|
|
1181
|
-
return
|
|
1181
|
+
return bo(s, t, e, c, h);
|
|
1182
1182
|
} else {
|
|
1183
|
-
const c =
|
|
1183
|
+
const c = xn(l, n), h = jo[c], E = e.direction[h] >= 0;
|
|
1184
1184
|
let u, f;
|
|
1185
1185
|
E ? (u = pt(l), f = Ct(l, n)) : (u = Ct(l, n), f = pt(l));
|
|
1186
1186
|
const R = Gt(u, i, e, Qi) ? di(u, s, t, e) : null;
|
|
@@ -1197,7 +1197,7 @@ function di(l, s, t, e) {
|
|
|
1197
1197
|
}
|
|
1198
1198
|
}
|
|
1199
1199
|
const os = /* @__PURE__ */ new gt(), oe = /* @__PURE__ */ new Ft(), re = /* @__PURE__ */ new Ft(), Se = /* @__PURE__ */ new yt(), ji = /* @__PURE__ */ new at(), rs = /* @__PURE__ */ new at();
|
|
1200
|
-
function
|
|
1200
|
+
function Ko(l, s, t, e) {
|
|
1201
1201
|
Z.setBuffer(l._roots[s]);
|
|
1202
1202
|
const i = ui(0, l, t, e);
|
|
1203
1203
|
return Z.clearBuffer(), i;
|
|
@@ -1230,12 +1230,12 @@ function ui(l, s, t, e, i = null) {
|
|
|
1230
1230
|
return K(h, o, os), !!(i.intersectsBox(os) && ui(h, s, t, e, i) || (K(d, o, os), i.intersectsBox(os) && ui(d, s, t, e, i)));
|
|
1231
1231
|
}
|
|
1232
1232
|
}
|
|
1233
|
-
const as = /* @__PURE__ */ new yt(), ks = /* @__PURE__ */ new at(), _e = /* @__PURE__ */ new at(),
|
|
1234
|
-
function
|
|
1233
|
+
const as = /* @__PURE__ */ new yt(), ks = /* @__PURE__ */ new at(), _e = /* @__PURE__ */ new at(), $o = /* @__PURE__ */ new M(), Jo = /* @__PURE__ */ new M(), tr = /* @__PURE__ */ new M(), er = /* @__PURE__ */ new M();
|
|
1234
|
+
function sr(l, s, t, e = {}, i = {}, o = 0, n = 1 / 0) {
|
|
1235
1235
|
s.boundingBox || s.computeBoundingBox(), ks.set(s.boundingBox.min, s.boundingBox.max, t), ks.needsUpdate = !0;
|
|
1236
1236
|
const r = l.geometry, a = r.attributes.position, c = r.index, h = s.attributes.position, d = s.index, E = It.getPrimitive(), u = It.getPrimitive();
|
|
1237
|
-
let f =
|
|
1238
|
-
i && (R =
|
|
1237
|
+
let f = $o, T = Jo, R = null, C = null;
|
|
1238
|
+
i && (R = tr, C = er);
|
|
1239
1239
|
let A = 1 / 0, F = null, p = null;
|
|
1240
1240
|
return as.copy(t).invert(), _e.matrix.copy(as), l.shapecast(
|
|
1241
1241
|
{
|
|
@@ -1278,12 +1278,12 @@ function er(l, s, t, e = {}, i = {}, o = 0, n = 1 / 0) {
|
|
|
1278
1278
|
}
|
|
1279
1279
|
), It.releasePrimitive(E), It.releasePrimitive(u), A === 1 / 0 ? null : (e.point ? e.point.copy(T) : e.point = T.clone(), e.distance = A, e.faceIndex = F, i && (i.point ? i.point.copy(C) : i.point = C.clone(), i.point.applyMatrix4(as), T.applyMatrix4(as), i.distance = T.sub(i.point).length(), i.faceIndex = p), e);
|
|
1280
1280
|
}
|
|
1281
|
-
function
|
|
1281
|
+
function ir() {
|
|
1282
1282
|
return typeof SharedArrayBuffer < "u";
|
|
1283
1283
|
}
|
|
1284
1284
|
const be = new Z.constructor(), As = new Z.constructor(), vt = new Oi(() => new gt()), ae = new gt(), ce = new gt(), Xs = new gt(), Zs = new gt();
|
|
1285
1285
|
let Qs = !1;
|
|
1286
|
-
function
|
|
1286
|
+
function nr(l, s, t, e) {
|
|
1287
1287
|
if (Qs)
|
|
1288
1288
|
throw new Error("MeshBVH: Recursive calls to bvhcast not supported.");
|
|
1289
1289
|
Qs = !0;
|
|
@@ -1524,7 +1524,7 @@ class Si {
|
|
|
1524
1524
|
if (r._roots = o, r._indirectBuffer = n || null, e.setIndex) {
|
|
1525
1525
|
const a = t.getIndex();
|
|
1526
1526
|
if (a === null) {
|
|
1527
|
-
const c = new
|
|
1527
|
+
const c = new Ln(s.index, 1, !1);
|
|
1528
1528
|
t.setIndex(c);
|
|
1529
1529
|
} else
|
|
1530
1530
|
a.array !== i && (a.array.set(i), a.needsUpdate = !0);
|
|
@@ -1541,7 +1541,7 @@ class Si {
|
|
|
1541
1541
|
} else
|
|
1542
1542
|
throw new Error("MeshBVH: Only BufferGeometries are supported.");
|
|
1543
1543
|
if (t = Object.assign({
|
|
1544
|
-
strategy:
|
|
1544
|
+
strategy: wn,
|
|
1545
1545
|
maxDepth: 40,
|
|
1546
1546
|
maxLeafTris: 10,
|
|
1547
1547
|
verbose: !0,
|
|
@@ -1552,14 +1552,14 @@ class Si {
|
|
|
1552
1552
|
// undocumented options
|
|
1553
1553
|
// Whether to skip generating the tree. Used for deserialization.
|
|
1554
1554
|
[Vs]: !1
|
|
1555
|
-
}, t), t.useSharedArrayBuffer && !
|
|
1555
|
+
}, t), t.useSharedArrayBuffer && !ir())
|
|
1556
1556
|
throw new Error("MeshBVH: SharedArrayBuffer is not available.");
|
|
1557
|
-
this.geometry = s, this._roots = null, this._indirectBuffer = null, t[Vs] || (
|
|
1557
|
+
this.geometry = s, this._roots = null, this._indirectBuffer = null, t[Vs] || (Ao(this, t), !s.boundingBox && t.setBoundingBox && (s.boundingBox = this.getBoundingBox(new gt())));
|
|
1558
1558
|
const { _indirectBuffer: e } = this;
|
|
1559
1559
|
this.resolveTriangleIndex = t.indirect ? (i) => e[i] : (i) => i;
|
|
1560
1560
|
}
|
|
1561
1561
|
refit(s = null) {
|
|
1562
|
-
return (this.indirect ?
|
|
1562
|
+
return (this.indirect ? Zo : Uo)(this, s);
|
|
1563
1563
|
}
|
|
1564
1564
|
traverse(s, t = 0) {
|
|
1565
1565
|
const e = this._roots[t], i = new Uint32Array(e), o = new Uint16Array(e);
|
|
@@ -1577,7 +1577,7 @@ class Si {
|
|
|
1577
1577
|
}
|
|
1578
1578
|
/* Core Cast Functions */
|
|
1579
1579
|
raycast(s, t = wi) {
|
|
1580
|
-
const e = this._roots, i = this.geometry, o = [], n = t.isMaterial, r = Array.isArray(t), a = i.groups, c = n ? t.side : t, h = this.indirect ?
|
|
1580
|
+
const e = this._roots, i = this.geometry, o = [], n = t.isMaterial, r = Array.isArray(t), a = i.groups, c = n ? t.side : t, h = this.indirect ? Qo : Bo;
|
|
1581
1581
|
for (let d = 0, E = e.length; d < E; d++) {
|
|
1582
1582
|
const u = r ? t[a[d].materialIndex].side : c, f = o.length;
|
|
1583
1583
|
if (h(this, d, u, s, o), r) {
|
|
@@ -1591,7 +1591,7 @@ class Si {
|
|
|
1591
1591
|
raycastFirst(s, t = wi) {
|
|
1592
1592
|
const e = this._roots, i = this.geometry, o = t.isMaterial, n = Array.isArray(t);
|
|
1593
1593
|
let r = null;
|
|
1594
|
-
const a = i.groups, c = o ? t.side : t, h = this.indirect ?
|
|
1594
|
+
const a = i.groups, c = o ? t.side : t, h = this.indirect ? qo : Vo;
|
|
1595
1595
|
for (let d = 0, E = e.length; d < E; d++) {
|
|
1596
1596
|
const u = n ? t[a[d].materialIndex].side : c, f = h(this, d, u, s);
|
|
1597
1597
|
f != null && (r == null || f.distance < r.distance) && (r = f, n && (f.face.materialIndex = a[d].materialIndex));
|
|
@@ -1600,13 +1600,13 @@ class Si {
|
|
|
1600
1600
|
}
|
|
1601
1601
|
intersectsGeometry(s, t) {
|
|
1602
1602
|
let e = !1;
|
|
1603
|
-
const i = this._roots, o = this.indirect ?
|
|
1603
|
+
const i = this._roots, o = this.indirect ? Ko : Go;
|
|
1604
1604
|
for (let n = 0, r = i.length; n < r && (e = o(this, n, s, t), !e); n++)
|
|
1605
1605
|
;
|
|
1606
1606
|
return e;
|
|
1607
1607
|
}
|
|
1608
1608
|
shapecast(s) {
|
|
1609
|
-
const t = It.getPrimitive(), e = this.indirect ?
|
|
1609
|
+
const t = It.getPrimitive(), e = this.indirect ? vo : Do;
|
|
1610
1610
|
let {
|
|
1611
1611
|
boundsTraverseOrder: i,
|
|
1612
1612
|
intersectsBounds: o,
|
|
@@ -1622,7 +1622,7 @@ class Si {
|
|
|
1622
1622
|
const h = this._roots;
|
|
1623
1623
|
for (let d = 0, E = h.length; d < E; d++) {
|
|
1624
1624
|
const u = h[d];
|
|
1625
|
-
if (a =
|
|
1625
|
+
if (a = No(this, d, o, n, i, c), a)
|
|
1626
1626
|
break;
|
|
1627
1627
|
c += u.byteLength;
|
|
1628
1628
|
}
|
|
@@ -1662,7 +1662,7 @@ class Si {
|
|
|
1662
1662
|
} else
|
|
1663
1663
|
i = f;
|
|
1664
1664
|
}
|
|
1665
|
-
return
|
|
1665
|
+
return nr(this, s, t, i);
|
|
1666
1666
|
}
|
|
1667
1667
|
/* Derived Cast Functions */
|
|
1668
1668
|
intersectsBox(s, t) {
|
|
@@ -1682,7 +1682,7 @@ class Si {
|
|
|
1682
1682
|
);
|
|
1683
1683
|
}
|
|
1684
1684
|
closestPointToGeometry(s, t, e = {}, i = {}, o = 0, n = 1 / 0) {
|
|
1685
|
-
return (this.indirect ?
|
|
1685
|
+
return (this.indirect ? sr : Xo)(
|
|
1686
1686
|
this,
|
|
1687
1687
|
s,
|
|
1688
1688
|
t,
|
|
@@ -1693,7 +1693,7 @@ class Si {
|
|
|
1693
1693
|
);
|
|
1694
1694
|
}
|
|
1695
1695
|
closestPointToPoint(s, t = {}, e = 0, i = 1 / 0) {
|
|
1696
|
-
return
|
|
1696
|
+
return Po(
|
|
1697
1697
|
this,
|
|
1698
1698
|
s,
|
|
1699
1699
|
t,
|
|
@@ -1710,8 +1710,8 @@ class Si {
|
|
|
1710
1710
|
function Ki(l, s, t) {
|
|
1711
1711
|
return l === null || (l.point.applyMatrix4(s.matrixWorld), l.distance = l.point.distanceTo(t.ray.origin), l.object = s, l.distance < t.near || l.distance > t.far) ? null : l;
|
|
1712
1712
|
}
|
|
1713
|
-
const js = /* @__PURE__ */ new
|
|
1714
|
-
function
|
|
1713
|
+
const js = /* @__PURE__ */ new qn(), $i = /* @__PURE__ */ new yt(), or = v.prototype.raycast;
|
|
1714
|
+
function rr(l, s) {
|
|
1715
1715
|
if (this.geometry.boundsTree) {
|
|
1716
1716
|
if (this.material === void 0)
|
|
1717
1717
|
return;
|
|
@@ -1728,12 +1728,12 @@ function or(l, s) {
|
|
|
1728
1728
|
}
|
|
1729
1729
|
}
|
|
1730
1730
|
} else
|
|
1731
|
-
|
|
1731
|
+
or.call(this, l, s);
|
|
1732
1732
|
}
|
|
1733
|
-
function
|
|
1733
|
+
function ar(l) {
|
|
1734
1734
|
return this.boundsTree = new Si(this, l), this.boundsTree;
|
|
1735
1735
|
}
|
|
1736
|
-
function
|
|
1736
|
+
function cr() {
|
|
1737
1737
|
this.boundsTree = null;
|
|
1738
1738
|
}
|
|
1739
1739
|
class w {
|
|
@@ -1829,7 +1829,7 @@ class Ni extends _i {
|
|
|
1829
1829
|
});
|
|
1830
1830
|
}
|
|
1831
1831
|
}
|
|
1832
|
-
class
|
|
1832
|
+
class lr extends Ni {
|
|
1833
1833
|
constructor() {
|
|
1834
1834
|
super(...arguments);
|
|
1835
1835
|
/**
|
|
@@ -1840,7 +1840,7 @@ class cr extends Ni {
|
|
|
1840
1840
|
I(this, "hasCameraControls", () => "controls" in this);
|
|
1841
1841
|
}
|
|
1842
1842
|
}
|
|
1843
|
-
class
|
|
1843
|
+
class hr extends Ni {
|
|
1844
1844
|
constructor() {
|
|
1845
1845
|
super(...arguments);
|
|
1846
1846
|
/** {@link Updateable.onBeforeUpdate} */
|
|
@@ -1958,7 +1958,7 @@ const ve = class ve extends et {
|
|
|
1958
1958
|
*/
|
|
1959
1959
|
I(ve, "uuid", "76e9cd8e-ad8f-4753-9ef6-cbc60f7247fe");
|
|
1960
1960
|
let zt = ve;
|
|
1961
|
-
class
|
|
1961
|
+
class Er extends Ni {
|
|
1962
1962
|
constructor(t) {
|
|
1963
1963
|
super(t);
|
|
1964
1964
|
/** {@link Disposable.onDisposed} */
|
|
@@ -1974,63 +1974,131 @@ class hr extends Ni {
|
|
|
1974
1974
|
this.three.children = [], this.onDisposed.trigger(), this.onDisposed.reset();
|
|
1975
1975
|
}
|
|
1976
1976
|
}
|
|
1977
|
-
class
|
|
1977
|
+
class ia extends Set {
|
|
1978
|
+
/**
|
|
1979
|
+
* Constructs a new instance of the DataSet class.
|
|
1980
|
+
*
|
|
1981
|
+
* @param iterable - An optional iterable object to initialize the set with.
|
|
1982
|
+
*/
|
|
1978
1983
|
constructor(t) {
|
|
1979
1984
|
super(t);
|
|
1985
|
+
/**
|
|
1986
|
+
* An event that is triggered when a new item is added to the set.
|
|
1987
|
+
*/
|
|
1980
1988
|
I(this, "onItemAdded", new w());
|
|
1989
|
+
/**
|
|
1990
|
+
* An event that is triggered when an item is deleted from the set.
|
|
1991
|
+
*/
|
|
1981
1992
|
I(this, "onItemDeleted", new w());
|
|
1993
|
+
/**
|
|
1994
|
+
* An event that is triggered when the set is cleared.
|
|
1995
|
+
*/
|
|
1982
1996
|
I(this, "onCleared", new w());
|
|
1983
1997
|
}
|
|
1998
|
+
/**
|
|
1999
|
+
* Clears the set and triggers the onCleared event.
|
|
2000
|
+
*/
|
|
1984
2001
|
clear() {
|
|
1985
2002
|
super.clear(), this.onCleared.trigger();
|
|
1986
2003
|
}
|
|
2004
|
+
/**
|
|
2005
|
+
* Adds a value to the set and triggers the onItemAdded event.
|
|
2006
|
+
*
|
|
2007
|
+
* @param value - The value to add to the set.
|
|
2008
|
+
* @returns - The set instance.
|
|
2009
|
+
*/
|
|
1987
2010
|
add(t) {
|
|
1988
2011
|
if (this.has(t))
|
|
1989
2012
|
return this;
|
|
1990
2013
|
const i = super.add(t);
|
|
1991
2014
|
return this.onItemAdded || (this.onItemAdded = new w()), this.onItemAdded.trigger(t), i;
|
|
1992
2015
|
}
|
|
2016
|
+
/**
|
|
2017
|
+
* Deletes a value from the set and triggers the onItemDeleted event.
|
|
2018
|
+
*
|
|
2019
|
+
* @param value - The value to delete from the set.
|
|
2020
|
+
* @returns - True if the value was successfully deleted, false otherwise.
|
|
2021
|
+
*/
|
|
1993
2022
|
delete(t) {
|
|
1994
2023
|
const e = super.delete(t);
|
|
1995
2024
|
return e && this.onItemDeleted.trigger(), e;
|
|
1996
2025
|
}
|
|
2026
|
+
/**
|
|
2027
|
+
* Clears the set and resets the onItemAdded, onItemDeleted, and onCleared events.
|
|
2028
|
+
*/
|
|
1997
2029
|
dispose() {
|
|
1998
2030
|
this.clear(), this.onItemAdded.reset(), this.onItemDeleted.reset(), this.onCleared.reset();
|
|
1999
2031
|
}
|
|
2000
2032
|
}
|
|
2001
|
-
class
|
|
2033
|
+
class Ji extends Map {
|
|
2034
|
+
/**
|
|
2035
|
+
* Constructs a new DataMap instance.
|
|
2036
|
+
*
|
|
2037
|
+
* @param iterable - An iterable object containing key-value pairs to populate the map.
|
|
2038
|
+
*/
|
|
2002
2039
|
constructor(t) {
|
|
2003
2040
|
super(t);
|
|
2041
|
+
/**
|
|
2042
|
+
* An event triggered when a new item is set in the map.
|
|
2043
|
+
*/
|
|
2004
2044
|
I(this, "onItemSet", new w());
|
|
2045
|
+
/**
|
|
2046
|
+
* An event triggered when an existing item in the map is updated.
|
|
2047
|
+
*/
|
|
2005
2048
|
I(this, "onItemUpdated", new w());
|
|
2049
|
+
/**
|
|
2050
|
+
* An event triggered when an item is deleted from the map.
|
|
2051
|
+
*/
|
|
2006
2052
|
I(this, "onItemDeleted", new w());
|
|
2053
|
+
/**
|
|
2054
|
+
* An event triggered when the map is cleared.
|
|
2055
|
+
*/
|
|
2007
2056
|
I(this, "onCleared", new w());
|
|
2008
2057
|
}
|
|
2058
|
+
/**
|
|
2059
|
+
* Clears the map and triggers the onCleared event.
|
|
2060
|
+
*/
|
|
2009
2061
|
clear() {
|
|
2010
2062
|
super.clear(), this.onCleared.trigger();
|
|
2011
2063
|
}
|
|
2064
|
+
/**
|
|
2065
|
+
* Sets the value for the specified key in the map and triggers the appropriate event (onItemSet or onItemUpdated).
|
|
2066
|
+
*
|
|
2067
|
+
* @param key - The key of the item to set.
|
|
2068
|
+
* @param value - The value of the item to set.
|
|
2069
|
+
* @returns The DataMap instance.
|
|
2070
|
+
*/
|
|
2012
2071
|
set(t, e) {
|
|
2013
2072
|
const i = this.has(t), o = super.set(t, e);
|
|
2014
2073
|
return i ? (this.onItemUpdated || (this.onItemUpdated = new w()), this.onItemUpdated.trigger({ key: t, value: e })) : (this.onItemSet || (this.onItemSet = new w()), this.onItemSet.trigger({ key: t, value: e })), o;
|
|
2015
2074
|
}
|
|
2075
|
+
/**
|
|
2076
|
+
* Deletes the specified key from the map and triggers the onItemDeleted event if the key was found.
|
|
2077
|
+
*
|
|
2078
|
+
* @param key - The key of the item to delete.
|
|
2079
|
+
* @returns True if the key was found and deleted; otherwise, false.
|
|
2080
|
+
*/
|
|
2016
2081
|
delete(t) {
|
|
2017
2082
|
const e = super.delete(t);
|
|
2018
2083
|
return e && this.onItemDeleted.trigger(), e;
|
|
2019
2084
|
}
|
|
2085
|
+
/**
|
|
2086
|
+
* Clears the map and resets the events.
|
|
2087
|
+
*/
|
|
2020
2088
|
dispose() {
|
|
2021
2089
|
this.clear(), this.onItemSet.reset(), this.onItemDeleted.reset(), this.onCleared.reset();
|
|
2022
2090
|
}
|
|
2023
2091
|
}
|
|
2024
|
-
const ms = 0,
|
|
2025
|
-
class
|
|
2092
|
+
const ms = 0, dr = 1, ur = new M(), tn = new Lt(), qs = new Fi(), en = new M(), ls = new ue();
|
|
2093
|
+
class Ir {
|
|
2026
2094
|
constructor() {
|
|
2027
|
-
this.tolerance = -1, this.faces = [], this.newFaces = [], this.assigned = new
|
|
2095
|
+
this.tolerance = -1, this.faces = [], this.newFaces = [], this.assigned = new sn(), this.unassigned = new sn(), this.vertices = [];
|
|
2028
2096
|
}
|
|
2029
2097
|
setFromPoints(s) {
|
|
2030
2098
|
if (s.length >= 4) {
|
|
2031
2099
|
this.makeEmpty();
|
|
2032
2100
|
for (let t = 0, e = s.length; t < e; t++)
|
|
2033
|
-
this.vertices.push(new
|
|
2101
|
+
this.vertices.push(new fr(s[t]));
|
|
2034
2102
|
this.compute();
|
|
2035
2103
|
}
|
|
2036
2104
|
return this;
|
|
@@ -2070,7 +2138,7 @@ class ur {
|
|
|
2070
2138
|
return i !== -1 / 0 ? s.at(i, t) : s.at(o, t), t;
|
|
2071
2139
|
}
|
|
2072
2140
|
intersectsRay(s) {
|
|
2073
|
-
return this.intersectRay(s,
|
|
2141
|
+
return this.intersectRay(s, ur) !== null;
|
|
2074
2142
|
}
|
|
2075
2143
|
makeEmpty() {
|
|
2076
2144
|
return this.faces = [], this.vertices = [], this;
|
|
@@ -2154,12 +2222,12 @@ class ur {
|
|
|
2154
2222
|
}
|
|
2155
2223
|
const r = e[n], a = i[n];
|
|
2156
2224
|
let c, h;
|
|
2157
|
-
o = 0,
|
|
2225
|
+
o = 0, tn.set(r.point, a.point);
|
|
2158
2226
|
for (let E = 0, u = this.vertices.length; E < u; E++) {
|
|
2159
2227
|
const f = s[E];
|
|
2160
2228
|
if (f !== r && f !== a) {
|
|
2161
|
-
|
|
2162
|
-
const T =
|
|
2229
|
+
tn.closestPointToPoint(f.point, !0, en);
|
|
2230
|
+
const T = en.distanceToSquared(f.point);
|
|
2163
2231
|
T > o && (o = T, c = f);
|
|
2164
2232
|
}
|
|
2165
2233
|
}
|
|
@@ -2237,7 +2305,7 @@ class ur {
|
|
|
2237
2305
|
// For an edge to be part of the horizon it must join a face that can see
|
|
2238
2306
|
// 'eyePoint' and a face that cannot see 'eyePoint'.
|
|
2239
2307
|
computeHorizon(s, t, e, i) {
|
|
2240
|
-
this.deleteFaceVertices(e), e.mark =
|
|
2308
|
+
this.deleteFaceVertices(e), e.mark = dr;
|
|
2241
2309
|
let o;
|
|
2242
2310
|
t === null ? o = t = e.getEdge(0) : o = t.next;
|
|
2243
2311
|
do {
|
|
@@ -2323,12 +2391,12 @@ class Ks {
|
|
|
2323
2391
|
return this.twin = s, s.twin = this, this;
|
|
2324
2392
|
}
|
|
2325
2393
|
}
|
|
2326
|
-
class
|
|
2394
|
+
class fr {
|
|
2327
2395
|
constructor(s) {
|
|
2328
2396
|
this.point = s, this.prev = null, this.next = null, this.face = null;
|
|
2329
2397
|
}
|
|
2330
2398
|
}
|
|
2331
|
-
class
|
|
2399
|
+
class sn {
|
|
2332
2400
|
constructor() {
|
|
2333
2401
|
this.head = null, this.tail = null;
|
|
2334
2402
|
}
|
|
@@ -2375,14 +2443,14 @@ const Ii = [2, 2, 1], fi = [1, 0, 0];
|
|
|
2375
2443
|
function Nt(l, s) {
|
|
2376
2444
|
return l * 3 + s;
|
|
2377
2445
|
}
|
|
2378
|
-
function
|
|
2446
|
+
function pr(l) {
|
|
2379
2447
|
const s = l.elements;
|
|
2380
2448
|
let t = 0;
|
|
2381
2449
|
for (let e = 0; e < 9; e++)
|
|
2382
2450
|
t += s[e] * s[e];
|
|
2383
2451
|
return Math.sqrt(t);
|
|
2384
2452
|
}
|
|
2385
|
-
function
|
|
2453
|
+
function Cr(l) {
|
|
2386
2454
|
const s = l.elements;
|
|
2387
2455
|
let t = 0;
|
|
2388
2456
|
for (let e = 0; e < 3; e++) {
|
|
@@ -2391,7 +2459,7 @@ function pr(l) {
|
|
|
2391
2459
|
}
|
|
2392
2460
|
return Math.sqrt(t);
|
|
2393
2461
|
}
|
|
2394
|
-
function
|
|
2462
|
+
function Tr(l, s) {
|
|
2395
2463
|
let t = 0, e = 1;
|
|
2396
2464
|
const i = l.elements;
|
|
2397
2465
|
for (let c = 0; c < 3; c++) {
|
|
@@ -2407,22 +2475,22 @@ function Cr(l, s) {
|
|
|
2407
2475
|
}
|
|
2408
2476
|
return s.identity(), s.elements[Nt(r, r)] = o, s.elements[Nt(a, a)] = o, s.elements[Nt(a, r)] = n, s.elements[Nt(r, a)] = -n, s;
|
|
2409
2477
|
}
|
|
2410
|
-
function
|
|
2478
|
+
function mr(l, s) {
|
|
2411
2479
|
let t = 0, e = 0;
|
|
2412
2480
|
const i = 10;
|
|
2413
2481
|
s.unitary.identity(), s.diagonal.copy(l);
|
|
2414
|
-
const o = s.unitary, n = s.diagonal, r = new O.Matrix3(), a = new O.Matrix3(), c = Number.EPSILON *
|
|
2415
|
-
for (; e < i &&
|
|
2416
|
-
|
|
2482
|
+
const o = s.unitary, n = s.diagonal, r = new O.Matrix3(), a = new O.Matrix3(), c = Number.EPSILON * pr(n);
|
|
2483
|
+
for (; e < i && Cr(n) > c; )
|
|
2484
|
+
Tr(n, r), a.copy(r).transpose(), n.multiply(r), n.premultiply(a), o.multiply(r), ++t > 2 && (e++, t = 0);
|
|
2417
2485
|
return s;
|
|
2418
2486
|
}
|
|
2419
|
-
function
|
|
2487
|
+
function Rr(l) {
|
|
2420
2488
|
const s = [];
|
|
2421
2489
|
for (let it = 0; it < l.length - 2; it += 3) {
|
|
2422
2490
|
const Xt = l[it], J = l[it + 1], $t = l[it + 2];
|
|
2423
2491
|
s.push(new O.Vector3(Xt, J, $t));
|
|
2424
2492
|
}
|
|
2425
|
-
const t = new
|
|
2493
|
+
const t = new Ir();
|
|
2426
2494
|
t.setFromPoints(s);
|
|
2427
2495
|
const e = {
|
|
2428
2496
|
unitary: new O.Matrix3(),
|
|
@@ -2435,8 +2503,8 @@ function mr(l) {
|
|
|
2435
2503
|
do
|
|
2436
2504
|
o.push($t), $t = $t.next;
|
|
2437
2505
|
while ($t !== J.edge);
|
|
2438
|
-
const
|
|
2439
|
-
for (let Xe = 1,
|
|
2506
|
+
const Wn = o.length - 2;
|
|
2507
|
+
for (let Xe = 1, kn = Wn; Xe <= kn; Xe++) {
|
|
2440
2508
|
const bs = o[0].vertex, vs = o[Xe + 0].vertex, Bs = o[Xe + 1].vertex;
|
|
2441
2509
|
n.push(bs.point.x, bs.point.y, bs.point.z), n.push(vs.point.x, vs.point.y, vs.point.z), n.push(Bs.point.x, Bs.point.y, Bs.point.z);
|
|
2442
2510
|
}
|
|
@@ -2450,7 +2518,7 @@ function mr(l) {
|
|
|
2450
2518
|
}
|
|
2451
2519
|
f.divideScalar(T), R /= T, C /= T, A /= T, F /= T, p /= T, m /= T, R -= f.x * f.x, C -= f.x * f.y, A -= f.x * f.z, F -= f.y * f.y, p -= f.y * f.z, m -= f.z * f.z;
|
|
2452
2520
|
const g = new O.Matrix3();
|
|
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,
|
|
2521
|
+
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, mr(g, e);
|
|
2454
2522
|
const S = e.unitary, _ = new O.Vector3(), N = new O.Vector3(), L = new O.Vector3();
|
|
2455
2523
|
S.extractBasis(_, N, L);
|
|
2456
2524
|
let D = -1 / 0, y = -1 / 0, x = -1 / 0, b = 1 / 0, B = 1 / 0, H = 1 / 0;
|
|
@@ -2472,7 +2540,7 @@ function mr(l) {
|
|
|
2472
2540
|
const me = new O.Matrix4();
|
|
2473
2541
|
return me.multiply(yi), me.multiply(Mi), me.multiply(Te), me.multiply(ke), { center: q, halfSizes: st, rotation: Q, transformation: me };
|
|
2474
2542
|
}
|
|
2475
|
-
function
|
|
2543
|
+
function Ar(l, s, t) {
|
|
2476
2544
|
const e = [
|
|
2477
2545
|
l[0] - s[0],
|
|
2478
2546
|
l[1] - s[1],
|
|
@@ -2480,7 +2548,7 @@ function Rr(l, s, t) {
|
|
|
2480
2548
|
];
|
|
2481
2549
|
return t[0] * e[0] + t[1] * e[1] + t[2] * e[2] > 0;
|
|
2482
2550
|
}
|
|
2483
|
-
class
|
|
2551
|
+
class nn {
|
|
2484
2552
|
static isTransparent(s) {
|
|
2485
2553
|
return s.transparent && s.opacity < 1;
|
|
2486
2554
|
}
|
|
@@ -3009,15 +3077,15 @@ const Fs = class Fs {
|
|
|
3009
3077
|
this._clock.stop(), this.onDisposed.trigger(), this.onDisposed.reset();
|
|
3010
3078
|
}
|
|
3011
3079
|
static setupBVH() {
|
|
3012
|
-
O.BufferGeometry.prototype.computeBoundsTree =
|
|
3080
|
+
O.BufferGeometry.prototype.computeBoundsTree = ar, O.BufferGeometry.prototype.disposeBoundsTree = cr, O.Mesh.prototype.raycast = rr;
|
|
3013
3081
|
}
|
|
3014
3082
|
};
|
|
3015
3083
|
/**
|
|
3016
3084
|
* The version of the @thatopen/components library.
|
|
3017
3085
|
*/
|
|
3018
|
-
I(Fs, "release", "2.1.
|
|
3086
|
+
I(Fs, "release", "2.1.17");
|
|
3019
3087
|
let pi = Fs;
|
|
3020
|
-
class
|
|
3088
|
+
class Fr {
|
|
3021
3089
|
constructor(s) {
|
|
3022
3090
|
I(this, "_event");
|
|
3023
3091
|
I(this, "_position", new O.Vector2());
|
|
@@ -3052,7 +3120,7 @@ class Ar {
|
|
|
3052
3120
|
s ? this.dom.addEventListener("pointermove", this.updateMouseInfo) : this.dom.removeEventListener("pointermove", this.updateMouseInfo);
|
|
3053
3121
|
}
|
|
3054
3122
|
}
|
|
3055
|
-
class
|
|
3123
|
+
class gr {
|
|
3056
3124
|
constructor(s, t) {
|
|
3057
3125
|
/** {@link Component.enabled} */
|
|
3058
3126
|
I(this, "enabled", !0);
|
|
@@ -3075,7 +3143,7 @@ class Fr {
|
|
|
3075
3143
|
const e = t.renderer;
|
|
3076
3144
|
if (!e)
|
|
3077
3145
|
throw new Error("A renderer is needed for the raycaster to work!");
|
|
3078
|
-
this.world = t, this.mouse = new
|
|
3146
|
+
this.world = t, this.mouse = new Fr(e.three.domElement), this.components = s;
|
|
3079
3147
|
}
|
|
3080
3148
|
/** {@link Disposable.dispose} */
|
|
3081
3149
|
dispose() {
|
|
@@ -3149,7 +3217,7 @@ const gs = class gs extends et {
|
|
|
3149
3217
|
get(t) {
|
|
3150
3218
|
if (this.list.has(t.uuid))
|
|
3151
3219
|
return this.list.get(t.uuid);
|
|
3152
|
-
const e = new
|
|
3220
|
+
const e = new gr(this.components, t);
|
|
3153
3221
|
return this.list.set(t.uuid, e), t.onDisposed.add(() => {
|
|
3154
3222
|
this.delete(t);
|
|
3155
3223
|
}), e;
|
|
@@ -3178,7 +3246,7 @@ const gs = class gs extends et {
|
|
|
3178
3246
|
*/
|
|
3179
3247
|
I(gs, "uuid", "d5d8bdf0-db25-4952-b951-b643af207ace");
|
|
3180
3248
|
let He = gs;
|
|
3181
|
-
class
|
|
3249
|
+
class Or extends _i {
|
|
3182
3250
|
constructor() {
|
|
3183
3251
|
super(...arguments);
|
|
3184
3252
|
/**
|
|
@@ -3278,7 +3346,7 @@ class gr extends _i {
|
|
|
3278
3346
|
this._scene = null, this._camera = null, this._renderer = null, this.onDisposed.trigger();
|
|
3279
3347
|
}
|
|
3280
3348
|
}
|
|
3281
|
-
class oa extends
|
|
3349
|
+
class oa extends Er {
|
|
3282
3350
|
constructor(t) {
|
|
3283
3351
|
super(t);
|
|
3284
3352
|
/** {@link Configurable.isSetup} */
|
|
@@ -3322,7 +3390,7 @@ class oa extends hr {
|
|
|
3322
3390
|
this.three.add(e, i), this.isSetup = !0, this.onSetup.trigger(this);
|
|
3323
3391
|
}
|
|
3324
3392
|
}
|
|
3325
|
-
class ra extends
|
|
3393
|
+
class ra extends hr {
|
|
3326
3394
|
/**
|
|
3327
3395
|
* Constructor for the SimpleRenderer class.
|
|
3328
3396
|
*
|
|
@@ -3455,17 +3523,17 @@ function Zt(l) {
|
|
|
3455
3523
|
function bt(l) {
|
|
3456
3524
|
return l.isOrthographicCamera;
|
|
3457
3525
|
}
|
|
3458
|
-
const he = Math.PI * 2,
|
|
3526
|
+
const he = Math.PI * 2, on = Math.PI / 2, bn = 1e-5, Ne = Math.PI / 180;
|
|
3459
3527
|
function mt(l, s, t) {
|
|
3460
3528
|
return Math.max(s, Math.min(t, l));
|
|
3461
3529
|
}
|
|
3462
|
-
function X(l, s =
|
|
3530
|
+
function X(l, s = bn) {
|
|
3463
3531
|
return Math.abs(l) < s;
|
|
3464
3532
|
}
|
|
3465
|
-
function W(l, s, t =
|
|
3533
|
+
function W(l, s, t = bn) {
|
|
3466
3534
|
return X(l - s, t);
|
|
3467
3535
|
}
|
|
3468
|
-
function
|
|
3536
|
+
function rn(l, s) {
|
|
3469
3537
|
return Math.round(l / s) * s;
|
|
3470
3538
|
}
|
|
3471
3539
|
function Pe(l) {
|
|
@@ -3485,7 +3553,7 @@ function hs(l, s, t, e, i = 1 / 0, o) {
|
|
|
3485
3553
|
let u = s + (c + E) * a;
|
|
3486
3554
|
return h - l > 0 == u > h && (u = h, t.value = (u - h) / o), u;
|
|
3487
3555
|
}
|
|
3488
|
-
function
|
|
3556
|
+
function an(l, s, t, e, i = 1 / 0, o, n) {
|
|
3489
3557
|
e = Math.max(1e-4, e);
|
|
3490
3558
|
const r = 2 / e, a = r * o, c = 1 / (1 + a + 0.48 * a * a + 0.235 * a * a * a);
|
|
3491
3559
|
let h = s.x, d = s.y, E = s.z, u = l.x - h, f = l.y - d, T = l.z - E;
|
|
@@ -3508,7 +3576,7 @@ function $s(l, s) {
|
|
|
3508
3576
|
function Js(l, s) {
|
|
3509
3577
|
return bt(l) ? (console.warn(`${s} is not supported in OrthographicCamera`), !0) : !1;
|
|
3510
3578
|
}
|
|
3511
|
-
class
|
|
3579
|
+
class Sr {
|
|
3512
3580
|
constructor() {
|
|
3513
3581
|
this._listeners = {};
|
|
3514
3582
|
}
|
|
@@ -3572,9 +3640,9 @@ class Or {
|
|
|
3572
3640
|
}
|
|
3573
3641
|
}
|
|
3574
3642
|
}
|
|
3575
|
-
const
|
|
3576
|
-
let Y,
|
|
3577
|
-
class ot extends
|
|
3643
|
+
const _r = "2.7.3", Es = 1 / 8, vn = typeof window < "u", Nr = vn && /Mac/.test(navigator.platform), Pr = !(vn && "PointerEvent" in window);
|
|
3644
|
+
let Y, cn, ds, ti, lt, G, z, Ee, ye, Ot, St, Qt, ln, hn, ut, Me, de, En, ei, dn, si, ii, us;
|
|
3645
|
+
class ot extends Sr {
|
|
3578
3646
|
/**
|
|
3579
3647
|
* Injects THREE as the dependency. You can then proceed to use CameraControls.
|
|
3580
3648
|
*
|
|
@@ -3616,7 +3684,7 @@ class ot extends Or {
|
|
|
3616
3684
|
* @category Statics
|
|
3617
3685
|
*/
|
|
3618
3686
|
static install(s) {
|
|
3619
|
-
Y = s.THREE,
|
|
3687
|
+
Y = s.THREE, cn = Object.freeze(new Y.Vector3(0, 0, 0)), ds = Object.freeze(new Y.Vector3(0, 1, 0)), ti = Object.freeze(new Y.Vector3(0, 0, 1)), lt = new Y.Vector2(), G = new Y.Vector3(), z = new Y.Vector3(), Ee = new Y.Vector3(), ye = new Y.Vector3(), Ot = new Y.Vector3(), St = new Y.Vector3(), Qt = new Y.Vector3(), ln = new Y.Vector3(), hn = new Y.Vector3(), ut = new Y.Spherical(), Me = new Y.Spherical(), de = new Y.Box3(), En = new Y.Box3(), ei = new Y.Sphere(), dn = new Y.Quaternion(), si = new Y.Quaternion(), ii = new Y.Matrix4(), us = new Y.Raycaster();
|
|
3620
3688
|
}
|
|
3621
3689
|
/**
|
|
3622
3690
|
* list all ACTIONs
|
|
@@ -3787,7 +3855,7 @@ class ot extends Or {
|
|
|
3787
3855
|
const N = performance.now();
|
|
3788
3856
|
E - N < 1e3 && this._getClientRect(this._elementRect), E = N;
|
|
3789
3857
|
}
|
|
3790
|
-
const m =
|
|
3858
|
+
const m = Nr ? -1 : -3, g = p.deltaMode === 1 ? p.deltaY / m : p.deltaY / (m * 10), S = this.dollyToCursor ? (p.clientX - this._elementRect.x) / this._elementRect.width * 2 - 1 : 0, _ = this.dollyToCursor ? (p.clientY - this._elementRect.y) / this._elementRect.height * -2 + 1 : 0;
|
|
3791
3859
|
switch (this.mouseButtons.wheel) {
|
|
3792
3860
|
case P.ROTATE: {
|
|
3793
3861
|
this._rotateInternal(p.deltaX, p.deltaY), this._isUserControllingRotate = !0;
|
|
@@ -3883,7 +3951,7 @@ class ot extends Or {
|
|
|
3883
3951
|
this.unlockPointer();
|
|
3884
3952
|
};
|
|
3885
3953
|
this._addAllEventListeners = (p) => {
|
|
3886
|
-
this._domElement = p, this._domElement.style.touchAction = "none", this._domElement.style.userSelect = "none", this._domElement.style.webkitUserSelect = "none", this._domElement.addEventListener("pointerdown", n),
|
|
3954
|
+
this._domElement = p, this._domElement.style.touchAction = "none", this._domElement.style.userSelect = "none", this._domElement.style.webkitUserSelect = "none", this._domElement.addEventListener("pointerdown", n), Pr && this._domElement.addEventListener("mousedown", r), this._domElement.addEventListener("pointercancel", h), this._domElement.addEventListener("wheel", u, { passive: !1 }), this._domElement.addEventListener("contextmenu", f);
|
|
3887
3955
|
}, this._removeAllEventListeners = () => {
|
|
3888
3956
|
this._domElement && (this._domElement.style.touchAction = "", this._domElement.style.userSelect = "", this._domElement.style.webkitUserSelect = "", this._domElement.removeEventListener("pointerdown", n), this._domElement.removeEventListener("mousedown", r), this._domElement.removeEventListener("pointercancel", h), this._domElement.removeEventListener("wheel", u, { passive: !1 }), this._domElement.removeEventListener("contextmenu", f), this._domElement.ownerDocument.removeEventListener("pointermove", a, { passive: !1 }), this._domElement.ownerDocument.removeEventListener("mousemove", c), this._domElement.ownerDocument.removeEventListener("pointerup", h), this._domElement.ownerDocument.removeEventListener("mouseup", d), this._domElement.ownerDocument.removeEventListener("pointerlockchange", A), this._domElement.ownerDocument.removeEventListener("pointerlockerror", F));
|
|
3889
3957
|
}, this.cancel = () => {
|
|
@@ -4252,11 +4320,11 @@ class ot extends Or {
|
|
|
4252
4320
|
fitToBox(s, t, { cover: e = !1, paddingLeft: i = 0, paddingRight: o = 0, paddingBottom: n = 0, paddingTop: r = 0 } = {}) {
|
|
4253
4321
|
const a = [], c = s.isBox3 ? de.copy(s) : de.setFromObject(s);
|
|
4254
4322
|
c.isEmpty() && (console.warn("camera-controls: fitTo() cannot be used with an empty box. Aborting"), Promise.resolve());
|
|
4255
|
-
const h =
|
|
4323
|
+
const h = rn(this._sphericalEnd.theta, on), d = rn(this._sphericalEnd.phi, on);
|
|
4256
4324
|
a.push(this.rotateTo(h, d, t));
|
|
4257
|
-
const E = G.setFromSpherical(this._sphericalEnd).normalize(), u =
|
|
4325
|
+
const E = G.setFromSpherical(this._sphericalEnd).normalize(), u = dn.setFromUnitVectors(E, ti), f = W(Math.abs(E.y), 1);
|
|
4258
4326
|
f && u.multiply(si.setFromAxisAngle(ds, h)), u.multiply(this._yAxisUpSpaceInverse);
|
|
4259
|
-
const T =
|
|
4327
|
+
const T = En.makeEmpty();
|
|
4260
4328
|
z.copy(c.min).applyQuaternion(u), T.expandByPoint(z), z.copy(c.min).setX(c.max.x).applyQuaternion(u), T.expandByPoint(z), z.copy(c.min).setY(c.max.y).applyQuaternion(u), T.expandByPoint(z), z.copy(c.max).setZ(c.min.z).applyQuaternion(u), T.expandByPoint(z), z.copy(c.min).setZ(c.max.z).applyQuaternion(u), T.expandByPoint(z), z.copy(c.max).setY(c.min.y).applyQuaternion(u), T.expandByPoint(z), z.copy(c.max).setX(c.min.x).applyQuaternion(u), T.expandByPoint(z), z.copy(c.max).applyQuaternion(u), T.expandByPoint(z), T.min.x -= i, T.min.y -= n, T.max.x += o, T.max.y += r, u.setFromUnitVectors(ti, E), f && u.premultiply(si.invert()), u.premultiply(this._yAxisUpSpace);
|
|
4261
4329
|
const R = T.getSize(G), C = T.getCenter(z).applyQuaternion(u);
|
|
4262
4330
|
if (Zt(this._camera)) {
|
|
@@ -4532,7 +4600,7 @@ class ot extends Or {
|
|
|
4532
4600
|
* @category Methods
|
|
4533
4601
|
*/
|
|
4534
4602
|
update(s) {
|
|
4535
|
-
const t = this._sphericalEnd.theta - this._spherical.theta, e = this._sphericalEnd.phi - this._spherical.phi, i = this._sphericalEnd.radius - this._spherical.radius, o =
|
|
4603
|
+
const t = this._sphericalEnd.theta - this._spherical.theta, e = this._sphericalEnd.phi - this._spherical.phi, i = this._sphericalEnd.radius - this._spherical.radius, o = ln.subVectors(this._targetEnd, this._target), n = hn.subVectors(this._focalOffsetEnd, this._focalOffset), r = this._zoomEnd - this._zoom;
|
|
4536
4604
|
if (X(t))
|
|
4537
4605
|
this._thetaVelocity.value = 0, this._spherical.theta = this._sphericalEnd.theta;
|
|
4538
4606
|
else {
|
|
@@ -4555,13 +4623,13 @@ class ot extends Or {
|
|
|
4555
4623
|
this._targetVelocity.set(0, 0, 0), this._target.copy(this._targetEnd);
|
|
4556
4624
|
else {
|
|
4557
4625
|
const d = this._isUserControllingTruck ? this.draggingSmoothTime : this.smoothTime;
|
|
4558
|
-
|
|
4626
|
+
an(this._target, this._targetEnd, this._targetVelocity, d, this.maxSpeed, s, this._target), this._needsUpdate = !0;
|
|
4559
4627
|
}
|
|
4560
4628
|
if (X(n.x) && X(n.y) && X(n.z))
|
|
4561
4629
|
this._focalOffsetVelocity.set(0, 0, 0), this._focalOffset.copy(this._focalOffsetEnd);
|
|
4562
4630
|
else {
|
|
4563
4631
|
const d = this._isUserControllingOffset ? this.draggingSmoothTime : this.smoothTime;
|
|
4564
|
-
|
|
4632
|
+
an(this._focalOffset, this._focalOffsetEnd, this._focalOffsetVelocity, d, this.maxSpeed, s, this._focalOffset), this._needsUpdate = !0;
|
|
4565
4633
|
}
|
|
4566
4634
|
if (X(r))
|
|
4567
4635
|
this._zoomVelocity.value = 0, this._zoom = this._zoomEnd;
|
|
@@ -4645,7 +4713,7 @@ class ot extends Or {
|
|
|
4645
4713
|
console.warn("camera-controls is already connected.");
|
|
4646
4714
|
return;
|
|
4647
4715
|
}
|
|
4648
|
-
s.setAttribute("data-camera-controls-version",
|
|
4716
|
+
s.setAttribute("data-camera-controls-version", _r), this._addAllEventListeners(s), this._getClientRect(this._elementRect);
|
|
4649
4717
|
}
|
|
4650
4718
|
/**
|
|
4651
4719
|
* Detach all internal event handlers to disable drag control.
|
|
@@ -4708,7 +4776,7 @@ class ot extends Or {
|
|
|
4708
4776
|
if (!(this.colliderMeshes.length >= 1) || Js(this._camera, "_collisionTest"))
|
|
4709
4777
|
return s;
|
|
4710
4778
|
const e = this._getTargetDirection(ye);
|
|
4711
|
-
ii.lookAt(
|
|
4779
|
+
ii.lookAt(cn, e, this._camera.up);
|
|
4712
4780
|
for (let i = 0; i < 4; i++) {
|
|
4713
4781
|
const o = z.copy(this._nearPlaneCorners[i]);
|
|
4714
4782
|
o.applyMatrix4(ii);
|
|
@@ -4790,7 +4858,7 @@ class ot extends Or {
|
|
|
4790
4858
|
}), e.radius = Math.sqrt(o), e;
|
|
4791
4859
|
}
|
|
4792
4860
|
}
|
|
4793
|
-
class We extends
|
|
4861
|
+
class We extends lr {
|
|
4794
4862
|
constructor(t) {
|
|
4795
4863
|
super(t);
|
|
4796
4864
|
/** {@link Updateable.onBeforeUpdate} */
|
|
@@ -4951,7 +5019,7 @@ const Os = class Os extends et {
|
|
|
4951
5019
|
* @throws {Error} - Throws an error if a world with the same UUID already exists in the list.
|
|
4952
5020
|
*/
|
|
4953
5021
|
create() {
|
|
4954
|
-
const t = new
|
|
5022
|
+
const t = new Or(this.components), e = t.uuid;
|
|
4955
5023
|
if (this.list.has(e))
|
|
4956
5024
|
throw new Error("There is already a world with this name!");
|
|
4957
5025
|
return this.list.set(e, t), this.onWorldCreated.trigger(t), t;
|
|
@@ -4997,7 +5065,7 @@ const Os = class Os extends et {
|
|
|
4997
5065
|
*/
|
|
4998
5066
|
I(Os, "uuid", "fdb61dc4-2ec1-4966-b83d-54ea795fad4a");
|
|
4999
5067
|
let Ci = Os;
|
|
5000
|
-
class
|
|
5068
|
+
class Lr {
|
|
5001
5069
|
constructor(s, t, e) {
|
|
5002
5070
|
/** {@link Disposable.onDisposed} */
|
|
5003
5071
|
I(this, "onDisposed", new w());
|
|
@@ -5177,7 +5245,7 @@ const Ss = class Ss extends et {
|
|
|
5177
5245
|
create(t) {
|
|
5178
5246
|
if (this.list.has(t.uuid))
|
|
5179
5247
|
throw new Error("This world already has a grid!");
|
|
5180
|
-
const e = new
|
|
5248
|
+
const e = new Lr(this.components, t, this.config);
|
|
5181
5249
|
return this.list.set(t.uuid, e), t.onDisposed.add(() => {
|
|
5182
5250
|
this.delete(t);
|
|
5183
5251
|
}), e;
|
|
@@ -5208,18 +5276,18 @@ const Ss = class Ss extends et {
|
|
|
5208
5276
|
* This UUID is used to register the component within the Components system.
|
|
5209
5277
|
*/
|
|
5210
5278
|
I(Ss, "uuid", "d1e814d5-b81c-4452-87a2-f039375e0489");
|
|
5211
|
-
let
|
|
5212
|
-
const jt = new
|
|
5279
|
+
let un = Ss;
|
|
5280
|
+
const jt = new Kn(), nt = new M(), xt = new M(), j = new Pt(), In = {
|
|
5213
5281
|
X: new M(1, 0, 0),
|
|
5214
5282
|
Y: new M(0, 1, 0),
|
|
5215
5283
|
Z: new M(0, 0, 1)
|
|
5216
|
-
}, ni = { type: "change" },
|
|
5217
|
-
class
|
|
5284
|
+
}, ni = { type: "change" }, fn = { type: "mouseDown" }, pn = { type: "mouseUp", mode: null }, Cn = { type: "objectChange" };
|
|
5285
|
+
class yr extends ri {
|
|
5218
5286
|
constructor(s, t) {
|
|
5219
5287
|
super(), t === void 0 && (console.warn('THREE.TransformControls: The second parameter "domElement" is now mandatory.'), t = document), this.isTransformControls = !0, this.visible = !1, this.domElement = t, this.domElement.style.touchAction = "none";
|
|
5220
|
-
const e = new
|
|
5288
|
+
const e = new br();
|
|
5221
5289
|
this._gizmo = e, this.add(e);
|
|
5222
|
-
const i = new
|
|
5290
|
+
const i = new vr();
|
|
5223
5291
|
this._plane = i, this.add(i);
|
|
5224
5292
|
const o = this;
|
|
5225
5293
|
function n(A, F) {
|
|
@@ -5235,7 +5303,7 @@ class Lr extends ri {
|
|
|
5235
5303
|
}
|
|
5236
5304
|
n("camera", s), n("object", void 0), n("enabled", !0), n("axis", null), n("mode", "translate"), n("translationSnap", null), n("rotationSnap", null), n("scaleSnap", null), n("space", "world"), n("size", 1), n("dragging", !1), n("showX", !0), n("showY", !0), n("showZ", !0);
|
|
5237
5305
|
const r = new M(), a = new M(), c = new Pt(), h = new Pt(), d = new M(), E = new Pt(), u = new M(), f = new M(), T = new M(), R = 0, C = new M();
|
|
5238
|
-
n("worldPosition", r), n("worldPositionStart", a), n("worldQuaternion", c), n("worldQuaternionStart", h), n("cameraPosition", d), n("cameraQuaternion", E), n("pointStart", u), n("pointEnd", f), n("rotationAxis", T), n("rotationAngle", R), n("eye", C), this._offset = new M(), this._startNorm = new M(), this._endNorm = new M(), this._cameraScale = new M(), this._parentPosition = new M(), this._parentQuaternion = new Pt(), this._parentQuaternionInv = new Pt(), this._parentScale = new M(), this._worldScaleStart = new M(), this._worldQuaternionInv = new Pt(), this._worldScale = new M(), this._positionStart = new M(), this._quaternionStart = new Pt(), this._scaleStart = new M(), this._getPointer =
|
|
5306
|
+
n("worldPosition", r), n("worldPositionStart", a), n("worldQuaternion", c), n("worldQuaternionStart", h), n("cameraPosition", d), n("cameraQuaternion", E), n("pointStart", u), n("pointEnd", f), n("rotationAxis", T), n("rotationAngle", R), n("eye", C), this._offset = new M(), this._startNorm = new M(), this._endNorm = new M(), this._cameraScale = new M(), this._parentPosition = new M(), this._parentQuaternion = new Pt(), this._parentQuaternionInv = new Pt(), this._parentScale = new M(), this._worldScaleStart = new M(), this._worldQuaternionInv = new Pt(), this._worldScale = new M(), this._positionStart = new M(), this._quaternionStart = new Pt(), this._scaleStart = new M(), this._getPointer = Mr.bind(this), this._onPointerDown = Dr.bind(this), this._onPointerHover = wr.bind(this), this._onPointerMove = Ur.bind(this), this._onPointerUp = xr.bind(this), this.domElement.addEventListener("pointerdown", this._onPointerDown), this.domElement.addEventListener("pointermove", this._onPointerHover), this.domElement.addEventListener("pointerup", this._onPointerUp);
|
|
5239
5307
|
}
|
|
5240
5308
|
// updateMatrixWorld updates key transformation variables
|
|
5241
5309
|
updateMatrixWorld() {
|
|
@@ -5252,7 +5320,7 @@ class Lr extends ri {
|
|
|
5252
5320
|
if (!(this.object === void 0 || this.dragging === !0 || s.button !== 0) && this.axis !== null) {
|
|
5253
5321
|
jt.setFromCamera(s, this.camera);
|
|
5254
5322
|
const t = oi(this._plane, jt, !0);
|
|
5255
|
-
t && (this.object.updateMatrixWorld(), this.object.parent.updateMatrixWorld(), this._positionStart.copy(this.object.position), this._quaternionStart.copy(this.object.quaternion), this._scaleStart.copy(this.object.scale), this.object.matrixWorld.decompose(this.worldPositionStart, this.worldQuaternionStart, this._worldScaleStart), this.pointStart.copy(t.point).sub(this.worldPositionStart)), this.dragging = !0,
|
|
5323
|
+
t && (this.object.updateMatrixWorld(), this.object.parent.updateMatrixWorld(), this._positionStart.copy(this.object.position), this._quaternionStart.copy(this.object.quaternion), this._scaleStart.copy(this.object.scale), this.object.matrixWorld.decompose(this.worldPositionStart, this.worldQuaternionStart, this._worldScaleStart), this.pointStart.copy(t.point).sub(this.worldPositionStart)), this.dragging = !0, fn.mode = this.mode, this.dispatchEvent(fn);
|
|
5256
5324
|
}
|
|
5257
5325
|
}
|
|
5258
5326
|
pointerMove(s) {
|
|
@@ -5276,13 +5344,13 @@ class Lr extends ri {
|
|
|
5276
5344
|
this._offset.copy(this.pointEnd).sub(this.pointStart);
|
|
5277
5345
|
const r = 20 / this.worldPosition.distanceTo(nt.setFromMatrixPosition(this.camera.matrixWorld));
|
|
5278
5346
|
let a = !1;
|
|
5279
|
-
t === "XYZE" ? (this.rotationAxis.copy(this._offset).cross(this.eye).normalize(), this.rotationAngle = this._offset.dot(nt.copy(this.rotationAxis).cross(this.eye)) * r) : (t === "X" || t === "Y" || t === "Z") && (this.rotationAxis.copy(
|
|
5347
|
+
t === "XYZE" ? (this.rotationAxis.copy(this._offset).cross(this.eye).normalize(), this.rotationAngle = this._offset.dot(nt.copy(this.rotationAxis).cross(this.eye)) * r) : (t === "X" || t === "Y" || t === "Z") && (this.rotationAxis.copy(In[t]), nt.copy(In[t]), o === "local" && nt.applyQuaternion(this.worldQuaternion), nt.cross(this.eye), nt.length() === 0 ? a = !0 : this.rotationAngle = this._offset.dot(nt.normalize()) * r), (t === "E" || a) && (this.rotationAxis.copy(this.eye), this.rotationAngle = this.pointEnd.angleTo(this.pointStart), this._startNorm.copy(this.pointStart).normalize(), this._endNorm.copy(this.pointEnd).normalize(), this.rotationAngle *= this._endNorm.cross(this._startNorm).dot(this.eye) < 0 ? 1 : -1), this.rotationSnap && (this.rotationAngle = Math.round(this.rotationAngle / this.rotationSnap) * this.rotationSnap), o === "local" && t !== "E" && t !== "XYZE" ? (i.quaternion.copy(this._quaternionStart), i.quaternion.multiply(j.setFromAxisAngle(this.rotationAxis, this.rotationAngle)).normalize()) : (this.rotationAxis.applyQuaternion(this._parentQuaternionInv), i.quaternion.copy(j.setFromAxisAngle(this.rotationAxis, this.rotationAngle)), i.quaternion.multiply(this._quaternionStart).normalize());
|
|
5280
5348
|
}
|
|
5281
|
-
this.dispatchEvent(ni), this.dispatchEvent(
|
|
5349
|
+
this.dispatchEvent(ni), this.dispatchEvent(Cn);
|
|
5282
5350
|
}
|
|
5283
5351
|
}
|
|
5284
5352
|
pointerUp(s) {
|
|
5285
|
-
s.button === 0 && (this.dragging && this.axis !== null && (
|
|
5353
|
+
s.button === 0 && (this.dragging && this.axis !== null && (pn.mode = this.mode, this.dispatchEvent(pn)), this.dragging = !1, this.axis = null);
|
|
5286
5354
|
}
|
|
5287
5355
|
dispose() {
|
|
5288
5356
|
this.domElement.removeEventListener("pointerdown", this._onPointerDown), this.domElement.removeEventListener("pointermove", this._onPointerHover), this.domElement.removeEventListener("pointermove", this._onPointerMove), this.domElement.removeEventListener("pointerup", this._onPointerUp), this.traverse(function(s) {
|
|
@@ -5298,7 +5366,7 @@ class Lr extends ri {
|
|
|
5298
5366
|
return this.object = void 0, this.visible = !1, this.axis = null, this;
|
|
5299
5367
|
}
|
|
5300
5368
|
reset() {
|
|
5301
|
-
this.enabled && this.dragging && (this.object.position.copy(this._positionStart), this.object.quaternion.copy(this._quaternionStart), this.object.scale.copy(this._scaleStart), this.dispatchEvent(ni), this.dispatchEvent(
|
|
5369
|
+
this.enabled && this.dragging && (this.object.position.copy(this._positionStart), this.object.quaternion.copy(this._quaternionStart), this.object.scale.copy(this._scaleStart), this.dispatchEvent(ni), this.dispatchEvent(Cn), this.pointStart.copy(this.pointEnd));
|
|
5302
5370
|
}
|
|
5303
5371
|
getRaycaster() {
|
|
5304
5372
|
return jt;
|
|
@@ -5326,7 +5394,7 @@ class Lr extends ri {
|
|
|
5326
5394
|
this.space = s;
|
|
5327
5395
|
}
|
|
5328
5396
|
}
|
|
5329
|
-
function
|
|
5397
|
+
function Mr(l) {
|
|
5330
5398
|
if (this.domElement.ownerDocument.pointerLockElement)
|
|
5331
5399
|
return {
|
|
5332
5400
|
x: 0,
|
|
@@ -5342,7 +5410,7 @@ function yr(l) {
|
|
|
5342
5410
|
};
|
|
5343
5411
|
}
|
|
5344
5412
|
}
|
|
5345
|
-
function
|
|
5413
|
+
function wr(l) {
|
|
5346
5414
|
if (this.enabled)
|
|
5347
5415
|
switch (l.pointerType) {
|
|
5348
5416
|
case "mouse":
|
|
@@ -5351,13 +5419,13 @@ function Mr(l) {
|
|
|
5351
5419
|
break;
|
|
5352
5420
|
}
|
|
5353
5421
|
}
|
|
5354
|
-
function
|
|
5422
|
+
function Dr(l) {
|
|
5355
5423
|
this.enabled && (document.pointerLockElement || this.domElement.setPointerCapture(l.pointerId), this.domElement.addEventListener("pointermove", this._onPointerMove), this.pointerHover(this._getPointer(l)), this.pointerDown(this._getPointer(l)));
|
|
5356
5424
|
}
|
|
5357
|
-
function
|
|
5425
|
+
function Ur(l) {
|
|
5358
5426
|
this.enabled && this.pointerMove(this._getPointer(l));
|
|
5359
5427
|
}
|
|
5360
|
-
function
|
|
5428
|
+
function xr(l) {
|
|
5361
5429
|
this.enabled && (this.domElement.releasePointerCapture(l.pointerId), this.domElement.removeEventListener("pointermove", this._onPointerMove), this.pointerUp(this._getPointer(l)));
|
|
5362
5430
|
}
|
|
5363
5431
|
function oi(l, s, t) {
|
|
@@ -5367,17 +5435,17 @@ function oi(l, s, t) {
|
|
|
5367
5435
|
return e[i];
|
|
5368
5436
|
return !1;
|
|
5369
5437
|
}
|
|
5370
|
-
const Is = new
|
|
5371
|
-
class
|
|
5438
|
+
const Is = new $n(), k = new M(0, 1, 0), Tn = new M(0, 0, 0), mn = new yt(), fs = new Pt(), Rs = new Pt(), _t = new M(), Rn = new yt(), Ue = new M(1, 0, 0), qt = new M(0, 1, 0), xe = new M(0, 0, 1), ps = new M(), we = new M(), De = new M();
|
|
5439
|
+
class br extends ri {
|
|
5372
5440
|
constructor() {
|
|
5373
5441
|
super(), this.isTransformControlsGizmo = !0, this.type = "TransformControlsGizmo";
|
|
5374
|
-
const s = new
|
|
5442
|
+
const s = new Mn({
|
|
5375
5443
|
depthTest: !1,
|
|
5376
5444
|
depthWrite: !1,
|
|
5377
5445
|
fog: !1,
|
|
5378
5446
|
toneMapped: !1,
|
|
5379
5447
|
transparent: !0
|
|
5380
|
-
}), t = new
|
|
5448
|
+
}), t = new Jn({
|
|
5381
5449
|
depthTest: !1,
|
|
5382
5450
|
depthWrite: !1,
|
|
5383
5451
|
fog: !1,
|
|
@@ -5515,7 +5583,7 @@ class xr extends ri {
|
|
|
5515
5583
|
]
|
|
5516
5584
|
}, L = {
|
|
5517
5585
|
XYZE: [
|
|
5518
|
-
[new v(new
|
|
5586
|
+
[new v(new to(0.25, 10, 8), e)]
|
|
5519
5587
|
],
|
|
5520
5588
|
X: [
|
|
5521
5589
|
[new v(new Re(0.5, 0.1, 4, 24), e), [0, 0, 0], [0, -Math.PI / 2, -Math.PI / 2]]
|
|
@@ -5617,21 +5685,21 @@ class xr extends ri {
|
|
|
5617
5685
|
n.visible = !0, n.rotation.set(0, 0, 0), n.position.copy(this.worldPosition);
|
|
5618
5686
|
let r;
|
|
5619
5687
|
if (this.camera.isOrthographicCamera ? r = (this.camera.top - this.camera.bottom) / this.camera.zoom : r = this.worldPosition.distanceTo(this.cameraPosition) * Math.min(1.9 * Math.tan(Math.PI * this.camera.fov / 360) / this.camera.zoom, 7), n.scale.set(1, 1, 1).multiplyScalar(r * this.size / 4), n.tag === "helper") {
|
|
5620
|
-
n.visible = !1, n.name === "AXIS" ? (n.visible = !!this.axis, this.axis === "X" && (j.setFromEuler(Is.set(0, 0, 0)), n.quaternion.copy(e).multiply(j), Math.abs(k.copy(Ue).applyQuaternion(e).dot(this.eye)) > 0.9 && (n.visible = !1)), this.axis === "Y" && (j.setFromEuler(Is.set(0, 0, Math.PI / 2)), n.quaternion.copy(e).multiply(j), Math.abs(k.copy(qt).applyQuaternion(e).dot(this.eye)) > 0.9 && (n.visible = !1)), this.axis === "Z" && (j.setFromEuler(Is.set(0, Math.PI / 2, 0)), n.quaternion.copy(e).multiply(j), Math.abs(k.copy(xe).applyQuaternion(e).dot(this.eye)) > 0.9 && (n.visible = !1)), this.axis === "XYZE" && (j.setFromEuler(Is.set(0, Math.PI / 2, 0)), k.copy(this.rotationAxis), n.quaternion.setFromRotationMatrix(
|
|
5688
|
+
n.visible = !1, n.name === "AXIS" ? (n.visible = !!this.axis, this.axis === "X" && (j.setFromEuler(Is.set(0, 0, 0)), n.quaternion.copy(e).multiply(j), Math.abs(k.copy(Ue).applyQuaternion(e).dot(this.eye)) > 0.9 && (n.visible = !1)), this.axis === "Y" && (j.setFromEuler(Is.set(0, 0, Math.PI / 2)), n.quaternion.copy(e).multiply(j), Math.abs(k.copy(qt).applyQuaternion(e).dot(this.eye)) > 0.9 && (n.visible = !1)), this.axis === "Z" && (j.setFromEuler(Is.set(0, Math.PI / 2, 0)), n.quaternion.copy(e).multiply(j), Math.abs(k.copy(xe).applyQuaternion(e).dot(this.eye)) > 0.9 && (n.visible = !1)), this.axis === "XYZE" && (j.setFromEuler(Is.set(0, Math.PI / 2, 0)), k.copy(this.rotationAxis), n.quaternion.setFromRotationMatrix(mn.lookAt(Tn, k, qt)), n.quaternion.multiply(j), n.visible = this.dragging), this.axis === "E" && (n.visible = !1)) : n.name === "START" ? (n.position.copy(this.worldPositionStart), n.visible = this.dragging) : n.name === "END" ? (n.position.copy(this.worldPosition), n.visible = this.dragging) : n.name === "DELTA" ? (n.position.copy(this.worldPositionStart), n.quaternion.copy(this.worldQuaternionStart), nt.set(1e-10, 1e-10, 1e-10).add(this.worldPositionStart).sub(this.worldPosition).multiplyScalar(-1), nt.applyQuaternion(this.worldQuaternionStart.clone().invert()), n.scale.copy(nt), n.visible = this.dragging) : (n.quaternion.copy(e), this.dragging ? n.position.copy(this.worldPositionStart) : n.position.copy(this.worldPosition), this.axis && (n.visible = this.axis.search(n.name) !== -1));
|
|
5621
5689
|
continue;
|
|
5622
5690
|
}
|
|
5623
|
-
n.quaternion.copy(e), this.mode === "translate" || this.mode === "scale" ? (n.name === "X" && Math.abs(k.copy(Ue).applyQuaternion(e).dot(this.eye)) > 0.99 && (n.scale.set(1e-10, 1e-10, 1e-10), n.visible = !1), n.name === "Y" && Math.abs(k.copy(qt).applyQuaternion(e).dot(this.eye)) > 0.99 && (n.scale.set(1e-10, 1e-10, 1e-10), n.visible = !1), n.name === "Z" && Math.abs(k.copy(xe).applyQuaternion(e).dot(this.eye)) > 0.99 && (n.scale.set(1e-10, 1e-10, 1e-10), n.visible = !1), n.name === "XY" && Math.abs(k.copy(xe).applyQuaternion(e).dot(this.eye)) < 0.2 && (n.scale.set(1e-10, 1e-10, 1e-10), n.visible = !1), n.name === "YZ" && Math.abs(k.copy(Ue).applyQuaternion(e).dot(this.eye)) < 0.2 && (n.scale.set(1e-10, 1e-10, 1e-10), n.visible = !1), n.name === "XZ" && Math.abs(k.copy(qt).applyQuaternion(e).dot(this.eye)) < 0.2 && (n.scale.set(1e-10, 1e-10, 1e-10), n.visible = !1)) : this.mode === "rotate" && (fs.copy(e), k.copy(this.eye).applyQuaternion(j.copy(e).invert()), n.name.search("E") !== -1 && n.quaternion.setFromRotationMatrix(
|
|
5691
|
+
n.quaternion.copy(e), this.mode === "translate" || this.mode === "scale" ? (n.name === "X" && Math.abs(k.copy(Ue).applyQuaternion(e).dot(this.eye)) > 0.99 && (n.scale.set(1e-10, 1e-10, 1e-10), n.visible = !1), n.name === "Y" && Math.abs(k.copy(qt).applyQuaternion(e).dot(this.eye)) > 0.99 && (n.scale.set(1e-10, 1e-10, 1e-10), n.visible = !1), n.name === "Z" && Math.abs(k.copy(xe).applyQuaternion(e).dot(this.eye)) > 0.99 && (n.scale.set(1e-10, 1e-10, 1e-10), n.visible = !1), n.name === "XY" && Math.abs(k.copy(xe).applyQuaternion(e).dot(this.eye)) < 0.2 && (n.scale.set(1e-10, 1e-10, 1e-10), n.visible = !1), n.name === "YZ" && Math.abs(k.copy(Ue).applyQuaternion(e).dot(this.eye)) < 0.2 && (n.scale.set(1e-10, 1e-10, 1e-10), n.visible = !1), n.name === "XZ" && Math.abs(k.copy(qt).applyQuaternion(e).dot(this.eye)) < 0.2 && (n.scale.set(1e-10, 1e-10, 1e-10), n.visible = !1)) : this.mode === "rotate" && (fs.copy(e), k.copy(this.eye).applyQuaternion(j.copy(e).invert()), n.name.search("E") !== -1 && n.quaternion.setFromRotationMatrix(mn.lookAt(this.eye, Tn, qt)), n.name === "X" && (j.setFromAxisAngle(Ue, Math.atan2(-k.y, k.z)), j.multiplyQuaternions(fs, j), n.quaternion.copy(j)), n.name === "Y" && (j.setFromAxisAngle(qt, Math.atan2(k.x, k.z)), j.multiplyQuaternions(fs, j), n.quaternion.copy(j)), n.name === "Z" && (j.setFromAxisAngle(xe, Math.atan2(k.y, k.x)), j.multiplyQuaternions(fs, j), n.quaternion.copy(j))), n.visible = n.visible && (n.name.indexOf("X") === -1 || this.showX), n.visible = n.visible && (n.name.indexOf("Y") === -1 || this.showY), n.visible = n.visible && (n.name.indexOf("Z") === -1 || this.showZ), n.visible = n.visible && (n.name.indexOf("E") === -1 || this.showX && this.showY && this.showZ), n.material._color = n.material._color || n.material.color.clone(), n.material._opacity = n.material._opacity || n.material.opacity, n.material.color.copy(n.material._color), n.material.opacity = n.material._opacity, this.enabled && this.axis && (n.name === this.axis || this.axis.split("").some(function(a) {
|
|
5624
5692
|
return n.name === a;
|
|
5625
5693
|
})) && (n.material.color.setHex(16776960), n.material.opacity = 1);
|
|
5626
5694
|
}
|
|
5627
5695
|
super.updateMatrixWorld(s);
|
|
5628
5696
|
}
|
|
5629
5697
|
}
|
|
5630
|
-
class
|
|
5698
|
+
class vr extends v {
|
|
5631
5699
|
constructor() {
|
|
5632
5700
|
super(
|
|
5633
|
-
new
|
|
5634
|
-
new
|
|
5701
|
+
new eo(1e5, 1e5, 2, 2),
|
|
5702
|
+
new Mn({ visible: !1, wireframe: !0, side: yn, transparent: !0, opacity: 0.1, toneMapped: !1 })
|
|
5635
5703
|
), this.isTransformControlsPlane = !0, this.type = "TransformControlsPlane";
|
|
5636
5704
|
}
|
|
5637
5705
|
updateMatrixWorld(s) {
|
|
@@ -5668,7 +5736,7 @@ class br extends v {
|
|
|
5668
5736
|
default:
|
|
5669
5737
|
_t.set(0, 0, 0);
|
|
5670
5738
|
}
|
|
5671
|
-
_t.length() === 0 ? this.quaternion.copy(this.cameraQuaternion) : (
|
|
5739
|
+
_t.length() === 0 ? this.quaternion.copy(this.cameraQuaternion) : (Rn.lookAt(nt.set(0, 0, 0), _t, k), this.quaternion.setFromRotationMatrix(Rn)), super.updateMatrixWorld(s);
|
|
5672
5740
|
}
|
|
5673
5741
|
}
|
|
5674
5742
|
class Pi {
|
|
@@ -5809,7 +5877,7 @@ class Pi {
|
|
|
5809
5877
|
newTransformControls() {
|
|
5810
5878
|
if (!this.world.renderer)
|
|
5811
5879
|
throw new Error("No renderer found for clipping plane!");
|
|
5812
|
-
const s = this.world.camera.three, t = this.world.renderer.three.domElement, e = new
|
|
5880
|
+
const s = this.world.camera.three, t = this.world.renderer.three.domElement, e = new yr(s, t);
|
|
5813
5881
|
return this.initializeControls(e), this.world.scene.three.add(e), e;
|
|
5814
5882
|
}
|
|
5815
5883
|
initializeControls(s) {
|
|
@@ -6074,8 +6142,8 @@ const Be = class Be extends et {
|
|
|
6074
6142
|
* This UUID is used to register the component within the Components system.
|
|
6075
6143
|
*/
|
|
6076
6144
|
I(Be, "uuid", "66290bc5-18c4-4cd1-9379-2e17a0617611");
|
|
6077
|
-
let
|
|
6078
|
-
function
|
|
6145
|
+
let An = Be;
|
|
6146
|
+
function Br(l, s, t, e) {
|
|
6079
6147
|
return new Promise((i, o) => {
|
|
6080
6148
|
function n() {
|
|
6081
6149
|
const r = l.clientWaitSync(s, t, 0);
|
|
@@ -6092,15 +6160,15 @@ function vr(l, s, t, e) {
|
|
|
6092
6160
|
n();
|
|
6093
6161
|
});
|
|
6094
6162
|
}
|
|
6095
|
-
async function
|
|
6163
|
+
async function Yr(l, s, t, e, i, o, n) {
|
|
6096
6164
|
const r = l.fenceSync(l.SYNC_GPU_COMMANDS_COMPLETE, 0);
|
|
6097
|
-
l.flush(), await
|
|
6165
|
+
l.flush(), await Br(l, r, 0, 10), l.deleteSync(r), l.bindBuffer(s, t), l.getBufferSubData(s, e, i, o, n), l.bindBuffer(s, null);
|
|
6098
6166
|
}
|
|
6099
|
-
async function
|
|
6167
|
+
async function Vr(l, s, t, e, i, o, n, r) {
|
|
6100
6168
|
const a = l.createBuffer();
|
|
6101
|
-
return l.bindBuffer(l.PIXEL_PACK_BUFFER, a), l.bufferData(l.PIXEL_PACK_BUFFER, r.byteLength, l.STREAM_READ), l.readPixels(s, t, e, i, o, n, 0), l.bindBuffer(l.PIXEL_PACK_BUFFER, null), await
|
|
6169
|
+
return l.bindBuffer(l.PIXEL_PACK_BUFFER, a), l.bufferData(l.PIXEL_PACK_BUFFER, r.byteLength, l.STREAM_READ), l.readPixels(s, t, e, i, o, n, 0), l.bindBuffer(l.PIXEL_PACK_BUFFER, null), await Yr(l, l.PIXEL_PACK_BUFFER, a, 0, r), l.deleteBuffer(a), r;
|
|
6102
6170
|
}
|
|
6103
|
-
class
|
|
6171
|
+
class Gr {
|
|
6104
6172
|
constructor(s, t, e) {
|
|
6105
6173
|
/** {@link Disposable.onDisposed} */
|
|
6106
6174
|
I(this, "onDisposed", new w());
|
|
@@ -6155,7 +6223,7 @@ class Vr {
|
|
|
6155
6223
|
const t = this.world.camera.three;
|
|
6156
6224
|
t.updateMatrix(), this.renderer.setSize(this._width, this._height), this.renderer.setRenderTarget(this.renderTarget), this.renderer.render(this.scene, t);
|
|
6157
6225
|
const e = this.renderer.getContext();
|
|
6158
|
-
await
|
|
6226
|
+
await Vr(
|
|
6159
6227
|
e,
|
|
6160
6228
|
0,
|
|
6161
6229
|
0,
|
|
@@ -6227,7 +6295,7 @@ class Vr {
|
|
|
6227
6295
|
s && (s.updateInterval !== void 0 && (this.updateInterval = s.updateInterval), s.height !== void 0 && (this._height = s.height), s.width !== void 0 && (this._width = s.width), s.autoUpdate !== void 0 && (this.autoUpdate = s.autoUpdate));
|
|
6228
6296
|
}
|
|
6229
6297
|
}
|
|
6230
|
-
class
|
|
6298
|
+
class zr extends Gr {
|
|
6231
6299
|
constructor(t, e, i) {
|
|
6232
6300
|
super(t, e, i);
|
|
6233
6301
|
/**
|
|
@@ -6313,13 +6381,13 @@ class Gr extends Vr {
|
|
|
6313
6381
|
let d = !0;
|
|
6314
6382
|
const E = [];
|
|
6315
6383
|
for (const u of o)
|
|
6316
|
-
|
|
6384
|
+
nn.isTransparent(u) ? E.push(this._transparentMat) : (d = !1, E.push(n));
|
|
6317
6385
|
if (d) {
|
|
6318
6386
|
n.dispose(), this.isProcessing = !1;
|
|
6319
6387
|
return;
|
|
6320
6388
|
}
|
|
6321
6389
|
a = E;
|
|
6322
|
-
} else if (
|
|
6390
|
+
} else if (nn.isTransparent(o)) {
|
|
6323
6391
|
n.dispose(), this.isProcessing = !1;
|
|
6324
6392
|
return;
|
|
6325
6393
|
} else
|
|
@@ -6412,7 +6480,7 @@ const Ye = class Ye extends et {
|
|
|
6412
6480
|
create(t, e) {
|
|
6413
6481
|
if (this.list.has(t.uuid))
|
|
6414
6482
|
return this.list.get(t.uuid);
|
|
6415
|
-
const i = new
|
|
6483
|
+
const i = new zr(this.components, t, e);
|
|
6416
6484
|
return this.list.set(t.uuid, i), i;
|
|
6417
6485
|
}
|
|
6418
6486
|
/**
|
|
@@ -6452,7 +6520,7 @@ const Ye = class Ye extends et {
|
|
|
6452
6520
|
*/
|
|
6453
6521
|
I(Ye, "uuid", "69f2a50d-c266-44fc-b1bd-fa4d34be89e6");
|
|
6454
6522
|
let Ti = Ye;
|
|
6455
|
-
class
|
|
6523
|
+
class Hr {
|
|
6456
6524
|
constructor(s) {
|
|
6457
6525
|
/** {@link Disposable.onDisposed} */
|
|
6458
6526
|
I(this, "onDisposed", new w());
|
|
@@ -6621,7 +6689,7 @@ const _s = class _s extends et {
|
|
|
6621
6689
|
create(t) {
|
|
6622
6690
|
if (this.list.has(t.uuid))
|
|
6623
6691
|
throw new Error("This world already has a minimap!");
|
|
6624
|
-
const e = new
|
|
6692
|
+
const e = new Hr(t);
|
|
6625
6693
|
return this.list.set(t.uuid, e), e;
|
|
6626
6694
|
}
|
|
6627
6695
|
/**
|
|
@@ -6652,8 +6720,8 @@ const _s = class _s extends et {
|
|
|
6652
6720
|
* This UUID is used to register the component within the Components system.
|
|
6653
6721
|
*/
|
|
6654
6722
|
I(_s, "uuid", "39ad6aad-84c8-4adf-a1e0-7f25313a9e7f");
|
|
6655
|
-
let
|
|
6656
|
-
class
|
|
6723
|
+
let Fn = _s;
|
|
6724
|
+
class Wr {
|
|
6657
6725
|
constructor(s) {
|
|
6658
6726
|
/** {@link NavigationMode.enabled} */
|
|
6659
6727
|
I(this, "enabled", !1);
|
|
@@ -6680,7 +6748,7 @@ class Hr {
|
|
|
6680
6748
|
), s.truckSpeed = 50, s.mouseButtons.wheel = ot.ACTION.DOLLY, s.touches.two = ot.ACTION.TOUCH_ZOOM_TRUCK;
|
|
6681
6749
|
}
|
|
6682
6750
|
}
|
|
6683
|
-
class
|
|
6751
|
+
class kr {
|
|
6684
6752
|
constructor(s) {
|
|
6685
6753
|
/** {@link NavigationMode.enabled} */
|
|
6686
6754
|
I(this, "enabled", !0);
|
|
@@ -6703,7 +6771,7 @@ class Wr {
|
|
|
6703
6771
|
s.moveTo(n.x, n.y, n.z);
|
|
6704
6772
|
}
|
|
6705
6773
|
}
|
|
6706
|
-
class
|
|
6774
|
+
class Xr {
|
|
6707
6775
|
constructor(s) {
|
|
6708
6776
|
/** {@link NavigationMode.enabled} */
|
|
6709
6777
|
I(this, "enabled", !1);
|
|
@@ -6723,7 +6791,7 @@ class kr {
|
|
|
6723
6791
|
t.azimuthRotateSpeed = s ? 0 : this.defaultAzimuthSpeed, t.polarRotateSpeed = s ? 0 : this.defaultPolarSpeed, this.mouseInitialized || (this.mouseAction1 = t.touches.one, this.mouseAction2 = t.touches.two, this.mouseInitialized = !0), s ? (t.mouseButtons.left = ot.ACTION.TRUCK, t.touches.one = ot.ACTION.TOUCH_TRUCK, t.touches.two = ot.ACTION.TOUCH_ZOOM) : (t.mouseButtons.left = ot.ACTION.ROTATE, t.touches.one = this.mouseAction1, t.touches.two = this.mouseAction2);
|
|
6724
6792
|
}
|
|
6725
6793
|
}
|
|
6726
|
-
class
|
|
6794
|
+
class Zr {
|
|
6727
6795
|
constructor(s) {
|
|
6728
6796
|
/**
|
|
6729
6797
|
* Event that fires when the {@link CameraProjection} changes.
|
|
@@ -6820,14 +6888,14 @@ class aa extends We {
|
|
|
6820
6888
|
I(this, "_navigationModes", /* @__PURE__ */ new Map());
|
|
6821
6889
|
I(this, "_mode", null);
|
|
6822
6890
|
I(this, "previousSize", null);
|
|
6823
|
-
this.threePersp = this.three, this.threeOrtho = this.newOrthoCamera(), this.projection = new
|
|
6891
|
+
this.threePersp = this.three, this.threeOrtho = this.newOrthoCamera(), this.projection = new Zr(this), this.onAspectUpdated.add(() => {
|
|
6824
6892
|
this.setOrthoPerspCameraAspect();
|
|
6825
6893
|
}), this.projection.onChanged.add(
|
|
6826
6894
|
(e) => {
|
|
6827
6895
|
this.three = e, this.updateAspect();
|
|
6828
6896
|
}
|
|
6829
6897
|
), this.onWorldChanged.add(({ action: e }) => {
|
|
6830
|
-
e === "added" && (this._navigationModes.clear(), this._navigationModes.set("Orbit", new
|
|
6898
|
+
e === "added" && (this._navigationModes.clear(), this._navigationModes.set("Orbit", new kr(this)), this._navigationModes.set("FirstPerson", new Wr(this)), this._navigationModes.set("Plan", new Xr(this)), this._mode = this._navigationModes.get("Orbit"), this.mode.set(!0, { preventTargetAdjustment: !0 }), this.currentWorld && this.currentWorld.renderer && (this.previousSize = this.currentWorld.renderer.getSize().clone()));
|
|
6831
6899
|
});
|
|
6832
6900
|
}
|
|
6833
6901
|
/**
|
|
@@ -6913,7 +6981,7 @@ class aa extends We {
|
|
|
6913
6981
|
this.threeOrtho.left = -a, this.threeOrtho.right = a, this.threeOrtho.top = r, this.threeOrtho.bottom = -r, this.threeOrtho.updateProjectionMatrix(), this.previousSize.copy(t);
|
|
6914
6982
|
}
|
|
6915
6983
|
}
|
|
6916
|
-
const
|
|
6984
|
+
const Qr = /* @__PURE__ */ new Map([
|
|
6917
6985
|
[
|
|
6918
6986
|
U.IFCRELAGGREGATES,
|
|
6919
6987
|
{
|
|
@@ -7009,7 +7077,7 @@ const Zr = /* @__PURE__ */ new Map([
|
|
|
7009
7077
|
I(this, "relationMaps", {});
|
|
7010
7078
|
/** {@link Component.enabled} */
|
|
7011
7079
|
I(this, "enabled", !0);
|
|
7012
|
-
I(this, "_relToAttributesMap",
|
|
7080
|
+
I(this, "_relToAttributesMap", Qr);
|
|
7013
7081
|
I(this, "_inverseAttributes", [
|
|
7014
7082
|
"IsDecomposedBy",
|
|
7015
7083
|
"Decomposes",
|
|
@@ -7329,20 +7397,20 @@ const Ns = class Ns extends et {
|
|
|
7329
7397
|
*/
|
|
7330
7398
|
I(this, "onFragmentsDisposed", new w());
|
|
7331
7399
|
/**
|
|
7332
|
-
*
|
|
7400
|
+
* DataMap containing all loaded fragments.
|
|
7333
7401
|
* The key is the fragment's unique identifier, and the value is the fragment itself.
|
|
7334
7402
|
*/
|
|
7335
|
-
I(this, "list",
|
|
7403
|
+
I(this, "list", new Ji());
|
|
7336
7404
|
/**
|
|
7337
|
-
*
|
|
7405
|
+
* DataMap containing all loaded fragment groups.
|
|
7338
7406
|
* The key is the group's unique identifier, and the value is the group itself.
|
|
7339
7407
|
*/
|
|
7340
|
-
I(this, "groups",
|
|
7408
|
+
I(this, "groups", new Ji());
|
|
7341
7409
|
I(this, "baseCoordinationModel", "");
|
|
7342
7410
|
I(this, "baseCoordinationMatrix", new O.Matrix4());
|
|
7343
7411
|
/** {@link Component.enabled} */
|
|
7344
7412
|
I(this, "enabled", !0);
|
|
7345
|
-
I(this, "_loader", new
|
|
7413
|
+
I(this, "_loader", new so());
|
|
7346
7414
|
this.components.add(Ns.uuid, this);
|
|
7347
7415
|
}
|
|
7348
7416
|
/**
|
|
@@ -7479,6 +7547,20 @@ const Ns = class Ns extends et {
|
|
|
7479
7547
|
applyBaseCoordinateSystem(t, e) {
|
|
7480
7548
|
t.applyMatrix4(e.clone().invert()), t.applyMatrix4(this.baseCoordinationMatrix);
|
|
7481
7549
|
}
|
|
7550
|
+
/**
|
|
7551
|
+
* Creates a copy of the whole model or a part of it.
|
|
7552
|
+
*
|
|
7553
|
+
* @param model - The model to clone.
|
|
7554
|
+
* @param items - Optional - The part of the model to be cloned. If not given, the whole group is cloned.
|
|
7555
|
+
*
|
|
7556
|
+
*/
|
|
7557
|
+
clone(t, e) {
|
|
7558
|
+
const i = t.cloneGroup(e);
|
|
7559
|
+
this.groups.set(i.uuid, i);
|
|
7560
|
+
for (const o of i.items)
|
|
7561
|
+
this.list.set(o.id, o);
|
|
7562
|
+
return i;
|
|
7563
|
+
}
|
|
7482
7564
|
};
|
|
7483
7565
|
/**
|
|
7484
7566
|
* A unique identifier for the component.
|
|
@@ -7761,8 +7843,8 @@ const At = class At extends et {
|
|
|
7761
7843
|
}
|
|
7762
7844
|
};
|
|
7763
7845
|
I(At, "uuid", "d1444724-dba6-4cdd-a0c7-68ee1450d166");
|
|
7764
|
-
let
|
|
7765
|
-
const
|
|
7846
|
+
let gn = At;
|
|
7847
|
+
const Bn = /* @__PURE__ */ new Set([
|
|
7766
7848
|
1123145078,
|
|
7767
7849
|
574549367,
|
|
7768
7850
|
1675464909,
|
|
@@ -7921,7 +8003,7 @@ const vn = /* @__PURE__ */ new Set([
|
|
|
7921
8003
|
for (const c of a)
|
|
7922
8004
|
r.add(c);
|
|
7923
8005
|
for (const c of r) {
|
|
7924
|
-
if (
|
|
8006
|
+
if (Bn.has(c))
|
|
7925
8007
|
continue;
|
|
7926
8008
|
const h = a.has(c) && o, d = t.GetLineIDsWithType(e, c);
|
|
7927
8009
|
for (const E of d) {
|
|
@@ -7938,7 +8020,7 @@ const vn = /* @__PURE__ */ new Set([
|
|
|
7938
8020
|
*/
|
|
7939
8021
|
I(Ps, "uuid", "b32c4332-cd67-436e-ba7f-196646c7a635");
|
|
7940
8022
|
let mi = Ps;
|
|
7941
|
-
const
|
|
8023
|
+
const jr = {
|
|
7942
8024
|
103090709: "IFCPROJECT",
|
|
7943
8025
|
4097777520: "IFCSITE",
|
|
7944
8026
|
4031249490: "IFCBUILDING",
|
|
@@ -8079,7 +8161,7 @@ const Qr = {
|
|
|
8079
8161
|
};
|
|
8080
8162
|
class ca {
|
|
8081
8163
|
getAll(s, t) {
|
|
8082
|
-
const e = {}, i = Object.keys(
|
|
8164
|
+
const e = {}, i = Object.keys(jr).map((o) => parseInt(o, 10));
|
|
8083
8165
|
for (let o = 0; o < i.length; o++) {
|
|
8084
8166
|
const n = i[o], r = s.GetLineIDsWithType(t, n), a = r.size();
|
|
8085
8167
|
for (let c = 0; c < a; c++)
|
|
@@ -8088,7 +8170,7 @@ class ca {
|
|
|
8088
8170
|
return e;
|
|
8089
8171
|
}
|
|
8090
8172
|
}
|
|
8091
|
-
const
|
|
8173
|
+
const Yn = {
|
|
8092
8174
|
950732822: "IFCURIREFERENCE",
|
|
8093
8175
|
4075327185: "IFCTIME",
|
|
8094
8176
|
1209108979: "IFCTEMPERATURERATEOFCHANGEMEASURE",
|
|
@@ -9326,7 +9408,7 @@ class Kt {
|
|
|
9326
9408
|
return i === null || e[i] === void 0 || e[i] === null ? o = null : o = e[i].value, { key: i, value: o };
|
|
9327
9409
|
}
|
|
9328
9410
|
static isRel(s) {
|
|
9329
|
-
return
|
|
9411
|
+
return Yn[s].startsWith("IFCREL");
|
|
9330
9412
|
}
|
|
9331
9413
|
static async attributeExists(s, t, e) {
|
|
9332
9414
|
const i = await s.getProperties(t);
|
|
@@ -9365,7 +9447,7 @@ class Kt {
|
|
|
9365
9447
|
// return propertyInstance;
|
|
9366
9448
|
// }
|
|
9367
9449
|
}
|
|
9368
|
-
class
|
|
9450
|
+
class qr {
|
|
9369
9451
|
constructor() {
|
|
9370
9452
|
I(this, "factor", 1);
|
|
9371
9453
|
I(this, "complement", 1);
|
|
@@ -9423,10 +9505,10 @@ class jr {
|
|
|
9423
9505
|
]);
|
|
9424
9506
|
}
|
|
9425
9507
|
}
|
|
9426
|
-
class
|
|
9508
|
+
class Vn {
|
|
9427
9509
|
constructor() {
|
|
9428
9510
|
I(this, "itemsByFloor", {});
|
|
9429
|
-
I(this, "_units", new
|
|
9511
|
+
I(this, "_units", new qr());
|
|
9430
9512
|
}
|
|
9431
9513
|
// TODO: Maybe make this more flexible so that it also support more exotic spatial structures?
|
|
9432
9514
|
setUp(s) {
|
|
@@ -9537,7 +9619,7 @@ class Li {
|
|
|
9537
9619
|
I(this, "customLocateFileHandler", null);
|
|
9538
9620
|
}
|
|
9539
9621
|
}
|
|
9540
|
-
class
|
|
9622
|
+
class Gn {
|
|
9541
9623
|
constructor() {
|
|
9542
9624
|
I(this, "defLineMat", new O.LineBasicMaterial({ color: 16777215 }));
|
|
9543
9625
|
}
|
|
@@ -9588,7 +9670,7 @@ class Vn {
|
|
|
9588
9670
|
return e;
|
|
9589
9671
|
}
|
|
9590
9672
|
}
|
|
9591
|
-
class
|
|
9673
|
+
class zn {
|
|
9592
9674
|
getNameInfo(s) {
|
|
9593
9675
|
var d;
|
|
9594
9676
|
const t = {}, { arguments: e } = s.GetHeaderLine(0, U.FILE_NAME) || {};
|
|
@@ -9623,7 +9705,7 @@ class Gn {
|
|
|
9623
9705
|
return o != null && o.value && (t.implementationLevel = o.value), t;
|
|
9624
9706
|
}
|
|
9625
9707
|
}
|
|
9626
|
-
class
|
|
9708
|
+
class Hn {
|
|
9627
9709
|
static get(s, t) {
|
|
9628
9710
|
const e = [
|
|
9629
9711
|
U.IFCPROJECT,
|
|
@@ -9670,10 +9752,10 @@ const Ge = class Ge extends et {
|
|
|
9670
9752
|
/** {@link Component.enabled} */
|
|
9671
9753
|
I(this, "enabled", !0);
|
|
9672
9754
|
I(this, "_material", new O.MeshLambertMaterial());
|
|
9673
|
-
I(this, "_spatialTree", new
|
|
9674
|
-
I(this, "_metaData", new
|
|
9755
|
+
I(this, "_spatialTree", new Vn());
|
|
9756
|
+
I(this, "_metaData", new zn());
|
|
9675
9757
|
I(this, "_fragmentInstances", /* @__PURE__ */ new Map());
|
|
9676
|
-
I(this, "_civil", new
|
|
9758
|
+
I(this, "_civil", new Gn());
|
|
9677
9759
|
I(this, "_visitedFragments", /* @__PURE__ */ new Map());
|
|
9678
9760
|
I(this, "_materialT", new O.MeshLambertMaterial({
|
|
9679
9761
|
transparent: !0,
|
|
@@ -9737,7 +9819,7 @@ const Ge = class Ge extends et {
|
|
|
9737
9819
|
const d = h.GlobalId.value || h.GlobalId;
|
|
9738
9820
|
o.globalToExpressIDs.set(d, c);
|
|
9739
9821
|
}
|
|
9740
|
-
return
|
|
9822
|
+
return Hn.get(o, this.webIfc), this.cleanUp(), console.log(`Streaming the IFC took ${performance.now() - i} ms!`), o;
|
|
9741
9823
|
}
|
|
9742
9824
|
/**
|
|
9743
9825
|
* Reads an IFC file and initializes the Web-IFC library.
|
|
@@ -10247,7 +10329,7 @@ const Bt = class Bt extends et {
|
|
|
10247
10329
|
* This UUID is used to register the component within the Components system.
|
|
10248
10330
|
*/
|
|
10249
10331
|
I(Bt, "uuid", "58c2d9f0-183c-48d6-a402-dfcf5b9a34df");
|
|
10250
|
-
let
|
|
10332
|
+
let On = Bt;
|
|
10251
10333
|
const Ls = class Ls extends et {
|
|
10252
10334
|
constructor(t) {
|
|
10253
10335
|
super(t);
|
|
@@ -10428,7 +10510,7 @@ const Ls = class Ls extends et {
|
|
|
10428
10510
|
byEntity(t) {
|
|
10429
10511
|
this.list.entities || (this.list.entities = {});
|
|
10430
10512
|
for (const [e, i] of t.data) {
|
|
10431
|
-
const n = i[1][1], r =
|
|
10513
|
+
const n = i[1][1], r = Yn[n];
|
|
10432
10514
|
this.saveItem(t, "entities", r, e);
|
|
10433
10515
|
}
|
|
10434
10516
|
}
|
|
@@ -10674,7 +10756,7 @@ const ys = class ys extends et {
|
|
|
10674
10756
|
* This UUID is used to register the component within the Components system.
|
|
10675
10757
|
*/
|
|
10676
10758
|
I(ys, "uuid", "d260618b-ce88-4c7d-826c-6debb91de3e2");
|
|
10677
|
-
let
|
|
10759
|
+
let Sn = ys;
|
|
10678
10760
|
const Ms = class Ms extends et {
|
|
10679
10761
|
constructor(t) {
|
|
10680
10762
|
super(t);
|
|
@@ -10730,8 +10812,8 @@ const Ms = class Ms extends et {
|
|
|
10730
10812
|
* This UUID is used to register the component within the Components system.
|
|
10731
10813
|
*/
|
|
10732
10814
|
I(Ms, "uuid", "dd9ccf2d-8a21-4821-b7f6-2949add16a29");
|
|
10733
|
-
let
|
|
10734
|
-
class
|
|
10815
|
+
let _n = Ms;
|
|
10816
|
+
class Kr extends Li {
|
|
10735
10817
|
constructor() {
|
|
10736
10818
|
super(...arguments);
|
|
10737
10819
|
/**
|
|
@@ -10774,20 +10856,20 @@ const ws = class ws extends et {
|
|
|
10774
10856
|
/**
|
|
10775
10857
|
* Settings for the IfcGeometryTiler.
|
|
10776
10858
|
*/
|
|
10777
|
-
I(this, "settings", new
|
|
10859
|
+
I(this, "settings", new Kr());
|
|
10778
10860
|
/** {@link Component.enabled} */
|
|
10779
10861
|
I(this, "enabled", !0);
|
|
10780
10862
|
/**
|
|
10781
10863
|
* The WebIFC API instance used for IFC file processing.
|
|
10782
10864
|
*/
|
|
10783
10865
|
I(this, "webIfc", new U.IfcAPI());
|
|
10784
|
-
I(this, "_spatialTree", new
|
|
10785
|
-
I(this, "_metaData", new
|
|
10866
|
+
I(this, "_spatialTree", new Vn());
|
|
10867
|
+
I(this, "_metaData", new zn());
|
|
10786
10868
|
I(this, "_visitedGeometries", /* @__PURE__ */ new Map());
|
|
10787
10869
|
I(this, "_streamSerializer", new Vt.StreamSerializer());
|
|
10788
10870
|
I(this, "_geometries", /* @__PURE__ */ new Map());
|
|
10789
10871
|
I(this, "_geometryCount", 0);
|
|
10790
|
-
I(this, "_civil", new
|
|
10872
|
+
I(this, "_civil", new Gn());
|
|
10791
10873
|
I(this, "_groupSerializer", new Vt.Serializer());
|
|
10792
10874
|
I(this, "_assets", []);
|
|
10793
10875
|
I(this, "_meshesWithHoles", /* @__PURE__ */ new Set());
|
|
@@ -10881,7 +10963,7 @@ const ws = class ws extends et {
|
|
|
10881
10963
|
const { opaque: d, transparent: E } = n.geometryIDs;
|
|
10882
10964
|
for (const [T, { index: R, uuid: C }] of this._visitedGeometries)
|
|
10883
10965
|
n.keyFragments.set(R, C), (T > 1 ? d : E).set(T, R);
|
|
10884
|
-
|
|
10966
|
+
Hn.get(n, this.webIfc);
|
|
10885
10967
|
const u = this.webIfc.GetCoordinationMatrix(0);
|
|
10886
10968
|
n.coordinationMatrix.fromArray(u), n.civilData = this._civil.read(this.webIfc);
|
|
10887
10969
|
const f = this._groupSerializer.export(n);
|
|
@@ -10921,11 +11003,11 @@ const ws = class ws extends et {
|
|
|
10921
11003
|
), r = new Float32Array(n.length / 2), a = new Float32Array(n.length / 2);
|
|
10922
11004
|
for (let u = 0; u < n.length; u += 6)
|
|
10923
11005
|
r[u / 2] = n[u], r[u / 2 + 1] = n[u + 1], r[u / 2 + 2] = n[u + 2], a[u / 2] = n[u + 3], a[u / 2 + 1] = n[u + 4], a[u / 2 + 2] = n[u + 5];
|
|
10924
|
-
const c =
|
|
11006
|
+
const c = Rr(r), h = new Float32Array(c.transformation.elements), d = [c.center.x, c.center.y, c.center.z];
|
|
10925
11007
|
let E = !1;
|
|
10926
11008
|
for (let u = 0; u < r.length - 2; u += 3) {
|
|
10927
11009
|
const f = r[u], T = r[u + 1], R = r[u + 2], C = a[u], A = a[u + 1], F = a[u + 2];
|
|
10928
|
-
if (
|
|
11010
|
+
if (Ar(d, [f, T, R], [C, A, F])) {
|
|
10929
11011
|
E = !0;
|
|
10930
11012
|
break;
|
|
10931
11013
|
}
|
|
@@ -10953,8 +11035,8 @@ const ws = class ws extends et {
|
|
|
10953
11035
|
* This UUID is used to register the component within the Components system.
|
|
10954
11036
|
*/
|
|
10955
11037
|
I(ws, "uuid", "d9999a00-e1f5-4d3f-8cfe-c56e08609764");
|
|
10956
|
-
let
|
|
10957
|
-
class
|
|
11038
|
+
let Nn = ws;
|
|
11039
|
+
class $r extends Li {
|
|
10958
11040
|
constructor() {
|
|
10959
11041
|
super(...arguments);
|
|
10960
11042
|
/**
|
|
@@ -10964,7 +11046,7 @@ class Kr extends Li {
|
|
|
10964
11046
|
I(this, "propertiesSize", 100);
|
|
10965
11047
|
}
|
|
10966
11048
|
}
|
|
10967
|
-
class
|
|
11049
|
+
class Jr extends et {
|
|
10968
11050
|
constructor() {
|
|
10969
11051
|
super(...arguments);
|
|
10970
11052
|
/**
|
|
@@ -10989,7 +11071,7 @@ class $r extends et {
|
|
|
10989
11071
|
/**
|
|
10990
11072
|
* An instance of the PropertiesStreamingSettings class, which holds the settings for the streaming process.
|
|
10991
11073
|
*/
|
|
10992
|
-
I(this, "settings", new
|
|
11074
|
+
I(this, "settings", new $r());
|
|
10993
11075
|
/**
|
|
10994
11076
|
* An instance of the IfcAPI class from the Web-IFC library, which provides methods for reading and processing IFC data.
|
|
10995
11077
|
*/
|
|
@@ -11037,7 +11119,7 @@ class $r extends et {
|
|
|
11037
11119
|
e.add(c);
|
|
11038
11120
|
let o = 0.01, n = 0;
|
|
11039
11121
|
for (const c of e) {
|
|
11040
|
-
if (n++,
|
|
11122
|
+
if (n++, Bn.has(c))
|
|
11041
11123
|
continue;
|
|
11042
11124
|
const h = i.has(c), d = this.webIfc.GetLineIDsWithType(0, c), E = d.size();
|
|
11043
11125
|
let u = 0;
|
|
@@ -11082,7 +11164,7 @@ class $r extends et {
|
|
|
11082
11164
|
* A unique identifier for the component.
|
|
11083
11165
|
* This UUID is used to register the component within the Components system.
|
|
11084
11166
|
*/
|
|
11085
|
-
I(
|
|
11167
|
+
I(Jr, "uuid", "88d2c89c-ce32-47d7-8cb6-d51e4b311a0b");
|
|
11086
11168
|
const Ds = class Ds extends et {
|
|
11087
11169
|
constructor(t) {
|
|
11088
11170
|
super(t);
|
|
@@ -11341,66 +11423,66 @@ const Ds = class Ds extends et {
|
|
|
11341
11423
|
* This UUID is used to register the component within the Components system.
|
|
11342
11424
|
*/
|
|
11343
11425
|
I(Ds, "uuid", "267ca032-672f-4cb0-afa9-d24e904f39d6");
|
|
11344
|
-
let
|
|
11426
|
+
let Pn = Ds;
|
|
11345
11427
|
export {
|
|
11346
11428
|
Ts as AsyncEvent,
|
|
11347
11429
|
_i as Base,
|
|
11348
|
-
|
|
11349
|
-
|
|
11350
|
-
|
|
11430
|
+
lr as BaseCamera,
|
|
11431
|
+
hr as BaseRenderer,
|
|
11432
|
+
Er as BaseScene,
|
|
11351
11433
|
Ni as BaseWorldItem,
|
|
11352
|
-
|
|
11434
|
+
gn as BoundingBoxer,
|
|
11353
11435
|
Ai as Classifier,
|
|
11354
|
-
|
|
11436
|
+
An as Clipper,
|
|
11355
11437
|
et as Component,
|
|
11356
11438
|
pi as Components,
|
|
11357
|
-
|
|
11439
|
+
Gr as CullerRenderer,
|
|
11358
11440
|
Ti as Cullers,
|
|
11359
|
-
|
|
11360
|
-
|
|
11441
|
+
Ji as DataMap,
|
|
11442
|
+
ia as DataSet,
|
|
11361
11443
|
zt as Disposer,
|
|
11362
11444
|
w as Event,
|
|
11363
|
-
|
|
11364
|
-
|
|
11445
|
+
Sn as Exploder,
|
|
11446
|
+
Wr as FirstPersonMode,
|
|
11365
11447
|
ht as FragmentsManager,
|
|
11366
|
-
|
|
11367
|
-
|
|
11368
|
-
|
|
11448
|
+
Bn as GeometryTypes,
|
|
11449
|
+
un as Grids,
|
|
11450
|
+
_n as Hider,
|
|
11369
11451
|
ca as IfcCategories,
|
|
11370
|
-
|
|
11371
|
-
|
|
11452
|
+
Yn as IfcCategoryMap,
|
|
11453
|
+
jr as IfcElements,
|
|
11372
11454
|
Li as IfcFragmentSettings,
|
|
11373
|
-
|
|
11455
|
+
Nn as IfcGeometryTiler,
|
|
11374
11456
|
mi as IfcJsonExporter,
|
|
11375
11457
|
Ri as IfcLoader,
|
|
11376
|
-
|
|
11377
|
-
|
|
11458
|
+
On as IfcPropertiesManager,
|
|
11459
|
+
Jr as IfcPropertiesTiler,
|
|
11378
11460
|
Kt as IfcPropertiesUtils,
|
|
11379
11461
|
pe as IfcRelationsIndexer,
|
|
11380
|
-
|
|
11381
|
-
|
|
11382
|
-
|
|
11383
|
-
|
|
11384
|
-
|
|
11385
|
-
|
|
11386
|
-
|
|
11387
|
-
|
|
11462
|
+
Kr as IfcStreamingSettings,
|
|
11463
|
+
nn as MaterialsUtils,
|
|
11464
|
+
Pn as MeasurementUtils,
|
|
11465
|
+
zr as MeshCullerRenderer,
|
|
11466
|
+
Hr as MiniMap,
|
|
11467
|
+
Fn as MiniMaps,
|
|
11468
|
+
Fr as Mouse,
|
|
11469
|
+
kr as OrbitMode,
|
|
11388
11470
|
aa as OrthoPerspectiveCamera,
|
|
11389
|
-
|
|
11390
|
-
|
|
11391
|
-
|
|
11471
|
+
Xr as PlanMode,
|
|
11472
|
+
Zr as ProjectionManager,
|
|
11473
|
+
$r as PropertiesStreamingSettings,
|
|
11392
11474
|
He as Raycasters,
|
|
11393
11475
|
We as SimpleCamera,
|
|
11394
|
-
|
|
11476
|
+
Lr as SimpleGrid,
|
|
11395
11477
|
Pi as SimplePlane,
|
|
11396
|
-
|
|
11478
|
+
gr as SimpleRaycaster,
|
|
11397
11479
|
ra as SimpleRenderer,
|
|
11398
11480
|
oa as SimpleScene,
|
|
11399
|
-
|
|
11481
|
+
Or as SimpleWorld,
|
|
11400
11482
|
ze as UUID,
|
|
11401
11483
|
na as VertexPicker,
|
|
11402
11484
|
Ci as Worlds,
|
|
11403
|
-
|
|
11404
|
-
|
|
11405
|
-
|
|
11485
|
+
Ar as isPointInFrontOfPlane,
|
|
11486
|
+
Rr as obbFromPoints,
|
|
11487
|
+
Vr as readPixelsAsync
|
|
11406
11488
|
};
|