ss-component-new 1.1.183 → 1.1.185
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/{array-yS93GpFh.cjs → array-Bo3p2itu.cjs} +1 -1
- package/dist/{array-CKFeRuXx.js → array-CTMBVA4w.js} +9 -9
- package/dist/{cloneDeep-ptqcNoLQ.js → cloneDeep-BmTK4FEu.js} +1 -1
- package/dist/{cloneDeep-wWT7F5V9.cjs → cloneDeep-gdyyfw9f.cjs} +1 -1
- package/dist/{formToTable-D8p_7BL5.cjs → formToTable-9jLakigk.cjs} +1 -1
- package/dist/{formToTable-kzbUTMeG.js → formToTable-oMNwkiWt.js} +1 -1
- package/dist/{index-ZFCchT5E.js → index--V7oWPMc.js} +6 -6
- package/dist/{index-DZbaNTdt.js → index-6rLImJnk.js} +7 -7
- package/dist/{index-Zqbph7id.cjs → index-B4VSd4FO.cjs} +1 -1
- package/dist/{index-CRRxsIoM.js → index-B51X7O6x.js} +1 -1
- package/dist/{index-32zMKTCS.js → index-B6If5wRP.js} +1 -1
- package/dist/{index-BcmfEVff.js → index-BEl2M4PP.js} +1 -1
- package/dist/{index-DZVCmcCJ.cjs → index-BHmQ-EAF.cjs} +1 -1
- package/dist/{index-_xD-UozG.js → index-BIL2-5d5.js} +5 -5
- package/dist/{index-Cvw7aXmX.js → index-BLCmE0gH.js} +1 -1
- package/dist/{index-CMLwNzie.cjs → index-BRY3GVIU.cjs} +1 -1
- package/dist/{index-DjHji-RQ.cjs → index-BW3rUIA3.cjs} +1 -1
- package/dist/{index-sTBMcpga.js → index-BXtYUiLa.js} +4 -4
- package/dist/{index-DxVrxHU9.cjs → index-BvmHLZq4.cjs} +1 -1
- package/dist/{index-BuHfHCU0.js → index-BxKY0INk.js} +83 -80
- package/dist/{index-CYFbyJP1.cjs → index-CWUIx9UX.cjs} +1 -1
- package/dist/{index-Cj9MeB6d.js → index-CiBIzvxQ.js} +6 -6
- package/dist/{index-Bl-0RurV.js → index-Cii3X2D7.js} +7 -7
- package/dist/{index-BHNpXM7v.cjs → index-CsgtAFqn.cjs} +1 -1
- package/dist/{index-CxuWwQFp.js → index-CtsdHUOE.js} +4 -4
- package/dist/{index-Bi5QL47F.cjs → index-D-r3mc6h.cjs} +1 -1
- package/dist/{index-xbVcs94X.cjs → index-D1ICyLb8.cjs} +1 -1
- package/dist/{index-CMlB-TxD.js → index-D9kdeth5.js} +7 -7
- package/dist/{index-ubJq0geI.cjs → index-DNtWZXYf.cjs} +1 -1
- package/dist/{index-DSFOuo8T.cjs → index-DZ4OPEoP.cjs} +1 -1
- package/dist/{index-BTqzaKZG.cjs → index-Dat5KfVY.cjs} +15 -15
- package/dist/{index-fYUwhoC0.js → index-DfbsqJIq.js} +7 -7
- package/dist/{index-CWXiZ_39.cjs → index-DqaJEmiB.cjs} +1 -1
- package/dist/index-Dtd6S7I9.cjs +1 -0
- package/dist/{index-DXF8TgyC.cjs → index-DuwbY0QO.cjs} +1 -1
- package/dist/{index-Ce8y7b6N.cjs → index-DyEqiHy2.cjs} +1 -1
- package/dist/{index-DtcZSXc9.js → index-DzMB2hvj.js} +1 -1
- package/dist/{index-uUIiw9fx.cjs → index-GqsIl7hf.cjs} +1 -1
- package/dist/{index-5gIyT35D.cjs → index-VmqxQPRp.cjs} +1 -1
- package/dist/{index-vDxkLZCX.cjs → index-bC8ZQAKp.cjs} +1 -1
- package/dist/{index-Dm2-njPX.js → index-evEttDGY.js} +1 -1
- package/dist/{index-B1RwU1Yy.js → index-gKxSxGyb.js} +7 -7
- package/dist/{index-CiwAmPI1.cjs → index-hrnwsq1g.cjs} +1 -1
- package/dist/{index-B2reOYdD.js → index-iL5QqqHE.js} +6 -6
- package/dist/{index-Cv5UrSOt.js → index-orWfMHps.js} +6 -6
- package/dist/{index-pgg0WYJD.js → index-t9jjDy7J.js} +480 -480
- package/dist/{index.vue_vue_type_script_setup_true_lang-B94GQi7O.cjs → index.vue_vue_type_script_setup_true_lang-B3tRQPw2.cjs} +1 -1
- package/dist/{index.vue_vue_type_script_setup_true_lang-CAm1lczB.js → index.vue_vue_type_script_setup_true_lang-Ov8SuBXY.js} +6 -6
- package/dist/{index.vue_vue_type_style_index_0_scoped_baf99455_lang-DypM_Bv9.js → index.vue_vue_type_style_index_0_scoped_baf99455_lang-B8gUfst7.js} +6 -6
- package/dist/{index.vue_vue_type_style_index_0_scoped_baf99455_lang-FcIBePX9.cjs → index.vue_vue_type_style_index_0_scoped_baf99455_lang-CsH63ZiQ.cjs} +1 -1
- package/dist/{index.vue_vue_type_style_index_0_scoped_bbb8ace9_lang-Fr0sgpOo.js → index.vue_vue_type_style_index_0_scoped_bbb8ace9_lang-BMtvW6OD.js} +6 -6
- package/dist/{index.vue_vue_type_style_index_0_scoped_bbb8ace9_lang-DnCr2hHT.cjs → index.vue_vue_type_style_index_0_scoped_bbb8ace9_lang-DeM2yeKn.cjs} +1 -1
- package/dist/{login-BZA9GhM1.js → login-BPlaS8oU.js} +3 -3
- package/dist/{login-bbTyKyTk.cjs → login-DSnvzDcT.cjs} +1 -1
- package/dist/{main-b_H3WxtI.cjs → main-DFONrwPN.cjs} +1 -1
- package/dist/{main-DQaIGKLX.js → main-DNhq7sqn.js} +6 -6
- package/dist/{menu-WPQ8JcMg.js → menu-CmjIVfwC.js} +1 -1
- package/dist/{menu-IE9q9ekO.cjs → menu-Dgk7naNE.cjs} +1 -1
- package/dist/modelComp-De5bf7vK.js +26 -0
- package/dist/modelComp-DgySA7lh.cjs +1 -0
- package/dist/{request-r_sL_ASa.cjs → request-BCuBMd6Z.cjs} +1 -1
- package/dist/{request-MJiCtaDl.js → request-BaXl3oQ9.js} +1 -1
- package/dist/ss-component.cjs +1 -1
- package/dist/ss-component.css +1 -1
- package/dist/ss-component.js +7 -7
- package/dist/ss-component2.cjs +1 -1
- package/dist/ss-component2.js +1 -1
- package/package.json +1 -1
- package/dist/index-xA6oBKw1.cjs +0 -1
- package/dist/modelComp-B54FcUDU.cjs +0 -1
- package/dist/modelComp-L3gGUSiO.js +0 -22
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { ref as nt, watch as vi, nextTick as
|
|
2
|
-
import { p as
|
|
3
|
-
import { u as
|
|
4
|
-
import { a2 as Zl } from "./index-
|
|
5
|
-
import { a as
|
|
6
|
-
import { c as ut } from "./cloneDeep-
|
|
1
|
+
import { ref as nt, watch as vi, nextTick as ql, resolveComponent as Yo, createBlock as ma, openBlock as Ht, withCtx as en, createElementVNode as qt, renderSlot as La, onMounted as _a, createElementBlock as pn, createCommentVNode as jo, Fragment as Ko, renderList as Zo, normalizeStyle as $o, toDisplayString as Ts, createVNode as Rn, unref as Yl, onBeforeUnmount as jl, createSlots as Kl } from "vue";
|
|
2
|
+
import { p as bs } from "./request-BaXl3oQ9.js";
|
|
3
|
+
import { u as Jo } from "./modelComp-De5bf7vK.js";
|
|
4
|
+
import { a2 as Zl } from "./index-D9kdeth5.js";
|
|
5
|
+
import { a as Qo, s as $l, b as Ua } from "./index-BIL2-5d5.js";
|
|
6
|
+
import { c as ut } from "./cloneDeep-BmTK4FEu.js";
|
|
7
7
|
import { _ as ga } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import { g as qs, u as
|
|
8
|
+
import { s as Oi, d as Jl, u as Ql } from "./menu-CmjIVfwC.js";
|
|
9
|
+
import { u as ec } from "./formToTable-oMNwkiWt.js";
|
|
10
|
+
import { g as qs, u as el, d as tc, c as nc } from "./index-BLCmE0gH.js";
|
|
11
11
|
const ic = {
|
|
12
12
|
__name: "index",
|
|
13
13
|
props: {
|
|
@@ -35,7 +35,7 @@ const ic = {
|
|
|
35
35
|
), vi(
|
|
36
36
|
() => s.value,
|
|
37
37
|
() => {
|
|
38
|
-
|
|
38
|
+
ql(() => {
|
|
39
39
|
var r, a;
|
|
40
40
|
(a = (r = t.value) == null ? void 0 : r.updatePopper) == null || a.call(r);
|
|
41
41
|
});
|
|
@@ -68,7 +68,7 @@ const ic = {
|
|
|
68
68
|
}, 8, ["visible", "title", "width"]);
|
|
69
69
|
};
|
|
70
70
|
}
|
|
71
|
-
}, fi = nt(0),
|
|
71
|
+
}, fi = nt(0), Is = (i) => (fi.value++, i == null ? void 0 : i.map((t) => Array.isArray(t) ? Is(t) : {
|
|
72
72
|
label: (t == null ? void 0 : t.label) ?? "",
|
|
73
73
|
prop: (t == null ? void 0 : t.label) === "操作" ? "operate" : (t == null ? void 0 : t.prop) ?? "a" + fi.value,
|
|
74
74
|
width: (t == null ? void 0 : t.label) === "操作" ? "160" : t != null && t.width ? parseInt(t.width) : "",
|
|
@@ -84,7 +84,7 @@ const ic = {
|
|
|
84
84
|
formType: (t == null ? void 0 : t.formType) ?? "",
|
|
85
85
|
isHidden: t == null ? void 0 : t.isHidden,
|
|
86
86
|
options: (t == null ? void 0 : t.options) ?? [],
|
|
87
|
-
children:
|
|
87
|
+
children: Is(t.children) ?? void 0
|
|
88
88
|
})), sc = (i) => {
|
|
89
89
|
const e = [];
|
|
90
90
|
function t(n) {
|
|
@@ -93,7 +93,7 @@ const ic = {
|
|
|
93
93
|
!s.children || s.children.length === 0 ? e.push(s) : t(s.children);
|
|
94
94
|
}
|
|
95
95
|
return t(i), e;
|
|
96
|
-
}, Ia = (i) => ut(i).map((t) => (Array.isArray(t) && (t = t.map((n) => (Array.isArray(n) ? n =
|
|
96
|
+
}, Ia = (i) => ut(i).map((t) => (Array.isArray(t) && (t = t.map((n) => (Array.isArray(n) ? n = Is(n) : (n = {
|
|
97
97
|
label: (n == null ? void 0 : n.label) ?? "",
|
|
98
98
|
prop: (n == null ? void 0 : n.label) === "操作" ? "operate" : (n == null ? void 0 : n.prop) ?? "a" + fi.value,
|
|
99
99
|
width: (n == null ? void 0 : n.label) === "操作" ? "160" : n != null && n.width ? parseInt(n.width) : "",
|
|
@@ -109,8 +109,8 @@ const ic = {
|
|
|
109
109
|
formType: (n == null ? void 0 : n.formType) ?? "",
|
|
110
110
|
isHidden: n == null ? void 0 : n.isHidden,
|
|
111
111
|
options: (n == null ? void 0 : n.options) ?? [],
|
|
112
|
-
children:
|
|
113
|
-
}, fi.value++), n))), t)),
|
|
112
|
+
children: Is(n.children)
|
|
113
|
+
}, fi.value++), n))), t)), tl = (i) => {
|
|
114
114
|
function e(t, n = []) {
|
|
115
115
|
if (!t || t.length === 0) return [];
|
|
116
116
|
let s = n;
|
|
@@ -141,7 +141,7 @@ const ic = {
|
|
|
141
141
|
t("buttonClick", h);
|
|
142
142
|
}, l = (h) => {
|
|
143
143
|
var u, f;
|
|
144
|
-
r.value = (f = (u =
|
|
144
|
+
r.value = (f = (u = tl(ut(h))) == null ? void 0 : u.filter((m) => (m == null ? void 0 : m.label) !== "" && (m == null ? void 0 : m.label) !== "操作")) == null ? void 0 : f.map((m) => ({
|
|
145
145
|
label: (m == null ? void 0 : m.label) ?? "",
|
|
146
146
|
value: "",
|
|
147
147
|
name: (m == null ? void 0 : m.prop) ?? "",
|
|
@@ -190,7 +190,7 @@ const ic = {
|
|
|
190
190
|
class: "button-style",
|
|
191
191
|
onClick: u[0] || (u[0] = (_) => s.value = !s.value)
|
|
192
192
|
}, [
|
|
193
|
-
Rn(
|
|
193
|
+
Rn(Yl(Zl), { color: "var(--ssComponent-black)" })
|
|
194
194
|
])
|
|
195
195
|
]),
|
|
196
196
|
_: 1
|
|
@@ -198,7 +198,7 @@ const ic = {
|
|
|
198
198
|
]),
|
|
199
199
|
content: en(() => [
|
|
200
200
|
qt("div", cc, [
|
|
201
|
-
(Ht(), ma(
|
|
201
|
+
(Ht(), ma(Qo, {
|
|
202
202
|
rowContents: r.value,
|
|
203
203
|
buttonValue: a.value,
|
|
204
204
|
isRowFlex: !0,
|
|
@@ -222,7 +222,7 @@ const ic = {
|
|
|
222
222
|
* Copyright 2010-2025 Three.js Authors
|
|
223
223
|
* SPDX-License-Identifier: MIT
|
|
224
224
|
*/
|
|
225
|
-
const va = "177", pi = { ROTATE: 0, DOLLY: 1, PAN: 2 }, ui = { ROTATE: 0, PAN: 1, DOLLY_PAN: 2, DOLLY_ROTATE: 3 }, dc = 0, Na = 1, fc = 2,
|
|
225
|
+
const va = "177", pi = { ROTATE: 0, DOLLY: 1, PAN: 2 }, ui = { ROTATE: 0, PAN: 1, DOLLY_PAN: 2, DOLLY_ROTATE: 3 }, dc = 0, Na = 1, fc = 2, nl = 1, pc = 2, dn = 3, vn = 0, Pt = 1, fn = 2, Pn = 0, mi = 1, Fa = 2, Oa = 3, Ba = 4, mc = 5, kn = 100, _c = 101, gc = 102, vc = 103, xc = 104, Mc = 200, Sc = 201, Ec = 202, yc = 203, Rr = 204, Cr = 205, Tc = 206, bc = 207, Ac = 208, wc = 209, Rc = 210, Cc = 211, Pc = 212, Dc = 213, Lc = 214, Pr = 0, Dr = 1, Lr = 2, xi = 3, Ur = 4, Ir = 5, Nr = 6, Fr = 7, xa = 0, Uc = 1, Ic = 2, Dn = 0, Nc = 1, Fc = 2, Oc = 3, Bc = 4, zc = 5, Hc = 6, kc = 7, il = 300, Mi = 301, Si = 302, Or = 303, Br = 304, ks = 306, Ns = 1e3, Gn = 1001, zr = 1002, Kt = 1003, Vc = 1004, $i = 1005, tn = 1006, Ys = 1007, Wn = 1008, sn = 1009, sl = 1010, rl = 1011, ki = 1012, Ma = 1013, Xn = 1014, mn = 1015, qi = 1016, Sa = 1017, Ea = 1018, Vi = 1020, al = 35902, ol = 1021, ll = 1022, Yt = 1023, Gi = 1026, Wi = 1027, cl = 1028, ya = 1029, hl = 1030, Ta = 1031, ba = 1033, As = 33776, ws = 33777, Rs = 33778, Cs = 33779, Hr = 35840, kr = 35841, Vr = 35842, Gr = 35843, Wr = 36196, Xr = 37492, qr = 37496, Yr = 37808, jr = 37809, Kr = 37810, Zr = 37811, $r = 37812, Jr = 37813, Qr = 37814, ea = 37815, ta = 37816, na = 37817, ia = 37818, sa = 37819, ra = 37820, aa = 37821, Ps = 36492, oa = 36494, la = 36495, ul = 36283, ca = 36284, ha = 36285, ua = 36286, Gc = 3200, Wc = 3201, dl = 0, Xc = 1, Cn = "", xt = "srgb", Ei = "srgb-linear", Fs = "linear", et = "srgb", $n = 7680, za = 519, qc = 512, Yc = 513, jc = 514, fl = 515, Kc = 516, Zc = 517, $c = 518, Jc = 519, Ha = 35044, ka = "300 es", _n = 2e3, Os = 2001;
|
|
226
226
|
class jn {
|
|
227
227
|
/**
|
|
228
228
|
* Adds the given event listener to the given event type.
|
|
@@ -279,8 +279,8 @@ class jn {
|
|
|
279
279
|
}
|
|
280
280
|
}
|
|
281
281
|
}
|
|
282
|
-
const St = ["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"],
|
|
283
|
-
function
|
|
282
|
+
const St = ["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"], Ds = Math.PI / 180, da = 180 / Math.PI;
|
|
283
|
+
function Yi() {
|
|
284
284
|
const i = Math.random() * 4294967295 | 0, e = Math.random() * 4294967295 | 0, t = Math.random() * 4294967295 | 0, n = Math.random() * 4294967295 | 0;
|
|
285
285
|
return (St[i & 255] + St[i >> 8 & 255] + St[i >> 16 & 255] + St[i >> 24 & 255] + "-" + St[e & 255] + St[e >> 8 & 255] + "-" + St[e >> 16 & 15 | 64] + St[e >> 24 & 255] + "-" + St[t & 63 | 128] + St[t >> 8 & 255] + "-" + St[t >> 16 & 255] + St[t >> 24 & 255] + St[n & 255] + St[n >> 8 & 255] + St[n >> 16 & 255] + St[n >> 24 & 255]).toLowerCase();
|
|
286
286
|
}
|
|
@@ -334,7 +334,7 @@ function Rt(i, e) {
|
|
|
334
334
|
}
|
|
335
335
|
}
|
|
336
336
|
const eh = {
|
|
337
|
-
DEG2RAD:
|
|
337
|
+
DEG2RAD: Ds
|
|
338
338
|
};
|
|
339
339
|
class Oe {
|
|
340
340
|
/**
|
|
@@ -915,13 +915,13 @@ class qn {
|
|
|
915
915
|
let p = 1 - o;
|
|
916
916
|
const d = l * f + c * m + h * _ + u * v, b = d >= 0 ? 1 : -1, T = 1 - d * d;
|
|
917
917
|
if (T > Number.EPSILON) {
|
|
918
|
-
const
|
|
919
|
-
p = Math.sin(p * A) /
|
|
918
|
+
const D = Math.sqrt(T), A = Math.atan2(D, d * b);
|
|
919
|
+
p = Math.sin(p * A) / D, o = Math.sin(o * A) / D;
|
|
920
920
|
}
|
|
921
921
|
const S = o * b;
|
|
922
922
|
if (l = l * p + f * S, c = c * p + m * S, h = h * p + _ * S, u = u * p + v * S, p === 1 - o) {
|
|
923
|
-
const
|
|
924
|
-
l *=
|
|
923
|
+
const D = 1 / Math.sqrt(l * l + c * c + h * h + u * u);
|
|
924
|
+
l *= D, c *= D, h *= D, u *= D;
|
|
925
925
|
}
|
|
926
926
|
}
|
|
927
927
|
e[t] = l, e[t + 1] = c, e[t + 2] = h, e[t + 3] = u;
|
|
@@ -2219,8 +2219,8 @@ class ze {
|
|
|
2219
2219
|
* @return {Matrix3} A reference to this matrix.
|
|
2220
2220
|
*/
|
|
2221
2221
|
multiplyMatrices(e, t) {
|
|
2222
|
-
const n = e.elements, s = t.elements, r = this.elements, a = n[0], o = n[3], l = n[6], c = n[1], h = n[4], u = n[7], f = n[2], m = n[5], _ = n[8], v = s[0], p = s[3], d = s[6], b = s[1], T = s[4], S = s[7],
|
|
2223
|
-
return r[0] = a * v + o * b + l *
|
|
2222
|
+
const n = e.elements, s = t.elements, r = this.elements, a = n[0], o = n[3], l = n[6], c = n[1], h = n[4], u = n[7], f = n[2], m = n[5], _ = n[8], v = s[0], p = s[3], d = s[6], b = s[1], T = s[4], S = s[7], D = s[2], A = s[5], C = s[8];
|
|
2223
|
+
return r[0] = a * v + o * b + l * D, r[3] = a * p + o * T + l * A, r[6] = a * d + o * S + l * C, r[1] = c * v + h * b + u * D, r[4] = c * p + h * T + u * A, r[7] = c * d + h * S + u * C, r[2] = f * v + m * b + _ * D, r[5] = f * p + m * T + _ * A, r[8] = f * d + m * S + _ * C, this;
|
|
2224
2224
|
}
|
|
2225
2225
|
/**
|
|
2226
2226
|
* Multiplies every component of the matrix by the given scalar.
|
|
@@ -2456,16 +2456,16 @@ class ze {
|
|
|
2456
2456
|
}
|
|
2457
2457
|
}
|
|
2458
2458
|
const Zs = /* @__PURE__ */ new ze();
|
|
2459
|
-
function
|
|
2459
|
+
function pl(i) {
|
|
2460
2460
|
for (let e = i.length - 1; e >= 0; --e)
|
|
2461
2461
|
if (i[e] >= 65535) return !0;
|
|
2462
2462
|
return !1;
|
|
2463
2463
|
}
|
|
2464
|
-
function
|
|
2464
|
+
function Xi(i) {
|
|
2465
2465
|
return document.createElementNS("http://www.w3.org/1999/xhtml", i);
|
|
2466
2466
|
}
|
|
2467
2467
|
function th() {
|
|
2468
|
-
const i =
|
|
2468
|
+
const i = Xi("canvas");
|
|
2469
2469
|
return i.style.display = "block", i;
|
|
2470
2470
|
}
|
|
2471
2471
|
const Ga = {};
|
|
@@ -2554,7 +2554,7 @@ function rh() {
|
|
|
2554
2554
|
return this.spaces[s].primaries;
|
|
2555
2555
|
},
|
|
2556
2556
|
getTransfer: function(s) {
|
|
2557
|
-
return s === Cn ?
|
|
2557
|
+
return s === Cn ? Fs : this.spaces[s].transfer;
|
|
2558
2558
|
},
|
|
2559
2559
|
getLuminanceCoefficients: function(s, r = this.workingColorSpace) {
|
|
2560
2560
|
return s.fromArray(this.spaces[r].luminanceCoefficients);
|
|
@@ -2584,7 +2584,7 @@ function rh() {
|
|
|
2584
2584
|
[Ei]: {
|
|
2585
2585
|
primaries: e,
|
|
2586
2586
|
whitePoint: n,
|
|
2587
|
-
transfer:
|
|
2587
|
+
transfer: Fs,
|
|
2588
2588
|
toXYZ: Wa,
|
|
2589
2589
|
fromXYZ: Xa,
|
|
2590
2590
|
luminanceCoefficients: t,
|
|
@@ -2625,7 +2625,7 @@ class ah {
|
|
|
2625
2625
|
if (e instanceof HTMLCanvasElement)
|
|
2626
2626
|
n = e;
|
|
2627
2627
|
else {
|
|
2628
|
-
Jn === void 0 && (Jn =
|
|
2628
|
+
Jn === void 0 && (Jn = Xi("canvas")), Jn.width = e.width, Jn.height = e.height;
|
|
2629
2629
|
const s = Jn.getContext("2d");
|
|
2630
2630
|
e instanceof ImageData ? s.putImageData(e, 0, 0) : s.drawImage(e, 0, 0, e.width, e.height), n = Jn;
|
|
2631
2631
|
}
|
|
@@ -2639,7 +2639,7 @@ class ah {
|
|
|
2639
2639
|
*/
|
|
2640
2640
|
static sRGBToLinear(e) {
|
|
2641
2641
|
if (typeof HTMLImageElement < "u" && e instanceof HTMLImageElement || typeof HTMLCanvasElement < "u" && e instanceof HTMLCanvasElement || typeof ImageBitmap < "u" && e instanceof ImageBitmap) {
|
|
2642
|
-
const t =
|
|
2642
|
+
const t = Xi("canvas");
|
|
2643
2643
|
t.width = e.width, t.height = e.height;
|
|
2644
2644
|
const n = t.getContext("2d");
|
|
2645
2645
|
n.drawImage(e, 0, 0, e.width, e.height);
|
|
@@ -2668,7 +2668,7 @@ class Aa {
|
|
|
2668
2668
|
* @param {any} [data=null] - The data definition of a texture.
|
|
2669
2669
|
*/
|
|
2670
2670
|
constructor(e = null) {
|
|
2671
|
-
this.isSource = !0, Object.defineProperty(this, "id", { value: oh++ }), this.uuid =
|
|
2671
|
+
this.isSource = !0, Object.defineProperty(this, "id", { value: oh++ }), this.uuid = Yi(), this.data = e, this.dataReady = !0, this.version = 0;
|
|
2672
2672
|
}
|
|
2673
2673
|
getSize(e) {
|
|
2674
2674
|
const t = this.data;
|
|
@@ -2740,7 +2740,7 @@ class At extends jn {
|
|
|
2740
2740
|
* @param {string} [colorSpace=NoColorSpace] - The color space.
|
|
2741
2741
|
*/
|
|
2742
2742
|
constructor(e = At.DEFAULT_IMAGE, t = At.DEFAULT_MAPPING, n = Gn, s = Gn, r = tn, a = Wn, o = Yt, l = sn, c = At.DEFAULT_ANISOTROPY, h = Cn) {
|
|
2743
|
-
super(), this.isTexture = !0, Object.defineProperty(this, "id", { value: lh++ }), this.uuid =
|
|
2743
|
+
super(), this.isTexture = !0, Object.defineProperty(this, "id", { value: lh++ }), this.uuid = Yi(), this.name = "", this.source = new Aa(e), this.mipmaps = [], this.mapping = t, this.channel = 0, this.wrapS = n, this.wrapT = s, this.magFilter = r, this.minFilter = a, this.anisotropy = c, this.format = o, this.internalFormat = null, this.type = l, this.offset = new Oe(0, 0), this.repeat = new Oe(1, 1), this.center = new Oe(0, 0), this.rotation = 0, this.matrixAutoUpdate = !0, this.matrix = new ze(), this.generateMipmaps = !0, this.premultiplyAlpha = !1, this.flipY = !0, this.unpackAlignment = 4, this.colorSpace = h, this.userData = {}, this.updateRanges = [], this.version = 0, this.onUpdate = null, this.renderTarget = null, this.isRenderTargetTexture = !1, this.isArrayTexture = !!(e && e.depth && e.depth > 1), this.pmremVersion = 0;
|
|
2744
2744
|
}
|
|
2745
2745
|
/**
|
|
2746
2746
|
* The width of the texture in pixels.
|
|
@@ -2886,10 +2886,10 @@ class At extends jn {
|
|
|
2886
2886
|
* @return {Vector2} The transformed uv vector.
|
|
2887
2887
|
*/
|
|
2888
2888
|
transformUv(e) {
|
|
2889
|
-
if (this.mapping !==
|
|
2889
|
+
if (this.mapping !== il) return e;
|
|
2890
2890
|
if (e.applyMatrix3(this.matrix), e.x < 0 || e.x > 1)
|
|
2891
2891
|
switch (this.wrapS) {
|
|
2892
|
-
case
|
|
2892
|
+
case Ns:
|
|
2893
2893
|
e.x = e.x - Math.floor(e.x);
|
|
2894
2894
|
break;
|
|
2895
2895
|
case Gn:
|
|
@@ -2901,7 +2901,7 @@ class At extends jn {
|
|
|
2901
2901
|
}
|
|
2902
2902
|
if (e.y < 0 || e.y > 1)
|
|
2903
2903
|
switch (this.wrapT) {
|
|
2904
|
-
case
|
|
2904
|
+
case Ns:
|
|
2905
2905
|
e.y = e.y - Math.floor(e.y);
|
|
2906
2906
|
break;
|
|
2907
2907
|
case Gn:
|
|
@@ -2938,7 +2938,7 @@ class At extends jn {
|
|
|
2938
2938
|
}
|
|
2939
2939
|
}
|
|
2940
2940
|
At.DEFAULT_IMAGE = null;
|
|
2941
|
-
At.DEFAULT_MAPPING =
|
|
2941
|
+
At.DEFAULT_MAPPING = il;
|
|
2942
2942
|
At.DEFAULT_ANISOTROPY = 1;
|
|
2943
2943
|
class ct {
|
|
2944
2944
|
/**
|
|
@@ -3234,8 +3234,8 @@ class ct {
|
|
|
3234
3234
|
if (Math.abs(h + f) < 0.1 && Math.abs(u + v) < 0.1 && Math.abs(_ + p) < 0.1 && Math.abs(c + m + d - 3) < 0.1)
|
|
3235
3235
|
return this.set(1, 0, 0, 0), this;
|
|
3236
3236
|
t = Math.PI;
|
|
3237
|
-
const T = (c + 1) / 2, S = (m + 1) / 2,
|
|
3238
|
-
return T > S && T >
|
|
3237
|
+
const T = (c + 1) / 2, S = (m + 1) / 2, D = (d + 1) / 2, A = (h + f) / 4, C = (u + v) / 4, F = (_ + p) / 4;
|
|
3238
|
+
return T > S && T > D ? T < 0.01 ? (n = 0, s = 0.707106781, r = 0.707106781) : (n = Math.sqrt(T), s = A / n, r = C / n) : S > D ? S < 0.01 ? (n = 0.707106781, s = 0, r = 0.707106781) : (s = Math.sqrt(S), n = A / s, r = F / s) : D < 0.01 ? (n = 0.707106781, s = 0.707106781, r = 0) : (r = Math.sqrt(D), n = C / r, s = F / r), this.set(n, s, r, t), this;
|
|
3239
3239
|
}
|
|
3240
3240
|
let b = Math.sqrt((p - _) * (p - _) + (u - v) * (u - v) + (f - h) * (f - h));
|
|
3241
3241
|
return Math.abs(b) < 1e-3 && (b = 1), this.x = (p - _) / b, this.y = (u - v) / b, this.z = (f - h) / b, this.w = Math.acos((c + m + d - 1) / 2), this;
|
|
@@ -3638,7 +3638,7 @@ class Yn extends ch {
|
|
|
3638
3638
|
super(e, t, n), this.isWebGLRenderTarget = !0;
|
|
3639
3639
|
}
|
|
3640
3640
|
}
|
|
3641
|
-
class
|
|
3641
|
+
class ml extends At {
|
|
3642
3642
|
/**
|
|
3643
3643
|
* Constructs a new data array texture.
|
|
3644
3644
|
*
|
|
@@ -4102,7 +4102,7 @@ function Qs(i, e, t, n, s) {
|
|
|
4102
4102
|
return !0;
|
|
4103
4103
|
}
|
|
4104
4104
|
const uh = /* @__PURE__ */ new Ti(), Ui = /* @__PURE__ */ new N(), er = /* @__PURE__ */ new N();
|
|
4105
|
-
class
|
|
4105
|
+
class ji {
|
|
4106
4106
|
/**
|
|
4107
4107
|
* Constructs a new sphere.
|
|
4108
4108
|
*
|
|
@@ -4322,7 +4322,7 @@ class Yi {
|
|
|
4322
4322
|
}
|
|
4323
4323
|
}
|
|
4324
4324
|
const on = /* @__PURE__ */ new N(), tr = /* @__PURE__ */ new N(), ts = /* @__PURE__ */ new N(), yn = /* @__PURE__ */ new N(), nr = /* @__PURE__ */ new N(), ns = /* @__PURE__ */ new N(), ir = /* @__PURE__ */ new N();
|
|
4325
|
-
class
|
|
4325
|
+
class Vs {
|
|
4326
4326
|
/**
|
|
4327
4327
|
* Constructs a new ray.
|
|
4328
4328
|
*
|
|
@@ -4865,8 +4865,8 @@ class st {
|
|
|
4865
4865
|
* @return {Matrix4} A reference to this matrix.
|
|
4866
4866
|
*/
|
|
4867
4867
|
multiplyMatrices(e, t) {
|
|
4868
|
-
const n = e.elements, s = t.elements, r = this.elements, a = n[0], o = n[4], l = n[8], c = n[12], h = n[1], u = n[5], f = n[9], m = n[13], _ = n[2], v = n[6], p = n[10], d = n[14], b = n[3], T = n[7], S = n[11],
|
|
4869
|
-
return r[0] = a * A + o * M + l * j + c * V, r[4] = a * C + o * P + l * te + c * de, r[8] = a * F + o * q + l * K + c * ge, r[12] = a * E + o * k + l * re + c * be, r[1] = h * A + u * M + f * j + m * V, r[5] = h * C + u * P + f * te + m * de, r[9] = h * F + u * q + f * K + m * ge, r[13] = h * E + u * k + f * re + m * be, r[2] = _ * A + v * M + p * j + d * V, r[6] = _ * C + v * P + p * te + d * de, r[10] = _ * F + v * q + p * K + d * ge, r[14] = _ * E + v * k + p * re + d * be, r[3] = b * A + T * M + S * j +
|
|
4868
|
+
const n = e.elements, s = t.elements, r = this.elements, a = n[0], o = n[4], l = n[8], c = n[12], h = n[1], u = n[5], f = n[9], m = n[13], _ = n[2], v = n[6], p = n[10], d = n[14], b = n[3], T = n[7], S = n[11], D = n[15], A = s[0], C = s[4], F = s[8], E = s[12], M = s[1], P = s[5], q = s[9], k = s[13], j = s[2], te = s[6], K = s[10], re = s[14], V = s[3], de = s[7], ge = s[11], be = s[15];
|
|
4869
|
+
return r[0] = a * A + o * M + l * j + c * V, r[4] = a * C + o * P + l * te + c * de, r[8] = a * F + o * q + l * K + c * ge, r[12] = a * E + o * k + l * re + c * be, r[1] = h * A + u * M + f * j + m * V, r[5] = h * C + u * P + f * te + m * de, r[9] = h * F + u * q + f * K + m * ge, r[13] = h * E + u * k + f * re + m * be, r[2] = _ * A + v * M + p * j + d * V, r[6] = _ * C + v * P + p * te + d * de, r[10] = _ * F + v * q + p * K + d * ge, r[14] = _ * E + v * k + p * re + d * be, r[3] = b * A + T * M + S * j + D * V, r[7] = b * C + T * P + S * te + D * de, r[11] = b * F + T * q + S * K + D * ge, r[15] = b * E + T * k + S * re + D * be, this;
|
|
4870
4870
|
}
|
|
4871
4871
|
/**
|
|
4872
4872
|
* Multiplies every component of the matrix by the given scalar.
|
|
@@ -4920,10 +4920,10 @@ class st {
|
|
|
4920
4920
|
* @return {Matrix4} A reference to this matrix.
|
|
4921
4921
|
*/
|
|
4922
4922
|
invert() {
|
|
4923
|
-
const e = this.elements, t = e[0], n = e[1], s = e[2], r = e[3], a = e[4], o = e[5], l = e[6], c = e[7], h = e[8], u = e[9], f = e[10], m = e[11], _ = e[12], v = e[13], p = e[14], d = e[15], b = u * p * c - v * f * c + v * l * m - o * p * m - u * l * d + o * f * d, T = _ * f * c - h * p * c - _ * l * m + a * p * m + h * l * d - a * f * d, S = h * v * c - _ * u * c + _ * o * m - a * v * m - h * o * d + a * u * d,
|
|
4923
|
+
const e = this.elements, t = e[0], n = e[1], s = e[2], r = e[3], a = e[4], o = e[5], l = e[6], c = e[7], h = e[8], u = e[9], f = e[10], m = e[11], _ = e[12], v = e[13], p = e[14], d = e[15], b = u * p * c - v * f * c + v * l * m - o * p * m - u * l * d + o * f * d, T = _ * f * c - h * p * c - _ * l * m + a * p * m + h * l * d - a * f * d, S = h * v * c - _ * u * c + _ * o * m - a * v * m - h * o * d + a * u * d, D = _ * u * l - h * v * l - _ * o * f + a * v * f + h * o * p - a * u * p, A = t * b + n * T + s * S + r * D;
|
|
4924
4924
|
if (A === 0) return this.set(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
|
|
4925
4925
|
const C = 1 / A;
|
|
4926
|
-
return e[0] = b * C, e[1] = (v * f * r - u * p * r - v * s * m + n * p * m + u * s * d - n * f * d) * C, e[2] = (o * p * r - v * l * r + v * s * c - n * p * c - o * s * d + n * l * d) * C, e[3] = (u * l * r - o * f * r - u * s * c + n * f * c + o * s * m - n * l * m) * C, e[4] = T * C, e[5] = (h * p * r - _ * f * r + _ * s * m - t * p * m - h * s * d + t * f * d) * C, e[6] = (_ * l * r - a * p * r - _ * s * c + t * p * c + a * s * d - t * l * d) * C, e[7] = (a * f * r - h * l * r + h * s * c - t * f * c - a * s * m + t * l * m) * C, e[8] = S * C, e[9] = (_ * u * r - h * v * r - _ * n * m + t * v * m + h * n * d - t * u * d) * C, e[10] = (a * v * r - _ * o * r + _ * n * c - t * v * c - a * n * d + t * o * d) * C, e[11] = (h * o * r - a * u * r - h * n * c + t * u * c + a * n * m - t * o * m) * C, e[12] =
|
|
4926
|
+
return e[0] = b * C, e[1] = (v * f * r - u * p * r - v * s * m + n * p * m + u * s * d - n * f * d) * C, e[2] = (o * p * r - v * l * r + v * s * c - n * p * c - o * s * d + n * l * d) * C, e[3] = (u * l * r - o * f * r - u * s * c + n * f * c + o * s * m - n * l * m) * C, e[4] = T * C, e[5] = (h * p * r - _ * f * r + _ * s * m - t * p * m - h * s * d + t * f * d) * C, e[6] = (_ * l * r - a * p * r - _ * s * c + t * p * c + a * s * d - t * l * d) * C, e[7] = (a * f * r - h * l * r + h * s * c - t * f * c - a * s * m + t * l * m) * C, e[8] = S * C, e[9] = (_ * u * r - h * v * r - _ * n * m + t * v * m + h * n * d - t * u * d) * C, e[10] = (a * v * r - _ * o * r + _ * n * c - t * v * c - a * n * d + t * o * d) * C, e[11] = (h * o * r - a * u * r - h * n * c + t * u * c + a * n * m - t * o * m) * C, e[12] = D * C, e[13] = (h * v * s - _ * u * s + _ * n * f - t * v * f - h * n * p + t * u * p) * C, e[14] = (_ * o * s - a * v * s - _ * n * l + t * v * l + a * n * p - t * o * p) * C, e[15] = (a * u * s - h * o * s + h * n * l - t * u * l - a * n * f + t * o * f) * C, this;
|
|
4927
4927
|
}
|
|
4928
4928
|
/**
|
|
4929
4929
|
* Multiplies the columns of this matrix by the given vector.
|
|
@@ -5174,8 +5174,8 @@ class st {
|
|
|
5174
5174
|
* @return {Matrix4} A reference to this matrix.
|
|
5175
5175
|
*/
|
|
5176
5176
|
compose(e, t, n) {
|
|
5177
|
-
const s = this.elements, r = t._x, a = t._y, o = t._z, l = t._w, c = r + r, h = a + a, u = o + o, f = r * c, m = r * h, _ = r * u, v = a * h, p = a * u, d = o * u, b = l * c, T = l * h, S = l * u,
|
|
5178
|
-
return s[0] = (1 - (v + d)) *
|
|
5177
|
+
const s = this.elements, r = t._x, a = t._y, o = t._z, l = t._w, c = r + r, h = a + a, u = o + o, f = r * c, m = r * h, _ = r * u, v = a * h, p = a * u, d = o * u, b = l * c, T = l * h, S = l * u, D = n.x, A = n.y, C = n.z;
|
|
5178
|
+
return s[0] = (1 - (v + d)) * D, s[1] = (m + S) * D, s[2] = (_ - T) * D, s[3] = 0, s[4] = (m - S) * A, s[5] = (1 - (f + d)) * A, s[6] = (p + b) * A, s[7] = 0, s[8] = (_ + T) * C, s[9] = (p - b) * C, s[10] = (1 - (f + v)) * C, s[11] = 0, s[12] = e.x, s[13] = e.y, s[14] = e.z, s[15] = 1, this;
|
|
5179
5179
|
}
|
|
5180
5180
|
/**
|
|
5181
5181
|
* Decomposes this matrix into its position, rotation and scale components
|
|
@@ -5216,7 +5216,7 @@ class st {
|
|
|
5216
5216
|
let m, _;
|
|
5217
5217
|
if (o === _n)
|
|
5218
5218
|
m = -(a + r) / (a - r), _ = -2 * a * r / (a - r);
|
|
5219
|
-
else if (o ===
|
|
5219
|
+
else if (o === Os)
|
|
5220
5220
|
m = -a / (a - r), _ = -a * r / (a - r);
|
|
5221
5221
|
else
|
|
5222
5222
|
throw new Error("THREE.Matrix4.makePerspective(): Invalid coordinate system: " + o);
|
|
@@ -5240,7 +5240,7 @@ class st {
|
|
|
5240
5240
|
let _, v;
|
|
5241
5241
|
if (o === _n)
|
|
5242
5242
|
_ = (a + r) * u, v = -2 * u;
|
|
5243
|
-
else if (o ===
|
|
5243
|
+
else if (o === Os)
|
|
5244
5244
|
_ = r * u, v = -1 * u;
|
|
5245
5245
|
else
|
|
5246
5246
|
throw new Error("THREE.Matrix4.makeOrthographic(): Invalid coordinate system: " + o);
|
|
@@ -5482,7 +5482,7 @@ class rn {
|
|
|
5482
5482
|
}
|
|
5483
5483
|
}
|
|
5484
5484
|
rn.DEFAULT_ORDER = "XYZ";
|
|
5485
|
-
class
|
|
5485
|
+
class _l {
|
|
5486
5486
|
/**
|
|
5487
5487
|
* Constructs a new layers instance, with membership
|
|
5488
5488
|
* initially set to layer `0`.
|
|
@@ -5561,7 +5561,7 @@ class gt extends jn {
|
|
|
5561
5561
|
* Constructs a new 3D object.
|
|
5562
5562
|
*/
|
|
5563
5563
|
constructor() {
|
|
5564
|
-
super(), this.isObject3D = !0, Object.defineProperty(this, "id", { value: ph++ }), this.uuid =
|
|
5564
|
+
super(), this.isObject3D = !0, Object.defineProperty(this, "id", { value: ph++ }), this.uuid = Yi(), this.name = "", this.type = "Object3D", this.parent = null, this.children = [], this.up = gt.DEFAULT_UP.clone();
|
|
5565
5565
|
const e = new N(), t = new rn(), n = new qn(), s = new N(1, 1, 1);
|
|
5566
5566
|
function r() {
|
|
5567
5567
|
n.setFromEuler(t, !1);
|
|
@@ -5635,7 +5635,7 @@ class gt extends jn {
|
|
|
5635
5635
|
normalMatrix: {
|
|
5636
5636
|
value: new ze()
|
|
5637
5637
|
}
|
|
5638
|
-
}), this.matrix = new st(), this.matrixWorld = new st(), this.matrixAutoUpdate = gt.DEFAULT_MATRIX_AUTO_UPDATE, this.matrixWorldAutoUpdate = gt.DEFAULT_MATRIX_WORLD_AUTO_UPDATE, this.matrixWorldNeedsUpdate = !1, this.layers = new
|
|
5638
|
+
}), this.matrix = new st(), this.matrixWorld = new st(), this.matrixAutoUpdate = gt.DEFAULT_MATRIX_AUTO_UPDATE, this.matrixWorldAutoUpdate = gt.DEFAULT_MATRIX_WORLD_AUTO_UPDATE, this.matrixWorldNeedsUpdate = !1, this.layers = new _l(), this.visible = !0, this.castShadow = !1, this.receiveShadow = !1, this.frustumCulled = !0, this.renderOrder = 0, this.animations = [], this.customDepthMaterial = void 0, this.customDistanceMaterial = void 0, this.userData = {};
|
|
5639
5639
|
}
|
|
5640
5640
|
/**
|
|
5641
5641
|
* A callback that is executed immediately before a 3D object is rendered to a shadow map.
|
|
@@ -6500,7 +6500,7 @@ class Xt {
|
|
|
6500
6500
|
return e.a.equals(this.a) && e.b.equals(this.b) && e.c.equals(this.c);
|
|
6501
6501
|
}
|
|
6502
6502
|
}
|
|
6503
|
-
const
|
|
6503
|
+
const gl = {
|
|
6504
6504
|
aliceblue: 15792383,
|
|
6505
6505
|
antiquewhite: 16444375,
|
|
6506
6506
|
aqua: 65535,
|
|
@@ -6813,7 +6813,7 @@ class Ge {
|
|
|
6813
6813
|
* @return {Color} A reference to this color.
|
|
6814
6814
|
*/
|
|
6815
6815
|
setColorName(e, t = xt) {
|
|
6816
|
-
const n =
|
|
6816
|
+
const n = gl[e.toLowerCase()];
|
|
6817
6817
|
return n !== void 0 ? this.setHex(n, t) : console.warn("THREE.Color: Unknown color " + e), this;
|
|
6818
6818
|
}
|
|
6819
6819
|
/**
|
|
@@ -7122,14 +7122,14 @@ class Ge {
|
|
|
7122
7122
|
}
|
|
7123
7123
|
}
|
|
7124
7124
|
const Et = /* @__PURE__ */ new Ge();
|
|
7125
|
-
Ge.NAMES =
|
|
7125
|
+
Ge.NAMES = gl;
|
|
7126
7126
|
let vh = 0;
|
|
7127
7127
|
class xn extends jn {
|
|
7128
7128
|
/**
|
|
7129
7129
|
* Constructs a new material.
|
|
7130
7130
|
*/
|
|
7131
7131
|
constructor() {
|
|
7132
|
-
super(), this.isMaterial = !0, Object.defineProperty(this, "id", { value: vh++ }), this.uuid =
|
|
7132
|
+
super(), this.isMaterial = !0, Object.defineProperty(this, "id", { value: vh++ }), this.uuid = Yi(), this.name = "", this.type = "Material", this.blending = mi, this.side = vn, this.vertexColors = !1, this.opacity = 1, this.transparent = !1, this.alphaHash = !1, this.blendSrc = Rr, this.blendDst = Cr, this.blendEquation = kn, this.blendSrcAlpha = null, this.blendDstAlpha = null, this.blendEquationAlpha = null, this.blendColor = new Ge(0, 0, 0), this.blendAlpha = 0, this.depthFunc = xi, this.depthTest = !0, this.depthWrite = !0, this.stencilWriteMask = 255, this.stencilFunc = za, this.stencilRef = 0, this.stencilFuncMask = 255, this.stencilFail = $n, this.stencilZFail = $n, this.stencilZPass = $n, this.stencilWrite = !1, this.clippingPlanes = null, this.clipIntersection = !1, this.clipShadows = !1, this.shadowSide = null, this.colorWrite = !0, this.precision = null, this.polygonOffset = !1, this.polygonOffsetFactor = 0, this.polygonOffsetUnits = 0, this.dithering = !1, this.alphaToCoverage = !1, this.premultipliedAlpha = !1, this.forceSinglePass = !1, this.allowOverride = !0, this.visible = !0, this.toneMapped = !0, this.userData = {}, this.version = 0, this._alphaTest = 0;
|
|
7133
7133
|
}
|
|
7134
7134
|
/**
|
|
7135
7135
|
* Sets the alpha value to be used when running an alpha test. The material
|
|
@@ -7290,7 +7290,7 @@ class xn extends jn {
|
|
|
7290
7290
|
e === !0 && this.version++;
|
|
7291
7291
|
}
|
|
7292
7292
|
}
|
|
7293
|
-
class
|
|
7293
|
+
class vl extends xn {
|
|
7294
7294
|
/**
|
|
7295
7295
|
* Constructs a new mesh basic material.
|
|
7296
7296
|
*
|
|
@@ -7631,7 +7631,7 @@ class nn {
|
|
|
7631
7631
|
return this.name !== "" && (e.name = this.name), this.usage !== Ha && (e.usage = this.usage), e;
|
|
7632
7632
|
}
|
|
7633
7633
|
}
|
|
7634
|
-
class
|
|
7634
|
+
class xl extends nn {
|
|
7635
7635
|
/**
|
|
7636
7636
|
* Constructs a new buffer attribute.
|
|
7637
7637
|
*
|
|
@@ -7643,7 +7643,7 @@ class vl extends nn {
|
|
|
7643
7643
|
super(new Uint16Array(e), t, n);
|
|
7644
7644
|
}
|
|
7645
7645
|
}
|
|
7646
|
-
class
|
|
7646
|
+
class Ml extends nn {
|
|
7647
7647
|
/**
|
|
7648
7648
|
* Constructs a new buffer attribute.
|
|
7649
7649
|
*
|
|
@@ -7674,7 +7674,7 @@ class Zt extends jn {
|
|
|
7674
7674
|
* Constructs a new geometry.
|
|
7675
7675
|
*/
|
|
7676
7676
|
constructor() {
|
|
7677
|
-
super(), this.isBufferGeometry = !0, Object.defineProperty(this, "id", { value: Mh++ }), this.uuid =
|
|
7677
|
+
super(), this.isBufferGeometry = !0, Object.defineProperty(this, "id", { value: Mh++ }), this.uuid = Yi(), this.name = "", this.type = "BufferGeometry", this.index = null, this.indirect = null, this.attributes = {}, this.morphAttributes = {}, this.morphTargetsRelative = !1, this.groups = [], this.boundingBox = null, this.boundingSphere = null, this.drawRange = { start: 0, count: 1 / 0 }, this.userData = {};
|
|
7678
7678
|
}
|
|
7679
7679
|
/**
|
|
7680
7680
|
* Returns the index of this geometry.
|
|
@@ -7691,7 +7691,7 @@ class Zt extends jn {
|
|
|
7691
7691
|
* @return {BufferGeometry} A reference to this instance.
|
|
7692
7692
|
*/
|
|
7693
7693
|
setIndex(e) {
|
|
7694
|
-
return Array.isArray(e) ? this.index = new (
|
|
7694
|
+
return Array.isArray(e) ? this.index = new (pl(e) ? Ml : xl)(e, 1) : this.index = e, this;
|
|
7695
7695
|
}
|
|
7696
7696
|
/**
|
|
7697
7697
|
* Sets the given indirect attribute to this geometry.
|
|
@@ -7944,7 +7944,7 @@ class Zt extends jn {
|
|
|
7944
7944
|
* You may need to recompute the bounding sphere if the geometry vertices are modified.
|
|
7945
7945
|
*/
|
|
7946
7946
|
computeBoundingSphere() {
|
|
7947
|
-
this.boundingSphere === null && (this.boundingSphere = new
|
|
7947
|
+
this.boundingSphere === null && (this.boundingSphere = new ji());
|
|
7948
7948
|
const e = this.attributes.position, t = this.morphAttributes.position;
|
|
7949
7949
|
if (e && e.isGLBufferAttribute) {
|
|
7950
7950
|
console.error("THREE.BufferGeometry.computeBoundingSphere(): GLBufferAttribute requires a manual bounding sphere.", this), this.boundingSphere.set(new N(), 1 / 0);
|
|
@@ -8008,11 +8008,11 @@ class Zt extends jn {
|
|
|
8008
8008
|
e.getX(k + 2)
|
|
8009
8009
|
);
|
|
8010
8010
|
}
|
|
8011
|
-
const T = new N(), S = new N(),
|
|
8011
|
+
const T = new N(), S = new N(), D = new N(), A = new N();
|
|
8012
8012
|
function C(F) {
|
|
8013
|
-
|
|
8013
|
+
D.fromBufferAttribute(s, F), A.copy(D);
|
|
8014
8014
|
const E = o[F];
|
|
8015
|
-
T.copy(E), T.sub(
|
|
8015
|
+
T.copy(E), T.sub(D.multiplyScalar(D.dot(E))).normalize(), S.crossVectors(A, E);
|
|
8016
8016
|
const P = S.dot(l[F]) < 0 ? -1 : 1;
|
|
8017
8017
|
a.setXYZW(F, T.x, T.y, T.z, P);
|
|
8018
8018
|
}
|
|
@@ -8198,7 +8198,7 @@ class Zt extends jn {
|
|
|
8198
8198
|
this.dispatchEvent({ type: "dispose" });
|
|
8199
8199
|
}
|
|
8200
8200
|
}
|
|
8201
|
-
const eo = /* @__PURE__ */ new st(), Fn = /* @__PURE__ */ new
|
|
8201
|
+
const eo = /* @__PURE__ */ new st(), Fn = /* @__PURE__ */ new Vs(), os = /* @__PURE__ */ new ji(), to = /* @__PURE__ */ new N(), ls = /* @__PURE__ */ new N(), cs = /* @__PURE__ */ new N(), hs = /* @__PURE__ */ new N(), pr = /* @__PURE__ */ new N(), us = /* @__PURE__ */ new N(), no = /* @__PURE__ */ new N(), ds = /* @__PURE__ */ new N();
|
|
8202
8202
|
class jt extends gt {
|
|
8203
8203
|
/**
|
|
8204
8204
|
* Constructs a new mesh.
|
|
@@ -8206,7 +8206,7 @@ class jt extends gt {
|
|
|
8206
8206
|
* @param {BufferGeometry} [geometry] - The mesh geometry.
|
|
8207
8207
|
* @param {Material|Array<Material>} [material] - The mesh material.
|
|
8208
8208
|
*/
|
|
8209
|
-
constructor(e = new Zt(), t = new
|
|
8209
|
+
constructor(e = new Zt(), t = new vl()) {
|
|
8210
8210
|
super(), this.isMesh = !0, this.type = "Mesh", this.geometry = e, this.material = t, this.morphTargetDictionary = void 0, this.morphTargetInfluences = void 0, this.count = 1, this.updateMorphTargets();
|
|
8211
8211
|
}
|
|
8212
8212
|
copy(e, t) {
|
|
@@ -8268,7 +8268,7 @@ class jt extends gt {
|
|
|
8268
8268
|
if (Array.isArray(a))
|
|
8269
8269
|
for (let _ = 0, v = f.length; _ < v; _++) {
|
|
8270
8270
|
const p = f[_], d = a[p.materialIndex], b = Math.max(p.start, m.start), T = Math.min(o.count, Math.min(p.start + p.count, m.start + m.count));
|
|
8271
|
-
for (let S = b,
|
|
8271
|
+
for (let S = b, D = T; S < D; S += 3) {
|
|
8272
8272
|
const A = o.getX(S), C = o.getX(S + 1), F = o.getX(S + 2);
|
|
8273
8273
|
s = fs(this, d, e, n, c, h, u, A, C, F), s && (s.faceIndex = Math.floor(S / 3), s.face.materialIndex = p.materialIndex, t.push(s));
|
|
8274
8274
|
}
|
|
@@ -8284,7 +8284,7 @@ class jt extends gt {
|
|
|
8284
8284
|
if (Array.isArray(a))
|
|
8285
8285
|
for (let _ = 0, v = f.length; _ < v; _++) {
|
|
8286
8286
|
const p = f[_], d = a[p.materialIndex], b = Math.max(p.start, m.start), T = Math.min(l.count, Math.min(p.start + p.count, m.start + m.count));
|
|
8287
|
-
for (let S = b,
|
|
8287
|
+
for (let S = b, D = T; S < D; S += 3) {
|
|
8288
8288
|
const A = S, C = S + 1, F = S + 2;
|
|
8289
8289
|
s = fs(this, d, e, n, c, h, u, A, C, F), s && (s.faceIndex = Math.floor(S / 3), s.face.materialIndex = p.materialIndex, t.push(s));
|
|
8290
8290
|
}
|
|
@@ -8326,7 +8326,7 @@ function fs(i, e, t, n, s, r, a, o, l, c) {
|
|
|
8326
8326
|
}
|
|
8327
8327
|
return h;
|
|
8328
8328
|
}
|
|
8329
|
-
class
|
|
8329
|
+
class Ki extends Zt {
|
|
8330
8330
|
/**
|
|
8331
8331
|
* Constructs a new box geometry.
|
|
8332
8332
|
*
|
|
@@ -8351,8 +8351,8 @@ class ji extends Zt {
|
|
|
8351
8351
|
const l = [], c = [], h = [], u = [];
|
|
8352
8352
|
let f = 0, m = 0;
|
|
8353
8353
|
_("z", "y", "x", -1, -1, n, t, e, a, r, 0), _("z", "y", "x", 1, -1, n, t, -e, a, r, 1), _("x", "z", "y", 1, 1, e, n, t, s, a, 2), _("x", "z", "y", 1, -1, e, n, -t, s, a, 3), _("x", "y", "z", 1, -1, e, t, n, s, r, 4), _("x", "y", "z", -1, -1, e, t, -n, s, r, 5), this.setIndex(l), this.setAttribute("position", new bt(c, 3)), this.setAttribute("normal", new bt(h, 3)), this.setAttribute("uv", new bt(u, 2));
|
|
8354
|
-
function _(v, p, d, b, T, S,
|
|
8355
|
-
const M = S / C, P =
|
|
8354
|
+
function _(v, p, d, b, T, S, D, A, C, F, E) {
|
|
8355
|
+
const M = S / C, P = D / F, q = S / 2, k = D / 2, j = A / 2, te = C + 1, K = F + 1;
|
|
8356
8356
|
let re = 0, V = 0;
|
|
8357
8357
|
const de = new N();
|
|
8358
8358
|
for (let ge = 0; ge < K; ge++) {
|
|
@@ -8381,7 +8381,7 @@ class ji extends Zt {
|
|
|
8381
8381
|
* @return {BoxGeometry} A new instance.
|
|
8382
8382
|
*/
|
|
8383
8383
|
static fromJSON(e) {
|
|
8384
|
-
return new
|
|
8384
|
+
return new Ki(e.width, e.height, e.depth, e.widthSegments, e.heightSegments, e.depthSegments);
|
|
8385
8385
|
}
|
|
8386
8386
|
}
|
|
8387
8387
|
function yi(i) {
|
|
@@ -8410,7 +8410,7 @@ function Eh(i) {
|
|
|
8410
8410
|
e.push(i[t].clone());
|
|
8411
8411
|
return e;
|
|
8412
8412
|
}
|
|
8413
|
-
function
|
|
8413
|
+
function Sl(i) {
|
|
8414
8414
|
const e = i.getRenderTarget();
|
|
8415
8415
|
return e === null ? i.outputColorSpace : e.isXRRenderTarget === !0 ? e.texture.colorSpace : je.workingColorSpace;
|
|
8416
8416
|
}
|
|
@@ -8482,7 +8482,7 @@ class Ln extends xn {
|
|
|
8482
8482
|
return Object.keys(n).length > 0 && (t.extensions = n), t;
|
|
8483
8483
|
}
|
|
8484
8484
|
}
|
|
8485
|
-
class
|
|
8485
|
+
class El extends gt {
|
|
8486
8486
|
/**
|
|
8487
8487
|
* Constructs a new camera.
|
|
8488
8488
|
*/
|
|
@@ -8515,7 +8515,7 @@ class Sl extends gt {
|
|
|
8515
8515
|
}
|
|
8516
8516
|
}
|
|
8517
8517
|
const An = /* @__PURE__ */ new N(), io = /* @__PURE__ */ new Oe(), so = /* @__PURE__ */ new Oe();
|
|
8518
|
-
class zt extends
|
|
8518
|
+
class zt extends El {
|
|
8519
8519
|
/**
|
|
8520
8520
|
* Constructs a new perspective camera.
|
|
8521
8521
|
*
|
|
@@ -8549,7 +8549,7 @@ class zt extends Sl {
|
|
|
8549
8549
|
* @return {number} The computed focal length.
|
|
8550
8550
|
*/
|
|
8551
8551
|
getFocalLength() {
|
|
8552
|
-
const e = Math.tan(
|
|
8552
|
+
const e = Math.tan(Ds * 0.5 * this.fov);
|
|
8553
8553
|
return 0.5 * this.getFilmHeight() / e;
|
|
8554
8554
|
}
|
|
8555
8555
|
/**
|
|
@@ -8559,7 +8559,7 @@ class zt extends Sl {
|
|
|
8559
8559
|
*/
|
|
8560
8560
|
getEffectiveFOV() {
|
|
8561
8561
|
return da * 2 * Math.atan(
|
|
8562
|
-
Math.tan(
|
|
8562
|
+
Math.tan(Ds * 0.5 * this.fov) / this.zoom
|
|
8563
8563
|
);
|
|
8564
8564
|
}
|
|
8565
8565
|
/**
|
|
@@ -8667,7 +8667,7 @@ class zt extends Sl {
|
|
|
8667
8667
|
*/
|
|
8668
8668
|
updateProjectionMatrix() {
|
|
8669
8669
|
const e = this.near;
|
|
8670
|
-
let t = e * Math.tan(
|
|
8670
|
+
let t = e * Math.tan(Ds * 0.5 * this.fov) / this.zoom, n = 2 * t, s = this.aspect * n, r = -0.5 * s;
|
|
8671
8671
|
const a = this.view;
|
|
8672
8672
|
if (this.view !== null && this.view.enabled) {
|
|
8673
8673
|
const l = a.fullWidth, c = a.fullHeight;
|
|
@@ -8713,7 +8713,7 @@ class Ah extends gt {
|
|
|
8713
8713
|
for (const c of t) this.remove(c);
|
|
8714
8714
|
if (e === _n)
|
|
8715
8715
|
n.up.set(0, 1, 0), n.lookAt(1, 0, 0), s.up.set(0, 1, 0), s.lookAt(-1, 0, 0), r.up.set(0, 0, -1), r.lookAt(0, 1, 0), a.up.set(0, 0, 1), a.lookAt(0, -1, 0), o.up.set(0, 1, 0), o.lookAt(0, 0, 1), l.up.set(0, 1, 0), l.lookAt(0, 0, -1);
|
|
8716
|
-
else if (e ===
|
|
8716
|
+
else if (e === Os)
|
|
8717
8717
|
n.up.set(0, -1, 0), n.lookAt(-1, 0, 0), s.up.set(0, -1, 0), s.lookAt(1, 0, 0), r.up.set(0, 0, 1), r.lookAt(0, 1, 0), a.up.set(0, 0, -1), a.lookAt(0, -1, 0), o.up.set(0, -1, 0), o.lookAt(0, 0, 1), l.up.set(0, -1, 0), l.lookAt(0, 0, -1);
|
|
8718
8718
|
else
|
|
8719
8719
|
throw new Error("THREE.CubeCamera.updateCoordinateSystem(): Invalid coordinate system: " + e);
|
|
@@ -8737,7 +8737,7 @@ class Ah extends gt {
|
|
|
8737
8737
|
n.texture.generateMipmaps = !1, e.setRenderTarget(n, 0, s), e.render(t, r), e.setRenderTarget(n, 1, s), e.render(t, a), e.setRenderTarget(n, 2, s), e.render(t, o), e.setRenderTarget(n, 3, s), e.render(t, l), e.setRenderTarget(n, 4, s), e.render(t, c), n.texture.generateMipmaps = v, e.setRenderTarget(n, 5, s), e.render(t, h), e.setRenderTarget(u, f, m), e.xr.enabled = _, n.texture.needsPMREMUpdate = !0;
|
|
8738
8738
|
}
|
|
8739
8739
|
}
|
|
8740
|
-
class
|
|
8740
|
+
class yl extends At {
|
|
8741
8741
|
/**
|
|
8742
8742
|
* Constructs a new cube texture.
|
|
8743
8743
|
*
|
|
@@ -8777,7 +8777,7 @@ class wh extends Yn {
|
|
|
8777
8777
|
constructor(e = 1, t = {}) {
|
|
8778
8778
|
super(e, e, t), this.isWebGLCubeRenderTarget = !0;
|
|
8779
8779
|
const n = { width: e, height: e, depth: 1 }, s = [n, n, n, n, n, n];
|
|
8780
|
-
this.texture = new
|
|
8780
|
+
this.texture = new yl(s), this._setTextureOptions(t), this.texture.isRenderTargetTexture = !0;
|
|
8781
8781
|
}
|
|
8782
8782
|
/**
|
|
8783
8783
|
* Converts the given equirectangular texture to a cube map.
|
|
@@ -8835,7 +8835,7 @@ class wh extends Yn {
|
|
|
8835
8835
|
}
|
|
8836
8836
|
`
|
|
8837
8837
|
)
|
|
8838
|
-
}, s = new
|
|
8838
|
+
}, s = new Ki(5, 5, 5), r = new Ln({
|
|
8839
8839
|
name: "CubemapFromEquirect",
|
|
8840
8840
|
uniforms: yi(n.uniforms),
|
|
8841
8841
|
vertexShader: n.vertexShader,
|
|
@@ -8862,7 +8862,7 @@ class wh extends Yn {
|
|
|
8862
8862
|
e.setRenderTarget(r);
|
|
8863
8863
|
}
|
|
8864
8864
|
}
|
|
8865
|
-
class
|
|
8865
|
+
class Bi extends gt {
|
|
8866
8866
|
constructor() {
|
|
8867
8867
|
super(), this.isGroup = !0, this.type = "Group";
|
|
8868
8868
|
}
|
|
@@ -8881,7 +8881,7 @@ class mr {
|
|
|
8881
8881
|
* @return {Group} A group representing the hand space of the XR controller.
|
|
8882
8882
|
*/
|
|
8883
8883
|
getHandSpace() {
|
|
8884
|
-
return this._hand === null && (this._hand = new
|
|
8884
|
+
return this._hand === null && (this._hand = new Bi(), this._hand.matrixAutoUpdate = !1, this._hand.visible = !1, this._hand.joints = {}, this._hand.inputState = { pinching: !1 }), this._hand;
|
|
8885
8885
|
}
|
|
8886
8886
|
/**
|
|
8887
8887
|
* Returns a group representing the target ray space of the XR controller.
|
|
@@ -8889,7 +8889,7 @@ class mr {
|
|
|
8889
8889
|
* @return {Group} A group representing the target ray space of the XR controller.
|
|
8890
8890
|
*/
|
|
8891
8891
|
getTargetRaySpace() {
|
|
8892
|
-
return this._targetRay === null && (this._targetRay = new
|
|
8892
|
+
return this._targetRay === null && (this._targetRay = new Bi(), this._targetRay.matrixAutoUpdate = !1, this._targetRay.visible = !1, this._targetRay.hasLinearVelocity = !1, this._targetRay.linearVelocity = new N(), this._targetRay.hasAngularVelocity = !1, this._targetRay.angularVelocity = new N()), this._targetRay;
|
|
8893
8893
|
}
|
|
8894
8894
|
/**
|
|
8895
8895
|
* Returns a group representing the grip space of the XR controller.
|
|
@@ -8897,7 +8897,7 @@ class mr {
|
|
|
8897
8897
|
* @return {Group} A group representing the grip space of the XR controller.
|
|
8898
8898
|
*/
|
|
8899
8899
|
getGripSpace() {
|
|
8900
|
-
return this._grip === null && (this._grip = new
|
|
8900
|
+
return this._grip === null && (this._grip = new Bi(), this._grip.matrixAutoUpdate = !1, this._grip.visible = !1, this._grip.hasLinearVelocity = !1, this._grip.linearVelocity = new N(), this._grip.hasAngularVelocity = !1, this._grip.angularVelocity = new N()), this._grip;
|
|
8901
8901
|
}
|
|
8902
8902
|
/**
|
|
8903
8903
|
* Dispatches the given event to the groups representing
|
|
@@ -8979,7 +8979,7 @@ class mr {
|
|
|
8979
8979
|
*/
|
|
8980
8980
|
_getHandJoint(e, t) {
|
|
8981
8981
|
if (e.joints[t.jointName] === void 0) {
|
|
8982
|
-
const n = new
|
|
8982
|
+
const n = new Bi();
|
|
8983
8983
|
n.matrixAutoUpdate = !1, n.visible = !1, e.joints[t.jointName] = n, e.add(n);
|
|
8984
8984
|
}
|
|
8985
8985
|
return e.joints[t.jointName];
|
|
@@ -9211,7 +9211,7 @@ class wn {
|
|
|
9211
9211
|
return new this.constructor().copy(this);
|
|
9212
9212
|
}
|
|
9213
9213
|
}
|
|
9214
|
-
const On = /* @__PURE__ */ new
|
|
9214
|
+
const On = /* @__PURE__ */ new ji(), ps = /* @__PURE__ */ new N();
|
|
9215
9215
|
class wa {
|
|
9216
9216
|
/**
|
|
9217
9217
|
* Constructs a new frustum.
|
|
@@ -9264,7 +9264,7 @@ class wa {
|
|
|
9264
9264
|
const n = this.planes, s = e.elements, r = s[0], a = s[1], o = s[2], l = s[3], c = s[4], h = s[5], u = s[6], f = s[7], m = s[8], _ = s[9], v = s[10], p = s[11], d = s[12], b = s[13], T = s[14], S = s[15];
|
|
9265
9265
|
if (n[0].setComponents(l - r, f - c, p - m, S - d).normalize(), n[1].setComponents(l + r, f + c, p + m, S + d).normalize(), n[2].setComponents(l + a, f + h, p + _, S + b).normalize(), n[3].setComponents(l - a, f - h, p - _, S - b).normalize(), n[4].setComponents(l - o, f - u, p - v, S - T).normalize(), t === _n)
|
|
9266
9266
|
n[5].setComponents(l + o, f + u, p + v, S + T).normalize();
|
|
9267
|
-
else if (t ===
|
|
9267
|
+
else if (t === Os)
|
|
9268
9268
|
n[5].setComponents(o, u, v, T).normalize();
|
|
9269
9269
|
else
|
|
9270
9270
|
throw new Error("THREE.Frustum.setFromProjectionMatrix(): Invalid coordinate system: " + t);
|
|
@@ -9346,7 +9346,7 @@ class wa {
|
|
|
9346
9346
|
return new this.constructor().copy(this);
|
|
9347
9347
|
}
|
|
9348
9348
|
}
|
|
9349
|
-
class
|
|
9349
|
+
class Ls extends xn {
|
|
9350
9350
|
/**
|
|
9351
9351
|
* Constructs a new line basic material.
|
|
9352
9352
|
*
|
|
@@ -9363,7 +9363,7 @@ class Ds extends xn {
|
|
|
9363
9363
|
return super.copy(e), this.color.copy(e.color), this.map = e.map, this.linewidth = e.linewidth, this.linecap = e.linecap, this.linejoin = e.linejoin, this.fog = e.fog, this;
|
|
9364
9364
|
}
|
|
9365
9365
|
}
|
|
9366
|
-
const
|
|
9366
|
+
const Bs = /* @__PURE__ */ new N(), zs = /* @__PURE__ */ new N(), ro = /* @__PURE__ */ new st(), Fi = /* @__PURE__ */ new Vs(), ms = /* @__PURE__ */ new ji(), gr = /* @__PURE__ */ new N(), ao = /* @__PURE__ */ new N();
|
|
9367
9367
|
class Lh extends gt {
|
|
9368
9368
|
/**
|
|
9369
9369
|
* Constructs a new line.
|
|
@@ -9371,7 +9371,7 @@ class Lh extends gt {
|
|
|
9371
9371
|
* @param {BufferGeometry} [geometry] - The line geometry.
|
|
9372
9372
|
* @param {Material|Array<Material>} [material] - The line material.
|
|
9373
9373
|
*/
|
|
9374
|
-
constructor(e = new Zt(), t = new
|
|
9374
|
+
constructor(e = new Zt(), t = new Ls()) {
|
|
9375
9375
|
super(), this.isLine = !0, this.type = "Line", this.geometry = e, this.material = t, this.morphTargetDictionary = void 0, this.morphTargetInfluences = void 0, this.updateMorphTargets();
|
|
9376
9376
|
}
|
|
9377
9377
|
copy(e, t) {
|
|
@@ -9389,7 +9389,7 @@ class Lh extends gt {
|
|
|
9389
9389
|
if (e.index === null) {
|
|
9390
9390
|
const t = e.attributes.position, n = [0];
|
|
9391
9391
|
for (let s = 1, r = t.count; s < r; s++)
|
|
9392
|
-
|
|
9392
|
+
Bs.fromBufferAttribute(t, s - 1), zs.fromBufferAttribute(t, s), n[s] = n[s - 1], n[s] += Bs.distanceTo(zs);
|
|
9393
9393
|
e.setAttribute("lineDistance", new bt(n, 1));
|
|
9394
9394
|
} else
|
|
9395
9395
|
console.warn("THREE.Line.computeLineDistances(): Computation only possible with non-indexed BufferGeometry.");
|
|
@@ -9448,7 +9448,7 @@ class Lh extends gt {
|
|
|
9448
9448
|
}
|
|
9449
9449
|
function _s(i, e, t, n, s, r, a) {
|
|
9450
9450
|
const o = i.geometry.attributes.position;
|
|
9451
|
-
if (
|
|
9451
|
+
if (Bs.fromBufferAttribute(o, s), zs.fromBufferAttribute(o, r), t.distanceSqToSegment(Bs, zs, gr, ao) > n) return;
|
|
9452
9452
|
gr.applyMatrix4(i.matrixWorld);
|
|
9453
9453
|
const c = e.ray.origin.distanceTo(gr);
|
|
9454
9454
|
if (!(c < e.near || c > e.far))
|
|
@@ -9487,7 +9487,7 @@ class co extends Lh {
|
|
|
9487
9487
|
return this;
|
|
9488
9488
|
}
|
|
9489
9489
|
}
|
|
9490
|
-
class
|
|
9490
|
+
class zi extends xn {
|
|
9491
9491
|
/**
|
|
9492
9492
|
* Constructs a new points material.
|
|
9493
9493
|
*
|
|
@@ -9504,7 +9504,7 @@ class Bi extends xn {
|
|
|
9504
9504
|
return super.copy(e), this.color.copy(e.color), this.map = e.map, this.alphaMap = e.alphaMap, this.size = e.size, this.sizeAttenuation = e.sizeAttenuation, this.fog = e.fog, this;
|
|
9505
9505
|
}
|
|
9506
9506
|
}
|
|
9507
|
-
const ho = /* @__PURE__ */ new st(), fa = /* @__PURE__ */ new
|
|
9507
|
+
const ho = /* @__PURE__ */ new st(), fa = /* @__PURE__ */ new Vs(), gs = /* @__PURE__ */ new ji(), vs = /* @__PURE__ */ new N();
|
|
9508
9508
|
class vr extends gt {
|
|
9509
9509
|
/**
|
|
9510
9510
|
* Constructs a new point cloud.
|
|
@@ -9512,7 +9512,7 @@ class vr extends gt {
|
|
|
9512
9512
|
* @param {BufferGeometry} [geometry] - The points geometry.
|
|
9513
9513
|
* @param {Material|Array<Material>} [material] - The points material.
|
|
9514
9514
|
*/
|
|
9515
|
-
constructor(e = new Zt(), t = new
|
|
9515
|
+
constructor(e = new Zt(), t = new zi()) {
|
|
9516
9516
|
super(), this.isPoints = !0, this.type = "Points", this.geometry = e, this.material = t, this.morphTargetDictionary = void 0, this.morphTargetInfluences = void 0, this.updateMorphTargets();
|
|
9517
9517
|
}
|
|
9518
9518
|
copy(e, t) {
|
|
@@ -9578,7 +9578,7 @@ function uo(i, e, t, n, s, r, a) {
|
|
|
9578
9578
|
});
|
|
9579
9579
|
}
|
|
9580
9580
|
}
|
|
9581
|
-
class
|
|
9581
|
+
class Tl extends At {
|
|
9582
9582
|
/**
|
|
9583
9583
|
* Constructs a new depth texture.
|
|
9584
9584
|
*
|
|
@@ -9594,8 +9594,8 @@ class yl extends At {
|
|
|
9594
9594
|
* @param {number} [format=DepthFormat] - The texture format.
|
|
9595
9595
|
* @param {number} [depth=1] - The depth of the texture.
|
|
9596
9596
|
*/
|
|
9597
|
-
constructor(e, t, n = Xn, s, r, a, o = Kt, l = Kt, c, h =
|
|
9598
|
-
if (h !==
|
|
9597
|
+
constructor(e, t, n = Xn, s, r, a, o = Kt, l = Kt, c, h = Gi, u = 1) {
|
|
9598
|
+
if (h !== Gi && h !== Wi)
|
|
9599
9599
|
throw new Error("DepthTexture format must be either THREE.DepthFormat or THREE.DepthStencilFormat");
|
|
9600
9600
|
const f = { width: e, height: t, depth: u };
|
|
9601
9601
|
super(f, s, r, a, o, l, h, n, c), this.isDepthTexture = !0, this.flipY = !1, this.generateMipmaps = !1, this.compareFunction = null;
|
|
@@ -9608,7 +9608,7 @@ class yl extends At {
|
|
|
9608
9608
|
return this.compareFunction !== null && (t.compareFunction = this.compareFunction), t;
|
|
9609
9609
|
}
|
|
9610
9610
|
}
|
|
9611
|
-
class
|
|
9611
|
+
class Gs extends Zt {
|
|
9612
9612
|
/**
|
|
9613
9613
|
* Constructs a new plane geometry.
|
|
9614
9614
|
*
|
|
@@ -9634,8 +9634,8 @@ class Vs extends Zt {
|
|
|
9634
9634
|
}
|
|
9635
9635
|
for (let d = 0; d < l; d++)
|
|
9636
9636
|
for (let b = 0; b < o; b++) {
|
|
9637
|
-
const T = b + c * d, S = b + c * (d + 1),
|
|
9638
|
-
m.push(T, S, A), m.push(S,
|
|
9637
|
+
const T = b + c * d, S = b + c * (d + 1), D = b + 1 + c * (d + 1), A = b + 1 + c * d;
|
|
9638
|
+
m.push(T, S, A), m.push(S, D, A);
|
|
9639
9639
|
}
|
|
9640
9640
|
this.setIndex(m), this.setAttribute("position", new bt(_, 3)), this.setAttribute("normal", new bt(v, 3)), this.setAttribute("uv", new bt(p, 2));
|
|
9641
9641
|
}
|
|
@@ -9650,10 +9650,10 @@ class Vs extends Zt {
|
|
|
9650
9650
|
* @return {PlaneGeometry} A new instance.
|
|
9651
9651
|
*/
|
|
9652
9652
|
static fromJSON(e) {
|
|
9653
|
-
return new
|
|
9653
|
+
return new Gs(e.width, e.height, e.widthSegments, e.heightSegments);
|
|
9654
9654
|
}
|
|
9655
9655
|
}
|
|
9656
|
-
class
|
|
9656
|
+
class bl extends xn {
|
|
9657
9657
|
/**
|
|
9658
9658
|
* Constructs a new mesh phong material.
|
|
9659
9659
|
*
|
|
@@ -9664,7 +9664,7 @@ class Tl extends xn {
|
|
|
9664
9664
|
* by {@link Color#set}.
|
|
9665
9665
|
*/
|
|
9666
9666
|
constructor(e) {
|
|
9667
|
-
super(), this.isMeshPhongMaterial = !0, this.type = "MeshPhongMaterial", this.color = new Ge(16777215), this.specular = new Ge(1118481), this.shininess = 30, this.map = null, this.lightMap = null, this.lightMapIntensity = 1, this.aoMap = null, this.aoMapIntensity = 1, this.emissive = new Ge(0), this.emissiveIntensity = 1, this.emissiveMap = null, this.bumpMap = null, this.bumpScale = 1, this.normalMap = null, this.normalMapType =
|
|
9667
|
+
super(), this.isMeshPhongMaterial = !0, this.type = "MeshPhongMaterial", this.color = new Ge(16777215), this.specular = new Ge(1118481), this.shininess = 30, this.map = null, this.lightMap = null, this.lightMapIntensity = 1, this.aoMap = null, this.aoMapIntensity = 1, this.emissive = new Ge(0), this.emissiveIntensity = 1, this.emissiveMap = null, this.bumpMap = null, this.bumpScale = 1, this.normalMap = null, this.normalMapType = dl, this.normalScale = new Oe(1, 1), this.displacementMap = null, this.displacementScale = 1, this.displacementBias = 0, this.specularMap = null, this.alphaMap = null, this.envMap = null, this.envMapRotation = new rn(), this.combine = xa, this.reflectivity = 1, this.refractionRatio = 0.98, this.wireframe = !1, this.wireframeLinewidth = 1, this.wireframeLinecap = "round", this.wireframeLinejoin = "round", this.flatShading = !1, this.fog = !0, this.setValues(e);
|
|
9668
9668
|
}
|
|
9669
9669
|
copy(e) {
|
|
9670
9670
|
return super.copy(e), this.color.copy(e.color), this.specular.copy(e.specular), this.shininess = e.shininess, this.map = e.map, this.lightMap = e.lightMap, this.lightMapIntensity = e.lightMapIntensity, this.aoMap = e.aoMap, this.aoMapIntensity = e.aoMapIntensity, this.emissive.copy(e.emissive), this.emissiveMap = e.emissiveMap, this.emissiveIntensity = e.emissiveIntensity, this.bumpMap = e.bumpMap, this.bumpScale = e.bumpScale, this.normalMap = e.normalMap, this.normalMapType = e.normalMapType, this.normalScale.copy(e.normalScale), this.displacementMap = e.displacementMap, this.displacementScale = e.displacementScale, this.displacementBias = e.displacementBias, this.specularMap = e.specularMap, this.alphaMap = e.alphaMap, this.envMap = e.envMap, this.envMapRotation.copy(e.envMapRotation), this.combine = e.combine, this.reflectivity = e.reflectivity, this.refractionRatio = e.refractionRatio, this.wireframe = e.wireframe, this.wireframeLinewidth = e.wireframeLinewidth, this.wireframeLinecap = e.wireframeLinecap, this.wireframeLinejoin = e.wireframeLinejoin, this.flatShading = e.flatShading, this.fog = e.fog, this;
|
|
@@ -9704,7 +9704,7 @@ class Ih extends xn {
|
|
|
9704
9704
|
return super.copy(e), this.map = e.map, this.alphaMap = e.alphaMap, this.displacementMap = e.displacementMap, this.displacementScale = e.displacementScale, this.displacementBias = e.displacementBias, this;
|
|
9705
9705
|
}
|
|
9706
9706
|
}
|
|
9707
|
-
const
|
|
9707
|
+
const Hs = {
|
|
9708
9708
|
/**
|
|
9709
9709
|
* Whether caching is enabled or not.
|
|
9710
9710
|
*
|
|
@@ -9797,7 +9797,7 @@ class Nh {
|
|
|
9797
9797
|
};
|
|
9798
9798
|
}
|
|
9799
9799
|
}
|
|
9800
|
-
const
|
|
9800
|
+
const Al = /* @__PURE__ */ new Nh();
|
|
9801
9801
|
class bi {
|
|
9802
9802
|
/**
|
|
9803
9803
|
* Constructs a new loader.
|
|
@@ -9805,7 +9805,7 @@ class bi {
|
|
|
9805
9805
|
* @param {LoadingManager} [manager] - The loading manager.
|
|
9806
9806
|
*/
|
|
9807
9807
|
constructor(e) {
|
|
9808
|
-
this.manager = e !== void 0 ? e :
|
|
9808
|
+
this.manager = e !== void 0 ? e : Al, this.crossOrigin = "anonymous", this.withCredentials = !1, this.path = "", this.resourcePath = "", this.requestHeader = {};
|
|
9809
9809
|
}
|
|
9810
9810
|
/**
|
|
9811
9811
|
* This method needs to be implemented by all concrete loaders. It holds the
|
|
@@ -9897,7 +9897,7 @@ class Fh extends Error {
|
|
|
9897
9897
|
super(e), this.response = t;
|
|
9898
9898
|
}
|
|
9899
9899
|
}
|
|
9900
|
-
class
|
|
9900
|
+
class wl extends bi {
|
|
9901
9901
|
/**
|
|
9902
9902
|
* Constructs a new file loader.
|
|
9903
9903
|
*
|
|
@@ -9917,7 +9917,7 @@ class Al extends bi {
|
|
|
9917
9917
|
*/
|
|
9918
9918
|
load(e, t, n, s) {
|
|
9919
9919
|
e === void 0 && (e = ""), this.path !== void 0 && (e = this.path + e), e = this.manager.resolveURL(e);
|
|
9920
|
-
const r =
|
|
9920
|
+
const r = Hs.get(e);
|
|
9921
9921
|
if (r !== void 0)
|
|
9922
9922
|
return this.manager.itemStart(e), setTimeout(() => {
|
|
9923
9923
|
t && t(r), this.manager.itemEnd(e);
|
|
@@ -9955,10 +9955,10 @@ class Al extends bi {
|
|
|
9955
9955
|
d.close();
|
|
9956
9956
|
else {
|
|
9957
9957
|
v += S.byteLength;
|
|
9958
|
-
const
|
|
9958
|
+
const D = new ProgressEvent("progress", { lengthComputable: _, loaded: v, total: m });
|
|
9959
9959
|
for (let A = 0, C = h.length; A < C; A++) {
|
|
9960
9960
|
const F = h[A];
|
|
9961
|
-
F.onProgress && F.onProgress(
|
|
9961
|
+
F.onProgress && F.onProgress(D);
|
|
9962
9962
|
}
|
|
9963
9963
|
d.enqueue(S), b();
|
|
9964
9964
|
}
|
|
@@ -9990,7 +9990,7 @@ class Al extends bi {
|
|
|
9990
9990
|
}
|
|
9991
9991
|
}
|
|
9992
9992
|
}).then((c) => {
|
|
9993
|
-
|
|
9993
|
+
Hs.add(e, c);
|
|
9994
9994
|
const h = un[e];
|
|
9995
9995
|
delete un[e];
|
|
9996
9996
|
for (let u = 0, f = h.length; u < f; u++) {
|
|
@@ -10053,14 +10053,14 @@ class Oh extends bi {
|
|
|
10053
10053
|
*/
|
|
10054
10054
|
load(e, t, n, s) {
|
|
10055
10055
|
this.path !== void 0 && (e = this.path + e), e = this.manager.resolveURL(e);
|
|
10056
|
-
const r = this, a =
|
|
10056
|
+
const r = this, a = Hs.get(e);
|
|
10057
10057
|
if (a !== void 0)
|
|
10058
10058
|
return r.manager.itemStart(e), setTimeout(function() {
|
|
10059
10059
|
t && t(a), r.manager.itemEnd(e);
|
|
10060
10060
|
}, 0), a;
|
|
10061
|
-
const o =
|
|
10061
|
+
const o = Xi("img");
|
|
10062
10062
|
function l() {
|
|
10063
|
-
h(),
|
|
10063
|
+
h(), Hs.add(e, this), t && t(this), r.manager.itemEnd(e);
|
|
10064
10064
|
}
|
|
10065
10065
|
function c(u) {
|
|
10066
10066
|
h(), s && s(u), r.manager.itemError(e), r.manager.itemEnd(e);
|
|
@@ -10099,7 +10099,7 @@ class Bh extends bi {
|
|
|
10099
10099
|
}, n, s), r;
|
|
10100
10100
|
}
|
|
10101
10101
|
}
|
|
10102
|
-
class
|
|
10102
|
+
class Rl extends gt {
|
|
10103
10103
|
/**
|
|
10104
10104
|
* Constructs a new light.
|
|
10105
10105
|
*
|
|
@@ -10230,7 +10230,7 @@ class zh {
|
|
|
10230
10230
|
return this.intensity !== 1 && (e.intensity = this.intensity), this.bias !== 0 && (e.bias = this.bias), this.normalBias !== 0 && (e.normalBias = this.normalBias), this.radius !== 1 && (e.radius = this.radius), (this.mapSize.x !== 512 || this.mapSize.y !== 512) && (e.mapSize = this.mapSize.toArray()), e.camera = this.camera.toJSON(!1).object, delete e.camera.matrix, e;
|
|
10231
10231
|
}
|
|
10232
10232
|
}
|
|
10233
|
-
class
|
|
10233
|
+
class Cl extends El {
|
|
10234
10234
|
/**
|
|
10235
10235
|
* Constructs a new orthographic camera.
|
|
10236
10236
|
*
|
|
@@ -10299,10 +10299,10 @@ class Hh extends zh {
|
|
|
10299
10299
|
* Constructs a new directional light shadow.
|
|
10300
10300
|
*/
|
|
10301
10301
|
constructor() {
|
|
10302
|
-
super(new
|
|
10302
|
+
super(new Cl(-5, 5, 5, -5, 0.5, 500)), this.isDirectionalLightShadow = !0;
|
|
10303
10303
|
}
|
|
10304
10304
|
}
|
|
10305
|
-
class kh extends
|
|
10305
|
+
class kh extends Rl {
|
|
10306
10306
|
/**
|
|
10307
10307
|
* Constructs a new directional light.
|
|
10308
10308
|
*
|
|
@@ -10319,7 +10319,7 @@ class kh extends wl {
|
|
|
10319
10319
|
return super.copy(e), this.target = e.target.clone(), this.shadow = e.shadow.clone(), this;
|
|
10320
10320
|
}
|
|
10321
10321
|
}
|
|
10322
|
-
class Vh extends
|
|
10322
|
+
class Vh extends Rl {
|
|
10323
10323
|
/**
|
|
10324
10324
|
* Constructs a new ambient light.
|
|
10325
10325
|
*
|
|
@@ -10481,28 +10481,28 @@ function _o(i, e, t, n) {
|
|
|
10481
10481
|
const s = qh(n);
|
|
10482
10482
|
switch (t) {
|
|
10483
10483
|
// https://registry.khronos.org/OpenGL-Refpages/es3.0/html/glTexImage2D.xhtml
|
|
10484
|
-
case
|
|
10484
|
+
case ol:
|
|
10485
10485
|
return i * e;
|
|
10486
|
-
case
|
|
10486
|
+
case cl:
|
|
10487
10487
|
return i * e / s.components * s.byteLength;
|
|
10488
10488
|
case ya:
|
|
10489
10489
|
return i * e / s.components * s.byteLength;
|
|
10490
|
-
case
|
|
10490
|
+
case hl:
|
|
10491
10491
|
return i * e * 2 / s.components * s.byteLength;
|
|
10492
10492
|
case Ta:
|
|
10493
10493
|
return i * e * 2 / s.components * s.byteLength;
|
|
10494
|
-
case
|
|
10494
|
+
case ll:
|
|
10495
10495
|
return i * e * 3 / s.components * s.byteLength;
|
|
10496
10496
|
case Yt:
|
|
10497
10497
|
return i * e * 4 / s.components * s.byteLength;
|
|
10498
10498
|
case ba:
|
|
10499
10499
|
return i * e * 4 / s.components * s.byteLength;
|
|
10500
10500
|
// https://registry.khronos.org/webgl/extensions/WEBGL_compressed_texture_s3tc_srgb/
|
|
10501
|
-
case bs:
|
|
10502
10501
|
case As:
|
|
10503
|
-
return Math.floor((i + 3) / 4) * Math.floor((e + 3) / 4) * 8;
|
|
10504
10502
|
case ws:
|
|
10503
|
+
return Math.floor((i + 3) / 4) * Math.floor((e + 3) / 4) * 8;
|
|
10505
10504
|
case Rs:
|
|
10505
|
+
case Cs:
|
|
10506
10506
|
return Math.floor((i + 3) / 4) * Math.floor((e + 3) / 4) * 16;
|
|
10507
10507
|
// https://registry.khronos.org/webgl/extensions/WEBGL_compressed_texture_pvrtc/
|
|
10508
10508
|
case kr:
|
|
@@ -10547,12 +10547,12 @@ function _o(i, e, t, n) {
|
|
|
10547
10547
|
case aa:
|
|
10548
10548
|
return Math.floor((i + 11) / 12) * Math.floor((e + 11) / 12) * 16;
|
|
10549
10549
|
// https://registry.khronos.org/webgl/extensions/EXT_texture_compression_bptc/
|
|
10550
|
-
case
|
|
10550
|
+
case Ps:
|
|
10551
10551
|
case oa:
|
|
10552
10552
|
case la:
|
|
10553
10553
|
return Math.ceil(i / 4) * Math.ceil(e / 4) * 16;
|
|
10554
10554
|
// https://registry.khronos.org/webgl/extensions/EXT_texture_compression_rgtc/
|
|
10555
|
-
case
|
|
10555
|
+
case ul:
|
|
10556
10556
|
case ca:
|
|
10557
10557
|
return Math.ceil(i / 4) * Math.ceil(e / 4) * 8;
|
|
10558
10558
|
case ha:
|
|
@@ -10566,11 +10566,11 @@ function _o(i, e, t, n) {
|
|
|
10566
10566
|
function qh(i) {
|
|
10567
10567
|
switch (i) {
|
|
10568
10568
|
case sn:
|
|
10569
|
-
case il:
|
|
10570
|
-
return { byteLength: 1, components: 1 };
|
|
10571
|
-
case Hi:
|
|
10572
10569
|
case sl:
|
|
10573
|
-
|
|
10570
|
+
return { byteLength: 1, components: 1 };
|
|
10571
|
+
case ki:
|
|
10572
|
+
case rl:
|
|
10573
|
+
case qi:
|
|
10574
10574
|
return { byteLength: 2, components: 1 };
|
|
10575
10575
|
case Sa:
|
|
10576
10576
|
case Ea:
|
|
@@ -10579,7 +10579,7 @@ function qh(i) {
|
|
|
10579
10579
|
case Ma:
|
|
10580
10580
|
case mn:
|
|
10581
10581
|
return { byteLength: 4, components: 1 };
|
|
10582
|
-
case
|
|
10582
|
+
case al:
|
|
10583
10583
|
return { byteLength: 4, components: 3 };
|
|
10584
10584
|
}
|
|
10585
10585
|
throw new Error(`Unknown texture type ${i}.`);
|
|
@@ -10593,7 +10593,7 @@ typeof window < "u" && (window.__THREE__ ? console.warn("WARNING: Multiple insta
|
|
|
10593
10593
|
* Copyright 2010-2025 Three.js Authors
|
|
10594
10594
|
* SPDX-License-Identifier: MIT
|
|
10595
10595
|
*/
|
|
10596
|
-
function
|
|
10596
|
+
function Pl() {
|
|
10597
10597
|
let i = null, e = !1, t = null, n = null;
|
|
10598
10598
|
function s(r, a) {
|
|
10599
10599
|
t(r, a), n = i.requestAnimationFrame(s);
|
|
@@ -14825,15 +14825,15 @@ function Cf(i, e, t, n, s, r, a) {
|
|
|
14825
14825
|
}
|
|
14826
14826
|
function v(T) {
|
|
14827
14827
|
let S = !1;
|
|
14828
|
-
const
|
|
14829
|
-
|
|
14828
|
+
const D = _(T);
|
|
14829
|
+
D === null ? d(o, l) : D && D.isColor && (d(D, 1), S = !0);
|
|
14830
14830
|
const A = i.xr.getEnvironmentBlendMode();
|
|
14831
14831
|
A === "additive" ? n.buffers.color.setClear(0, 0, 0, 1, a) : A === "alpha-blend" && n.buffers.color.setClear(0, 0, 0, 0, a), (i.autoClear || S) && (n.buffers.depth.setTest(!0), n.buffers.depth.setMask(!0), n.buffers.color.setMask(!0), i.clear(i.autoClearColor, i.autoClearDepth, i.autoClearStencil));
|
|
14832
14832
|
}
|
|
14833
14833
|
function p(T, S) {
|
|
14834
|
-
const
|
|
14835
|
-
|
|
14836
|
-
new
|
|
14834
|
+
const D = _(S);
|
|
14835
|
+
D && (D.isCubeTexture || D.mapping === ks) ? (h === void 0 && (h = new jt(
|
|
14836
|
+
new Ki(1, 1, 1),
|
|
14837
14837
|
new Ln({
|
|
14838
14838
|
name: "BackgroundCubeMaterial",
|
|
14839
14839
|
uniforms: yi(Qt.backgroundCube.uniforms),
|
|
@@ -14851,8 +14851,8 @@ function Cf(i, e, t, n, s, r, a) {
|
|
|
14851
14851
|
get: function() {
|
|
14852
14852
|
return this.uniforms.envMap.value;
|
|
14853
14853
|
}
|
|
14854
|
-
}), s.update(h)), Bn.copy(S.backgroundRotation), Bn.x *= -1, Bn.y *= -1, Bn.z *= -1,
|
|
14855
|
-
new
|
|
14854
|
+
}), s.update(h)), Bn.copy(S.backgroundRotation), Bn.x *= -1, Bn.y *= -1, Bn.z *= -1, D.isCubeTexture && D.isRenderTargetTexture === !1 && (Bn.y *= -1, Bn.z *= -1), h.material.uniforms.envMap.value = D, h.material.uniforms.flipEnvMap.value = D.isCubeTexture && D.isRenderTargetTexture === !1 ? -1 : 1, h.material.uniforms.backgroundBlurriness.value = S.backgroundBlurriness, h.material.uniforms.backgroundIntensity.value = S.backgroundIntensity, h.material.uniforms.backgroundRotation.value.setFromMatrix4(Rf.makeRotationFromEuler(Bn)), h.material.toneMapped = je.getTransfer(D.colorSpace) !== et, (u !== D || f !== D.version || m !== i.toneMapping) && (h.material.needsUpdate = !0, u = D, f = D.version, m = i.toneMapping), h.layers.enableAll(), T.unshift(h, h.geometry, h.material, 0, 0, null)) : D && D.isTexture && (c === void 0 && (c = new jt(
|
|
14855
|
+
new Gs(2, 2),
|
|
14856
14856
|
new Ln({
|
|
14857
14857
|
name: "BackgroundMaterial",
|
|
14858
14858
|
uniforms: yi(Qt.background.uniforms),
|
|
@@ -14868,10 +14868,10 @@ function Cf(i, e, t, n, s, r, a) {
|
|
|
14868
14868
|
get: function() {
|
|
14869
14869
|
return this.uniforms.t2D.value;
|
|
14870
14870
|
}
|
|
14871
|
-
}), s.update(c)), c.material.uniforms.t2D.value =
|
|
14871
|
+
}), s.update(c)), c.material.uniforms.t2D.value = D, c.material.uniforms.backgroundIntensity.value = S.backgroundIntensity, c.material.toneMapped = je.getTransfer(D.colorSpace) !== et, D.matrixAutoUpdate === !0 && D.updateMatrix(), c.material.uniforms.uvTransform.value.copy(D.matrix), (u !== D || f !== D.version || m !== i.toneMapping) && (c.material.needsUpdate = !0, u = D, f = D.version, m = i.toneMapping), c.layers.enableAll(), T.unshift(c, c.geometry, c.material, 0, 0, null));
|
|
14872
14872
|
}
|
|
14873
14873
|
function d(T, S) {
|
|
14874
|
-
T.getRGB(xs,
|
|
14874
|
+
T.getRGB(xs, Sl(i)), n.buffers.color.setClear(xs.r, xs.g, xs.b, S, a);
|
|
14875
14875
|
}
|
|
14876
14876
|
function b() {
|
|
14877
14877
|
h !== void 0 && (h.geometry.dispose(), h.material.dispose(), h = void 0), c !== void 0 && (c.geometry.dispose(), c.material.dispose(), c = void 0);
|
|
@@ -15055,7 +15055,7 @@ function Pf(i, e) {
|
|
|
15055
15055
|
}
|
|
15056
15056
|
b();
|
|
15057
15057
|
}
|
|
15058
|
-
function
|
|
15058
|
+
function D() {
|
|
15059
15059
|
F();
|
|
15060
15060
|
for (const M in n) {
|
|
15061
15061
|
const P = n[M];
|
|
@@ -15099,7 +15099,7 @@ function Pf(i, e) {
|
|
|
15099
15099
|
setup: o,
|
|
15100
15100
|
reset: F,
|
|
15101
15101
|
resetDefaultState: E,
|
|
15102
|
-
dispose:
|
|
15102
|
+
dispose: D,
|
|
15103
15103
|
releaseStatesOfGeometry: A,
|
|
15104
15104
|
releaseStatesOfProgram: C,
|
|
15105
15105
|
initAttributes: v,
|
|
@@ -15157,7 +15157,7 @@ function Lf(i, e, t, n) {
|
|
|
15157
15157
|
return !(C !== Yt && n.convert(C) !== i.getParameter(i.IMPLEMENTATION_COLOR_READ_FORMAT));
|
|
15158
15158
|
}
|
|
15159
15159
|
function o(C) {
|
|
15160
|
-
const F = C ===
|
|
15160
|
+
const F = C === qi && (e.has("EXT_color_buffer_half_float") || e.has("EXT_color_buffer_float"));
|
|
15161
15161
|
return !(C !== sn && n.convert(C) !== i.getParameter(i.IMPLEMENTATION_COLOR_READ_TYPE) && // Edge and Chrome Mac < 52 (#9513)
|
|
15162
15162
|
C !== mn && !F);
|
|
15163
15163
|
}
|
|
@@ -15172,7 +15172,7 @@ function Lf(i, e, t, n) {
|
|
|
15172
15172
|
let c = t.precision !== void 0 ? t.precision : "highp";
|
|
15173
15173
|
const h = l(c);
|
|
15174
15174
|
h !== c && (console.warn("THREE.WebGLRenderer:", c, "not supported, using", h, "instead."), c = h);
|
|
15175
|
-
const u = t.logarithmicDepthBuffer === !0, f = t.reverseDepthBuffer === !0 && e.has("EXT_clip_control"), m = i.getParameter(i.MAX_TEXTURE_IMAGE_UNITS), _ = i.getParameter(i.MAX_VERTEX_TEXTURE_IMAGE_UNITS), v = i.getParameter(i.MAX_TEXTURE_SIZE), p = i.getParameter(i.MAX_CUBE_MAP_TEXTURE_SIZE), d = i.getParameter(i.MAX_VERTEX_ATTRIBS), b = i.getParameter(i.MAX_VERTEX_UNIFORM_VECTORS), T = i.getParameter(i.MAX_VARYING_VECTORS), S = i.getParameter(i.MAX_FRAGMENT_UNIFORM_VECTORS),
|
|
15175
|
+
const u = t.logarithmicDepthBuffer === !0, f = t.reverseDepthBuffer === !0 && e.has("EXT_clip_control"), m = i.getParameter(i.MAX_TEXTURE_IMAGE_UNITS), _ = i.getParameter(i.MAX_VERTEX_TEXTURE_IMAGE_UNITS), v = i.getParameter(i.MAX_TEXTURE_SIZE), p = i.getParameter(i.MAX_CUBE_MAP_TEXTURE_SIZE), d = i.getParameter(i.MAX_VERTEX_ATTRIBS), b = i.getParameter(i.MAX_VERTEX_UNIFORM_VECTORS), T = i.getParameter(i.MAX_VARYING_VECTORS), S = i.getParameter(i.MAX_FRAGMENT_UNIFORM_VECTORS), D = _ > 0, A = i.getParameter(i.MAX_SAMPLES);
|
|
15176
15176
|
return {
|
|
15177
15177
|
isWebGL2: !0,
|
|
15178
15178
|
// keeping this for backwards compatibility
|
|
@@ -15191,7 +15191,7 @@ function Lf(i, e, t, n) {
|
|
|
15191
15191
|
maxVertexUniforms: b,
|
|
15192
15192
|
maxVaryings: T,
|
|
15193
15193
|
maxFragmentUniforms: S,
|
|
15194
|
-
vertexTextures:
|
|
15194
|
+
vertexTextures: D,
|
|
15195
15195
|
maxSamples: A
|
|
15196
15196
|
};
|
|
15197
15197
|
}
|
|
@@ -15218,8 +15218,8 @@ function Uf(i) {
|
|
|
15218
15218
|
const b = r ? 0 : n, T = b * 4;
|
|
15219
15219
|
let S = d.clippingState || null;
|
|
15220
15220
|
l.value = S, S = h(_, f, T, m);
|
|
15221
|
-
for (let
|
|
15222
|
-
S[
|
|
15221
|
+
for (let D = 0; D !== T; ++D)
|
|
15222
|
+
S[D] = t[D];
|
|
15223
15223
|
d.clippingState = S, this.numIntersection = v ? this.numPlanes : 0, this.numPlanes += b;
|
|
15224
15224
|
}
|
|
15225
15225
|
};
|
|
@@ -15278,7 +15278,7 @@ function If(i) {
|
|
|
15278
15278
|
dispose: r
|
|
15279
15279
|
};
|
|
15280
15280
|
}
|
|
15281
|
-
const di = 4, go = [0.125, 0.215, 0.35, 0.446, 0.526, 0.582], Vn = 20, Mr = /* @__PURE__ */ new
|
|
15281
|
+
const di = 4, go = [0.125, 0.215, 0.35, 0.446, 0.526, 0.582], Vn = 20, Mr = /* @__PURE__ */ new Cl(), vo = /* @__PURE__ */ new Ge();
|
|
15282
15282
|
let Sr = null, Er = 0, yr = 0, Tr = !1;
|
|
15283
15283
|
const Hn = (1 + Math.sqrt(5)) / 2, hi = 1 / Hn, xo = [
|
|
15284
15284
|
/* @__PURE__ */ new N(-Hn, hi, 0),
|
|
@@ -15393,7 +15393,7 @@ class Mo {
|
|
|
15393
15393
|
magFilter: tn,
|
|
15394
15394
|
minFilter: tn,
|
|
15395
15395
|
generateMipmaps: !1,
|
|
15396
|
-
type:
|
|
15396
|
+
type: qi,
|
|
15397
15397
|
format: Yt,
|
|
15398
15398
|
colorSpace: Ei,
|
|
15399
15399
|
depthBuffer: !1
|
|
@@ -15412,12 +15412,12 @@ class Mo {
|
|
|
15412
15412
|
_sceneToCubeUV(e, t, n, s, r) {
|
|
15413
15413
|
const l = new zt(90, 1, t, n), c = [1, -1, 1, 1, 1, 1], h = [1, 1, 1, -1, -1, -1], u = this._renderer, f = u.autoClear, m = u.toneMapping;
|
|
15414
15414
|
u.getClearColor(vo), u.toneMapping = Dn, u.autoClear = !1;
|
|
15415
|
-
const _ = new
|
|
15415
|
+
const _ = new vl({
|
|
15416
15416
|
name: "PMREM.Background",
|
|
15417
15417
|
side: Pt,
|
|
15418
15418
|
depthWrite: !1,
|
|
15419
15419
|
depthTest: !1
|
|
15420
|
-
}), v = new jt(new
|
|
15420
|
+
}), v = new jt(new Ki(), _);
|
|
15421
15421
|
let p = !1;
|
|
15422
15422
|
const d = e.background;
|
|
15423
15423
|
d ? d.isColor && (_.color.copy(d), e.background = null, p = !0) : (_.color.copy(vo), p = !0);
|
|
@@ -15499,8 +15499,8 @@ class Mo {
|
|
|
15499
15499
|
f.envMap.value = e.texture, f.samples.value = p, f.weights.value = d, f.latitudinal.value = a === "latitudinal", o && (f.poleAxis.value = o);
|
|
15500
15500
|
const { _lodMax: T } = this;
|
|
15501
15501
|
f.dTheta.value = _, f.mipInt.value = T - n;
|
|
15502
|
-
const S = this._sizeLods[s],
|
|
15503
|
-
Ms(t,
|
|
15502
|
+
const S = this._sizeLods[s], D = 3 * S * (s > T - di ? s - T + di : 0), A = 4 * (this._cubeSize - S);
|
|
15503
|
+
Ms(t, D, A, 3 * S, 2 * S), l.setRenderTarget(t), l.render(u, Mr);
|
|
15504
15504
|
}
|
|
15505
15505
|
}
|
|
15506
15506
|
function Ff(i) {
|
|
@@ -15538,14 +15538,14 @@ function Ff(i) {
|
|
|
15538
15538
|
const M = [A, A, A, A, A, A];
|
|
15539
15539
|
S.set(M, d * _ * A);
|
|
15540
15540
|
}
|
|
15541
|
-
const
|
|
15542
|
-
|
|
15541
|
+
const D = new Zt();
|
|
15542
|
+
D.setAttribute("position", new nn(b, v)), D.setAttribute("uv", new nn(T, p)), D.setAttribute("faceIndex", new nn(S, d)), e.push(D), s > di && s--;
|
|
15543
15543
|
}
|
|
15544
15544
|
return { lodPlanes: e, sizeLods: t, sigmas: n };
|
|
15545
15545
|
}
|
|
15546
15546
|
function So(i, e, t) {
|
|
15547
15547
|
const n = new Yn(i, e, t);
|
|
15548
|
-
return n.texture.mapping =
|
|
15548
|
+
return n.texture.mapping = ks, n.texture.name = "PMREM.cubeUv", n.scissorTest = !0, n;
|
|
15549
15549
|
}
|
|
15550
15550
|
function Ms(i, e, t, n, s) {
|
|
15551
15551
|
i.viewport.set(e, t, n, s), i.scissor.set(e, t, n, s);
|
|
@@ -15872,19 +15872,19 @@ function Hf(i, e, t, n) {
|
|
|
15872
15872
|
const b = m.array;
|
|
15873
15873
|
v = m.version;
|
|
15874
15874
|
for (let T = 0, S = b.length; T < S; T += 3) {
|
|
15875
|
-
const
|
|
15876
|
-
f.push(
|
|
15875
|
+
const D = b[T + 0], A = b[T + 1], C = b[T + 2];
|
|
15876
|
+
f.push(D, A, A, C, C, D);
|
|
15877
15877
|
}
|
|
15878
15878
|
} else if (_ !== void 0) {
|
|
15879
15879
|
const b = _.array;
|
|
15880
15880
|
v = _.version;
|
|
15881
15881
|
for (let T = 0, S = b.length / 3 - 1; T < S; T += 3) {
|
|
15882
|
-
const
|
|
15883
|
-
f.push(
|
|
15882
|
+
const D = T + 0, A = T + 1, C = T + 2;
|
|
15883
|
+
f.push(D, A, A, C, C, D);
|
|
15884
15884
|
}
|
|
15885
15885
|
} else
|
|
15886
15886
|
return;
|
|
15887
|
-
const p = new (
|
|
15887
|
+
const p = new (pl(f) ? Ml : xl)(f, 1);
|
|
15888
15888
|
p.version = v;
|
|
15889
15889
|
const d = r.get(u);
|
|
15890
15890
|
d && e.remove(d), r.set(u, p);
|
|
@@ -16001,13 +16001,13 @@ function Gf(i, e, t) {
|
|
|
16001
16001
|
const m = o.morphAttributes.position !== void 0, _ = o.morphAttributes.normal !== void 0, v = o.morphAttributes.color !== void 0, p = o.morphAttributes.position || [], d = o.morphAttributes.normal || [], b = o.morphAttributes.color || [];
|
|
16002
16002
|
let T = 0;
|
|
16003
16003
|
m === !0 && (T = 1), _ === !0 && (T = 2), v === !0 && (T = 3);
|
|
16004
|
-
let S = o.attributes.position.count * T,
|
|
16005
|
-
S > e.maxTextureSize && (
|
|
16006
|
-
const A = new Float32Array(S *
|
|
16004
|
+
let S = o.attributes.position.count * T, D = 1;
|
|
16005
|
+
S > e.maxTextureSize && (D = Math.ceil(S / e.maxTextureSize), S = e.maxTextureSize);
|
|
16006
|
+
const A = new Float32Array(S * D * 4 * u), C = new ml(A, S, D, u);
|
|
16007
16007
|
C.type = mn, C.needsUpdate = !0;
|
|
16008
16008
|
const F = T * 4;
|
|
16009
16009
|
for (let M = 0; M < u; M++) {
|
|
16010
|
-
const P = p[M], q = d[M], k = b[M], j = S *
|
|
16010
|
+
const P = p[M], q = d[M], k = b[M], j = S * D * 4 * M;
|
|
16011
16011
|
for (let te = 0; te < P.count; te++) {
|
|
16012
16012
|
const K = te * F;
|
|
16013
16013
|
m === !0 && (s.fromBufferAttribute(P, te), A[j + K + 0] = s.x, A[j + K + 1] = s.y, A[j + K + 2] = s.z, A[j + K + 3] = 0), _ === !0 && (s.fromBufferAttribute(q, te), A[j + K + 4] = s.x, A[j + K + 5] = s.y, A[j + K + 6] = s.z, A[j + K + 7] = 0), v === !0 && (s.fromBufferAttribute(k, te), A[j + K + 8] = s.x, A[j + K + 9] = s.y, A[j + K + 10] = s.z, A[j + K + 11] = k.itemSize === 4 ? s.w : 1);
|
|
@@ -16016,7 +16016,7 @@ function Gf(i, e, t) {
|
|
|
16016
16016
|
f = {
|
|
16017
16017
|
count: u,
|
|
16018
16018
|
texture: C,
|
|
16019
|
-
size: new Oe(S,
|
|
16019
|
+
size: new Oe(S, D)
|
|
16020
16020
|
}, n.set(o, f), o.addEventListener("dispose", E);
|
|
16021
16021
|
}
|
|
16022
16022
|
if (a.isInstancedMesh === !0 && a.morphTexture !== null)
|
|
@@ -16056,7 +16056,7 @@ function Wf(i, e, t, n) {
|
|
|
16056
16056
|
dispose: a
|
|
16057
16057
|
};
|
|
16058
16058
|
}
|
|
16059
|
-
const
|
|
16059
|
+
const Dl = /* @__PURE__ */ new At(), To = /* @__PURE__ */ new Tl(1, 1), Ll = /* @__PURE__ */ new ml(), Ul = /* @__PURE__ */ new hh(), Il = /* @__PURE__ */ new yl(), bo = [], Ao = [], wo = new Float32Array(16), Ro = new Float32Array(9), Co = new Float32Array(4);
|
|
16060
16060
|
function Ai(i, e, t) {
|
|
16061
16061
|
const n = i[0];
|
|
16062
16062
|
if (n <= 0 || n > 0) return i;
|
|
@@ -16079,7 +16079,7 @@ function mt(i, e) {
|
|
|
16079
16079
|
for (let t = 0, n = e.length; t < n; t++)
|
|
16080
16080
|
i[t] = e[t];
|
|
16081
16081
|
}
|
|
16082
|
-
function
|
|
16082
|
+
function Ws(i, e) {
|
|
16083
16083
|
let t = Ao[e];
|
|
16084
16084
|
t === void 0 && (t = new Int32Array(e), Ao[e] = t);
|
|
16085
16085
|
for (let n = 0; n !== e; ++n)
|
|
@@ -16215,19 +16215,19 @@ function ap(i, e, t) {
|
|
|
16215
16215
|
const n = this.cache, s = t.allocateTextureUnit();
|
|
16216
16216
|
n[0] !== s && (i.uniform1i(this.addr, s), n[0] = s);
|
|
16217
16217
|
let r;
|
|
16218
|
-
this.type === i.SAMPLER_2D_SHADOW ? (To.compareFunction =
|
|
16218
|
+
this.type === i.SAMPLER_2D_SHADOW ? (To.compareFunction = fl, r = To) : r = Dl, t.setTexture2D(e || r, s);
|
|
16219
16219
|
}
|
|
16220
16220
|
function op(i, e, t) {
|
|
16221
16221
|
const n = this.cache, s = t.allocateTextureUnit();
|
|
16222
|
-
n[0] !== s && (i.uniform1i(this.addr, s), n[0] = s), t.setTexture3D(e ||
|
|
16222
|
+
n[0] !== s && (i.uniform1i(this.addr, s), n[0] = s), t.setTexture3D(e || Ul, s);
|
|
16223
16223
|
}
|
|
16224
16224
|
function lp(i, e, t) {
|
|
16225
16225
|
const n = this.cache, s = t.allocateTextureUnit();
|
|
16226
|
-
n[0] !== s && (i.uniform1i(this.addr, s), n[0] = s), t.setTextureCube(e ||
|
|
16226
|
+
n[0] !== s && (i.uniform1i(this.addr, s), n[0] = s), t.setTextureCube(e || Il, s);
|
|
16227
16227
|
}
|
|
16228
16228
|
function cp(i, e, t) {
|
|
16229
16229
|
const n = this.cache, s = t.allocateTextureUnit();
|
|
16230
|
-
n[0] !== s && (i.uniform1i(this.addr, s), n[0] = s), t.setTexture2DArray(e ||
|
|
16230
|
+
n[0] !== s && (i.uniform1i(this.addr, s), n[0] = s), t.setTexture2DArray(e || Ll, s);
|
|
16231
16231
|
}
|
|
16232
16232
|
function hp(i) {
|
|
16233
16233
|
switch (i) {
|
|
@@ -16366,28 +16366,28 @@ function bp(i, e) {
|
|
|
16366
16366
|
i.uniform4uiv(this.addr, e);
|
|
16367
16367
|
}
|
|
16368
16368
|
function Ap(i, e, t) {
|
|
16369
|
-
const n = this.cache, s = e.length, r =
|
|
16369
|
+
const n = this.cache, s = e.length, r = Ws(t, s);
|
|
16370
16370
|
pt(n, r) || (i.uniform1iv(this.addr, r), mt(n, r));
|
|
16371
16371
|
for (let a = 0; a !== s; ++a)
|
|
16372
|
-
t.setTexture2D(e[a] ||
|
|
16372
|
+
t.setTexture2D(e[a] || Dl, r[a]);
|
|
16373
16373
|
}
|
|
16374
16374
|
function wp(i, e, t) {
|
|
16375
|
-
const n = this.cache, s = e.length, r =
|
|
16375
|
+
const n = this.cache, s = e.length, r = Ws(t, s);
|
|
16376
16376
|
pt(n, r) || (i.uniform1iv(this.addr, r), mt(n, r));
|
|
16377
16377
|
for (let a = 0; a !== s; ++a)
|
|
16378
|
-
t.setTexture3D(e[a] ||
|
|
16378
|
+
t.setTexture3D(e[a] || Ul, r[a]);
|
|
16379
16379
|
}
|
|
16380
16380
|
function Rp(i, e, t) {
|
|
16381
|
-
const n = this.cache, s = e.length, r =
|
|
16381
|
+
const n = this.cache, s = e.length, r = Ws(t, s);
|
|
16382
16382
|
pt(n, r) || (i.uniform1iv(this.addr, r), mt(n, r));
|
|
16383
16383
|
for (let a = 0; a !== s; ++a)
|
|
16384
|
-
t.setTextureCube(e[a] ||
|
|
16384
|
+
t.setTextureCube(e[a] || Il, r[a]);
|
|
16385
16385
|
}
|
|
16386
16386
|
function Cp(i, e, t) {
|
|
16387
|
-
const n = this.cache, s = e.length, r =
|
|
16387
|
+
const n = this.cache, s = e.length, r = Ws(t, s);
|
|
16388
16388
|
pt(n, r) || (i.uniform1iv(this.addr, r), mt(n, r));
|
|
16389
16389
|
for (let a = 0; a !== s; ++a)
|
|
16390
|
-
t.setTexture2DArray(e[a] ||
|
|
16390
|
+
t.setTexture2DArray(e[a] || Ll, r[a]);
|
|
16391
16391
|
}
|
|
16392
16392
|
function Pp(i) {
|
|
16393
16393
|
switch (i) {
|
|
@@ -16515,7 +16515,7 @@ function Ip(i, e, t) {
|
|
|
16515
16515
|
}
|
|
16516
16516
|
}
|
|
16517
16517
|
}
|
|
16518
|
-
class
|
|
16518
|
+
class Us {
|
|
16519
16519
|
constructor(e, t) {
|
|
16520
16520
|
this.seq = [], this.map = {};
|
|
16521
16521
|
const n = e.getProgramParameter(t, e.ACTIVE_UNIFORMS);
|
|
@@ -16568,7 +16568,7 @@ function Bp(i) {
|
|
|
16568
16568
|
je._getMatrix(Lo, je.workingColorSpace, i);
|
|
16569
16569
|
const e = `mat3( ${Lo.elements.map((t) => t.toFixed(4))} )`;
|
|
16570
16570
|
switch (je.getTransfer(i)) {
|
|
16571
|
-
case
|
|
16571
|
+
case Fs:
|
|
16572
16572
|
return [e, "LinearTransferOETF"];
|
|
16573
16573
|
case et:
|
|
16574
16574
|
return [e, "sRGBTransferOETF"];
|
|
@@ -16644,7 +16644,7 @@ function Vp(i) {
|
|
|
16644
16644
|
return [
|
|
16645
16645
|
i.extensionClipCullDistance ? "#extension GL_ANGLE_clip_cull_distance : require" : "",
|
|
16646
16646
|
i.extensionMultiDraw ? "#extension GL_ANGLE_multi_draw : require" : ""
|
|
16647
|
-
].filter(
|
|
16647
|
+
].filter(Hi).join(`
|
|
16648
16648
|
`);
|
|
16649
16649
|
}
|
|
16650
16650
|
function Gp(i) {
|
|
@@ -16669,7 +16669,7 @@ function Wp(i, e) {
|
|
|
16669
16669
|
}
|
|
16670
16670
|
return t;
|
|
16671
16671
|
}
|
|
16672
|
-
function
|
|
16672
|
+
function Hi(i) {
|
|
16673
16673
|
return i !== "";
|
|
16674
16674
|
}
|
|
16675
16675
|
function Io(i, e) {
|
|
@@ -16731,7 +16731,7 @@ function Oo(i) {
|
|
|
16731
16731
|
}
|
|
16732
16732
|
function Zp(i) {
|
|
16733
16733
|
let e = "SHADOWMAP_TYPE_BASIC";
|
|
16734
|
-
return i.shadowMapType ===
|
|
16734
|
+
return i.shadowMapType === nl ? e = "SHADOWMAP_TYPE_PCF" : i.shadowMapType === pc ? e = "SHADOWMAP_TYPE_PCF_SOFT" : i.shadowMapType === dn && (e = "SHADOWMAP_TYPE_VSM"), e;
|
|
16735
16735
|
}
|
|
16736
16736
|
function $p(i) {
|
|
16737
16737
|
let e = "ENVMAP_TYPE_CUBE";
|
|
@@ -16741,7 +16741,7 @@ function $p(i) {
|
|
|
16741
16741
|
case Si:
|
|
16742
16742
|
e = "ENVMAP_TYPE_CUBE";
|
|
16743
16743
|
break;
|
|
16744
|
-
case
|
|
16744
|
+
case ks:
|
|
16745
16745
|
e = "ENVMAP_TYPE_CUBE_UV";
|
|
16746
16746
|
break;
|
|
16747
16747
|
}
|
|
@@ -16789,13 +16789,13 @@ function tm(i, e, t, n) {
|
|
|
16789
16789
|
"#define SHADER_TYPE " + t.shaderType,
|
|
16790
16790
|
"#define SHADER_NAME " + t.shaderName,
|
|
16791
16791
|
_
|
|
16792
|
-
].filter(
|
|
16792
|
+
].filter(Hi).join(`
|
|
16793
16793
|
`), p.length > 0 && (p += `
|
|
16794
16794
|
`), d = [
|
|
16795
16795
|
"#define SHADER_TYPE " + t.shaderType,
|
|
16796
16796
|
"#define SHADER_NAME " + t.shaderName,
|
|
16797
16797
|
_
|
|
16798
|
-
].filter(
|
|
16798
|
+
].filter(Hi).join(`
|
|
16799
16799
|
`), d.length > 0 && (d += `
|
|
16800
16800
|
`)) : (p = [
|
|
16801
16801
|
Oo(t),
|
|
@@ -16929,7 +16929,7 @@ function tm(i, e, t, n) {
|
|
|
16929
16929
|
"#endif",
|
|
16930
16930
|
`
|
|
16931
16931
|
`
|
|
16932
|
-
].filter(
|
|
16932
|
+
].filter(Hi).join(`
|
|
16933
16933
|
`), d = [
|
|
16934
16934
|
Oo(t),
|
|
16935
16935
|
"#define SHADER_TYPE " + t.shaderType,
|
|
@@ -17013,7 +17013,7 @@ function tm(i, e, t, n) {
|
|
|
17013
17013
|
t.useDepthPacking ? "#define DEPTH_PACKING " + t.depthPacking : "",
|
|
17014
17014
|
`
|
|
17015
17015
|
`
|
|
17016
|
-
].filter(
|
|
17016
|
+
].filter(Hi).join(`
|
|
17017
17017
|
`)), a = pa(a), a = Io(a, t), a = No(a, t), o = pa(o), o = Io(o, t), o = No(o, t), a = Fo(a), o = Fo(o), t.isRawShaderMaterial !== !0 && (b = `#version 300 es
|
|
17018
17018
|
`, p = [
|
|
17019
17019
|
m,
|
|
@@ -17039,17 +17039,17 @@ function tm(i, e, t, n) {
|
|
|
17039
17039
|
].join(`
|
|
17040
17040
|
`) + `
|
|
17041
17041
|
` + d);
|
|
17042
|
-
const T = b + p + a, S = b + d + o,
|
|
17043
|
-
s.attachShader(v,
|
|
17042
|
+
const T = b + p + a, S = b + d + o, D = Do(s, s.VERTEX_SHADER, T), A = Do(s, s.FRAGMENT_SHADER, S);
|
|
17043
|
+
s.attachShader(v, D), s.attachShader(v, A), t.index0AttributeName !== void 0 ? s.bindAttribLocation(v, 0, t.index0AttributeName) : t.morphTargets === !0 && s.bindAttribLocation(v, 0, "position"), s.linkProgram(v);
|
|
17044
17044
|
function C(P) {
|
|
17045
17045
|
if (i.debug.checkShaderErrors) {
|
|
17046
|
-
const q = s.getProgramInfoLog(v).trim(), k = s.getShaderInfoLog(
|
|
17046
|
+
const q = s.getProgramInfoLog(v).trim(), k = s.getShaderInfoLog(D).trim(), j = s.getShaderInfoLog(A).trim();
|
|
17047
17047
|
let te = !0, K = !0;
|
|
17048
17048
|
if (s.getProgramParameter(v, s.LINK_STATUS) === !1)
|
|
17049
17049
|
if (te = !1, typeof i.debug.onShaderError == "function")
|
|
17050
|
-
i.debug.onShaderError(s, v,
|
|
17050
|
+
i.debug.onShaderError(s, v, D, A);
|
|
17051
17051
|
else {
|
|
17052
|
-
const re = Uo(s,
|
|
17052
|
+
const re = Uo(s, D, "vertex"), V = Uo(s, A, "fragment");
|
|
17053
17053
|
console.error(
|
|
17054
17054
|
"THREE.WebGLProgram: Shader Error " + s.getError() + " - VALIDATE_STATUS " + s.getProgramParameter(v, s.VALIDATE_STATUS) + `
|
|
17055
17055
|
|
|
@@ -17075,7 +17075,7 @@ Program Info Log: ` + q + `
|
|
|
17075
17075
|
}
|
|
17076
17076
|
});
|
|
17077
17077
|
}
|
|
17078
|
-
s.deleteShader(
|
|
17078
|
+
s.deleteShader(D), s.deleteShader(A), F = new Us(s, v), E = Wp(s, v);
|
|
17079
17079
|
}
|
|
17080
17080
|
let F;
|
|
17081
17081
|
this.getUniforms = function() {
|
|
@@ -17090,7 +17090,7 @@ Program Info Log: ` + q + `
|
|
|
17090
17090
|
return M === !1 && (M = s.getProgramParameter(v, Np)), M;
|
|
17091
17091
|
}, this.destroy = function() {
|
|
17092
17092
|
n.releaseStatesOfProgram(this), s.deleteProgram(v), this.program = void 0;
|
|
17093
|
-
}, this.type = t.shaderType, this.name = t.shaderName, this.id = Fp++, this.cacheKey = e, this.usedTimes = 1, this.program = v, this.vertexShader =
|
|
17093
|
+
}, this.type = t.shaderType, this.name = t.shaderName, this.id = Fp++, this.cacheKey = e, this.usedTimes = 1, this.program = v, this.vertexShader = D, this.fragmentShader = A, this;
|
|
17094
17094
|
}
|
|
17095
17095
|
let nm = 0;
|
|
17096
17096
|
class im {
|
|
@@ -17133,7 +17133,7 @@ class sm {
|
|
|
17133
17133
|
}
|
|
17134
17134
|
}
|
|
17135
17135
|
function rm(i, e, t, n, s, r, a) {
|
|
17136
|
-
const o = new
|
|
17136
|
+
const o = new _l(), l = new im(), c = /* @__PURE__ */ new Set(), h = [], u = s.logarithmicDepthBuffer, f = s.vertexTextures;
|
|
17137
17137
|
let m = s.precision;
|
|
17138
17138
|
const _ = {
|
|
17139
17139
|
MeshDepthMaterial: "depth",
|
|
@@ -17156,7 +17156,7 @@ function rm(i, e, t, n, s, r, a) {
|
|
|
17156
17156
|
return c.add(E), E === 0 ? "uv" : `uv${E}`;
|
|
17157
17157
|
}
|
|
17158
17158
|
function p(E, M, P, q, k) {
|
|
17159
|
-
const j = q.fog, te = k.geometry, K = E.isMeshStandardMaterial ? q.environment : null, re = (E.isMeshStandardMaterial ? t : e).get(E.envMap || K), V = re && re.mapping ===
|
|
17159
|
+
const j = q.fog, te = k.geometry, K = E.isMeshStandardMaterial ? q.environment : null, re = (E.isMeshStandardMaterial ? t : e).get(E.envMap || K), V = re && re.mapping === ks ? re.image.height : null, de = _[E.type];
|
|
17160
17160
|
E.precision !== null && (m = s.getMaxPrecision(E.precision), m !== E.precision && console.warn("THREE.WebGLProgram.getParameters:", E.precision, "not supported, using", m, "instead."));
|
|
17161
17161
|
const ge = te.morphAttributes.position || te.morphAttributes.normal || te.morphAttributes.color, be = ge !== void 0 ? ge.length : 0;
|
|
17162
17162
|
let Ve = 0;
|
|
@@ -17202,7 +17202,7 @@ function rm(i, e, t, n, s, r, a) {
|
|
|
17202
17202
|
displacementMap: f && Se,
|
|
17203
17203
|
emissiveMap: qe,
|
|
17204
17204
|
normalMapObjectSpace: Je && E.normalMapType === Xc,
|
|
17205
|
-
normalMapTangentSpace: Je && E.normalMapType ===
|
|
17205
|
+
normalMapTangentSpace: Je && E.normalMapType === dl,
|
|
17206
17206
|
metalnessMap: we,
|
|
17207
17207
|
roughnessMap: Fe,
|
|
17208
17208
|
anisotropy: ot,
|
|
@@ -17327,7 +17327,7 @@ function rm(i, e, t, n, s, r, a) {
|
|
|
17327
17327
|
P = E.uniforms;
|
|
17328
17328
|
return P;
|
|
17329
17329
|
}
|
|
17330
|
-
function
|
|
17330
|
+
function D(E, M) {
|
|
17331
17331
|
let P;
|
|
17332
17332
|
for (let q = 0, k = h.length; q < k; q++) {
|
|
17333
17333
|
const j = h[q];
|
|
@@ -17354,7 +17354,7 @@ function rm(i, e, t, n, s, r, a) {
|
|
|
17354
17354
|
getParameters: p,
|
|
17355
17355
|
getProgramCacheKey: d,
|
|
17356
17356
|
getUniforms: S,
|
|
17357
|
-
acquireProgram:
|
|
17357
|
+
acquireProgram: D,
|
|
17358
17358
|
releaseProgram: A,
|
|
17359
17359
|
releaseShaderCache: C,
|
|
17360
17360
|
// Exposed for resource monitoring & error feedback via renderer.info:
|
|
@@ -17599,7 +17599,7 @@ function fm(i) {
|
|
|
17599
17599
|
function o(c) {
|
|
17600
17600
|
let h = 0, u = 0, f = 0;
|
|
17601
17601
|
for (let E = 0; E < 9; E++) n.probe[E].set(0, 0, 0);
|
|
17602
|
-
let m = 0, _ = 0, v = 0, p = 0, d = 0, b = 0, T = 0, S = 0,
|
|
17602
|
+
let m = 0, _ = 0, v = 0, p = 0, d = 0, b = 0, T = 0, S = 0, D = 0, A = 0, C = 0;
|
|
17603
17603
|
c.sort(dm);
|
|
17604
17604
|
for (let E = 0, M = c.length; E < M; E++) {
|
|
17605
17605
|
const P = c[E], q = P.color, k = P.intensity, j = P.distance, te = P.shadow && P.shadow.map ? P.shadow.map.texture : null;
|
|
@@ -17620,7 +17620,7 @@ function fm(i) {
|
|
|
17620
17620
|
const K = e.get(P);
|
|
17621
17621
|
K.position.setFromMatrixPosition(P.matrixWorld), K.color.copy(q).multiplyScalar(k), K.distance = j, K.coneCos = Math.cos(P.angle), K.penumbraCos = Math.cos(P.angle * (1 - P.penumbra)), K.decay = P.decay, n.spot[v] = K;
|
|
17622
17622
|
const re = P.shadow;
|
|
17623
|
-
if (P.map && (n.spotLightMap[
|
|
17623
|
+
if (P.map && (n.spotLightMap[D] = P.map, D++, re.updateMatrices(P), P.castShadow && A++), n.spotLightMatrix[v] = re.matrix, P.castShadow) {
|
|
17624
17624
|
const V = t.get(P);
|
|
17625
17625
|
V.shadowIntensity = re.intensity, V.shadowBias = re.bias, V.shadowNormalBias = re.normalBias, V.shadowRadius = re.radius, V.shadowMapSize = re.mapSize, n.spotShadow[v] = V, n.spotShadowMap[v] = te, S++;
|
|
17626
17626
|
}
|
|
@@ -17642,7 +17642,7 @@ function fm(i) {
|
|
|
17642
17642
|
}
|
|
17643
17643
|
p > 0 && (i.has("OES_texture_float_linear") === !0 ? (n.rectAreaLTC1 = ue.LTC_FLOAT_1, n.rectAreaLTC2 = ue.LTC_FLOAT_2) : (n.rectAreaLTC1 = ue.LTC_HALF_1, n.rectAreaLTC2 = ue.LTC_HALF_2)), n.ambient[0] = h, n.ambient[1] = u, n.ambient[2] = f;
|
|
17644
17644
|
const F = n.hash;
|
|
17645
|
-
(F.directionalLength !== m || F.pointLength !== _ || F.spotLength !== v || F.rectAreaLength !== p || F.hemiLength !== d || F.numDirectionalShadows !== b || F.numPointShadows !== T || F.numSpotShadows !== S || F.numSpotMaps !==
|
|
17645
|
+
(F.directionalLength !== m || F.pointLength !== _ || F.spotLength !== v || F.rectAreaLength !== p || F.hemiLength !== d || F.numDirectionalShadows !== b || F.numPointShadows !== T || F.numSpotShadows !== S || F.numSpotMaps !== D || F.numLightProbes !== C) && (n.directional.length = m, n.spot.length = v, n.rectArea.length = p, n.point.length = _, n.hemi.length = d, n.directionalShadow.length = b, n.directionalShadowMap.length = b, n.pointShadow.length = T, n.pointShadowMap.length = T, n.spotShadow.length = S, n.spotShadowMap.length = S, n.directionalShadowMatrix.length = b, n.pointShadowMatrix.length = T, n.spotLightMatrix.length = S + D - A, n.spotLightMap.length = D, n.numSpotLightShadowsWithMaps = A, n.numLightProbes = C, F.directionalLength = m, F.pointLength = _, F.spotLength = v, F.rectAreaLength = p, F.hemiLength = d, F.numDirectionalShadows = b, F.numPointShadows = T, F.numSpotShadows = S, F.numSpotMaps = D, F.numLightProbes = C, n.version = um++);
|
|
17646
17646
|
}
|
|
17647
17647
|
function l(c, h) {
|
|
17648
17648
|
let u = 0, f = 0, m = 0, _ = 0, v = 0;
|
|
@@ -17774,7 +17774,7 @@ function gm(i, e, t) {
|
|
|
17774
17774
|
)
|
|
17775
17775
|
);
|
|
17776
17776
|
const v = new jt(_, f), p = this;
|
|
17777
|
-
this.enabled = !1, this.autoUpdate = !0, this.needsUpdate = !1, this.type =
|
|
17777
|
+
this.enabled = !1, this.autoUpdate = !0, this.needsUpdate = !1, this.type = nl;
|
|
17778
17778
|
let d = this.type;
|
|
17779
17779
|
this.render = function(A, C, F) {
|
|
17780
17780
|
if (p.enabled === !1 || p.autoUpdate === !1 && p.needsUpdate === !1 || A.length === 0) return;
|
|
@@ -17823,7 +17823,7 @@ function gm(i, e, t) {
|
|
|
17823
17823
|
let j = c[q];
|
|
17824
17824
|
j === void 0 && (j = {}, c[q] = j);
|
|
17825
17825
|
let te = j[k];
|
|
17826
|
-
te === void 0 && (te = M.clone(), j[k] = te, C.addEventListener("dispose",
|
|
17826
|
+
te === void 0 && (te = M.clone(), j[k] = te, C.addEventListener("dispose", D)), M = te;
|
|
17827
17827
|
}
|
|
17828
17828
|
if (M.visible = C.visible, M.wireframe = C.wireframe, E === dn ? M.side = C.shadowSide !== null ? C.shadowSide : C.side : M.side = C.shadowSide !== null ? C.shadowSide : u[C.side], M.alphaMap = C.alphaMap, M.alphaTest = C.alphaToCoverage === !0 ? 0.5 : C.alphaTest, M.map = C.map, M.clipShadows = C.clipShadows, M.clippingPlanes = C.clippingPlanes, M.clipIntersection = C.clipIntersection, M.displacementMap = C.displacementMap, M.displacementScale = C.displacementScale, M.displacementBias = C.displacementBias, M.wireframeLinewidth = C.wireframeLinewidth, M.linewidth = C.linewidth, F.isPointLight === !0 && M.isMeshDistanceMaterial === !0) {
|
|
17829
17829
|
const q = i.properties.get(M);
|
|
@@ -17854,8 +17854,8 @@ function gm(i, e, t) {
|
|
|
17854
17854
|
for (let k = 0, j = q.length; k < j; k++)
|
|
17855
17855
|
S(q[k], C, F, E, M);
|
|
17856
17856
|
}
|
|
17857
|
-
function
|
|
17858
|
-
A.target.removeEventListener("dispose",
|
|
17857
|
+
function D(A) {
|
|
17858
|
+
A.target.removeEventListener("dispose", D);
|
|
17859
17859
|
for (const F in c) {
|
|
17860
17860
|
const E = c[F], M = A.target.uuid;
|
|
17861
17861
|
M in E && (E[M].dispose(), delete E[M]);
|
|
@@ -17984,7 +17984,7 @@ function xm(i, e) {
|
|
|
17984
17984
|
};
|
|
17985
17985
|
}
|
|
17986
17986
|
const r = new t(), a = new n(), o = new s(), l = /* @__PURE__ */ new WeakMap(), c = /* @__PURE__ */ new WeakMap();
|
|
17987
|
-
let h = {}, u = {}, f = /* @__PURE__ */ new WeakMap(), m = [], _ = null, v = !1, p = null, d = null, b = null, T = null, S = null,
|
|
17987
|
+
let h = {}, u = {}, f = /* @__PURE__ */ new WeakMap(), m = [], _ = null, v = !1, p = null, d = null, b = null, T = null, S = null, D = null, A = null, C = new Ge(0, 0, 0), F = 0, E = !1, M = null, P = null, q = null, k = null, j = null;
|
|
17988
17988
|
const te = i.getParameter(i.MAX_COMBINED_TEXTURE_IMAGE_UNITS);
|
|
17989
17989
|
let K = !1, re = 0;
|
|
17990
17990
|
const V = i.getParameter(i.VERSION);
|
|
@@ -18092,11 +18092,11 @@ function xm(i, e) {
|
|
|
18092
18092
|
console.error("THREE.WebGLState: Invalid blending: ", R);
|
|
18093
18093
|
break;
|
|
18094
18094
|
}
|
|
18095
|
-
b = null, T = null,
|
|
18095
|
+
b = null, T = null, D = null, A = null, C.set(0, 0, 0), F = 0, p = R, E = He;
|
|
18096
18096
|
}
|
|
18097
18097
|
return;
|
|
18098
18098
|
}
|
|
18099
|
-
z = z || oe, U = U || ee, he = he || _e, (oe !== d || z !== S) && (i.blendEquationSeparate(Ae[oe], Ae[z]), d = oe, S = z), (ee !== b || _e !== T || U !==
|
|
18099
|
+
z = z || oe, U = U || ee, he = he || _e, (oe !== d || z !== S) && (i.blendEquationSeparate(Ae[oe], Ae[z]), d = oe, S = z), (ee !== b || _e !== T || U !== D || he !== A) && (i.blendFuncSeparate(Ue[ee], Ue[_e], Ue[U], Ue[he]), b = ee, T = _e, D = U, A = he), (De.equals(C) === !1 || Be !== F) && (i.blendColor(De.r, De.g, De.b, Be), C.copy(De), F = Be), p = R, E = !1;
|
|
18100
18100
|
}
|
|
18101
18101
|
function rt(R, oe) {
|
|
18102
18102
|
R.side === fn ? ne(i.CULL_FACE) : Y(i.CULL_FACE);
|
|
@@ -18219,7 +18219,7 @@ function xm(i, e) {
|
|
|
18219
18219
|
l.get(oe) !== _e && (i.uniformBlockBinding(oe, _e, R.__bindingPointIndex), l.set(oe, _e));
|
|
18220
18220
|
}
|
|
18221
18221
|
function Te() {
|
|
18222
|
-
i.disable(i.BLEND), i.disable(i.CULL_FACE), i.disable(i.DEPTH_TEST), i.disable(i.POLYGON_OFFSET_FILL), i.disable(i.SCISSOR_TEST), i.disable(i.STENCIL_TEST), i.disable(i.SAMPLE_ALPHA_TO_COVERAGE), i.blendEquation(i.FUNC_ADD), i.blendFunc(i.ONE, i.ZERO), i.blendFuncSeparate(i.ONE, i.ZERO, i.ONE, i.ZERO), i.blendColor(0, 0, 0, 0), i.colorMask(!0, !0, !0, !0), i.clearColor(0, 0, 0, 0), i.depthMask(!0), i.depthFunc(i.LESS), a.setReversed(!1), i.clearDepth(1), i.stencilMask(4294967295), i.stencilFunc(i.ALWAYS, 0, 4294967295), i.stencilOp(i.KEEP, i.KEEP, i.KEEP), i.clearStencil(0), i.cullFace(i.BACK), i.frontFace(i.CCW), i.polygonOffset(0, 0), i.activeTexture(i.TEXTURE0), i.bindFramebuffer(i.FRAMEBUFFER, null), i.bindFramebuffer(i.DRAW_FRAMEBUFFER, null), i.bindFramebuffer(i.READ_FRAMEBUFFER, null), i.useProgram(null), i.lineWidth(1), i.scissor(0, 0, i.canvas.width, i.canvas.height), i.viewport(0, 0, i.canvas.width, i.canvas.height), h = {}, de = null, ge = {}, u = {}, f = /* @__PURE__ */ new WeakMap(), m = [], _ = null, v = !1, p = null, d = null, b = null, T = null, S = null,
|
|
18222
|
+
i.disable(i.BLEND), i.disable(i.CULL_FACE), i.disable(i.DEPTH_TEST), i.disable(i.POLYGON_OFFSET_FILL), i.disable(i.SCISSOR_TEST), i.disable(i.STENCIL_TEST), i.disable(i.SAMPLE_ALPHA_TO_COVERAGE), i.blendEquation(i.FUNC_ADD), i.blendFunc(i.ONE, i.ZERO), i.blendFuncSeparate(i.ONE, i.ZERO, i.ONE, i.ZERO), i.blendColor(0, 0, 0, 0), i.colorMask(!0, !0, !0, !0), i.clearColor(0, 0, 0, 0), i.depthMask(!0), i.depthFunc(i.LESS), a.setReversed(!1), i.clearDepth(1), i.stencilMask(4294967295), i.stencilFunc(i.ALWAYS, 0, 4294967295), i.stencilOp(i.KEEP, i.KEEP, i.KEEP), i.clearStencil(0), i.cullFace(i.BACK), i.frontFace(i.CCW), i.polygonOffset(0, 0), i.activeTexture(i.TEXTURE0), i.bindFramebuffer(i.FRAMEBUFFER, null), i.bindFramebuffer(i.DRAW_FRAMEBUFFER, null), i.bindFramebuffer(i.READ_FRAMEBUFFER, null), i.useProgram(null), i.lineWidth(1), i.scissor(0, 0, i.canvas.width, i.canvas.height), i.viewport(0, 0, i.canvas.width, i.canvas.height), h = {}, de = null, ge = {}, u = {}, f = /* @__PURE__ */ new WeakMap(), m = [], _ = null, v = !1, p = null, d = null, b = null, T = null, S = null, D = null, A = null, C = new Ge(0, 0, 0), F = 0, E = !1, M = null, P = null, q = null, k = null, j = null, Ze.set(0, 0, i.canvas.width, i.canvas.height), $.set(0, 0, i.canvas.width, i.canvas.height), r.reset(), a.reset(), o.reset();
|
|
18223
18223
|
}
|
|
18224
18224
|
return {
|
|
18225
18225
|
buffers: {
|
|
@@ -18272,7 +18272,7 @@ function Mm(i, e, t, n, s, r, a) {
|
|
|
18272
18272
|
return m ? (
|
|
18273
18273
|
// eslint-disable-next-line compat/compat
|
|
18274
18274
|
new OffscreenCanvas(y, g)
|
|
18275
|
-
) :
|
|
18275
|
+
) : Xi("canvas");
|
|
18276
18276
|
}
|
|
18277
18277
|
function v(y, g, O) {
|
|
18278
18278
|
let Z = 1;
|
|
@@ -18303,16 +18303,16 @@ function Mm(i, e, t, n, s, r, a) {
|
|
|
18303
18303
|
}
|
|
18304
18304
|
let W = g;
|
|
18305
18305
|
if (g === i.RED && (O === i.FLOAT && (W = i.R32F), O === i.HALF_FLOAT && (W = i.R16F), O === i.UNSIGNED_BYTE && (W = i.R8)), g === i.RED_INTEGER && (O === i.UNSIGNED_BYTE && (W = i.R8UI), O === i.UNSIGNED_SHORT && (W = i.R16UI), O === i.UNSIGNED_INT && (W = i.R32UI), O === i.BYTE && (W = i.R8I), O === i.SHORT && (W = i.R16I), O === i.INT && (W = i.R32I)), g === i.RG && (O === i.FLOAT && (W = i.RG32F), O === i.HALF_FLOAT && (W = i.RG16F), O === i.UNSIGNED_BYTE && (W = i.RG8)), g === i.RG_INTEGER && (O === i.UNSIGNED_BYTE && (W = i.RG8UI), O === i.UNSIGNED_SHORT && (W = i.RG16UI), O === i.UNSIGNED_INT && (W = i.RG32UI), O === i.BYTE && (W = i.RG8I), O === i.SHORT && (W = i.RG16I), O === i.INT && (W = i.RG32I)), g === i.RGB_INTEGER && (O === i.UNSIGNED_BYTE && (W = i.RGB8UI), O === i.UNSIGNED_SHORT && (W = i.RGB16UI), O === i.UNSIGNED_INT && (W = i.RGB32UI), O === i.BYTE && (W = i.RGB8I), O === i.SHORT && (W = i.RGB16I), O === i.INT && (W = i.RGB32I)), g === i.RGBA_INTEGER && (O === i.UNSIGNED_BYTE && (W = i.RGBA8UI), O === i.UNSIGNED_SHORT && (W = i.RGBA16UI), O === i.UNSIGNED_INT && (W = i.RGBA32UI), O === i.BYTE && (W = i.RGBA8I), O === i.SHORT && (W = i.RGBA16I), O === i.INT && (W = i.RGBA32I)), g === i.RGB && O === i.UNSIGNED_INT_5_9_9_9_REV && (W = i.RGB9_E5), g === i.RGBA) {
|
|
18306
|
-
const Ee = J ?
|
|
18306
|
+
const Ee = J ? Fs : je.getTransfer(Z);
|
|
18307
18307
|
O === i.FLOAT && (W = i.RGBA32F), O === i.HALF_FLOAT && (W = i.RGBA16F), O === i.UNSIGNED_BYTE && (W = Ee === et ? i.SRGB8_ALPHA8 : i.RGBA8), O === i.UNSIGNED_SHORT_4_4_4_4 && (W = i.RGBA4), O === i.UNSIGNED_SHORT_5_5_5_1 && (W = i.RGB5_A1);
|
|
18308
18308
|
}
|
|
18309
18309
|
return (W === i.R16F || W === i.R32F || W === i.RG16F || W === i.RG32F || W === i.RGBA16F || W === i.RGBA32F) && e.get("EXT_color_buffer_float"), W;
|
|
18310
18310
|
}
|
|
18311
18311
|
function S(y, g) {
|
|
18312
18312
|
let O;
|
|
18313
|
-
return y ? g === null || g === Xn || g ===
|
|
18313
|
+
return y ? g === null || g === Xn || g === Vi ? O = i.DEPTH24_STENCIL8 : g === mn ? O = i.DEPTH32F_STENCIL8 : g === ki && (O = i.DEPTH24_STENCIL8, console.warn("DepthTexture: 16 bit depth attachment is not supported with stencil. Using 24-bit attachment.")) : g === null || g === Xn || g === Vi ? O = i.DEPTH_COMPONENT24 : g === mn ? O = i.DEPTH_COMPONENT32F : g === ki && (O = i.DEPTH_COMPONENT16), O;
|
|
18314
18314
|
}
|
|
18315
|
-
function
|
|
18315
|
+
function D(y, g) {
|
|
18316
18316
|
return p(y) === !0 || y.isFramebufferTexture && y.minFilter !== Kt && y.minFilter !== tn ? Math.log2(Math.max(g.width, g.height)) + 1 : y.mipmaps !== void 0 && y.mipmaps.length > 0 ? y.mipmaps.length : y.isCompressedTexture && Array.isArray(y.image) ? g.mipmaps.length : 1;
|
|
18317
18317
|
}
|
|
18318
18318
|
function A(y) {
|
|
@@ -18418,7 +18418,7 @@ function Mm(i, e, t, n, s, r, a) {
|
|
|
18418
18418
|
t.bindTexture(i.TEXTURE_CUBE_MAP, O.__webglTexture, i.TEXTURE0 + g);
|
|
18419
18419
|
}
|
|
18420
18420
|
const de = {
|
|
18421
|
-
[
|
|
18421
|
+
[Ns]: i.REPEAT,
|
|
18422
18422
|
[Gn]: i.CLAMP_TO_EDGE,
|
|
18423
18423
|
[zr]: i.MIRRORED_REPEAT
|
|
18424
18424
|
}, ge = {
|
|
@@ -18432,7 +18432,7 @@ function Mm(i, e, t, n, s, r, a) {
|
|
|
18432
18432
|
[qc]: i.NEVER,
|
|
18433
18433
|
[Jc]: i.ALWAYS,
|
|
18434
18434
|
[Yc]: i.LESS,
|
|
18435
|
-
[
|
|
18435
|
+
[fl]: i.LEQUAL,
|
|
18436
18436
|
[jc]: i.EQUAL,
|
|
18437
18437
|
[$c]: i.GEQUAL,
|
|
18438
18438
|
[Kc]: i.GREATER,
|
|
@@ -18507,9 +18507,9 @@ function Mm(i, e, t, n, s, r, a) {
|
|
|
18507
18507
|
let Ce = T(g.internalFormat, me, Pe, g.colorSpace, g.isVideoTexture);
|
|
18508
18508
|
Ve(Z, g);
|
|
18509
18509
|
let X;
|
|
18510
|
-
const Te = g.mipmaps, R = g.isVideoTexture !== !0, oe = Ee.__version === void 0 || J === !0, ee = W.dataReady, _e =
|
|
18510
|
+
const Te = g.mipmaps, R = g.isVideoTexture !== !0, oe = Ee.__version === void 0 || J === !0, ee = W.dataReady, _e = D(g, Q);
|
|
18511
18511
|
if (g.isDepthTexture)
|
|
18512
|
-
Ce = S(g.format ===
|
|
18512
|
+
Ce = S(g.format === Wi, g.type), oe && (R ? t.texStorage2D(i.TEXTURE_2D, 1, Ce, Q.width, Q.height) : t.texImage2D(i.TEXTURE_2D, 0, Ce, Q.width, Q.height, 0, me, Pe, null));
|
|
18513
18513
|
else if (g.isDataTexture)
|
|
18514
18514
|
if (Te.length > 0) {
|
|
18515
18515
|
R && oe && t.texStorage2D(i.TEXTURE_2D, _e, Ce, Te[0].width, Te[0].height);
|
|
@@ -18610,7 +18610,7 @@ function Mm(i, e, t, n, s, r, a) {
|
|
|
18610
18610
|
for (let U = 0; U < 6; U++)
|
|
18611
18611
|
!ye && !Q ? me[U] = v(g.image[U], !0, s.maxCubemapSize) : me[U] = Q ? g.image[U].image : g.image[U], me[U] = Fe(g, me[U]);
|
|
18612
18612
|
const Pe = me[0], Ce = r.convert(g.format, g.colorSpace), X = r.convert(g.type), Te = T(g.internalFormat, Ce, X, g.colorSpace), R = g.isVideoTexture !== !0, oe = W.__version === void 0 || Z === !0, ee = J.dataReady;
|
|
18613
|
-
let _e =
|
|
18613
|
+
let _e = D(g, Pe);
|
|
18614
18614
|
Ve(i.TEXTURE_CUBE_MAP, g);
|
|
18615
18615
|
let z;
|
|
18616
18616
|
if (ye) {
|
|
@@ -18675,9 +18675,9 @@ function Mm(i, e, t, n, s, r, a) {
|
|
|
18675
18675
|
const Z = n.get(g.depthTexture);
|
|
18676
18676
|
Z.__renderTarget = g, (!Z.__webglTexture || g.depthTexture.image.width !== g.width || g.depthTexture.image.height !== g.height) && (g.depthTexture.image.width = g.width, g.depthTexture.image.height = g.height, g.depthTexture.needsUpdate = !0), te(g.depthTexture, 0);
|
|
18677
18677
|
const J = Z.__webglTexture, W = Se(g);
|
|
18678
|
-
if (g.depthTexture.format ===
|
|
18678
|
+
if (g.depthTexture.format === Gi)
|
|
18679
18679
|
qe(g) ? o.framebufferTexture2DMultisampleEXT(i.FRAMEBUFFER, i.DEPTH_ATTACHMENT, i.TEXTURE_2D, J, 0, W) : i.framebufferTexture2D(i.FRAMEBUFFER, i.DEPTH_ATTACHMENT, i.TEXTURE_2D, J, 0);
|
|
18680
|
-
else if (g.depthTexture.format ===
|
|
18680
|
+
else if (g.depthTexture.format === Wi)
|
|
18681
18681
|
qe(g) ? o.framebufferTexture2DMultisampleEXT(i.FRAMEBUFFER, i.DEPTH_STENCIL_ATTACHMENT, i.TEXTURE_2D, J, 0, W) : i.framebufferTexture2D(i.FRAMEBUFFER, i.DEPTH_STENCIL_ATTACHMENT, i.TEXTURE_2D, J, 0);
|
|
18682
18682
|
else
|
|
18683
18683
|
throw new Error("Unknown depthTexture format");
|
|
@@ -18855,38 +18855,38 @@ function Sm(i, e) {
|
|
|
18855
18855
|
if (n === sn) return i.UNSIGNED_BYTE;
|
|
18856
18856
|
if (n === Sa) return i.UNSIGNED_SHORT_4_4_4_4;
|
|
18857
18857
|
if (n === Ea) return i.UNSIGNED_SHORT_5_5_5_1;
|
|
18858
|
-
if (n ===
|
|
18859
|
-
if (n ===
|
|
18860
|
-
if (n ===
|
|
18861
|
-
if (n ===
|
|
18858
|
+
if (n === al) return i.UNSIGNED_INT_5_9_9_9_REV;
|
|
18859
|
+
if (n === sl) return i.BYTE;
|
|
18860
|
+
if (n === rl) return i.SHORT;
|
|
18861
|
+
if (n === ki) return i.UNSIGNED_SHORT;
|
|
18862
18862
|
if (n === Ma) return i.INT;
|
|
18863
18863
|
if (n === Xn) return i.UNSIGNED_INT;
|
|
18864
18864
|
if (n === mn) return i.FLOAT;
|
|
18865
|
-
if (n ===
|
|
18866
|
-
if (n ===
|
|
18867
|
-
if (n ===
|
|
18865
|
+
if (n === qi) return i.HALF_FLOAT;
|
|
18866
|
+
if (n === ol) return i.ALPHA;
|
|
18867
|
+
if (n === ll) return i.RGB;
|
|
18868
18868
|
if (n === Yt) return i.RGBA;
|
|
18869
|
-
if (n ===
|
|
18870
|
-
if (n ===
|
|
18871
|
-
if (n ===
|
|
18869
|
+
if (n === Gi) return i.DEPTH_COMPONENT;
|
|
18870
|
+
if (n === Wi) return i.DEPTH_STENCIL;
|
|
18871
|
+
if (n === cl) return i.RED;
|
|
18872
18872
|
if (n === ya) return i.RED_INTEGER;
|
|
18873
|
-
if (n ===
|
|
18873
|
+
if (n === hl) return i.RG;
|
|
18874
18874
|
if (n === Ta) return i.RG_INTEGER;
|
|
18875
18875
|
if (n === ba) return i.RGBA_INTEGER;
|
|
18876
|
-
if (n ===
|
|
18876
|
+
if (n === As || n === ws || n === Rs || n === Cs)
|
|
18877
18877
|
if (a === et)
|
|
18878
18878
|
if (r = e.get("WEBGL_compressed_texture_s3tc_srgb"), r !== null) {
|
|
18879
|
-
if (n ===
|
|
18880
|
-
if (n ===
|
|
18881
|
-
if (n ===
|
|
18882
|
-
if (n ===
|
|
18879
|
+
if (n === As) return r.COMPRESSED_SRGB_S3TC_DXT1_EXT;
|
|
18880
|
+
if (n === ws) return r.COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT;
|
|
18881
|
+
if (n === Rs) return r.COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT;
|
|
18882
|
+
if (n === Cs) return r.COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT;
|
|
18883
18883
|
} else
|
|
18884
18884
|
return null;
|
|
18885
18885
|
else if (r = e.get("WEBGL_compressed_texture_s3tc"), r !== null) {
|
|
18886
|
-
if (n ===
|
|
18887
|
-
if (n ===
|
|
18888
|
-
if (n ===
|
|
18889
|
-
if (n ===
|
|
18886
|
+
if (n === As) return r.COMPRESSED_RGB_S3TC_DXT1_EXT;
|
|
18887
|
+
if (n === ws) return r.COMPRESSED_RGBA_S3TC_DXT1_EXT;
|
|
18888
|
+
if (n === Rs) return r.COMPRESSED_RGBA_S3TC_DXT3_EXT;
|
|
18889
|
+
if (n === Cs) return r.COMPRESSED_RGBA_S3TC_DXT5_EXT;
|
|
18890
18890
|
} else
|
|
18891
18891
|
return null;
|
|
18892
18892
|
if (n === Hr || n === kr || n === Vr || n === Gr)
|
|
@@ -18921,22 +18921,22 @@ function Sm(i, e) {
|
|
|
18921
18921
|
if (n === aa) return a === et ? r.COMPRESSED_SRGB8_ALPHA8_ASTC_12x12_KHR : r.COMPRESSED_RGBA_ASTC_12x12_KHR;
|
|
18922
18922
|
} else
|
|
18923
18923
|
return null;
|
|
18924
|
-
if (n ===
|
|
18924
|
+
if (n === Ps || n === oa || n === la)
|
|
18925
18925
|
if (r = e.get("EXT_texture_compression_bptc"), r !== null) {
|
|
18926
|
-
if (n ===
|
|
18926
|
+
if (n === Ps) return a === et ? r.COMPRESSED_SRGB_ALPHA_BPTC_UNORM_EXT : r.COMPRESSED_RGBA_BPTC_UNORM_EXT;
|
|
18927
18927
|
if (n === oa) return r.COMPRESSED_RGB_BPTC_SIGNED_FLOAT_EXT;
|
|
18928
18928
|
if (n === la) return r.COMPRESSED_RGB_BPTC_UNSIGNED_FLOAT_EXT;
|
|
18929
18929
|
} else
|
|
18930
18930
|
return null;
|
|
18931
|
-
if (n ===
|
|
18931
|
+
if (n === ul || n === ca || n === ha || n === ua)
|
|
18932
18932
|
if (r = e.get("EXT_texture_compression_rgtc"), r !== null) {
|
|
18933
|
-
if (n ===
|
|
18933
|
+
if (n === Ps) return r.COMPRESSED_RED_RGTC1_EXT;
|
|
18934
18934
|
if (n === ca) return r.COMPRESSED_SIGNED_RED_RGTC1_EXT;
|
|
18935
18935
|
if (n === ha) return r.COMPRESSED_RED_GREEN_RGTC2_EXT;
|
|
18936
18936
|
if (n === ua) return r.COMPRESSED_SIGNED_RED_GREEN_RGTC2_EXT;
|
|
18937
18937
|
} else
|
|
18938
18938
|
return null;
|
|
18939
|
-
return n ===
|
|
18939
|
+
return n === Vi ? i.UNSIGNED_INT_24_8 : i[n] !== void 0 ? i[n] : null;
|
|
18940
18940
|
}
|
|
18941
18941
|
return { convert: t };
|
|
18942
18942
|
}
|
|
@@ -19002,7 +19002,7 @@ class Tm {
|
|
|
19002
19002
|
depthHeight: { value: t.w }
|
|
19003
19003
|
}
|
|
19004
19004
|
});
|
|
19005
|
-
this.mesh = new jt(new
|
|
19005
|
+
this.mesh = new jt(new Gs(20, 20), n);
|
|
19006
19006
|
}
|
|
19007
19007
|
return this.mesh;
|
|
19008
19008
|
}
|
|
@@ -19034,7 +19034,7 @@ class bm extends jn {
|
|
|
19034
19034
|
let s = null, r = 1, a = null, o = "local-floor", l = 1, c = null, h = null, u = null, f = null, m = null, _ = null;
|
|
19035
19035
|
const v = new Tm(), p = t.getContextAttributes();
|
|
19036
19036
|
let d = null, b = null;
|
|
19037
|
-
const T = [], S = [],
|
|
19037
|
+
const T = [], S = [], D = new Oe();
|
|
19038
19038
|
let A = null;
|
|
19039
19039
|
const C = new zt();
|
|
19040
19040
|
C.viewport = new ct();
|
|
@@ -19065,7 +19065,7 @@ class bm extends jn {
|
|
|
19065
19065
|
const ae = S[$];
|
|
19066
19066
|
ae !== null && (S[$] = null, T[$].disconnect(ae));
|
|
19067
19067
|
}
|
|
19068
|
-
P = null, q = null, v.reset(), e.setRenderTarget(d), m = null, f = null, u = null, s = null, b = null, Ze.stop(), n.isPresenting = !1, e.setPixelRatio(A), e.setSize(
|
|
19068
|
+
P = null, q = null, v.reset(), e.setRenderTarget(d), m = null, f = null, u = null, s = null, b = null, Ze.stop(), n.isPresenting = !1, e.setPixelRatio(A), e.setSize(D.width, D.height, !1), n.dispatchEvent({ type: "sessionend" });
|
|
19069
19069
|
}
|
|
19070
19070
|
this.setFramebufferScaleFactor = function($) {
|
|
19071
19071
|
r = $, n.isPresenting === !0 && console.warn("THREE.WebXRManager: Cannot change framebuffer scale while presenting.");
|
|
@@ -19085,9 +19085,9 @@ class bm extends jn {
|
|
|
19085
19085
|
return s;
|
|
19086
19086
|
}, this.setSession = async function($) {
|
|
19087
19087
|
if (s = $, s !== null) {
|
|
19088
|
-
if (d = e.getRenderTarget(), s.addEventListener("select", k), s.addEventListener("selectstart", k), s.addEventListener("selectend", k), s.addEventListener("squeeze", k), s.addEventListener("squeezestart", k), s.addEventListener("squeezeend", k), s.addEventListener("end", j), s.addEventListener("inputsourceschange", te), p.xrCompatible !== !0 && await t.makeXRCompatible(), A = e.getPixelRatio(), e.getSize(
|
|
19088
|
+
if (d = e.getRenderTarget(), s.addEventListener("select", k), s.addEventListener("selectstart", k), s.addEventListener("selectend", k), s.addEventListener("squeeze", k), s.addEventListener("squeezestart", k), s.addEventListener("squeezeend", k), s.addEventListener("end", j), s.addEventListener("inputsourceschange", te), p.xrCompatible !== !0 && await t.makeXRCompatible(), A = e.getPixelRatio(), e.getSize(D), typeof XRWebGLBinding < "u" && "createProjectionLayer" in XRWebGLBinding.prototype) {
|
|
19089
19089
|
let G = null, Y = null, ne = null;
|
|
19090
|
-
p.depth && (ne = p.stencil ? t.DEPTH24_STENCIL8 : t.DEPTH_COMPONENT24, G = p.stencil ?
|
|
19090
|
+
p.depth && (ne = p.stencil ? t.DEPTH24_STENCIL8 : t.DEPTH_COMPONENT24, G = p.stencil ? Wi : Gi, Y = p.stencil ? Vi : Xn);
|
|
19091
19091
|
const pe = {
|
|
19092
19092
|
colorFormat: t.RGBA8,
|
|
19093
19093
|
depthFormat: ne,
|
|
@@ -19099,7 +19099,7 @@ class bm extends jn {
|
|
|
19099
19099
|
{
|
|
19100
19100
|
format: Yt,
|
|
19101
19101
|
type: sn,
|
|
19102
|
-
depthTexture: new
|
|
19102
|
+
depthTexture: new Tl(f.textureWidth, f.textureHeight, Y, void 0, void 0, void 0, void 0, void 0, void 0, G),
|
|
19103
19103
|
stencilBuffer: p.stencil,
|
|
19104
19104
|
colorSpace: e.outputColorSpace,
|
|
19105
19105
|
samples: p.antialias ? 4 : 0,
|
|
@@ -19236,7 +19236,7 @@ class bm extends jn {
|
|
|
19236
19236
|
}
|
|
19237
19237
|
be && be($, ae), ae.detectedPlanes && n.dispatchEvent({ type: "planesdetected", data: ae }), _ = null;
|
|
19238
19238
|
}
|
|
19239
|
-
const Ze = new
|
|
19239
|
+
const Ze = new Pl();
|
|
19240
19240
|
Ze.setAnimationLoop(Ve), this.setAnimationLoop = function($) {
|
|
19241
19241
|
be = $;
|
|
19242
19242
|
}, this.dispose = function() {
|
|
@@ -19249,7 +19249,7 @@ function wm(i, e) {
|
|
|
19249
19249
|
p.matrixAutoUpdate === !0 && p.updateMatrix(), d.value.copy(p.matrix);
|
|
19250
19250
|
}
|
|
19251
19251
|
function n(p, d) {
|
|
19252
|
-
d.color.getRGB(p.fogColor.value,
|
|
19252
|
+
d.color.getRGB(p.fogColor.value, Sl(i)), d.isFog ? (p.fogNear.value = d.near, p.fogFar.value = d.far) : d.isFogExp2 && (p.fogDensity.value = d.density);
|
|
19253
19253
|
}
|
|
19254
19254
|
function s(p, d, b, T, S) {
|
|
19255
19255
|
d.isMeshBasicMaterial || d.isMeshLambertMaterial ? r(p, d) : d.isMeshToonMaterial ? (r(p, d), u(p, d)) : d.isMeshPhongMaterial ? (r(p, d), h(p, d)) : d.isMeshStandardMaterial ? (r(p, d), f(p, d), d.isMeshPhysicalMaterial && m(p, d, S)) : d.isMeshMatcapMaterial ? (r(p, d), _(p, d)) : d.isMeshDepthMaterial ? r(p, d) : d.isMeshDistanceMaterial ? (r(p, d), v(p, d)) : d.isMeshNormalMaterial ? r(p, d) : d.isLineBasicMaterial ? (a(p, d), d.isLineDashedMaterial && o(p, d)) : d.isPointsMaterial ? l(p, d, b, T) : d.isSpriteMaterial ? c(p, d) : d.isShadowMaterial ? (p.color.value.copy(d.color), p.opacity.value = d.opacity) : d.isShaderMaterial && (d.uniformsNeedUpdate = !1);
|
|
@@ -19305,16 +19305,16 @@ function Rm(i, e, t, n) {
|
|
|
19305
19305
|
function c(b, T) {
|
|
19306
19306
|
let S = s[b.id];
|
|
19307
19307
|
S === void 0 && (_(b), S = h(b), s[b.id] = S, b.addEventListener("dispose", p));
|
|
19308
|
-
const
|
|
19309
|
-
n.updateUBOMapping(b,
|
|
19308
|
+
const D = T.program;
|
|
19309
|
+
n.updateUBOMapping(b, D);
|
|
19310
19310
|
const A = e.render.frame;
|
|
19311
19311
|
r[b.id] !== A && (f(b), r[b.id] = A);
|
|
19312
19312
|
}
|
|
19313
19313
|
function h(b) {
|
|
19314
19314
|
const T = u();
|
|
19315
19315
|
b.__bindingPointIndex = T;
|
|
19316
|
-
const S = i.createBuffer(),
|
|
19317
|
-
return i.bindBuffer(i.UNIFORM_BUFFER, S), i.bufferData(i.UNIFORM_BUFFER,
|
|
19316
|
+
const S = i.createBuffer(), D = b.__size, A = b.usage;
|
|
19317
|
+
return i.bindBuffer(i.UNIFORM_BUFFER, S), i.bufferData(i.UNIFORM_BUFFER, D, A), i.bindBuffer(i.UNIFORM_BUFFER, null), i.bindBufferBase(i.UNIFORM_BUFFER, T, S), S;
|
|
19318
19318
|
}
|
|
19319
19319
|
function u() {
|
|
19320
19320
|
for (let b = 0; b < o; b++)
|
|
@@ -19323,13 +19323,13 @@ function Rm(i, e, t, n) {
|
|
|
19323
19323
|
return console.error("THREE.WebGLRenderer: Maximum number of simultaneously usable uniforms groups reached."), 0;
|
|
19324
19324
|
}
|
|
19325
19325
|
function f(b) {
|
|
19326
|
-
const T = s[b.id], S = b.uniforms,
|
|
19326
|
+
const T = s[b.id], S = b.uniforms, D = b.__cache;
|
|
19327
19327
|
i.bindBuffer(i.UNIFORM_BUFFER, T);
|
|
19328
19328
|
for (let A = 0, C = S.length; A < C; A++) {
|
|
19329
19329
|
const F = Array.isArray(S[A]) ? S[A] : [S[A]];
|
|
19330
19330
|
for (let E = 0, M = F.length; E < M; E++) {
|
|
19331
19331
|
const P = F[E];
|
|
19332
|
-
if (m(P, A, E,
|
|
19332
|
+
if (m(P, A, E, D) === !0) {
|
|
19333
19333
|
const q = P.__offset, k = Array.isArray(P.value) ? P.value : [P.value];
|
|
19334
19334
|
let j = 0;
|
|
19335
19335
|
for (let te = 0; te < k.length; te++) {
|
|
@@ -19342,15 +19342,15 @@ function Rm(i, e, t, n) {
|
|
|
19342
19342
|
}
|
|
19343
19343
|
i.bindBuffer(i.UNIFORM_BUFFER, null);
|
|
19344
19344
|
}
|
|
19345
|
-
function m(b, T, S,
|
|
19345
|
+
function m(b, T, S, D) {
|
|
19346
19346
|
const A = b.value, C = T + "_" + S;
|
|
19347
|
-
if (
|
|
19348
|
-
return typeof A == "number" || typeof A == "boolean" ?
|
|
19347
|
+
if (D[C] === void 0)
|
|
19348
|
+
return typeof A == "number" || typeof A == "boolean" ? D[C] = A : D[C] = A.clone(), !0;
|
|
19349
19349
|
{
|
|
19350
|
-
const F =
|
|
19350
|
+
const F = D[C];
|
|
19351
19351
|
if (typeof A == "number" || typeof A == "boolean") {
|
|
19352
19352
|
if (F !== A)
|
|
19353
|
-
return
|
|
19353
|
+
return D[C] = A, !0;
|
|
19354
19354
|
} else if (F.equals(A) === !1)
|
|
19355
19355
|
return F.copy(A), !0;
|
|
19356
19356
|
}
|
|
@@ -19359,19 +19359,19 @@ function Rm(i, e, t, n) {
|
|
|
19359
19359
|
function _(b) {
|
|
19360
19360
|
const T = b.uniforms;
|
|
19361
19361
|
let S = 0;
|
|
19362
|
-
const
|
|
19362
|
+
const D = 16;
|
|
19363
19363
|
for (let C = 0, F = T.length; C < F; C++) {
|
|
19364
19364
|
const E = Array.isArray(T[C]) ? T[C] : [T[C]];
|
|
19365
19365
|
for (let M = 0, P = E.length; M < P; M++) {
|
|
19366
19366
|
const q = E[M], k = Array.isArray(q.value) ? q.value : [q.value];
|
|
19367
19367
|
for (let j = 0, te = k.length; j < te; j++) {
|
|
19368
|
-
const K = k[j], re = v(K), V = S %
|
|
19369
|
-
S += de, ge !== 0 &&
|
|
19368
|
+
const K = k[j], re = v(K), V = S % D, de = V % re.boundary, ge = V + de;
|
|
19369
|
+
S += de, ge !== 0 && D - ge < re.storage && (S += D - ge), q.__data = new Float32Array(re.storage / Float32Array.BYTES_PER_ELEMENT), q.__offset = S, S += re.storage;
|
|
19370
19370
|
}
|
|
19371
19371
|
}
|
|
19372
19372
|
}
|
|
19373
|
-
const A = S %
|
|
19374
|
-
return A > 0 && (S +=
|
|
19373
|
+
const A = S % D;
|
|
19374
|
+
return A > 0 && (S += D - A), b.__size = S, b.__cache = {}, this;
|
|
19375
19375
|
}
|
|
19376
19376
|
function v(b) {
|
|
19377
19377
|
const T = {
|
|
@@ -19443,7 +19443,7 @@ class Cm {
|
|
|
19443
19443
|
onShaderError: null
|
|
19444
19444
|
}, this.autoClear = !0, this.autoClearColor = !0, this.autoClearDepth = !0, this.autoClearStencil = !0, this.sortObjects = !0, this.clippingPlanes = [], this.localClippingEnabled = !1, this.toneMapping = Dn, this.toneMappingExposure = 1, this.transmissionResolutionScale = 1;
|
|
19445
19445
|
const S = this;
|
|
19446
|
-
let
|
|
19446
|
+
let D = !1;
|
|
19447
19447
|
this._outputColorSpace = xt;
|
|
19448
19448
|
let A = 0, C = 0, F = null, E = -1, M = null;
|
|
19449
19449
|
const P = new ct(), q = new ct();
|
|
@@ -19460,8 +19460,8 @@ class Cm {
|
|
|
19460
19460
|
return F === null ? V : 1;
|
|
19461
19461
|
}
|
|
19462
19462
|
let w = n;
|
|
19463
|
-
function rt(x,
|
|
19464
|
-
return t.getContext(x,
|
|
19463
|
+
function rt(x, L) {
|
|
19464
|
+
return t.getContext(x, L);
|
|
19465
19465
|
}
|
|
19466
19466
|
try {
|
|
19467
19467
|
const x = {
|
|
@@ -19475,9 +19475,9 @@ class Cm {
|
|
|
19475
19475
|
failIfMajorPerformanceCaveat: u
|
|
19476
19476
|
};
|
|
19477
19477
|
if ("setAttribute" in t && t.setAttribute("data-engine", `three.js r${va}`), t.addEventListener("webglcontextlost", _e, !1), t.addEventListener("webglcontextrestored", z, !1), t.addEventListener("webglcontextcreationerror", U, !1), w === null) {
|
|
19478
|
-
const
|
|
19479
|
-
if (w = rt(
|
|
19480
|
-
throw rt(
|
|
19478
|
+
const L = "webgl2";
|
|
19479
|
+
if (w = rt(L, x), w === null)
|
|
19480
|
+
throw rt(L) ? new Error("Error creating WebGL context with your selected attributes.") : new Error("Error creating WebGL context.");
|
|
19481
19481
|
}
|
|
19482
19482
|
} catch (x) {
|
|
19483
19483
|
throw console.error("THREE.WebGLRenderer: " + x.message), x;
|
|
@@ -19504,26 +19504,26 @@ class Cm {
|
|
|
19504
19504
|
x !== void 0 && (V = x, this.setSize(K, re, !1));
|
|
19505
19505
|
}, this.getSize = function(x) {
|
|
19506
19506
|
return x.set(K, re);
|
|
19507
|
-
}, this.setSize = function(x,
|
|
19507
|
+
}, this.setSize = function(x, L, B = !0) {
|
|
19508
19508
|
if (ee.isPresenting) {
|
|
19509
19509
|
console.warn("THREE.WebGLRenderer: Can't change size while VR device is presenting.");
|
|
19510
19510
|
return;
|
|
19511
19511
|
}
|
|
19512
|
-
K = x, re =
|
|
19512
|
+
K = x, re = L, t.width = Math.floor(x * V), t.height = Math.floor(L * V), B === !0 && (t.style.width = x + "px", t.style.height = L + "px"), this.setViewport(0, 0, x, L);
|
|
19513
19513
|
}, this.getDrawingBufferSize = function(x) {
|
|
19514
19514
|
return x.set(K * V, re * V).floor();
|
|
19515
|
-
}, this.setDrawingBufferSize = function(x,
|
|
19516
|
-
K = x, re =
|
|
19515
|
+
}, this.setDrawingBufferSize = function(x, L, B) {
|
|
19516
|
+
K = x, re = L, V = B, t.width = Math.floor(x * B), t.height = Math.floor(L * B), this.setViewport(0, 0, x, L);
|
|
19517
19517
|
}, this.getCurrentViewport = function(x) {
|
|
19518
19518
|
return x.copy(P);
|
|
19519
19519
|
}, this.getViewport = function(x) {
|
|
19520
19520
|
return x.copy(be);
|
|
19521
|
-
}, this.setViewport = function(x,
|
|
19522
|
-
x.isVector4 ? be.set(x.x, x.y, x.z, x.w) : be.set(x,
|
|
19521
|
+
}, this.setViewport = function(x, L, B, H) {
|
|
19522
|
+
x.isVector4 ? be.set(x.x, x.y, x.z, x.w) : be.set(x, L, B, H), Se.viewport(P.copy(be).multiplyScalar(V).round());
|
|
19523
19523
|
}, this.getScissor = function(x) {
|
|
19524
19524
|
return x.copy(Ve);
|
|
19525
|
-
}, this.setScissor = function(x,
|
|
19526
|
-
x.isVector4 ? Ve.set(x.x, x.y, x.z, x.w) : Ve.set(x,
|
|
19525
|
+
}, this.setScissor = function(x, L, B, H) {
|
|
19526
|
+
x.isVector4 ? Ve.set(x.x, x.y, x.z, x.w) : Ve.set(x, L, B, H), Se.scissor(q.copy(Ve).multiplyScalar(V).round());
|
|
19527
19527
|
}, this.getScissorTest = function() {
|
|
19528
19528
|
return Ze;
|
|
19529
19529
|
}, this.setScissorTest = function(x) {
|
|
@@ -19540,7 +19540,7 @@ class Cm {
|
|
|
19540
19540
|
return Q.getClearAlpha();
|
|
19541
19541
|
}, this.setClearAlpha = function() {
|
|
19542
19542
|
Q.setClearAlpha(...arguments);
|
|
19543
|
-
}, this.clear = function(x = !0,
|
|
19543
|
+
}, this.clear = function(x = !0, L = !0, B = !0) {
|
|
19544
19544
|
let H = 0;
|
|
19545
19545
|
if (x) {
|
|
19546
19546
|
let I = !1;
|
|
@@ -19549,12 +19549,12 @@ class Cm {
|
|
|
19549
19549
|
I = se === ba || se === Ta || se === ya;
|
|
19550
19550
|
}
|
|
19551
19551
|
if (I) {
|
|
19552
|
-
const se = F.texture.type, fe = se === sn || se === Xn || se ===
|
|
19552
|
+
const se = F.texture.type, fe = se === sn || se === Xn || se === ki || se === Vi || se === Sa || se === Ea, Me = Q.getClearColor(), ve = Q.getClearAlpha(), Ie = Me.r, Ne = Me.g, Re = Me.b;
|
|
19553
19553
|
fe ? (_[0] = Ie, _[1] = Ne, _[2] = Re, _[3] = ve, w.clearBufferuiv(w.COLOR, 0, _)) : (v[0] = Ie, v[1] = Ne, v[2] = Re, v[3] = ve, w.clearBufferiv(w.COLOR, 0, v));
|
|
19554
19554
|
} else
|
|
19555
19555
|
H |= w.COLOR_BUFFER_BIT;
|
|
19556
19556
|
}
|
|
19557
|
-
|
|
19557
|
+
L && (H |= w.DEPTH_BUFFER_BIT), B && (H |= w.STENCIL_BUFFER_BIT, this.state.buffers.stencil.setMask(4294967295)), w.clear(H);
|
|
19558
19558
|
}, this.clearColor = function() {
|
|
19559
19559
|
this.clear(!0, !1, !1);
|
|
19560
19560
|
}, this.clearDepth = function() {
|
|
@@ -19565,32 +19565,32 @@ class Cm {
|
|
|
19565
19565
|
t.removeEventListener("webglcontextlost", _e, !1), t.removeEventListener("webglcontextrestored", z, !1), t.removeEventListener("webglcontextcreationerror", U, !1), Q.dispose(), Ee.dispose(), ce.dispose(), we.dispose(), ot.dispose(), y.dispose(), Z.dispose(), Te.dispose(), R.dispose(), J.dispose(), ee.dispose(), ee.removeEventListener("sessionstart", wi), ee.removeEventListener("sessionend", Ri), $t.stop();
|
|
19566
19566
|
};
|
|
19567
19567
|
function _e(x) {
|
|
19568
|
-
x.preventDefault(), console.log("THREE.WebGLRenderer: Context Lost."),
|
|
19568
|
+
x.preventDefault(), console.log("THREE.WebGLRenderer: Context Lost."), D = !0;
|
|
19569
19569
|
}
|
|
19570
19570
|
function z() {
|
|
19571
|
-
console.log("THREE.WebGLRenderer: Context Restored."),
|
|
19572
|
-
const x = qe.autoReset,
|
|
19573
|
-
oe(), qe.autoReset = x, ye.enabled =
|
|
19571
|
+
console.log("THREE.WebGLRenderer: Context Restored."), D = !1;
|
|
19572
|
+
const x = qe.autoReset, L = ye.enabled, B = ye.autoUpdate, H = ye.needsUpdate, I = ye.type;
|
|
19573
|
+
oe(), qe.autoReset = x, ye.enabled = L, ye.autoUpdate = B, ye.needsUpdate = H, ye.type = I;
|
|
19574
19574
|
}
|
|
19575
19575
|
function U(x) {
|
|
19576
19576
|
console.error("THREE.WebGLRenderer: A WebGL context could not be created. Reason: ", x.statusMessage);
|
|
19577
19577
|
}
|
|
19578
19578
|
function he(x) {
|
|
19579
|
-
const
|
|
19580
|
-
|
|
19579
|
+
const L = x.target;
|
|
19580
|
+
L.removeEventListener("dispose", he), De(L);
|
|
19581
19581
|
}
|
|
19582
19582
|
function De(x) {
|
|
19583
19583
|
Be(x), we.remove(x);
|
|
19584
19584
|
}
|
|
19585
19585
|
function Be(x) {
|
|
19586
|
-
const
|
|
19587
|
-
|
|
19586
|
+
const L = we.get(x).programs;
|
|
19587
|
+
L !== void 0 && (L.forEach(function(B) {
|
|
19588
19588
|
J.releaseProgram(B);
|
|
19589
19589
|
}), x.isShaderMaterial && J.releaseShaderCache(x));
|
|
19590
19590
|
}
|
|
19591
|
-
this.renderBufferDirect = function(x,
|
|
19592
|
-
|
|
19593
|
-
const fe = I.isMesh && I.matrixWorld.determinant() < 0, Me =
|
|
19591
|
+
this.renderBufferDirect = function(x, L, B, H, I, se) {
|
|
19592
|
+
L === null && (L = le);
|
|
19593
|
+
const fe = I.isMesh && I.matrixWorld.determinant() < 0, Me = Hl(x, L, B, H, I);
|
|
19594
19594
|
Se.setMaterial(H, fe);
|
|
19595
19595
|
let ve = B.index, Ie = 1;
|
|
19596
19596
|
if (H.wireframe === !0) {
|
|
@@ -19628,14 +19628,14 @@ class Cm {
|
|
|
19628
19628
|
} else
|
|
19629
19629
|
Ke.render(Ye, at);
|
|
19630
19630
|
};
|
|
19631
|
-
function He(x,
|
|
19632
|
-
x.transparent === !0 && x.side === fn && x.forceSinglePass === !1 ? (x.side = Pt, x.needsUpdate = !0,
|
|
19631
|
+
function He(x, L, B) {
|
|
19632
|
+
x.transparent === !0 && x.side === fn && x.forceSinglePass === !1 ? (x.side = Pt, x.needsUpdate = !0, Zi(x, L, B), x.side = vn, x.needsUpdate = !0, Zi(x, L, B), x.side = fn) : Zi(x, L, B);
|
|
19633
19633
|
}
|
|
19634
|
-
this.compile = function(x,
|
|
19635
|
-
B === null && (B = x), d = ce.get(B), d.init(
|
|
19636
|
-
I.isLight && I.layers.test(
|
|
19634
|
+
this.compile = function(x, L, B = null) {
|
|
19635
|
+
B === null && (B = x), d = ce.get(B), d.init(L), T.push(d), B.traverseVisible(function(I) {
|
|
19636
|
+
I.isLight && I.layers.test(L.layers) && (d.pushLight(I), I.castShadow && d.pushShadow(I));
|
|
19637
19637
|
}), x !== B && x.traverseVisible(function(I) {
|
|
19638
|
-
I.isLight && I.layers.test(
|
|
19638
|
+
I.isLight && I.layers.test(L.layers) && (d.pushLight(I), I.castShadow && d.pushShadow(I));
|
|
19639
19639
|
}), d.setupLights();
|
|
19640
19640
|
const H = /* @__PURE__ */ new Set();
|
|
19641
19641
|
return x.traverse(function(I) {
|
|
@@ -19651,8 +19651,8 @@ class Cm {
|
|
|
19651
19651
|
else
|
|
19652
19652
|
He(se, B, I), H.add(se);
|
|
19653
19653
|
}), d = T.pop(), H;
|
|
19654
|
-
}, this.compileAsync = function(x,
|
|
19655
|
-
const H = this.compile(x,
|
|
19654
|
+
}, this.compileAsync = function(x, L, B = null) {
|
|
19655
|
+
const H = this.compile(x, L, B);
|
|
19656
19656
|
return new Promise((I) => {
|
|
19657
19657
|
function se() {
|
|
19658
19658
|
if (H.forEach(function(fe) {
|
|
@@ -19676,25 +19676,25 @@ class Cm {
|
|
|
19676
19676
|
function Ri() {
|
|
19677
19677
|
$t.start();
|
|
19678
19678
|
}
|
|
19679
|
-
const $t = new
|
|
19679
|
+
const $t = new Pl();
|
|
19680
19680
|
$t.setAnimationLoop(It), typeof self < "u" && $t.setContext(self), this.setAnimationLoop = function(x) {
|
|
19681
19681
|
ht = x, ee.setAnimationLoop(x), x === null ? $t.stop() : $t.start();
|
|
19682
|
-
}, ee.addEventListener("sessionstart", wi), ee.addEventListener("sessionend", Ri), this.render = function(x,
|
|
19683
|
-
if (
|
|
19682
|
+
}, ee.addEventListener("sessionstart", wi), ee.addEventListener("sessionend", Ri), this.render = function(x, L) {
|
|
19683
|
+
if (L !== void 0 && L.isCamera !== !0) {
|
|
19684
19684
|
console.error("THREE.WebGLRenderer.render: camera is not an instance of THREE.Camera.");
|
|
19685
19685
|
return;
|
|
19686
19686
|
}
|
|
19687
|
-
if (
|
|
19688
|
-
if (x.matrixWorldAutoUpdate === !0 && x.updateMatrixWorld(),
|
|
19687
|
+
if (D === !0) return;
|
|
19688
|
+
if (x.matrixWorldAutoUpdate === !0 && x.updateMatrixWorld(), L.parent === null && L.matrixWorldAutoUpdate === !0 && L.updateMatrixWorld(), ee.enabled === !0 && ee.isPresenting === !0 && (ee.cameraAutoUpdate === !0 && ee.updateCamera(L), L = ee.getCamera()), x.isScene === !0 && x.onBeforeRender(S, x, L, F), d = ce.get(x, T.length), d.init(L), T.push(d), ne.multiplyMatrices(L.projectionMatrix, L.matrixWorldInverse), $.setFromProjectionMatrix(ne), G = this.localClippingEnabled, ae = xe.init(this.clippingPlanes, G), p = Ee.get(x, b.length), p.init(), b.push(p), ee.enabled === !0 && ee.isPresenting === !0) {
|
|
19689
19689
|
const se = S.xr.getDepthSensingMesh();
|
|
19690
|
-
se !== null && Kn(se,
|
|
19690
|
+
se !== null && Kn(se, L, -1 / 0, S.sortObjects);
|
|
19691
19691
|
}
|
|
19692
|
-
Kn(x,
|
|
19692
|
+
Kn(x, L, 0, S.sortObjects), p.finish(), S.sortObjects === !0 && p.sort(de, ge), Ae = ee.enabled === !1 || ee.isPresenting === !1 || ee.hasDepthSensing() === !1, Ae && Q.addToRenderList(p, x), this.info.render.frame++, ae === !0 && xe.beginShadows();
|
|
19693
19693
|
const B = d.state.shadowsArray;
|
|
19694
|
-
ye.render(B, x,
|
|
19694
|
+
ye.render(B, x, L), ae === !0 && xe.endShadows(), this.info.autoReset === !0 && this.info.reset();
|
|
19695
19695
|
const H = p.opaque, I = p.transmissive;
|
|
19696
|
-
if (d.setupLights(),
|
|
19697
|
-
const se =
|
|
19696
|
+
if (d.setupLights(), L.isArrayCamera) {
|
|
19697
|
+
const se = L.cameras;
|
|
19698
19698
|
if (I.length > 0)
|
|
19699
19699
|
for (let fe = 0, Me = se.length; fe < Me; fe++) {
|
|
19700
19700
|
const ve = se[fe];
|
|
@@ -19706,16 +19706,16 @@ class Cm {
|
|
|
19706
19706
|
Ci(p, x, ve, ve.viewport);
|
|
19707
19707
|
}
|
|
19708
19708
|
} else
|
|
19709
|
-
I.length > 0 && Jt(H, I, x,
|
|
19710
|
-
F !== null && C === 0 && (Fe.updateMultisampleRenderTarget(F), Fe.updateRenderTargetMipmap(F)), x.isScene === !0 && x.onAfterRender(S, x,
|
|
19709
|
+
I.length > 0 && Jt(H, I, x, L), Ae && Q.render(x), Ci(p, x, L);
|
|
19710
|
+
F !== null && C === 0 && (Fe.updateMultisampleRenderTarget(F), Fe.updateRenderTargetMipmap(F)), x.isScene === !0 && x.onAfterRender(S, x, L), Te.resetDefaultState(), E = -1, M = null, T.pop(), T.length > 0 ? (d = T[T.length - 1], ae === !0 && xe.setGlobalState(S.clippingPlanes, d.state.camera)) : d = null, b.pop(), b.length > 0 ? p = b[b.length - 1] : p = null;
|
|
19711
19711
|
};
|
|
19712
|
-
function Kn(x,
|
|
19712
|
+
function Kn(x, L, B, H) {
|
|
19713
19713
|
if (x.visible === !1) return;
|
|
19714
|
-
if (x.layers.test(
|
|
19714
|
+
if (x.layers.test(L.layers)) {
|
|
19715
19715
|
if (x.isGroup)
|
|
19716
19716
|
B = x.renderOrder;
|
|
19717
19717
|
else if (x.isLOD)
|
|
19718
|
-
x.autoUpdate === !0 && x.update(
|
|
19718
|
+
x.autoUpdate === !0 && x.update(L);
|
|
19719
19719
|
else if (x.isLight)
|
|
19720
19720
|
d.pushLight(x), x.castShadow && d.pushShadow(x);
|
|
19721
19721
|
else if (x.isSprite) {
|
|
@@ -19737,18 +19737,18 @@ class Cm {
|
|
|
19737
19737
|
}
|
|
19738
19738
|
const se = x.children;
|
|
19739
19739
|
for (let fe = 0, Me = se.length; fe < Me; fe++)
|
|
19740
|
-
Kn(se[fe],
|
|
19740
|
+
Kn(se[fe], L, B, H);
|
|
19741
19741
|
}
|
|
19742
|
-
function Ci(x,
|
|
19742
|
+
function Ci(x, L, B, H) {
|
|
19743
19743
|
const I = x.opaque, se = x.transmissive, fe = x.transparent;
|
|
19744
|
-
d.setupLightsView(B), ae === !0 && xe.setGlobalState(S.clippingPlanes, B), H && Se.viewport(P.copy(H)), I.length > 0 && Mt(I,
|
|
19744
|
+
d.setupLightsView(B), ae === !0 && xe.setGlobalState(S.clippingPlanes, B), H && Se.viewport(P.copy(H)), I.length > 0 && Mt(I, L, B), se.length > 0 && Mt(se, L, B), fe.length > 0 && Mt(fe, L, B), Se.buffers.depth.setTest(!0), Se.buffers.depth.setMask(!0), Se.buffers.color.setMask(!0), Se.setPolygonOffset(!1);
|
|
19745
19745
|
}
|
|
19746
|
-
function Jt(x,
|
|
19746
|
+
function Jt(x, L, B, H) {
|
|
19747
19747
|
if ((B.isScene === !0 ? B.overrideMaterial : null) !== null)
|
|
19748
19748
|
return;
|
|
19749
19749
|
d.state.transmissionRenderTarget[H.id] === void 0 && (d.state.transmissionRenderTarget[H.id] = new Yn(1, 1, {
|
|
19750
19750
|
generateMipmaps: !0,
|
|
19751
|
-
type: We.has("EXT_color_buffer_half_float") || We.has("EXT_color_buffer_float") ?
|
|
19751
|
+
type: We.has("EXT_color_buffer_half_float") || We.has("EXT_color_buffer_float") ? qi : sn,
|
|
19752
19752
|
minFilter: Wn,
|
|
19753
19753
|
samples: 4,
|
|
19754
19754
|
stencilBuffer: r,
|
|
@@ -19765,8 +19765,8 @@ class Cm {
|
|
|
19765
19765
|
const Ie = H.viewport;
|
|
19766
19766
|
if (H.viewport !== void 0 && (H.viewport = void 0), d.setupLightsView(H), ae === !0 && xe.setGlobalState(S.clippingPlanes, H), Mt(x, B, H), Fe.updateMultisampleRenderTarget(se), Fe.updateRenderTargetMipmap(se), We.has("WEBGL_multisampled_render_to_texture") === !1) {
|
|
19767
19767
|
let Ne = !1;
|
|
19768
|
-
for (let Re = 0, Ye =
|
|
19769
|
-
const Qe =
|
|
19768
|
+
for (let Re = 0, Ye = L.length; Re < Ye; Re++) {
|
|
19769
|
+
const Qe = L[Re], at = Qe.object, lt = Qe.geometry, Ke = Qe.material, Le = Qe.group;
|
|
19770
19770
|
if (Ke.side === fn && at.layers.test(H.layers)) {
|
|
19771
19771
|
const vt = Ke.side;
|
|
19772
19772
|
Ke.side = Pt, Ke.needsUpdate = !0, Mn(at, B, H, lt, Ke, Le), Ke.side = vt, Ke.needsUpdate = !0, Ne = !0;
|
|
@@ -19776,22 +19776,22 @@ class Cm {
|
|
|
19776
19776
|
}
|
|
19777
19777
|
S.setRenderTarget(Me), S.setClearColor(j, te), Ie !== void 0 && (H.viewport = Ie), S.toneMapping = ve;
|
|
19778
19778
|
}
|
|
19779
|
-
function Mt(x,
|
|
19780
|
-
const H =
|
|
19779
|
+
function Mt(x, L, B) {
|
|
19780
|
+
const H = L.isScene === !0 ? L.overrideMaterial : null;
|
|
19781
19781
|
for (let I = 0, se = x.length; I < se; I++) {
|
|
19782
19782
|
const fe = x[I], Me = fe.object, ve = fe.geometry, Ie = fe.group;
|
|
19783
19783
|
let Ne = fe.material;
|
|
19784
|
-
Ne.allowOverride === !0 && H !== null && (Ne = H), Me.layers.test(B.layers) && Mn(Me,
|
|
19784
|
+
Ne.allowOverride === !0 && H !== null && (Ne = H), Me.layers.test(B.layers) && Mn(Me, L, B, ve, Ne, Ie);
|
|
19785
19785
|
}
|
|
19786
19786
|
}
|
|
19787
|
-
function Mn(x,
|
|
19788
|
-
x.onBeforeRender(S,
|
|
19787
|
+
function Mn(x, L, B, H, I, se) {
|
|
19788
|
+
x.onBeforeRender(S, L, B, H, I, se), x.modelViewMatrix.multiplyMatrices(B.matrixWorldInverse, x.matrixWorld), x.normalMatrix.getNormalMatrix(x.modelViewMatrix), I.onBeforeRender(S, L, B, H, x, se), I.transparent === !0 && I.side === fn && I.forceSinglePass === !1 ? (I.side = Pt, I.needsUpdate = !0, S.renderBufferDirect(B, L, H, I, x, se), I.side = vn, I.needsUpdate = !0, S.renderBufferDirect(B, L, H, I, x, se), I.side = fn) : S.renderBufferDirect(B, L, H, I, x, se), x.onAfterRender(S, L, B, H, I, se);
|
|
19789
19789
|
}
|
|
19790
|
-
function
|
|
19791
|
-
|
|
19792
|
-
const H = we.get(x), I = d.state.lights, se = d.state.shadowsArray, fe = I.state.version, Me = J.getParameters(x, I.state, se,
|
|
19790
|
+
function Zi(x, L, B) {
|
|
19791
|
+
L.isScene !== !0 && (L = le);
|
|
19792
|
+
const H = we.get(x), I = d.state.lights, se = d.state.shadowsArray, fe = I.state.version, Me = J.getParameters(x, I.state, se, L, B), ve = J.getProgramCacheKey(Me);
|
|
19793
19793
|
let Ie = H.programs;
|
|
19794
|
-
H.environment = x.isMeshStandardMaterial ?
|
|
19794
|
+
H.environment = x.isMeshStandardMaterial ? L.environment : null, H.fog = L.fog, H.envMap = (x.isMeshStandardMaterial ? y : ot).get(x.envMap || H.environment), H.envMapRotation = H.environment !== null && x.envMap === null ? L.environmentRotation : x.envMapRotation, Ie === void 0 && (x.addEventListener("dispose", he), Ie = /* @__PURE__ */ new Map(), H.programs = Ie);
|
|
19795
19795
|
let Ne = Ie.get(ve);
|
|
19796
19796
|
if (Ne !== void 0) {
|
|
19797
19797
|
if (H.currentProgram === Ne && H.lightsStateVersion === fe)
|
|
@@ -19799,22 +19799,22 @@ class Cm {
|
|
|
19799
19799
|
} else
|
|
19800
19800
|
Me.uniforms = J.getUniforms(x), x.onBeforeCompile(Me, S), Ne = J.acquireProgram(Me, ve), Ie.set(ve, Ne), H.uniforms = Me.uniforms;
|
|
19801
19801
|
const Re = H.uniforms;
|
|
19802
|
-
return (!x.isShaderMaterial && !x.isRawShaderMaterial || x.clipping === !0) && (Re.clippingPlanes = xe.uniform), Da(x, Me), H.needsLights =
|
|
19802
|
+
return (!x.isShaderMaterial && !x.isRawShaderMaterial || x.clipping === !0) && (Re.clippingPlanes = xe.uniform), Da(x, Me), H.needsLights = Vl(x), H.lightsStateVersion = fe, H.needsLights && (Re.ambientLightColor.value = I.state.ambient, Re.lightProbe.value = I.state.probe, Re.directionalLights.value = I.state.directional, Re.directionalLightShadows.value = I.state.directionalShadow, Re.spotLights.value = I.state.spot, Re.spotLightShadows.value = I.state.spotShadow, Re.rectAreaLights.value = I.state.rectArea, Re.ltc_1.value = I.state.rectAreaLTC1, Re.ltc_2.value = I.state.rectAreaLTC2, Re.pointLights.value = I.state.point, Re.pointLightShadows.value = I.state.pointShadow, Re.hemisphereLights.value = I.state.hemi, Re.directionalShadowMap.value = I.state.directionalShadowMap, Re.directionalShadowMatrix.value = I.state.directionalShadowMatrix, Re.spotShadowMap.value = I.state.spotShadowMap, Re.spotLightMatrix.value = I.state.spotLightMatrix, Re.spotLightMap.value = I.state.spotLightMap, Re.pointShadowMap.value = I.state.pointShadowMap, Re.pointShadowMatrix.value = I.state.pointShadowMatrix), H.currentProgram = Ne, H.uniformsList = null, Ne;
|
|
19803
19803
|
}
|
|
19804
19804
|
function Pa(x) {
|
|
19805
19805
|
if (x.uniformsList === null) {
|
|
19806
|
-
const
|
|
19807
|
-
x.uniformsList =
|
|
19806
|
+
const L = x.currentProgram.getUniforms();
|
|
19807
|
+
x.uniformsList = Us.seqWithValue(L.seq, x.uniforms);
|
|
19808
19808
|
}
|
|
19809
19809
|
return x.uniformsList;
|
|
19810
19810
|
}
|
|
19811
|
-
function Da(x,
|
|
19811
|
+
function Da(x, L) {
|
|
19812
19812
|
const B = we.get(x);
|
|
19813
|
-
B.outputColorSpace =
|
|
19813
|
+
B.outputColorSpace = L.outputColorSpace, B.batching = L.batching, B.batchingColor = L.batchingColor, B.instancing = L.instancing, B.instancingColor = L.instancingColor, B.instancingMorph = L.instancingMorph, B.skinning = L.skinning, B.morphTargets = L.morphTargets, B.morphNormals = L.morphNormals, B.morphColors = L.morphColors, B.morphTargetsCount = L.morphTargetsCount, B.numClippingPlanes = L.numClippingPlanes, B.numIntersection = L.numClipIntersection, B.vertexAlphas = L.vertexAlphas, B.vertexTangents = L.vertexTangents, B.toneMapping = L.toneMapping;
|
|
19814
19814
|
}
|
|
19815
|
-
function
|
|
19816
|
-
|
|
19817
|
-
const se =
|
|
19815
|
+
function Hl(x, L, B, H, I) {
|
|
19816
|
+
L.isScene !== !0 && (L = le), Fe.resetTextureUnits();
|
|
19817
|
+
const se = L.fog, fe = H.isMeshStandardMaterial ? L.environment : null, Me = F === null ? S.outputColorSpace : F.isXRRenderTarget === !0 ? F.texture.colorSpace : Ei, ve = (H.isMeshStandardMaterial ? y : ot).get(H.envMap || fe), Ie = H.vertexColors === !0 && !!B.attributes.color && B.attributes.color.itemSize === 4, Ne = !!B.attributes.tangent && (!!H.normalMap || H.anisotropy > 0), Re = !!B.morphAttributes.position, Ye = !!B.morphAttributes.normal, Qe = !!B.morphAttributes.color;
|
|
19818
19818
|
let at = Dn;
|
|
19819
19819
|
H.toneMapped && (F === null || F.isXRRenderTarget === !0) && (at = S.toneMapping);
|
|
19820
19820
|
const lt = B.morphAttributes.position || B.morphAttributes.normal || B.morphAttributes.color, Ke = lt !== void 0 ? lt.length : 0, Le = we.get(H), vt = d.state.lights;
|
|
@@ -19825,7 +19825,7 @@ class Cm {
|
|
|
19825
19825
|
let $e = !1;
|
|
19826
19826
|
H.version === Le.__version ? (Le.needsLights && Le.lightsStateVersion !== vt.state.version || Le.outputColorSpace !== Me || I.isBatchedMesh && Le.batching === !1 || !I.isBatchedMesh && Le.batching === !0 || I.isBatchedMesh && Le.batchingColor === !0 && I.colorTexture === null || I.isBatchedMesh && Le.batchingColor === !1 && I.colorTexture !== null || I.isInstancedMesh && Le.instancing === !1 || !I.isInstancedMesh && Le.instancing === !0 || I.isSkinnedMesh && Le.skinning === !1 || !I.isSkinnedMesh && Le.skinning === !0 || I.isInstancedMesh && Le.instancingColor === !0 && I.instanceColor === null || I.isInstancedMesh && Le.instancingColor === !1 && I.instanceColor !== null || I.isInstancedMesh && Le.instancingMorph === !0 && I.morphTexture === null || I.isInstancedMesh && Le.instancingMorph === !1 && I.morphTexture !== null || Le.envMap !== ve || H.fog === !0 && Le.fog !== se || Le.numClippingPlanes !== void 0 && (Le.numClippingPlanes !== xe.numPlanes || Le.numIntersection !== xe.numIntersection) || Le.vertexAlphas !== Ie || Le.vertexTangents !== Ne || Le.morphTargets !== Re || Le.morphNormals !== Ye || Le.morphColors !== Qe || Le.toneMapping !== at || Le.morphTargetsCount !== Ke) && ($e = !0) : ($e = !0, Le.__version = H.version);
|
|
19827
19827
|
let kt = Le.currentProgram;
|
|
19828
|
-
$e === !0 && (kt =
|
|
19828
|
+
$e === !0 && (kt = Zi(H, L, I));
|
|
19829
19829
|
let Zn = !1, Dt = !1, Pi = !1;
|
|
19830
19830
|
const it = kt.getUniforms(), Nt = Le.uniforms;
|
|
19831
19831
|
if (Se.useProgram(kt.program) && (Zn = !0, Dt = !0, Pi = !0), H.id !== E && (E = H.id, Dt = !0), Zn || M !== x) {
|
|
@@ -19844,19 +19844,19 @@ class Cm {
|
|
|
19844
19844
|
}
|
|
19845
19845
|
I.isBatchedMesh && (it.setOptional(w, I, "batchingTexture"), it.setValue(w, "batchingTexture", I._matricesTexture, Fe), it.setOptional(w, I, "batchingIdTexture"), it.setValue(w, "batchingIdTexture", I._indirectTexture, Fe), it.setOptional(w, I, "batchingColorTexture"), I._colorsTexture !== null && it.setValue(w, "batchingColorTexture", I._colorsTexture, Fe));
|
|
19846
19846
|
const Ft = B.morphAttributes;
|
|
19847
|
-
if ((Ft.position !== void 0 || Ft.normal !== void 0 || Ft.color !== void 0) && me.update(I, B, kt), (Dt || Le.receiveShadow !== I.receiveShadow) && (Le.receiveShadow = I.receiveShadow, it.setValue(w, "receiveShadow", I.receiveShadow)), H.isMeshGouraudMaterial && H.envMap !== null && (Nt.envMap.value = ve, Nt.flipEnvMap.value = ve.isCubeTexture && ve.isRenderTargetTexture === !1 ? -1 : 1), H.isMeshStandardMaterial && H.envMap === null &&
|
|
19847
|
+
if ((Ft.position !== void 0 || Ft.normal !== void 0 || Ft.color !== void 0) && me.update(I, B, kt), (Dt || Le.receiveShadow !== I.receiveShadow) && (Le.receiveShadow = I.receiveShadow, it.setValue(w, "receiveShadow", I.receiveShadow)), H.isMeshGouraudMaterial && H.envMap !== null && (Nt.envMap.value = ve, Nt.flipEnvMap.value = ve.isCubeTexture && ve.isRenderTargetTexture === !1 ? -1 : 1), H.isMeshStandardMaterial && H.envMap === null && L.environment !== null && (Nt.envMapIntensity.value = L.environmentIntensity), Dt && (it.setValue(w, "toneMappingExposure", S.toneMappingExposure), Le.needsLights && kl(Nt, Pi), se && H.fog === !0 && W.refreshFogUniforms(Nt, se), W.refreshMaterialUniforms(Nt, H, V, re, d.state.transmissionRenderTarget[x.id]), Us.upload(w, Pa(Le), Nt, Fe)), H.isShaderMaterial && H.uniformsNeedUpdate === !0 && (Us.upload(w, Pa(Le), Nt, Fe), H.uniformsNeedUpdate = !1), H.isSpriteMaterial && it.setValue(w, "center", I.center), it.setValue(w, "modelViewMatrix", I.modelViewMatrix), it.setValue(w, "normalMatrix", I.normalMatrix), it.setValue(w, "modelMatrix", I.matrixWorld), H.isShaderMaterial || H.isRawShaderMaterial) {
|
|
19848
19848
|
const yt = H.uniformsGroups;
|
|
19849
|
-
for (let wt = 0,
|
|
19849
|
+
for (let wt = 0, Xs = yt.length; wt < Xs; wt++) {
|
|
19850
19850
|
const Un = yt[wt];
|
|
19851
19851
|
R.update(Un, kt), R.bind(Un, kt);
|
|
19852
19852
|
}
|
|
19853
19853
|
}
|
|
19854
19854
|
return kt;
|
|
19855
19855
|
}
|
|
19856
|
-
function
|
|
19857
|
-
x.ambientLightColor.needsUpdate =
|
|
19856
|
+
function kl(x, L) {
|
|
19857
|
+
x.ambientLightColor.needsUpdate = L, x.lightProbe.needsUpdate = L, x.directionalLights.needsUpdate = L, x.directionalLightShadows.needsUpdate = L, x.pointLights.needsUpdate = L, x.pointLightShadows.needsUpdate = L, x.spotLights.needsUpdate = L, x.spotLightShadows.needsUpdate = L, x.rectAreaLights.needsUpdate = L, x.hemisphereLights.needsUpdate = L;
|
|
19858
19858
|
}
|
|
19859
|
-
function
|
|
19859
|
+
function Vl(x) {
|
|
19860
19860
|
return x.isMeshLambertMaterial || x.isMeshToonMaterial || x.isMeshPhongMaterial || x.isMeshStandardMaterial || x.isShadowMaterial || x.isShaderMaterial && x.lights === !0;
|
|
19861
19861
|
}
|
|
19862
19862
|
this.getActiveCubeFace = function() {
|
|
@@ -19865,16 +19865,16 @@ class Cm {
|
|
|
19865
19865
|
return C;
|
|
19866
19866
|
}, this.getRenderTarget = function() {
|
|
19867
19867
|
return F;
|
|
19868
|
-
}, this.setRenderTargetTextures = function(x,
|
|
19868
|
+
}, this.setRenderTargetTextures = function(x, L, B) {
|
|
19869
19869
|
const H = we.get(x);
|
|
19870
|
-
H.__autoAllocateDepthBuffer = x.resolveDepthBuffer === !1, H.__autoAllocateDepthBuffer === !1 && (H.__useRenderToTexture = !1), we.get(x.texture).__webglTexture =
|
|
19871
|
-
}, this.setRenderTargetFramebuffer = function(x,
|
|
19870
|
+
H.__autoAllocateDepthBuffer = x.resolveDepthBuffer === !1, H.__autoAllocateDepthBuffer === !1 && (H.__useRenderToTexture = !1), we.get(x.texture).__webglTexture = L, we.get(x.depthTexture).__webglTexture = H.__autoAllocateDepthBuffer ? void 0 : B, H.__hasExternalTextures = !0;
|
|
19871
|
+
}, this.setRenderTargetFramebuffer = function(x, L) {
|
|
19872
19872
|
const B = we.get(x);
|
|
19873
|
-
B.__webglFramebuffer =
|
|
19873
|
+
B.__webglFramebuffer = L, B.__useDefaultFramebuffer = L === void 0;
|
|
19874
19874
|
};
|
|
19875
|
-
const
|
|
19876
|
-
this.setRenderTarget = function(x,
|
|
19877
|
-
F = x, A =
|
|
19875
|
+
const Gl = w.createFramebuffer();
|
|
19876
|
+
this.setRenderTarget = function(x, L = 0, B = 0) {
|
|
19877
|
+
F = x, A = L, C = B;
|
|
19878
19878
|
let H = !0, I = null, se = !1, fe = !1;
|
|
19879
19879
|
if (x) {
|
|
19880
19880
|
const ve = we.get(x);
|
|
@@ -19895,21 +19895,21 @@ class Cm {
|
|
|
19895
19895
|
const Ie = x.texture;
|
|
19896
19896
|
(Ie.isData3DTexture || Ie.isDataArrayTexture || Ie.isCompressedArrayTexture) && (fe = !0);
|
|
19897
19897
|
const Ne = we.get(x).__webglFramebuffer;
|
|
19898
|
-
x.isWebGLCubeRenderTarget ? (Array.isArray(Ne[
|
|
19898
|
+
x.isWebGLCubeRenderTarget ? (Array.isArray(Ne[L]) ? I = Ne[L][B] : I = Ne[L], se = !0) : x.samples > 0 && Fe.useMultisampledRTT(x) === !1 ? I = we.get(x).__webglMultisampledFramebuffer : Array.isArray(Ne) ? I = Ne[B] : I = Ne, P.copy(x.viewport), q.copy(x.scissor), k = x.scissorTest;
|
|
19899
19899
|
} else
|
|
19900
19900
|
P.copy(be).multiplyScalar(V).floor(), q.copy(Ve).multiplyScalar(V).floor(), k = Ze;
|
|
19901
|
-
if (B !== 0 && (I =
|
|
19901
|
+
if (B !== 0 && (I = Gl), Se.bindFramebuffer(w.FRAMEBUFFER, I) && H && Se.drawBuffers(x, I), Se.viewport(P), Se.scissor(q), Se.setScissorTest(k), se) {
|
|
19902
19902
|
const ve = we.get(x.texture);
|
|
19903
|
-
w.framebufferTexture2D(w.FRAMEBUFFER, w.COLOR_ATTACHMENT0, w.TEXTURE_CUBE_MAP_POSITIVE_X +
|
|
19903
|
+
w.framebufferTexture2D(w.FRAMEBUFFER, w.COLOR_ATTACHMENT0, w.TEXTURE_CUBE_MAP_POSITIVE_X + L, ve.__webglTexture, B);
|
|
19904
19904
|
} else if (fe) {
|
|
19905
|
-
const ve = we.get(x.texture), Ie =
|
|
19905
|
+
const ve = we.get(x.texture), Ie = L;
|
|
19906
19906
|
w.framebufferTextureLayer(w.FRAMEBUFFER, w.COLOR_ATTACHMENT0, ve.__webglTexture, B, Ie);
|
|
19907
19907
|
} else if (x !== null && B !== 0) {
|
|
19908
19908
|
const ve = we.get(x.texture);
|
|
19909
19909
|
w.framebufferTexture2D(w.FRAMEBUFFER, w.COLOR_ATTACHMENT0, w.TEXTURE_2D, ve.__webglTexture, B);
|
|
19910
19910
|
}
|
|
19911
19911
|
E = -1;
|
|
19912
|
-
}, this.readRenderTargetPixels = function(x,
|
|
19912
|
+
}, this.readRenderTargetPixels = function(x, L, B, H, I, se, fe, Me = 0) {
|
|
19913
19913
|
if (!(x && x.isWebGLRenderTarget)) {
|
|
19914
19914
|
console.error("THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not THREE.WebGLRenderTarget.");
|
|
19915
19915
|
return;
|
|
@@ -19927,18 +19927,18 @@ class Cm {
|
|
|
19927
19927
|
console.error("THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not in UnsignedByteType or implementation defined type.");
|
|
19928
19928
|
return;
|
|
19929
19929
|
}
|
|
19930
|
-
|
|
19930
|
+
L >= 0 && L <= x.width - H && B >= 0 && B <= x.height - I && (x.textures.length > 1 && w.readBuffer(w.COLOR_ATTACHMENT0 + Me), w.readPixels(L, B, H, I, X.convert(Ne), X.convert(Re), se));
|
|
19931
19931
|
} finally {
|
|
19932
19932
|
const Ie = F !== null ? we.get(F).__webglFramebuffer : null;
|
|
19933
19933
|
Se.bindFramebuffer(w.FRAMEBUFFER, Ie);
|
|
19934
19934
|
}
|
|
19935
19935
|
}
|
|
19936
|
-
}, this.readRenderTargetPixelsAsync = async function(x,
|
|
19936
|
+
}, this.readRenderTargetPixelsAsync = async function(x, L, B, H, I, se, fe, Me = 0) {
|
|
19937
19937
|
if (!(x && x.isWebGLRenderTarget))
|
|
19938
19938
|
throw new Error("THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not THREE.WebGLRenderTarget.");
|
|
19939
19939
|
let ve = we.get(x).__webglFramebuffer;
|
|
19940
19940
|
if (x.isWebGLCubeRenderTarget && fe !== void 0 && (ve = ve[fe]), ve)
|
|
19941
|
-
if (
|
|
19941
|
+
if (L >= 0 && L <= x.width - H && B >= 0 && B <= x.height - I) {
|
|
19942
19942
|
Se.bindFramebuffer(w.FRAMEBUFFER, ve);
|
|
19943
19943
|
const Ie = x.textures[Me], Ne = Ie.format, Re = Ie.type;
|
|
19944
19944
|
if (!Je.textureFormatReadable(Ne))
|
|
@@ -19946,19 +19946,19 @@ class Cm {
|
|
|
19946
19946
|
if (!Je.textureTypeReadable(Re))
|
|
19947
19947
|
throw new Error("THREE.WebGLRenderer.readRenderTargetPixelsAsync: renderTarget is not in UnsignedByteType or implementation defined type.");
|
|
19948
19948
|
const Ye = w.createBuffer();
|
|
19949
|
-
w.bindBuffer(w.PIXEL_PACK_BUFFER, Ye), w.bufferData(w.PIXEL_PACK_BUFFER, se.byteLength, w.STREAM_READ), x.textures.length > 1 && w.readBuffer(w.COLOR_ATTACHMENT0 + Me), w.readPixels(
|
|
19949
|
+
w.bindBuffer(w.PIXEL_PACK_BUFFER, Ye), w.bufferData(w.PIXEL_PACK_BUFFER, se.byteLength, w.STREAM_READ), x.textures.length > 1 && w.readBuffer(w.COLOR_ATTACHMENT0 + Me), w.readPixels(L, B, H, I, X.convert(Ne), X.convert(Re), 0);
|
|
19950
19950
|
const Qe = F !== null ? we.get(F).__webglFramebuffer : null;
|
|
19951
19951
|
Se.bindFramebuffer(w.FRAMEBUFFER, Qe);
|
|
19952
19952
|
const at = w.fenceSync(w.SYNC_GPU_COMMANDS_COMPLETE, 0);
|
|
19953
19953
|
return w.flush(), await nh(w, at, 4), w.bindBuffer(w.PIXEL_PACK_BUFFER, Ye), w.getBufferSubData(w.PIXEL_PACK_BUFFER, 0, se), w.deleteBuffer(Ye), w.deleteSync(at), se;
|
|
19954
19954
|
} else
|
|
19955
19955
|
throw new Error("THREE.WebGLRenderer.readRenderTargetPixelsAsync: requested read bounds are out of range.");
|
|
19956
|
-
}, this.copyFramebufferToTexture = function(x,
|
|
19957
|
-
const H = Math.pow(2, -B), I = Math.floor(x.image.width * H), se = Math.floor(x.image.height * H), fe =
|
|
19956
|
+
}, this.copyFramebufferToTexture = function(x, L = null, B = 0) {
|
|
19957
|
+
const H = Math.pow(2, -B), I = Math.floor(x.image.width * H), se = Math.floor(x.image.height * H), fe = L !== null ? L.x : 0, Me = L !== null ? L.y : 0;
|
|
19958
19958
|
Fe.setTexture2D(x, 0), w.copyTexSubImage2D(w.TEXTURE_2D, B, 0, 0, fe, Me, I, se), Se.unbindTexture();
|
|
19959
19959
|
};
|
|
19960
|
-
const
|
|
19961
|
-
this.copyTextureToTexture = function(x,
|
|
19960
|
+
const Wl = w.createFramebuffer(), Xl = w.createFramebuffer();
|
|
19961
|
+
this.copyTextureToTexture = function(x, L, B = null, H = null, I = 0, se = null) {
|
|
19962
19962
|
se === null && (I !== 0 ? (_i("WebGLRenderer: copyTextureToTexture function signature has changed to support src and dst mipmap levels."), se = I, I = 0) : se = 0);
|
|
19963
19963
|
let fe, Me, ve, Ie, Ne, Re, Ye, Qe, at;
|
|
19964
19964
|
const lt = x.isCompressedTexture ? x.mipmaps[se] : x.image;
|
|
@@ -19969,29 +19969,29 @@ class Cm {
|
|
|
19969
19969
|
fe = Math.floor(lt.width * Ft), Me = Math.floor(lt.height * Ft), x.isDataArrayTexture ? ve = lt.depth : x.isData3DTexture ? ve = Math.floor(lt.depth * Ft) : ve = 1, Ie = 0, Ne = 0, Re = 0;
|
|
19970
19970
|
}
|
|
19971
19971
|
H !== null ? (Ye = H.x, Qe = H.y, at = H.z) : (Ye = 0, Qe = 0, at = 0);
|
|
19972
|
-
const Ke = X.convert(
|
|
19972
|
+
const Ke = X.convert(L.format), Le = X.convert(L.type);
|
|
19973
19973
|
let vt;
|
|
19974
|
-
|
|
19974
|
+
L.isData3DTexture ? (Fe.setTexture3D(L, 0), vt = w.TEXTURE_3D) : L.isDataArrayTexture || L.isCompressedArrayTexture ? (Fe.setTexture2DArray(L, 0), vt = w.TEXTURE_2D_ARRAY) : (Fe.setTexture2D(L, 0), vt = w.TEXTURE_2D), w.pixelStorei(w.UNPACK_FLIP_Y_WEBGL, L.flipY), w.pixelStorei(w.UNPACK_PREMULTIPLY_ALPHA_WEBGL, L.premultiplyAlpha), w.pixelStorei(w.UNPACK_ALIGNMENT, L.unpackAlignment);
|
|
19975
19975
|
const $e = w.getParameter(w.UNPACK_ROW_LENGTH), kt = w.getParameter(w.UNPACK_IMAGE_HEIGHT), Zn = w.getParameter(w.UNPACK_SKIP_PIXELS), Dt = w.getParameter(w.UNPACK_SKIP_ROWS), Pi = w.getParameter(w.UNPACK_SKIP_IMAGES);
|
|
19976
19976
|
w.pixelStorei(w.UNPACK_ROW_LENGTH, lt.width), w.pixelStorei(w.UNPACK_IMAGE_HEIGHT, lt.height), w.pixelStorei(w.UNPACK_SKIP_PIXELS, Ie), w.pixelStorei(w.UNPACK_SKIP_ROWS, Ne), w.pixelStorei(w.UNPACK_SKIP_IMAGES, Re);
|
|
19977
|
-
const it = x.isDataArrayTexture || x.isData3DTexture, Nt =
|
|
19977
|
+
const it = x.isDataArrayTexture || x.isData3DTexture, Nt = L.isDataArrayTexture || L.isData3DTexture;
|
|
19978
19978
|
if (x.isDepthTexture) {
|
|
19979
|
-
const Ft = we.get(x), yt = we.get(
|
|
19980
|
-
Se.bindFramebuffer(w.READ_FRAMEBUFFER, wt.__webglFramebuffer), Se.bindFramebuffer(w.DRAW_FRAMEBUFFER,
|
|
19979
|
+
const Ft = we.get(x), yt = we.get(L), wt = we.get(Ft.__renderTarget), Xs = we.get(yt.__renderTarget);
|
|
19980
|
+
Se.bindFramebuffer(w.READ_FRAMEBUFFER, wt.__webglFramebuffer), Se.bindFramebuffer(w.DRAW_FRAMEBUFFER, Xs.__webglFramebuffer);
|
|
19981
19981
|
for (let Un = 0; Un < ve; Un++)
|
|
19982
|
-
it && (w.framebufferTextureLayer(w.READ_FRAMEBUFFER, w.COLOR_ATTACHMENT0, we.get(x).__webglTexture, I, Re + Un), w.framebufferTextureLayer(w.DRAW_FRAMEBUFFER, w.COLOR_ATTACHMENT0, we.get(
|
|
19982
|
+
it && (w.framebufferTextureLayer(w.READ_FRAMEBUFFER, w.COLOR_ATTACHMENT0, we.get(x).__webglTexture, I, Re + Un), w.framebufferTextureLayer(w.DRAW_FRAMEBUFFER, w.COLOR_ATTACHMENT0, we.get(L).__webglTexture, se, at + Un)), w.blitFramebuffer(Ie, Ne, fe, Me, Ye, Qe, fe, Me, w.DEPTH_BUFFER_BIT, w.NEAREST);
|
|
19983
19983
|
Se.bindFramebuffer(w.READ_FRAMEBUFFER, null), Se.bindFramebuffer(w.DRAW_FRAMEBUFFER, null);
|
|
19984
19984
|
} else if (I !== 0 || x.isRenderTargetTexture || we.has(x)) {
|
|
19985
|
-
const Ft = we.get(x), yt = we.get(
|
|
19986
|
-
Se.bindFramebuffer(w.READ_FRAMEBUFFER,
|
|
19985
|
+
const Ft = we.get(x), yt = we.get(L);
|
|
19986
|
+
Se.bindFramebuffer(w.READ_FRAMEBUFFER, Wl), Se.bindFramebuffer(w.DRAW_FRAMEBUFFER, Xl);
|
|
19987
19987
|
for (let wt = 0; wt < ve; wt++)
|
|
19988
19988
|
it ? w.framebufferTextureLayer(w.READ_FRAMEBUFFER, w.COLOR_ATTACHMENT0, Ft.__webglTexture, I, Re + wt) : w.framebufferTexture2D(w.READ_FRAMEBUFFER, w.COLOR_ATTACHMENT0, w.TEXTURE_2D, Ft.__webglTexture, I), Nt ? w.framebufferTextureLayer(w.DRAW_FRAMEBUFFER, w.COLOR_ATTACHMENT0, yt.__webglTexture, se, at + wt) : w.framebufferTexture2D(w.DRAW_FRAMEBUFFER, w.COLOR_ATTACHMENT0, w.TEXTURE_2D, yt.__webglTexture, se), I !== 0 ? w.blitFramebuffer(Ie, Ne, fe, Me, Ye, Qe, fe, Me, w.COLOR_BUFFER_BIT, w.NEAREST) : Nt ? w.copyTexSubImage3D(vt, se, Ye, Qe, at + wt, Ie, Ne, fe, Me) : w.copyTexSubImage2D(vt, se, Ye, Qe, Ie, Ne, fe, Me);
|
|
19989
19989
|
Se.bindFramebuffer(w.READ_FRAMEBUFFER, null), Se.bindFramebuffer(w.DRAW_FRAMEBUFFER, null);
|
|
19990
19990
|
} else
|
|
19991
|
-
Nt ? x.isDataTexture || x.isData3DTexture ? w.texSubImage3D(vt, se, Ye, Qe, at, fe, Me, ve, Ke, Le, lt.data) :
|
|
19992
|
-
w.pixelStorei(w.UNPACK_ROW_LENGTH, $e), w.pixelStorei(w.UNPACK_IMAGE_HEIGHT, kt), w.pixelStorei(w.UNPACK_SKIP_PIXELS, Zn), w.pixelStorei(w.UNPACK_SKIP_ROWS, Dt), w.pixelStorei(w.UNPACK_SKIP_IMAGES, Pi), se === 0 &&
|
|
19993
|
-
}, this.copyTextureToTexture3D = function(x,
|
|
19994
|
-
return _i('WebGLRenderer: copyTextureToTexture3D function has been deprecated. Use "copyTextureToTexture" instead.'), this.copyTextureToTexture(x,
|
|
19991
|
+
Nt ? x.isDataTexture || x.isData3DTexture ? w.texSubImage3D(vt, se, Ye, Qe, at, fe, Me, ve, Ke, Le, lt.data) : L.isCompressedArrayTexture ? w.compressedTexSubImage3D(vt, se, Ye, Qe, at, fe, Me, ve, Ke, lt.data) : w.texSubImage3D(vt, se, Ye, Qe, at, fe, Me, ve, Ke, Le, lt) : x.isDataTexture ? w.texSubImage2D(w.TEXTURE_2D, se, Ye, Qe, fe, Me, Ke, Le, lt.data) : x.isCompressedTexture ? w.compressedTexSubImage2D(w.TEXTURE_2D, se, Ye, Qe, lt.width, lt.height, Ke, lt.data) : w.texSubImage2D(w.TEXTURE_2D, se, Ye, Qe, fe, Me, Ke, Le, lt);
|
|
19992
|
+
w.pixelStorei(w.UNPACK_ROW_LENGTH, $e), w.pixelStorei(w.UNPACK_IMAGE_HEIGHT, kt), w.pixelStorei(w.UNPACK_SKIP_PIXELS, Zn), w.pixelStorei(w.UNPACK_SKIP_ROWS, Dt), w.pixelStorei(w.UNPACK_SKIP_IMAGES, Pi), se === 0 && L.generateMipmaps && w.generateMipmap(vt), Se.unbindTexture();
|
|
19993
|
+
}, this.copyTextureToTexture3D = function(x, L, B = null, H = null, I = 0) {
|
|
19994
|
+
return _i('WebGLRenderer: copyTextureToTexture3D function has been deprecated. Use "copyTextureToTexture" instead.'), this.copyTextureToTexture(x, L, B, H, I);
|
|
19995
19995
|
}, this.initRenderTarget = function(x) {
|
|
19996
19996
|
we.get(x).__webglFramebuffer === void 0 && Fe.setupRenderTarget(x);
|
|
19997
19997
|
}, this.initTexture = function(x) {
|
|
@@ -20207,7 +20207,7 @@ class Nm extends bi {
|
|
|
20207
20207
|
* @param {onErrorCallback} onError - Executed when errors occur.
|
|
20208
20208
|
*/
|
|
20209
20209
|
load(e, t, n, s) {
|
|
20210
|
-
const r = this, a = new
|
|
20210
|
+
const r = this, a = new wl(this.manager);
|
|
20211
20211
|
a.setPath(this.path), a.setRequestHeader(this.requestHeader), a.setWithCredentials(this.withCredentials), a.load(e, function(o) {
|
|
20212
20212
|
try {
|
|
20213
20213
|
t(r.parse(o));
|
|
@@ -20336,7 +20336,7 @@ class Nm extends bi {
|
|
|
20336
20336
|
}
|
|
20337
20337
|
}
|
|
20338
20338
|
t.finalize();
|
|
20339
|
-
const r = new
|
|
20339
|
+
const r = new Bi();
|
|
20340
20340
|
if (r.materialLibraries = [].concat(t.materialLibraries), !(t.objects.length === 1 && t.objects[0].geometry.vertices.length === 0) === !0)
|
|
20341
20341
|
for (let o = 0, l = t.objects.length; o < l; o++) {
|
|
20342
20342
|
const c = t.objects[o], h = c.geometry, u = c.materials, f = h.type === "Line", m = h.type === "Points";
|
|
@@ -20346,18 +20346,18 @@ class Nm extends bi {
|
|
|
20346
20346
|
v.setAttribute("position", new bt(h.vertices, 3)), h.normals.length > 0 && v.setAttribute("normal", new bt(h.normals, 3)), h.colors.length > 0 && (_ = !0, v.setAttribute("color", new bt(h.colors, 3))), h.hasUVIndices === !0 && v.setAttribute("uv", new bt(h.uvs, 2));
|
|
20347
20347
|
const p = [];
|
|
20348
20348
|
for (let b = 0, T = u.length; b < T; b++) {
|
|
20349
|
-
const S = u[b],
|
|
20350
|
-
let A = t.materials[
|
|
20349
|
+
const S = u[b], D = S.name + "_" + S.smooth + "_" + _;
|
|
20350
|
+
let A = t.materials[D];
|
|
20351
20351
|
if (this.materials !== null) {
|
|
20352
|
-
if (A = this.materials.create(S.name), f && A && !(A instanceof
|
|
20353
|
-
const C = new
|
|
20352
|
+
if (A = this.materials.create(S.name), f && A && !(A instanceof Ls)) {
|
|
20353
|
+
const C = new Ls();
|
|
20354
20354
|
xn.prototype.copy.call(C, A), C.color.copy(A.color), A = C;
|
|
20355
|
-
} else if (m && A && !(A instanceof
|
|
20356
|
-
const C = new
|
|
20355
|
+
} else if (m && A && !(A instanceof zi)) {
|
|
20356
|
+
const C = new zi({ size: 10, sizeAttenuation: !1 });
|
|
20357
20357
|
xn.prototype.copy.call(C, A), C.color.copy(A.color), C.map = A.map, A = C;
|
|
20358
20358
|
}
|
|
20359
20359
|
}
|
|
20360
|
-
A === void 0 && (f ? A = new
|
|
20360
|
+
A === void 0 && (f ? A = new Ls() : m ? A = new zi({ size: 1, sizeAttenuation: !1 }) : A = new bl(), A.name = S.name, A.flatShading = !S.smooth, A.vertexColors = _, t.materials[D] = A), p.push(A);
|
|
20361
20361
|
}
|
|
20362
20362
|
let d;
|
|
20363
20363
|
if (p.length > 1) {
|
|
@@ -20371,7 +20371,7 @@ class Nm extends bi {
|
|
|
20371
20371
|
d.name = c.name, r.add(d);
|
|
20372
20372
|
}
|
|
20373
20373
|
else if (t.vertices.length > 0) {
|
|
20374
|
-
const o = new
|
|
20374
|
+
const o = new zi({ size: 1, sizeAttenuation: !1 }), l = new Zt();
|
|
20375
20375
|
l.setAttribute("position", new bt(t.vertices, 3)), t.colors.length > 0 && t.colors[0] !== void 0 && (l.setAttribute("color", new bt(t.colors, 3)), o.vertexColors = !0);
|
|
20376
20376
|
const c = new vr(l, o);
|
|
20377
20377
|
r.add(c);
|
|
@@ -20393,7 +20393,7 @@ class Fm extends bi {
|
|
|
20393
20393
|
* @param {onErrorCallback} onError - Executed when errors occur.
|
|
20394
20394
|
*/
|
|
20395
20395
|
load(e, t, n, s) {
|
|
20396
|
-
const r = this, a = this.path === "" ? Gh.extractUrlBase(e) : this.path, o = new
|
|
20396
|
+
const r = this, a = this.path === "" ? Gh.extractUrlBase(e) : this.path, o = new wl(this.manager);
|
|
20397
20397
|
o.setPath(this.path), o.setRequestHeader(this.requestHeader), o.setWithCredentials(this.withCredentials), o.load(e, function(l) {
|
|
20398
20398
|
try {
|
|
20399
20399
|
t(r.parse(l, a));
|
|
@@ -20445,7 +20445,7 @@ class Fm extends bi {
|
|
|
20445
20445
|
}
|
|
20446
20446
|
class Om {
|
|
20447
20447
|
constructor(e = "", t = {}) {
|
|
20448
|
-
this.baseUrl = e, this.options = t, this.materialsInfo = {}, this.materials = {}, this.materialsArray = [], this.nameLookup = {}, this.crossOrigin = "anonymous", this.side = this.options.side !== void 0 ? this.options.side : vn, this.wrap = this.options.wrap !== void 0 ? this.options.wrap :
|
|
20448
|
+
this.baseUrl = e, this.options = t, this.materialsInfo = {}, this.materials = {}, this.materialsArray = [], this.nameLookup = {}, this.crossOrigin = "anonymous", this.side = this.options.side !== void 0 ? this.options.side : vn, this.wrap = this.options.wrap !== void 0 ? this.options.wrap : Ns;
|
|
20449
20449
|
}
|
|
20450
20450
|
setCrossOrigin(e) {
|
|
20451
20451
|
return this.crossOrigin = e, this;
|
|
@@ -20554,7 +20554,7 @@ class Om {
|
|
|
20554
20554
|
break;
|
|
20555
20555
|
}
|
|
20556
20556
|
}
|
|
20557
|
-
return this.materials[e] = new
|
|
20557
|
+
return this.materials[e] = new bl(s), this.materials[e];
|
|
20558
20558
|
}
|
|
20559
20559
|
getTextureParams(e, t) {
|
|
20560
20560
|
const n = {
|
|
@@ -20565,14 +20565,14 @@ class Om {
|
|
|
20565
20565
|
return r = s.indexOf("-bm"), r >= 0 && (t.bumpScale = parseFloat(s[r + 1]), s.splice(r, 2)), r = s.indexOf("-mm"), r >= 0 && (t.displacementBias = parseFloat(s[r + 1]), t.displacementScale = parseFloat(s[r + 2]), s.splice(r, 3)), r = s.indexOf("-s"), r >= 0 && (n.scale.set(parseFloat(s[r + 1]), parseFloat(s[r + 2])), s.splice(r, 4)), r = s.indexOf("-o"), r >= 0 && (n.offset.set(parseFloat(s[r + 1]), parseFloat(s[r + 2])), s.splice(r, 4)), n.url = s.join(" ").trim(), n;
|
|
20566
20566
|
}
|
|
20567
20567
|
loadTexture(e, t, n, s, r) {
|
|
20568
|
-
const a = this.manager !== void 0 ? this.manager :
|
|
20568
|
+
const a = this.manager !== void 0 ? this.manager : Al;
|
|
20569
20569
|
let o = a.getHandler(e);
|
|
20570
20570
|
o === null && (o = new Bh(a)), o.setCrossOrigin && o.setCrossOrigin(this.crossOrigin);
|
|
20571
20571
|
const l = o.load(e, n, s, r);
|
|
20572
20572
|
return t !== void 0 && (l.mapping = t), l;
|
|
20573
20573
|
}
|
|
20574
20574
|
}
|
|
20575
|
-
const Xo = { type: "change" }, Ca = { type: "start" },
|
|
20575
|
+
const Xo = { type: "change" }, Ca = { type: "start" }, Nl = { type: "end" }, ys = new Vs(), qo = new wn(), Bm = Math.cos(70 * eh.DEG2RAD), ft = new N(), Ct = 2 * Math.PI, tt = {
|
|
20576
20576
|
NONE: -1,
|
|
20577
20577
|
ROTATE: 0,
|
|
20578
20578
|
DOLLY: 1,
|
|
@@ -20887,7 +20887,7 @@ function km(i) {
|
|
|
20887
20887
|
function Vm(i) {
|
|
20888
20888
|
switch (this._removePointer(i), this._pointers.length) {
|
|
20889
20889
|
case 0:
|
|
20890
|
-
this.domElement.releasePointerCapture(i.pointerId), this.domElement.removeEventListener("pointermove", this._onPointerMove), this.domElement.removeEventListener("pointerup", this._onPointerUp), this.dispatchEvent(
|
|
20890
|
+
this.domElement.releasePointerCapture(i.pointerId), this.domElement.removeEventListener("pointermove", this._onPointerMove), this.domElement.removeEventListener("pointerup", this._onPointerUp), this.dispatchEvent(Nl), this.state = tt.NONE;
|
|
20891
20891
|
break;
|
|
20892
20892
|
case 1:
|
|
20893
20893
|
const e = this._pointers[0], t = this._pointerPositions[e];
|
|
@@ -20955,7 +20955,7 @@ function Wm(i) {
|
|
|
20955
20955
|
}
|
|
20956
20956
|
}
|
|
20957
20957
|
function Xm(i) {
|
|
20958
|
-
this.enabled === !1 || this.enableZoom === !1 || this.state !== tt.NONE || (i.preventDefault(), this.dispatchEvent(Ca), this._handleMouseWheel(this._customWheelEvent(i)), this.dispatchEvent(
|
|
20958
|
+
this.enabled === !1 || this.enableZoom === !1 || this.state !== tt.NONE || (i.preventDefault(), this.dispatchEvent(Ca), this._handleMouseWheel(this._customWheelEvent(i)), this.dispatchEvent(Nl));
|
|
20959
20959
|
}
|
|
20960
20960
|
function qm(i) {
|
|
20961
20961
|
this.enabled !== !1 && this._handleKeyDown(i);
|
|
@@ -21032,69 +21032,69 @@ const Jm = { class: "content-show" }, Qm = {
|
|
|
21032
21032
|
isShow: Boolean
|
|
21033
21033
|
},
|
|
21034
21034
|
setup(i) {
|
|
21035
|
-
const e = nt(null), t = i;
|
|
21036
|
-
let
|
|
21037
|
-
const
|
|
21038
|
-
|
|
21035
|
+
const e = nt(null), t = i, n = Jo(bs), { nodeDev: s } = Oi(n);
|
|
21036
|
+
let r, a, o, l, c;
|
|
21037
|
+
const h = () => {
|
|
21038
|
+
r = new Ch(), r.background = new Ge(15790320), a = new zt(
|
|
21039
21039
|
75,
|
|
21040
21040
|
e.value.clientWidth / e.value.clientHeight,
|
|
21041
21041
|
0.1,
|
|
21042
21042
|
1e3
|
|
21043
|
-
),
|
|
21044
|
-
const
|
|
21045
|
-
|
|
21046
|
-
const
|
|
21047
|
-
|
|
21048
|
-
},
|
|
21043
|
+
), a.position.z = 5, o = new Cm({ antialias: !0 }), o.setSize(e.value.clientWidth, e.value.clientHeight), o.setPixelRatio(window.devicePixelRatio), e.value.appendChild(o.domElement), l = new zm(a, o.domElement), l.enableDamping = !0, l.dampingFactor = 0.05;
|
|
21044
|
+
const _ = new Vh(16777215, 0.5);
|
|
21045
|
+
r.add(_);
|
|
21046
|
+
const v = new kh(16777215, 0.8);
|
|
21047
|
+
v.position.set(1, 1, 1), r.add(v), u("model"), f();
|
|
21048
|
+
}, u = (_) => {
|
|
21049
21049
|
new Fm().load(
|
|
21050
21050
|
// new URL('/obj/' + modelContent + '.mtl', import.meta.url).href,
|
|
21051
|
-
"
|
|
21051
|
+
s.value === "" ? "/obj/" + _ + ".mtl" : "/" + s.value + "/obj/" + _ + ".mtl",
|
|
21052
21052
|
// 替换为你的MTL文件路径
|
|
21053
|
-
(
|
|
21054
|
-
|
|
21055
|
-
const
|
|
21056
|
-
|
|
21053
|
+
(p) => {
|
|
21054
|
+
p.preload();
|
|
21055
|
+
const d = new Nm();
|
|
21056
|
+
d.setMaterials(p), d.load(
|
|
21057
21057
|
// new URL('/obj/' + modelContent + '.obj', import.meta.url).href,
|
|
21058
|
-
"
|
|
21058
|
+
s.value === "" ? "/obj/" + _ + ".obj" : "/" + s.value + "/obj/" + _ + ".obj",
|
|
21059
21059
|
// 替换为你的OBJ文件路径
|
|
21060
|
-
(
|
|
21061
|
-
|
|
21062
|
-
const
|
|
21063
|
-
|
|
21060
|
+
(b) => {
|
|
21061
|
+
c = b, c.rotation.set(50, -20, 200), r.add(c);
|
|
21062
|
+
const T = new Ti().setFromObject(c), S = T.getSize(new N()).length(), D = T.getCenter(new N());
|
|
21063
|
+
a.position.copy(D), a.position.z += S * 0.6, a.lookAt(D), l.target.copy(D);
|
|
21064
21064
|
},
|
|
21065
|
-
(
|
|
21066
|
-
console.log(
|
|
21065
|
+
(b) => {
|
|
21066
|
+
console.log(b.loaded / b.total * 100 + "% loaded");
|
|
21067
21067
|
},
|
|
21068
|
-
(
|
|
21069
|
-
console.error("An error happened loading the OBJ model:",
|
|
21068
|
+
(b) => {
|
|
21069
|
+
console.error("An error happened loading the OBJ model:", b);
|
|
21070
21070
|
}
|
|
21071
21071
|
);
|
|
21072
21072
|
},
|
|
21073
|
-
(
|
|
21074
|
-
console.log(
|
|
21073
|
+
(p) => {
|
|
21074
|
+
console.log(p.loaded / p.total * 100 + "% loaded");
|
|
21075
21075
|
},
|
|
21076
|
-
(
|
|
21077
|
-
console.error("An error happened loading the MTL materials:",
|
|
21076
|
+
(p) => {
|
|
21077
|
+
console.error("An error happened loading the MTL materials:", p);
|
|
21078
21078
|
}
|
|
21079
21079
|
);
|
|
21080
|
-
},
|
|
21081
|
-
requestAnimationFrame(
|
|
21082
|
-
},
|
|
21083
|
-
|
|
21080
|
+
}, f = () => {
|
|
21081
|
+
requestAnimationFrame(f), l.update(), o.render(r, a);
|
|
21082
|
+
}, m = () => {
|
|
21083
|
+
a.aspect = e.value.clientWidth / e.value.clientHeight, a.updateProjectionMatrix(), o.setSize(e.value.clientWidth, e.value.clientHeight);
|
|
21084
21084
|
};
|
|
21085
21085
|
return _a(() => {
|
|
21086
|
-
window.addEventListener("resize",
|
|
21086
|
+
window.addEventListener("resize", m), h();
|
|
21087
21087
|
}), vi(
|
|
21088
21088
|
() => t == null ? void 0 : t.isShow,
|
|
21089
21089
|
() => {
|
|
21090
|
-
t != null && t.isShow && !
|
|
21091
|
-
window.addEventListener("resize",
|
|
21090
|
+
t != null && t.isShow && !l && !o && setTimeout(() => {
|
|
21091
|
+
window.addEventListener("resize", m), h();
|
|
21092
21092
|
}, 100);
|
|
21093
21093
|
},
|
|
21094
21094
|
{ deep: !0, immediate: !0 }
|
|
21095
|
-
),
|
|
21096
|
-
window.removeEventListener("resize",
|
|
21097
|
-
}), (
|
|
21095
|
+
), jl(() => {
|
|
21096
|
+
window.removeEventListener("resize", m), o && o.dispose(), l && l.dispose();
|
|
21097
|
+
}), (_, v) => (Ht(), pn("div", Jm, [
|
|
21098
21098
|
qt("div", {
|
|
21099
21099
|
ref_key: "container",
|
|
21100
21100
|
ref: e,
|
|
@@ -21102,7 +21102,7 @@ const Jm = { class: "content-show" }, Qm = {
|
|
|
21102
21102
|
}, null, 512)
|
|
21103
21103
|
]));
|
|
21104
21104
|
}
|
|
21105
|
-
}, e_ = /* @__PURE__ */ ga(Qm, [["__scopeId", "data-v-
|
|
21105
|
+
}, e_ = /* @__PURE__ */ ga(Qm, [["__scopeId", "data-v-cfe06b46"]]), t_ = Jl("unit", {
|
|
21106
21106
|
state: () => ({
|
|
21107
21107
|
selectIndex: "",
|
|
21108
21108
|
selectMenu: "",
|
|
@@ -21119,25 +21119,25 @@ const Jm = { class: "content-show" }, Qm = {
|
|
|
21119
21119
|
this.selectTitle = i;
|
|
21120
21120
|
}
|
|
21121
21121
|
}
|
|
21122
|
-
}),
|
|
21122
|
+
}), Fl = (i, e) => {
|
|
21123
21123
|
let t = i, n = e;
|
|
21124
21124
|
return Array.isArray(t) && (t = t == null ? void 0 : t.map((s, r) => {
|
|
21125
21125
|
if (Array.isArray(s)) {
|
|
21126
21126
|
let a = {};
|
|
21127
21127
|
return s = s == null ? void 0 : s.forEach((o, l) => {
|
|
21128
21128
|
var c;
|
|
21129
|
-
(c = n == null ? void 0 : n[l]) != null && c.prop ? a[n[l].prop] = o : Array.isArray(o) && (a.children =
|
|
21129
|
+
(c = n == null ? void 0 : n[l]) != null && c.prop ? a[n[l].prop] = o : Array.isArray(o) && (a.children = Fl(o, n));
|
|
21130
21130
|
}), Object.assign(a, { id: r });
|
|
21131
21131
|
} else
|
|
21132
21132
|
return s;
|
|
21133
21133
|
})), t;
|
|
21134
|
-
},
|
|
21134
|
+
}, Ol = (i, e, t) => {
|
|
21135
21135
|
let n = i, s = e;
|
|
21136
21136
|
return n = n == null ? void 0 : n.map((r, a) => {
|
|
21137
21137
|
var o, l;
|
|
21138
21138
|
return !Array.isArray(r) || !((o = s == null ? void 0 : s[a]) != null && o.label) && !t || (r.unshift(((l = s == null ? void 0 : s[a]) == null ? void 0 : l.label) ?? ""), r.some((c) => Array.isArray(c)) && (r = r == null ? void 0 : r.map((c) => {
|
|
21139
21139
|
var h;
|
|
21140
|
-
return Array.isArray(c) && (c =
|
|
21140
|
+
return Array.isArray(c) && (c = Ol(c, (h = s == null ? void 0 : s[a]) == null ? void 0 : h.children, t)), c;
|
|
21141
21141
|
}))), r;
|
|
21142
21142
|
}), n;
|
|
21143
21143
|
}, n_ = (i, e, t) => {
|
|
@@ -21149,11 +21149,11 @@ const Jm = { class: "content-show" }, Qm = {
|
|
|
21149
21149
|
}
|
|
21150
21150
|
}, i_ = (i, e, t) => {
|
|
21151
21151
|
let n = i, s = e;
|
|
21152
|
-
return (s == null ? void 0 : s.length) === 0 ? n = n == null ? void 0 : n.filter((r) => r.id !== t) : n = n == null ? void 0 : n.map((r) => (r.id.toString() === (s == null ? void 0 : s[0]) && (s == null || s.shift(), r =
|
|
21153
|
-
},
|
|
21152
|
+
return (s == null ? void 0 : s.length) === 0 ? n = n == null ? void 0 : n.filter((r) => r.id !== t) : n = n == null ? void 0 : n.map((r) => (r.id.toString() === (s == null ? void 0 : s[0]) && (s == null || s.shift(), r = Bl(r, s, t)), r)), n;
|
|
21153
|
+
}, Bl = (i, e, t) => {
|
|
21154
21154
|
var r, a;
|
|
21155
21155
|
let n = i, s = e;
|
|
21156
|
-
return (s == null ? void 0 : s.length) === 0 ? n.children = (r = n.children) == null ? void 0 : r.filter((o) => o.id !== t) : n.children = (a = n.children) == null ? void 0 : a.map((o) => (o.id.toString() === (s == null ? void 0 : s[0]) && (s == null || s.shift(), o =
|
|
21156
|
+
return (s == null ? void 0 : s.length) === 0 ? n.children = (r = n.children) == null ? void 0 : r.filter((o) => o.id !== t) : n.children = (a = n.children) == null ? void 0 : a.map((o) => (o.id.toString() === (s == null ? void 0 : s[0]) && (s == null || s.shift(), o = Bl(o, s, t)), o)), n;
|
|
21157
21157
|
}, s_ = (i, e, t) => {
|
|
21158
21158
|
if (e === "")
|
|
21159
21159
|
return t;
|
|
@@ -21163,11 +21163,11 @@ const Jm = { class: "content-show" }, Qm = {
|
|
|
21163
21163
|
}
|
|
21164
21164
|
}, r_ = (i, e, t) => {
|
|
21165
21165
|
let n = i, s = e;
|
|
21166
|
-
return (s == null ? void 0 : s.length) === 0 ? n = t : n = n == null ? void 0 : n.map((r) => (r.id.toString() === (s == null ? void 0 : s[0]) && (s == null || s.shift(), r =
|
|
21167
|
-
},
|
|
21166
|
+
return (s == null ? void 0 : s.length) === 0 ? n = t : n = n == null ? void 0 : n.map((r) => (r.id.toString() === (s == null ? void 0 : s[0]) && (s == null || s.shift(), r = zl(r, s, t)), r)), n;
|
|
21167
|
+
}, zl = (i, e, t) => {
|
|
21168
21168
|
var r;
|
|
21169
21169
|
let n = i, s = e;
|
|
21170
|
-
return (s == null ? void 0 : s.length) === 0 ? n.children = t : n.children = (r = n.children) == null ? void 0 : r.map((a) => (a.id.toString() === (s == null ? void 0 : s[0]) && (s == null || s.shift(), a =
|
|
21170
|
+
return (s == null ? void 0 : s.length) === 0 ? n.children = t : n.children = (r = n.children) == null ? void 0 : r.map((a) => (a.id.toString() === (s == null ? void 0 : s[0]) && (s == null || s.shift(), a = zl(a, s, t)), a)), n;
|
|
21171
21171
|
}, a_ = async (i, e, t = "") => {
|
|
21172
21172
|
var h, u, f, m, _, v;
|
|
21173
21173
|
const n = await qs({
|
|
@@ -21190,13 +21190,13 @@ const Jm = { class: "content-show" }, Qm = {
|
|
|
21190
21190
|
}
|
|
21191
21191
|
})), o = await Promise.all(a), l = [];
|
|
21192
21192
|
o == null || o.forEach((p) => {
|
|
21193
|
-
var T, S,
|
|
21193
|
+
var T, S, D, A;
|
|
21194
21194
|
const d = (T = p.data.result) == null ? void 0 : T.map((C) => {
|
|
21195
21195
|
const F = C.value.tableData;
|
|
21196
21196
|
return F.unshift({
|
|
21197
21197
|
id: C.id
|
|
21198
21198
|
}), F;
|
|
21199
|
-
}), b = (A = (
|
|
21199
|
+
}), b = (A = (D = (S = p.data.result) == null ? void 0 : S[0]) == null ? void 0 : D.key) == null ? void 0 : A.tableId;
|
|
21200
21200
|
l.push({
|
|
21201
21201
|
key: b,
|
|
21202
21202
|
contents: d
|
|
@@ -21208,16 +21208,16 @@ const Jm = { class: "content-show" }, Qm = {
|
|
|
21208
21208
|
const d = p.value.pageData, b = ut(d.compData);
|
|
21209
21209
|
if (b.push({
|
|
21210
21210
|
key: "tableContents",
|
|
21211
|
-
contents: (T = l == null ? void 0 : l.find((
|
|
21211
|
+
contents: (T = l == null ? void 0 : l.find((D) => (D == null ? void 0 : D.key) === p.id)) == null ? void 0 : T.contents
|
|
21212
21212
|
}), d.compData = b, d.id = p.id, ((S = p.key) == null ? void 0 : S.type) !== "method")
|
|
21213
21213
|
c.push(d);
|
|
21214
21214
|
else {
|
|
21215
|
-
let
|
|
21216
|
-
|
|
21215
|
+
let D;
|
|
21216
|
+
D = {
|
|
21217
21217
|
name: "",
|
|
21218
21218
|
compData: [d],
|
|
21219
21219
|
comp: "calculator"
|
|
21220
|
-
}, c.push(
|
|
21220
|
+
}, c.push(D);
|
|
21221
21221
|
}
|
|
21222
21222
|
}), ((m = (f = s.data.result) == null ? void 0 : f.map((p) => p.value.pageData)) == null ? void 0 : m.filter((p) => Object.values(p).length > 0).length) > 0 && c.push({
|
|
21223
21223
|
comp: "methodButton",
|
|
@@ -21241,7 +21241,7 @@ const Jm = { class: "content-show" }, Qm = {
|
|
|
21241
21241
|
}
|
|
21242
21242
|
});
|
|
21243
21243
|
}, T_ = async (i, e, t, n, s, r) => {
|
|
21244
|
-
await
|
|
21244
|
+
await el({
|
|
21245
21245
|
key: {
|
|
21246
21246
|
type: i,
|
|
21247
21247
|
pageKey: e,
|
|
@@ -21254,7 +21254,7 @@ const Jm = { class: "content-show" }, Qm = {
|
|
|
21254
21254
|
id: n
|
|
21255
21255
|
});
|
|
21256
21256
|
}, b_ = async (i, e) => {
|
|
21257
|
-
await
|
|
21257
|
+
await el({
|
|
21258
21258
|
value: {
|
|
21259
21259
|
pageData: e
|
|
21260
21260
|
},
|
|
@@ -21283,11 +21283,11 @@ const Jm = { class: "content-show" }, Qm = {
|
|
|
21283
21283
|
},
|
|
21284
21284
|
emits: ["change", "contentChange", "onButtonClick", "contentClick", "pageChange"],
|
|
21285
21285
|
setup(i, { emit: e }) {
|
|
21286
|
-
const t = i, n = e, s = nt([]), r =
|
|
21286
|
+
const t = i, n = e, s = nt([]), r = Ql(), { activeMenuPath: a } = Oi(r), o = Jo(bs), { extraContents: l } = Oi(o), c = nt([]), h = nt(!1), u = nt("");
|
|
21287
21287
|
nt();
|
|
21288
21288
|
const f = nt(!0), m = nt(0), _ = nt(!1), v = nt(""), p = nt(!1), d = nt({
|
|
21289
21289
|
label: "查看三维模型"
|
|
21290
|
-
}), b = nt([]), T = nt(!1), S = nt([]),
|
|
21290
|
+
}), b = nt([]), T = nt(!1), S = nt([]), D = nt([]), A = nt(), C = nt(), F = ec(bs), E = nt(), M = t_(bs), { selectIndex: P, selectMenu: q, selectTitle: k } = Oi(M), { selectString: j } = Oi(F), te = nt(720), K = () => {
|
|
21291
21291
|
p.value = !1;
|
|
21292
21292
|
}, re = (G, Y) => {
|
|
21293
21293
|
if (Object.values(Y).length !== 0)
|
|
@@ -21357,7 +21357,7 @@ const Jm = { class: "content-show" }, Qm = {
|
|
|
21357
21357
|
let ne = [];
|
|
21358
21358
|
for (let le in G)
|
|
21359
21359
|
Array.isArray(G == null ? void 0 : G[le]) && ne.push(le);
|
|
21360
|
-
(ie =
|
|
21360
|
+
(ie = tl((pe = ut(s.value)) == null ? void 0 : pe.filter((le) => (le == null ? void 0 : le.label) !== "操作"))) == null || ie.forEach((le, Ae) => {
|
|
21361
21361
|
ne.find((Ue) => Ue === (le == null ? void 0 : le.prop)) || Y.push({
|
|
21362
21362
|
label: (le == null ? void 0 : le.label) ?? "",
|
|
21363
21363
|
name: (le == null ? void 0 : le.prop) ?? "t" + Ae,
|
|
@@ -21368,7 +21368,7 @@ const Jm = { class: "content-show" }, Qm = {
|
|
|
21368
21368
|
width: 1,
|
|
21369
21369
|
isFormColHidden: le == null ? void 0 : le.isFormColHidden
|
|
21370
21370
|
});
|
|
21371
|
-
}), G === "" || !G || (u.value = G == null ? void 0 : G.id),
|
|
21371
|
+
}), G === "" || !G || (u.value = G == null ? void 0 : G.id), D.value = Y;
|
|
21372
21372
|
};
|
|
21373
21373
|
_a(() => {
|
|
21374
21374
|
});
|
|
@@ -21442,7 +21442,7 @@ const Jm = { class: "content-show" }, Qm = {
|
|
|
21442
21442
|
return z;
|
|
21443
21443
|
}));
|
|
21444
21444
|
const ee = !!((Q = s.value) != null && Q.find((z) => z.prop === "index"));
|
|
21445
|
-
oe =
|
|
21445
|
+
oe = Ol(ut(oe), Ue == null ? void 0 : Ue.contents, ee);
|
|
21446
21446
|
const _e = [];
|
|
21447
21447
|
oe == null || oe.forEach((z, U) => {
|
|
21448
21448
|
var De;
|
|
@@ -21460,7 +21460,7 @@ const Jm = { class: "content-show" }, Qm = {
|
|
|
21460
21460
|
var Mn;
|
|
21461
21461
|
return ((Mn = Object.keys(Mt)) == null ? void 0 : Mn[0]) === Te[ht].column;
|
|
21462
21462
|
})) == null ? void 0 : Kn[Te[ht].column] : He : he[Te[ht].prop] = He;
|
|
21463
|
-
} else Array.isArray(He) && (He.find((Jt) => (Jt == null ? void 0 : Jt.key) === "tableContentName") && ((Ci = Te[ht]) != null && Ci.prop) ? he[Te[ht].prop] = He : he.children =
|
|
21463
|
+
} else Array.isArray(He) && (He.find((Jt) => (Jt == null ? void 0 : Jt.key) === "tableContentName") && ((Ci = Te[ht]) != null && Ci.prop) ? he[Te[ht].prop] = He : he.children = Fl(He, Te));
|
|
21464
21464
|
});
|
|
21465
21465
|
} else
|
|
21466
21466
|
he = z;
|
|
@@ -21485,7 +21485,7 @@ const Jm = { class: "content-show" }, Qm = {
|
|
|
21485
21485
|
extraButton: S.value,
|
|
21486
21486
|
onButtonClick: Y[1] || (Y[1] = (pe) => be(pe, "")),
|
|
21487
21487
|
onContentClick: ge
|
|
21488
|
-
},
|
|
21488
|
+
}, Kl({
|
|
21489
21489
|
headerButton: en((pe) => [
|
|
21490
21490
|
Rn(uc, {
|
|
21491
21491
|
buttons: pe.buttons,
|
|
@@ -21517,8 +21517,8 @@ const Jm = { class: "content-show" }, Qm = {
|
|
|
21517
21517
|
}, {
|
|
21518
21518
|
default: en(() => [
|
|
21519
21519
|
qt("div", c_, [
|
|
21520
|
-
Rn(
|
|
21521
|
-
rowContents:
|
|
21520
|
+
Rn(Qo, {
|
|
21521
|
+
rowContents: D.value,
|
|
21522
21522
|
isEnableWrap: !1,
|
|
21523
21523
|
onChange: ae,
|
|
21524
21524
|
isEdit: f.value
|