dpot-ui 0.4.1 → 0.4.3
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/index.es.js +541 -539
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -77,7 +77,7 @@ function al(n, e, t) {
|
|
|
77
77
|
}
|
|
78
78
|
return h;
|
|
79
79
|
}
|
|
80
|
-
const
|
|
80
|
+
const Tf = (n, e, t) => zt(void 0, null, function* () {
|
|
81
81
|
const { placement: i = "bottom", strategy: r = "absolute", middleware: s = [], platform: o } = t, a = s.filter(Boolean), l = yield o.isRTL == null ? void 0 : o.isRTL(e);
|
|
82
82
|
let c = yield o.getElementRects({ reference: n, floating: e, strategy: r }), { x: u, y: h } = al(c, i, l), f = i, d = {}, g = 0;
|
|
83
83
|
for (let _ = 0; _ < a.length; _++) {
|
|
@@ -105,9 +105,9 @@ function Cs(n, e) {
|
|
|
105
105
|
return { top: (m.top - M.top + g.top) / v.y, bottom: (M.bottom - m.bottom + g.bottom) / v.y, left: (m.left - M.left + g.left) / v.x, right: (M.right - m.right + g.right) / v.x };
|
|
106
106
|
});
|
|
107
107
|
}
|
|
108
|
-
const Yo = Math.min,
|
|
108
|
+
const Yo = Math.min, wf = Math.max;
|
|
109
109
|
function Ko(n, e, t) {
|
|
110
|
-
return
|
|
110
|
+
return wf(n, Yo(e, t));
|
|
111
111
|
}
|
|
112
112
|
const Af = (n) => ({ name: "arrow", options: n, fn(t) {
|
|
113
113
|
return zt(this, null, function* () {
|
|
@@ -115,9 +115,9 @@ const Af = (n) => ({ name: "arrow", options: n, fn(t) {
|
|
|
115
115
|
if (c == null)
|
|
116
116
|
return {};
|
|
117
117
|
const h = Xu(u), f = { x: i, y: r }, d = Lr(s), g = Ea(d), _ = yield a.getDimensions(c), m = d === "y", p = m ? "top" : "left", S = m ? "bottom" : "right", v = m ? "clientHeight" : "clientWidth", M = o.reference[g] + o.reference[d] - f[d] - o.floating[g], b = f[d] - o.reference[d], R = yield a.getOffsetParent == null ? void 0 : a.getOffsetParent(c);
|
|
118
|
-
let
|
|
119
|
-
|
|
120
|
-
const N = M / 2 - b / 2, x =
|
|
118
|
+
let w = R ? R[v] : 0;
|
|
119
|
+
w && (yield a.isElement == null ? void 0 : a.isElement(R)) || (w = l.floating[v] || o.floating[g]);
|
|
120
|
+
const N = M / 2 - b / 2, x = w / 2 - _[g] / 2 - 1, E = Yo(h[p], x), F = Yo(h[S], x), ee = E, O = w - _[g] - F, U = w / 2 - _[g] / 2 + N, C = Ko(ee, U, O), z = Pr(s) != null && U != C && o.reference[g] / 2 - (U < ee ? E : F) - _[g] / 2 < 0 ? U < ee ? ee - U : O - U : 0;
|
|
121
121
|
return { [d]: f[d] - z, data: { [d]: C, centerOffset: U - C + z } };
|
|
122
122
|
});
|
|
123
123
|
} }), $u = ["top", "right", "bottom", "left"];
|
|
@@ -161,13 +161,13 @@ const Lf = function(n) {
|
|
|
161
161
|
}(si(O), C === "start", z);
|
|
162
162
|
return H && (V = V.map((K) => K + "-" + H), U && (V = V.concat(V.map(ro)))), V;
|
|
163
163
|
}(a, _, g, v));
|
|
164
|
-
const b = [a, ...M], R = yield Cs(t, m),
|
|
164
|
+
const b = [a, ...M], R = yield Cs(t, m), w = [];
|
|
165
165
|
let N = ((i = s.flip) == null ? void 0 : i.overflows) || [];
|
|
166
|
-
if (u &&
|
|
166
|
+
if (u && w.push(R[p]), h) {
|
|
167
167
|
const { main: O, cross: U } = Rf(r, o, v);
|
|
168
|
-
|
|
168
|
+
w.push(R[O], R[U]);
|
|
169
169
|
}
|
|
170
|
-
if (N = [...N, { placement: r, overflows:
|
|
170
|
+
if (N = [...N, { placement: r, overflows: w }], !w.every((O) => O <= 0)) {
|
|
171
171
|
var x, E;
|
|
172
172
|
const O = (((x = s.flip) == null ? void 0 : x.index) || 0) + 1, U = b[O];
|
|
173
173
|
if (U)
|
|
@@ -299,11 +299,11 @@ function ju(n) {
|
|
|
299
299
|
const r = ln(n), s = r ? n.offsetWidth : t, o = r ? n.offsetHeight : i, a = Ps(t) !== s || Ps(i) !== o;
|
|
300
300
|
return a && (t = s, i = o), { width: t, height: i, $: a };
|
|
301
301
|
}
|
|
302
|
-
function
|
|
302
|
+
function Ta(n) {
|
|
303
303
|
return Pn(n) ? n : n.contextElement;
|
|
304
304
|
}
|
|
305
305
|
function zi(n) {
|
|
306
|
-
const e =
|
|
306
|
+
const e = Ta(n);
|
|
307
307
|
if (!ln(e))
|
|
308
308
|
return hi(1);
|
|
309
309
|
const t = e.getBoundingClientRect(), { width: i, height: r, $: s } = ju(e);
|
|
@@ -320,7 +320,7 @@ function Yu(n, e, t) {
|
|
|
320
320
|
}
|
|
321
321
|
function fi(n, e, t, i) {
|
|
322
322
|
e === void 0 && (e = !1), t === void 0 && (t = !1);
|
|
323
|
-
const r = n.getBoundingClientRect(), s =
|
|
323
|
+
const r = n.getBoundingClientRect(), s = Ta(n);
|
|
324
324
|
let o = hi(1);
|
|
325
325
|
e && (i ? Pn(i) && (o = zi(i)) : o = zi(n));
|
|
326
326
|
const a = Yu(s, t, i);
|
|
@@ -469,7 +469,7 @@ const Bf = { getClippingRect: function(n) {
|
|
|
469
469
|
}, getClientRects: (n) => Array.from(n.getClientRects()), isRTL: (n) => on(n).direction === "rtl" };
|
|
470
470
|
function zf(n, e, t, i) {
|
|
471
471
|
i === void 0 && (i = {});
|
|
472
|
-
const { ancestorScroll: r = !0, ancestorResize: s = !0, elementResize: o = !0, layoutShift: a = typeof IntersectionObserver == "function", animationFrame: l = !1 } = i, c =
|
|
472
|
+
const { ancestorScroll: r = !0, ancestorResize: s = !0, elementResize: o = !0, layoutShift: a = typeof IntersectionObserver == "function", animationFrame: l = !1 } = i, c = Ta(n), u = r || s ? [...c ? Ls(c) : [], ...Ls(e)] : [];
|
|
473
473
|
u.forEach((_) => {
|
|
474
474
|
r && _.addEventListener("scroll", t, { passive: !0 }), s && _.addEventListener("resize", t);
|
|
475
475
|
});
|
|
@@ -479,8 +479,8 @@ function zf(n, e, t, i) {
|
|
|
479
479
|
function M() {
|
|
480
480
|
clearTimeout(p), S && S.disconnect(), S = null;
|
|
481
481
|
}
|
|
482
|
-
return function b(R,
|
|
483
|
-
R === void 0 && (R = !1),
|
|
482
|
+
return function b(R, w) {
|
|
483
|
+
R === void 0 && (R = !1), w === void 0 && (w = 1), M();
|
|
484
484
|
const { left: N, top: x, width: E, height: F } = _.getBoundingClientRect();
|
|
485
485
|
if (R || m(), !E || !F)
|
|
486
486
|
return;
|
|
@@ -488,7 +488,7 @@ function zf(n, e, t, i) {
|
|
|
488
488
|
let z = !0;
|
|
489
489
|
S = new IntersectionObserver((H) => {
|
|
490
490
|
const V = H[0].intersectionRatio;
|
|
491
|
-
if (V !==
|
|
491
|
+
if (V !== w) {
|
|
492
492
|
if (!z)
|
|
493
493
|
return b();
|
|
494
494
|
V ? b(!1, V) : p = setTimeout(() => {
|
|
@@ -496,7 +496,7 @@ function zf(n, e, t, i) {
|
|
|
496
496
|
}, 100);
|
|
497
497
|
}
|
|
498
498
|
z = !1;
|
|
499
|
-
}, { rootMargin: -ee + "px " + -O + "px " + -U + "px " + -C + "px", threshold: Bi(0, Jo(1,
|
|
499
|
+
}, { rootMargin: -ee + "px " + -O + "px " + -U + "px " + -C + "px", threshold: Bi(0, Jo(1, w)) || 1 }), S.observe(_);
|
|
500
500
|
}(!0), M;
|
|
501
501
|
}(c, t) : null;
|
|
502
502
|
let f, d = null;
|
|
@@ -513,7 +513,7 @@ function zf(n, e, t, i) {
|
|
|
513
513
|
}
|
|
514
514
|
const Hf = (n, e, t) => {
|
|
515
515
|
const i = /* @__PURE__ */ new Map(), r = Le({ platform: Bf }, t), s = nt(Le({}, r.platform), { _c: i });
|
|
516
|
-
return
|
|
516
|
+
return Tf(n, e, nt(Le({}, r), { platform: s }));
|
|
517
517
|
};
|
|
518
518
|
var kf = function() {
|
|
519
519
|
var n = this, e = n.$createElement, t = n._self._c || e;
|
|
@@ -545,7 +545,7 @@ var kf = function() {
|
|
|
545
545
|
}
|
|
546
546
|
}, [n._t("reference")], 2)]);
|
|
547
547
|
}, Gf = [];
|
|
548
|
-
function
|
|
548
|
+
function Tt(n, e, t, i, r, s, o, a) {
|
|
549
549
|
var l = typeof n == "function" ? n.options : n;
|
|
550
550
|
e && (l.render = e, l.staticRenderFns = t, l._compiled = !0), i && (l.functional = !0), s && (l._scopeId = "data-v-" + s);
|
|
551
551
|
var c;
|
|
@@ -671,7 +671,7 @@ const Vf = {
|
|
|
671
671
|
n && (n.removeEventListener("mouseenter", this.handleMouseEnter), n.removeEventListener("mouseleave", this.handleMouseLeave), e.removeEventListener("mouseenter", this.handleMouseEnter), e.removeEventListener("mouseleave", this.handleMouseLeave));
|
|
672
672
|
}
|
|
673
673
|
}, ml = {};
|
|
674
|
-
var Wf = /* @__PURE__ */
|
|
674
|
+
var Wf = /* @__PURE__ */ Tt(
|
|
675
675
|
Vf,
|
|
676
676
|
kf,
|
|
677
677
|
Gf,
|
|
@@ -685,7 +685,7 @@ function Xf(n) {
|
|
|
685
685
|
for (let e in ml)
|
|
686
686
|
this[e] = ml[e];
|
|
687
687
|
}
|
|
688
|
-
const
|
|
688
|
+
const wa = /* @__PURE__ */ function() {
|
|
689
689
|
return Wf.exports;
|
|
690
690
|
}();
|
|
691
691
|
var $f = function() {
|
|
@@ -728,7 +728,7 @@ const jf = {
|
|
|
728
728
|
}
|
|
729
729
|
}
|
|
730
730
|
}, gl = {};
|
|
731
|
-
var Yf = /* @__PURE__ */
|
|
731
|
+
var Yf = /* @__PURE__ */ Tt(
|
|
732
732
|
jf,
|
|
733
733
|
$f,
|
|
734
734
|
qf,
|
|
@@ -784,7 +784,7 @@ const ed = {
|
|
|
784
784
|
}
|
|
785
785
|
}
|
|
786
786
|
}, _l = {};
|
|
787
|
-
var td = /* @__PURE__ */
|
|
787
|
+
var td = /* @__PURE__ */ Tt(
|
|
788
788
|
ed,
|
|
789
789
|
Jf,
|
|
790
790
|
Qf,
|
|
@@ -853,7 +853,7 @@ var rd = function() {
|
|
|
853
853
|
const od = {
|
|
854
854
|
name: "dp-checkfilter",
|
|
855
855
|
components: {
|
|
856
|
-
DpPopover:
|
|
856
|
+
DpPopover: wa,
|
|
857
857
|
DpCheck: Zf,
|
|
858
858
|
DpRadio: id
|
|
859
859
|
},
|
|
@@ -885,7 +885,7 @@ const od = {
|
|
|
885
885
|
}
|
|
886
886
|
}
|
|
887
887
|
}, vl = {};
|
|
888
|
-
var ad = /* @__PURE__ */
|
|
888
|
+
var ad = /* @__PURE__ */ Tt(
|
|
889
889
|
od,
|
|
890
890
|
rd,
|
|
891
891
|
sd,
|
|
@@ -947,7 +947,7 @@ const hd = {
|
|
|
947
947
|
}
|
|
948
948
|
}
|
|
949
949
|
}, xl = {};
|
|
950
|
-
var fd = /* @__PURE__ */
|
|
950
|
+
var fd = /* @__PURE__ */ Tt(
|
|
951
951
|
hd,
|
|
952
952
|
cd,
|
|
953
953
|
ud,
|
|
@@ -1020,7 +1020,7 @@ var md = function() {
|
|
|
1020
1020
|
const _d = {
|
|
1021
1021
|
name: "dp-select",
|
|
1022
1022
|
components: {
|
|
1023
|
-
DpPopover:
|
|
1023
|
+
DpPopover: wa
|
|
1024
1024
|
},
|
|
1025
1025
|
props: {
|
|
1026
1026
|
value: {
|
|
@@ -1068,7 +1068,7 @@ const _d = {
|
|
|
1068
1068
|
}
|
|
1069
1069
|
}
|
|
1070
1070
|
}, yl = {};
|
|
1071
|
-
var vd = /* @__PURE__ */
|
|
1071
|
+
var vd = /* @__PURE__ */ Tt(
|
|
1072
1072
|
_d,
|
|
1073
1073
|
md,
|
|
1074
1074
|
gd,
|
|
@@ -1175,21 +1175,21 @@ const Ed = {
|
|
|
1175
1175
|
}
|
|
1176
1176
|
}
|
|
1177
1177
|
}, Sl = {};
|
|
1178
|
-
var bd = /* @__PURE__ */
|
|
1178
|
+
var bd = /* @__PURE__ */ Tt(
|
|
1179
1179
|
Ed,
|
|
1180
1180
|
Sd,
|
|
1181
1181
|
Md,
|
|
1182
1182
|
!1,
|
|
1183
|
-
|
|
1183
|
+
Td,
|
|
1184
1184
|
"cf64bc14",
|
|
1185
1185
|
null,
|
|
1186
1186
|
null
|
|
1187
1187
|
);
|
|
1188
|
-
function
|
|
1188
|
+
function Td(n) {
|
|
1189
1189
|
for (let e in Sl)
|
|
1190
1190
|
this[e] = Sl[e];
|
|
1191
1191
|
}
|
|
1192
|
-
const
|
|
1192
|
+
const wd = /* @__PURE__ */ function() {
|
|
1193
1193
|
return bd.exports;
|
|
1194
1194
|
}();
|
|
1195
1195
|
var Ad = function() {
|
|
@@ -1278,7 +1278,7 @@ const Rd = {
|
|
|
1278
1278
|
name: "dp-pagin",
|
|
1279
1279
|
components: {
|
|
1280
1280
|
DpSelect: yd,
|
|
1281
|
-
DpInput:
|
|
1281
|
+
DpInput: wd
|
|
1282
1282
|
},
|
|
1283
1283
|
props: {
|
|
1284
1284
|
pageInfo: {
|
|
@@ -1327,7 +1327,7 @@ const Rd = {
|
|
|
1327
1327
|
}
|
|
1328
1328
|
}
|
|
1329
1329
|
}, Ml = {};
|
|
1330
|
-
var Pd = /* @__PURE__ */
|
|
1330
|
+
var Pd = /* @__PURE__ */ Tt(
|
|
1331
1331
|
Rd,
|
|
1332
1332
|
Ad,
|
|
1333
1333
|
Cd,
|
|
@@ -1443,7 +1443,7 @@ const Ud = {
|
|
|
1443
1443
|
}
|
|
1444
1444
|
}
|
|
1445
1445
|
}, El = {};
|
|
1446
|
-
var Nd = /* @__PURE__ */
|
|
1446
|
+
var Nd = /* @__PURE__ */ Tt(
|
|
1447
1447
|
Ud,
|
|
1448
1448
|
Dd,
|
|
1449
1449
|
Id,
|
|
@@ -1597,7 +1597,7 @@ const Hd = {
|
|
|
1597
1597
|
this.item.children || this.$nextTick(this.handleResize);
|
|
1598
1598
|
}
|
|
1599
1599
|
}, bl = {};
|
|
1600
|
-
var kd = /* @__PURE__ */
|
|
1600
|
+
var kd = /* @__PURE__ */ Tt(
|
|
1601
1601
|
Hd,
|
|
1602
1602
|
Bd,
|
|
1603
1603
|
zd,
|
|
@@ -1740,8 +1740,8 @@ const $d = {
|
|
|
1740
1740
|
this.key++, this.widthInfo = {}, this.$emit("changeBlock", this.isBlock);
|
|
1741
1741
|
}
|
|
1742
1742
|
}
|
|
1743
|
-
},
|
|
1744
|
-
var qd = /* @__PURE__ */
|
|
1743
|
+
}, Tl = {};
|
|
1744
|
+
var qd = /* @__PURE__ */ Tt(
|
|
1745
1745
|
$d,
|
|
1746
1746
|
Wd,
|
|
1747
1747
|
Xd,
|
|
@@ -1752,8 +1752,8 @@ var qd = /* @__PURE__ */ wt(
|
|
|
1752
1752
|
null
|
|
1753
1753
|
);
|
|
1754
1754
|
function jd(n) {
|
|
1755
|
-
for (let e in
|
|
1756
|
-
this[e] =
|
|
1755
|
+
for (let e in Tl)
|
|
1756
|
+
this[e] = Tl[e];
|
|
1757
1757
|
}
|
|
1758
1758
|
const Yd = /* @__PURE__ */ function() {
|
|
1759
1759
|
return qd.exports;
|
|
@@ -2191,8 +2191,8 @@ const Jd = {
|
|
|
2191
2191
|
this.filterInfo = Le(Le({}, this.filterInfo), n), this.beforeIndex = 0, this.currentIndex = 50, this.$refs.table.scrollTop = 0, this.$emit("changeFilter", Object.values(this.filterInfo).map((e) => ({ key: e.key, value: e.value })));
|
|
2192
2192
|
}
|
|
2193
2193
|
}
|
|
2194
|
-
},
|
|
2195
|
-
var Qd = /* @__PURE__ */
|
|
2194
|
+
}, wl = {};
|
|
2195
|
+
var Qd = /* @__PURE__ */ Tt(
|
|
2196
2196
|
Jd,
|
|
2197
2197
|
Kd,
|
|
2198
2198
|
Zd,
|
|
@@ -2203,8 +2203,8 @@ var Qd = /* @__PURE__ */ wt(
|
|
|
2203
2203
|
null
|
|
2204
2204
|
);
|
|
2205
2205
|
function ep(n) {
|
|
2206
|
-
for (let e in
|
|
2207
|
-
this[e] =
|
|
2206
|
+
for (let e in wl)
|
|
2207
|
+
this[e] = wl[e];
|
|
2208
2208
|
}
|
|
2209
2209
|
const tp = /* @__PURE__ */ function() {
|
|
2210
2210
|
return Qd.exports;
|
|
@@ -2252,7 +2252,7 @@ const rp = {
|
|
|
2252
2252
|
}
|
|
2253
2253
|
}
|
|
2254
2254
|
}, Al = {};
|
|
2255
|
-
var sp = /* @__PURE__ */
|
|
2255
|
+
var sp = /* @__PURE__ */ Tt(
|
|
2256
2256
|
rp,
|
|
2257
2257
|
np,
|
|
2258
2258
|
ip,
|
|
@@ -2314,7 +2314,7 @@ const fp = {
|
|
|
2314
2314
|
}
|
|
2315
2315
|
}
|
|
2316
2316
|
}, Cl = {};
|
|
2317
|
-
var dp = /* @__PURE__ */
|
|
2317
|
+
var dp = /* @__PURE__ */ Tt(
|
|
2318
2318
|
fp,
|
|
2319
2319
|
up,
|
|
2320
2320
|
hp,
|
|
@@ -2400,7 +2400,7 @@ const vp = {
|
|
|
2400
2400
|
}
|
|
2401
2401
|
}
|
|
2402
2402
|
}, Rl = {};
|
|
2403
|
-
var xp = /* @__PURE__ */
|
|
2403
|
+
var xp = /* @__PURE__ */ Tt(
|
|
2404
2404
|
vp,
|
|
2405
2405
|
gp,
|
|
2406
2406
|
_p,
|
|
@@ -2446,7 +2446,7 @@ const bp = {
|
|
|
2446
2446
|
name: "dp-toggleraw",
|
|
2447
2447
|
components: {
|
|
2448
2448
|
DpIcon: mp,
|
|
2449
|
-
DpPopover:
|
|
2449
|
+
DpPopover: wa,
|
|
2450
2450
|
DpCapsule: Sp
|
|
2451
2451
|
},
|
|
2452
2452
|
props: {
|
|
@@ -2481,22 +2481,22 @@ const bp = {
|
|
|
2481
2481
|
}
|
|
2482
2482
|
}
|
|
2483
2483
|
}, Pl = {};
|
|
2484
|
-
var
|
|
2484
|
+
var Tp = /* @__PURE__ */ Tt(
|
|
2485
2485
|
bp,
|
|
2486
2486
|
Mp,
|
|
2487
2487
|
Ep,
|
|
2488
2488
|
!1,
|
|
2489
|
-
|
|
2489
|
+
wp,
|
|
2490
2490
|
"1a73bbf6",
|
|
2491
2491
|
null,
|
|
2492
2492
|
null
|
|
2493
2493
|
);
|
|
2494
|
-
function
|
|
2494
|
+
function wp(n) {
|
|
2495
2495
|
for (let e in Pl)
|
|
2496
2496
|
this[e] = Pl[e];
|
|
2497
2497
|
}
|
|
2498
2498
|
const Ap = /* @__PURE__ */ function() {
|
|
2499
|
-
return
|
|
2499
|
+
return Tp.exports;
|
|
2500
2500
|
}();
|
|
2501
2501
|
/**
|
|
2502
2502
|
* @license
|
|
@@ -2538,12 +2538,12 @@ class gi {
|
|
|
2538
2538
|
}
|
|
2539
2539
|
}
|
|
2540
2540
|
}
|
|
2541
|
-
const
|
|
2541
|
+
const wt = ["00", "01", "02", "03", "04", "05", "06", "07", "08", "09", "0a", "0b", "0c", "0d", "0e", "0f", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19", "1a", "1b", "1c", "1d", "1e", "1f", "20", "21", "22", "23", "24", "25", "26", "27", "28", "29", "2a", "2b", "2c", "2d", "2e", "2f", "30", "31", "32", "33", "34", "35", "36", "37", "38", "39", "3a", "3b", "3c", "3d", "3e", "3f", "40", "41", "42", "43", "44", "45", "46", "47", "48", "49", "4a", "4b", "4c", "4d", "4e", "4f", "50", "51", "52", "53", "54", "55", "56", "57", "58", "59", "5a", "5b", "5c", "5d", "5e", "5f", "60", "61", "62", "63", "64", "65", "66", "67", "68", "69", "6a", "6b", "6c", "6d", "6e", "6f", "70", "71", "72", "73", "74", "75", "76", "77", "78", "79", "7a", "7b", "7c", "7d", "7e", "7f", "80", "81", "82", "83", "84", "85", "86", "87", "88", "89", "8a", "8b", "8c", "8d", "8e", "8f", "90", "91", "92", "93", "94", "95", "96", "97", "98", "99", "9a", "9b", "9c", "9d", "9e", "9f", "a0", "a1", "a2", "a3", "a4", "a5", "a6", "a7", "a8", "a9", "aa", "ab", "ac", "ad", "ae", "af", "b0", "b1", "b2", "b3", "b4", "b5", "b6", "b7", "b8", "b9", "ba", "bb", "bc", "bd", "be", "bf", "c0", "c1", "c2", "c3", "c4", "c5", "c6", "c7", "c8", "c9", "ca", "cb", "cc", "cd", "ce", "cf", "d0", "d1", "d2", "d3", "d4", "d5", "d6", "d7", "d8", "d9", "da", "db", "dc", "dd", "de", "df", "e0", "e1", "e2", "e3", "e4", "e5", "e6", "e7", "e8", "e9", "ea", "eb", "ec", "ed", "ee", "ef", "f0", "f1", "f2", "f3", "f4", "f5", "f6", "f7", "f8", "f9", "fa", "fb", "fc", "fd", "fe", "ff"];
|
|
2542
2542
|
let uc = 1234567;
|
|
2543
2543
|
const fr = Math.PI / 180, Mr = 180 / Math.PI;
|
|
2544
2544
|
function mn() {
|
|
2545
2545
|
const n = Math.random() * 4294967295 | 0, e = Math.random() * 4294967295 | 0, t = Math.random() * 4294967295 | 0, i = Math.random() * 4294967295 | 0;
|
|
2546
|
-
return (
|
|
2546
|
+
return (wt[n & 255] + wt[n >> 8 & 255] + wt[n >> 16 & 255] + wt[n >> 24 & 255] + "-" + wt[e & 255] + wt[e >> 8 & 255] + "-" + wt[e >> 16 & 15 | 64] + wt[e >> 24 & 255] + "-" + wt[t & 63 | 128] + wt[t >> 8 & 255] + "-" + wt[t >> 16 & 255] + wt[t >> 24 & 255] + wt[i & 255] + wt[i >> 8 & 255] + wt[i >> 16 & 255] + wt[i >> 24 & 255]).toLowerCase();
|
|
2547
2547
|
}
|
|
2548
2548
|
function vt(n, e, t) {
|
|
2549
2549
|
return Math.max(e, Math.min(t, n));
|
|
@@ -2551,10 +2551,10 @@ function vt(n, e, t) {
|
|
|
2551
2551
|
function Pa(n, e) {
|
|
2552
2552
|
return (n % e + e) % e;
|
|
2553
2553
|
}
|
|
2554
|
-
function
|
|
2554
|
+
function Tm(n, e, t, i, r) {
|
|
2555
2555
|
return i + (n - e) * (r - i) / (t - e);
|
|
2556
2556
|
}
|
|
2557
|
-
function
|
|
2557
|
+
function wm(n, e, t) {
|
|
2558
2558
|
return n !== e ? (t - n) / (e - n) : 0;
|
|
2559
2559
|
}
|
|
2560
2560
|
function dr(n, e, t) {
|
|
@@ -2672,8 +2672,8 @@ const ph = {
|
|
|
2672
2672
|
generateUUID: mn,
|
|
2673
2673
|
clamp: vt,
|
|
2674
2674
|
euclideanModulo: Pa,
|
|
2675
|
-
mapLinear:
|
|
2676
|
-
inverseLerp:
|
|
2675
|
+
mapLinear: Tm,
|
|
2676
|
+
inverseLerp: wm,
|
|
2677
2677
|
lerp: dr,
|
|
2678
2678
|
damp: Am,
|
|
2679
2679
|
pingpong: Cm,
|
|
@@ -2946,8 +2946,8 @@ class Be {
|
|
|
2946
2946
|
return this.multiplyMatrices(e, this);
|
|
2947
2947
|
}
|
|
2948
2948
|
multiplyMatrices(e, t) {
|
|
2949
|
-
const i = e.elements, r = t.elements, s = this.elements, o = i[0], a = i[3], l = i[6], c = i[1], u = i[4], h = i[7], f = i[2], d = i[5], g = i[8], _ = r[0], m = r[3], p = r[6], S = r[1], v = r[4], M = r[7], b = r[2], R = r[5],
|
|
2950
|
-
return s[0] = o * _ + a * S + l * b, s[3] = o * m + a * v + l * R, s[6] = o * p + a * M + l *
|
|
2949
|
+
const i = e.elements, r = t.elements, s = this.elements, o = i[0], a = i[3], l = i[6], c = i[1], u = i[4], h = i[7], f = i[2], d = i[5], g = i[8], _ = r[0], m = r[3], p = r[6], S = r[1], v = r[4], M = r[7], b = r[2], R = r[5], w = r[8];
|
|
2950
|
+
return s[0] = o * _ + a * S + l * b, s[3] = o * m + a * v + l * R, s[6] = o * p + a * M + l * w, s[1] = c * _ + u * S + h * b, s[4] = c * m + u * v + h * R, s[7] = c * p + u * M + h * w, s[2] = f * _ + d * S + g * b, s[5] = f * m + d * v + g * R, s[8] = f * p + d * M + g * w, this;
|
|
2951
2951
|
}
|
|
2952
2952
|
multiplyScalar(e) {
|
|
2953
2953
|
const t = this.elements;
|
|
@@ -3453,8 +3453,8 @@ class Ke {
|
|
|
3453
3453
|
if (Math.abs(u + f) < 0.1 && Math.abs(h + _) < 0.1 && Math.abs(g + m) < 0.1 && Math.abs(c + d + p - 3) < 0.1)
|
|
3454
3454
|
return this.set(1, 0, 0, 0), this;
|
|
3455
3455
|
t = Math.PI;
|
|
3456
|
-
const v = (c + 1) / 2, M = (d + 1) / 2, b = (p + 1) / 2, R = (u + f) / 4,
|
|
3457
|
-
return v > M && v > b ? v < 0.01 ? (i = 0, r = 0.707106781, s = 0.707106781) : (i = Math.sqrt(v), r = R / i, s =
|
|
3456
|
+
const v = (c + 1) / 2, M = (d + 1) / 2, b = (p + 1) / 2, R = (u + f) / 4, w = (h + _) / 4, N = (g + m) / 4;
|
|
3457
|
+
return v > M && v > b ? v < 0.01 ? (i = 0, r = 0.707106781, s = 0.707106781) : (i = Math.sqrt(v), r = R / i, s = w / i) : M > b ? M < 0.01 ? (i = 0.707106781, r = 0, s = 0.707106781) : (r = Math.sqrt(M), i = R / r, s = N / r) : b < 0.01 ? (i = 0.707106781, r = 0.707106781, s = 0) : (s = Math.sqrt(b), i = w / s, r = N / s), this.set(i, r, s, t), this;
|
|
3458
3458
|
}
|
|
3459
3459
|
let S = Math.sqrt((m - g) * (m - g) + (h - _) * (h - _) + (f - u) * (f - u));
|
|
3460
3460
|
return Math.abs(S) < 1e-3 && (S = 1), this.x = (m - g) / S, this.y = (h - _) / S, this.z = (f - u) / S, this.w = Math.acos((c + d + p - 1) / 2), this;
|
|
@@ -4564,8 +4564,8 @@ class rt {
|
|
|
4564
4564
|
return this.multiplyMatrices(e, this);
|
|
4565
4565
|
}
|
|
4566
4566
|
multiplyMatrices(e, t) {
|
|
4567
|
-
const i = e.elements, r = t.elements, s = this.elements, o = i[0], a = i[4], l = i[8], c = i[12], u = i[1], h = i[5], f = i[9], d = i[13], g = i[2], _ = i[6], m = i[10], p = i[14], S = i[3], v = i[7], M = i[11], b = i[15], R = r[0],
|
|
4568
|
-
return s[0] = o * R + a * E + l * U + c * V, s[4] = o *
|
|
4567
|
+
const i = e.elements, r = t.elements, s = this.elements, o = i[0], a = i[4], l = i[8], c = i[12], u = i[1], h = i[5], f = i[9], d = i[13], g = i[2], _ = i[6], m = i[10], p = i[14], S = i[3], v = i[7], M = i[11], b = i[15], R = r[0], w = r[4], N = r[8], x = r[12], E = r[1], F = r[5], ee = r[9], O = r[13], U = r[2], C = r[6], z = r[10], H = r[14], V = r[3], K = r[7], Q = r[11], B = r[15];
|
|
4568
|
+
return s[0] = o * R + a * E + l * U + c * V, s[4] = o * w + a * F + l * C + c * K, s[8] = o * N + a * ee + l * z + c * Q, s[12] = o * x + a * O + l * H + c * B, s[1] = u * R + h * E + f * U + d * V, s[5] = u * w + h * F + f * C + d * K, s[9] = u * N + h * ee + f * z + d * Q, s[13] = u * x + h * O + f * H + d * B, s[2] = g * R + _ * E + m * U + p * V, s[6] = g * w + _ * F + m * C + p * K, s[10] = g * N + _ * ee + m * z + p * Q, s[14] = g * x + _ * O + m * H + p * B, s[3] = S * R + v * E + M * U + b * V, s[7] = S * w + v * F + M * C + b * K, s[11] = S * N + v * ee + M * z + b * Q, s[15] = S * x + v * O + M * H + b * B, this;
|
|
4569
4569
|
}
|
|
4570
4570
|
multiplyScalar(e) {
|
|
4571
4571
|
const t = this.elements;
|
|
@@ -4588,8 +4588,8 @@ class rt {
|
|
|
4588
4588
|
const e = this.elements, t = e[0], i = e[1], r = e[2], s = e[3], o = e[4], a = e[5], l = e[6], c = e[7], u = e[8], h = e[9], f = e[10], d = e[11], g = e[12], _ = e[13], m = e[14], p = e[15], S = h * m * c - _ * f * c + _ * l * d - a * m * d - h * l * p + a * f * p, v = g * f * c - u * m * c - g * l * d + o * m * d + u * l * p - o * f * p, M = u * _ * c - g * h * c + g * a * d - o * _ * d - u * a * p + o * h * p, b = g * h * l - u * _ * l - g * a * f + o * _ * f + u * a * m - o * h * m, R = t * S + i * v + r * M + s * b;
|
|
4589
4589
|
if (R === 0)
|
|
4590
4590
|
return this.set(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
|
|
4591
|
-
const
|
|
4592
|
-
return e[0] = S *
|
|
4591
|
+
const w = 1 / R;
|
|
4592
|
+
return e[0] = S * w, e[1] = (_ * f * s - h * m * s - _ * r * d + i * m * d + h * r * p - i * f * p) * w, e[2] = (a * m * s - _ * l * s + _ * r * c - i * m * c - a * r * p + i * l * p) * w, e[3] = (h * l * s - a * f * s - h * r * c + i * f * c + a * r * d - i * l * d) * w, e[4] = v * w, e[5] = (u * m * s - g * f * s + g * r * d - t * m * d - u * r * p + t * f * p) * w, e[6] = (g * l * s - o * m * s - g * r * c + t * m * c + o * r * p - t * l * p) * w, e[7] = (o * f * s - u * l * s + u * r * c - t * f * c - o * r * d + t * l * d) * w, e[8] = M * w, e[9] = (g * h * s - u * _ * s - g * i * d + t * _ * d + u * i * p - t * h * p) * w, e[10] = (o * _ * s - g * a * s + g * i * c - t * _ * c - o * i * p + t * a * p) * w, e[11] = (u * a * s - o * h * s - u * i * c + t * h * c + o * i * d - t * a * d) * w, e[12] = b * w, e[13] = (u * _ * r - g * h * r + g * i * f - t * _ * f - u * i * m + t * h * m) * w, e[14] = (g * a * r - o * _ * r - g * i * l + t * _ * l + o * i * m - t * a * m) * w, e[15] = (o * h * r - u * a * r + u * i * l - t * h * l - o * i * f + t * a * f) * w, this;
|
|
4593
4593
|
}
|
|
4594
4594
|
scale(e) {
|
|
4595
4595
|
const t = this.elements, i = e.x, r = e.y, s = e.z;
|
|
@@ -4761,8 +4761,8 @@ class rt {
|
|
|
4761
4761
|
), this;
|
|
4762
4762
|
}
|
|
4763
4763
|
compose(e, t, i) {
|
|
4764
|
-
const r = this.elements, s = t._x, o = t._y, a = t._z, l = t._w, c = s + s, u = o + o, h = a + a, f = s * c, d = s * u, g = s * h, _ = o * u, m = o * h, p = a * h, S = l * c, v = l * u, M = l * h, b = i.x, R = i.y,
|
|
4765
|
-
return r[0] = (1 - (_ + p)) * b, r[1] = (d + M) * b, r[2] = (g - v) * b, r[3] = 0, r[4] = (d - M) * R, r[5] = (1 - (f + p)) * R, r[6] = (m + S) * R, r[7] = 0, r[8] = (g + v) *
|
|
4764
|
+
const r = this.elements, s = t._x, o = t._y, a = t._z, l = t._w, c = s + s, u = o + o, h = a + a, f = s * c, d = s * u, g = s * h, _ = o * u, m = o * h, p = a * h, S = l * c, v = l * u, M = l * h, b = i.x, R = i.y, w = i.z;
|
|
4765
|
+
return r[0] = (1 - (_ + p)) * b, r[1] = (d + M) * b, r[2] = (g - v) * b, r[3] = 0, r[4] = (d - M) * R, r[5] = (1 - (f + p)) * R, r[6] = (m + S) * R, r[7] = 0, r[8] = (g + v) * w, r[9] = (m - S) * w, r[10] = (1 - (f + _)) * w, r[11] = 0, r[12] = e.x, r[13] = e.y, r[14] = e.z, r[15] = 1, this;
|
|
4766
4766
|
}
|
|
4767
4767
|
decompose(e, t, i) {
|
|
4768
4768
|
const r = this.elements;
|
|
@@ -5225,7 +5225,7 @@ class at extends gi {
|
|
|
5225
5225
|
at.DEFAULT_UP = /* @__PURE__ */ new D(0, 1, 0);
|
|
5226
5226
|
at.DEFAULT_MATRIX_AUTO_UPDATE = !0;
|
|
5227
5227
|
at.DEFAULT_MATRIX_WORLD_AUTO_UPDATE = !0;
|
|
5228
|
-
const Qt = /* @__PURE__ */ new D(),
|
|
5228
|
+
const Qt = /* @__PURE__ */ new D(), Tn = /* @__PURE__ */ new D(), Mo = /* @__PURE__ */ new D(), wn = /* @__PURE__ */ new D(), Ti = /* @__PURE__ */ new D(), wi = /* @__PURE__ */ new D(), xc = /* @__PURE__ */ new D(), Eo = /* @__PURE__ */ new D(), bo = /* @__PURE__ */ new D(), To = /* @__PURE__ */ new D();
|
|
5229
5229
|
let qr = !1;
|
|
5230
5230
|
class tn {
|
|
5231
5231
|
constructor(e = new D(), t = new D(), i = new D()) {
|
|
@@ -5239,24 +5239,24 @@ class tn {
|
|
|
5239
5239
|
// static/instance method to calculate barycentric coordinates
|
|
5240
5240
|
// based on: http://www.blackpawn.com/texts/pointinpoly/default.html
|
|
5241
5241
|
static getBarycoord(e, t, i, r, s) {
|
|
5242
|
-
Qt.subVectors(r, t),
|
|
5243
|
-
const o = Qt.dot(Qt), a = Qt.dot(
|
|
5242
|
+
Qt.subVectors(r, t), Tn.subVectors(i, t), Mo.subVectors(e, t);
|
|
5243
|
+
const o = Qt.dot(Qt), a = Qt.dot(Tn), l = Qt.dot(Mo), c = Tn.dot(Tn), u = Tn.dot(Mo), h = o * c - a * a;
|
|
5244
5244
|
if (h === 0)
|
|
5245
5245
|
return s.set(-2, -1, -1);
|
|
5246
5246
|
const f = 1 / h, d = (c * l - a * u) * f, g = (o * u - a * l) * f;
|
|
5247
5247
|
return s.set(1 - d - g, g, d);
|
|
5248
5248
|
}
|
|
5249
5249
|
static containsPoint(e, t, i, r) {
|
|
5250
|
-
return this.getBarycoord(e, t, i, r,
|
|
5250
|
+
return this.getBarycoord(e, t, i, r, wn), wn.x >= 0 && wn.y >= 0 && wn.x + wn.y <= 1;
|
|
5251
5251
|
}
|
|
5252
5252
|
static getUV(e, t, i, r, s, o, a, l) {
|
|
5253
5253
|
return qr === !1 && (console.warn("THREE.Triangle.getUV() has been renamed to THREE.Triangle.getInterpolation()."), qr = !0), this.getInterpolation(e, t, i, r, s, o, a, l);
|
|
5254
5254
|
}
|
|
5255
5255
|
static getInterpolation(e, t, i, r, s, o, a, l) {
|
|
5256
|
-
return this.getBarycoord(e, t, i, r,
|
|
5256
|
+
return this.getBarycoord(e, t, i, r, wn), l.setScalar(0), l.addScaledVector(s, wn.x), l.addScaledVector(o, wn.y), l.addScaledVector(a, wn.z), l;
|
|
5257
5257
|
}
|
|
5258
5258
|
static isFrontFacing(e, t, i, r) {
|
|
5259
|
-
return Qt.subVectors(i, t),
|
|
5259
|
+
return Qt.subVectors(i, t), Tn.subVectors(e, t), Qt.cross(Tn).dot(r) < 0;
|
|
5260
5260
|
}
|
|
5261
5261
|
set(e, t, i) {
|
|
5262
5262
|
return this.a.copy(e), this.b.copy(t), this.c.copy(i), this;
|
|
@@ -5274,7 +5274,7 @@ class tn {
|
|
|
5274
5274
|
return this.a.copy(e.a), this.b.copy(e.b), this.c.copy(e.c), this;
|
|
5275
5275
|
}
|
|
5276
5276
|
getArea() {
|
|
5277
|
-
return Qt.subVectors(this.c, this.b),
|
|
5277
|
+
return Qt.subVectors(this.c, this.b), Tn.subVectors(this.a, this.b), Qt.cross(Tn).length() * 0.5;
|
|
5278
5278
|
}
|
|
5279
5279
|
getMidpoint(e) {
|
|
5280
5280
|
return e.addVectors(this.a, this.b).add(this.c).multiplyScalar(1 / 3);
|
|
@@ -5306,29 +5306,29 @@ class tn {
|
|
|
5306
5306
|
closestPointToPoint(e, t) {
|
|
5307
5307
|
const i = this.a, r = this.b, s = this.c;
|
|
5308
5308
|
let o, a;
|
|
5309
|
-
|
|
5310
|
-
const l =
|
|
5309
|
+
Ti.subVectors(r, i), wi.subVectors(s, i), Eo.subVectors(e, i);
|
|
5310
|
+
const l = Ti.dot(Eo), c = wi.dot(Eo);
|
|
5311
5311
|
if (l <= 0 && c <= 0)
|
|
5312
5312
|
return t.copy(i);
|
|
5313
5313
|
bo.subVectors(e, r);
|
|
5314
|
-
const u =
|
|
5314
|
+
const u = Ti.dot(bo), h = wi.dot(bo);
|
|
5315
5315
|
if (u >= 0 && h <= u)
|
|
5316
5316
|
return t.copy(r);
|
|
5317
5317
|
const f = l * h - u * c;
|
|
5318
5318
|
if (f <= 0 && l >= 0 && u <= 0)
|
|
5319
|
-
return o = l / (l - u), t.copy(i).addScaledVector(
|
|
5320
|
-
|
|
5321
|
-
const d =
|
|
5319
|
+
return o = l / (l - u), t.copy(i).addScaledVector(Ti, o);
|
|
5320
|
+
To.subVectors(e, s);
|
|
5321
|
+
const d = Ti.dot(To), g = wi.dot(To);
|
|
5322
5322
|
if (g >= 0 && d <= g)
|
|
5323
5323
|
return t.copy(s);
|
|
5324
5324
|
const _ = d * c - l * g;
|
|
5325
5325
|
if (_ <= 0 && c >= 0 && g <= 0)
|
|
5326
|
-
return a = c / (c - g), t.copy(i).addScaledVector(
|
|
5326
|
+
return a = c / (c - g), t.copy(i).addScaledVector(wi, a);
|
|
5327
5327
|
const m = u * g - d * h;
|
|
5328
5328
|
if (m <= 0 && h - u >= 0 && d - g >= 0)
|
|
5329
5329
|
return xc.subVectors(s, r), a = (h - u) / (h - u + (d - g)), t.copy(r).addScaledVector(xc, a);
|
|
5330
5330
|
const p = 1 / (m + _ + f);
|
|
5331
|
-
return o = _ * p, a = f * p, t.copy(i).addScaledVector(
|
|
5331
|
+
return o = _ * p, a = f * p, t.copy(i).addScaledVector(Ti, o).addScaledVector(wi, a);
|
|
5332
5332
|
}
|
|
5333
5333
|
equals(e) {
|
|
5334
5334
|
return e.a.equals(this.a) && e.b.equals(this.b) && e.c.equals(this.c);
|
|
@@ -5570,7 +5570,7 @@ const xh = {
|
|
|
5570
5570
|
yellow: 16776960,
|
|
5571
5571
|
yellowgreen: 10145074
|
|
5572
5572
|
}, en = { h: 0, s: 0, l: 0 }, jr = { h: 0, s: 0, l: 0 };
|
|
5573
|
-
function
|
|
5573
|
+
function wo(n, e, t) {
|
|
5574
5574
|
return t < 0 && (t += 1), t > 1 && (t -= 1), t < 1 / 6 ? n + (e - n) * 6 * t : t < 1 / 2 ? e : t < 2 / 3 ? n + (e - n) * 6 * (2 / 3 - t) : n;
|
|
5575
5575
|
}
|
|
5576
5576
|
class je {
|
|
@@ -5599,7 +5599,7 @@ class je {
|
|
|
5599
5599
|
this.r = this.g = this.b = i;
|
|
5600
5600
|
else {
|
|
5601
5601
|
const s = i <= 0.5 ? i * (1 + t) : i + t - i * t, o = 2 * i - s;
|
|
5602
|
-
this.r =
|
|
5602
|
+
this.r = wo(o, s, e + 1 / 3), this.g = wo(o, s, e), this.b = wo(o, s, e - 1 / 3);
|
|
5603
5603
|
}
|
|
5604
5604
|
return Zt.toWorkingColorSpace(this, r), this;
|
|
5605
5605
|
}
|
|
@@ -6073,11 +6073,11 @@ class _n extends gi {
|
|
|
6073
6073
|
i[C + 2]
|
|
6074
6074
|
);
|
|
6075
6075
|
}
|
|
6076
|
-
const b = new D(), R = new D(),
|
|
6076
|
+
const b = new D(), R = new D(), w = new D(), N = new D();
|
|
6077
6077
|
function x(E) {
|
|
6078
|
-
|
|
6078
|
+
w.fromArray(s, E * 3), N.copy(w);
|
|
6079
6079
|
const F = c[E];
|
|
6080
|
-
b.copy(F), b.sub(
|
|
6080
|
+
b.copy(F), b.sub(w.multiplyScalar(w.dot(F))).normalize(), R.crossVectors(N, F);
|
|
6081
6081
|
const O = R.dot(u[E]) < 0 ? -1 : 1;
|
|
6082
6082
|
l[E * 4] = b.x, l[E * 4 + 1] = b.y, l[E * 4 + 2] = b.z, l[E * 4 + 3] = O;
|
|
6083
6083
|
}
|
|
@@ -6275,8 +6275,8 @@ class pn extends at {
|
|
|
6275
6275
|
for (let g = 0, _ = f.length; g < _; g++) {
|
|
6276
6276
|
const m = f[g], p = o[m.materialIndex], S = Math.max(m.start, d.start), v = Math.min(a.count, Math.min(m.start + m.count, d.start + d.count));
|
|
6277
6277
|
for (let M = S, b = v; M < b; M += 3) {
|
|
6278
|
-
const R = a.getX(M),
|
|
6279
|
-
r = is(this, p, e, i, c, u, h, R,
|
|
6278
|
+
const R = a.getX(M), w = a.getX(M + 1), N = a.getX(M + 2);
|
|
6279
|
+
r = is(this, p, e, i, c, u, h, R, w, N), r && (r.faceIndex = Math.floor(M / 3), r.face.materialIndex = m.materialIndex, t.push(r));
|
|
6280
6280
|
}
|
|
6281
6281
|
}
|
|
6282
6282
|
else {
|
|
@@ -6291,8 +6291,8 @@ class pn extends at {
|
|
|
6291
6291
|
for (let g = 0, _ = f.length; g < _; g++) {
|
|
6292
6292
|
const m = f[g], p = o[m.materialIndex], S = Math.max(m.start, d.start), v = Math.min(l.count, Math.min(m.start + m.count, d.start + d.count));
|
|
6293
6293
|
for (let M = S, b = v; M < b; M += 3) {
|
|
6294
|
-
const R = M,
|
|
6295
|
-
r = is(this, p, e, i, c, u, h, R,
|
|
6294
|
+
const R = M, w = M + 1, N = M + 2;
|
|
6295
|
+
r = is(this, p, e, i, c, u, h, R, w, N), r && (r.faceIndex = Math.floor(M / 3), r.face.materialIndex = m.materialIndex, t.push(r));
|
|
6296
6296
|
}
|
|
6297
6297
|
}
|
|
6298
6298
|
else {
|
|
@@ -6347,19 +6347,19 @@ class Ir extends _n {
|
|
|
6347
6347
|
const l = [], c = [], u = [], h = [];
|
|
6348
6348
|
let f = 0, d = 0;
|
|
6349
6349
|
g("z", "y", "x", -1, -1, i, t, e, o, s, 0), g("z", "y", "x", 1, -1, i, t, -e, o, s, 1), g("x", "z", "y", 1, 1, e, i, t, r, o, 2), g("x", "z", "y", 1, -1, e, i, -t, r, o, 3), g("x", "y", "z", 1, -1, e, t, i, r, s, 4), g("x", "y", "z", -1, -1, e, t, -i, r, s, 5), this.setIndex(l), this.setAttribute("position", new jt(c, 3)), this.setAttribute("normal", new jt(u, 3)), this.setAttribute("uv", new jt(h, 2));
|
|
6350
|
-
function g(_, m, p, S, v, M, b, R,
|
|
6351
|
-
const E = M /
|
|
6350
|
+
function g(_, m, p, S, v, M, b, R, w, N, x) {
|
|
6351
|
+
const E = M / w, F = b / N, ee = M / 2, O = b / 2, U = R / 2, C = w + 1, z = N + 1;
|
|
6352
6352
|
let H = 0, V = 0;
|
|
6353
6353
|
const K = new D();
|
|
6354
6354
|
for (let Q = 0; Q < z; Q++) {
|
|
6355
6355
|
const B = Q * F - O;
|
|
6356
6356
|
for (let q = 0; q < C; q++) {
|
|
6357
6357
|
const oe = q * E - ee;
|
|
6358
|
-
K[_] = oe * S, K[m] = B * v, K[p] = U, c.push(K.x, K.y, K.z), K[_] = 0, K[m] = 0, K[p] = R > 0 ? 1 : -1, u.push(K.x, K.y, K.z), h.push(q /
|
|
6358
|
+
K[_] = oe * S, K[m] = B * v, K[p] = U, c.push(K.x, K.y, K.z), K[_] = 0, K[m] = 0, K[p] = R > 0 ? 1 : -1, u.push(K.x, K.y, K.z), h.push(q / w), h.push(1 - Q / N), H += 1;
|
|
6359
6359
|
}
|
|
6360
6360
|
}
|
|
6361
6361
|
for (let Q = 0; Q < N; Q++)
|
|
6362
|
-
for (let B = 0; B <
|
|
6362
|
+
for (let B = 0; B < w; B++) {
|
|
6363
6363
|
const q = f + B + C * Q, oe = f + B + C * (Q + 1), me = f + (B + 1) + C * (Q + 1), ge = f + (B + 1) + C * Q;
|
|
6364
6364
|
l.push(q, oe, ge), l.push(oe, me, ge), V += 6;
|
|
6365
6365
|
}
|
|
@@ -6849,7 +6849,7 @@ class Na {
|
|
|
6849
6849
|
return new this.constructor().copy(this);
|
|
6850
6850
|
}
|
|
6851
6851
|
}
|
|
6852
|
-
function
|
|
6852
|
+
function Th() {
|
|
6853
6853
|
let n = null, e = !1, t = null, i = null;
|
|
6854
6854
|
function r(s, o) {
|
|
6855
6855
|
t(s, o), i = n.requestAnimationFrame(r);
|
|
@@ -7040,7 +7040,7 @@ var mg = `#ifdef USE_ALPHAHASH
|
|
|
7040
7040
|
#endif`, bg = `vec3 objectNormal = vec3( normal );
|
|
7041
7041
|
#ifdef USE_TANGENT
|
|
7042
7042
|
vec3 objectTangent = vec3( tangent.xyz );
|
|
7043
|
-
#endif`,
|
|
7043
|
+
#endif`, Tg = `float G_BlinnPhong_Implicit( ) {
|
|
7044
7044
|
return 0.25;
|
|
7045
7045
|
}
|
|
7046
7046
|
float D_BlinnPhong( const in float shininess, const in float dotNH ) {
|
|
@@ -7054,7 +7054,7 @@ vec3 BRDF_BlinnPhong( const in vec3 lightDir, const in vec3 viewDir, const in ve
|
|
|
7054
7054
|
float G = G_BlinnPhong_Implicit( );
|
|
7055
7055
|
float D = D_BlinnPhong( shininess, dotNH );
|
|
7056
7056
|
return F * ( G * D );
|
|
7057
|
-
} // validated`,
|
|
7057
|
+
} // validated`, wg = `#ifdef USE_IRIDESCENCE
|
|
7058
7058
|
const mat3 XYZ_TO_REC709 = mat3(
|
|
7059
7059
|
3.2404542, -0.9692660, 0.0556434,
|
|
7060
7060
|
-1.5371385, 1.8760108, -0.2040259,
|
|
@@ -8294,9 +8294,9 @@ IncidentLight directLight;
|
|
|
8294
8294
|
#ifdef USE_METALNESSMAP
|
|
8295
8295
|
vec4 texelMetalness = texture2D( metalnessMap, vMetalnessMapUv );
|
|
8296
8296
|
metalnessFactor *= texelMetalness.b;
|
|
8297
|
-
#endif`,
|
|
8297
|
+
#endif`, T_ = `#ifdef USE_METALNESSMAP
|
|
8298
8298
|
uniform sampler2D metalnessMap;
|
|
8299
|
-
#endif`,
|
|
8299
|
+
#endif`, w_ = `#if defined( USE_MORPHCOLORS ) && defined( MORPHTARGETS_TEXTURE )
|
|
8300
8300
|
vColor *= morphTargetBaseInfluence;
|
|
8301
8301
|
for ( int i = 0; i < MORPHTARGETS_COUNT; i ++ ) {
|
|
8302
8302
|
#if defined( USE_COLOR_ALPHA )
|
|
@@ -9478,7 +9478,7 @@ void main() {
|
|
|
9478
9478
|
#include <logdepthbuf_vertex>
|
|
9479
9479
|
#include <clipping_planes_vertex>
|
|
9480
9480
|
#include <fog_vertex>
|
|
9481
|
-
}`,
|
|
9481
|
+
}`, Tv = `uniform vec3 diffuse;
|
|
9482
9482
|
uniform float opacity;
|
|
9483
9483
|
uniform float dashSize;
|
|
9484
9484
|
uniform float totalSize;
|
|
@@ -9506,7 +9506,7 @@ void main() {
|
|
|
9506
9506
|
#include <colorspace_fragment>
|
|
9507
9507
|
#include <fog_fragment>
|
|
9508
9508
|
#include <premultiplied_alpha_fragment>
|
|
9509
|
-
}`,
|
|
9509
|
+
}`, wv = `#include <common>
|
|
9510
9510
|
#include <uv_pars_vertex>
|
|
9511
9511
|
#include <envmap_pars_vertex>
|
|
9512
9512
|
#include <color_pars_vertex>
|
|
@@ -10301,8 +10301,8 @@ void main() {
|
|
|
10301
10301
|
aomap_pars_fragment: Mg,
|
|
10302
10302
|
begin_vertex: Eg,
|
|
10303
10303
|
beginnormal_vertex: bg,
|
|
10304
|
-
bsdfs:
|
|
10305
|
-
iridescence_fragment:
|
|
10304
|
+
bsdfs: Tg,
|
|
10305
|
+
iridescence_fragment: wg,
|
|
10306
10306
|
bumpmap_pars_fragment: Ag,
|
|
10307
10307
|
clipping_planes_fragment: Cg,
|
|
10308
10308
|
clipping_planes_pars_fragment: Rg,
|
|
@@ -10355,8 +10355,8 @@ void main() {
|
|
|
10355
10355
|
map_particle_fragment: M_,
|
|
10356
10356
|
map_particle_pars_fragment: E_,
|
|
10357
10357
|
metalnessmap_fragment: b_,
|
|
10358
|
-
metalnessmap_pars_fragment:
|
|
10359
|
-
morphcolor_vertex:
|
|
10358
|
+
metalnessmap_pars_fragment: T_,
|
|
10359
|
+
morphcolor_vertex: w_,
|
|
10360
10360
|
morphnormal_vertex: A_,
|
|
10361
10361
|
morphtarget_pars_vertex: C_,
|
|
10362
10362
|
morphtarget_vertex: R_,
|
|
@@ -10409,8 +10409,8 @@ void main() {
|
|
|
10409
10409
|
equirect_vert: Mv,
|
|
10410
10410
|
equirect_frag: Ev,
|
|
10411
10411
|
linedashed_vert: bv,
|
|
10412
|
-
linedashed_frag:
|
|
10413
|
-
meshbasic_vert:
|
|
10412
|
+
linedashed_frag: Tv,
|
|
10413
|
+
meshbasic_vert: wv,
|
|
10414
10414
|
meshbasic_frag: Av,
|
|
10415
10415
|
meshlambert_vert: Cv,
|
|
10416
10416
|
meshlambert_frag: Rv,
|
|
@@ -10883,8 +10883,8 @@ function $v(n, e, t, i, r, s, o) {
|
|
|
10883
10883
|
depthWrite: !1,
|
|
10884
10884
|
fog: !1
|
|
10885
10885
|
})
|
|
10886
|
-
), u.geometry.deleteAttribute("normal"), u.geometry.deleteAttribute("uv"), u.onBeforeRender = function(b, R,
|
|
10887
|
-
this.matrixWorld.copyPosition(
|
|
10886
|
+
), u.geometry.deleteAttribute("normal"), u.geometry.deleteAttribute("uv"), u.onBeforeRender = function(b, R, w) {
|
|
10887
|
+
this.matrixWorld.copyPosition(w.matrixWorld);
|
|
10888
10888
|
}, Object.defineProperty(u.material, "envMap", {
|
|
10889
10889
|
get: function() {
|
|
10890
10890
|
return this.uniforms.envMap.value;
|
|
@@ -11019,7 +11019,7 @@ function qv(n, e, t, i) {
|
|
|
11019
11019
|
for (let z = 0, H = C.length; z < H; z++)
|
|
11020
11020
|
C[z] !== U[z] && (n.disableVertexAttribArray(z), C[z] = 0);
|
|
11021
11021
|
}
|
|
11022
|
-
function
|
|
11022
|
+
function w(U, C, z, H, V, K, Q) {
|
|
11023
11023
|
Q === !0 ? n.vertexAttribIPointer(U, C, z, V, K) : n.vertexAttribPointer(U, C, z, H, V, K);
|
|
11024
11024
|
}
|
|
11025
11025
|
function N(U, C, z, H) {
|
|
@@ -11035,7 +11035,7 @@ function qv(n, e, t, i) {
|
|
|
11035
11035
|
const me = oe.normalized, ge = oe.itemSize, Ae = t.get(oe);
|
|
11036
11036
|
if (Ae === void 0)
|
|
11037
11037
|
continue;
|
|
11038
|
-
const
|
|
11038
|
+
const we = Ae.buffer, Te = Ae.type, Ve = Ae.bytesPerElement, Ze = i.isWebGL2 === !0 && (Te === n.INT || Te === n.UNSIGNED_INT || oe.gpuType === oh);
|
|
11039
11039
|
if (oe.isInterleavedBufferAttribute) {
|
|
11040
11040
|
const Ce = oe.data, P = Ce.stride, he = oe.offset;
|
|
11041
11041
|
if (Ce.isInstancedInterleavedBuffer) {
|
|
@@ -11045,12 +11045,12 @@ function qv(n, e, t, i) {
|
|
|
11045
11045
|
} else
|
|
11046
11046
|
for (let J = 0; J < q.locationSize; J++)
|
|
11047
11047
|
M(q.location + J);
|
|
11048
|
-
n.bindBuffer(n.ARRAY_BUFFER,
|
|
11048
|
+
n.bindBuffer(n.ARRAY_BUFFER, we);
|
|
11049
11049
|
for (let J = 0; J < q.locationSize; J++)
|
|
11050
|
-
|
|
11050
|
+
w(
|
|
11051
11051
|
q.location + J,
|
|
11052
11052
|
ge / q.locationSize,
|
|
11053
|
-
|
|
11053
|
+
Te,
|
|
11054
11054
|
me,
|
|
11055
11055
|
P * Ve,
|
|
11056
11056
|
(he + ge / q.locationSize * J) * Ve,
|
|
@@ -11064,12 +11064,12 @@ function qv(n, e, t, i) {
|
|
|
11064
11064
|
} else
|
|
11065
11065
|
for (let Ce = 0; Ce < q.locationSize; Ce++)
|
|
11066
11066
|
M(q.location + Ce);
|
|
11067
|
-
n.bindBuffer(n.ARRAY_BUFFER,
|
|
11067
|
+
n.bindBuffer(n.ARRAY_BUFFER, we);
|
|
11068
11068
|
for (let Ce = 0; Ce < q.locationSize; Ce++)
|
|
11069
|
-
|
|
11069
|
+
w(
|
|
11070
11070
|
q.location + Ce,
|
|
11071
11071
|
ge / q.locationSize,
|
|
11072
|
-
|
|
11072
|
+
Te,
|
|
11073
11073
|
me,
|
|
11074
11074
|
ge * Ve,
|
|
11075
11075
|
ge / q.locationSize * Ce * Ve,
|
|
@@ -11180,19 +11180,19 @@ function Yv(n, e, t) {
|
|
|
11180
11180
|
if (i !== void 0)
|
|
11181
11181
|
return i;
|
|
11182
11182
|
if (e.has("EXT_texture_filter_anisotropic") === !0) {
|
|
11183
|
-
const
|
|
11184
|
-
i = n.getParameter(
|
|
11183
|
+
const w = e.get("EXT_texture_filter_anisotropic");
|
|
11184
|
+
i = n.getParameter(w.MAX_TEXTURE_MAX_ANISOTROPY_EXT);
|
|
11185
11185
|
} else
|
|
11186
11186
|
i = 0;
|
|
11187
11187
|
return i;
|
|
11188
11188
|
}
|
|
11189
|
-
function s(
|
|
11190
|
-
if (
|
|
11189
|
+
function s(w) {
|
|
11190
|
+
if (w === "highp") {
|
|
11191
11191
|
if (n.getShaderPrecisionFormat(n.VERTEX_SHADER, n.HIGH_FLOAT).precision > 0 && n.getShaderPrecisionFormat(n.FRAGMENT_SHADER, n.HIGH_FLOAT).precision > 0)
|
|
11192
11192
|
return "highp";
|
|
11193
|
-
|
|
11193
|
+
w = "mediump";
|
|
11194
11194
|
}
|
|
11195
|
-
return
|
|
11195
|
+
return w === "mediump" && n.getShaderPrecisionFormat(n.VERTEX_SHADER, n.MEDIUM_FLOAT).precision > 0 && n.getShaderPrecisionFormat(n.FRAGMENT_SHADER, n.MEDIUM_FLOAT).precision > 0 ? "mediump" : "lowp";
|
|
11196
11196
|
}
|
|
11197
11197
|
const o = typeof WebGL2RenderingContext != "undefined" && n.constructor.name === "WebGL2RenderingContext";
|
|
11198
11198
|
let a = t.precision !== void 0 ? t.precision : "highp";
|
|
@@ -11338,7 +11338,7 @@ class Jv extends Eh {
|
|
|
11338
11338
|
return t.object.zoom = this.zoom, t.object.left = this.left, t.object.right = this.right, t.object.top = this.top, t.object.bottom = this.bottom, t.object.near = this.near, t.object.far = this.far, this.view !== null && (t.object.view = Object.assign({}, this.view)), t;
|
|
11339
11339
|
}
|
|
11340
11340
|
}
|
|
11341
|
-
const Oi = 4,
|
|
11341
|
+
const Oi = 4, Tc = [0.125, 0.215, 0.35, 0.446, 0.526, 0.582], ri = 20, Po = /* @__PURE__ */ new Jv(), wc = /* @__PURE__ */ new je();
|
|
11342
11342
|
let Lo = null;
|
|
11343
11343
|
const ii = (1 + Math.sqrt(5)) / 2, Ii = 1 / ii, Ac = [
|
|
11344
11344
|
/* @__PURE__ */ new D(1, 1, 1),
|
|
@@ -11446,7 +11446,7 @@ class Cc {
|
|
|
11446
11446
|
}
|
|
11447
11447
|
_sceneToCubeUV(e, t, i, r) {
|
|
11448
11448
|
const a = new Vt(90, 1, t, i), l = [1, -1, 1, 1, 1, 1], c = [1, 1, 1, -1, -1, -1], u = this._renderer, h = u.autoClear, f = u.toneMapping;
|
|
11449
|
-
u.getClearColor(
|
|
11449
|
+
u.getClearColor(wc), u.toneMapping = Xn, u.autoClear = !1;
|
|
11450
11450
|
const d = new Ia({
|
|
11451
11451
|
name: "PMREM.Background",
|
|
11452
11452
|
side: Ot,
|
|
@@ -11455,7 +11455,7 @@ class Cc {
|
|
|
11455
11455
|
}), g = new pn(new Ir(), d);
|
|
11456
11456
|
let _ = !1;
|
|
11457
11457
|
const m = e.background;
|
|
11458
|
-
m ? m.isColor && (d.color.copy(m), e.background = null, _ = !0) : (d.color.copy(
|
|
11458
|
+
m ? m.isColor && (d.color.copy(m), e.background = null, _ = !0) : (d.color.copy(wc), _ = !0);
|
|
11459
11459
|
for (let p = 0; p < 6; p++) {
|
|
11460
11460
|
const S = p % 3;
|
|
11461
11461
|
S === 0 ? (a.up.set(0, l[p], 0), a.lookAt(c[p], 0, 0)) : S === 1 ? (a.up.set(0, 0, l[p]), a.lookAt(0, c[p], 0)) : (a.up.set(0, l[p], 0), a.lookAt(0, 0, c[p]));
|
|
@@ -11517,12 +11517,12 @@ class Cc {
|
|
|
11517
11517
|
m > ri && console.warn(`sigmaRadians, ${s}, is too large and will clip, as it requested ${m} samples when the maximum is set to ${ri}`);
|
|
11518
11518
|
const p = [];
|
|
11519
11519
|
let S = 0;
|
|
11520
|
-
for (let
|
|
11521
|
-
const N =
|
|
11522
|
-
p.push(x),
|
|
11520
|
+
for (let w = 0; w < ri; ++w) {
|
|
11521
|
+
const N = w / _, x = Math.exp(-N * N / 2);
|
|
11522
|
+
p.push(x), w === 0 ? S += x : w < m && (S += 2 * x);
|
|
11523
11523
|
}
|
|
11524
|
-
for (let
|
|
11525
|
-
p[
|
|
11524
|
+
for (let w = 0; w < p.length; w++)
|
|
11525
|
+
p[w] = p[w] / S;
|
|
11526
11526
|
f.envMap.value = e.texture, f.samples.value = m, f.weights.value = p, f.latitudinal.value = o === "latitudinal", a && (f.poleAxis.value = a);
|
|
11527
11527
|
const { _lodMax: v } = this;
|
|
11528
11528
|
f.dTheta.value = g, f.mipInt.value = v - i;
|
|
@@ -11533,31 +11533,31 @@ class Cc {
|
|
|
11533
11533
|
function Qv(n) {
|
|
11534
11534
|
const e = [], t = [], i = [];
|
|
11535
11535
|
let r = n;
|
|
11536
|
-
const s = n - Oi + 1 +
|
|
11536
|
+
const s = n - Oi + 1 + Tc.length;
|
|
11537
11537
|
for (let o = 0; o < s; o++) {
|
|
11538
11538
|
const a = Math.pow(2, r);
|
|
11539
11539
|
t.push(a);
|
|
11540
11540
|
let l = 1 / a;
|
|
11541
|
-
o > n - Oi ? l =
|
|
11541
|
+
o > n - Oi ? l = Tc[o - n + Oi - 1] : o === 0 && (l = 0), i.push(l);
|
|
11542
11542
|
const c = 1 / (a - 2), u = -c, h = 1 + c, f = [u, u, h, u, h, h, u, u, h, h, u, h], d = 6, g = 6, _ = 3, m = 2, p = 1, S = new Float32Array(_ * g * d), v = new Float32Array(m * g * d), M = new Float32Array(p * g * d);
|
|
11543
11543
|
for (let R = 0; R < d; R++) {
|
|
11544
|
-
const
|
|
11545
|
-
|
|
11544
|
+
const w = R % 3 * 2 / 3 - 1, N = R > 2 ? 0 : -1, x = [
|
|
11545
|
+
w,
|
|
11546
11546
|
N,
|
|
11547
11547
|
0,
|
|
11548
|
-
|
|
11548
|
+
w + 2 / 3,
|
|
11549
11549
|
N,
|
|
11550
11550
|
0,
|
|
11551
|
-
|
|
11551
|
+
w + 2 / 3,
|
|
11552
11552
|
N + 1,
|
|
11553
11553
|
0,
|
|
11554
|
-
|
|
11554
|
+
w,
|
|
11555
11555
|
N,
|
|
11556
11556
|
0,
|
|
11557
|
-
|
|
11557
|
+
w + 2 / 3,
|
|
11558
11558
|
N + 1,
|
|
11559
11559
|
0,
|
|
11560
|
-
|
|
11560
|
+
w,
|
|
11561
11561
|
N + 1,
|
|
11562
11562
|
0
|
|
11563
11563
|
];
|
|
@@ -11916,15 +11916,15 @@ function i0(n, e, t, i) {
|
|
|
11916
11916
|
const S = d.array;
|
|
11917
11917
|
_ = d.version;
|
|
11918
11918
|
for (let v = 0, M = S.length; v < M; v += 3) {
|
|
11919
|
-
const b = S[v + 0], R = S[v + 1],
|
|
11920
|
-
f.push(b, R, R,
|
|
11919
|
+
const b = S[v + 0], R = S[v + 1], w = S[v + 2];
|
|
11920
|
+
f.push(b, R, R, w, w, b);
|
|
11921
11921
|
}
|
|
11922
11922
|
} else if (g !== void 0) {
|
|
11923
11923
|
const S = g.array;
|
|
11924
11924
|
_ = g.version;
|
|
11925
11925
|
for (let v = 0, M = S.length / 3 - 1; v < M; v += 3) {
|
|
11926
|
-
const b = v + 0, R = v + 1,
|
|
11927
|
-
f.push(b, R, R,
|
|
11926
|
+
const b = v + 0, R = v + 1, w = v + 2;
|
|
11927
|
+
f.push(b, R, R, w, w, b);
|
|
11928
11928
|
}
|
|
11929
11929
|
} else
|
|
11930
11930
|
return;
|
|
@@ -12040,7 +12040,7 @@ function l0(n, e, t) {
|
|
|
12040
12040
|
ee.dispose(), s.delete(u), u.removeEventListener("dispose", U);
|
|
12041
12041
|
};
|
|
12042
12042
|
_ !== void 0 && _.texture.dispose();
|
|
12043
|
-
const S = u.morphAttributes.position !== void 0, v = u.morphAttributes.normal !== void 0, M = u.morphAttributes.color !== void 0, b = u.morphAttributes.position || [], R = u.morphAttributes.normal || [],
|
|
12043
|
+
const S = u.morphAttributes.position !== void 0, v = u.morphAttributes.normal !== void 0, M = u.morphAttributes.color !== void 0, b = u.morphAttributes.position || [], R = u.morphAttributes.normal || [], w = u.morphAttributes.color || [];
|
|
12044
12044
|
let N = 0;
|
|
12045
12045
|
S === !0 && (N = 1), v === !0 && (N = 2), M === !0 && (N = 3);
|
|
12046
12046
|
let x = u.attributes.position.count * N, E = 1;
|
|
@@ -12049,7 +12049,7 @@ function l0(n, e, t) {
|
|
|
12049
12049
|
ee.type = Gn, ee.needsUpdate = !0;
|
|
12050
12050
|
const O = N * 4;
|
|
12051
12051
|
for (let C = 0; C < g; C++) {
|
|
12052
|
-
const z = b[C], H = R[C], V =
|
|
12052
|
+
const z = b[C], H = R[C], V = w[C], K = x * E * 4 * C;
|
|
12053
12053
|
for (let Q = 0; Q < z.count; Q++) {
|
|
12054
12054
|
const B = Q * O;
|
|
12055
12055
|
S === !0 && (o.fromBufferAttribute(z, Q), F[K + B + 0] = o.x, F[K + B + 1] = o.y, F[K + B + 2] = o.z, F[K + B + 3] = 0), v === !0 && (o.fromBufferAttribute(H, Q), F[K + B + 4] = o.x, F[K + B + 5] = o.y, F[K + B + 6] = o.z, F[K + B + 7] = 0), M === !0 && (o.fromBufferAttribute(V, Q), F[K + B + 8] = o.x, F[K + B + 9] = o.y, F[K + B + 10] = o.z, F[K + B + 11] = V.itemSize === 4 ? o.w : 1);
|
|
@@ -12119,7 +12119,7 @@ function c0(n, e, t, i) {
|
|
|
12119
12119
|
dispose: o
|
|
12120
12120
|
};
|
|
12121
12121
|
}
|
|
12122
|
-
const
|
|
12122
|
+
const wh = /* @__PURE__ */ new It(), Ah = /* @__PURE__ */ new vh(), Ch = /* @__PURE__ */ new Ym(), Rh = /* @__PURE__ */ new bh(), Dc = [], Ic = [], Uc = new Float32Array(16), Nc = new Float32Array(9), Oc = new Float32Array(4);
|
|
12123
12123
|
function Ji(n, e, t) {
|
|
12124
12124
|
const i = n[0];
|
|
12125
12125
|
if (i <= 0 || i > 0)
|
|
@@ -12292,11 +12292,11 @@ function b0(n, e) {
|
|
|
12292
12292
|
n.uniform4uiv(this.addr, e), yt(t, e);
|
|
12293
12293
|
}
|
|
12294
12294
|
}
|
|
12295
|
-
function
|
|
12295
|
+
function T0(n, e, t) {
|
|
12296
12296
|
const i = this.cache, r = t.allocateTextureUnit();
|
|
12297
|
-
i[0] !== r && (n.uniform1i(this.addr, r), i[0] = r), t.setTexture2D(e ||
|
|
12297
|
+
i[0] !== r && (n.uniform1i(this.addr, r), i[0] = r), t.setTexture2D(e || wh, r);
|
|
12298
12298
|
}
|
|
12299
|
-
function
|
|
12299
|
+
function w0(n, e, t) {
|
|
12300
12300
|
const i = this.cache, r = t.allocateTextureUnit();
|
|
12301
12301
|
i[0] !== r && (n.uniform1i(this.addr, r), i[0] = r), t.setTexture3D(e || Ch, r);
|
|
12302
12302
|
}
|
|
@@ -12349,11 +12349,11 @@ function R0(n) {
|
|
|
12349
12349
|
case 36298:
|
|
12350
12350
|
case 36306:
|
|
12351
12351
|
case 35682:
|
|
12352
|
-
return
|
|
12352
|
+
return T0;
|
|
12353
12353
|
case 35679:
|
|
12354
12354
|
case 36299:
|
|
12355
12355
|
case 36307:
|
|
12356
|
-
return
|
|
12356
|
+
return w0;
|
|
12357
12357
|
case 35680:
|
|
12358
12358
|
case 36300:
|
|
12359
12359
|
case 36308:
|
|
@@ -12421,7 +12421,7 @@ function X0(n, e, t) {
|
|
|
12421
12421
|
const i = this.cache, r = e.length, s = Xs(t, r);
|
|
12422
12422
|
xt(i, s) || (n.uniform1iv(this.addr, s), yt(i, s));
|
|
12423
12423
|
for (let o = 0; o !== r; ++o)
|
|
12424
|
-
t.setTexture2D(e[o] ||
|
|
12424
|
+
t.setTexture2D(e[o] || wh, s[o]);
|
|
12425
12425
|
}
|
|
12426
12426
|
function $0(n, e, t) {
|
|
12427
12427
|
const i = this.cache, r = e.length, s = Xs(t, r);
|
|
@@ -13073,9 +13073,9 @@ Program Info Log: ` + x + `
|
|
|
13073
13073
|
});
|
|
13074
13074
|
}
|
|
13075
13075
|
r.deleteShader(b), r.deleteShader(R);
|
|
13076
|
-
let
|
|
13076
|
+
let w;
|
|
13077
13077
|
this.getUniforms = function() {
|
|
13078
|
-
return
|
|
13078
|
+
return w === void 0 && (w = new Ss(r, _)), w;
|
|
13079
13079
|
};
|
|
13080
13080
|
let N;
|
|
13081
13081
|
return this.getAttributes = function() {
|
|
@@ -13159,9 +13159,9 @@ function Mx(n, e, t, i, r, s, o) {
|
|
|
13159
13159
|
oe = et.vertexShader, me = et.fragmentShader;
|
|
13160
13160
|
} else
|
|
13161
13161
|
oe = x.vertexShader, me = x.fragmentShader, l.update(x), ge = l.getVertexShaderID(x), Ae = l.getFragmentShaderID(x);
|
|
13162
|
-
const
|
|
13162
|
+
const we = n.getRenderTarget(), Te = O.isInstancedMesh === !0, Ve = !!x.map, Ze = !!x.matcap, Ce = !!H, P = !!x.aoMap, he = !!x.lightMap, J = !!x.bumpMap, ae = !!x.normalMap, ne = !!x.displacementMap, be = !!x.emissiveMap, ye = !!x.metalnessMap, Se = !!x.roughnessMap, Pe = x.anisotropy > 0, ze = x.clearcoat > 0, tt = x.iridescence > 0, A = x.sheen > 0, y = x.transmission > 0, W = Pe && !!x.anisotropyMap, se = ze && !!x.clearcoatMap, ie = ze && !!x.clearcoatNormalMap, le = ze && !!x.clearcoatRoughnessMap, Ee = tt && !!x.iridescenceMap, ce = tt && !!x.iridescenceThicknessMap, X = A && !!x.sheenColorMap, L = A && !!x.sheenRoughnessMap, te = !!x.specularMap, xe = !!x.specularColorMap, pe = !!x.specularIntensityMap, ve = y && !!x.transmissionMap, Ne = y && !!x.thicknessMap, We = !!x.gradientMap, I = !!x.alphaMap, _e = x.alphaTest > 0, $ = !!x.alphaHash, re = !!x.extensions, fe = !!C.attributes.uv1, He = !!C.attributes.uv2, qe = !!C.attributes.uv3;
|
|
13163
13163
|
let Je = Xn;
|
|
13164
|
-
return x.toneMapped && (
|
|
13164
|
+
return x.toneMapped && (we === null || we.isXRRenderTarget === !0) && (Je = n.toneMapping), {
|
|
13165
13165
|
isWebGL2: u,
|
|
13166
13166
|
shaderID: K,
|
|
13167
13167
|
shaderType: x.type,
|
|
@@ -13174,10 +13174,10 @@ function Mx(n, e, t, i, r, s, o) {
|
|
|
13174
13174
|
isRawShaderMaterial: x.isRawShaderMaterial === !0,
|
|
13175
13175
|
glslVersion: x.glslVersion,
|
|
13176
13176
|
precision: d,
|
|
13177
|
-
instancing:
|
|
13178
|
-
instancingColor:
|
|
13177
|
+
instancing: Te,
|
|
13178
|
+
instancingColor: Te && O.instanceColor !== null,
|
|
13179
13179
|
supportsVertexTextures: f,
|
|
13180
|
-
outputColorSpace:
|
|
13180
|
+
outputColorSpace: we === null ? n.outputColorSpace : we.isXRRenderTarget === !0 ? we.texture.colorSpace : gn,
|
|
13181
13181
|
map: Ve,
|
|
13182
13182
|
matcap: Ze,
|
|
13183
13183
|
envMap: Ce,
|
|
@@ -13335,7 +13335,7 @@ function Mx(n, e, t, i, r, s, o) {
|
|
|
13335
13335
|
c[E] = c[c.length - 1], c.pop(), x.destroy();
|
|
13336
13336
|
}
|
|
13337
13337
|
}
|
|
13338
|
-
function
|
|
13338
|
+
function w(x) {
|
|
13339
13339
|
l.remove(x);
|
|
13340
13340
|
}
|
|
13341
13341
|
function N() {
|
|
@@ -13347,7 +13347,7 @@ function Mx(n, e, t, i, r, s, o) {
|
|
|
13347
13347
|
getUniforms: M,
|
|
13348
13348
|
acquireProgram: b,
|
|
13349
13349
|
releaseProgram: R,
|
|
13350
|
-
releaseShaderCache:
|
|
13350
|
+
releaseShaderCache: w,
|
|
13351
13351
|
// Exposed for resource monitoring & error feedback via renderer.info:
|
|
13352
13352
|
programs: c,
|
|
13353
13353
|
dispose: N
|
|
@@ -13431,7 +13431,7 @@ function Xc() {
|
|
|
13431
13431
|
sort: c
|
|
13432
13432
|
};
|
|
13433
13433
|
}
|
|
13434
|
-
function
|
|
13434
|
+
function Tx() {
|
|
13435
13435
|
let n = /* @__PURE__ */ new WeakMap();
|
|
13436
13436
|
function e(i, r) {
|
|
13437
13437
|
const s = n.get(i);
|
|
@@ -13446,7 +13446,7 @@ function wx() {
|
|
|
13446
13446
|
dispose: t
|
|
13447
13447
|
};
|
|
13448
13448
|
}
|
|
13449
|
-
function
|
|
13449
|
+
function wx() {
|
|
13450
13450
|
const n = {};
|
|
13451
13451
|
return {
|
|
13452
13452
|
get: function(e) {
|
|
@@ -13543,7 +13543,7 @@ function Rx(n, e) {
|
|
|
13543
13543
|
return (e.castShadow ? 2 : 0) - (n.castShadow ? 2 : 0) + (e.map ? 1 : 0) - (n.map ? 1 : 0);
|
|
13544
13544
|
}
|
|
13545
13545
|
function Px(n, e) {
|
|
13546
|
-
const t = new
|
|
13546
|
+
const t = new wx(), i = Ax(), r = {
|
|
13547
13547
|
version: 0,
|
|
13548
13548
|
hash: {
|
|
13549
13549
|
directionalLength: -1,
|
|
@@ -13584,7 +13584,7 @@ function Px(n, e) {
|
|
|
13584
13584
|
let f = 0, d = 0, g = 0;
|
|
13585
13585
|
for (let F = 0; F < 9; F++)
|
|
13586
13586
|
r.probe[F].set(0, 0, 0);
|
|
13587
|
-
let _ = 0, m = 0, p = 0, S = 0, v = 0, M = 0, b = 0, R = 0,
|
|
13587
|
+
let _ = 0, m = 0, p = 0, S = 0, v = 0, M = 0, b = 0, R = 0, w = 0, N = 0;
|
|
13588
13588
|
u.sort(Rx);
|
|
13589
13589
|
const x = h === !0 ? Math.PI : 1;
|
|
13590
13590
|
for (let F = 0, ee = u.length; F < ee; F++) {
|
|
@@ -13605,7 +13605,7 @@ function Px(n, e) {
|
|
|
13605
13605
|
const V = t.get(O);
|
|
13606
13606
|
V.position.setFromMatrixPosition(O.matrixWorld), V.color.copy(U).multiplyScalar(C * x), V.distance = z, V.coneCos = Math.cos(O.angle), V.penumbraCos = Math.cos(O.angle * (1 - O.penumbra)), V.decay = O.decay, r.spot[p] = V;
|
|
13607
13607
|
const K = O.shadow;
|
|
13608
|
-
if (O.map && (r.spotLightMap[
|
|
13608
|
+
if (O.map && (r.spotLightMap[w] = O.map, w++, K.updateMatrices(O), O.castShadow && N++), r.spotLightMatrix[p] = K.matrix, O.castShadow) {
|
|
13609
13609
|
const Q = i.get(O);
|
|
13610
13610
|
Q.shadowBias = K.bias, Q.shadowNormalBias = K.normalBias, Q.shadowRadius = K.radius, Q.shadowMapSize = K.mapSize, r.spotShadow[p] = Q, r.spotShadowMap[p] = H, R++;
|
|
13611
13611
|
}
|
|
@@ -13627,7 +13627,7 @@ function Px(n, e) {
|
|
|
13627
13627
|
}
|
|
13628
13628
|
S > 0 && (e.isWebGL2 || n.has("OES_texture_float_linear") === !0 ? (r.rectAreaLTC1 = de.LTC_FLOAT_1, r.rectAreaLTC2 = de.LTC_FLOAT_2) : n.has("OES_texture_half_float_linear") === !0 ? (r.rectAreaLTC1 = de.LTC_HALF_1, r.rectAreaLTC2 = de.LTC_HALF_2) : console.error("THREE.WebGLRenderer: Unable to use RectAreaLight. Missing WebGL extensions.")), r.ambient[0] = f, r.ambient[1] = d, r.ambient[2] = g;
|
|
13629
13629
|
const E = r.hash;
|
|
13630
|
-
(E.directionalLength !== _ || E.pointLength !== m || E.spotLength !== p || E.rectAreaLength !== S || E.hemiLength !== v || E.numDirectionalShadows !== M || E.numPointShadows !== b || E.numSpotShadows !== R || E.numSpotMaps !==
|
|
13630
|
+
(E.directionalLength !== _ || E.pointLength !== m || E.spotLength !== p || E.rectAreaLength !== S || E.hemiLength !== v || E.numDirectionalShadows !== M || E.numPointShadows !== b || E.numSpotShadows !== R || E.numSpotMaps !== w) && (r.directional.length = _, r.spot.length = p, r.rectArea.length = S, r.point.length = m, r.hemi.length = v, r.directionalShadow.length = M, r.directionalShadowMap.length = M, r.pointShadow.length = b, r.pointShadowMap.length = b, r.spotShadow.length = R, r.spotShadowMap.length = R, r.directionalShadowMatrix.length = M, r.pointShadowMatrix.length = b, r.spotLightMatrix.length = R + w - N, r.spotLightMap.length = w, r.numSpotLightShadowsWithMaps = N, E.directionalLength = _, E.pointLength = m, E.spotLength = p, E.rectAreaLength = S, E.hemiLength = v, E.numDirectionalShadows = M, E.numPointShadows = b, E.numSpotShadows = R, E.numSpotMaps = w, r.version = Cx++);
|
|
13631
13631
|
}
|
|
13632
13632
|
function c(u, h) {
|
|
13633
13633
|
let f = 0, d = 0, g = 0, _ = 0, m = 0;
|
|
@@ -13774,7 +13774,7 @@ function Ox(n, e, t) {
|
|
|
13774
13774
|
const _ = new pn(g, f), m = this;
|
|
13775
13775
|
this.enabled = !1, this.autoUpdate = !0, this.needsUpdate = !1, this.type = nh;
|
|
13776
13776
|
let p = this.type;
|
|
13777
|
-
this.render = function(b, R,
|
|
13777
|
+
this.render = function(b, R, w) {
|
|
13778
13778
|
if (m.enabled === !1 || m.autoUpdate === !1 && m.needsUpdate === !1 || b.length === 0)
|
|
13779
13779
|
return;
|
|
13780
13780
|
const N = n.getRenderTarget(), x = n.getActiveCubeFace(), E = n.getActiveMipmapLevel(), F = n.state;
|
|
@@ -13803,39 +13803,39 @@ function Ox(n, e, t) {
|
|
|
13803
13803
|
s.y * B.y,
|
|
13804
13804
|
s.x * B.z,
|
|
13805
13805
|
s.y * B.w
|
|
13806
|
-
), F.viewport(o), H.updateMatrices(z, Q), i = H.getFrustum(), M(R,
|
|
13806
|
+
), F.viewport(o), H.updateMatrices(z, Q), i = H.getFrustum(), M(R, w, H.camera, z, this.type);
|
|
13807
13807
|
}
|
|
13808
|
-
H.isPointLightShadow !== !0 && this.type === An && S(H,
|
|
13808
|
+
H.isPointLightShadow !== !0 && this.type === An && S(H, w), H.needsUpdate = !1;
|
|
13809
13809
|
}
|
|
13810
13810
|
p = this.type, m.needsUpdate = !1, n.setRenderTarget(N, x, E);
|
|
13811
13811
|
};
|
|
13812
13812
|
function S(b, R) {
|
|
13813
|
-
const
|
|
13814
|
-
f.defines.VSM_SAMPLES !== b.blurSamples && (f.defines.VSM_SAMPLES = b.blurSamples, d.defines.VSM_SAMPLES = b.blurSamples, f.needsUpdate = !0, d.needsUpdate = !0), b.mapPass === null && (b.mapPass = new di(r.x, r.y)), f.uniforms.shadow_pass.value = b.map.texture, f.uniforms.resolution.value = b.mapSize, f.uniforms.radius.value = b.radius, n.setRenderTarget(b.mapPass), n.clear(), n.renderBufferDirect(R, null,
|
|
13813
|
+
const w = e.update(_);
|
|
13814
|
+
f.defines.VSM_SAMPLES !== b.blurSamples && (f.defines.VSM_SAMPLES = b.blurSamples, d.defines.VSM_SAMPLES = b.blurSamples, f.needsUpdate = !0, d.needsUpdate = !0), b.mapPass === null && (b.mapPass = new di(r.x, r.y)), f.uniforms.shadow_pass.value = b.map.texture, f.uniforms.resolution.value = b.mapSize, f.uniforms.radius.value = b.radius, n.setRenderTarget(b.mapPass), n.clear(), n.renderBufferDirect(R, null, w, f, _, null), d.uniforms.shadow_pass.value = b.mapPass.texture, d.uniforms.resolution.value = b.mapSize, d.uniforms.radius.value = b.radius, n.setRenderTarget(b.map), n.clear(), n.renderBufferDirect(R, null, w, d, _, null);
|
|
13815
13815
|
}
|
|
13816
|
-
function v(b, R,
|
|
13816
|
+
function v(b, R, w, N) {
|
|
13817
13817
|
let x = null;
|
|
13818
|
-
const E =
|
|
13818
|
+
const E = w.isPointLight === !0 ? b.customDistanceMaterial : b.customDepthMaterial;
|
|
13819
13819
|
if (E !== void 0)
|
|
13820
13820
|
x = E;
|
|
13821
|
-
else if (x =
|
|
13821
|
+
else if (x = w.isPointLight === !0 ? l : a, n.localClippingEnabled && R.clipShadows === !0 && Array.isArray(R.clippingPlanes) && R.clippingPlanes.length !== 0 || R.displacementMap && R.displacementScale !== 0 || R.alphaMap && R.alphaTest > 0 || R.map && R.alphaTest > 0) {
|
|
13822
13822
|
const F = x.uuid, ee = R.uuid;
|
|
13823
13823
|
let O = c[F];
|
|
13824
13824
|
O === void 0 && (O = {}, c[F] = O);
|
|
13825
13825
|
let U = O[ee];
|
|
13826
13826
|
U === void 0 && (U = x.clone(), O[ee] = U), x = U;
|
|
13827
13827
|
}
|
|
13828
|
-
if (x.visible = R.visible, x.wireframe = R.wireframe, N === An ? x.side = R.shadowSide !== null ? R.shadowSide : R.side : x.side = R.shadowSide !== null ? R.shadowSide : h[R.side], x.alphaMap = R.alphaMap, x.alphaTest = R.alphaTest, x.map = R.map, x.clipShadows = R.clipShadows, x.clippingPlanes = R.clippingPlanes, x.clipIntersection = R.clipIntersection, x.displacementMap = R.displacementMap, x.displacementScale = R.displacementScale, x.displacementBias = R.displacementBias, x.wireframeLinewidth = R.wireframeLinewidth, x.linewidth = R.linewidth,
|
|
13828
|
+
if (x.visible = R.visible, x.wireframe = R.wireframe, N === An ? x.side = R.shadowSide !== null ? R.shadowSide : R.side : x.side = R.shadowSide !== null ? R.shadowSide : h[R.side], x.alphaMap = R.alphaMap, x.alphaTest = R.alphaTest, x.map = R.map, x.clipShadows = R.clipShadows, x.clippingPlanes = R.clippingPlanes, x.clipIntersection = R.clipIntersection, x.displacementMap = R.displacementMap, x.displacementScale = R.displacementScale, x.displacementBias = R.displacementBias, x.wireframeLinewidth = R.wireframeLinewidth, x.linewidth = R.linewidth, w.isPointLight === !0 && x.isMeshDistanceMaterial === !0) {
|
|
13829
13829
|
const F = n.properties.get(x);
|
|
13830
|
-
F.light =
|
|
13830
|
+
F.light = w;
|
|
13831
13831
|
}
|
|
13832
13832
|
return x;
|
|
13833
13833
|
}
|
|
13834
|
-
function M(b, R,
|
|
13834
|
+
function M(b, R, w, N, x) {
|
|
13835
13835
|
if (b.visible === !1)
|
|
13836
13836
|
return;
|
|
13837
13837
|
if (b.layers.test(R.layers) && (b.isMesh || b.isLine || b.isPoints) && (b.castShadow || b.receiveShadow && x === An) && (!b.frustumCulled || i.intersectsObject(b))) {
|
|
13838
|
-
b.modelViewMatrix.multiplyMatrices(
|
|
13838
|
+
b.modelViewMatrix.multiplyMatrices(w.matrixWorldInverse, b.matrixWorld);
|
|
13839
13839
|
const ee = e.update(b), O = b.material;
|
|
13840
13840
|
if (Array.isArray(O)) {
|
|
13841
13841
|
const U = ee.groups;
|
|
@@ -13843,17 +13843,17 @@ function Ox(n, e, t) {
|
|
|
13843
13843
|
const H = U[C], V = O[H.materialIndex];
|
|
13844
13844
|
if (V && V.visible) {
|
|
13845
13845
|
const K = v(b, V, N, x);
|
|
13846
|
-
n.renderBufferDirect(
|
|
13846
|
+
n.renderBufferDirect(w, null, ee, K, b, H);
|
|
13847
13847
|
}
|
|
13848
13848
|
}
|
|
13849
13849
|
} else if (O.visible) {
|
|
13850
13850
|
const U = v(b, O, N, x);
|
|
13851
|
-
n.renderBufferDirect(
|
|
13851
|
+
n.renderBufferDirect(w, null, ee, U, b, null);
|
|
13852
13852
|
}
|
|
13853
13853
|
}
|
|
13854
13854
|
const F = b.children;
|
|
13855
13855
|
for (let ee = 0, O = F.length; ee < O; ee++)
|
|
13856
|
-
M(F[ee], R,
|
|
13856
|
+
M(F[ee], R, w, N, x);
|
|
13857
13857
|
}
|
|
13858
13858
|
}
|
|
13859
13859
|
function Fx(n, e, t) {
|
|
@@ -13882,7 +13882,7 @@ function Fx(n, e, t) {
|
|
|
13882
13882
|
let I = !1, _e = null, $ = null, re = null;
|
|
13883
13883
|
return {
|
|
13884
13884
|
setTest: function(fe) {
|
|
13885
|
-
fe ?
|
|
13885
|
+
fe ? we(n.DEPTH_TEST) : Te(n.DEPTH_TEST);
|
|
13886
13886
|
},
|
|
13887
13887
|
setMask: function(fe) {
|
|
13888
13888
|
_e !== fe && !I && (n.depthMask(fe), _e = fe);
|
|
@@ -13935,7 +13935,7 @@ function Fx(n, e, t) {
|
|
|
13935
13935
|
let I = !1, _e = null, $ = null, re = null, fe = null, He = null, qe = null, Je = null, Ft = null;
|
|
13936
13936
|
return {
|
|
13937
13937
|
setTest: function(et) {
|
|
13938
|
-
I || (et ?
|
|
13938
|
+
I || (et ? we(n.STENCIL_TEST) : Te(n.STENCIL_TEST));
|
|
13939
13939
|
},
|
|
13940
13940
|
setMask: function(et) {
|
|
13941
13941
|
_e !== et && !I && (n.stencilMask(et), _e = et);
|
|
@@ -13958,7 +13958,7 @@ function Fx(n, e, t) {
|
|
|
13958
13958
|
};
|
|
13959
13959
|
}
|
|
13960
13960
|
const a = new r(), l = new s(), c = new o(), u = /* @__PURE__ */ new WeakMap(), h = /* @__PURE__ */ new WeakMap();
|
|
13961
|
-
let f = {}, d = {}, g = /* @__PURE__ */ new WeakMap(), _ = [], m = null, p = !1, S = null, v = null, M = null, b = null, R = null,
|
|
13961
|
+
let f = {}, d = {}, g = /* @__PURE__ */ new WeakMap(), _ = [], m = null, p = !1, S = null, v = null, M = null, b = null, R = null, w = null, N = null, x = !1, E = null, F = null, ee = null, O = null, U = null;
|
|
13962
13962
|
const C = n.getParameter(n.MAX_COMBINED_TEXTURE_IMAGE_UNITS);
|
|
13963
13963
|
let z = !1, H = 0;
|
|
13964
13964
|
const V = n.getParameter(n.VERSION);
|
|
@@ -13973,11 +13973,11 @@ function Fx(n, e, t) {
|
|
|
13973
13973
|
return He;
|
|
13974
13974
|
}
|
|
13975
13975
|
const Ae = {};
|
|
13976
|
-
Ae[n.TEXTURE_2D] = ge(n.TEXTURE_2D, n.TEXTURE_2D, 1), Ae[n.TEXTURE_CUBE_MAP] = ge(n.TEXTURE_CUBE_MAP, n.TEXTURE_CUBE_MAP_POSITIVE_X, 6), i && (Ae[n.TEXTURE_2D_ARRAY] = ge(n.TEXTURE_2D_ARRAY, n.TEXTURE_2D_ARRAY, 1, 1), Ae[n.TEXTURE_3D] = ge(n.TEXTURE_3D, n.TEXTURE_3D, 1, 1)), a.setClear(0, 0, 0, 1), l.setClear(1), c.setClear(0),
|
|
13977
|
-
function
|
|
13976
|
+
Ae[n.TEXTURE_2D] = ge(n.TEXTURE_2D, n.TEXTURE_2D, 1), Ae[n.TEXTURE_CUBE_MAP] = ge(n.TEXTURE_CUBE_MAP, n.TEXTURE_CUBE_MAP_POSITIVE_X, 6), i && (Ae[n.TEXTURE_2D_ARRAY] = ge(n.TEXTURE_2D_ARRAY, n.TEXTURE_2D_ARRAY, 1, 1), Ae[n.TEXTURE_3D] = ge(n.TEXTURE_3D, n.TEXTURE_3D, 1, 1)), a.setClear(0, 0, 0, 1), l.setClear(1), c.setClear(0), we(n.DEPTH_TEST), l.setFunc(ea), ne(!1), be(Ll), we(n.CULL_FACE), J(Wn);
|
|
13977
|
+
function we(I) {
|
|
13978
13978
|
f[I] !== !0 && (n.enable(I), f[I] = !0);
|
|
13979
13979
|
}
|
|
13980
|
-
function
|
|
13980
|
+
function Te(I) {
|
|
13981
13981
|
f[I] !== !1 && (n.disable(I), f[I] = !1);
|
|
13982
13982
|
}
|
|
13983
13983
|
function Ve(I, _e) {
|
|
@@ -14028,10 +14028,10 @@ function Fx(n, e, t) {
|
|
|
14028
14028
|
};
|
|
14029
14029
|
function J(I, _e, $, re, fe, He, qe, Je) {
|
|
14030
14030
|
if (I === Wn) {
|
|
14031
|
-
p === !0 && (
|
|
14031
|
+
p === !0 && (Te(n.BLEND), p = !1);
|
|
14032
14032
|
return;
|
|
14033
14033
|
}
|
|
14034
|
-
if (p === !1 && (
|
|
14034
|
+
if (p === !1 && (we(n.BLEND), p = !0), I !== Lp) {
|
|
14035
14035
|
if (I !== S || Je !== x) {
|
|
14036
14036
|
if ((v !== Ni || R !== Ni) && (n.blendEquation(n.FUNC_ADD), v = Ni, R = Ni), Je)
|
|
14037
14037
|
switch (I) {
|
|
@@ -14069,33 +14069,33 @@ function Fx(n, e, t) {
|
|
|
14069
14069
|
console.error("THREE.WebGLState: Invalid blending: ", I);
|
|
14070
14070
|
break;
|
|
14071
14071
|
}
|
|
14072
|
-
M = null, b = null,
|
|
14072
|
+
M = null, b = null, w = null, N = null, S = I, x = Je;
|
|
14073
14073
|
}
|
|
14074
14074
|
return;
|
|
14075
14075
|
}
|
|
14076
|
-
fe = fe || _e, He = He || $, qe = qe || re, (_e !== v || fe !== R) && (n.blendEquationSeparate(P[_e], P[fe]), v = _e, R = fe), ($ !== M || re !== b || He !==
|
|
14076
|
+
fe = fe || _e, He = He || $, qe = qe || re, (_e !== v || fe !== R) && (n.blendEquationSeparate(P[_e], P[fe]), v = _e, R = fe), ($ !== M || re !== b || He !== w || qe !== N) && (n.blendFuncSeparate(he[$], he[re], he[He], he[qe]), M = $, b = re, w = He, N = qe), S = I, x = !1;
|
|
14077
14077
|
}
|
|
14078
14078
|
function ae(I, _e) {
|
|
14079
|
-
I.side === Cn ?
|
|
14079
|
+
I.side === Cn ? Te(n.CULL_FACE) : we(n.CULL_FACE);
|
|
14080
14080
|
let $ = I.side === Ot;
|
|
14081
14081
|
_e && ($ = !$), ne($), I.blending === Hi && I.transparent === !1 ? J(Wn) : J(I.blending, I.blendEquation, I.blendSrc, I.blendDst, I.blendEquationAlpha, I.blendSrcAlpha, I.blendDstAlpha, I.premultipliedAlpha), l.setFunc(I.depthFunc), l.setTest(I.depthTest), l.setMask(I.depthWrite), a.setMask(I.colorWrite);
|
|
14082
14082
|
const re = I.stencilWrite;
|
|
14083
|
-
c.setTest(re), re && (c.setMask(I.stencilWriteMask), c.setFunc(I.stencilFunc, I.stencilRef, I.stencilFuncMask), c.setOp(I.stencilFail, I.stencilZFail, I.stencilZPass)), Se(I.polygonOffset, I.polygonOffsetFactor, I.polygonOffsetUnits), I.alphaToCoverage === !0 ?
|
|
14083
|
+
c.setTest(re), re && (c.setMask(I.stencilWriteMask), c.setFunc(I.stencilFunc, I.stencilRef, I.stencilFuncMask), c.setOp(I.stencilFail, I.stencilZFail, I.stencilZPass)), Se(I.polygonOffset, I.polygonOffsetFactor, I.polygonOffsetUnits), I.alphaToCoverage === !0 ? we(n.SAMPLE_ALPHA_TO_COVERAGE) : Te(n.SAMPLE_ALPHA_TO_COVERAGE);
|
|
14084
14084
|
}
|
|
14085
14085
|
function ne(I) {
|
|
14086
14086
|
E !== I && (I ? n.frontFace(n.CW) : n.frontFace(n.CCW), E = I);
|
|
14087
14087
|
}
|
|
14088
14088
|
function be(I) {
|
|
14089
|
-
I !== Cp ? (
|
|
14089
|
+
I !== Cp ? (we(n.CULL_FACE), I !== F && (I === Ll ? n.cullFace(n.BACK) : I === Rp ? n.cullFace(n.FRONT) : n.cullFace(n.FRONT_AND_BACK))) : Te(n.CULL_FACE), F = I;
|
|
14090
14090
|
}
|
|
14091
14091
|
function ye(I) {
|
|
14092
14092
|
I !== ee && (z && n.lineWidth(I), ee = I);
|
|
14093
14093
|
}
|
|
14094
14094
|
function Se(I, _e, $) {
|
|
14095
|
-
I ? (
|
|
14095
|
+
I ? (we(n.POLYGON_OFFSET_FILL), (O !== _e || U !== $) && (n.polygonOffset(_e, $), O = _e, U = $)) : Te(n.POLYGON_OFFSET_FILL);
|
|
14096
14096
|
}
|
|
14097
14097
|
function Pe(I) {
|
|
14098
|
-
I ?
|
|
14098
|
+
I ? we(n.SCISSOR_TEST) : Te(n.SCISSOR_TEST);
|
|
14099
14099
|
}
|
|
14100
14100
|
function ze(I) {
|
|
14101
14101
|
I === void 0 && (I = n.TEXTURE0 + C - 1), K !== I && (n.activeTexture(I), K = I);
|
|
@@ -14196,7 +14196,7 @@ function Fx(n, e, t) {
|
|
|
14196
14196
|
u.get(_e) !== re && (n.uniformBlockBinding(_e, re, I.__bindingPointIndex), u.set(_e, re));
|
|
14197
14197
|
}
|
|
14198
14198
|
function We() {
|
|
14199
|
-
n.disable(n.BLEND), n.disable(n.CULL_FACE), n.disable(n.DEPTH_TEST), n.disable(n.POLYGON_OFFSET_FILL), n.disable(n.SCISSOR_TEST), n.disable(n.STENCIL_TEST), n.disable(n.SAMPLE_ALPHA_TO_COVERAGE), n.blendEquation(n.FUNC_ADD), n.blendFunc(n.ONE, n.ZERO), n.blendFuncSeparate(n.ONE, n.ZERO, n.ONE, n.ZERO), n.colorMask(!0, !0, !0, !0), n.clearColor(0, 0, 0, 0), n.depthMask(!0), n.depthFunc(n.LESS), n.clearDepth(1), n.stencilMask(4294967295), n.stencilFunc(n.ALWAYS, 0, 4294967295), n.stencilOp(n.KEEP, n.KEEP, n.KEEP), n.clearStencil(0), n.cullFace(n.BACK), n.frontFace(n.CCW), n.polygonOffset(0, 0), n.activeTexture(n.TEXTURE0), n.bindFramebuffer(n.FRAMEBUFFER, null), i === !0 && (n.bindFramebuffer(n.DRAW_FRAMEBUFFER, null), n.bindFramebuffer(n.READ_FRAMEBUFFER, null)), n.useProgram(null), n.lineWidth(1), n.scissor(0, 0, n.canvas.width, n.canvas.height), n.viewport(0, 0, n.canvas.width, n.canvas.height), f = {}, K = null, Q = {}, d = {}, g = /* @__PURE__ */ new WeakMap(), _ = [], m = null, p = !1, S = null, v = null, M = null, b = null, R = null,
|
|
14199
|
+
n.disable(n.BLEND), n.disable(n.CULL_FACE), n.disable(n.DEPTH_TEST), n.disable(n.POLYGON_OFFSET_FILL), n.disable(n.SCISSOR_TEST), n.disable(n.STENCIL_TEST), n.disable(n.SAMPLE_ALPHA_TO_COVERAGE), n.blendEquation(n.FUNC_ADD), n.blendFunc(n.ONE, n.ZERO), n.blendFuncSeparate(n.ONE, n.ZERO, n.ONE, n.ZERO), n.colorMask(!0, !0, !0, !0), n.clearColor(0, 0, 0, 0), n.depthMask(!0), n.depthFunc(n.LESS), n.clearDepth(1), n.stencilMask(4294967295), n.stencilFunc(n.ALWAYS, 0, 4294967295), n.stencilOp(n.KEEP, n.KEEP, n.KEEP), n.clearStencil(0), n.cullFace(n.BACK), n.frontFace(n.CCW), n.polygonOffset(0, 0), n.activeTexture(n.TEXTURE0), n.bindFramebuffer(n.FRAMEBUFFER, null), i === !0 && (n.bindFramebuffer(n.DRAW_FRAMEBUFFER, null), n.bindFramebuffer(n.READ_FRAMEBUFFER, null)), n.useProgram(null), n.lineWidth(1), n.scissor(0, 0, n.canvas.width, n.canvas.height), n.viewport(0, 0, n.canvas.width, n.canvas.height), f = {}, K = null, Q = {}, d = {}, g = /* @__PURE__ */ new WeakMap(), _ = [], m = null, p = !1, S = null, v = null, M = null, b = null, R = null, w = null, N = null, x = !1, E = null, F = null, ee = null, O = null, U = null, oe.set(0, 0, n.canvas.width, n.canvas.height), me.set(0, 0, n.canvas.width, n.canvas.height), a.reset(), l.reset(), c.reset();
|
|
14200
14200
|
}
|
|
14201
14201
|
return {
|
|
14202
14202
|
buffers: {
|
|
@@ -14204,8 +14204,8 @@ function Fx(n, e, t) {
|
|
|
14204
14204
|
depth: l,
|
|
14205
14205
|
stencil: c
|
|
14206
14206
|
},
|
|
14207
|
-
enable:
|
|
14208
|
-
disable:
|
|
14207
|
+
enable: we,
|
|
14208
|
+
disable: Te,
|
|
14209
14209
|
bindFramebuffer: Ve,
|
|
14210
14210
|
drawBuffers: Ze,
|
|
14211
14211
|
useProgram: Ce,
|
|
@@ -14272,7 +14272,7 @@ function Bx(n, e, t, i, r, s, o) {
|
|
|
14272
14272
|
function R(A, y) {
|
|
14273
14273
|
return A.generateMipmaps && y && A.minFilter !== Dt && A.minFilter !== $t;
|
|
14274
14274
|
}
|
|
14275
|
-
function
|
|
14275
|
+
function w(A) {
|
|
14276
14276
|
n.generateMipmap(A);
|
|
14277
14277
|
}
|
|
14278
14278
|
function N(A, y, W, se, ie = !1) {
|
|
@@ -14418,7 +14418,7 @@ function Bx(n, e, t, i, r, s, o) {
|
|
|
14418
14418
|
[Sm]: n.GREATER,
|
|
14419
14419
|
[Mm]: n.NOTEQUAL
|
|
14420
14420
|
};
|
|
14421
|
-
function
|
|
14421
|
+
function we(A, y, W) {
|
|
14422
14422
|
if (W ? (n.texParameteri(A, n.TEXTURE_WRAP_S, me[y.wrapS]), n.texParameteri(A, n.TEXTURE_WRAP_T, me[y.wrapT]), (A === n.TEXTURE_3D || A === n.TEXTURE_2D_ARRAY) && n.texParameteri(A, n.TEXTURE_WRAP_R, me[y.wrapR]), n.texParameteri(A, n.TEXTURE_MAG_FILTER, ge[y.magFilter]), n.texParameteri(A, n.TEXTURE_MIN_FILTER, ge[y.minFilter])) : (n.texParameteri(A, n.TEXTURE_WRAP_S, n.CLAMP_TO_EDGE), n.texParameteri(A, n.TEXTURE_WRAP_T, n.CLAMP_TO_EDGE), (A === n.TEXTURE_3D || A === n.TEXTURE_2D_ARRAY) && n.texParameteri(A, n.TEXTURE_WRAP_R, n.CLAMP_TO_EDGE), (y.wrapS !== nn || y.wrapT !== nn) && console.warn("THREE.WebGLRenderer: Texture is not power of two. Texture.wrapS and Texture.wrapT should be set to THREE.ClampToEdgeWrapping."), n.texParameteri(A, n.TEXTURE_MAG_FILTER, E(y.magFilter)), n.texParameteri(A, n.TEXTURE_MIN_FILTER, E(y.minFilter)), y.minFilter !== Dt && y.minFilter !== $t && console.warn("THREE.WebGLRenderer: Texture is not power of two. Texture.minFilter should be set to THREE.NearestFilter or THREE.LinearFilter.")), y.compareFunction && (n.texParameteri(A, n.TEXTURE_COMPARE_MODE, n.COMPARE_REF_TO_TEXTURE), n.texParameteri(A, n.TEXTURE_COMPARE_FUNC, Ae[y.compareFunction])), e.has("EXT_texture_filter_anisotropic") === !0) {
|
|
14423
14423
|
const se = e.get("EXT_texture_filter_anisotropic");
|
|
14424
14424
|
if (y.magFilter === Dt || y.minFilter !== so && y.minFilter !== yr || y.type === Gn && e.has("OES_texture_float_linear") === !1 || a === !1 && y.type === Sr && e.has("OES_texture_half_float_linear") === !1)
|
|
@@ -14426,7 +14426,7 @@ function Bx(n, e, t, i, r, s, o) {
|
|
|
14426
14426
|
(y.anisotropy > 1 || i.get(y).__currentAnisotropy) && (n.texParameterf(A, se.TEXTURE_MAX_ANISOTROPY_EXT, Math.min(y.anisotropy, r.getMaxAnisotropy())), i.get(y).__currentAnisotropy = y.anisotropy);
|
|
14427
14427
|
}
|
|
14428
14428
|
}
|
|
14429
|
-
function
|
|
14429
|
+
function Te(A, y) {
|
|
14430
14430
|
let W = !1;
|
|
14431
14431
|
A.__webglInit === void 0 && (A.__webglInit = !0, y.addEventListener("dispose", F));
|
|
14432
14432
|
const se = y.source;
|
|
@@ -14446,7 +14446,7 @@ function Bx(n, e, t, i, r, s, o) {
|
|
|
14446
14446
|
function Ve(A, y, W) {
|
|
14447
14447
|
let se = n.TEXTURE_2D;
|
|
14448
14448
|
(y.isDataArrayTexture || y.isCompressedArrayTexture) && (se = n.TEXTURE_2D_ARRAY), y.isData3DTexture && (se = n.TEXTURE_3D);
|
|
14449
|
-
const ie =
|
|
14449
|
+
const ie = Te(A, y), le = y.source;
|
|
14450
14450
|
t.bindTexture(se, A.__webglTexture, n.TEXTURE0 + W);
|
|
14451
14451
|
const Ee = i.get(le);
|
|
14452
14452
|
if (le.version !== Ee.__version || ie === !0) {
|
|
@@ -14456,7 +14456,7 @@ function Bx(n, e, t, i, r, s, o) {
|
|
|
14456
14456
|
X = tt(y, X);
|
|
14457
14457
|
const L = M(X) || a, te = s.convert(y.format, y.colorSpace);
|
|
14458
14458
|
let xe = s.convert(y.type), pe = N(y.internalFormat, te, xe, y.colorSpace, y.isVideoTexture);
|
|
14459
|
-
|
|
14459
|
+
we(se, y, L);
|
|
14460
14460
|
let ve;
|
|
14461
14461
|
const Ne = y.mipmaps, We = a && y.isVideoTexture !== !0, I = Ee.__version === void 0 || ie === !0, _e = x(y, X, L);
|
|
14462
14462
|
if (y.isDepthTexture)
|
|
@@ -14499,14 +14499,14 @@ function Bx(n, e, t, i, r, s, o) {
|
|
|
14499
14499
|
y.generateMipmaps = !1;
|
|
14500
14500
|
} else
|
|
14501
14501
|
We ? (I && t.texStorage2D(n.TEXTURE_2D, _e, pe, X.width, X.height), t.texSubImage2D(n.TEXTURE_2D, 0, 0, 0, te, xe, X)) : t.texImage2D(n.TEXTURE_2D, 0, pe, te, xe, X);
|
|
14502
|
-
R(y, L) &&
|
|
14502
|
+
R(y, L) && w(se), Ee.__version = le.version, y.onUpdate && y.onUpdate(y);
|
|
14503
14503
|
}
|
|
14504
14504
|
A.__version = y.version;
|
|
14505
14505
|
}
|
|
14506
14506
|
function Ze(A, y, W) {
|
|
14507
14507
|
if (y.image.length !== 6)
|
|
14508
14508
|
return;
|
|
14509
|
-
const se =
|
|
14509
|
+
const se = Te(A, y), ie = y.source;
|
|
14510
14510
|
t.bindTexture(n.TEXTURE_CUBE_MAP, A.__webglTexture, n.TEXTURE0 + W);
|
|
14511
14511
|
const le = i.get(ie);
|
|
14512
14512
|
if (ie.version !== le.__version || se === !0) {
|
|
@@ -14516,7 +14516,7 @@ function Bx(n, e, t, i, r, s, o) {
|
|
|
14516
14516
|
!Ee && !ce ? X[$] = v(y.image[$], !1, !0, c) : X[$] = ce ? y.image[$].image : y.image[$], X[$] = tt(y, X[$]);
|
|
14517
14517
|
const L = X[0], te = M(L) || a, xe = s.convert(y.format, y.colorSpace), pe = s.convert(y.type), ve = N(y.internalFormat, xe, pe, y.colorSpace), Ne = a && y.isVideoTexture !== !0, We = le.__version === void 0 || se === !0;
|
|
14518
14518
|
let I = x(y, L, te);
|
|
14519
|
-
|
|
14519
|
+
we(n.TEXTURE_CUBE_MAP, y, te);
|
|
14520
14520
|
let _e;
|
|
14521
14521
|
if (Ee) {
|
|
14522
14522
|
Ne && We && t.texStorage2D(n.TEXTURE_CUBE_MAP, I, ve, L.width, L.height);
|
|
@@ -14544,7 +14544,7 @@ function Bx(n, e, t, i, r, s, o) {
|
|
|
14544
14544
|
}
|
|
14545
14545
|
}
|
|
14546
14546
|
}
|
|
14547
|
-
R(y, te) &&
|
|
14547
|
+
R(y, te) && w(n.TEXTURE_CUBE_MAP), le.__version = ie.version, y.onUpdate && y.onUpdate(y);
|
|
14548
14548
|
}
|
|
14549
14549
|
A.__version = y.version;
|
|
14550
14550
|
}
|
|
@@ -14653,29 +14653,29 @@ function Bx(n, e, t, i, r, s, o) {
|
|
|
14653
14653
|
}
|
|
14654
14654
|
}
|
|
14655
14655
|
if (ie) {
|
|
14656
|
-
t.bindTexture(n.TEXTURE_CUBE_MAP, se.__webglTexture),
|
|
14656
|
+
t.bindTexture(n.TEXTURE_CUBE_MAP, se.__webglTexture), we(n.TEXTURE_CUBE_MAP, y, Ee);
|
|
14657
14657
|
for (let ce = 0; ce < 6; ce++)
|
|
14658
14658
|
if (a && y.mipmaps && y.mipmaps.length > 0)
|
|
14659
14659
|
for (let X = 0; X < y.mipmaps.length; X++)
|
|
14660
14660
|
Ce(W.__webglFramebuffer[ce][X], A, y, n.COLOR_ATTACHMENT0, n.TEXTURE_CUBE_MAP_POSITIVE_X + ce, X);
|
|
14661
14661
|
else
|
|
14662
14662
|
Ce(W.__webglFramebuffer[ce], A, y, n.COLOR_ATTACHMENT0, n.TEXTURE_CUBE_MAP_POSITIVE_X + ce, 0);
|
|
14663
|
-
R(y, Ee) &&
|
|
14663
|
+
R(y, Ee) && w(n.TEXTURE_CUBE_MAP), t.unbindTexture();
|
|
14664
14664
|
} else if (le) {
|
|
14665
14665
|
const ce = A.texture;
|
|
14666
14666
|
for (let X = 0, L = ce.length; X < L; X++) {
|
|
14667
14667
|
const te = ce[X], xe = i.get(te);
|
|
14668
|
-
t.bindTexture(n.TEXTURE_2D, xe.__webglTexture),
|
|
14668
|
+
t.bindTexture(n.TEXTURE_2D, xe.__webglTexture), we(n.TEXTURE_2D, te, Ee), Ce(W.__webglFramebuffer, A, te, n.COLOR_ATTACHMENT0 + X, n.TEXTURE_2D, 0), R(te, Ee) && w(n.TEXTURE_2D);
|
|
14669
14669
|
}
|
|
14670
14670
|
t.unbindTexture();
|
|
14671
14671
|
} else {
|
|
14672
14672
|
let ce = n.TEXTURE_2D;
|
|
14673
|
-
if ((A.isWebGL3DRenderTarget || A.isWebGLArrayRenderTarget) && (a ? ce = A.isWebGL3DRenderTarget ? n.TEXTURE_3D : n.TEXTURE_2D_ARRAY : console.error("THREE.WebGLTextures: THREE.Data3DTexture and THREE.DataArrayTexture only supported with WebGL2.")), t.bindTexture(ce, se.__webglTexture),
|
|
14673
|
+
if ((A.isWebGL3DRenderTarget || A.isWebGLArrayRenderTarget) && (a ? ce = A.isWebGL3DRenderTarget ? n.TEXTURE_3D : n.TEXTURE_2D_ARRAY : console.error("THREE.WebGLTextures: THREE.Data3DTexture and THREE.DataArrayTexture only supported with WebGL2.")), t.bindTexture(ce, se.__webglTexture), we(ce, y, Ee), a && y.mipmaps && y.mipmaps.length > 0)
|
|
14674
14674
|
for (let X = 0; X < y.mipmaps.length; X++)
|
|
14675
14675
|
Ce(W.__webglFramebuffer[X], A, y, n.COLOR_ATTACHMENT0, ce, X);
|
|
14676
14676
|
else
|
|
14677
14677
|
Ce(W.__webglFramebuffer, A, y, n.COLOR_ATTACHMENT0, ce, 0);
|
|
14678
|
-
R(y, Ee) &&
|
|
14678
|
+
R(y, Ee) && w(ce), t.unbindTexture();
|
|
14679
14679
|
}
|
|
14680
14680
|
A.depthBuffer && J(A);
|
|
14681
14681
|
}
|
|
@@ -14685,7 +14685,7 @@ function Bx(n, e, t, i, r, s, o) {
|
|
|
14685
14685
|
const le = W[se];
|
|
14686
14686
|
if (R(le, y)) {
|
|
14687
14687
|
const Ee = A.isWebGLCubeRenderTarget ? n.TEXTURE_CUBE_MAP : n.TEXTURE_2D, ce = i.get(le).__webglTexture;
|
|
14688
|
-
t.bindTexture(Ee, ce),
|
|
14688
|
+
t.bindTexture(Ee, ce), w(Ee), t.unbindTexture();
|
|
14689
14689
|
}
|
|
14690
14690
|
}
|
|
14691
14691
|
}
|
|
@@ -14986,8 +14986,8 @@ class Wx extends gi {
|
|
|
14986
14986
|
M.layers.enable(1), M.viewport = new Ke();
|
|
14987
14987
|
const b = new Vt();
|
|
14988
14988
|
b.layers.enable(2), b.viewport = new Ke();
|
|
14989
|
-
const R = [M, b],
|
|
14990
|
-
|
|
14989
|
+
const R = [M, b], w = new kx();
|
|
14990
|
+
w.layers.enable(1), w.layers.enable(2);
|
|
14991
14991
|
let N = null, x = null;
|
|
14992
14992
|
this.cameraAutoUpdate = !0, this.enabled = !1, this.isPresenting = !1, this.getController = function(B) {
|
|
14993
14993
|
let q = S[B];
|
|
@@ -15108,9 +15108,9 @@ class Wx extends gi {
|
|
|
15108
15108
|
const O = new D(), U = new D();
|
|
15109
15109
|
function C(B, q, oe) {
|
|
15110
15110
|
O.setFromMatrixPosition(q.matrixWorld), U.setFromMatrixPosition(oe.matrixWorld);
|
|
15111
|
-
const me = O.distanceTo(U), ge = q.projectionMatrix.elements, Ae = oe.projectionMatrix.elements,
|
|
15111
|
+
const me = O.distanceTo(U), ge = q.projectionMatrix.elements, Ae = oe.projectionMatrix.elements, we = ge[14] / (ge[10] - 1), Te = ge[14] / (ge[10] + 1), Ve = (ge[9] + 1) / ge[5], Ze = (ge[9] - 1) / ge[5], Ce = (ge[8] - 1) / ge[0], P = (Ae[8] + 1) / Ae[0], he = we * Ce, J = we * P, ae = me / (-Ce + P), ne = ae * -Ce;
|
|
15112
15112
|
q.matrixWorld.decompose(B.position, B.quaternion, B.scale), B.translateX(ne), B.translateZ(ae), B.matrixWorld.compose(B.position, B.quaternion, B.scale), B.matrixWorldInverse.copy(B.matrixWorld).invert();
|
|
15113
|
-
const be =
|
|
15113
|
+
const be = we + ae, ye = Te + ae, Se = he - ne, Pe = J + (me - ne), ze = Ve * Te / ye * be, tt = Ze * Te / ye * be;
|
|
15114
15114
|
B.projectionMatrix.makePerspective(Se, Pe, ze, tt, be, ye), B.projectionMatrixInverse.copy(B.projectionMatrix).invert();
|
|
15115
15115
|
}
|
|
15116
15116
|
function z(B, q) {
|
|
@@ -15119,21 +15119,21 @@ class Wx extends gi {
|
|
|
15119
15119
|
this.updateCamera = function(B) {
|
|
15120
15120
|
if (r === null)
|
|
15121
15121
|
return;
|
|
15122
|
-
|
|
15123
|
-
depthNear:
|
|
15124
|
-
depthFar:
|
|
15125
|
-
}), N =
|
|
15126
|
-
const q = B.parent, oe =
|
|
15127
|
-
z(
|
|
15122
|
+
w.near = b.near = M.near = B.near, w.far = b.far = M.far = B.far, (N !== w.near || x !== w.far) && (r.updateRenderState({
|
|
15123
|
+
depthNear: w.near,
|
|
15124
|
+
depthFar: w.far
|
|
15125
|
+
}), N = w.near, x = w.far);
|
|
15126
|
+
const q = B.parent, oe = w.cameras;
|
|
15127
|
+
z(w, q);
|
|
15128
15128
|
for (let me = 0; me < oe.length; me++)
|
|
15129
15129
|
z(oe[me], q);
|
|
15130
|
-
oe.length === 2 ? C(
|
|
15130
|
+
oe.length === 2 ? C(w, M, b) : w.projectionMatrix.copy(M.projectionMatrix), H(B, w, q);
|
|
15131
15131
|
};
|
|
15132
15132
|
function H(B, q, oe) {
|
|
15133
15133
|
oe === null ? B.matrix.copy(q.matrixWorld) : (B.matrix.copy(oe.matrixWorld), B.matrix.invert(), B.matrix.multiply(q.matrixWorld)), B.matrix.decompose(B.position, B.quaternion, B.scale), B.updateMatrixWorld(!0), B.projectionMatrix.copy(q.projectionMatrix), B.projectionMatrixInverse.copy(q.projectionMatrixInverse), B.isPerspectiveCamera && (B.fov = Mr * 2 * Math.atan(1 / B.projectionMatrix.elements[5]), B.zoom = 1);
|
|
15134
15134
|
}
|
|
15135
15135
|
this.getCamera = function() {
|
|
15136
|
-
return
|
|
15136
|
+
return w;
|
|
15137
15137
|
}, this.getFoveation = function() {
|
|
15138
15138
|
if (!(f === null && d === null))
|
|
15139
15139
|
return l;
|
|
@@ -15146,22 +15146,22 @@ class Wx extends gi {
|
|
|
15146
15146
|
const oe = u.views;
|
|
15147
15147
|
d !== null && (e.setRenderTargetFramebuffer(p, d.framebuffer), e.setRenderTarget(p));
|
|
15148
15148
|
let me = !1;
|
|
15149
|
-
oe.length !==
|
|
15149
|
+
oe.length !== w.cameras.length && (w.cameras.length = 0, me = !0);
|
|
15150
15150
|
for (let ge = 0; ge < oe.length; ge++) {
|
|
15151
15151
|
const Ae = oe[ge];
|
|
15152
|
-
let
|
|
15152
|
+
let we = null;
|
|
15153
15153
|
if (d !== null)
|
|
15154
|
-
|
|
15154
|
+
we = d.getViewport(Ae);
|
|
15155
15155
|
else {
|
|
15156
15156
|
const Ve = h.getViewSubImage(f, Ae);
|
|
15157
|
-
|
|
15157
|
+
we = Ve.viewport, ge === 0 && (e.setRenderTargetTextures(
|
|
15158
15158
|
p,
|
|
15159
15159
|
Ve.colorTexture,
|
|
15160
15160
|
f.ignoreDepthValues ? void 0 : Ve.depthStencilTexture
|
|
15161
15161
|
), e.setRenderTarget(p));
|
|
15162
15162
|
}
|
|
15163
|
-
let
|
|
15164
|
-
|
|
15163
|
+
let Te = R[ge];
|
|
15164
|
+
Te === void 0 && (Te = new Vt(), Te.layers.enable(ge), Te.viewport = new Ke(), R[ge] = Te), Te.matrix.fromArray(Ae.transform.matrix), Te.matrix.decompose(Te.position, Te.quaternion, Te.scale), Te.projectionMatrix.fromArray(Ae.projectionMatrix), Te.projectionMatrixInverse.copy(Te.projectionMatrix).invert(), Te.viewport.set(we.x, we.y, we.width, we.height), ge === 0 && (w.matrix.copy(Te.matrix), w.matrix.decompose(w.position, w.quaternion, w.scale)), me === !0 && w.cameras.push(Te);
|
|
15165
15165
|
}
|
|
15166
15166
|
}
|
|
15167
15167
|
for (let oe = 0; oe < S.length; oe++) {
|
|
@@ -15170,7 +15170,7 @@ class Wx extends gi {
|
|
|
15170
15170
|
}
|
|
15171
15171
|
V && V(B, q), q.detectedPlanes && i.dispatchEvent({ type: "planesdetected", data: q }), g = null;
|
|
15172
15172
|
}
|
|
15173
|
-
const Q = new
|
|
15173
|
+
const Q = new Th();
|
|
15174
15174
|
Q.setAnimationLoop(K), this.setAnimationLoop = function(B) {
|
|
15175
15175
|
V = B;
|
|
15176
15176
|
}, this.dispose = function() {
|
|
@@ -15263,7 +15263,7 @@ function $x(n, e, t, i) {
|
|
|
15263
15263
|
function f(S) {
|
|
15264
15264
|
const v = r[S.id], M = S.uniforms, b = S.__cache;
|
|
15265
15265
|
n.bindBuffer(n.UNIFORM_BUFFER, v);
|
|
15266
|
-
for (let R = 0,
|
|
15266
|
+
for (let R = 0, w = M.length; R < w; R++) {
|
|
15267
15267
|
const N = M[R];
|
|
15268
15268
|
if (d(N, R, b) === !0) {
|
|
15269
15269
|
const x = N.__offset, E = Array.isArray(N.value) ? N.value : [N.value];
|
|
@@ -15283,21 +15283,21 @@ function $x(n, e, t, i) {
|
|
|
15283
15283
|
if (typeof b == "number")
|
|
15284
15284
|
M[v] = b;
|
|
15285
15285
|
else {
|
|
15286
|
-
const R = Array.isArray(b) ? b : [b],
|
|
15286
|
+
const R = Array.isArray(b) ? b : [b], w = [];
|
|
15287
15287
|
for (let N = 0; N < R.length; N++)
|
|
15288
|
-
|
|
15289
|
-
M[v] =
|
|
15288
|
+
w.push(R[N].clone());
|
|
15289
|
+
M[v] = w;
|
|
15290
15290
|
}
|
|
15291
15291
|
return !0;
|
|
15292
15292
|
} else if (typeof b == "number") {
|
|
15293
15293
|
if (M[v] !== b)
|
|
15294
15294
|
return M[v] = b, !0;
|
|
15295
15295
|
} else {
|
|
15296
|
-
const R = Array.isArray(M[v]) ? M[v] : [M[v]],
|
|
15296
|
+
const R = Array.isArray(M[v]) ? M[v] : [M[v]], w = Array.isArray(b) ? b : [b];
|
|
15297
15297
|
for (let N = 0; N < R.length; N++) {
|
|
15298
15298
|
const x = R[N];
|
|
15299
|
-
if (x.equals(
|
|
15300
|
-
return x.copy(
|
|
15299
|
+
if (x.equals(w[N]) === !1)
|
|
15300
|
+
return x.copy(w[N]), !0;
|
|
15301
15301
|
}
|
|
15302
15302
|
}
|
|
15303
15303
|
return !1;
|
|
@@ -15307,8 +15307,8 @@ function $x(n, e, t, i) {
|
|
|
15307
15307
|
let M = 0;
|
|
15308
15308
|
const b = 16;
|
|
15309
15309
|
let R = 0;
|
|
15310
|
-
for (let
|
|
15311
|
-
const x = v[
|
|
15310
|
+
for (let w = 0, N = v.length; w < N; w++) {
|
|
15311
|
+
const x = v[w], E = {
|
|
15312
15312
|
boundary: 0,
|
|
15313
15313
|
// bytes
|
|
15314
15314
|
storage: 0
|
|
@@ -15318,7 +15318,7 @@ function $x(n, e, t, i) {
|
|
|
15318
15318
|
const U = F[ee], C = _(U);
|
|
15319
15319
|
E.boundary += C.boundary, E.storage += C.storage;
|
|
15320
15320
|
}
|
|
15321
|
-
if (x.__data = new Float32Array(E.storage / Float32Array.BYTES_PER_ELEMENT), x.__offset = M,
|
|
15321
|
+
if (x.__data = new Float32Array(E.storage / Float32Array.BYTES_PER_ELEMENT), x.__offset = M, w > 0) {
|
|
15322
15322
|
R = M % b;
|
|
15323
15323
|
const ee = b - R;
|
|
15324
15324
|
R !== 0 && ee - E.boundary < 0 && (M += b - R, x.__offset = M);
|
|
@@ -15386,7 +15386,7 @@ class Ph {
|
|
|
15386
15386
|
onShaderError: null
|
|
15387
15387
|
}, this.autoClear = !0, this.autoClearColor = !0, this.autoClearDepth = !0, this.autoClearStencil = !0, this.sortObjects = !0, this.clippingPlanes = [], this.localClippingEnabled = !1, this.outputColorSpace = it, this._useLegacyLights = !1, this.toneMapping = Xn, this.toneMappingExposure = 1;
|
|
15388
15388
|
const v = this;
|
|
15389
|
-
let M = !1, b = 0, R = 0,
|
|
15389
|
+
let M = !1, b = 0, R = 0, w = null, N = -1, x = null;
|
|
15390
15390
|
const E = new Ke(), F = new Ke();
|
|
15391
15391
|
let ee = null;
|
|
15392
15392
|
const O = new je(0);
|
|
@@ -15395,21 +15395,21 @@ class Ph {
|
|
|
15395
15395
|
let q = !1;
|
|
15396
15396
|
const oe = new Na();
|
|
15397
15397
|
let me = !1, ge = !1, Ae = null;
|
|
15398
|
-
const
|
|
15398
|
+
const we = new rt(), Te = new ue(), Ve = new D(), Ze = { background: null, fog: null, environment: null, overrideMaterial: null, isScene: !0 };
|
|
15399
15399
|
function Ce() {
|
|
15400
|
-
return
|
|
15400
|
+
return w === null ? H : 1;
|
|
15401
15401
|
}
|
|
15402
15402
|
let P = i;
|
|
15403
|
-
function he(
|
|
15404
|
-
for (let j = 0; j <
|
|
15405
|
-
const G =
|
|
15403
|
+
function he(T, k) {
|
|
15404
|
+
for (let j = 0; j < T.length; j++) {
|
|
15405
|
+
const G = T[j], Y = t.getContext(G, k);
|
|
15406
15406
|
if (Y !== null)
|
|
15407
15407
|
return Y;
|
|
15408
15408
|
}
|
|
15409
15409
|
return null;
|
|
15410
15410
|
}
|
|
15411
15411
|
try {
|
|
15412
|
-
const
|
|
15412
|
+
const T = {
|
|
15413
15413
|
alpha: !0,
|
|
15414
15414
|
depth: r,
|
|
15415
15415
|
stencil: s,
|
|
@@ -15421,18 +15421,18 @@ class Ph {
|
|
|
15421
15421
|
};
|
|
15422
15422
|
if ("setAttribute" in t && t.setAttribute("data-engine", `three.js r${Aa}`), t.addEventListener("webglcontextlost", _e, !1), t.addEventListener("webglcontextrestored", $, !1), t.addEventListener("webglcontextcreationerror", re, !1), P === null) {
|
|
15423
15423
|
const k = ["webgl2", "webgl", "experimental-webgl"];
|
|
15424
|
-
if (v.isWebGL1Renderer === !0 && k.shift(), P = he(k,
|
|
15424
|
+
if (v.isWebGL1Renderer === !0 && k.shift(), P = he(k, T), P === null)
|
|
15425
15425
|
throw he(k) ? new Error("Error creating WebGL context with your selected attributes.") : new Error("Error creating WebGL context.");
|
|
15426
15426
|
}
|
|
15427
15427
|
typeof WebGLRenderingContext != "undefined" && P instanceof WebGLRenderingContext && console.warn("THREE.WebGLRenderer: WebGL 1 support was deprecated in r153 and will be removed in r163."), P.getShaderPrecisionFormat === void 0 && (P.getShaderPrecisionFormat = function() {
|
|
15428
15428
|
return { rangeMin: 1, rangeMax: 1, precision: 1 };
|
|
15429
15429
|
});
|
|
15430
|
-
} catch (
|
|
15431
|
-
throw console.error("THREE.WebGLRenderer: " +
|
|
15430
|
+
} catch (T) {
|
|
15431
|
+
throw console.error("THREE.WebGLRenderer: " + T.message), T;
|
|
15432
15432
|
}
|
|
15433
15433
|
let J, ae, ne, be, ye, Se, Pe, ze, tt, A, y, W, se, ie, le, Ee, ce, X, L, te, xe, pe, ve, Ne;
|
|
15434
15434
|
function We() {
|
|
15435
|
-
J = new n0(P), ae = new Yv(P, J, e), J.init(ae), pe = new Hx(P, J, ae), ne = new Fx(P, J, ae), be = new s0(P), ye = new Ex(), Se = new Bx(P, J, ne, ye, ae, pe, be), Pe = new Zv(v), ze = new t0(v), tt = new pg(P, ae), ve = new qv(P, J, tt, ae), A = new i0(P, tt, be, ve), y = new c0(P, A, tt, be), L = new l0(P, ae, Se), Ee = new Kv(ye), W = new Mx(v, Pe, ze, J, ae, ve, Ee), se = new Xx(v, ye), ie = new
|
|
15435
|
+
J = new n0(P), ae = new Yv(P, J, e), J.init(ae), pe = new Hx(P, J, ae), ne = new Fx(P, J, ae), be = new s0(P), ye = new Ex(), Se = new Bx(P, J, ne, ye, ae, pe, be), Pe = new Zv(v), ze = new t0(v), tt = new pg(P, ae), ve = new qv(P, J, tt, ae), A = new i0(P, tt, be, ve), y = new c0(P, A, tt, be), L = new l0(P, ae, Se), Ee = new Kv(ye), W = new Mx(v, Pe, ze, J, ae, ve, Ee), se = new Xx(v, ye), ie = new Tx(), le = new Lx(J, ae), X = new $v(v, Pe, ze, ne, y, f, l), ce = new Ox(v, y, ae), Ne = new $x(P, be, ae, ne), te = new jv(P, J, be, ae), xe = new r0(P, J, be, ae), be.programs = W.programs, v.capabilities = ae, v.extensions = J, v.properties = ye, v.renderLists = ie, v.shadowMap = ce, v.state = ne, v.info = be;
|
|
15436
15436
|
}
|
|
15437
15437
|
We();
|
|
15438
15438
|
const I = new Wx(v, P);
|
|
@@ -15441,63 +15441,63 @@ class Ph {
|
|
|
15441
15441
|
}, this.getContextAttributes = function() {
|
|
15442
15442
|
return P.getContextAttributes();
|
|
15443
15443
|
}, this.forceContextLoss = function() {
|
|
15444
|
-
const
|
|
15445
|
-
|
|
15444
|
+
const T = J.get("WEBGL_lose_context");
|
|
15445
|
+
T && T.loseContext();
|
|
15446
15446
|
}, this.forceContextRestore = function() {
|
|
15447
|
-
const
|
|
15448
|
-
|
|
15447
|
+
const T = J.get("WEBGL_lose_context");
|
|
15448
|
+
T && T.restoreContext();
|
|
15449
15449
|
}, this.getPixelRatio = function() {
|
|
15450
15450
|
return H;
|
|
15451
|
-
}, this.setPixelRatio = function(
|
|
15452
|
-
|
|
15453
|
-
}, this.getSize = function(
|
|
15454
|
-
return
|
|
15455
|
-
}, this.setSize = function(
|
|
15451
|
+
}, this.setPixelRatio = function(T) {
|
|
15452
|
+
T !== void 0 && (H = T, this.setSize(C, z, !1));
|
|
15453
|
+
}, this.getSize = function(T) {
|
|
15454
|
+
return T.set(C, z);
|
|
15455
|
+
}, this.setSize = function(T, k, j = !0) {
|
|
15456
15456
|
if (I.isPresenting) {
|
|
15457
15457
|
console.warn("THREE.WebGLRenderer: Can't change size while VR device is presenting.");
|
|
15458
15458
|
return;
|
|
15459
15459
|
}
|
|
15460
|
-
C =
|
|
15461
|
-
}, this.getDrawingBufferSize = function(
|
|
15462
|
-
return
|
|
15463
|
-
}, this.setDrawingBufferSize = function(
|
|
15464
|
-
C =
|
|
15465
|
-
}, this.getCurrentViewport = function(
|
|
15466
|
-
return
|
|
15467
|
-
}, this.getViewport = function(
|
|
15468
|
-
return
|
|
15469
|
-
}, this.setViewport = function(
|
|
15470
|
-
|
|
15471
|
-
}, this.getScissor = function(
|
|
15472
|
-
return
|
|
15473
|
-
}, this.setScissor = function(
|
|
15474
|
-
|
|
15460
|
+
C = T, z = k, t.width = Math.floor(T * H), t.height = Math.floor(k * H), j === !0 && (t.style.width = T + "px", t.style.height = k + "px"), this.setViewport(0, 0, T, k);
|
|
15461
|
+
}, this.getDrawingBufferSize = function(T) {
|
|
15462
|
+
return T.set(C * H, z * H).floor();
|
|
15463
|
+
}, this.setDrawingBufferSize = function(T, k, j) {
|
|
15464
|
+
C = T, z = k, H = j, t.width = Math.floor(T * j), t.height = Math.floor(k * j), this.setViewport(0, 0, T, k);
|
|
15465
|
+
}, this.getCurrentViewport = function(T) {
|
|
15466
|
+
return T.copy(E);
|
|
15467
|
+
}, this.getViewport = function(T) {
|
|
15468
|
+
return T.copy(Q);
|
|
15469
|
+
}, this.setViewport = function(T, k, j, G) {
|
|
15470
|
+
T.isVector4 ? Q.set(T.x, T.y, T.z, T.w) : Q.set(T, k, j, G), ne.viewport(E.copy(Q).multiplyScalar(H).floor());
|
|
15471
|
+
}, this.getScissor = function(T) {
|
|
15472
|
+
return T.copy(B);
|
|
15473
|
+
}, this.setScissor = function(T, k, j, G) {
|
|
15474
|
+
T.isVector4 ? B.set(T.x, T.y, T.z, T.w) : B.set(T, k, j, G), ne.scissor(F.copy(B).multiplyScalar(H).floor());
|
|
15475
15475
|
}, this.getScissorTest = function() {
|
|
15476
15476
|
return q;
|
|
15477
|
-
}, this.setScissorTest = function(
|
|
15478
|
-
ne.setScissorTest(q =
|
|
15479
|
-
}, this.setOpaqueSort = function(
|
|
15480
|
-
V =
|
|
15481
|
-
}, this.setTransparentSort = function(
|
|
15482
|
-
K =
|
|
15483
|
-
}, this.getClearColor = function(
|
|
15484
|
-
return
|
|
15477
|
+
}, this.setScissorTest = function(T) {
|
|
15478
|
+
ne.setScissorTest(q = T);
|
|
15479
|
+
}, this.setOpaqueSort = function(T) {
|
|
15480
|
+
V = T;
|
|
15481
|
+
}, this.setTransparentSort = function(T) {
|
|
15482
|
+
K = T;
|
|
15483
|
+
}, this.getClearColor = function(T) {
|
|
15484
|
+
return T.copy(X.getClearColor());
|
|
15485
15485
|
}, this.setClearColor = function() {
|
|
15486
15486
|
X.setClearColor.apply(X, arguments);
|
|
15487
15487
|
}, this.getClearAlpha = function() {
|
|
15488
15488
|
return X.getClearAlpha();
|
|
15489
15489
|
}, this.setClearAlpha = function() {
|
|
15490
15490
|
X.setClearAlpha.apply(X, arguments);
|
|
15491
|
-
}, this.clear = function(
|
|
15491
|
+
}, this.clear = function(T = !0, k = !0, j = !0) {
|
|
15492
15492
|
let G = 0;
|
|
15493
|
-
if (
|
|
15493
|
+
if (T) {
|
|
15494
15494
|
let Y = !1;
|
|
15495
|
-
if (
|
|
15496
|
-
const Me =
|
|
15495
|
+
if (w !== null) {
|
|
15496
|
+
const Me = w.texture.format;
|
|
15497
15497
|
Y = Me === hh || Me === uh || Me === ch;
|
|
15498
15498
|
}
|
|
15499
15499
|
if (Y) {
|
|
15500
|
-
const Me =
|
|
15500
|
+
const Me = w.texture.type, Re = Me === $n || Me === kn || Me === Ra || Me === oi || Me === ah || Me === lh, Ie = X.getClearColor(), Ue = X.getClearAlpha(), ke = Ie.r, De = Ie.g, Oe = Ie.b;
|
|
15501
15501
|
Re ? (d[0] = ke, d[1] = De, d[2] = Oe, d[3] = Ue, P.clearBufferuiv(P.COLOR, 0, d)) : (g[0] = ke, g[1] = De, g[2] = Oe, g[3] = Ue, P.clearBufferiv(P.COLOR, 0, g));
|
|
15502
15502
|
} else
|
|
15503
15503
|
G |= P.COLOR_BUFFER_BIT;
|
|
@@ -15512,33 +15512,33 @@ class Ph {
|
|
|
15512
15512
|
}, this.dispose = function() {
|
|
15513
15513
|
t.removeEventListener("webglcontextlost", _e, !1), t.removeEventListener("webglcontextrestored", $, !1), t.removeEventListener("webglcontextcreationerror", re, !1), ie.dispose(), le.dispose(), ye.dispose(), Pe.dispose(), ze.dispose(), y.dispose(), ve.dispose(), Ne.dispose(), W.dispose(), I.dispose(), I.removeEventListener("sessionstart", et), I.removeEventListener("sessionend", cn), Ae && (Ae.dispose(), Ae = null), Ct.stop();
|
|
15514
15514
|
};
|
|
15515
|
-
function _e(
|
|
15516
|
-
|
|
15515
|
+
function _e(T) {
|
|
15516
|
+
T.preventDefault(), console.log("THREE.WebGLRenderer: Context Lost."), M = !0;
|
|
15517
15517
|
}
|
|
15518
15518
|
function $() {
|
|
15519
15519
|
console.log("THREE.WebGLRenderer: Context Restored."), M = !1;
|
|
15520
|
-
const
|
|
15521
|
-
We(), be.autoReset =
|
|
15520
|
+
const T = be.autoReset, k = ce.enabled, j = ce.autoUpdate, G = ce.needsUpdate, Y = ce.type;
|
|
15521
|
+
We(), be.autoReset = T, ce.enabled = k, ce.autoUpdate = j, ce.needsUpdate = G, ce.type = Y;
|
|
15522
15522
|
}
|
|
15523
|
-
function re(
|
|
15524
|
-
console.error("THREE.WebGLRenderer: A WebGL context could not be created. Reason: ",
|
|
15523
|
+
function re(T) {
|
|
15524
|
+
console.error("THREE.WebGLRenderer: A WebGL context could not be created. Reason: ", T.statusMessage);
|
|
15525
15525
|
}
|
|
15526
|
-
function fe(
|
|
15527
|
-
const k =
|
|
15526
|
+
function fe(T) {
|
|
15527
|
+
const k = T.target;
|
|
15528
15528
|
k.removeEventListener("dispose", fe), He(k);
|
|
15529
15529
|
}
|
|
15530
|
-
function He(
|
|
15531
|
-
qe(
|
|
15530
|
+
function He(T) {
|
|
15531
|
+
qe(T), ye.remove(T);
|
|
15532
15532
|
}
|
|
15533
|
-
function qe(
|
|
15534
|
-
const k = ye.get(
|
|
15533
|
+
function qe(T) {
|
|
15534
|
+
const k = ye.get(T).programs;
|
|
15535
15535
|
k !== void 0 && (k.forEach(function(j) {
|
|
15536
15536
|
W.releaseProgram(j);
|
|
15537
|
-
}),
|
|
15537
|
+
}), T.isShaderMaterial && W.releaseShaderCache(T));
|
|
15538
15538
|
}
|
|
15539
|
-
this.renderBufferDirect = function(
|
|
15539
|
+
this.renderBufferDirect = function(T, k, j, G, Y, Me) {
|
|
15540
15540
|
k === null && (k = Ze);
|
|
15541
|
-
const Re = Y.isMesh && Y.matrixWorld.determinant() < 0, Ie = _f(
|
|
15541
|
+
const Re = Y.isMesh && Y.matrixWorld.determinant() < 0, Ie = _f(T, k, j, G, Y);
|
|
15542
15542
|
ne.setMaterial(G, Re);
|
|
15543
15543
|
let Ue = j.index, ke = 1;
|
|
15544
15544
|
if (G.wireframe === !0) {
|
|
@@ -15568,27 +15568,27 @@ class Ph {
|
|
|
15568
15568
|
ft.renderInstances(ot, Wt, Qs);
|
|
15569
15569
|
} else
|
|
15570
15570
|
ft.render(ot, Wt);
|
|
15571
|
-
}, this.compile = function(
|
|
15571
|
+
}, this.compile = function(T, k) {
|
|
15572
15572
|
function j(G, Y, Me) {
|
|
15573
15573
|
G.transparent === !0 && G.side === Cn && G.forceSinglePass === !1 ? (G.side = Ot, G.needsUpdate = !0, Fr(G, Y, Me), G.side = jn, G.needsUpdate = !0, Fr(G, Y, Me), G.side = Cn) : Fr(G, Y, Me);
|
|
15574
15574
|
}
|
|
15575
|
-
m = le.get(
|
|
15575
|
+
m = le.get(T), m.init(), S.push(m), T.traverseVisible(function(G) {
|
|
15576
15576
|
G.isLight && G.layers.test(k.layers) && (m.pushLight(G), G.castShadow && m.pushShadow(G));
|
|
15577
|
-
}), m.setupLights(v._useLegacyLights),
|
|
15577
|
+
}), m.setupLights(v._useLegacyLights), T.traverse(function(G) {
|
|
15578
15578
|
const Y = G.material;
|
|
15579
15579
|
if (Y)
|
|
15580
15580
|
if (Array.isArray(Y))
|
|
15581
15581
|
for (let Me = 0; Me < Y.length; Me++) {
|
|
15582
15582
|
const Re = Y[Me];
|
|
15583
|
-
j(Re,
|
|
15583
|
+
j(Re, T, G);
|
|
15584
15584
|
}
|
|
15585
15585
|
else
|
|
15586
|
-
j(Y,
|
|
15586
|
+
j(Y, T, G);
|
|
15587
15587
|
}), S.pop(), m = null;
|
|
15588
15588
|
};
|
|
15589
15589
|
let Je = null;
|
|
15590
|
-
function Ft(
|
|
15591
|
-
Je && Je(
|
|
15590
|
+
function Ft(T) {
|
|
15591
|
+
Je && Je(T);
|
|
15592
15592
|
}
|
|
15593
15593
|
function et() {
|
|
15594
15594
|
Ct.stop();
|
|
@@ -15596,76 +15596,76 @@ class Ph {
|
|
|
15596
15596
|
function cn() {
|
|
15597
15597
|
Ct.start();
|
|
15598
15598
|
}
|
|
15599
|
-
const Ct = new
|
|
15600
|
-
Ct.setAnimationLoop(Ft), typeof self != "undefined" && Ct.setContext(self), this.setAnimationLoop = function(
|
|
15601
|
-
Je =
|
|
15602
|
-
}, I.addEventListener("sessionstart", et), I.addEventListener("sessionend", cn), this.render = function(
|
|
15599
|
+
const Ct = new Th();
|
|
15600
|
+
Ct.setAnimationLoop(Ft), typeof self != "undefined" && Ct.setContext(self), this.setAnimationLoop = function(T) {
|
|
15601
|
+
Je = T, I.setAnimationLoop(T), T === null ? Ct.stop() : Ct.start();
|
|
15602
|
+
}, I.addEventListener("sessionstart", et), I.addEventListener("sessionend", cn), this.render = function(T, k) {
|
|
15603
15603
|
if (k !== void 0 && k.isCamera !== !0) {
|
|
15604
15604
|
console.error("THREE.WebGLRenderer.render: camera is not an instance of THREE.Camera.");
|
|
15605
15605
|
return;
|
|
15606
15606
|
}
|
|
15607
15607
|
if (M === !0)
|
|
15608
15608
|
return;
|
|
15609
|
-
|
|
15609
|
+
T.matrixWorldAutoUpdate === !0 && T.updateMatrixWorld(), k.parent === null && k.matrixWorldAutoUpdate === !0 && k.updateMatrixWorld(), I.enabled === !0 && I.isPresenting === !0 && (I.cameraAutoUpdate === !0 && I.updateCamera(k), k = I.getCamera()), T.isScene === !0 && T.onBeforeRender(v, T, k, w), m = le.get(T, S.length), m.init(), S.push(m), we.multiplyMatrices(k.projectionMatrix, k.matrixWorldInverse), oe.setFromProjectionMatrix(we), ge = this.localClippingEnabled, me = Ee.init(this.clippingPlanes, ge), _ = ie.get(T, p.length), _.init(), p.push(_), Ja(T, k, 0, v.sortObjects), _.finish(), v.sortObjects === !0 && _.sort(V, K), this.info.render.frame++, me === !0 && Ee.beginShadows();
|
|
15610
15610
|
const j = m.state.shadowsArray;
|
|
15611
|
-
if (ce.render(j,
|
|
15611
|
+
if (ce.render(j, T, k), me === !0 && Ee.endShadows(), this.info.autoReset === !0 && this.info.reset(), X.render(_, T), m.setupLights(v._useLegacyLights), k.isArrayCamera) {
|
|
15612
15612
|
const G = k.cameras;
|
|
15613
15613
|
for (let Y = 0, Me = G.length; Y < Me; Y++) {
|
|
15614
15614
|
const Re = G[Y];
|
|
15615
|
-
Qa(_,
|
|
15615
|
+
Qa(_, T, Re, Re.viewport);
|
|
15616
15616
|
}
|
|
15617
15617
|
} else
|
|
15618
|
-
Qa(_,
|
|
15619
|
-
|
|
15618
|
+
Qa(_, T, k);
|
|
15619
|
+
w !== null && (Se.updateMultisampleRenderTarget(w), Se.updateRenderTargetMipmap(w)), T.isScene === !0 && T.onAfterRender(v, T, k), ve.resetDefaultState(), N = -1, x = null, S.pop(), S.length > 0 ? m = S[S.length - 1] : m = null, p.pop(), p.length > 0 ? _ = p[p.length - 1] : _ = null;
|
|
15620
15620
|
};
|
|
15621
|
-
function Ja(
|
|
15622
|
-
if (
|
|
15621
|
+
function Ja(T, k, j, G) {
|
|
15622
|
+
if (T.visible === !1)
|
|
15623
15623
|
return;
|
|
15624
|
-
if (
|
|
15625
|
-
if (
|
|
15626
|
-
j =
|
|
15627
|
-
else if (
|
|
15628
|
-
|
|
15629
|
-
else if (
|
|
15630
|
-
m.pushLight(
|
|
15631
|
-
else if (
|
|
15632
|
-
if (!
|
|
15633
|
-
G && Ve.setFromMatrixPosition(
|
|
15634
|
-
const Re = y.update(
|
|
15635
|
-
Ie.visible && _.push(
|
|
15624
|
+
if (T.layers.test(k.layers)) {
|
|
15625
|
+
if (T.isGroup)
|
|
15626
|
+
j = T.renderOrder;
|
|
15627
|
+
else if (T.isLOD)
|
|
15628
|
+
T.autoUpdate === !0 && T.update(k);
|
|
15629
|
+
else if (T.isLight)
|
|
15630
|
+
m.pushLight(T), T.castShadow && m.pushShadow(T);
|
|
15631
|
+
else if (T.isSprite) {
|
|
15632
|
+
if (!T.frustumCulled || oe.intersectsSprite(T)) {
|
|
15633
|
+
G && Ve.setFromMatrixPosition(T.matrixWorld).applyMatrix4(we);
|
|
15634
|
+
const Re = y.update(T), Ie = T.material;
|
|
15635
|
+
Ie.visible && _.push(T, Re, Ie, j, Ve.z, null);
|
|
15636
15636
|
}
|
|
15637
|
-
} else if ((
|
|
15638
|
-
const Re = y.update(
|
|
15639
|
-
if (G && (
|
|
15637
|
+
} else if ((T.isMesh || T.isLine || T.isPoints) && (!T.frustumCulled || oe.intersectsObject(T))) {
|
|
15638
|
+
const Re = y.update(T), Ie = T.material;
|
|
15639
|
+
if (G && (T.boundingSphere !== void 0 ? (T.boundingSphere === null && T.computeBoundingSphere(), Ve.copy(T.boundingSphere.center)) : (Re.boundingSphere === null && Re.computeBoundingSphere(), Ve.copy(Re.boundingSphere.center)), Ve.applyMatrix4(T.matrixWorld).applyMatrix4(we)), Array.isArray(Ie)) {
|
|
15640
15640
|
const Ue = Re.groups;
|
|
15641
15641
|
for (let ke = 0, De = Ue.length; ke < De; ke++) {
|
|
15642
15642
|
const Oe = Ue[ke], ot = Ie[Oe.materialIndex];
|
|
15643
|
-
ot && ot.visible && _.push(
|
|
15643
|
+
ot && ot.visible && _.push(T, Re, ot, j, Ve.z, Oe);
|
|
15644
15644
|
}
|
|
15645
15645
|
} else
|
|
15646
|
-
Ie.visible && _.push(
|
|
15646
|
+
Ie.visible && _.push(T, Re, Ie, j, Ve.z, null);
|
|
15647
15647
|
}
|
|
15648
15648
|
}
|
|
15649
|
-
const Me =
|
|
15649
|
+
const Me = T.children;
|
|
15650
15650
|
for (let Re = 0, Ie = Me.length; Re < Ie; Re++)
|
|
15651
15651
|
Ja(Me[Re], k, j, G);
|
|
15652
15652
|
}
|
|
15653
|
-
function Qa(
|
|
15654
|
-
const Y =
|
|
15653
|
+
function Qa(T, k, j, G) {
|
|
15654
|
+
const Y = T.opaque, Me = T.transmissive, Re = T.transparent;
|
|
15655
15655
|
m.setupLightsView(j), me === !0 && Ee.setGlobalState(v.clippingPlanes, j), Me.length > 0 && gf(Y, Me, k, j), G && ne.viewport(E.copy(G)), Y.length > 0 && Or(Y, k, j), Me.length > 0 && Or(Me, k, j), Re.length > 0 && Or(Re, k, j), ne.buffers.depth.setTest(!0), ne.buffers.depth.setMask(!0), ne.buffers.color.setMask(!0), ne.setPolygonOffset(!1);
|
|
15656
15656
|
}
|
|
15657
|
-
function gf(
|
|
15657
|
+
function gf(T, k, j, G) {
|
|
15658
15658
|
const Y = ae.isWebGL2;
|
|
15659
15659
|
Ae === null && (Ae = new di(1, 1, {
|
|
15660
15660
|
generateMipmaps: !0,
|
|
15661
15661
|
type: J.has("EXT_color_buffer_half_float") ? Sr : $n,
|
|
15662
15662
|
minFilter: yr,
|
|
15663
15663
|
samples: Y ? 4 : 0
|
|
15664
|
-
})), v.getDrawingBufferSize(
|
|
15664
|
+
})), v.getDrawingBufferSize(Te), Y ? Ae.setSize(Te.x, Te.y) : Ae.setSize(Is(Te.x), Is(Te.y));
|
|
15665
15665
|
const Me = v.getRenderTarget();
|
|
15666
15666
|
v.setRenderTarget(Ae), v.getClearColor(O), U = v.getClearAlpha(), U < 1 && v.setClearColor(16777215, 0.5), v.clear();
|
|
15667
15667
|
const Re = v.toneMapping;
|
|
15668
|
-
v.toneMapping = Xn, Or(
|
|
15668
|
+
v.toneMapping = Xn, Or(T, j, G), Se.updateMultisampleRenderTarget(Ae), Se.updateRenderTargetMipmap(Ae);
|
|
15669
15669
|
let Ie = !1;
|
|
15670
15670
|
for (let Ue = 0, ke = k.length; Ue < ke; Ue++) {
|
|
15671
15671
|
const De = k[Ue], Oe = De.object, ot = De.geometry, ct = De.material, Wt = De.group;
|
|
@@ -15676,45 +15676,45 @@ class Ph {
|
|
|
15676
15676
|
}
|
|
15677
15677
|
Ie === !0 && (Se.updateMultisampleRenderTarget(Ae), Se.updateRenderTargetMipmap(Ae)), v.setRenderTarget(Me), v.setClearColor(O, U), v.toneMapping = Re;
|
|
15678
15678
|
}
|
|
15679
|
-
function Or(
|
|
15679
|
+
function Or(T, k, j) {
|
|
15680
15680
|
const G = k.isScene === !0 ? k.overrideMaterial : null;
|
|
15681
|
-
for (let Y = 0, Me =
|
|
15682
|
-
const Re =
|
|
15681
|
+
for (let Y = 0, Me = T.length; Y < Me; Y++) {
|
|
15682
|
+
const Re = T[Y], Ie = Re.object, Ue = Re.geometry, ke = G === null ? Re.material : G, De = Re.group;
|
|
15683
15683
|
Ie.layers.test(j.layers) && el(Ie, k, j, Ue, ke, De);
|
|
15684
15684
|
}
|
|
15685
15685
|
}
|
|
15686
|
-
function el(
|
|
15687
|
-
|
|
15686
|
+
function el(T, k, j, G, Y, Me) {
|
|
15687
|
+
T.onBeforeRender(v, k, j, G, Y, Me), T.modelViewMatrix.multiplyMatrices(j.matrixWorldInverse, T.matrixWorld), T.normalMatrix.getNormalMatrix(T.modelViewMatrix), Y.onBeforeRender(v, k, j, G, T, Me), Y.transparent === !0 && Y.side === Cn && Y.forceSinglePass === !1 ? (Y.side = Ot, Y.needsUpdate = !0, v.renderBufferDirect(j, k, G, Y, T, Me), Y.side = jn, Y.needsUpdate = !0, v.renderBufferDirect(j, k, G, Y, T, Me), Y.side = Cn) : v.renderBufferDirect(j, k, G, Y, T, Me), T.onAfterRender(v, k, j, G, Y, Me);
|
|
15688
15688
|
}
|
|
15689
|
-
function Fr(
|
|
15689
|
+
function Fr(T, k, j) {
|
|
15690
15690
|
k.isScene !== !0 && (k = Ze);
|
|
15691
|
-
const G = ye.get(
|
|
15691
|
+
const G = ye.get(T), Y = m.state.lights, Me = m.state.shadowsArray, Re = Y.state.version, Ie = W.getParameters(T, Y.state, Me, k, j), Ue = W.getProgramCacheKey(Ie);
|
|
15692
15692
|
let ke = G.programs;
|
|
15693
|
-
G.environment =
|
|
15693
|
+
G.environment = T.isMeshStandardMaterial ? k.environment : null, G.fog = k.fog, G.envMap = (T.isMeshStandardMaterial ? ze : Pe).get(T.envMap || G.environment), ke === void 0 && (T.addEventListener("dispose", fe), ke = /* @__PURE__ */ new Map(), G.programs = ke);
|
|
15694
15694
|
let De = ke.get(Ue);
|
|
15695
15695
|
if (De !== void 0) {
|
|
15696
15696
|
if (G.currentProgram === De && G.lightsStateVersion === Re)
|
|
15697
|
-
return tl(
|
|
15697
|
+
return tl(T, Ie), De;
|
|
15698
15698
|
} else
|
|
15699
|
-
Ie.uniforms = W.getUniforms(
|
|
15699
|
+
Ie.uniforms = W.getUniforms(T), T.onBuild(j, Ie, v), T.onBeforeCompile(Ie, v), De = W.acquireProgram(Ie, Ue), ke.set(Ue, De), G.uniforms = Ie.uniforms;
|
|
15700
15700
|
const Oe = G.uniforms;
|
|
15701
|
-
(!
|
|
15701
|
+
(!T.isShaderMaterial && !T.isRawShaderMaterial || T.clipping === !0) && (Oe.clippingPlanes = Ee.uniform), tl(T, Ie), G.needsLights = xf(T), G.lightsStateVersion = Re, G.needsLights && (Oe.ambientLightColor.value = Y.state.ambient, Oe.lightProbe.value = Y.state.probe, Oe.directionalLights.value = Y.state.directional, Oe.directionalLightShadows.value = Y.state.directionalShadow, Oe.spotLights.value = Y.state.spot, Oe.spotLightShadows.value = Y.state.spotShadow, Oe.rectAreaLights.value = Y.state.rectArea, Oe.ltc_1.value = Y.state.rectAreaLTC1, Oe.ltc_2.value = Y.state.rectAreaLTC2, Oe.pointLights.value = Y.state.point, Oe.pointLightShadows.value = Y.state.pointShadow, Oe.hemisphereLights.value = Y.state.hemi, Oe.directionalShadowMap.value = Y.state.directionalShadowMap, Oe.directionalShadowMatrix.value = Y.state.directionalShadowMatrix, Oe.spotShadowMap.value = Y.state.spotShadowMap, Oe.spotLightMatrix.value = Y.state.spotLightMatrix, Oe.spotLightMap.value = Y.state.spotLightMap, Oe.pointShadowMap.value = Y.state.pointShadowMap, Oe.pointShadowMatrix.value = Y.state.pointShadowMatrix);
|
|
15702
15702
|
const ot = De.getUniforms(), ct = Ss.seqWithValue(ot.seq, Oe);
|
|
15703
15703
|
return G.currentProgram = De, G.uniformsList = ct, De;
|
|
15704
15704
|
}
|
|
15705
|
-
function tl(
|
|
15706
|
-
const j = ye.get(
|
|
15705
|
+
function tl(T, k) {
|
|
15706
|
+
const j = ye.get(T);
|
|
15707
15707
|
j.outputColorSpace = k.outputColorSpace, j.instancing = k.instancing, j.instancingColor = k.instancingColor, j.skinning = k.skinning, j.morphTargets = k.morphTargets, j.morphNormals = k.morphNormals, j.morphColors = k.morphColors, j.morphTargetsCount = k.morphTargetsCount, j.numClippingPlanes = k.numClippingPlanes, j.numIntersection = k.numClipIntersection, j.vertexAlphas = k.vertexAlphas, j.vertexTangents = k.vertexTangents, j.toneMapping = k.toneMapping;
|
|
15708
15708
|
}
|
|
15709
|
-
function _f(
|
|
15709
|
+
function _f(T, k, j, G, Y) {
|
|
15710
15710
|
k.isScene !== !0 && (k = Ze), Se.resetTextureUnits();
|
|
15711
|
-
const Me = k.fog, Re = G.isMeshStandardMaterial ? k.environment : null, Ie =
|
|
15711
|
+
const Me = k.fog, Re = G.isMeshStandardMaterial ? k.environment : null, Ie = w === null ? v.outputColorSpace : w.isXRRenderTarget === !0 ? w.texture.colorSpace : gn, Ue = (G.isMeshStandardMaterial ? ze : Pe).get(G.envMap || Re), ke = G.vertexColors === !0 && !!j.attributes.color && j.attributes.color.itemSize === 4, De = !!j.attributes.tangent && (!!G.normalMap || G.anisotropy > 0), Oe = !!j.morphAttributes.position, ot = !!j.morphAttributes.normal, ct = !!j.morphAttributes.color;
|
|
15712
15712
|
let Wt = Xn;
|
|
15713
|
-
G.toneMapped && (
|
|
15713
|
+
G.toneMapped && (w === null || w.isXRRenderTarget === !0) && (Wt = v.toneMapping);
|
|
15714
15714
|
const yn = j.morphAttributes.position || j.morphAttributes.normal || j.morphAttributes.color, ft = yn !== void 0 ? yn.length : 0, Ge = ye.get(G), Qs = m.state.lights;
|
|
15715
|
-
if (me === !0 && (ge === !0 ||
|
|
15716
|
-
const Bt =
|
|
15717
|
-
Ee.setState(G,
|
|
15715
|
+
if (me === !0 && (ge === !0 || T !== x)) {
|
|
15716
|
+
const Bt = T === x && G.id === N;
|
|
15717
|
+
Ee.setState(G, T, Bt);
|
|
15718
15718
|
}
|
|
15719
15719
|
let dt = !1;
|
|
15720
15720
|
G.version === Ge.__version ? (Ge.needsLights && Ge.lightsStateVersion !== Qs.state.version || Ge.outputColorSpace !== Ie || Y.isInstancedMesh && Ge.instancing === !1 || !Y.isInstancedMesh && Ge.instancing === !0 || Y.isSkinnedMesh && Ge.skinning === !1 || !Y.isSkinnedMesh && Ge.skinning === !0 || Y.isInstancedMesh && Ge.instancingColor === !0 && Y.instanceColor === null || Y.isInstancedMesh && Ge.instancingColor === !1 && Y.instanceColor !== null || Ge.envMap !== Ue || G.fog === !0 && Ge.fog !== Me || Ge.numClippingPlanes !== void 0 && (Ge.numClippingPlanes !== Ee.numPlanes || Ge.numIntersection !== Ee.numIntersection) || Ge.vertexAlphas !== ke || Ge.vertexTangents !== De || Ge.morphTargets !== Oe || Ge.morphNormals !== ot || Ge.morphColors !== ct || Ge.toneMapping !== Wt || ae.isWebGL2 === !0 && Ge.morphTargetsCount !== ft) && (dt = !0) : (dt = !0, Ge.__version = G.version);
|
|
@@ -15722,14 +15722,14 @@ class Ph {
|
|
|
15722
15722
|
dt === !0 && (Zn = Fr(G, k, Y));
|
|
15723
15723
|
let nl = !1, er = !1, eo = !1;
|
|
15724
15724
|
const Rt = Zn.getUniforms(), Jn = Ge.uniforms;
|
|
15725
|
-
if (ne.useProgram(Zn.program) && (nl = !0, er = !0, eo = !0), G.id !== N && (N = G.id, er = !0), nl || x !==
|
|
15726
|
-
Rt.setValue(P, "projectionMatrix",
|
|
15725
|
+
if (ne.useProgram(Zn.program) && (nl = !0, er = !0, eo = !0), G.id !== N && (N = G.id, er = !0), nl || x !== T) {
|
|
15726
|
+
Rt.setValue(P, "projectionMatrix", T.projectionMatrix), Rt.setValue(P, "viewMatrix", T.matrixWorldInverse);
|
|
15727
15727
|
const Bt = Rt.map.cameraPosition;
|
|
15728
|
-
Bt !== void 0 && Bt.setValue(P, Ve.setFromMatrixPosition(
|
|
15728
|
+
Bt !== void 0 && Bt.setValue(P, Ve.setFromMatrixPosition(T.matrixWorld)), ae.logarithmicDepthBuffer && Rt.setValue(
|
|
15729
15729
|
P,
|
|
15730
15730
|
"logDepthBufFC",
|
|
15731
|
-
2 / (Math.log(
|
|
15732
|
-
), (G.isMeshPhongMaterial || G.isMeshToonMaterial || G.isMeshLambertMaterial || G.isMeshBasicMaterial || G.isMeshStandardMaterial || G.isShaderMaterial) && Rt.setValue(P, "isOrthographic",
|
|
15731
|
+
2 / (Math.log(T.far + 1) / Math.LN2)
|
|
15732
|
+
), (G.isMeshPhongMaterial || G.isMeshToonMaterial || G.isMeshLambertMaterial || G.isMeshBasicMaterial || G.isMeshStandardMaterial || G.isShaderMaterial) && Rt.setValue(P, "isOrthographic", T.isOrthographicCamera === !0), x !== T && (x = T, er = !0, eo = !0);
|
|
15733
15733
|
}
|
|
15734
15734
|
if (Y.isSkinnedMesh) {
|
|
15735
15735
|
Rt.setOptional(P, Y, "bindMatrix"), Rt.setOptional(P, Y, "bindMatrixInverse");
|
|
@@ -15748,55 +15748,55 @@ class Ph {
|
|
|
15748
15748
|
}
|
|
15749
15749
|
return Zn;
|
|
15750
15750
|
}
|
|
15751
|
-
function vf(
|
|
15752
|
-
|
|
15751
|
+
function vf(T, k) {
|
|
15752
|
+
T.ambientLightColor.needsUpdate = k, T.lightProbe.needsUpdate = k, T.directionalLights.needsUpdate = k, T.directionalLightShadows.needsUpdate = k, T.pointLights.needsUpdate = k, T.pointLightShadows.needsUpdate = k, T.spotLights.needsUpdate = k, T.spotLightShadows.needsUpdate = k, T.rectAreaLights.needsUpdate = k, T.hemisphereLights.needsUpdate = k;
|
|
15753
15753
|
}
|
|
15754
|
-
function xf(
|
|
15755
|
-
return
|
|
15754
|
+
function xf(T) {
|
|
15755
|
+
return T.isMeshLambertMaterial || T.isMeshToonMaterial || T.isMeshPhongMaterial || T.isMeshStandardMaterial || T.isShadowMaterial || T.isShaderMaterial && T.lights === !0;
|
|
15756
15756
|
}
|
|
15757
15757
|
this.getActiveCubeFace = function() {
|
|
15758
15758
|
return b;
|
|
15759
15759
|
}, this.getActiveMipmapLevel = function() {
|
|
15760
15760
|
return R;
|
|
15761
15761
|
}, this.getRenderTarget = function() {
|
|
15762
|
-
return
|
|
15763
|
-
}, this.setRenderTargetTextures = function(
|
|
15764
|
-
ye.get(
|
|
15765
|
-
const G = ye.get(
|
|
15762
|
+
return w;
|
|
15763
|
+
}, this.setRenderTargetTextures = function(T, k, j) {
|
|
15764
|
+
ye.get(T.texture).__webglTexture = k, ye.get(T.depthTexture).__webglTexture = j;
|
|
15765
|
+
const G = ye.get(T);
|
|
15766
15766
|
G.__hasExternalTextures = !0, G.__hasExternalTextures && (G.__autoAllocateDepthBuffer = j === void 0, G.__autoAllocateDepthBuffer || J.has("WEBGL_multisampled_render_to_texture") === !0 && (console.warn("THREE.WebGLRenderer: Render-to-texture extension was disabled because an external texture was provided"), G.__useRenderToTexture = !1));
|
|
15767
|
-
}, this.setRenderTargetFramebuffer = function(
|
|
15768
|
-
const j = ye.get(
|
|
15767
|
+
}, this.setRenderTargetFramebuffer = function(T, k) {
|
|
15768
|
+
const j = ye.get(T);
|
|
15769
15769
|
j.__webglFramebuffer = k, j.__useDefaultFramebuffer = k === void 0;
|
|
15770
|
-
}, this.setRenderTarget = function(
|
|
15771
|
-
|
|
15770
|
+
}, this.setRenderTarget = function(T, k = 0, j = 0) {
|
|
15771
|
+
w = T, b = k, R = j;
|
|
15772
15772
|
let G = !0, Y = null, Me = !1, Re = !1;
|
|
15773
|
-
if (
|
|
15774
|
-
const Ue = ye.get(
|
|
15775
|
-
Ue.__useDefaultFramebuffer !== void 0 ? (ne.bindFramebuffer(P.FRAMEBUFFER, null), G = !1) : Ue.__webglFramebuffer === void 0 ? Se.setupRenderTarget(
|
|
15776
|
-
const ke =
|
|
15773
|
+
if (T) {
|
|
15774
|
+
const Ue = ye.get(T);
|
|
15775
|
+
Ue.__useDefaultFramebuffer !== void 0 ? (ne.bindFramebuffer(P.FRAMEBUFFER, null), G = !1) : Ue.__webglFramebuffer === void 0 ? Se.setupRenderTarget(T) : Ue.__hasExternalTextures && Se.rebindTextures(T, ye.get(T.texture).__webglTexture, ye.get(T.depthTexture).__webglTexture);
|
|
15776
|
+
const ke = T.texture;
|
|
15777
15777
|
(ke.isData3DTexture || ke.isDataArrayTexture || ke.isCompressedArrayTexture) && (Re = !0);
|
|
15778
|
-
const De = ye.get(
|
|
15779
|
-
|
|
15778
|
+
const De = ye.get(T).__webglFramebuffer;
|
|
15779
|
+
T.isWebGLCubeRenderTarget ? (Array.isArray(De[k]) ? Y = De[k][j] : Y = De[k], Me = !0) : ae.isWebGL2 && T.samples > 0 && Se.useMultisampledRTT(T) === !1 ? Y = ye.get(T).__webglMultisampledFramebuffer : Array.isArray(De) ? Y = De[j] : Y = De, E.copy(T.viewport), F.copy(T.scissor), ee = T.scissorTest;
|
|
15780
15780
|
} else
|
|
15781
15781
|
E.copy(Q).multiplyScalar(H).floor(), F.copy(B).multiplyScalar(H).floor(), ee = q;
|
|
15782
|
-
if (ne.bindFramebuffer(P.FRAMEBUFFER, Y) && ae.drawBuffers && G && ne.drawBuffers(
|
|
15783
|
-
const Ue = ye.get(
|
|
15782
|
+
if (ne.bindFramebuffer(P.FRAMEBUFFER, Y) && ae.drawBuffers && G && ne.drawBuffers(T, Y), ne.viewport(E), ne.scissor(F), ne.setScissorTest(ee), Me) {
|
|
15783
|
+
const Ue = ye.get(T.texture);
|
|
15784
15784
|
P.framebufferTexture2D(P.FRAMEBUFFER, P.COLOR_ATTACHMENT0, P.TEXTURE_CUBE_MAP_POSITIVE_X + k, Ue.__webglTexture, j);
|
|
15785
15785
|
} else if (Re) {
|
|
15786
|
-
const Ue = ye.get(
|
|
15786
|
+
const Ue = ye.get(T.texture), ke = k || 0;
|
|
15787
15787
|
P.framebufferTextureLayer(P.FRAMEBUFFER, P.COLOR_ATTACHMENT0, Ue.__webglTexture, j || 0, ke);
|
|
15788
15788
|
}
|
|
15789
15789
|
N = -1;
|
|
15790
|
-
}, this.readRenderTargetPixels = function(
|
|
15791
|
-
if (!(
|
|
15790
|
+
}, this.readRenderTargetPixels = function(T, k, j, G, Y, Me, Re) {
|
|
15791
|
+
if (!(T && T.isWebGLRenderTarget)) {
|
|
15792
15792
|
console.error("THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not THREE.WebGLRenderTarget.");
|
|
15793
15793
|
return;
|
|
15794
15794
|
}
|
|
15795
|
-
let Ie = ye.get(
|
|
15796
|
-
if (
|
|
15795
|
+
let Ie = ye.get(T).__webglFramebuffer;
|
|
15796
|
+
if (T.isWebGLCubeRenderTarget && Re !== void 0 && (Ie = Ie[Re]), Ie) {
|
|
15797
15797
|
ne.bindFramebuffer(P.FRAMEBUFFER, Ie);
|
|
15798
15798
|
try {
|
|
15799
|
-
const Ue =
|
|
15799
|
+
const Ue = T.texture, ke = Ue.format, De = Ue.type;
|
|
15800
15800
|
if (ke !== rn && pe.convert(ke) !== P.getParameter(P.IMPLEMENTATION_COLOR_READ_FORMAT)) {
|
|
15801
15801
|
console.error("THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not in RGBA or implementation defined format.");
|
|
15802
15802
|
return;
|
|
@@ -15808,24 +15808,24 @@ class Ph {
|
|
|
15808
15808
|
console.error("THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not in UnsignedByteType or implementation defined type.");
|
|
15809
15809
|
return;
|
|
15810
15810
|
}
|
|
15811
|
-
k >= 0 && k <=
|
|
15811
|
+
k >= 0 && k <= T.width - G && j >= 0 && j <= T.height - Y && P.readPixels(k, j, G, Y, pe.convert(ke), pe.convert(De), Me);
|
|
15812
15812
|
} finally {
|
|
15813
|
-
const Ue =
|
|
15813
|
+
const Ue = w !== null ? ye.get(w).__webglFramebuffer : null;
|
|
15814
15814
|
ne.bindFramebuffer(P.FRAMEBUFFER, Ue);
|
|
15815
15815
|
}
|
|
15816
15816
|
}
|
|
15817
|
-
}, this.copyFramebufferToTexture = function(
|
|
15817
|
+
}, this.copyFramebufferToTexture = function(T, k, j = 0) {
|
|
15818
15818
|
const G = Math.pow(2, -j), Y = Math.floor(k.image.width * G), Me = Math.floor(k.image.height * G);
|
|
15819
|
-
Se.setTexture2D(k, 0), P.copyTexSubImage2D(P.TEXTURE_2D, j, 0, 0,
|
|
15820
|
-
}, this.copyTextureToTexture = function(
|
|
15819
|
+
Se.setTexture2D(k, 0), P.copyTexSubImage2D(P.TEXTURE_2D, j, 0, 0, T.x, T.y, Y, Me), ne.unbindTexture();
|
|
15820
|
+
}, this.copyTextureToTexture = function(T, k, j, G = 0) {
|
|
15821
15821
|
const Y = k.image.width, Me = k.image.height, Re = pe.convert(j.format), Ie = pe.convert(j.type);
|
|
15822
|
-
Se.setTexture2D(j, 0), P.pixelStorei(P.UNPACK_FLIP_Y_WEBGL, j.flipY), P.pixelStorei(P.UNPACK_PREMULTIPLY_ALPHA_WEBGL, j.premultiplyAlpha), P.pixelStorei(P.UNPACK_ALIGNMENT, j.unpackAlignment), k.isDataTexture ? P.texSubImage2D(P.TEXTURE_2D, G,
|
|
15823
|
-
}, this.copyTextureToTexture3D = function(
|
|
15822
|
+
Se.setTexture2D(j, 0), P.pixelStorei(P.UNPACK_FLIP_Y_WEBGL, j.flipY), P.pixelStorei(P.UNPACK_PREMULTIPLY_ALPHA_WEBGL, j.premultiplyAlpha), P.pixelStorei(P.UNPACK_ALIGNMENT, j.unpackAlignment), k.isDataTexture ? P.texSubImage2D(P.TEXTURE_2D, G, T.x, T.y, Y, Me, Re, Ie, k.image.data) : k.isCompressedTexture ? P.compressedTexSubImage2D(P.TEXTURE_2D, G, T.x, T.y, k.mipmaps[0].width, k.mipmaps[0].height, Re, k.mipmaps[0].data) : P.texSubImage2D(P.TEXTURE_2D, G, T.x, T.y, Re, Ie, k.image), G === 0 && j.generateMipmaps && P.generateMipmap(P.TEXTURE_2D), ne.unbindTexture();
|
|
15823
|
+
}, this.copyTextureToTexture3D = function(T, k, j, G, Y = 0) {
|
|
15824
15824
|
if (v.isWebGL1Renderer) {
|
|
15825
15825
|
console.warn("THREE.WebGLRenderer.copyTextureToTexture3D: can only be used with WebGL2.");
|
|
15826
15826
|
return;
|
|
15827
15827
|
}
|
|
15828
|
-
const Me =
|
|
15828
|
+
const Me = T.max.x - T.min.x + 1, Re = T.max.y - T.min.y + 1, Ie = T.max.z - T.min.z + 1, Ue = pe.convert(G.format), ke = pe.convert(G.type);
|
|
15829
15829
|
let De;
|
|
15830
15830
|
if (G.isData3DTexture)
|
|
15831
15831
|
Se.setTexture3D(G, 0), De = P.TEXTURE_3D;
|
|
@@ -15837,11 +15837,11 @@ class Ph {
|
|
|
15837
15837
|
}
|
|
15838
15838
|
P.pixelStorei(P.UNPACK_FLIP_Y_WEBGL, G.flipY), P.pixelStorei(P.UNPACK_PREMULTIPLY_ALPHA_WEBGL, G.premultiplyAlpha), P.pixelStorei(P.UNPACK_ALIGNMENT, G.unpackAlignment);
|
|
15839
15839
|
const Oe = P.getParameter(P.UNPACK_ROW_LENGTH), ot = P.getParameter(P.UNPACK_IMAGE_HEIGHT), ct = P.getParameter(P.UNPACK_SKIP_PIXELS), Wt = P.getParameter(P.UNPACK_SKIP_ROWS), yn = P.getParameter(P.UNPACK_SKIP_IMAGES), ft = j.isCompressedTexture ? j.mipmaps[0] : j.image;
|
|
15840
|
-
P.pixelStorei(P.UNPACK_ROW_LENGTH, ft.width), P.pixelStorei(P.UNPACK_IMAGE_HEIGHT, ft.height), P.pixelStorei(P.UNPACK_SKIP_PIXELS,
|
|
15841
|
-
}, this.initTexture = function(
|
|
15842
|
-
|
|
15840
|
+
P.pixelStorei(P.UNPACK_ROW_LENGTH, ft.width), P.pixelStorei(P.UNPACK_IMAGE_HEIGHT, ft.height), P.pixelStorei(P.UNPACK_SKIP_PIXELS, T.min.x), P.pixelStorei(P.UNPACK_SKIP_ROWS, T.min.y), P.pixelStorei(P.UNPACK_SKIP_IMAGES, T.min.z), j.isDataTexture || j.isData3DTexture ? P.texSubImage3D(De, Y, k.x, k.y, k.z, Me, Re, Ie, Ue, ke, ft.data) : j.isCompressedArrayTexture ? (console.warn("THREE.WebGLRenderer.copyTextureToTexture3D: untested support for compressed srcTexture."), P.compressedTexSubImage3D(De, Y, k.x, k.y, k.z, Me, Re, Ie, Ue, ft.data)) : P.texSubImage3D(De, Y, k.x, k.y, k.z, Me, Re, Ie, Ue, ke, ft), P.pixelStorei(P.UNPACK_ROW_LENGTH, Oe), P.pixelStorei(P.UNPACK_IMAGE_HEIGHT, ot), P.pixelStorei(P.UNPACK_SKIP_PIXELS, ct), P.pixelStorei(P.UNPACK_SKIP_ROWS, Wt), P.pixelStorei(P.UNPACK_SKIP_IMAGES, yn), Y === 0 && G.generateMipmaps && P.generateMipmap(De), ne.unbindTexture();
|
|
15841
|
+
}, this.initTexture = function(T) {
|
|
15842
|
+
T.isCubeTexture ? Se.setTextureCube(T, 0) : T.isData3DTexture ? Se.setTexture3D(T, 0) : T.isDataArrayTexture || T.isCompressedArrayTexture ? Se.setTexture2DArray(T, 0) : Se.setTexture2D(T, 0), ne.unbindTexture();
|
|
15843
15843
|
}, this.resetState = function() {
|
|
15844
|
-
b = 0, R = 0,
|
|
15844
|
+
b = 0, R = 0, w = null, ne.reset(), ve.reset();
|
|
15845
15845
|
}, typeof __THREE_DEVTOOLS__ != "undefined" && __THREE_DEVTOOLS__.dispatchEvent(new CustomEvent("observe", { detail: this }));
|
|
15846
15846
|
}
|
|
15847
15847
|
get coordinateSystem() {
|
|
@@ -16734,13 +16734,13 @@ const cy = {
|
|
|
16734
16734
|
};
|
|
16735
16735
|
function Oh(n, e, t, i, r) {
|
|
16736
16736
|
let s, o;
|
|
16737
|
-
if (r ===
|
|
16737
|
+
if (r === Ty(n, e, t, i) > 0)
|
|
16738
16738
|
for (s = e; s < t; s += i)
|
|
16739
16739
|
o = Yc(s, n[s], n[s + 1], o);
|
|
16740
16740
|
else
|
|
16741
16741
|
for (s = t - i; s >= e; s -= i)
|
|
16742
16742
|
o = Yc(s, n[s], n[s + 1], o);
|
|
16743
|
-
return o && $s(o, o.next) && (
|
|
16743
|
+
return o && $s(o, o.next) && (Tr(o), o = o.next), o;
|
|
16744
16744
|
}
|
|
16745
16745
|
function mi(n, e) {
|
|
16746
16746
|
if (!n)
|
|
@@ -16749,7 +16749,7 @@ function mi(n, e) {
|
|
|
16749
16749
|
let t = n, i;
|
|
16750
16750
|
do
|
|
16751
16751
|
if (i = !1, !t.steiner && ($s(t, t.next) || st(t.prev, t, t.next) === 0)) {
|
|
16752
|
-
if (
|
|
16752
|
+
if (Tr(t), t = e = t.prev, t === t.next)
|
|
16753
16753
|
break;
|
|
16754
16754
|
i = !0;
|
|
16755
16755
|
} else
|
|
@@ -16764,7 +16764,7 @@ function Er(n, e, t, i, r, s, o) {
|
|
|
16764
16764
|
let a = n, l, c;
|
|
16765
16765
|
for (; n.prev !== n.next; ) {
|
|
16766
16766
|
if (l = n.prev, c = n.next, s ? hy(n, i, r, s) : uy(n)) {
|
|
16767
|
-
e.push(l.i / t | 0), e.push(n.i / t | 0), e.push(c.i / t | 0),
|
|
16767
|
+
e.push(l.i / t | 0), e.push(n.i / t | 0), e.push(c.i / t | 0), Tr(n), n = c.next, a = c.next;
|
|
16768
16768
|
continue;
|
|
16769
16769
|
}
|
|
16770
16770
|
if (n = c, n === a) {
|
|
@@ -16813,7 +16813,7 @@ function fy(n, e, t) {
|
|
|
16813
16813
|
let i = n;
|
|
16814
16814
|
do {
|
|
16815
16815
|
const r = i.prev, s = i.next.next;
|
|
16816
|
-
!$s(r, s) && Fh(r, i, i.next, s) && br(r, s) && br(s, r) && (e.push(r.i / t | 0), e.push(i.i / t | 0), e.push(s.i / t | 0),
|
|
16816
|
+
!$s(r, s) && Fh(r, i, i.next, s) && br(r, s) && br(s, r) && (e.push(r.i / t | 0), e.push(i.i / t | 0), e.push(s.i / t | 0), Tr(i), Tr(i.next), i = n = s), i = i.next;
|
|
16817
16817
|
} while (i !== n);
|
|
16818
16818
|
return mi(i);
|
|
16819
16819
|
}
|
|
@@ -16959,13 +16959,13 @@ function Yc(n, e, t, i) {
|
|
|
16959
16959
|
const r = new ua(n, e, t);
|
|
16960
16960
|
return i ? (r.next = i.next, r.prev = i, i.next.prev = r, i.next = r) : (r.prev = r, r.next = r), r;
|
|
16961
16961
|
}
|
|
16962
|
-
function
|
|
16962
|
+
function Tr(n) {
|
|
16963
16963
|
n.next.prev = n.prev, n.prev.next = n.next, n.prevZ && (n.prevZ.nextZ = n.nextZ), n.nextZ && (n.nextZ.prevZ = n.prevZ);
|
|
16964
16964
|
}
|
|
16965
16965
|
function ua(n, e, t) {
|
|
16966
16966
|
this.i = n, this.x = e, this.y = t, this.prev = null, this.next = null, this.z = 0, this.prevZ = null, this.nextZ = null, this.steiner = !1;
|
|
16967
16967
|
}
|
|
16968
|
-
function
|
|
16968
|
+
function Ty(n, e, t, i) {
|
|
16969
16969
|
let r = 0;
|
|
16970
16970
|
for (let s = e, o = t - i; s < t; s += i)
|
|
16971
16971
|
r += (n[o] - n[s]) * (n[s + 1] + n[o + 1]), o = s;
|
|
@@ -17019,9 +17019,9 @@ class ka extends _n {
|
|
|
17019
17019
|
function o(a) {
|
|
17020
17020
|
const l = [], c = t.curveSegments !== void 0 ? t.curveSegments : 12, u = t.steps !== void 0 ? t.steps : 1, h = t.depth !== void 0 ? t.depth : 1;
|
|
17021
17021
|
let f = t.bevelEnabled !== void 0 ? t.bevelEnabled : !0, d = t.bevelThickness !== void 0 ? t.bevelThickness : 0.2, g = t.bevelSize !== void 0 ? t.bevelSize : d - 0.1, _ = t.bevelOffset !== void 0 ? t.bevelOffset : 0, m = t.bevelSegments !== void 0 ? t.bevelSegments : 3;
|
|
17022
|
-
const p = t.extrudePath, S = t.UVGenerator !== void 0 ? t.UVGenerator :
|
|
17023
|
-
let v, M = !1, b, R,
|
|
17024
|
-
p && (v = p.getSpacedPoints(u), M = !0, f = !1, b = p.computeFrenetFrames(u, !1), R = new D(),
|
|
17022
|
+
const p = t.extrudePath, S = t.UVGenerator !== void 0 ? t.UVGenerator : wy;
|
|
17023
|
+
let v, M = !1, b, R, w, N;
|
|
17024
|
+
p && (v = p.getSpacedPoints(u), M = !0, f = !1, b = p.computeFrenetFrames(u, !1), R = new D(), w = new D(), N = new D()), f || (m = 0, d = 0, g = 0, _ = 0);
|
|
17025
17025
|
const x = a.extractPoints(c);
|
|
17026
17026
|
let E = x.shape;
|
|
17027
17027
|
const F = x.holes;
|
|
@@ -17073,39 +17073,39 @@ class ka extends _n {
|
|
|
17073
17073
|
const he = P / m, J = d * Math.cos(he * Math.PI / 2), ae = g * Math.sin(he * Math.PI / 2) + _;
|
|
17074
17074
|
for (let ne = 0, be = U.length; ne < be; ne++) {
|
|
17075
17075
|
const ye = C(U[ne], K[ne], ae);
|
|
17076
|
-
|
|
17076
|
+
we(ye.x, ye.y, -J);
|
|
17077
17077
|
}
|
|
17078
17078
|
for (let ne = 0, be = F.length; ne < be; ne++) {
|
|
17079
17079
|
const ye = F[ne];
|
|
17080
17080
|
B = Q[ne];
|
|
17081
17081
|
for (let Se = 0, Pe = ye.length; Se < Pe; Se++) {
|
|
17082
17082
|
const ze = C(ye[Se], B[Se], ae);
|
|
17083
|
-
|
|
17083
|
+
we(ze.x, ze.y, -J);
|
|
17084
17084
|
}
|
|
17085
17085
|
}
|
|
17086
17086
|
}
|
|
17087
17087
|
const oe = g + _;
|
|
17088
17088
|
for (let P = 0; P < z; P++) {
|
|
17089
17089
|
const he = f ? C(E[P], q[P], oe) : E[P];
|
|
17090
|
-
M ? (
|
|
17090
|
+
M ? (w.copy(b.normals[0]).multiplyScalar(he.x), R.copy(b.binormals[0]).multiplyScalar(he.y), N.copy(v[0]).add(w).add(R), we(N.x, N.y, N.z)) : we(he.x, he.y, 0);
|
|
17091
17091
|
}
|
|
17092
17092
|
for (let P = 1; P <= u; P++)
|
|
17093
17093
|
for (let he = 0; he < z; he++) {
|
|
17094
17094
|
const J = f ? C(E[he], q[he], oe) : E[he];
|
|
17095
|
-
M ? (
|
|
17095
|
+
M ? (w.copy(b.normals[P]).multiplyScalar(J.x), R.copy(b.binormals[P]).multiplyScalar(J.y), N.copy(v[P]).add(w).add(R), we(N.x, N.y, N.z)) : we(J.x, J.y, h / u * P);
|
|
17096
17096
|
}
|
|
17097
17097
|
for (let P = m - 1; P >= 0; P--) {
|
|
17098
17098
|
const he = P / m, J = d * Math.cos(he * Math.PI / 2), ae = g * Math.sin(he * Math.PI / 2) + _;
|
|
17099
17099
|
for (let ne = 0, be = U.length; ne < be; ne++) {
|
|
17100
17100
|
const ye = C(U[ne], K[ne], ae);
|
|
17101
|
-
|
|
17101
|
+
we(ye.x, ye.y, h + J);
|
|
17102
17102
|
}
|
|
17103
17103
|
for (let ne = 0, be = F.length; ne < be; ne++) {
|
|
17104
17104
|
const ye = F[ne];
|
|
17105
17105
|
B = Q[ne];
|
|
17106
17106
|
for (let Se = 0, Pe = ye.length; Se < Pe; Se++) {
|
|
17107
17107
|
const ze = C(ye[Se], B[Se], ae);
|
|
17108
|
-
M ?
|
|
17108
|
+
M ? we(ze.x, ze.y + v[u - 1].y, v[u - 1].x + J) : we(ze.x, ze.y, h + J);
|
|
17109
17109
|
}
|
|
17110
17110
|
}
|
|
17111
17111
|
}
|
|
@@ -17116,21 +17116,21 @@ class ka extends _n {
|
|
|
17116
17116
|
let he = 0, J = z * he;
|
|
17117
17117
|
for (let ae = 0; ae < H; ae++) {
|
|
17118
17118
|
const ne = O[ae];
|
|
17119
|
-
|
|
17119
|
+
Te(ne[2] + J, ne[1] + J, ne[0] + J);
|
|
17120
17120
|
}
|
|
17121
17121
|
he = u + m * 2, J = z * he;
|
|
17122
17122
|
for (let ae = 0; ae < H; ae++) {
|
|
17123
17123
|
const ne = O[ae];
|
|
17124
|
-
|
|
17124
|
+
Te(ne[0] + J, ne[1] + J, ne[2] + J);
|
|
17125
17125
|
}
|
|
17126
17126
|
} else {
|
|
17127
17127
|
for (let he = 0; he < H; he++) {
|
|
17128
17128
|
const J = O[he];
|
|
17129
|
-
|
|
17129
|
+
Te(J[2], J[1], J[0]);
|
|
17130
17130
|
}
|
|
17131
17131
|
for (let he = 0; he < H; he++) {
|
|
17132
17132
|
const J = O[he];
|
|
17133
|
-
|
|
17133
|
+
Te(J[0] + z * u, J[1] + z * u, J[2] + z * u);
|
|
17134
17134
|
}
|
|
17135
17135
|
}
|
|
17136
17136
|
i.addGroup(P, r.length / 3 - P, 0);
|
|
@@ -17157,10 +17157,10 @@ class ka extends _n {
|
|
|
17157
17157
|
}
|
|
17158
17158
|
}
|
|
17159
17159
|
}
|
|
17160
|
-
function
|
|
17160
|
+
function we(P, he, J) {
|
|
17161
17161
|
l.push(P), l.push(he), l.push(J);
|
|
17162
17162
|
}
|
|
17163
|
-
function
|
|
17163
|
+
function Te(P, he, J) {
|
|
17164
17164
|
Ze(P), Ze(he), Ze(J);
|
|
17165
17165
|
const ae = r.length / 3, ne = S.generateTopUV(i, r, ae - 3, ae - 2, ae - 1);
|
|
17166
17166
|
Ce(ne[0]), Ce(ne[1]), Ce(ne[2]);
|
|
@@ -17195,7 +17195,7 @@ class ka extends _n {
|
|
|
17195
17195
|
return r !== void 0 && (e.options.extrudePath = new Uh[r.type]().fromJSON(r)), new ka(i, e.options);
|
|
17196
17196
|
}
|
|
17197
17197
|
}
|
|
17198
|
-
const
|
|
17198
|
+
const wy = {
|
|
17199
17199
|
generateTopUV: function(n, e, t, i, r) {
|
|
17200
17200
|
const s = e[t * 3], o = e[t * 3 + 1], a = e[i * 3], l = e[i * 3 + 1], c = e[r * 3], u = e[r * 3 + 1];
|
|
17201
17201
|
return [
|
|
@@ -17607,7 +17607,7 @@ class By extends gi {
|
|
|
17607
17607
|
let c = 1;
|
|
17608
17608
|
const u = new D(), h = new ue(), f = new ue(), d = new ue(), g = new ue(), _ = new ue(), m = new ue(), p = new ue(), S = new ue(), v = new ue(), M = new D(), b = new ue();
|
|
17609
17609
|
let R = !1;
|
|
17610
|
-
const
|
|
17610
|
+
const w = [], N = {};
|
|
17611
17611
|
function x(L) {
|
|
17612
17612
|
return L !== null ? 2 * Math.PI / 60 * i.autoRotateSpeed * L : 2 * Math.PI / 60 / 60 * i.autoRotateSpeed;
|
|
17613
17613
|
}
|
|
@@ -17682,7 +17682,7 @@ class By extends gi {
|
|
|
17682
17682
|
function Ae(L) {
|
|
17683
17683
|
V(L), L.deltaY < 0 ? H(E()) : L.deltaY > 0 && z(E()), i.update();
|
|
17684
17684
|
}
|
|
17685
|
-
function
|
|
17685
|
+
function we(L) {
|
|
17686
17686
|
let te = !1;
|
|
17687
17687
|
switch (L.code) {
|
|
17688
17688
|
case i.keys.UP:
|
|
@@ -17700,34 +17700,34 @@ class By extends gi {
|
|
|
17700
17700
|
}
|
|
17701
17701
|
te && (L.preventDefault(), i.update());
|
|
17702
17702
|
}
|
|
17703
|
-
function
|
|
17704
|
-
if (
|
|
17705
|
-
h.set(
|
|
17703
|
+
function Te() {
|
|
17704
|
+
if (w.length === 1)
|
|
17705
|
+
h.set(w[0].pageX, w[0].pageY);
|
|
17706
17706
|
else {
|
|
17707
|
-
const L = 0.5 * (
|
|
17707
|
+
const L = 0.5 * (w[0].pageX + w[1].pageX), te = 0.5 * (w[0].pageY + w[1].pageY);
|
|
17708
17708
|
h.set(L, te);
|
|
17709
17709
|
}
|
|
17710
17710
|
}
|
|
17711
17711
|
function Ve() {
|
|
17712
|
-
if (
|
|
17713
|
-
g.set(
|
|
17712
|
+
if (w.length === 1)
|
|
17713
|
+
g.set(w[0].pageX, w[0].pageY);
|
|
17714
17714
|
else {
|
|
17715
|
-
const L = 0.5 * (
|
|
17715
|
+
const L = 0.5 * (w[0].pageX + w[1].pageX), te = 0.5 * (w[0].pageY + w[1].pageY);
|
|
17716
17716
|
g.set(L, te);
|
|
17717
17717
|
}
|
|
17718
17718
|
}
|
|
17719
17719
|
function Ze() {
|
|
17720
|
-
const L =
|
|
17720
|
+
const L = w[0].pageX - w[1].pageX, te = w[0].pageY - w[1].pageY, xe = Math.sqrt(L * L + te * te);
|
|
17721
17721
|
p.set(0, xe);
|
|
17722
17722
|
}
|
|
17723
17723
|
function Ce() {
|
|
17724
17724
|
i.enableZoom && Ze(), i.enablePan && Ve();
|
|
17725
17725
|
}
|
|
17726
17726
|
function P() {
|
|
17727
|
-
i.enableZoom && Ze(), i.enableRotate &&
|
|
17727
|
+
i.enableZoom && Ze(), i.enableRotate && Te();
|
|
17728
17728
|
}
|
|
17729
17729
|
function he(L) {
|
|
17730
|
-
if (
|
|
17730
|
+
if (w.length == 1)
|
|
17731
17731
|
f.set(L.pageX, L.pageY);
|
|
17732
17732
|
else {
|
|
17733
17733
|
const xe = X(L), pe = 0.5 * (L.pageX + xe.x), ve = 0.5 * (L.pageY + xe.y);
|
|
@@ -17738,7 +17738,7 @@ class By extends gi {
|
|
|
17738
17738
|
F(2 * Math.PI * d.x / te.clientHeight), ee(2 * Math.PI * d.y / te.clientHeight), h.copy(f);
|
|
17739
17739
|
}
|
|
17740
17740
|
function J(L) {
|
|
17741
|
-
if (
|
|
17741
|
+
if (w.length === 1)
|
|
17742
17742
|
_.set(L.pageX, L.pageY);
|
|
17743
17743
|
else {
|
|
17744
17744
|
const te = X(L), xe = 0.5 * (L.pageX + te.x), pe = 0.5 * (L.pageY + te.y);
|
|
@@ -17757,13 +17757,13 @@ class By extends gi {
|
|
|
17757
17757
|
i.enableZoom && ae(L), i.enableRotate && he(L);
|
|
17758
17758
|
}
|
|
17759
17759
|
function ye(L) {
|
|
17760
|
-
i.enabled !== !1 && (
|
|
17760
|
+
i.enabled !== !1 && (w.length === 0 && (i.domElement.setPointerCapture(L.pointerId), i.domElement.addEventListener("pointermove", Se), i.domElement.addEventListener("pointerup", Pe)), le(L), L.pointerType === "touch" ? W(L) : ze(L));
|
|
17761
17761
|
}
|
|
17762
17762
|
function Se(L) {
|
|
17763
17763
|
i.enabled !== !1 && (L.pointerType === "touch" ? se(L) : tt(L));
|
|
17764
17764
|
}
|
|
17765
17765
|
function Pe(L) {
|
|
17766
|
-
Ee(L),
|
|
17766
|
+
Ee(L), w.length === 0 && (i.domElement.releasePointerCapture(L.pointerId), i.domElement.removeEventListener("pointermove", Se), i.domElement.removeEventListener("pointerup", Pe)), i.dispatchEvent(ou), s = r.NONE;
|
|
17767
17767
|
}
|
|
17768
17768
|
function ze(L) {
|
|
17769
17769
|
let te;
|
|
@@ -17836,16 +17836,16 @@ class By extends gi {
|
|
|
17836
17836
|
i.enabled === !1 || i.enableZoom === !1 || s !== r.NONE || (L.preventDefault(), i.dispatchEvent(zo), Ae(L), i.dispatchEvent(ou));
|
|
17837
17837
|
}
|
|
17838
17838
|
function y(L) {
|
|
17839
|
-
i.enabled === !1 || i.enablePan === !1 ||
|
|
17839
|
+
i.enabled === !1 || i.enablePan === !1 || we(L);
|
|
17840
17840
|
}
|
|
17841
17841
|
function W(L) {
|
|
17842
|
-
switch (ce(L),
|
|
17842
|
+
switch (ce(L), w.length) {
|
|
17843
17843
|
case 1:
|
|
17844
17844
|
switch (i.touches.ONE) {
|
|
17845
17845
|
case _i.ROTATE:
|
|
17846
17846
|
if (i.enableRotate === !1)
|
|
17847
17847
|
return;
|
|
17848
|
-
|
|
17848
|
+
Te(), s = r.TOUCH_ROTATE;
|
|
17849
17849
|
break;
|
|
17850
17850
|
case _i.PAN:
|
|
17851
17851
|
if (i.enablePan === !1)
|
|
@@ -17907,13 +17907,13 @@ class By extends gi {
|
|
|
17907
17907
|
i.enabled !== !1 && L.preventDefault();
|
|
17908
17908
|
}
|
|
17909
17909
|
function le(L) {
|
|
17910
|
-
|
|
17910
|
+
w.push(L);
|
|
17911
17911
|
}
|
|
17912
17912
|
function Ee(L) {
|
|
17913
17913
|
delete N[L.pointerId];
|
|
17914
|
-
for (let te = 0; te <
|
|
17915
|
-
if (
|
|
17916
|
-
|
|
17914
|
+
for (let te = 0; te < w.length; te++)
|
|
17915
|
+
if (w[te].pointerId == L.pointerId) {
|
|
17916
|
+
w.splice(te, 1);
|
|
17917
17917
|
return;
|
|
17918
17918
|
}
|
|
17919
17919
|
}
|
|
@@ -17922,7 +17922,7 @@ class By extends gi {
|
|
|
17922
17922
|
te === void 0 && (te = new ue(), N[L.pointerId] = te), te.set(L.pageX, L.pageY);
|
|
17923
17923
|
}
|
|
17924
17924
|
function X(L) {
|
|
17925
|
-
const te = L.pointerId ===
|
|
17925
|
+
const te = L.pointerId === w[0].pointerId ? w[1] : w[0];
|
|
17926
17926
|
return N[te.pointerId];
|
|
17927
17927
|
}
|
|
17928
17928
|
i.domElement.addEventListener("contextmenu", ie), i.domElement.addEventListener("pointerdown", ye), i.domElement.addEventListener("pointercancel", Pe), i.domElement.addEventListener("wheel", A, { passive: !1 }), this.update();
|
|
@@ -18730,7 +18730,7 @@ function* Xy(n) {
|
|
|
18730
18730
|
function kh(n) {
|
|
18731
18731
|
return Array.from(Xy(n));
|
|
18732
18732
|
}
|
|
18733
|
-
var Qe = 1e-6, $y = 1e-12, Xe = Math.PI, Nt = Xe / 2, _u = Xe / 4, Kt = Xe * 2, Gt = 180 / Xe, mt = Xe / 180, lt = Math.abs, Gh = Math.atan,
|
|
18733
|
+
var Qe = 1e-6, $y = 1e-12, Xe = Math.PI, Nt = Xe / 2, _u = Xe / 4, Kt = Xe * 2, Gt = 180 / Xe, mt = Xe / 180, lt = Math.abs, Gh = Math.atan, wr = Math.atan2, ut = Math.cos, qy = Math.exp, jy = Math.log, ht = Math.sin, Yy = Math.sign || function(n) {
|
|
18734
18734
|
return n > 0 ? 1 : n < 0 ? -1 : 0;
|
|
18735
18735
|
}, qs = Math.sqrt, Ky = Math.tan;
|
|
18736
18736
|
function Zy(n) {
|
|
@@ -18798,7 +18798,7 @@ function Jy(n, e) {
|
|
|
18798
18798
|
n && vu.hasOwnProperty(n.type) ? vu[n.type](n, e) : Ns(n, e);
|
|
18799
18799
|
}
|
|
18800
18800
|
function pa(n) {
|
|
18801
|
-
return [
|
|
18801
|
+
return [wr(n[1], n[0]), Ar(n[2])];
|
|
18802
18802
|
}
|
|
18803
18803
|
function qi(n) {
|
|
18804
18804
|
var e = n[0], t = n[1], i = ut(t);
|
|
@@ -18849,14 +18849,14 @@ function Eu(n, e) {
|
|
|
18849
18849
|
function o(a, l) {
|
|
18850
18850
|
var c = ut(l), u = ut(a) * c, h = ht(a) * c, f = ht(l), d = f * t + u * i;
|
|
18851
18851
|
return [
|
|
18852
|
-
|
|
18852
|
+
wr(h * r - d * s, u * t - f * i),
|
|
18853
18853
|
Ar(d * r + h * s)
|
|
18854
18854
|
];
|
|
18855
18855
|
}
|
|
18856
18856
|
return o.invert = function(a, l) {
|
|
18857
18857
|
var c = ut(l), u = ut(a) * c, h = ht(a) * c, f = ht(l), d = f * r - h * s;
|
|
18858
18858
|
return [
|
|
18859
|
-
|
|
18859
|
+
wr(h * r + f * s, u * t + d * i),
|
|
18860
18860
|
Ar(d * t - u * i)
|
|
18861
18861
|
];
|
|
18862
18862
|
}, o;
|
|
@@ -18925,7 +18925,7 @@ function Xh(n, e, t, i, r) {
|
|
|
18925
18925
|
s.push(S = new vs(m, g, null, !0)), o.push(S.o = new vs(m, null, S, !1)), s.push(S = new vs(p, g, null, !1)), o.push(S.o = new vs(p, null, S, !0));
|
|
18926
18926
|
}
|
|
18927
18927
|
}), !!s.length) {
|
|
18928
|
-
for (o.sort(e),
|
|
18928
|
+
for (o.sort(e), Tu(s), Tu(o), a = 0, l = o.length; a < l; ++a)
|
|
18929
18929
|
o[a].e = t = !t;
|
|
18930
18930
|
for (var c = s[0], u, h; ; ) {
|
|
18931
18931
|
for (var f = c, d = !0; f.v; )
|
|
@@ -18954,7 +18954,7 @@ function Xh(n, e, t, i, r) {
|
|
|
18954
18954
|
}
|
|
18955
18955
|
}
|
|
18956
18956
|
}
|
|
18957
|
-
function
|
|
18957
|
+
function Tu(n) {
|
|
18958
18958
|
if (e = n.length) {
|
|
18959
18959
|
for (var e, t = 0, i = n[0], r; ++t < e; )
|
|
18960
18960
|
i.n = r = n[t], r.p = i, i = r;
|
|
@@ -18969,9 +18969,9 @@ function tS(n, e) {
|
|
|
18969
18969
|
r === 1 ? i = Nt + Qe : r === -1 && (i = -Nt - Qe);
|
|
18970
18970
|
for (var c = 0, u = n.length; c < u; ++c)
|
|
18971
18971
|
if (f = (h = n[c]).length)
|
|
18972
|
-
for (var h, f, d = h[f - 1], g = Wo(d), _ = d[1] / 2 + _u, m = ht(_), p = ut(_), S = 0; S < f; ++S, g = M, m = R, p =
|
|
18973
|
-
var v = h[S], M = Wo(v), b = v[1] / 2 + _u, R = ht(b),
|
|
18974
|
-
if (l.add(
|
|
18972
|
+
for (var h, f, d = h[f - 1], g = Wo(d), _ = d[1] / 2 + _u, m = ht(_), p = ut(_), S = 0; S < f; ++S, g = M, m = R, p = w, d = v) {
|
|
18973
|
+
var v = h[S], M = Wo(v), b = v[1] / 2 + _u, R = ht(b), w = ut(b), N = M - g, x = N >= 0 ? 1 : -1, E = x * N, F = E > Xe, ee = m * R;
|
|
18974
|
+
if (l.add(wr(ee * x * ht(E), p * w + ee * ut(E))), o += F ? N + x * Kt : N, F ^ g >= t ^ M >= t) {
|
|
18975
18975
|
var O = Os(qi(d), qi(v));
|
|
18976
18976
|
ma(O);
|
|
18977
18977
|
var U = Os(s, O);
|
|
@@ -19020,8 +19020,8 @@ function $h(n, e, t, i) {
|
|
|
19020
19020
|
}
|
|
19021
19021
|
function v() {
|
|
19022
19022
|
p(h[0][0], h[0][1]), a.lineEnd();
|
|
19023
|
-
var M = a.clean(), b = o.result(), R,
|
|
19024
|
-
if (h.pop(), c.push(h), h = null, !!
|
|
19023
|
+
var M = a.clean(), b = o.result(), R, w = b.length, N, x, E;
|
|
19024
|
+
if (h.pop(), c.push(h), h = null, !!w) {
|
|
19025
19025
|
if (M & 1) {
|
|
19026
19026
|
if (x = b[0], (N = x.length - 1) > 0) {
|
|
19027
19027
|
for (l || (r.polygonStart(), l = !0), r.lineStart(), R = 0; R < N; ++R)
|
|
@@ -19030,7 +19030,7 @@ function $h(n, e, t, i) {
|
|
|
19030
19030
|
}
|
|
19031
19031
|
return;
|
|
19032
19032
|
}
|
|
19033
|
-
|
|
19033
|
+
w > 1 && M & 2 && b.push(b.pop().concat(b.shift())), u.push(b.filter(nS));
|
|
19034
19034
|
}
|
|
19035
19035
|
}
|
|
19036
19036
|
return f;
|
|
@@ -19042,7 +19042,7 @@ function nS(n) {
|
|
|
19042
19042
|
function iS(n, e) {
|
|
19043
19043
|
return ((n = n.x)[0] < 0 ? n[1] - Nt - Qe : Nt - n[1]) - ((e = e.x)[0] < 0 ? e[1] - Nt - Qe : Nt - e[1]);
|
|
19044
19044
|
}
|
|
19045
|
-
const
|
|
19045
|
+
const wu = $h(
|
|
19046
19046
|
function() {
|
|
19047
19047
|
return !0;
|
|
19048
19048
|
},
|
|
@@ -19120,19 +19120,19 @@ function aS(n) {
|
|
|
19120
19120
|
var d = qi(u), g = qi(h), _ = [1, 0, 0], m = Os(d, g), p = gs(m, m), S = m[0], v = p - S * S;
|
|
19121
19121
|
if (!v)
|
|
19122
19122
|
return !f && u;
|
|
19123
|
-
var M = e * p / v, b = -e * S / v, R = Os(_, m),
|
|
19124
|
-
Vo(
|
|
19125
|
-
var x = R, E = gs(
|
|
19123
|
+
var M = e * p / v, b = -e * S / v, R = Os(_, m), w = _s(_, M), N = _s(m, b);
|
|
19124
|
+
Vo(w, N);
|
|
19125
|
+
var x = R, E = gs(w, x), F = gs(x, x), ee = E * E - F * (gs(w, w) - 1);
|
|
19126
19126
|
if (!(ee < 0)) {
|
|
19127
19127
|
var O = qs(ee), U = _s(x, (-E - O) / F);
|
|
19128
|
-
if (Vo(U,
|
|
19128
|
+
if (Vo(U, w), U = pa(U), !f)
|
|
19129
19129
|
return U;
|
|
19130
19130
|
var C = u[0], z = h[0], H = u[1], V = h[1], K;
|
|
19131
19131
|
z < C && (K = C, C = z, z = K);
|
|
19132
19132
|
var Q = z - C, B = lt(Q - Xe) < Qe, q = B || Q < Qe;
|
|
19133
19133
|
if (!B && V < H && (K = H, H = V, V = K), q ? B ? H + V > 0 ^ U[1] < (lt(U[0] - C) < Qe ? H : V) : H <= U[1] && U[1] <= V : Q > Xe ^ (C <= U[0] && U[0] <= z)) {
|
|
19134
19134
|
var oe = _s(x, (-E + O) / F);
|
|
19135
|
-
return Vo(oe,
|
|
19135
|
+
return Vo(oe, w), [U, pa(oe)];
|
|
19136
19136
|
}
|
|
19137
19137
|
}
|
|
19138
19138
|
}
|
|
@@ -19215,7 +19215,7 @@ function cS(n, e, t, i) {
|
|
|
19215
19215
|
return h !== f ? h - f : h === 0 ? u[1] - c[1] : h === 1 ? c[0] - u[0] : h === 2 ? c[1] - u[1] : u[0] - c[0];
|
|
19216
19216
|
}
|
|
19217
19217
|
return function(c) {
|
|
19218
|
-
var u = c, h = Wh(), f, d, g, _, m, p, S, v, M, b, R,
|
|
19218
|
+
var u = c, h = Wh(), f, d, g, _, m, p, S, v, M, b, R, w = {
|
|
19219
19219
|
point: N,
|
|
19220
19220
|
lineStart: ee,
|
|
19221
19221
|
lineEnd: O,
|
|
@@ -19239,10 +19239,10 @@ function cS(n, e, t, i) {
|
|
|
19239
19239
|
(z || H) && (c.polygonStart(), z && (c.lineStart(), s(null, null, 1, c), c.lineEnd()), H && Xh(f, a, C, s, c), c.polygonEnd()), u = c, f = d = g = null;
|
|
19240
19240
|
}
|
|
19241
19241
|
function ee() {
|
|
19242
|
-
|
|
19242
|
+
w.point = U, d && d.push(g = []), b = !0, M = !1, S = v = NaN;
|
|
19243
19243
|
}
|
|
19244
19244
|
function O() {
|
|
19245
|
-
f && (U(_, m), p && M && h.rejoin(), f.push(h.result())),
|
|
19245
|
+
f && (U(_, m), p && M && h.rejoin(), f.push(h.result())), w.point = N, M && u.lineEnd();
|
|
19246
19246
|
}
|
|
19247
19247
|
function U(C, z) {
|
|
19248
19248
|
var H = r(C, z);
|
|
@@ -19256,7 +19256,7 @@ function cS(n, e, t, i) {
|
|
|
19256
19256
|
}
|
|
19257
19257
|
S = C, v = z, M = H;
|
|
19258
19258
|
}
|
|
19259
|
-
return
|
|
19259
|
+
return w;
|
|
19260
19260
|
};
|
|
19261
19261
|
}
|
|
19262
19262
|
const Au = (n) => n;
|
|
@@ -19346,8 +19346,8 @@ function _S(n, e) {
|
|
|
19346
19346
|
function t(i, r, s, o, a, l, c, u, h, f, d, g, _, m) {
|
|
19347
19347
|
var p = c - i, S = u - r, v = p * p + S * S;
|
|
19348
19348
|
if (v > 4 * e && _--) {
|
|
19349
|
-
var M = o + f, b = a + d, R = l + g,
|
|
19350
|
-
(C * C / v > e || lt((p * O + S * U) / v - 0.5) > 0.3 || o * f + a * d + l * g < mS) && (t(i, r, s, o, a, l, F, ee, x, M /=
|
|
19349
|
+
var M = o + f, b = a + d, R = l + g, w = qs(M * M + b * b + R * R), N = Ar(R /= w), x = lt(lt(R) - 1) < Qe || lt(s - h) < Qe ? (s + h) / 2 : wr(b, M), E = n(x, N), F = E[0], ee = E[1], O = F - i, U = ee - r, C = S * O - p * U;
|
|
19350
|
+
(C * C / v > e || lt((p * O + S * U) / v - 0.5) > 0.3 || o * f + a * d + l * g < mS) && (t(i, r, s, o, a, l, F, ee, x, M /= w, b /= w, R, _, m), m.point(F, ee), t(F, ee, x, M, b, R, c, u, h, f, d, g, _, m));
|
|
19351
19351
|
}
|
|
19352
19352
|
}
|
|
19353
19353
|
return function(i) {
|
|
@@ -19376,12 +19376,12 @@ function _S(n, e) {
|
|
|
19376
19376
|
m.point = p, i.lineEnd();
|
|
19377
19377
|
}
|
|
19378
19378
|
function b() {
|
|
19379
|
-
S(), m.point = R, m.lineEnd =
|
|
19379
|
+
S(), m.point = R, m.lineEnd = w;
|
|
19380
19380
|
}
|
|
19381
19381
|
function R(N, x) {
|
|
19382
19382
|
v(r = N, x), s = h, o = f, a = d, l = g, c = _, m.point = v;
|
|
19383
19383
|
}
|
|
19384
|
-
function
|
|
19384
|
+
function w() {
|
|
19385
19385
|
t(h, f, u, d, g, _, s, o, r, a, l, c, Ru, i), m.lineEnd = M, M();
|
|
19386
19386
|
}
|
|
19387
19387
|
return m;
|
|
@@ -19425,7 +19425,7 @@ function SS(n) {
|
|
|
19425
19425
|
})();
|
|
19426
19426
|
}
|
|
19427
19427
|
function MS(n) {
|
|
19428
|
-
var e, t = 150, i = 480, r = 250, s = 0, o = 0, a = 0, l = 0, c = 0, u, h = 0, f = 1, d = 1, g = null, _ =
|
|
19428
|
+
var e, t = 150, i = 480, r = 250, s = 0, o = 0, a = 0, l = 0, c = 0, u, h = 0, f = 1, d = 1, g = null, _ = wu, m = null, p, S, v, M = Au, b = 0.5, R, w, N, x, E;
|
|
19429
19429
|
function F(C) {
|
|
19430
19430
|
return N(C[0] * mt, C[1] * mt);
|
|
19431
19431
|
}
|
|
@@ -19439,7 +19439,7 @@ function MS(n) {
|
|
|
19439
19439
|
}, F.postclip = function(C) {
|
|
19440
19440
|
return arguments.length ? (M = C, m = p = S = v = null, U()) : M;
|
|
19441
19441
|
}, F.clipAngle = function(C) {
|
|
19442
|
-
return arguments.length ? (_ = +C ? aS(g = C * mt) : (g = null,
|
|
19442
|
+
return arguments.length ? (_ = +C ? aS(g = C * mt) : (g = null, wu), U()) : g * Gt;
|
|
19443
19443
|
}, F.clipExtent = function(C) {
|
|
19444
19444
|
return arguments.length ? (M = C == null ? (m = p = S = v = null, Au) : cS(m = +C[0][0], p = +C[0][1], S = +C[1][0], v = +C[1][1]), U()) : m == null ? null : [[m, p], [S, v]];
|
|
19445
19445
|
}, F.scale = function(C) {
|
|
@@ -19457,7 +19457,7 @@ function MS(n) {
|
|
|
19457
19457
|
}, F.reflectY = function(C) {
|
|
19458
19458
|
return arguments.length ? (d = C ? -1 : 1, O()) : d < 0;
|
|
19459
19459
|
}, F.precision = function(C) {
|
|
19460
|
-
return arguments.length ? (R = Pu(
|
|
19460
|
+
return arguments.length ? (R = Pu(w, b = C * C), U()) : qs(b);
|
|
19461
19461
|
}, F.fitExtent = function(C, z) {
|
|
19462
19462
|
return qh(F, C, z);
|
|
19463
19463
|
}, F.fitSize = function(C, z) {
|
|
@@ -19469,7 +19469,7 @@ function MS(n) {
|
|
|
19469
19469
|
};
|
|
19470
19470
|
function O() {
|
|
19471
19471
|
var C = Lu(t, 0, 0, f, d, h).apply(null, e(s, o)), z = Lu(t, i - C[0], r - C[1], f, d, h);
|
|
19472
|
-
return u = Vh(a, l, c),
|
|
19472
|
+
return u = Vh(a, l, c), w = ga(e, z), N = ga(u, w), R = Pu(w, b), U();
|
|
19473
19473
|
}
|
|
19474
19474
|
function U() {
|
|
19475
19475
|
return x = E = null, F;
|
|
@@ -19553,11 +19553,11 @@ const { toString: bS } = Object.prototype, { getPrototypeOf: $a } = Object, js =
|
|
|
19553
19553
|
const t = bS.call(e);
|
|
19554
19554
|
return n[t] || (n[t] = t.slice(8, -1).toLowerCase());
|
|
19555
19555
|
})(/* @__PURE__ */ Object.create(null)), xn = (n) => (n = n.toLowerCase(), (e) => js(e) === n), Ys = (n) => (e) => typeof e === n, { isArray: Qi } = Array, Rr = Ys("undefined");
|
|
19556
|
-
function
|
|
19556
|
+
function TS(n) {
|
|
19557
19557
|
return n !== null && !Rr(n) && n.constructor !== null && !Rr(n.constructor) && Yt(n.constructor.isBuffer) && n.constructor.isBuffer(n);
|
|
19558
19558
|
}
|
|
19559
19559
|
const Yh = xn("ArrayBuffer");
|
|
19560
|
-
function
|
|
19560
|
+
function wS(n) {
|
|
19561
19561
|
let e;
|
|
19562
19562
|
return typeof ArrayBuffer != "undefined" && ArrayBuffer.isView ? e = ArrayBuffer.isView(n) : e = n && n.buffer && Yh(n.buffer), e;
|
|
19563
19563
|
}
|
|
@@ -19718,9 +19718,9 @@ const tM = (n) => {
|
|
|
19718
19718
|
}, nM = xn("AsyncFunction"), iM = (n) => n && (Ks(n) || Yt(n)) && Yt(n.then) && Yt(n.catch), Z = {
|
|
19719
19719
|
isArray: Qi,
|
|
19720
19720
|
isArrayBuffer: Yh,
|
|
19721
|
-
isBuffer:
|
|
19721
|
+
isBuffer: TS,
|
|
19722
19722
|
isFormData: US,
|
|
19723
|
-
isArrayBufferView:
|
|
19723
|
+
isArrayBufferView: wS,
|
|
19724
19724
|
isString: AS,
|
|
19725
19725
|
isNumber: Kh,
|
|
19726
19726
|
isBoolean: CS,
|
|
@@ -20336,7 +20336,7 @@ function bM(n, e, t) {
|
|
|
20336
20336
|
t
|
|
20337
20337
|
));
|
|
20338
20338
|
}
|
|
20339
|
-
const
|
|
20339
|
+
const TM = sn.isStandardBrowserEnv ? (
|
|
20340
20340
|
// Standard browser envs support document.cookie
|
|
20341
20341
|
function() {
|
|
20342
20342
|
return {
|
|
@@ -20367,14 +20367,14 @@ const wM = sn.isStandardBrowserEnv ? (
|
|
|
20367
20367
|
};
|
|
20368
20368
|
}()
|
|
20369
20369
|
);
|
|
20370
|
-
function
|
|
20370
|
+
function wM(n) {
|
|
20371
20371
|
return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(n);
|
|
20372
20372
|
}
|
|
20373
20373
|
function AM(n, e) {
|
|
20374
20374
|
return e ? n.replace(/\/+$/, "") + "/" + e.replace(/^\/+/, "") : n;
|
|
20375
20375
|
}
|
|
20376
20376
|
function hf(n, e) {
|
|
20377
|
-
return n && !
|
|
20377
|
+
return n && !wM(e) ? AM(n, e) : e;
|
|
20378
20378
|
}
|
|
20379
20379
|
const CM = sn.isStandardBrowserEnv ? (
|
|
20380
20380
|
// Standard browser envs have full support of the APIs needed to test
|
|
@@ -20497,7 +20497,7 @@ const LM = typeof XMLHttpRequest != "undefined", DM = LM && function(n) {
|
|
|
20497
20497
|
c
|
|
20498
20498
|
)), c = null;
|
|
20499
20499
|
}, sn.isStandardBrowserEnv) {
|
|
20500
|
-
const d = (n.withCredentials || CM(u)) && n.xsrfCookieName &&
|
|
20500
|
+
const d = (n.withCredentials || CM(u)) && n.xsrfCookieName && TM.read(n.xsrfCookieName);
|
|
20501
20501
|
d && s.set(n.xsrfHeaderName, d);
|
|
20502
20502
|
}
|
|
20503
20503
|
r === void 0 && s.setContentType(null), "setRequestHeader" in c && Z.forEach(s.toJSON(), function(g, _) {
|
|
@@ -20512,11 +20512,11 @@ const LM = typeof XMLHttpRequest != "undefined", DM = LM && function(n) {
|
|
|
20512
20512
|
}
|
|
20513
20513
|
c.send(r || null);
|
|
20514
20514
|
});
|
|
20515
|
-
},
|
|
20515
|
+
}, Ts = {
|
|
20516
20516
|
http: rM,
|
|
20517
20517
|
xhr: DM
|
|
20518
20518
|
};
|
|
20519
|
-
Z.forEach(
|
|
20519
|
+
Z.forEach(Ts, (n, e) => {
|
|
20520
20520
|
if (n) {
|
|
20521
20521
|
try {
|
|
20522
20522
|
Object.defineProperty(n, "name", { value: e });
|
|
@@ -20530,20 +20530,20 @@ const ff = {
|
|
|
20530
20530
|
n = Z.isArray(n) ? n : [n];
|
|
20531
20531
|
const { length: e } = n;
|
|
20532
20532
|
let t, i;
|
|
20533
|
-
for (let r = 0; r < e && (t = n[r], !(i = Z.isString(t) ?
|
|
20533
|
+
for (let r = 0; r < e && (t = n[r], !(i = Z.isString(t) ? Ts[t.toLowerCase()] : t)); r++)
|
|
20534
20534
|
;
|
|
20535
20535
|
if (!i)
|
|
20536
20536
|
throw i === !1 ? new $e(
|
|
20537
20537
|
`Adapter ${t} is not supported by the environment`,
|
|
20538
20538
|
"ERR_NOT_SUPPORT"
|
|
20539
20539
|
) : new Error(
|
|
20540
|
-
Z.hasOwnProp(
|
|
20540
|
+
Z.hasOwnProp(Ts, t) ? `Adapter '${t}' is not available in the build` : `Unknown adapter '${t}'`
|
|
20541
20541
|
);
|
|
20542
20542
|
if (!Z.isFunction(i))
|
|
20543
20543
|
throw new TypeError("adapter is not a function");
|
|
20544
20544
|
return i;
|
|
20545
20545
|
},
|
|
20546
|
-
adapters:
|
|
20546
|
+
adapters: Ts
|
|
20547
20547
|
};
|
|
20548
20548
|
function jo(n) {
|
|
20549
20549
|
if (n.cancelToken && n.cancelToken.throwIfRequested(), n.signal && n.signal.aborted)
|
|
@@ -20783,7 +20783,7 @@ Z.forEach(["post", "put", "patch"], function(e) {
|
|
|
20783
20783
|
}
|
|
20784
20784
|
zs.prototype[e] = t(), zs.prototype[e + "Form"] = t(!0);
|
|
20785
20785
|
});
|
|
20786
|
-
const
|
|
20786
|
+
const ws = zs;
|
|
20787
20787
|
class Za {
|
|
20788
20788
|
constructor(e) {
|
|
20789
20789
|
if (typeof e != "function")
|
|
@@ -20931,13 +20931,13 @@ Object.entries(Ma).forEach(([n, e]) => {
|
|
|
20931
20931
|
});
|
|
20932
20932
|
const FM = Ma;
|
|
20933
20933
|
function pf(n) {
|
|
20934
|
-
const e = new
|
|
20935
|
-
return Z.extend(t,
|
|
20934
|
+
const e = new ws(n), t = jh(ws.prototype.request, e);
|
|
20935
|
+
return Z.extend(t, ws.prototype, e, { allOwnKeys: !0 }), Z.extend(t, e, null, { allOwnKeys: !0 }), t.create = function(r) {
|
|
20936
20936
|
return pf(Yi(n, r));
|
|
20937
20937
|
}, t;
|
|
20938
20938
|
}
|
|
20939
20939
|
const gt = pf(Ya);
|
|
20940
|
-
gt.Axios =
|
|
20940
|
+
gt.Axios = ws;
|
|
20941
20941
|
gt.CanceledError = Nr;
|
|
20942
20942
|
gt.CancelToken = UM;
|
|
20943
20943
|
gt.isCancel = uf;
|
|
@@ -21055,6 +21055,15 @@ const ys = vr.track.bind(vr), kM = bf.extend({
|
|
|
21055
21055
|
// 手动缩放
|
|
21056
21056
|
mouseScale() {
|
|
21057
21057
|
return this.wheelScale / this.baseScale;
|
|
21058
|
+
},
|
|
21059
|
+
// 小弹窗
|
|
21060
|
+
tipsData() {
|
|
21061
|
+
return this.tipsData = (this.infoOpt || []).map((n) => {
|
|
21062
|
+
var e;
|
|
21063
|
+
return nt(Le({}, n), {
|
|
21064
|
+
code: n.code || ((e = this.focusData.find((t) => t.gps && t.gps.join("") === n.gps.join(""))) == null ? void 0 : e.code)
|
|
21065
|
+
});
|
|
21066
|
+
});
|
|
21058
21067
|
}
|
|
21059
21068
|
},
|
|
21060
21069
|
watch: {
|
|
@@ -21064,29 +21073,28 @@ const ys = vr.track.bind(vr), kM = bf.extend({
|
|
|
21064
21073
|
code() {
|
|
21065
21074
|
vr.dispose(), this.getData();
|
|
21066
21075
|
},
|
|
21067
|
-
areaObj
|
|
21068
|
-
|
|
21069
|
-
|
|
21070
|
-
|
|
21071
|
-
|
|
21072
|
-
|
|
21073
|
-
|
|
21074
|
-
|
|
21075
|
-
|
|
21076
|
-
|
|
21077
|
-
|
|
21078
|
-
});
|
|
21079
|
-
});
|
|
21076
|
+
areaObj: {
|
|
21077
|
+
immediate: !0,
|
|
21078
|
+
handler(n) {
|
|
21079
|
+
let e = [], t = [], i = [];
|
|
21080
|
+
if (this.computCode = null, this.focusData = (n == null ? void 0 : n.areaList) || [], this.focusData.forEach((r) => {
|
|
21081
|
+
r.gps && (e.push(r.province), t.push(r.city), i.push(r.area));
|
|
21082
|
+
}), e.length) {
|
|
21083
|
+
let r = "";
|
|
21084
|
+
e.length === 1 ? t.length > 1 ? (this.computCode = e[0], r = "city") : i.length > 1 ? (this.computCode = t[0], r = "area") : (this.computCode = i[0], r = "area") : (this.computCode = 1e5, r = "province"), this.focusData = this.focusData.map((s) => nt(Le({}, s), { code: s[r] }));
|
|
21085
|
+
}
|
|
21086
|
+
this.loading || this.renderMap();
|
|
21080
21087
|
}
|
|
21081
|
-
this.loading || this.renderMap();
|
|
21082
21088
|
},
|
|
21083
|
-
infoOpt
|
|
21084
|
-
|
|
21085
|
-
|
|
21086
|
-
|
|
21087
|
-
|
|
21088
|
-
|
|
21089
|
-
|
|
21089
|
+
infoOpt: {
|
|
21090
|
+
handler(n) {
|
|
21091
|
+
this.tipsData = (n || []).map((e) => {
|
|
21092
|
+
var t;
|
|
21093
|
+
return nt(Le({}, e), {
|
|
21094
|
+
code: e.code || ((t = this.focusData.find((i) => i.gps && i.gps.join("") === e.gps.join(""))) == null ? void 0 : t.code)
|
|
21095
|
+
});
|
|
21096
|
+
}), this.drawTips(), this.animate();
|
|
21097
|
+
}
|
|
21090
21098
|
}
|
|
21091
21099
|
},
|
|
21092
21100
|
data() {
|
|
@@ -21257,7 +21265,7 @@ const ys = vr.track.bind(vr), kM = bf.extend({
|
|
|
21257
21265
|
},
|
|
21258
21266
|
// 绘制小弹窗
|
|
21259
21267
|
drawTips() {
|
|
21260
|
-
if (!this.centroid) {
|
|
21268
|
+
if (!this.centroid || !this.scene) {
|
|
21261
21269
|
setTimeout(() => {
|
|
21262
21270
|
this.drawTips();
|
|
21263
21271
|
}, 100);
|
|
@@ -21288,7 +21296,7 @@ const ys = vr.track.bind(vr), kM = bf.extend({
|
|
|
21288
21296
|
return Math.min(...u) === s[0] && (o[0] = this.mouseScale * -1.2, a[0] = this.mouseScale * -6.5, l = "left"), (Math.min(...h) === s[1] || i.find((f) => f.x === l && f.y === "top" && s[1] < f.yVal)) && (o[1] = this.mouseScale * -2, a[1] = this.mouseScale * -2, c = "bottom"), i.push({ x: l, y: c, yVal: s[1] }), { middle: o, end: a };
|
|
21289
21297
|
};
|
|
21290
21298
|
e.forEach((s) => {
|
|
21291
|
-
var R,
|
|
21299
|
+
var R, w;
|
|
21292
21300
|
const o = s.properties, a = n(s.userData.gps || o.centroid || o.center), { middle: l, end: c } = r(s.userData.gps || o.centroid || o.center), u = document.createElement("div");
|
|
21293
21301
|
u.textContent = o.name, u.style.cssText = `color:#fff;border:1px solid #78f0fe;padding:${this.baseRem * 3}px ${this.baseRem * 5}px;border-radius: 0 ${this.baseRem * 10}px;background:linear-gradient(180deg,#78f0fe,#005276);opacity:0.8;min-width:${this.baseRem * 50}px;text-align:center;`;
|
|
21294
21302
|
const h = new Ho(u);
|
|
@@ -21301,7 +21309,7 @@ const ys = vr.track.bind(vr), kM = bf.extend({
|
|
|
21301
21309
|
v.push(new D(a[0], -a[1], 1)), v.push(new D(a[0] + l[0], -a[1] + l[1], 1)), v.push(new D(a[0] + c[0], -a[1] + c[1], 1));
|
|
21302
21310
|
const M = this.drawLine(v, "#ffda57");
|
|
21303
21311
|
this.tipsMesh.add(h), this.tipsMesh.add(S), this.tipsMesh.add(M);
|
|
21304
|
-
const b = (
|
|
21312
|
+
const b = (w = (R = this.scene.children.find((N) => N.name === "map")) == null ? void 0 : R.children.find((N) => N.name === o.adcode)) == null ? void 0 : w.children;
|
|
21305
21313
|
b == null || b.forEach((N) => {
|
|
21306
21314
|
N.name === o.adcode && this.activeMesh.push(N);
|
|
21307
21315
|
}), this.activeMesh.forEach((N) => {
|
|
@@ -21353,12 +21361,6 @@ const ys = vr.track.bind(vr), kM = bf.extend({
|
|
|
21353
21361
|
var GM = function() {
|
|
21354
21362
|
var n = this, e = n.$createElement, t = n._self._c || e;
|
|
21355
21363
|
return t("div", {
|
|
21356
|
-
directives: [{
|
|
21357
|
-
name: "loading",
|
|
21358
|
-
rawName: "v-loading",
|
|
21359
|
-
value: n.loading,
|
|
21360
|
-
expression: "loading"
|
|
21361
|
-
}],
|
|
21362
21364
|
staticClass: "dp-map_view"
|
|
21363
21365
|
}, [t("div", {
|
|
21364
21366
|
ref: "tag"
|
|
@@ -21368,13 +21370,13 @@ var GM = function() {
|
|
|
21368
21370
|
})]);
|
|
21369
21371
|
}, VM = [];
|
|
21370
21372
|
const Wu = {};
|
|
21371
|
-
var WM = /* @__PURE__ */
|
|
21373
|
+
var WM = /* @__PURE__ */ Tt(
|
|
21372
21374
|
kM,
|
|
21373
21375
|
GM,
|
|
21374
21376
|
VM,
|
|
21375
21377
|
!1,
|
|
21376
21378
|
XM,
|
|
21377
|
-
"
|
|
21379
|
+
"71f7b544",
|
|
21378
21380
|
null,
|
|
21379
21381
|
null
|
|
21380
21382
|
);
|