vis-core 0.18.15 → 0.18.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +25 -25
- package/dist/index.module.js +671 -633
- package/dist/version.d.ts +1 -1
- package/dist/vis/map/index.d.ts +2 -0
- package/package.json +1 -1
package/dist/index.module.js
CHANGED
|
@@ -4,7 +4,7 @@ var kf = Object.getOwnPropertyDescriptors;
|
|
|
4
4
|
var yb = Object.getOwnPropertySymbols, zf = Object.getPrototypeOf, Uf = Object.prototype.hasOwnProperty, Bf = Object.prototype.propertyIsEnumerable, Pf = Reflect.get;
|
|
5
5
|
var no = (i, t) => (t = Symbol[i]) ? t : Symbol.for("Symbol." + i), Ef = (i) => {
|
|
6
6
|
throw TypeError(i);
|
|
7
|
-
},
|
|
7
|
+
}, Ys = Math.pow, Gm = (i, t, e) => t in i ? wf(i, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : i[t] = e, Tt = (i, t) => {
|
|
8
8
|
for (var e in t || (t = {}))
|
|
9
9
|
Uf.call(t, e) && Gm(i, e, t[e]);
|
|
10
10
|
if (yb)
|
|
@@ -13,8 +13,8 @@ var no = (i, t) => (t = Symbol[i]) ? t : Symbol.for("Symbol." + i), Ef = (i) =>
|
|
|
13
13
|
return i;
|
|
14
14
|
}, Be = (i, t) => Kf(i, kf(t));
|
|
15
15
|
var A = (i, t, e) => Gm(i, typeof t != "symbol" ? t + "" : t, e);
|
|
16
|
-
var
|
|
17
|
-
var
|
|
16
|
+
var Is = (i, t, e) => Pf(zf(i), e, t);
|
|
17
|
+
var ht = (i, t, e) => new Promise((n, s) => {
|
|
18
18
|
var l = (c) => {
|
|
19
19
|
try {
|
|
20
20
|
o(e.next(c));
|
|
@@ -92,7 +92,7 @@ const oR = "LS0tLS1CRUdJTiBQVUJMSUMgS0VZLS0tLS0KTUlJQklqQU5CZ2txaGtpRzl3MEJBUUVG
|
|
|
92
92
|
* Copyright 2010-2024 Three.js Authors
|
|
93
93
|
* SPDX-License-Identifier: MIT
|
|
94
94
|
*/
|
|
95
|
-
const Ba = "166", cR = { LEFT: 0, MIDDLE: 1, RIGHT: 2, ROTATE: 0, DOLLY: 1, PAN: 2 }, dR = { ROTATE: 0, PAN: 1, DOLLY_PAN: 2, DOLLY_ROTATE: 3 }, wX = 0, ip = 1, KX = 2, rR = 3, hR = 0, C2 = 1, kX = 2, di = 3, $n = 0, y0 = 1, He = 2, M0 = 0, Fi = 1, qo = 2, sp = 3, lp = 4, zX = 5,
|
|
95
|
+
const Ba = "166", cR = { LEFT: 0, MIDDLE: 1, RIGHT: 2, ROTATE: 0, DOLLY: 1, PAN: 2 }, dR = { ROTATE: 0, PAN: 1, DOLLY_PAN: 2, DOLLY_ROTATE: 3 }, wX = 0, ip = 1, KX = 2, rR = 3, hR = 0, C2 = 1, kX = 2, di = 3, $n = 0, y0 = 1, He = 2, M0 = 0, Fi = 1, qo = 2, sp = 3, lp = 4, zX = 5, rs = 100, UX = 101, BX = 102, PX = 103, EX = 104, QX = 200, jX = 201, AX = 202, DX = 203, _r = 204, qr = 205, OX = 206, _X = 207, qX = 208, $X = 209, ty = 210, ey = 211, ny = 212, iy = 213, sy = 214, Y2 = 0, I2 = 1, $r = 2, ga = 3, $o = 4, N2 = 5, v2 = 6, Lu = 7, Ic = 0, ly = 1, ay = 2, Hi = 0, oy = 1, cy = 2, dy = 3, ry = 4, hy = 5, uy = 6, my = 7, ap = "attached", py = "detached", vi = 300, Gi = 301, ki = 302, fa = 303, Ra = 304, Rl = 306, Se = 1e3, G0 = 1001, bl = 1002, ze = 1003, Nc = 1004, uR = 1004, hs = 1005, mR = 1005, Ne = 1006, ol = 1007, pR = 1007, rn = 1008, bR = 1008, L0 = 1009, T2 = 1010, M2 = 1011, xa = 1012, Cu = 1013, Xi = 1014, S0 = 1015, tn = 1016, Yu = 1017, Iu = 1018, Gs = 1020, F2 = 35902, H2 = 1021, J2 = 1022, R0 = 1023, w2 = 1024, K2 = 1025, cl = 1026, Xs = 1027, vc = 1028, Tc = 1029, k2 = 1030, Nu = 1031, ZR = 1032, vu = 1033, Ho = 33776, Jo = 33777, wo = 33778, Ko = 33779, th = 35840, eh = 35841, nh = 35842, ih = 35843, sh = 36196, lh = 37492, ah = 37496, oh = 37808, ch = 37809, dh = 37810, rh = 37811, hh = 37812, uh = 37813, mh = 37814, ph = 37815, bh = 37816, Zh = 37817, Gh = 37818, Xh = 37819, yh = 37820, Wh = 37821, ko = 36492, Vh = 36494, gh = 36495, z2 = 36283, fh = 36284, Rh = 36285, xh = 36286, by = 2200, Zy = 2201, Gy = 2202, Sa = 2300, La = 2301, vr = 2302, $s = 2400, tl = 2401, tc = 2402, Tu = 2500, U2 = 2501, Xy = 0, B2 = 1, Sh = 2, zi = 3200, Mu = 3201, Ws = 0, yy = 1, dn = "", ye = "srgb", u0 = "srgb-linear", Fu = "display-p3", Mc = "display-p3-linear", ec = "linear", $e = "srgb", nc = "rec709", ic = "p3", GR = 0, js = 7680, XR = 7681, yR = 7682, WR = 7683, VR = 34055, gR = 34056, fR = 5386, RR = 512, xR = 513, SR = 514, LR = 515, CR = 516, YR = 517, IR = 518, op = 519, Wy = 512, Vy = 513, gy = 514, P2 = 515, fy = 516, Ry = 517, xy = 518, Sy = 519, sc = 35044, Ly = 35048, NR = 35040, vR = 35045, TR = 35049, MR = 35041, FR = 35046, HR = 35050, JR = 35042, wR = "100", cp = "300 es", hi = 2e3, lc = 2001;
|
|
96
96
|
class Fn {
|
|
97
97
|
addEventListener(t, e) {
|
|
98
98
|
this._listeners === void 0 && (this._listeners = {});
|
|
@@ -1819,7 +1819,7 @@ class W0 {
|
|
|
1819
1819
|
intersectsTriangle(t) {
|
|
1820
1820
|
if (this.isEmpty())
|
|
1821
1821
|
return !1;
|
|
1822
|
-
this.getCenter(io), Xd.subVectors(this.max, io), Il.subVectors(t.a, io), Nl.subVectors(t.b, io), vl.subVectors(t.c, io), ji.subVectors(Nl, Il), Ai.subVectors(vl, Nl),
|
|
1822
|
+
this.getCenter(io), Xd.subVectors(this.max, io), Il.subVectors(t.a, io), Nl.subVectors(t.b, io), vl.subVectors(t.c, io), ji.subVectors(Nl, Il), Ai.subVectors(vl, Nl), Ns.subVectors(Il, vl);
|
|
1823
1823
|
let e = [
|
|
1824
1824
|
0,
|
|
1825
1825
|
-ji.z,
|
|
@@ -1828,25 +1828,25 @@ class W0 {
|
|
|
1828
1828
|
-Ai.z,
|
|
1829
1829
|
Ai.y,
|
|
1830
1830
|
0,
|
|
1831
|
-
-
|
|
1832
|
-
|
|
1831
|
+
-Ns.z,
|
|
1832
|
+
Ns.y,
|
|
1833
1833
|
ji.z,
|
|
1834
1834
|
0,
|
|
1835
1835
|
-ji.x,
|
|
1836
1836
|
Ai.z,
|
|
1837
1837
|
0,
|
|
1838
1838
|
-Ai.x,
|
|
1839
|
-
|
|
1839
|
+
Ns.z,
|
|
1840
1840
|
0,
|
|
1841
|
-
-
|
|
1841
|
+
-Ns.x,
|
|
1842
1842
|
-ji.y,
|
|
1843
1843
|
ji.x,
|
|
1844
1844
|
0,
|
|
1845
1845
|
-Ai.y,
|
|
1846
1846
|
Ai.x,
|
|
1847
1847
|
0,
|
|
1848
|
-
-
|
|
1849
|
-
|
|
1848
|
+
-Ns.y,
|
|
1849
|
+
Ns.x,
|
|
1850
1850
|
0
|
|
1851
1851
|
];
|
|
1852
1852
|
return !fm(e, Il, Nl, vl, Xd) || (e = [1, 0, 0, 0, 1, 0, 0, 0, 1], !fm(e, Il, Nl, vl, Xd)) ? !1 : (yd.crossVectors(ji, Ai), e = [yd.x, yd.y, yd.z], fm(e, Il, Nl, vl, Xd));
|
|
@@ -1885,11 +1885,11 @@ const gi = [
|
|
|
1885
1885
|
/* @__PURE__ */ new N(),
|
|
1886
1886
|
/* @__PURE__ */ new N(),
|
|
1887
1887
|
/* @__PURE__ */ new N()
|
|
1888
|
-
], Kn = /* @__PURE__ */ new N(), Gd = /* @__PURE__ */ new W0(), Il = /* @__PURE__ */ new N(), Nl = /* @__PURE__ */ new N(), vl = /* @__PURE__ */ new N(), ji = /* @__PURE__ */ new N(), Ai = /* @__PURE__ */ new N(),
|
|
1888
|
+
], Kn = /* @__PURE__ */ new N(), Gd = /* @__PURE__ */ new W0(), Il = /* @__PURE__ */ new N(), Nl = /* @__PURE__ */ new N(), vl = /* @__PURE__ */ new N(), ji = /* @__PURE__ */ new N(), Ai = /* @__PURE__ */ new N(), Ns = /* @__PURE__ */ new N(), io = /* @__PURE__ */ new N(), Xd = /* @__PURE__ */ new N(), yd = /* @__PURE__ */ new N(), vs = /* @__PURE__ */ new N();
|
|
1889
1889
|
function fm(i, t, e, n, s) {
|
|
1890
1890
|
for (let l = 0, a = i.length - 3; l <= a; l += 3) {
|
|
1891
|
-
|
|
1892
|
-
const o = s.x * Math.abs(
|
|
1891
|
+
vs.fromArray(i, l);
|
|
1892
|
+
const o = s.x * Math.abs(vs.x) + s.y * Math.abs(vs.y) + s.z * Math.abs(vs.z), c = t.dot(vs), d = e.dot(vs), r = n.dot(vs);
|
|
1893
1893
|
if (Math.max(-Math.max(c, d, r), Math.min(c, d, r)) > o)
|
|
1894
1894
|
return !1;
|
|
1895
1895
|
}
|
|
@@ -3357,7 +3357,7 @@ lt.NAMES = vy;
|
|
|
3357
3357
|
let bx = 0;
|
|
3358
3358
|
class g0 extends Fn {
|
|
3359
3359
|
constructor() {
|
|
3360
|
-
super(), this.isMaterial = !0, Object.defineProperty(this, "id", { value: bx++ }), this.uuid = Rn(), this.name = "", this.type = "Material", this.blending = Fi, this.side = $n, this.vertexColors = !1, this.opacity = 1, this.transparent = !1, this.alphaHash = !1, this.blendSrc = _r, this.blendDst = qr, this.blendEquation =
|
|
3360
|
+
super(), this.isMaterial = !0, Object.defineProperty(this, "id", { value: bx++ }), this.uuid = Rn(), this.name = "", this.type = "Material", this.blending = Fi, this.side = $n, this.vertexColors = !1, this.opacity = 1, this.transparent = !1, this.alphaHash = !1, this.blendSrc = _r, this.blendDst = qr, this.blendEquation = rs, this.blendSrcAlpha = null, this.blendDstAlpha = null, this.blendEquationAlpha = null, this.blendColor = new lt(0, 0, 0), this.blendAlpha = 0, this.depthFunc = ga, this.depthTest = !0, this.depthWrite = !0, this.stencilWriteMask = 255, this.stencilFunc = op, this.stencilRef = 0, this.stencilFuncMask = 255, this.stencilFail = js, this.stencilZFail = js, this.stencilZPass = js, 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.visible = !0, this.toneMapped = !0, this.userData = {}, this.version = 0, this._alphaTest = 0;
|
|
3361
3361
|
}
|
|
3362
3362
|
get alphaTest() {
|
|
3363
3363
|
return this._alphaTest;
|
|
@@ -3399,7 +3399,7 @@ class g0 extends Fn {
|
|
|
3399
3399
|
generator: "Material.toJSON"
|
|
3400
3400
|
}
|
|
3401
3401
|
};
|
|
3402
|
-
n.uuid = this.uuid, n.type = this.type, this.name !== "" && (n.name = this.name), this.color && this.color.isColor && (n.color = this.color.getHex()), this.roughness !== void 0 && (n.roughness = this.roughness), this.metalness !== void 0 && (n.metalness = this.metalness), this.sheen !== void 0 && (n.sheen = this.sheen), this.sheenColor && this.sheenColor.isColor && (n.sheenColor = this.sheenColor.getHex()), this.sheenRoughness !== void 0 && (n.sheenRoughness = this.sheenRoughness), this.emissive && this.emissive.isColor && (n.emissive = this.emissive.getHex()), this.emissiveIntensity !== void 0 && this.emissiveIntensity !== 1 && (n.emissiveIntensity = this.emissiveIntensity), this.specular && this.specular.isColor && (n.specular = this.specular.getHex()), this.specularIntensity !== void 0 && (n.specularIntensity = this.specularIntensity), this.specularColor && this.specularColor.isColor && (n.specularColor = this.specularColor.getHex()), this.shininess !== void 0 && (n.shininess = this.shininess), this.clearcoat !== void 0 && (n.clearcoat = this.clearcoat), this.clearcoatRoughness !== void 0 && (n.clearcoatRoughness = this.clearcoatRoughness), this.clearcoatMap && this.clearcoatMap.isTexture && (n.clearcoatMap = this.clearcoatMap.toJSON(t).uuid), this.clearcoatRoughnessMap && this.clearcoatRoughnessMap.isTexture && (n.clearcoatRoughnessMap = this.clearcoatRoughnessMap.toJSON(t).uuid), this.clearcoatNormalMap && this.clearcoatNormalMap.isTexture && (n.clearcoatNormalMap = this.clearcoatNormalMap.toJSON(t).uuid, n.clearcoatNormalScale = this.clearcoatNormalScale.toArray()), this.dispersion !== void 0 && (n.dispersion = this.dispersion), this.iridescence !== void 0 && (n.iridescence = this.iridescence), this.iridescenceIOR !== void 0 && (n.iridescenceIOR = this.iridescenceIOR), this.iridescenceThicknessRange !== void 0 && (n.iridescenceThicknessRange = this.iridescenceThicknessRange), this.iridescenceMap && this.iridescenceMap.isTexture && (n.iridescenceMap = this.iridescenceMap.toJSON(t).uuid), this.iridescenceThicknessMap && this.iridescenceThicknessMap.isTexture && (n.iridescenceThicknessMap = this.iridescenceThicknessMap.toJSON(t).uuid), this.anisotropy !== void 0 && (n.anisotropy = this.anisotropy), this.anisotropyRotation !== void 0 && (n.anisotropyRotation = this.anisotropyRotation), this.anisotropyMap && this.anisotropyMap.isTexture && (n.anisotropyMap = this.anisotropyMap.toJSON(t).uuid), this.map && this.map.isTexture && (n.map = this.map.toJSON(t).uuid), this.matcap && this.matcap.isTexture && (n.matcap = this.matcap.toJSON(t).uuid), this.alphaMap && this.alphaMap.isTexture && (n.alphaMap = this.alphaMap.toJSON(t).uuid), this.lightMap && this.lightMap.isTexture && (n.lightMap = this.lightMap.toJSON(t).uuid, n.lightMapIntensity = this.lightMapIntensity), this.aoMap && this.aoMap.isTexture && (n.aoMap = this.aoMap.toJSON(t).uuid, n.aoMapIntensity = this.aoMapIntensity), this.bumpMap && this.bumpMap.isTexture && (n.bumpMap = this.bumpMap.toJSON(t).uuid, n.bumpScale = this.bumpScale), this.normalMap && this.normalMap.isTexture && (n.normalMap = this.normalMap.toJSON(t).uuid, n.normalMapType = this.normalMapType, n.normalScale = this.normalScale.toArray()), this.displacementMap && this.displacementMap.isTexture && (n.displacementMap = this.displacementMap.toJSON(t).uuid, n.displacementScale = this.displacementScale, n.displacementBias = this.displacementBias), this.roughnessMap && this.roughnessMap.isTexture && (n.roughnessMap = this.roughnessMap.toJSON(t).uuid), this.metalnessMap && this.metalnessMap.isTexture && (n.metalnessMap = this.metalnessMap.toJSON(t).uuid), this.emissiveMap && this.emissiveMap.isTexture && (n.emissiveMap = this.emissiveMap.toJSON(t).uuid), this.specularMap && this.specularMap.isTexture && (n.specularMap = this.specularMap.toJSON(t).uuid), this.specularIntensityMap && this.specularIntensityMap.isTexture && (n.specularIntensityMap = this.specularIntensityMap.toJSON(t).uuid), this.specularColorMap && this.specularColorMap.isTexture && (n.specularColorMap = this.specularColorMap.toJSON(t).uuid), this.envMap && this.envMap.isTexture && (n.envMap = this.envMap.toJSON(t).uuid, this.combine !== void 0 && (n.combine = this.combine)), this.envMapRotation !== void 0 && (n.envMapRotation = this.envMapRotation.toArray()), this.envMapIntensity !== void 0 && (n.envMapIntensity = this.envMapIntensity), this.reflectivity !== void 0 && (n.reflectivity = this.reflectivity), this.refractionRatio !== void 0 && (n.refractionRatio = this.refractionRatio), this.gradientMap && this.gradientMap.isTexture && (n.gradientMap = this.gradientMap.toJSON(t).uuid), this.transmission !== void 0 && (n.transmission = this.transmission), this.transmissionMap && this.transmissionMap.isTexture && (n.transmissionMap = this.transmissionMap.toJSON(t).uuid), this.thickness !== void 0 && (n.thickness = this.thickness), this.thicknessMap && this.thicknessMap.isTexture && (n.thicknessMap = this.thicknessMap.toJSON(t).uuid), this.attenuationDistance !== void 0 && this.attenuationDistance !== 1 / 0 && (n.attenuationDistance = this.attenuationDistance), this.attenuationColor !== void 0 && (n.attenuationColor = this.attenuationColor.getHex()), this.size !== void 0 && (n.size = this.size), this.shadowSide !== null && (n.shadowSide = this.shadowSide), this.sizeAttenuation !== void 0 && (n.sizeAttenuation = this.sizeAttenuation), this.blending !== Fi && (n.blending = this.blending), this.side !== $n && (n.side = this.side), this.vertexColors === !0 && (n.vertexColors = !0), this.opacity < 1 && (n.opacity = this.opacity), this.transparent === !0 && (n.transparent = !0), this.blendSrc !== _r && (n.blendSrc = this.blendSrc), this.blendDst !== qr && (n.blendDst = this.blendDst), this.blendEquation !==
|
|
3402
|
+
n.uuid = this.uuid, n.type = this.type, this.name !== "" && (n.name = this.name), this.color && this.color.isColor && (n.color = this.color.getHex()), this.roughness !== void 0 && (n.roughness = this.roughness), this.metalness !== void 0 && (n.metalness = this.metalness), this.sheen !== void 0 && (n.sheen = this.sheen), this.sheenColor && this.sheenColor.isColor && (n.sheenColor = this.sheenColor.getHex()), this.sheenRoughness !== void 0 && (n.sheenRoughness = this.sheenRoughness), this.emissive && this.emissive.isColor && (n.emissive = this.emissive.getHex()), this.emissiveIntensity !== void 0 && this.emissiveIntensity !== 1 && (n.emissiveIntensity = this.emissiveIntensity), this.specular && this.specular.isColor && (n.specular = this.specular.getHex()), this.specularIntensity !== void 0 && (n.specularIntensity = this.specularIntensity), this.specularColor && this.specularColor.isColor && (n.specularColor = this.specularColor.getHex()), this.shininess !== void 0 && (n.shininess = this.shininess), this.clearcoat !== void 0 && (n.clearcoat = this.clearcoat), this.clearcoatRoughness !== void 0 && (n.clearcoatRoughness = this.clearcoatRoughness), this.clearcoatMap && this.clearcoatMap.isTexture && (n.clearcoatMap = this.clearcoatMap.toJSON(t).uuid), this.clearcoatRoughnessMap && this.clearcoatRoughnessMap.isTexture && (n.clearcoatRoughnessMap = this.clearcoatRoughnessMap.toJSON(t).uuid), this.clearcoatNormalMap && this.clearcoatNormalMap.isTexture && (n.clearcoatNormalMap = this.clearcoatNormalMap.toJSON(t).uuid, n.clearcoatNormalScale = this.clearcoatNormalScale.toArray()), this.dispersion !== void 0 && (n.dispersion = this.dispersion), this.iridescence !== void 0 && (n.iridescence = this.iridescence), this.iridescenceIOR !== void 0 && (n.iridescenceIOR = this.iridescenceIOR), this.iridescenceThicknessRange !== void 0 && (n.iridescenceThicknessRange = this.iridescenceThicknessRange), this.iridescenceMap && this.iridescenceMap.isTexture && (n.iridescenceMap = this.iridescenceMap.toJSON(t).uuid), this.iridescenceThicknessMap && this.iridescenceThicknessMap.isTexture && (n.iridescenceThicknessMap = this.iridescenceThicknessMap.toJSON(t).uuid), this.anisotropy !== void 0 && (n.anisotropy = this.anisotropy), this.anisotropyRotation !== void 0 && (n.anisotropyRotation = this.anisotropyRotation), this.anisotropyMap && this.anisotropyMap.isTexture && (n.anisotropyMap = this.anisotropyMap.toJSON(t).uuid), this.map && this.map.isTexture && (n.map = this.map.toJSON(t).uuid), this.matcap && this.matcap.isTexture && (n.matcap = this.matcap.toJSON(t).uuid), this.alphaMap && this.alphaMap.isTexture && (n.alphaMap = this.alphaMap.toJSON(t).uuid), this.lightMap && this.lightMap.isTexture && (n.lightMap = this.lightMap.toJSON(t).uuid, n.lightMapIntensity = this.lightMapIntensity), this.aoMap && this.aoMap.isTexture && (n.aoMap = this.aoMap.toJSON(t).uuid, n.aoMapIntensity = this.aoMapIntensity), this.bumpMap && this.bumpMap.isTexture && (n.bumpMap = this.bumpMap.toJSON(t).uuid, n.bumpScale = this.bumpScale), this.normalMap && this.normalMap.isTexture && (n.normalMap = this.normalMap.toJSON(t).uuid, n.normalMapType = this.normalMapType, n.normalScale = this.normalScale.toArray()), this.displacementMap && this.displacementMap.isTexture && (n.displacementMap = this.displacementMap.toJSON(t).uuid, n.displacementScale = this.displacementScale, n.displacementBias = this.displacementBias), this.roughnessMap && this.roughnessMap.isTexture && (n.roughnessMap = this.roughnessMap.toJSON(t).uuid), this.metalnessMap && this.metalnessMap.isTexture && (n.metalnessMap = this.metalnessMap.toJSON(t).uuid), this.emissiveMap && this.emissiveMap.isTexture && (n.emissiveMap = this.emissiveMap.toJSON(t).uuid), this.specularMap && this.specularMap.isTexture && (n.specularMap = this.specularMap.toJSON(t).uuid), this.specularIntensityMap && this.specularIntensityMap.isTexture && (n.specularIntensityMap = this.specularIntensityMap.toJSON(t).uuid), this.specularColorMap && this.specularColorMap.isTexture && (n.specularColorMap = this.specularColorMap.toJSON(t).uuid), this.envMap && this.envMap.isTexture && (n.envMap = this.envMap.toJSON(t).uuid, this.combine !== void 0 && (n.combine = this.combine)), this.envMapRotation !== void 0 && (n.envMapRotation = this.envMapRotation.toArray()), this.envMapIntensity !== void 0 && (n.envMapIntensity = this.envMapIntensity), this.reflectivity !== void 0 && (n.reflectivity = this.reflectivity), this.refractionRatio !== void 0 && (n.refractionRatio = this.refractionRatio), this.gradientMap && this.gradientMap.isTexture && (n.gradientMap = this.gradientMap.toJSON(t).uuid), this.transmission !== void 0 && (n.transmission = this.transmission), this.transmissionMap && this.transmissionMap.isTexture && (n.transmissionMap = this.transmissionMap.toJSON(t).uuid), this.thickness !== void 0 && (n.thickness = this.thickness), this.thicknessMap && this.thicknessMap.isTexture && (n.thicknessMap = this.thicknessMap.toJSON(t).uuid), this.attenuationDistance !== void 0 && this.attenuationDistance !== 1 / 0 && (n.attenuationDistance = this.attenuationDistance), this.attenuationColor !== void 0 && (n.attenuationColor = this.attenuationColor.getHex()), this.size !== void 0 && (n.size = this.size), this.shadowSide !== null && (n.shadowSide = this.shadowSide), this.sizeAttenuation !== void 0 && (n.sizeAttenuation = this.sizeAttenuation), this.blending !== Fi && (n.blending = this.blending), this.side !== $n && (n.side = this.side), this.vertexColors === !0 && (n.vertexColors = !0), this.opacity < 1 && (n.opacity = this.opacity), this.transparent === !0 && (n.transparent = !0), this.blendSrc !== _r && (n.blendSrc = this.blendSrc), this.blendDst !== qr && (n.blendDst = this.blendDst), this.blendEquation !== rs && (n.blendEquation = this.blendEquation), this.blendSrcAlpha !== null && (n.blendSrcAlpha = this.blendSrcAlpha), this.blendDstAlpha !== null && (n.blendDstAlpha = this.blendDstAlpha), this.blendEquationAlpha !== null && (n.blendEquationAlpha = this.blendEquationAlpha), this.blendColor && this.blendColor.isColor && (n.blendColor = this.blendColor.getHex()), this.blendAlpha !== 0 && (n.blendAlpha = this.blendAlpha), this.depthFunc !== ga && (n.depthFunc = this.depthFunc), this.depthTest === !1 && (n.depthTest = this.depthTest), this.depthWrite === !1 && (n.depthWrite = this.depthWrite), this.colorWrite === !1 && (n.colorWrite = this.colorWrite), this.stencilWriteMask !== 255 && (n.stencilWriteMask = this.stencilWriteMask), this.stencilFunc !== op && (n.stencilFunc = this.stencilFunc), this.stencilRef !== 0 && (n.stencilRef = this.stencilRef), this.stencilFuncMask !== 255 && (n.stencilFuncMask = this.stencilFuncMask), this.stencilFail !== js && (n.stencilFail = this.stencilFail), this.stencilZFail !== js && (n.stencilZFail = this.stencilZFail), this.stencilZPass !== js && (n.stencilZPass = this.stencilZPass), this.stencilWrite === !0 && (n.stencilWrite = this.stencilWrite), this.rotation !== void 0 && this.rotation !== 0 && (n.rotation = this.rotation), this.polygonOffset === !0 && (n.polygonOffset = !0), this.polygonOffsetFactor !== 0 && (n.polygonOffsetFactor = this.polygonOffsetFactor), this.polygonOffsetUnits !== 0 && (n.polygonOffsetUnits = this.polygonOffsetUnits), this.linewidth !== void 0 && this.linewidth !== 1 && (n.linewidth = this.linewidth), this.dashSize !== void 0 && (n.dashSize = this.dashSize), this.gapSize !== void 0 && (n.gapSize = this.gapSize), this.scale !== void 0 && (n.scale = this.scale), this.dithering === !0 && (n.dithering = !0), this.alphaTest > 0 && (n.alphaTest = this.alphaTest), this.alphaHash === !0 && (n.alphaHash = !0), this.alphaToCoverage === !0 && (n.alphaToCoverage = !0), this.premultipliedAlpha === !0 && (n.premultipliedAlpha = !0), this.forceSinglePass === !0 && (n.forceSinglePass = !0), this.wireframe === !0 && (n.wireframe = !0), this.wireframeLinewidth > 1 && (n.wireframeLinewidth = this.wireframeLinewidth), this.wireframeLinecap !== "round" && (n.wireframeLinecap = this.wireframeLinecap), this.wireframeLinejoin !== "round" && (n.wireframeLinejoin = this.wireframeLinejoin), this.flatShading === !0 && (n.flatShading = !0), this.visible === !1 && (n.visible = !1), this.toneMapped === !1 && (n.toneMapped = !1), this.fog === !1 && (n.fog = !1), Object.keys(this.userData).length > 0 && (n.userData = this.userData);
|
|
3403
3403
|
function s(l) {
|
|
3404
3404
|
const a = [];
|
|
3405
3405
|
for (const o in l) {
|
|
@@ -4014,7 +4014,7 @@ class Ot extends Fn {
|
|
|
4014
4014
|
this.dispatchEvent({ type: "dispose" });
|
|
4015
4015
|
}
|
|
4016
4016
|
}
|
|
4017
|
-
const wb = /* @__PURE__ */ new Pt(),
|
|
4017
|
+
const wb = /* @__PURE__ */ new Pt(), Ts = /* @__PURE__ */ new Pa(), Sd = /* @__PURE__ */ new F0(), Kb = /* @__PURE__ */ new N(), Kl = /* @__PURE__ */ new N(), kl = /* @__PURE__ */ new N(), zl = /* @__PURE__ */ new N(), Fm = /* @__PURE__ */ new N(), Ld = /* @__PURE__ */ new N(), Cd = /* @__PURE__ */ new _(), Yd = /* @__PURE__ */ new _(), Id = /* @__PURE__ */ new _(), kb = /* @__PURE__ */ new N(), zb = /* @__PURE__ */ new N(), Ub = /* @__PURE__ */ new N(), Nd = /* @__PURE__ */ new N(), vd = /* @__PURE__ */ new N();
|
|
4018
4018
|
class Gt extends be {
|
|
4019
4019
|
constructor(t = new Ot(), e = new Dt()) {
|
|
4020
4020
|
super(), this.isMesh = !0, this.type = "Mesh", this.geometry = t, this.material = e, this.updateMorphTargets();
|
|
@@ -4051,7 +4051,7 @@ class Gt extends be {
|
|
|
4051
4051
|
}
|
|
4052
4052
|
raycast(t, e) {
|
|
4053
4053
|
const n = this.geometry, s = this.material, l = this.matrixWorld;
|
|
4054
|
-
s !== void 0 && (n.boundingSphere === null && n.computeBoundingSphere(), Sd.copy(n.boundingSphere), Sd.applyMatrix4(l),
|
|
4054
|
+
s !== void 0 && (n.boundingSphere === null && n.computeBoundingSphere(), Sd.copy(n.boundingSphere), Sd.applyMatrix4(l), Ts.copy(t.ray).recast(t.near), !(Sd.containsPoint(Ts.origin) === !1 && (Ts.intersectSphere(Sd, Kb) === null || Ts.origin.distanceToSquared(Kb) > Ys(t.far - t.near, 2))) && (wb.copy(l).invert(), Ts.copy(t.ray).applyMatrix4(wb), !(n.boundingBox !== null && Ts.intersectsBox(n.boundingBox) === !1) && this._computeIntersections(t, e, Ts)));
|
|
4055
4055
|
}
|
|
4056
4056
|
_computeIntersections(t, e, n) {
|
|
4057
4057
|
let s;
|
|
@@ -4579,7 +4579,7 @@ let Qn = class {
|
|
|
4579
4579
|
return new this.constructor().copy(this);
|
|
4580
4580
|
}
|
|
4581
4581
|
};
|
|
4582
|
-
const
|
|
4582
|
+
const Ms = /* @__PURE__ */ new F0(), Md = /* @__PURE__ */ new N();
|
|
4583
4583
|
class Jc {
|
|
4584
4584
|
constructor(t = new Qn(), e = new Qn(), n = new Qn(), s = new Qn(), l = new Qn(), a = new Qn()) {
|
|
4585
4585
|
this.planes = [t, e, n, s, l, a];
|
|
@@ -4606,15 +4606,15 @@ class Jc {
|
|
|
4606
4606
|
}
|
|
4607
4607
|
intersectsObject(t) {
|
|
4608
4608
|
if (t.boundingSphere !== void 0)
|
|
4609
|
-
t.boundingSphere === null && t.computeBoundingSphere(),
|
|
4609
|
+
t.boundingSphere === null && t.computeBoundingSphere(), Ms.copy(t.boundingSphere).applyMatrix4(t.matrixWorld);
|
|
4610
4610
|
else {
|
|
4611
4611
|
const e = t.geometry;
|
|
4612
|
-
e.boundingSphere === null && e.computeBoundingSphere(),
|
|
4612
|
+
e.boundingSphere === null && e.computeBoundingSphere(), Ms.copy(e.boundingSphere).applyMatrix4(t.matrixWorld);
|
|
4613
4613
|
}
|
|
4614
|
-
return this.intersectsSphere(
|
|
4614
|
+
return this.intersectsSphere(Ms);
|
|
4615
4615
|
}
|
|
4616
4616
|
intersectsSprite(t) {
|
|
4617
|
-
return
|
|
4617
|
+
return Ms.center.set(0, 0, 0), Ms.radius = 0.7071067811865476, Ms.applyMatrix4(t.matrixWorld), this.intersectsSphere(Ms);
|
|
4618
4618
|
}
|
|
4619
4619
|
intersectsSphere(t) {
|
|
4620
4620
|
const e = this.planes, n = t.center, s = -t.radius;
|
|
@@ -8887,7 +8887,7 @@ jn.physical = {
|
|
|
8887
8887
|
vertexShader: me.meshphysical_vert,
|
|
8888
8888
|
fragmentShader: me.meshphysical_frag
|
|
8889
8889
|
};
|
|
8890
|
-
const Fd = { r: 0, b: 0, g: 0 },
|
|
8890
|
+
const Fd = { r: 0, b: 0, g: 0 }, Fs = /* @__PURE__ */ new E0(), rL = /* @__PURE__ */ new Pt();
|
|
8891
8891
|
function hL(i, t, e, n, s, l, a) {
|
|
8892
8892
|
const o = new lt(0);
|
|
8893
8893
|
let c = l === !0 ? 0 : 1, d, r, h = null, u = 0, m = null;
|
|
@@ -8922,7 +8922,7 @@ function hL(i, t, e, n, s, l, a) {
|
|
|
8922
8922
|
get: function() {
|
|
8923
8923
|
return this.uniforms.envMap.value;
|
|
8924
8924
|
}
|
|
8925
|
-
}), s.update(r)),
|
|
8925
|
+
}), s.update(r)), Fs.copy(y.backgroundRotation), Fs.x *= -1, Fs.y *= -1, Fs.z *= -1, W.isCubeTexture && W.isRenderTargetTexture === !1 && (Fs.y *= -1, Fs.z *= -1), r.material.uniforms.envMap.value = W, r.material.uniforms.flipEnvMap.value = W.isCubeTexture && W.isRenderTargetTexture === !1 ? -1 : 1, r.material.uniforms.backgroundBlurriness.value = y.backgroundBlurriness, r.material.uniforms.backgroundIntensity.value = y.backgroundIntensity, r.material.uniforms.backgroundRotation.value.setFromMatrix4(rL.makeRotationFromEuler(Fs)), r.material.toneMapped = Ie.getTransfer(W.colorSpace) !== $e, (h !== W || u !== W.version || m !== i.toneMapping) && (r.material.needsUpdate = !0, h = W, u = W.version, m = i.toneMapping), r.layers.enableAll(), X.unshift(r, r.geometry, r.material, 0, 0, null)) : W && W.isTexture && (d === void 0 && (d = new Gt(
|
|
8926
8926
|
new Sn(2, 2),
|
|
8927
8927
|
new _e({
|
|
8928
8928
|
name: "BackgroundMaterial",
|
|
@@ -9381,13 +9381,13 @@ class wc extends Ea {
|
|
|
9381
9381
|
}
|
|
9382
9382
|
const ca = 4, Eb = [0.125, 0.215, 0.35, 0.446, 0.526, 0.582], qs = 20, Jm = /* @__PURE__ */ new wc(), Qb = /* @__PURE__ */ new lt();
|
|
9383
9383
|
let wm = null, Km = 0, km = 0, zm = !1;
|
|
9384
|
-
const
|
|
9385
|
-
/* @__PURE__ */ new N(-
|
|
9386
|
-
/* @__PURE__ */ new N(
|
|
9387
|
-
/* @__PURE__ */ new N(-Pl, 0,
|
|
9388
|
-
/* @__PURE__ */ new N(Pl, 0,
|
|
9389
|
-
/* @__PURE__ */ new N(0,
|
|
9390
|
-
/* @__PURE__ */ new N(0,
|
|
9384
|
+
const As = (1 + Math.sqrt(5)) / 2, Pl = 1 / As, jb = [
|
|
9385
|
+
/* @__PURE__ */ new N(-As, Pl, 0),
|
|
9386
|
+
/* @__PURE__ */ new N(As, Pl, 0),
|
|
9387
|
+
/* @__PURE__ */ new N(-Pl, 0, As),
|
|
9388
|
+
/* @__PURE__ */ new N(Pl, 0, As),
|
|
9389
|
+
/* @__PURE__ */ new N(0, As, -Pl),
|
|
9390
|
+
/* @__PURE__ */ new N(0, As, Pl),
|
|
9391
9391
|
/* @__PURE__ */ new N(-1, 1, -1),
|
|
9392
9392
|
/* @__PURE__ */ new N(1, 1, -1),
|
|
9393
9393
|
/* @__PURE__ */ new N(-1, 1, 1),
|
|
@@ -10141,9 +10141,9 @@ function xL(i, t, e, n) {
|
|
|
10141
10141
|
}
|
|
10142
10142
|
class wu extends Je {
|
|
10143
10143
|
constructor(t, e, n, s, l, a, o, c, d, r = cl) {
|
|
10144
|
-
if (r !== cl && r !==
|
|
10144
|
+
if (r !== cl && r !== Xs)
|
|
10145
10145
|
throw new Error("DepthTexture format must be either THREE.DepthFormat or THREE.DepthStencilFormat");
|
|
10146
|
-
n === void 0 && r === cl && (n = Xi), n === void 0 && r ===
|
|
10146
|
+
n === void 0 && r === cl && (n = Xi), n === void 0 && r === Xs && (n = Gs), super(null, s, l, a, o, c, r, n, d), this.isDepthTexture = !0, this.image = { width: t, height: e }, this.magFilter = o !== void 0 ? o : ze, this.minFilter = c !== void 0 ? c : ze, this.flipY = !1, this.generateMipmaps = !1, this.compareFunction = null;
|
|
10147
10147
|
}
|
|
10148
10148
|
copy(t) {
|
|
10149
10149
|
return super.copy(t), this.compareFunction = t.compareFunction, this;
|
|
@@ -11190,7 +11190,7 @@ function KC(i, t, e, n, s, l, a) {
|
|
|
11190
11190
|
jt = ve.vertexShader, st = ve.fragmentShader;
|
|
11191
11191
|
} else
|
|
11192
11192
|
jt = S.vertexShader, st = S.fragmentShader, c.update(S), Xt = c.getVertexShaderID(S), Wt = c.getFragmentShaderID(S);
|
|
11193
|
-
const St = i.getRenderTarget(), Qt = w.isInstancedMesh === !0, se = w.isBatchedMesh === !0, qt = !!S.map, he = !!S.matcap, M = !!E, ft = !!S.aoMap, gt = !!S.lightMap, Ct = !!S.bumpMap,
|
|
11193
|
+
const St = i.getRenderTarget(), Qt = w.isInstancedMesh === !0, se = w.isBatchedMesh === !0, qt = !!S.map, he = !!S.matcap, M = !!E, ft = !!S.aoMap, gt = !!S.lightMap, Ct = !!S.bumpMap, mt = !!S.normalMap, rt = !!S.displacementMap, nt = !!S.emissiveMap, ot = !!S.metalnessMap, F = !!S.roughnessMap, Y = S.anisotropy > 0, D = S.clearcoat > 0, at = S.dispersion > 0, dt = S.iridescence > 0, bt = S.sheen > 0, Kt = S.transmission > 0, vt = Y && !!S.anisotropyMap, kt = D && !!S.clearcoatMap, At = D && !!S.clearcoatNormalMap, xt = D && !!S.clearcoatRoughnessMap, zt = dt && !!S.iridescenceMap, Xe = dt && !!S.iridescenceThicknessMap, Et = bt && !!S.sheenColorMap, Ht = bt && !!S.sheenRoughnessMap, te = !!S.specularMap, $t = !!S.specularColorMap, Ve = !!S.specularIntensityMap, B = Kt && !!S.transmissionMap, Yt = Kt && !!S.thicknessMap, O = !!S.gradientMap, Zt = !!S.alphaMap, Mt = S.alphaTest > 0, ee = !!S.alphaHash, xe = !!S.extensions;
|
|
11194
11194
|
let m0 = Hi;
|
|
11195
11195
|
S.toneMapped && (St === null || St.isXRRenderTarget === !0) && (m0 = i.toneMapping);
|
|
11196
11196
|
const x0 = {
|
|
@@ -11221,11 +11221,11 @@ function KC(i, t, e, n, s, l, a) {
|
|
|
11221
11221
|
aoMap: ft,
|
|
11222
11222
|
lightMap: gt,
|
|
11223
11223
|
bumpMap: Ct,
|
|
11224
|
-
normalMap:
|
|
11224
|
+
normalMap: mt,
|
|
11225
11225
|
displacementMap: u && rt,
|
|
11226
11226
|
emissiveMap: nt,
|
|
11227
|
-
normalMapObjectSpace:
|
|
11228
|
-
normalMapTangentSpace:
|
|
11227
|
+
normalMapObjectSpace: mt && S.normalMapType === yy,
|
|
11228
|
+
normalMapTangentSpace: mt && S.normalMapType === Ws,
|
|
11229
11229
|
metalnessMap: ot,
|
|
11230
11230
|
roughnessMap: F,
|
|
11231
11231
|
anisotropy: Y,
|
|
@@ -11238,7 +11238,7 @@ function KC(i, t, e, n, s, l, a) {
|
|
|
11238
11238
|
iridescence: dt,
|
|
11239
11239
|
iridescenceMap: zt,
|
|
11240
11240
|
iridescenceThicknessMap: Xe,
|
|
11241
|
-
sheen:
|
|
11241
|
+
sheen: bt,
|
|
11242
11242
|
sheenColorMap: Et,
|
|
11243
11243
|
sheenRoughnessMap: Ht,
|
|
11244
11244
|
specularMap: te,
|
|
@@ -11258,7 +11258,7 @@ function KC(i, t, e, n, s, l, a) {
|
|
|
11258
11258
|
aoMapUv: ft && G(S.aoMap.channel),
|
|
11259
11259
|
lightMapUv: gt && G(S.lightMap.channel),
|
|
11260
11260
|
bumpMapUv: Ct && G(S.bumpMap.channel),
|
|
11261
|
-
normalMapUv:
|
|
11261
|
+
normalMapUv: mt && G(S.normalMap.channel),
|
|
11262
11262
|
displacementMapUv: rt && G(S.displacementMap.channel),
|
|
11263
11263
|
emissiveMapUv: nt && G(S.emissiveMap.channel),
|
|
11264
11264
|
metalnessMapUv: ot && G(S.metalnessMap.channel),
|
|
@@ -11278,7 +11278,7 @@ function KC(i, t, e, n, s, l, a) {
|
|
|
11278
11278
|
thicknessMapUv: Yt && G(S.thicknessMap.channel),
|
|
11279
11279
|
alphaMapUv: Zt && G(S.alphaMap.channel),
|
|
11280
11280
|
//
|
|
11281
|
-
vertexTangents: !!H.attributes.tangent && (
|
|
11281
|
+
vertexTangents: !!H.attributes.tangent && (mt || Y),
|
|
11282
11282
|
vertexColors: S.vertexColors,
|
|
11283
11283
|
vertexAlphas: S.vertexColors === !0 && !!H.attributes.color && H.attributes.color.itemSize === 4,
|
|
11284
11284
|
pointsUvs: w.isPoints === !0 && !!H.attributes.uv && (qt || Zt),
|
|
@@ -12011,7 +12011,7 @@ function qC(i) {
|
|
|
12011
12011
|
return ee;
|
|
12012
12012
|
}
|
|
12013
12013
|
const Xt = {};
|
|
12014
|
-
Xt[i.TEXTURE_2D] = st(i.TEXTURE_2D, i.TEXTURE_2D, 1), Xt[i.TEXTURE_CUBE_MAP] = st(i.TEXTURE_CUBE_MAP, i.TEXTURE_CUBE_MAP_POSITIVE_X, 6), Xt[i.TEXTURE_2D_ARRAY] = st(i.TEXTURE_2D_ARRAY, i.TEXTURE_2D_ARRAY, 1, 1), Xt[i.TEXTURE_3D] = st(i.TEXTURE_3D, i.TEXTURE_3D, 1, 1), s.setClear(0, 0, 0, 1), l.setClear(1), a.setClear(0), Wt(i.DEPTH_TEST), l.setFunc(ga), Ct(!1),
|
|
12014
|
+
Xt[i.TEXTURE_2D] = st(i.TEXTURE_2D, i.TEXTURE_2D, 1), Xt[i.TEXTURE_CUBE_MAP] = st(i.TEXTURE_CUBE_MAP, i.TEXTURE_CUBE_MAP_POSITIVE_X, 6), Xt[i.TEXTURE_2D_ARRAY] = st(i.TEXTURE_2D_ARRAY, i.TEXTURE_2D_ARRAY, 1, 1), Xt[i.TEXTURE_3D] = st(i.TEXTURE_3D, i.TEXTURE_3D, 1, 1), s.setClear(0, 0, 0, 1), l.setClear(1), a.setClear(0), Wt(i.DEPTH_TEST), l.setFunc(ga), Ct(!1), mt(ip), Wt(i.CULL_FACE), ft(M0);
|
|
12015
12015
|
function Wt(B) {
|
|
12016
12016
|
d[B] !== !0 && (i.enable(B), d[B] = !0);
|
|
12017
12017
|
}
|
|
@@ -12039,7 +12039,7 @@ function qC(i) {
|
|
|
12039
12039
|
return m !== B ? (i.useProgram(B), m = B, !0) : !1;
|
|
12040
12040
|
}
|
|
12041
12041
|
const he = {
|
|
12042
|
-
[
|
|
12042
|
+
[rs]: i.FUNC_ADD,
|
|
12043
12043
|
[UX]: i.FUNC_SUBTRACT,
|
|
12044
12044
|
[BX]: i.FUNC_REVERSE_SUBTRACT
|
|
12045
12045
|
};
|
|
@@ -12068,7 +12068,7 @@ function qC(i) {
|
|
|
12068
12068
|
}
|
|
12069
12069
|
if (b === !1 && (Wt(i.BLEND), b = !0), B !== zX) {
|
|
12070
12070
|
if (B !== G || ve !== I) {
|
|
12071
|
-
if ((Z !==
|
|
12071
|
+
if ((Z !== rs || y !== rs) && (i.blendEquation(i.FUNC_ADD), Z = rs, y = rs), ve)
|
|
12072
12072
|
switch (B) {
|
|
12073
12073
|
case Fi:
|
|
12074
12074
|
i.blendFuncSeparate(i.ONE, i.ONE_MINUS_SRC_ALPHA, i.ONE, i.ONE_MINUS_SRC_ALPHA);
|
|
@@ -12120,7 +12120,7 @@ function qC(i) {
|
|
|
12120
12120
|
function Ct(B) {
|
|
12121
12121
|
S !== B && (B ? i.frontFace(i.CW) : i.frontFace(i.CCW), S = B);
|
|
12122
12122
|
}
|
|
12123
|
-
function
|
|
12123
|
+
function mt(B) {
|
|
12124
12124
|
B !== wX ? (Wt(i.CULL_FACE), B !== R && (B === ip ? i.cullFace(i.BACK) : B === KX ? i.cullFace(i.FRONT) : i.cullFace(i.FRONT_AND_BACK))) : St(i.CULL_FACE), R = B;
|
|
12125
12125
|
}
|
|
12126
12126
|
function rt(B) {
|
|
@@ -12158,7 +12158,7 @@ function qC(i) {
|
|
|
12158
12158
|
console.error("THREE.WebGLState:", B);
|
|
12159
12159
|
}
|
|
12160
12160
|
}
|
|
12161
|
-
function
|
|
12161
|
+
function bt() {
|
|
12162
12162
|
try {
|
|
12163
12163
|
i.texSubImage2D.apply(i, arguments);
|
|
12164
12164
|
} catch (B) {
|
|
@@ -12247,7 +12247,7 @@ function qC(i) {
|
|
|
12247
12247
|
setBlending: ft,
|
|
12248
12248
|
setMaterial: gt,
|
|
12249
12249
|
setFlipSided: Ct,
|
|
12250
|
-
setCullFace:
|
|
12250
|
+
setCullFace: mt,
|
|
12251
12251
|
setLineWidth: rt,
|
|
12252
12252
|
setPolygonOffset: nt,
|
|
12253
12253
|
setScissorTest: ot,
|
|
@@ -12262,7 +12262,7 @@ function qC(i) {
|
|
|
12262
12262
|
uniformBlockBinding: $t,
|
|
12263
12263
|
texStorage2D: At,
|
|
12264
12264
|
texStorage3D: xt,
|
|
12265
|
-
texSubImage2D:
|
|
12265
|
+
texSubImage2D: bt,
|
|
12266
12266
|
texSubImage3D: Kt,
|
|
12267
12267
|
compressedTexSubImage2D: vt,
|
|
12268
12268
|
compressedTexSubImage3D: kt,
|
|
@@ -12412,10 +12412,10 @@ function sY(i, t, e, n, s, l, a) {
|
|
|
12412
12412
|
const dt = ot(F);
|
|
12413
12413
|
if ((dt.width > D || dt.height > D) && (at = D / Math.max(dt.width, dt.height)), at < 1)
|
|
12414
12414
|
if (typeof HTMLImageElement != "undefined" && F instanceof HTMLImageElement || typeof HTMLCanvasElement != "undefined" && F instanceof HTMLCanvasElement || typeof ImageBitmap != "undefined" && F instanceof ImageBitmap || typeof VideoFrame != "undefined" && F instanceof VideoFrame) {
|
|
12415
|
-
const
|
|
12416
|
-
h === void 0 && (h = b(
|
|
12417
|
-
const vt = Y ? b(
|
|
12418
|
-
return vt.width =
|
|
12415
|
+
const bt = Math.floor(at * dt.width), Kt = Math.floor(at * dt.height);
|
|
12416
|
+
h === void 0 && (h = b(bt, Kt));
|
|
12417
|
+
const vt = Y ? b(bt, Kt) : h;
|
|
12418
|
+
return vt.width = bt, vt.height = Kt, vt.getContext("2d").drawImage(F, 0, 0, bt, Kt), console.warn("THREE.WebGLRenderer: Texture has been resized from (" + dt.width + "x" + dt.height + ") to (" + bt + "x" + Kt + ")."), vt;
|
|
12419
12419
|
} else
|
|
12420
12420
|
return "data" in F && console.warn("THREE.WebGLRenderer: Image in DataTexture is too big (" + dt.width + "x" + dt.height + ")."), F;
|
|
12421
12421
|
return F;
|
|
@@ -12431,16 +12431,16 @@ function sY(i, t, e, n, s, l, a) {
|
|
|
12431
12431
|
if (i[F] !== void 0) return i[F];
|
|
12432
12432
|
console.warn("THREE.WebGLRenderer: Attempt to use non-existing WebGL internal format '" + F + "'");
|
|
12433
12433
|
}
|
|
12434
|
-
let
|
|
12435
|
-
if (Y === i.RED && (D === i.FLOAT && (
|
|
12434
|
+
let bt = Y;
|
|
12435
|
+
if (Y === i.RED && (D === i.FLOAT && (bt = i.R32F), D === i.HALF_FLOAT && (bt = i.R16F), D === i.UNSIGNED_BYTE && (bt = i.R8)), Y === i.RED_INTEGER && (D === i.UNSIGNED_BYTE && (bt = i.R8UI), D === i.UNSIGNED_SHORT && (bt = i.R16UI), D === i.UNSIGNED_INT && (bt = i.R32UI), D === i.BYTE && (bt = i.R8I), D === i.SHORT && (bt = i.R16I), D === i.INT && (bt = i.R32I)), Y === i.RG && (D === i.FLOAT && (bt = i.RG32F), D === i.HALF_FLOAT && (bt = i.RG16F), D === i.UNSIGNED_BYTE && (bt = i.RG8)), Y === i.RG_INTEGER && (D === i.UNSIGNED_BYTE && (bt = i.RG8UI), D === i.UNSIGNED_SHORT && (bt = i.RG16UI), D === i.UNSIGNED_INT && (bt = i.RG32UI), D === i.BYTE && (bt = i.RG8I), D === i.SHORT && (bt = i.RG16I), D === i.INT && (bt = i.RG32I)), Y === i.RGB && D === i.UNSIGNED_INT_5_9_9_9_REV && (bt = i.RGB9_E5), Y === i.RGBA) {
|
|
12436
12436
|
const Kt = dt ? ec : Ie.getTransfer(at);
|
|
12437
|
-
D === i.FLOAT && (
|
|
12437
|
+
D === i.FLOAT && (bt = i.RGBA32F), D === i.HALF_FLOAT && (bt = i.RGBA16F), D === i.UNSIGNED_BYTE && (bt = Kt === $e ? i.SRGB8_ALPHA8 : i.RGBA8), D === i.UNSIGNED_SHORT_4_4_4_4 && (bt = i.RGBA4), D === i.UNSIGNED_SHORT_5_5_5_1 && (bt = i.RGB5_A1);
|
|
12438
12438
|
}
|
|
12439
|
-
return (
|
|
12439
|
+
return (bt === i.R16F || bt === i.R32F || bt === i.RG16F || bt === i.RG32F || bt === i.RGBA16F || bt === i.RGBA32F) && t.get("EXT_color_buffer_float"), bt;
|
|
12440
12440
|
}
|
|
12441
12441
|
function y(F, Y) {
|
|
12442
12442
|
let D;
|
|
12443
|
-
return F ? Y === null || Y === Xi || Y ===
|
|
12443
|
+
return F ? Y === null || Y === Xi || Y === Gs ? D = i.DEPTH24_STENCIL8 : Y === S0 ? D = i.DEPTH32F_STENCIL8 : Y === xa && (D = i.DEPTH24_STENCIL8, console.warn("DepthTexture: 16 bit depth attachment is not supported with stencil. Using 24-bit attachment.")) : Y === null || Y === Xi || Y === Gs ? D = i.DEPTH_COMPONENT24 : Y === S0 ? D = i.DEPTH_COMPONENT32F : Y === xa && (D = i.DEPTH_COMPONENT16), D;
|
|
12444
12444
|
}
|
|
12445
12445
|
function W(F, Y) {
|
|
12446
12446
|
return Z(F) === !0 || F.isFramebufferTexture && F.minFilter !== ze && F.minFilter !== Ne ? Math.log2(Math.max(Y.width, Y.height)) + 1 : F.mipmaps !== void 0 && F.mipmaps.length > 0 ? F.mipmaps.length : F.isCompressedTexture && Array.isArray(F.image) ? Y.mipmaps.length : 1;
|
|
@@ -12491,8 +12491,8 @@ function sY(i, t, e, n, s, l, a) {
|
|
|
12491
12491
|
}
|
|
12492
12492
|
const D = F.textures;
|
|
12493
12493
|
for (let at = 0, dt = D.length; at < dt; at++) {
|
|
12494
|
-
const
|
|
12495
|
-
|
|
12494
|
+
const bt = n.get(D[at]);
|
|
12495
|
+
bt.__webglTexture && (i.deleteTexture(bt.__webglTexture), a.memory.textures--), n.remove(D[at]);
|
|
12496
12496
|
}
|
|
12497
12497
|
n.remove(F);
|
|
12498
12498
|
}
|
|
@@ -12554,7 +12554,7 @@ function sY(i, t, e, n, s, l, a) {
|
|
|
12554
12554
|
}, et = {
|
|
12555
12555
|
[ze]: i.NEAREST,
|
|
12556
12556
|
[Nc]: i.NEAREST_MIPMAP_NEAREST,
|
|
12557
|
-
[
|
|
12557
|
+
[hs]: i.NEAREST_MIPMAP_LINEAR,
|
|
12558
12558
|
[Ne]: i.LINEAR,
|
|
12559
12559
|
[ol]: i.LINEAR_MIPMAP_NEAREST,
|
|
12560
12560
|
[rn]: i.LINEAR_MIPMAP_LINEAR
|
|
@@ -12569,8 +12569,8 @@ function sY(i, t, e, n, s, l, a) {
|
|
|
12569
12569
|
[Ry]: i.NOTEQUAL
|
|
12570
12570
|
};
|
|
12571
12571
|
function Vt(F, Y) {
|
|
12572
|
-
if (Y.type === S0 && t.has("OES_texture_float_linear") === !1 && (Y.magFilter === Ne || Y.magFilter === ol || Y.magFilter ===
|
|
12573
|
-
if (Y.magFilter === ze || Y.minFilter !==
|
|
12572
|
+
if (Y.type === S0 && t.has("OES_texture_float_linear") === !1 && (Y.magFilter === Ne || Y.magFilter === ol || Y.magFilter === hs || Y.magFilter === rn || Y.minFilter === Ne || Y.minFilter === ol || Y.minFilter === hs || Y.minFilter === rn) && console.warn("THREE.WebGLRenderer: Unable to use linear filtering with floating point textures. OES_texture_float_linear not supported on this device."), i.texParameteri(F, i.TEXTURE_WRAP_S, Q[Y.wrapS]), i.texParameteri(F, i.TEXTURE_WRAP_T, Q[Y.wrapT]), (F === i.TEXTURE_3D || F === i.TEXTURE_2D_ARRAY) && i.texParameteri(F, i.TEXTURE_WRAP_R, Q[Y.wrapR]), i.texParameteri(F, i.TEXTURE_MAG_FILTER, et[Y.magFilter]), i.texParameteri(F, i.TEXTURE_MIN_FILTER, et[Y.minFilter]), Y.compareFunction && (i.texParameteri(F, i.TEXTURE_COMPARE_MODE, i.COMPARE_REF_TO_TEXTURE), i.texParameteri(F, i.TEXTURE_COMPARE_FUNC, yt[Y.compareFunction])), t.has("EXT_texture_filter_anisotropic") === !0) {
|
|
12573
|
+
if (Y.magFilter === ze || Y.minFilter !== hs && Y.minFilter !== rn || Y.type === S0 && t.has("OES_texture_float_linear") === !1) return;
|
|
12574
12574
|
if (Y.anisotropy > 1 || n.get(Y).__currentAnisotropy) {
|
|
12575
12575
|
const D = t.get("EXT_texture_filter_anisotropic");
|
|
12576
12576
|
i.texParameterf(F, D.TEXTURE_MAX_ANISOTROPY_EXT, Math.min(Y.anisotropy, s.getMaxAnisotropy())), n.get(Y).__currentAnisotropy = Y.anisotropy;
|
|
@@ -12583,24 +12583,24 @@ function sY(i, t, e, n, s, l, a) {
|
|
|
12583
12583
|
const at = Y.source;
|
|
12584
12584
|
let dt = u.get(at);
|
|
12585
12585
|
dt === void 0 && (dt = {}, u.set(at, dt));
|
|
12586
|
-
const
|
|
12587
|
-
if (
|
|
12588
|
-
dt[
|
|
12586
|
+
const bt = w(Y);
|
|
12587
|
+
if (bt !== F.__cacheKey) {
|
|
12588
|
+
dt[bt] === void 0 && (dt[bt] = {
|
|
12589
12589
|
texture: i.createTexture(),
|
|
12590
12590
|
usedTimes: 0
|
|
12591
|
-
}, a.memory.textures++, D = !0), dt[
|
|
12591
|
+
}, a.memory.textures++, D = !0), dt[bt].usedTimes++;
|
|
12592
12592
|
const Kt = dt[F.__cacheKey];
|
|
12593
|
-
Kt !== void 0 && (dt[F.__cacheKey].usedTimes--, Kt.usedTimes === 0 && I(Y)), F.__cacheKey =
|
|
12593
|
+
Kt !== void 0 && (dt[F.__cacheKey].usedTimes--, Kt.usedTimes === 0 && I(Y)), F.__cacheKey = bt, F.__webglTexture = dt[bt].texture;
|
|
12594
12594
|
}
|
|
12595
12595
|
return D;
|
|
12596
12596
|
}
|
|
12597
12597
|
function jt(F, Y, D) {
|
|
12598
12598
|
let at = i.TEXTURE_2D;
|
|
12599
12599
|
(Y.isDataArrayTexture || Y.isCompressedArrayTexture) && (at = i.TEXTURE_2D_ARRAY), Y.isData3DTexture && (at = i.TEXTURE_3D);
|
|
12600
|
-
const dt = Ut(F, Y),
|
|
12600
|
+
const dt = Ut(F, Y), bt = Y.source;
|
|
12601
12601
|
e.bindTexture(at, F.__webglTexture, i.TEXTURE0 + D);
|
|
12602
|
-
const Kt = n.get(
|
|
12603
|
-
if (
|
|
12602
|
+
const Kt = n.get(bt);
|
|
12603
|
+
if (bt.version !== Kt.__version || dt === !0) {
|
|
12604
12604
|
e.activeTexture(i.TEXTURE0 + D);
|
|
12605
12605
|
const vt = Ie.getPrimaries(Ie.workingColorSpace), kt = Y.colorSpace === dn ? null : Ie.getPrimaries(Y.colorSpace), At = Y.colorSpace === dn || vt === kt ? i.NONE : i.BROWSER_DEFAULT_WEBGL;
|
|
12606
12606
|
i.pixelStorei(i.UNPACK_FLIP_Y_WEBGL, Y.flipY), i.pixelStorei(i.UNPACK_PREMULTIPLY_ALPHA_WEBGL, Y.premultiplyAlpha), i.pixelStorei(i.UNPACK_ALIGNMENT, Y.unpackAlignment), i.pixelStorei(i.UNPACK_COLORSPACE_CONVERSION_WEBGL, At);
|
|
@@ -12610,9 +12610,9 @@ function sY(i, t, e, n, s, l, a) {
|
|
|
12610
12610
|
let Et = X(Y.internalFormat, zt, Xe, Y.colorSpace, Y.isVideoTexture);
|
|
12611
12611
|
Vt(at, Y);
|
|
12612
12612
|
let Ht;
|
|
12613
|
-
const te = Y.mipmaps, $t = Y.isVideoTexture !== !0, Ve = Kt.__version === void 0 || dt === !0, B =
|
|
12613
|
+
const te = Y.mipmaps, $t = Y.isVideoTexture !== !0, Ve = Kt.__version === void 0 || dt === !0, B = bt.dataReady, Yt = W(Y, xt);
|
|
12614
12614
|
if (Y.isDepthTexture)
|
|
12615
|
-
Et = y(Y.format ===
|
|
12615
|
+
Et = y(Y.format === Xs, Y.type), Ve && ($t ? e.texStorage2D(i.TEXTURE_2D, 1, Et, xt.width, xt.height) : e.texImage2D(i.TEXTURE_2D, 0, Et, xt.width, xt.height, 0, zt, Xe, null));
|
|
12616
12616
|
else if (Y.isDataTexture)
|
|
12617
12617
|
if (te.length > 0) {
|
|
12618
12618
|
$t && Ve && e.texStorage2D(i.TEXTURE_2D, Yt, Et, te[0].width, te[0].height);
|
|
@@ -12696,7 +12696,7 @@ function sY(i, t, e, n, s, l, a) {
|
|
|
12696
12696
|
B && e.texSubImage2D(i.TEXTURE_2D, 0, 0, 0, zt, Xe, xt);
|
|
12697
12697
|
} else
|
|
12698
12698
|
e.texImage2D(i.TEXTURE_2D, 0, Et, zt, Xe, xt);
|
|
12699
|
-
Z(Y) && p(at), Kt.__version =
|
|
12699
|
+
Z(Y) && p(at), Kt.__version = bt.version, Y.onUpdate && Y.onUpdate(Y);
|
|
12700
12700
|
}
|
|
12701
12701
|
F.__version = Y.version;
|
|
12702
12702
|
}
|
|
@@ -12704,15 +12704,15 @@ function sY(i, t, e, n, s, l, a) {
|
|
|
12704
12704
|
if (Y.image.length !== 6) return;
|
|
12705
12705
|
const at = Ut(F, Y), dt = Y.source;
|
|
12706
12706
|
e.bindTexture(i.TEXTURE_CUBE_MAP, F.__webglTexture, i.TEXTURE0 + D);
|
|
12707
|
-
const
|
|
12708
|
-
if (dt.version !==
|
|
12707
|
+
const bt = n.get(dt);
|
|
12708
|
+
if (dt.version !== bt.__version || at === !0) {
|
|
12709
12709
|
e.activeTexture(i.TEXTURE0 + D);
|
|
12710
12710
|
const Kt = Ie.getPrimaries(Ie.workingColorSpace), vt = Y.colorSpace === dn ? null : Ie.getPrimaries(Y.colorSpace), kt = Y.colorSpace === dn || Kt === vt ? i.NONE : i.BROWSER_DEFAULT_WEBGL;
|
|
12711
12711
|
i.pixelStorei(i.UNPACK_FLIP_Y_WEBGL, Y.flipY), i.pixelStorei(i.UNPACK_PREMULTIPLY_ALPHA_WEBGL, Y.premultiplyAlpha), i.pixelStorei(i.UNPACK_ALIGNMENT, Y.unpackAlignment), i.pixelStorei(i.UNPACK_COLORSPACE_CONVERSION_WEBGL, kt);
|
|
12712
12712
|
const At = Y.isCompressedTexture || Y.image[0].isCompressedTexture, xt = Y.image[0] && Y.image[0].isDataTexture, zt = [];
|
|
12713
12713
|
for (let Zt = 0; Zt < 6; Zt++)
|
|
12714
12714
|
!At && !xt ? zt[Zt] = G(Y.image[Zt], !0, s.maxCubemapSize) : zt[Zt] = xt ? Y.image[Zt].image : Y.image[Zt], zt[Zt] = nt(Y, zt[Zt]);
|
|
12715
|
-
const Xe = zt[0], Et = l.convert(Y.format, Y.colorSpace), Ht = l.convert(Y.type), te = X(Y.internalFormat, Et, Ht, Y.colorSpace), $t = Y.isVideoTexture !== !0, Ve =
|
|
12715
|
+
const Xe = zt[0], Et = l.convert(Y.format, Y.colorSpace), Ht = l.convert(Y.type), te = X(Y.internalFormat, Et, Ht, Y.colorSpace), $t = Y.isVideoTexture !== !0, Ve = bt.__version === void 0 || at === !0, B = dt.dataReady;
|
|
12716
12716
|
let Yt = W(Y, Xe);
|
|
12717
12717
|
Vt(i.TEXTURE_CUBE_MAP, Y);
|
|
12718
12718
|
let O;
|
|
@@ -12746,27 +12746,27 @@ function sY(i, t, e, n, s, l, a) {
|
|
|
12746
12746
|
}
|
|
12747
12747
|
}
|
|
12748
12748
|
}
|
|
12749
|
-
Z(Y) && p(i.TEXTURE_CUBE_MAP),
|
|
12749
|
+
Z(Y) && p(i.TEXTURE_CUBE_MAP), bt.__version = dt.version, Y.onUpdate && Y.onUpdate(Y);
|
|
12750
12750
|
}
|
|
12751
12751
|
F.__version = Y.version;
|
|
12752
12752
|
}
|
|
12753
|
-
function Xt(F, Y, D, at, dt,
|
|
12753
|
+
function Xt(F, Y, D, at, dt, bt) {
|
|
12754
12754
|
const Kt = l.convert(D.format, D.colorSpace), vt = l.convert(D.type), kt = X(D.internalFormat, Kt, vt, D.colorSpace);
|
|
12755
12755
|
if (!n.get(Y).__hasExternalTextures) {
|
|
12756
|
-
const xt = Math.max(1, Y.width >>
|
|
12757
|
-
dt === i.TEXTURE_3D || dt === i.TEXTURE_2D_ARRAY ? e.texImage3D(dt,
|
|
12756
|
+
const xt = Math.max(1, Y.width >> bt), zt = Math.max(1, Y.height >> bt);
|
|
12757
|
+
dt === i.TEXTURE_3D || dt === i.TEXTURE_2D_ARRAY ? e.texImage3D(dt, bt, kt, xt, zt, Y.depth, 0, Kt, vt, null) : e.texImage2D(dt, bt, kt, xt, zt, 0, Kt, vt, null);
|
|
12758
12758
|
}
|
|
12759
|
-
e.bindFramebuffer(i.FRAMEBUFFER, F),
|
|
12759
|
+
e.bindFramebuffer(i.FRAMEBUFFER, F), mt(Y) ? o.framebufferTexture2DMultisampleEXT(i.FRAMEBUFFER, at, dt, n.get(D).__webglTexture, 0, Ct(Y)) : (dt === i.TEXTURE_2D || dt >= i.TEXTURE_CUBE_MAP_POSITIVE_X && dt <= i.TEXTURE_CUBE_MAP_NEGATIVE_Z) && i.framebufferTexture2D(i.FRAMEBUFFER, at, dt, n.get(D).__webglTexture, bt), e.bindFramebuffer(i.FRAMEBUFFER, null);
|
|
12760
12760
|
}
|
|
12761
12761
|
function Wt(F, Y, D) {
|
|
12762
12762
|
if (i.bindRenderbuffer(i.RENDERBUFFER, F), Y.depthBuffer) {
|
|
12763
|
-
const at = Y.depthTexture, dt = at && at.isDepthTexture ? at.type : null,
|
|
12764
|
-
|
|
12763
|
+
const at = Y.depthTexture, dt = at && at.isDepthTexture ? at.type : null, bt = y(Y.stencilBuffer, dt), Kt = Y.stencilBuffer ? i.DEPTH_STENCIL_ATTACHMENT : i.DEPTH_ATTACHMENT, vt = Ct(Y);
|
|
12764
|
+
mt(Y) ? o.renderbufferStorageMultisampleEXT(i.RENDERBUFFER, vt, bt, Y.width, Y.height) : D ? i.renderbufferStorageMultisample(i.RENDERBUFFER, vt, bt, Y.width, Y.height) : i.renderbufferStorage(i.RENDERBUFFER, bt, Y.width, Y.height), i.framebufferRenderbuffer(i.FRAMEBUFFER, Kt, i.RENDERBUFFER, F);
|
|
12765
12765
|
} else {
|
|
12766
12766
|
const at = Y.textures;
|
|
12767
12767
|
for (let dt = 0; dt < at.length; dt++) {
|
|
12768
|
-
const
|
|
12769
|
-
D &&
|
|
12768
|
+
const bt = at[dt], Kt = l.convert(bt.format, bt.colorSpace), vt = l.convert(bt.type), kt = X(bt.internalFormat, Kt, vt, bt.colorSpace), At = Ct(Y);
|
|
12769
|
+
D && mt(Y) === !1 ? i.renderbufferStorageMultisample(i.RENDERBUFFER, At, kt, Y.width, Y.height) : mt(Y) ? o.renderbufferStorageMultisampleEXT(i.RENDERBUFFER, At, kt, Y.width, Y.height) : i.renderbufferStorage(i.RENDERBUFFER, kt, Y.width, Y.height);
|
|
12770
12770
|
}
|
|
12771
12771
|
}
|
|
12772
12772
|
i.bindRenderbuffer(i.RENDERBUFFER, null);
|
|
@@ -12778,9 +12778,9 @@ function sY(i, t, e, n, s, l, a) {
|
|
|
12778
12778
|
(!n.get(Y.depthTexture).__webglTexture || Y.depthTexture.image.width !== Y.width || Y.depthTexture.image.height !== Y.height) && (Y.depthTexture.image.width = Y.width, Y.depthTexture.image.height = Y.height, Y.depthTexture.needsUpdate = !0), K(Y.depthTexture, 0);
|
|
12779
12779
|
const at = n.get(Y.depthTexture).__webglTexture, dt = Ct(Y);
|
|
12780
12780
|
if (Y.depthTexture.format === cl)
|
|
12781
|
-
|
|
12782
|
-
else if (Y.depthTexture.format ===
|
|
12783
|
-
|
|
12781
|
+
mt(Y) ? o.framebufferTexture2DMultisampleEXT(i.FRAMEBUFFER, i.DEPTH_ATTACHMENT, i.TEXTURE_2D, at, 0, dt) : i.framebufferTexture2D(i.FRAMEBUFFER, i.DEPTH_ATTACHMENT, i.TEXTURE_2D, at, 0);
|
|
12782
|
+
else if (Y.depthTexture.format === Xs)
|
|
12783
|
+
mt(Y) ? o.framebufferTexture2DMultisampleEXT(i.FRAMEBUFFER, i.DEPTH_STENCIL_ATTACHMENT, i.TEXTURE_2D, at, 0, dt) : i.framebufferTexture2D(i.FRAMEBUFFER, i.DEPTH_STENCIL_ATTACHMENT, i.TEXTURE_2D, at, 0);
|
|
12784
12784
|
else
|
|
12785
12785
|
throw new Error("Unknown depthTexture format");
|
|
12786
12786
|
}
|
|
@@ -12804,8 +12804,8 @@ function sY(i, t, e, n, s, l, a) {
|
|
|
12804
12804
|
function qt(F) {
|
|
12805
12805
|
const Y = F.texture, D = n.get(F), at = n.get(Y);
|
|
12806
12806
|
F.addEventListener("dispose", f);
|
|
12807
|
-
const dt = F.textures,
|
|
12808
|
-
if (Kt || (at.__webglTexture === void 0 && (at.__webglTexture = i.createTexture()), at.__version = Y.version, a.memory.textures++),
|
|
12807
|
+
const dt = F.textures, bt = F.isWebGLCubeRenderTarget === !0, Kt = dt.length > 1;
|
|
12808
|
+
if (Kt || (at.__webglTexture === void 0 && (at.__webglTexture = i.createTexture()), at.__version = Y.version, a.memory.textures++), bt) {
|
|
12809
12809
|
D.__webglFramebuffer = [];
|
|
12810
12810
|
for (let vt = 0; vt < 6; vt++)
|
|
12811
12811
|
if (Y.mipmaps && Y.mipmaps.length > 0) {
|
|
@@ -12826,7 +12826,7 @@ function sY(i, t, e, n, s, l, a) {
|
|
|
12826
12826
|
const At = n.get(dt[vt]);
|
|
12827
12827
|
At.__webglTexture === void 0 && (At.__webglTexture = i.createTexture(), a.memory.textures++);
|
|
12828
12828
|
}
|
|
12829
|
-
if (F.samples > 0 &&
|
|
12829
|
+
if (F.samples > 0 && mt(F) === !1) {
|
|
12830
12830
|
D.__webglMultisampledFramebuffer = i.createFramebuffer(), D.__webglColorRenderbuffer = [], e.bindFramebuffer(i.FRAMEBUFFER, D.__webglMultisampledFramebuffer);
|
|
12831
12831
|
for (let vt = 0; vt < dt.length; vt++) {
|
|
12832
12832
|
const kt = dt[vt];
|
|
@@ -12837,7 +12837,7 @@ function sY(i, t, e, n, s, l, a) {
|
|
|
12837
12837
|
i.bindRenderbuffer(i.RENDERBUFFER, null), F.depthBuffer && (D.__webglDepthRenderbuffer = i.createRenderbuffer(), Wt(D.__webglDepthRenderbuffer, F, !0)), e.bindFramebuffer(i.FRAMEBUFFER, null);
|
|
12838
12838
|
}
|
|
12839
12839
|
}
|
|
12840
|
-
if (
|
|
12840
|
+
if (bt) {
|
|
12841
12841
|
e.bindTexture(i.TEXTURE_CUBE_MAP, at.__webglTexture), Vt(i.TEXTURE_CUBE_MAP, Y);
|
|
12842
12842
|
for (let vt = 0; vt < 6; vt++)
|
|
12843
12843
|
if (Y.mipmaps && Y.mipmaps.length > 0)
|
|
@@ -12868,18 +12868,18 @@ function sY(i, t, e, n, s, l, a) {
|
|
|
12868
12868
|
for (let D = 0, at = Y.length; D < at; D++) {
|
|
12869
12869
|
const dt = Y[D];
|
|
12870
12870
|
if (Z(dt)) {
|
|
12871
|
-
const
|
|
12872
|
-
e.bindTexture(
|
|
12871
|
+
const bt = F.isWebGLCubeRenderTarget ? i.TEXTURE_CUBE_MAP : i.TEXTURE_2D, Kt = n.get(dt).__webglTexture;
|
|
12872
|
+
e.bindTexture(bt, Kt), p(bt), e.unbindTexture();
|
|
12873
12873
|
}
|
|
12874
12874
|
}
|
|
12875
12875
|
}
|
|
12876
12876
|
const M = [], ft = [];
|
|
12877
12877
|
function gt(F) {
|
|
12878
12878
|
if (F.samples > 0) {
|
|
12879
|
-
if (
|
|
12879
|
+
if (mt(F) === !1) {
|
|
12880
12880
|
const Y = F.textures, D = F.width, at = F.height;
|
|
12881
12881
|
let dt = i.COLOR_BUFFER_BIT;
|
|
12882
|
-
const
|
|
12882
|
+
const bt = F.stencilBuffer ? i.DEPTH_STENCIL_ATTACHMENT : i.DEPTH_ATTACHMENT, Kt = n.get(F), vt = Y.length > 1;
|
|
12883
12883
|
if (vt)
|
|
12884
12884
|
for (let kt = 0; kt < Y.length; kt++)
|
|
12885
12885
|
e.bindFramebuffer(i.FRAMEBUFFER, Kt.__webglMultisampledFramebuffer), i.framebufferRenderbuffer(i.FRAMEBUFFER, i.COLOR_ATTACHMENT0 + kt, i.RENDERBUFFER, null), e.bindFramebuffer(i.FRAMEBUFFER, Kt.__webglFramebuffer), i.framebufferTexture2D(i.DRAW_FRAMEBUFFER, i.COLOR_ATTACHMENT0 + kt, i.TEXTURE_2D, null, 0);
|
|
@@ -12890,7 +12890,7 @@ function sY(i, t, e, n, s, l, a) {
|
|
|
12890
12890
|
const At = n.get(Y[kt]).__webglTexture;
|
|
12891
12891
|
i.framebufferTexture2D(i.DRAW_FRAMEBUFFER, i.COLOR_ATTACHMENT0, i.TEXTURE_2D, At, 0);
|
|
12892
12892
|
}
|
|
12893
|
-
i.blitFramebuffer(0, 0, D, at, 0, 0, D, at, dt, i.NEAREST), c === !0 && (M.length = 0, ft.length = 0, M.push(i.COLOR_ATTACHMENT0 + kt), F.depthBuffer && F.resolveDepthBuffer === !1 && (M.push(
|
|
12893
|
+
i.blitFramebuffer(0, 0, D, at, 0, 0, D, at, dt, i.NEAREST), c === !0 && (M.length = 0, ft.length = 0, M.push(i.COLOR_ATTACHMENT0 + kt), F.depthBuffer && F.resolveDepthBuffer === !1 && (M.push(bt), ft.push(bt), i.invalidateFramebuffer(i.DRAW_FRAMEBUFFER, ft)), i.invalidateFramebuffer(i.READ_FRAMEBUFFER, M));
|
|
12894
12894
|
}
|
|
12895
12895
|
if (e.bindFramebuffer(i.READ_FRAMEBUFFER, null), e.bindFramebuffer(i.DRAW_FRAMEBUFFER, null), vt)
|
|
12896
12896
|
for (let kt = 0; kt < Y.length; kt++) {
|
|
@@ -12908,7 +12908,7 @@ function sY(i, t, e, n, s, l, a) {
|
|
|
12908
12908
|
function Ct(F) {
|
|
12909
12909
|
return Math.min(s.maxSamples, F.samples);
|
|
12910
12910
|
}
|
|
12911
|
-
function
|
|
12911
|
+
function mt(F) {
|
|
12912
12912
|
const Y = n.get(F);
|
|
12913
12913
|
return F.samples > 0 && t.has("WEBGL_multisampled_render_to_texture") === !0 && Y.__useRenderToTexture !== !1;
|
|
12914
12914
|
}
|
|
@@ -12923,7 +12923,7 @@ function sY(i, t, e, n, s, l, a) {
|
|
|
12923
12923
|
function ot(F) {
|
|
12924
12924
|
return typeof HTMLImageElement != "undefined" && F instanceof HTMLImageElement ? (d.width = F.naturalWidth || F.width, d.height = F.naturalHeight || F.height) : typeof VideoFrame != "undefined" && F instanceof VideoFrame ? (d.width = F.displayWidth, d.height = F.displayHeight) : (d.width = F.width, d.height = F.height), d;
|
|
12925
12925
|
}
|
|
12926
|
-
this.allocateTextureUnit = k, this.resetTextureUnits = v, this.setTexture2D = K, this.setTexture2DArray = H, this.setTexture3D = z, this.setTextureCube = E, this.rebindTextures = se, this.setupRenderTarget = qt, this.updateRenderTargetMipmap = he, this.updateMultisampleRenderTarget = gt, this.setupDepthRenderbuffer = Qt, this.setupFrameBufferTexture = Xt, this.useMultisampledRTT =
|
|
12926
|
+
this.allocateTextureUnit = k, this.resetTextureUnits = v, this.setTexture2D = K, this.setTexture2DArray = H, this.setTexture3D = z, this.setTextureCube = E, this.rebindTextures = se, this.setupRenderTarget = qt, this.updateRenderTargetMipmap = he, this.updateMultisampleRenderTarget = gt, this.setupDepthRenderbuffer = Qt, this.setupFrameBufferTexture = Xt, this.useMultisampledRTT = mt;
|
|
12927
12927
|
}
|
|
12928
12928
|
function zy(i, t) {
|
|
12929
12929
|
function e(n, s = dn) {
|
|
@@ -12946,7 +12946,7 @@ function zy(i, t) {
|
|
|
12946
12946
|
if (n === w2) return i.LUMINANCE;
|
|
12947
12947
|
if (n === K2) return i.LUMINANCE_ALPHA;
|
|
12948
12948
|
if (n === cl) return i.DEPTH_COMPONENT;
|
|
12949
|
-
if (n ===
|
|
12949
|
+
if (n === Xs) return i.DEPTH_STENCIL;
|
|
12950
12950
|
if (n === vc) return i.RED;
|
|
12951
12951
|
if (n === Tc) return i.RED_INTEGER;
|
|
12952
12952
|
if (n === k2) return i.RG;
|
|
@@ -13015,7 +13015,7 @@ function zy(i, t) {
|
|
|
13015
13015
|
if (n === xh) return l.COMPRESSED_SIGNED_RED_GREEN_RGTC2_EXT;
|
|
13016
13016
|
} else
|
|
13017
13017
|
return null;
|
|
13018
|
-
return n ===
|
|
13018
|
+
return n === Gs ? i.UNSIGNED_INT_24_8 : i[n] !== void 0 ? i[n] : null;
|
|
13019
13019
|
}
|
|
13020
13020
|
return { convert: e };
|
|
13021
13021
|
}
|
|
@@ -13208,7 +13208,7 @@ class dY extends Fn {
|
|
|
13208
13208
|
}, this.getSession = function() {
|
|
13209
13209
|
return s;
|
|
13210
13210
|
}, this.setSession = function(st) {
|
|
13211
|
-
return
|
|
13211
|
+
return ht(this, null, function* () {
|
|
13212
13212
|
if (s = st, s !== null) {
|
|
13213
13213
|
if (p = t.getRenderTarget(), s.addEventListener("select", w), s.addEventListener("selectstart", w), s.addEventListener("selectend", w), s.addEventListener("squeeze", w), s.addEventListener("squeezestart", w), s.addEventListener("squeezeend", w), s.addEventListener("end", K), s.addEventListener("inputsourceschange", H), Z.xrCompatible !== !0 && (yield e.makeXRCompatible()), f = t.getPixelRatio(), t.getSize(g), s.renderState.layers === void 0) {
|
|
13214
13214
|
const Xt = {
|
|
@@ -13230,7 +13230,7 @@ class dY extends Fn {
|
|
|
13230
13230
|
);
|
|
13231
13231
|
} else {
|
|
13232
13232
|
let Xt = null, Wt = null, St = null;
|
|
13233
|
-
Z.depth && (St = Z.stencil ? e.DEPTH24_STENCIL8 : e.DEPTH_COMPONENT24, Xt = Z.stencil ?
|
|
13233
|
+
Z.depth && (St = Z.stencil ? e.DEPTH24_STENCIL8 : e.DEPTH_COMPONENT24, Xt = Z.stencil ? Xs : cl, Wt = Z.stencil ? Gs : Xi);
|
|
13234
13234
|
const Qt = {
|
|
13235
13235
|
colorFormat: e.RGBA8,
|
|
13236
13236
|
depthFormat: St,
|
|
@@ -13285,10 +13285,10 @@ class dY extends Fn {
|
|
|
13285
13285
|
const z = new N(), E = new N();
|
|
13286
13286
|
function Q(st, Xt, Wt) {
|
|
13287
13287
|
z.setFromMatrixPosition(Xt.matrixWorld), E.setFromMatrixPosition(Wt.matrixWorld);
|
|
13288
|
-
const St = z.distanceTo(E), Qt = Xt.projectionMatrix.elements, se = Wt.projectionMatrix.elements, qt = Qt[14] / (Qt[10] - 1), he = Qt[14] / (Qt[10] + 1), M = (Qt[9] + 1) / Qt[5], ft = (Qt[9] - 1) / Qt[5], gt = (Qt[8] - 1) / Qt[0], Ct = (se[8] + 1) / se[0],
|
|
13288
|
+
const St = z.distanceTo(E), Qt = Xt.projectionMatrix.elements, se = Wt.projectionMatrix.elements, qt = Qt[14] / (Qt[10] - 1), he = Qt[14] / (Qt[10] + 1), M = (Qt[9] + 1) / Qt[5], ft = (Qt[9] - 1) / Qt[5], gt = (Qt[8] - 1) / Qt[0], Ct = (se[8] + 1) / se[0], mt = qt * gt, rt = qt * Ct, nt = St / (-gt + Ct), ot = nt * -gt;
|
|
13289
13289
|
Xt.matrixWorld.decompose(st.position, st.quaternion, st.scale), st.translateX(ot), st.translateZ(nt), st.matrixWorld.compose(st.position, st.quaternion, st.scale), st.matrixWorldInverse.copy(st.matrixWorld).invert();
|
|
13290
|
-
const F = qt + nt, Y = he + nt, D =
|
|
13291
|
-
st.projectionMatrix.makePerspective(D, at, dt,
|
|
13290
|
+
const F = qt + nt, Y = he + nt, D = mt - ot, at = rt + (St - ot), dt = M * he / Y * F, bt = ft * he / Y * F;
|
|
13291
|
+
st.projectionMatrix.makePerspective(D, at, dt, bt, F, Y), st.projectionMatrixInverse.copy(st.projectionMatrix).invert();
|
|
13292
13292
|
}
|
|
13293
13293
|
function et(st, Xt) {
|
|
13294
13294
|
Xt === null ? st.matrixWorld.copy(st.matrix) : st.matrixWorld.multiplyMatrices(Xt.matrixWorld, st.matrix), st.matrixWorldInverse.copy(st.matrixWorld).invert();
|
|
@@ -13362,7 +13362,7 @@ class dY extends Fn {
|
|
|
13362
13362
|
};
|
|
13363
13363
|
}
|
|
13364
13364
|
}
|
|
13365
|
-
const
|
|
13365
|
+
const Hs = /* @__PURE__ */ new E0(), rY = /* @__PURE__ */ new Pt();
|
|
13366
13366
|
function hY(i, t) {
|
|
13367
13367
|
function e(Z, p) {
|
|
13368
13368
|
Z.matrixAutoUpdate === !0 && Z.updateMatrix(), p.value.copy(Z.matrix);
|
|
@@ -13376,7 +13376,7 @@ function hY(i, t) {
|
|
|
13376
13376
|
function l(Z, p) {
|
|
13377
13377
|
Z.opacity.value = p.opacity, p.color && Z.diffuse.value.copy(p.color), p.emissive && Z.emissive.value.copy(p.emissive).multiplyScalar(p.emissiveIntensity), p.map && (Z.map.value = p.map, e(p.map, Z.mapTransform)), p.alphaMap && (Z.alphaMap.value = p.alphaMap, e(p.alphaMap, Z.alphaMapTransform)), p.bumpMap && (Z.bumpMap.value = p.bumpMap, e(p.bumpMap, Z.bumpMapTransform), Z.bumpScale.value = p.bumpScale, p.side === y0 && (Z.bumpScale.value *= -1)), p.normalMap && (Z.normalMap.value = p.normalMap, e(p.normalMap, Z.normalMapTransform), Z.normalScale.value.copy(p.normalScale), p.side === y0 && Z.normalScale.value.negate()), p.displacementMap && (Z.displacementMap.value = p.displacementMap, e(p.displacementMap, Z.displacementMapTransform), Z.displacementScale.value = p.displacementScale, Z.displacementBias.value = p.displacementBias), p.emissiveMap && (Z.emissiveMap.value = p.emissiveMap, e(p.emissiveMap, Z.emissiveMapTransform)), p.specularMap && (Z.specularMap.value = p.specularMap, e(p.specularMap, Z.specularMapTransform)), p.alphaTest > 0 && (Z.alphaTest.value = p.alphaTest);
|
|
13378
13378
|
const X = t.get(p), y = X.envMap, W = X.envMapRotation;
|
|
13379
|
-
y && (Z.envMap.value = y,
|
|
13379
|
+
y && (Z.envMap.value = y, Hs.copy(W), Hs.x *= -1, Hs.y *= -1, Hs.z *= -1, y.isCubeTexture && y.isRenderTargetTexture === !1 && (Hs.y *= -1, Hs.z *= -1), Z.envMapRotation.value.setFromMatrix4(rY.makeRotationFromEuler(Hs)), Z.flipEnvMap.value = y.isCubeTexture && y.isRenderTargetTexture === !1 ? -1 : 1, Z.reflectivity.value = p.reflectivity, Z.ior.value = p.ior, Z.refractionRatio.value = p.refractionRatio), p.lightMap && (Z.lightMap.value = p.lightMap, Z.lightMapIntensity.value = p.lightMapIntensity, e(p.lightMap, Z.lightMapTransform)), p.aoMap && (Z.aoMap.value = p.aoMap, Z.aoMapIntensity.value = p.aoMapIntensity, e(p.aoMap, Z.aoMapTransform));
|
|
13380
13380
|
}
|
|
13381
13381
|
function a(Z, p) {
|
|
13382
13382
|
Z.diffuse.value.copy(p.color), Z.opacity.value = p.opacity, p.map && (Z.map.value = p.map, e(p.map, Z.mapTransform));
|
|
@@ -13593,9 +13593,9 @@ class By {
|
|
|
13593
13593
|
} catch (T) {
|
|
13594
13594
|
throw console.error("THREE.WebGLRenderer: " + T.message), T;
|
|
13595
13595
|
}
|
|
13596
|
-
let gt, Ct,
|
|
13596
|
+
let gt, Ct, mt, rt, nt, ot, F, Y, D, at, dt, bt, Kt, vt, kt, At, xt, zt, Xe, Et, Ht, te, $t, Ve;
|
|
13597
13597
|
function B() {
|
|
13598
|
-
gt = new WL(M), gt.init(), te = new zy(M, gt), Ct = new pL(M, gt, t, te),
|
|
13598
|
+
gt = new WL(M), gt.init(), te = new zy(M, gt), Ct = new pL(M, gt, t, te), mt = new qC(M), rt = new fL(M), nt = new kC(), ot = new sY(M, gt, mt, nt, Ct, te, rt), F = new ZL(y), Y = new yL(y), D = new Ix(M), $t = new uL(M, D), at = new VL(M, D, rt, $t), dt = new xL(M, at, D, rt), Xe = new RL(M, Ct, ot), At = new bL(nt), bt = new KC(y, F, Y, gt, Ct, $t, At), Kt = new hY(y, nt), vt = new UC(), kt = new AC(gt), zt = new hL(y, F, Y, mt, dt, u, c), xt = new _C(y, dt, Ct), Ve = new uY(M, rt, Ct, mt), Et = new mL(M, gt, rt), Ht = new gL(M, gt, rt), rt.programs = bt.programs, y.capabilities = Ct, y.extensions = gt, y.properties = nt, y.renderLists = vt, y.shadowMap = xt, y.state = mt, y.info = rt;
|
|
13599
13599
|
}
|
|
13600
13600
|
B();
|
|
13601
13601
|
const Yt = new dY(y, M);
|
|
@@ -13630,15 +13630,15 @@ class By {
|
|
|
13630
13630
|
}, this.getViewport = function(T) {
|
|
13631
13631
|
return T.copy(yt);
|
|
13632
13632
|
}, this.setViewport = function(T, j, V, x) {
|
|
13633
|
-
T.isVector4 ? yt.set(T.x, T.y, T.z, T.w) : yt.set(T, j, V, x),
|
|
13633
|
+
T.isVector4 ? yt.set(T.x, T.y, T.z, T.w) : yt.set(T, j, V, x), mt.viewport(R.copy(yt).multiplyScalar(E).round());
|
|
13634
13634
|
}, this.getScissor = function(T) {
|
|
13635
13635
|
return T.copy(Vt);
|
|
13636
13636
|
}, this.setScissor = function(T, j, V, x) {
|
|
13637
|
-
T.isVector4 ? Vt.set(T.x, T.y, T.z, T.w) : Vt.set(T, j, V, x),
|
|
13637
|
+
T.isVector4 ? Vt.set(T.x, T.y, T.z, T.w) : Vt.set(T, j, V, x), mt.scissor(v.copy(Vt).multiplyScalar(E).round());
|
|
13638
13638
|
}, this.getScissorTest = function() {
|
|
13639
13639
|
return Ut;
|
|
13640
13640
|
}, this.setScissorTest = function(T) {
|
|
13641
|
-
|
|
13641
|
+
mt.setScissorTest(Ut = T);
|
|
13642
13642
|
}, this.setOpaqueSort = function(T) {
|
|
13643
13643
|
Q = T;
|
|
13644
13644
|
}, this.setTransparentSort = function(T) {
|
|
@@ -13660,7 +13660,7 @@ class By {
|
|
|
13660
13660
|
C = J === vu || J === Nu || J === Tc;
|
|
13661
13661
|
}
|
|
13662
13662
|
if (C) {
|
|
13663
|
-
const J = L.texture.type, P = J === L0 || J === Xi || J === xa || J ===
|
|
13663
|
+
const J = L.texture.type, P = J === L0 || J === Xi || J === xa || J === Gs || J === Yu || J === Iu, U = zt.getClearColor(), q = zt.getClearAlpha(), ct = U.r, tt = U.g, $ = U.b;
|
|
13664
13664
|
P ? (m[0] = ct, m[1] = tt, m[2] = $, m[3] = q, M.clearBufferuiv(M.COLOR, 0, m)) : (b[0] = ct, b[1] = tt, b[2] = $, b[3] = q, M.clearBufferiv(M.COLOR, 0, b));
|
|
13665
13665
|
} else
|
|
13666
13666
|
x |= M.COLOR_BUFFER_BIT;
|
|
@@ -13673,7 +13673,7 @@ class By {
|
|
|
13673
13673
|
}, this.clearStencil = function() {
|
|
13674
13674
|
this.clear(!1, !1, !0);
|
|
13675
13675
|
}, this.dispose = function() {
|
|
13676
|
-
e.removeEventListener("webglcontextlost", O, !1), e.removeEventListener("webglcontextrestored", Zt, !1), e.removeEventListener("webglcontextcreationerror", Mt, !1), vt.dispose(), kt.dispose(), nt.dispose(), F.dispose(), Y.dispose(), dt.dispose(), $t.dispose(), Ve.dispose(),
|
|
13676
|
+
e.removeEventListener("webglcontextlost", O, !1), e.removeEventListener("webglcontextrestored", Zt, !1), e.removeEventListener("webglcontextcreationerror", Mt, !1), vt.dispose(), kt.dispose(), nt.dispose(), F.dispose(), Y.dispose(), dt.dispose(), $t.dispose(), Ve.dispose(), bt.dispose(), Yt.dispose(), Yt.removeEventListener("sessionstart", Ln), Yt.removeEventListener("sessionend", od), Vi.stop();
|
|
13677
13677
|
};
|
|
13678
13678
|
function O(T) {
|
|
13679
13679
|
T.preventDefault(), console.log("THREE.WebGLRenderer: Context Lost."), W = !0;
|
|
@@ -13696,13 +13696,13 @@ class By {
|
|
|
13696
13696
|
function m0(T) {
|
|
13697
13697
|
const j = nt.get(T).programs;
|
|
13698
13698
|
j !== void 0 && (j.forEach(function(V) {
|
|
13699
|
-
|
|
13700
|
-
}), T.isShaderMaterial &&
|
|
13699
|
+
bt.releaseProgram(V);
|
|
13700
|
+
}), T.isShaderMaterial && bt.releaseShaderCache(T));
|
|
13701
13701
|
}
|
|
13702
13702
|
this.renderBufferDirect = function(T, j, V, x, C, J) {
|
|
13703
13703
|
j === null && (j = se);
|
|
13704
13704
|
const P = C.isMesh && C.matrixWorld.determinant() < 0, U = md(T, j, V, x, C);
|
|
13705
|
-
|
|
13705
|
+
mt.setMaterial(x, P);
|
|
13706
13706
|
let q = V.index, ct = 1;
|
|
13707
13707
|
if (x.wireframe === !0) {
|
|
13708
13708
|
if (q = at.getWireframeAttribute(V), q === void 0) return;
|
|
@@ -13716,10 +13716,10 @@ class By {
|
|
|
13716
13716
|
$t.setup(C, x, U, V, q);
|
|
13717
13717
|
let Ft, Nt = Et;
|
|
13718
13718
|
if (q !== null && (Ft = D.get(q), Nt = Ht, Nt.setIndex(Ft)), C.isMesh)
|
|
13719
|
-
x.wireframe === !0 ? (
|
|
13719
|
+
x.wireframe === !0 ? (mt.setLineWidth(x.wireframeLinewidth * he()), Nt.setMode(M.LINES)) : Nt.setMode(M.TRIANGLES);
|
|
13720
13720
|
else if (C.isLine) {
|
|
13721
|
-
let
|
|
13722
|
-
|
|
13721
|
+
let pt = x.linewidth;
|
|
13722
|
+
pt === void 0 && (pt = 1), mt.setLineWidth(pt * he()), C.isLineSegments ? Nt.setMode(M.LINES) : C.isLineLoop ? Nt.setMode(M.LINE_LOOP) : Nt.setMode(M.LINE_STRIP);
|
|
13723
13723
|
} else C.isPoints ? Nt.setMode(M.POINTS) : C.isSprite && Nt.setMode(M.TRIANGLES);
|
|
13724
13724
|
if (C.isBatchedMesh)
|
|
13725
13725
|
if (C._multiDrawInstances !== null)
|
|
@@ -13727,14 +13727,14 @@ class By {
|
|
|
13727
13727
|
else if (gt.get("WEBGL_multi_draw"))
|
|
13728
13728
|
Nt.renderMultiDraw(C._multiDrawStarts, C._multiDrawCounts, C._multiDrawCount);
|
|
13729
13729
|
else {
|
|
13730
|
-
const
|
|
13730
|
+
const pt = C._multiDrawStarts, Jt = C._multiDrawCounts, wt = C._multiDrawCount, Ze = q ? D.get(q).bytesPerElement : 1, we = nt.get(x).currentProgram.getUniforms();
|
|
13731
13731
|
for (let De = 0; De < wt; De++)
|
|
13732
|
-
we.setValue(M, "_gl_DrawID", De), Nt.render(
|
|
13732
|
+
we.setValue(M, "_gl_DrawID", De), Nt.render(pt[De] / Ze, Jt[De]);
|
|
13733
13733
|
}
|
|
13734
13734
|
else if (C.isInstancedMesh)
|
|
13735
13735
|
Nt.renderInstances(it, Lt, C.count);
|
|
13736
13736
|
else if (V.isInstancedBufferGeometry) {
|
|
13737
|
-
const
|
|
13737
|
+
const pt = V._maxInstanceCount !== void 0 ? V._maxInstanceCount : 1 / 0, Jt = Math.min(V.instanceCount, pt);
|
|
13738
13738
|
Nt.renderInstances(it, Lt, Jt);
|
|
13739
13739
|
} else
|
|
13740
13740
|
Nt.render(it, Lt);
|
|
@@ -13850,7 +13850,7 @@ class By {
|
|
|
13850
13850
|
}
|
|
13851
13851
|
function cd(T, j, V, x) {
|
|
13852
13852
|
const C = T.opaque, J = T.transmissive, P = T.transparent;
|
|
13853
|
-
Z.setupLightsView(V), st === !0 && At.setGlobalState(y.clippingPlanes, V), x &&
|
|
13853
|
+
Z.setupLightsView(V), st === !0 && At.setGlobalState(y.clippingPlanes, V), x && mt.viewport(R.copy(x)), C.length > 0 && Cs(C, j, V), J.length > 0 && Cs(J, j, V), P.length > 0 && Cs(P, j, V), mt.buffers.depth.setTest(!0), mt.buffers.depth.setMask(!0), mt.buffers.color.setMask(!0), mt.setPolygonOffset(!1);
|
|
13854
13854
|
}
|
|
13855
13855
|
function dd(T, j, V, x) {
|
|
13856
13856
|
if ((V.isScene === !0 ? V.overrideMaterial : null) !== null)
|
|
@@ -13872,20 +13872,20 @@ class By {
|
|
|
13872
13872
|
const q = y.toneMapping;
|
|
13873
13873
|
y.toneMapping = Hi;
|
|
13874
13874
|
const ct = x.viewport;
|
|
13875
|
-
if (x.viewport !== void 0 && (x.viewport = void 0), Z.setupLightsView(x), st === !0 && At.setGlobalState(y.clippingPlanes, x),
|
|
13875
|
+
if (x.viewport !== void 0 && (x.viewport = void 0), Z.setupLightsView(x), st === !0 && At.setGlobalState(y.clippingPlanes, x), Cs(T, V, x), ot.updateMultisampleRenderTarget(J), ot.updateRenderTargetMipmap(J), gt.has("WEBGL_multisampled_render_to_texture") === !1) {
|
|
13876
13876
|
let tt = !1;
|
|
13877
13877
|
for (let $ = 0, it = j.length; $ < it; $++) {
|
|
13878
|
-
const Rt = j[$], Lt = Rt.object, Ft = Rt.geometry, Nt = Rt.material,
|
|
13878
|
+
const Rt = j[$], Lt = Rt.object, Ft = Rt.geometry, Nt = Rt.material, pt = Rt.group;
|
|
13879
13879
|
if (Nt.side === He && Lt.layers.test(x.layers)) {
|
|
13880
13880
|
const Jt = Nt.side;
|
|
13881
|
-
Nt.side = y0, Nt.needsUpdate = !0, rd(Lt, V, x, Ft, Nt,
|
|
13881
|
+
Nt.side = y0, Nt.needsUpdate = !0, rd(Lt, V, x, Ft, Nt, pt), Nt.side = Jt, Nt.needsUpdate = !0, tt = !0;
|
|
13882
13882
|
}
|
|
13883
13883
|
}
|
|
13884
13884
|
tt === !0 && (ot.updateMultisampleRenderTarget(J), ot.updateRenderTargetMipmap(J));
|
|
13885
13885
|
}
|
|
13886
13886
|
y.setRenderTarget(U), y.setClearColor(w, K), ct !== void 0 && (x.viewport = ct), y.toneMapping = q;
|
|
13887
13887
|
}
|
|
13888
|
-
function
|
|
13888
|
+
function Cs(T, j, V) {
|
|
13889
13889
|
const x = j.isScene === !0 ? j.overrideMaterial : null;
|
|
13890
13890
|
for (let C = 0, J = T.length; C < J; C++) {
|
|
13891
13891
|
const P = T[C], U = P.object, q = P.geometry, ct = x === null ? P.material : x, tt = P.group;
|
|
@@ -13897,7 +13897,7 @@ class By {
|
|
|
13897
13897
|
}
|
|
13898
13898
|
function Cl(T, j, V) {
|
|
13899
13899
|
j.isScene !== !0 && (j = se);
|
|
13900
|
-
const x = nt.get(T), C = Z.state.lights, J = Z.state.shadowsArray, P = C.state.version, U =
|
|
13900
|
+
const x = nt.get(T), C = Z.state.lights, J = Z.state.shadowsArray, P = C.state.version, U = bt.getParameters(T, C.state, J, j, V), q = bt.getProgramCacheKey(U);
|
|
13901
13901
|
let ct = x.programs;
|
|
13902
13902
|
x.environment = T.isMeshStandardMaterial ? j.environment : null, x.fog = j.fog, x.envMap = (T.isMeshStandardMaterial ? Y : F).get(T.envMap || x.environment), x.envMapRotation = x.environment !== null && T.envMap === null ? j.environmentRotation : T.envMapRotation, ct === void 0 && (T.addEventListener("dispose", ee), ct = /* @__PURE__ */ new Map(), x.programs = ct);
|
|
13903
13903
|
let tt = ct.get(q);
|
|
@@ -13905,7 +13905,7 @@ class By {
|
|
|
13905
13905
|
if (x.currentProgram === tt && x.lightsStateVersion === P)
|
|
13906
13906
|
return ud(T, U), tt;
|
|
13907
13907
|
} else
|
|
13908
|
-
U.uniforms =
|
|
13908
|
+
U.uniforms = bt.getUniforms(T), T.onBeforeCompile(U, y), tt = bt.acquireProgram(U, q), ct.set(q, tt), x.uniforms = U.uniforms;
|
|
13909
13909
|
const $ = x.uniforms;
|
|
13910
13910
|
return (!T.isShaderMaterial && !T.isRawShaderMaterial || T.clipping === !0) && ($.clippingPlanes = At.uniform), ud(T, U), x.needsLights = Zm(T), x.lightsStateVersion = P, x.needsLights && ($.ambientLightColor.value = C.state.ambient, $.lightProbe.value = C.state.probe, $.directionalLights.value = C.state.directional, $.directionalLightShadows.value = C.state.directionalShadow, $.spotLights.value = C.state.spot, $.spotLightShadows.value = C.state.spotShadow, $.rectAreaLights.value = C.state.rectArea, $.ltc_1.value = C.state.rectAreaLTC1, $.ltc_2.value = C.state.rectAreaLTC2, $.pointLights.value = C.state.point, $.pointLightShadows.value = C.state.pointShadow, $.hemisphereLights.value = C.state.hemi, $.directionalShadowMap.value = C.state.directionalShadowMap, $.directionalShadowMatrix.value = C.state.directionalShadowMatrix, $.spotShadowMap.value = C.state.spotShadowMap, $.spotLightMatrix.value = C.state.spotLightMatrix, $.spotLightMap.value = C.state.spotLightMap, $.pointShadowMap.value = C.state.pointShadowMap, $.pointShadowMatrix.value = C.state.pointShadowMatrix), x.currentProgram = tt, x.uniformsList = null, tt;
|
|
13911
13911
|
}
|
|
@@ -13925,18 +13925,18 @@ class By {
|
|
|
13925
13925
|
const J = j.fog, P = x.isMeshStandardMaterial ? j.environment : null, U = L === null ? y.outputColorSpace : L.isXRRenderTarget === !0 ? L.texture.colorSpace : u0, q = (x.isMeshStandardMaterial ? Y : F).get(x.envMap || P), ct = x.vertexColors === !0 && !!V.attributes.color && V.attributes.color.itemSize === 4, tt = !!V.attributes.tangent && (!!x.normalMap || x.anisotropy > 0), $ = !!V.morphAttributes.position, it = !!V.morphAttributes.normal, Rt = !!V.morphAttributes.color;
|
|
13926
13926
|
let Lt = Hi;
|
|
13927
13927
|
x.toneMapped && (L === null || L.isXRRenderTarget === !0) && (Lt = y.toneMapping);
|
|
13928
|
-
const Ft = V.morphAttributes.position || V.morphAttributes.normal || V.morphAttributes.color, Nt = Ft !== void 0 ? Ft.length : 0,
|
|
13928
|
+
const Ft = V.morphAttributes.position || V.morphAttributes.normal || V.morphAttributes.color, Nt = Ft !== void 0 ? Ft.length : 0, pt = nt.get(x), Jt = Z.state.lights;
|
|
13929
13929
|
if (st === !0 && (Xt === !0 || T !== S)) {
|
|
13930
13930
|
const Fe = T === S && x.id === I;
|
|
13931
13931
|
At.setState(x, T, Fe);
|
|
13932
13932
|
}
|
|
13933
13933
|
let wt = !1;
|
|
13934
|
-
x.version ===
|
|
13935
|
-
let Ze =
|
|
13934
|
+
x.version === pt.__version ? (pt.needsLights && pt.lightsStateVersion !== Jt.state.version || pt.outputColorSpace !== U || C.isBatchedMesh && pt.batching === !1 || !C.isBatchedMesh && pt.batching === !0 || C.isBatchedMesh && pt.batchingColor === !0 && C.colorTexture === null || C.isBatchedMesh && pt.batchingColor === !1 && C.colorTexture !== null || C.isInstancedMesh && pt.instancing === !1 || !C.isInstancedMesh && pt.instancing === !0 || C.isSkinnedMesh && pt.skinning === !1 || !C.isSkinnedMesh && pt.skinning === !0 || C.isInstancedMesh && pt.instancingColor === !0 && C.instanceColor === null || C.isInstancedMesh && pt.instancingColor === !1 && C.instanceColor !== null || C.isInstancedMesh && pt.instancingMorph === !0 && C.morphTexture === null || C.isInstancedMesh && pt.instancingMorph === !1 && C.morphTexture !== null || pt.envMap !== q || x.fog === !0 && pt.fog !== J || pt.numClippingPlanes !== void 0 && (pt.numClippingPlanes !== At.numPlanes || pt.numIntersection !== At.numIntersection) || pt.vertexAlphas !== ct || pt.vertexTangents !== tt || pt.morphTargets !== $ || pt.morphNormals !== it || pt.morphColors !== Rt || pt.toneMapping !== Lt || pt.morphTargetsCount !== Nt) && (wt = !0) : (wt = !0, pt.__version = x.version);
|
|
13935
|
+
let Ze = pt.currentProgram;
|
|
13936
13936
|
wt === !0 && (Ze = Cl(x, j, C));
|
|
13937
13937
|
let we = !1, De = !1, Ue = !1;
|
|
13938
|
-
const _t = Ze.getUniforms(), Ee =
|
|
13939
|
-
if (
|
|
13938
|
+
const _t = Ze.getUniforms(), Ee = pt.uniforms;
|
|
13939
|
+
if (mt.useProgram(Ze.program) && (we = !0, De = !0, Ue = !0), x.id !== I && (I = x.id, De = !0), we || S !== T) {
|
|
13940
13940
|
_t.setValue(M, "projectionMatrix", T.projectionMatrix), _t.setValue(M, "viewMatrix", T.matrixWorldInverse);
|
|
13941
13941
|
const Fe = _t.map.cameraPosition;
|
|
13942
13942
|
Fe !== void 0 && Fe.setValue(M, St.setFromMatrixPosition(T.matrixWorld)), Ct.logarithmicDepthBuffer && _t.setValue(
|
|
@@ -13952,7 +13952,7 @@ class By {
|
|
|
13952
13952
|
}
|
|
13953
13953
|
C.isBatchedMesh && (_t.setOptional(M, C, "batchingTexture"), _t.setValue(M, "batchingTexture", C._matricesTexture, ot), _t.setOptional(M, C, "batchingIdTexture"), _t.setValue(M, "batchingIdTexture", C._indirectTexture, ot), _t.setOptional(M, C, "batchingColorTexture"), C._colorsTexture !== null && _t.setValue(M, "batchingColorTexture", C._colorsTexture, ot));
|
|
13954
13954
|
const w0 = V.morphAttributes;
|
|
13955
|
-
if ((w0.position !== void 0 || w0.normal !== void 0 || w0.color !== void 0) && Xe.update(C, V, Ze), (De ||
|
|
13955
|
+
if ((w0.position !== void 0 || w0.normal !== void 0 || w0.color !== void 0) && Xe.update(C, V, Ze), (De || pt.receiveShadow !== C.receiveShadow) && (pt.receiveShadow = C.receiveShadow, _t.setValue(M, "receiveShadow", C.receiveShadow)), x.isMeshGouraudMaterial && x.envMap !== null && (Ee.envMap.value = q, Ee.flipEnvMap.value = q.isCubeTexture && q.isRenderTargetTexture === !1 ? -1 : 1), x.isMeshStandardMaterial && x.envMap === null && j.environment !== null && (Ee.envMapIntensity.value = j.environmentIntensity), De && (_t.setValue(M, "toneMappingExposure", y.toneMappingExposure), pt.needsLights && pd(Ee, Ue), J && x.fog === !0 && Kt.refreshFogUniforms(Ee, J), Kt.refreshMaterialUniforms(Ee, x, E, z, Z.state.transmissionRenderTarget[T.id]), Tr.upload(M, hd(pt), Ee, ot)), x.isShaderMaterial && x.uniformsNeedUpdate === !0 && (Tr.upload(M, hd(pt), Ee, ot), x.uniformsNeedUpdate = !1), x.isSpriteMaterial && _t.setValue(M, "center", C.center), _t.setValue(M, "modelViewMatrix", C.modelViewMatrix), _t.setValue(M, "normalMatrix", C.normalMatrix), _t.setValue(M, "modelMatrix", C.matrixWorld), x.isShaderMaterial || x.isRawShaderMaterial) {
|
|
13956
13956
|
const Fe = x.uniformsGroups;
|
|
13957
13957
|
for (let Ye = 0, Qe = Fe.length; Ye < Qe; Ye++) {
|
|
13958
13958
|
const Cn = Fe[Ye];
|
|
@@ -13985,14 +13985,14 @@ class By {
|
|
|
13985
13985
|
let x = !0, C = null, J = !1, P = !1;
|
|
13986
13986
|
if (T) {
|
|
13987
13987
|
const q = nt.get(T);
|
|
13988
|
-
q.__useDefaultFramebuffer !== void 0 ? (
|
|
13988
|
+
q.__useDefaultFramebuffer !== void 0 ? (mt.bindFramebuffer(M.FRAMEBUFFER, null), x = !1) : q.__webglFramebuffer === void 0 ? ot.setupRenderTarget(T) : q.__hasExternalTextures && ot.rebindTextures(T, nt.get(T.texture).__webglTexture, nt.get(T.depthTexture).__webglTexture);
|
|
13989
13989
|
const ct = T.texture;
|
|
13990
13990
|
(ct.isData3DTexture || ct.isDataArrayTexture || ct.isCompressedArrayTexture) && (P = !0);
|
|
13991
13991
|
const tt = nt.get(T).__webglFramebuffer;
|
|
13992
13992
|
T.isWebGLCubeRenderTarget ? (Array.isArray(tt[j]) ? C = tt[j][V] : C = tt[j], J = !0) : T.samples > 0 && ot.useMultisampledRTT(T) === !1 ? C = nt.get(T).__webglMultisampledFramebuffer : Array.isArray(tt) ? C = tt[V] : C = tt, R.copy(T.viewport), v.copy(T.scissor), k = T.scissorTest;
|
|
13993
13993
|
} else
|
|
13994
13994
|
R.copy(yt).multiplyScalar(E).floor(), v.copy(Vt).multiplyScalar(E).floor(), k = Ut;
|
|
13995
|
-
if (
|
|
13995
|
+
if (mt.bindFramebuffer(M.FRAMEBUFFER, C) && x && mt.drawBuffers(T, C), mt.viewport(R), mt.scissor(v), mt.setScissorTest(k), J) {
|
|
13996
13996
|
const q = nt.get(T.texture);
|
|
13997
13997
|
M.framebufferTexture2D(M.FRAMEBUFFER, M.COLOR_ATTACHMENT0, M.TEXTURE_CUBE_MAP_POSITIVE_X + j, q.__webglTexture, V);
|
|
13998
13998
|
} else if (P) {
|
|
@@ -14007,7 +14007,7 @@ class By {
|
|
|
14007
14007
|
}
|
|
14008
14008
|
let U = nt.get(T).__webglFramebuffer;
|
|
14009
14009
|
if (T.isWebGLCubeRenderTarget && P !== void 0 && (U = U[P]), U) {
|
|
14010
|
-
|
|
14010
|
+
mt.bindFramebuffer(M.FRAMEBUFFER, U);
|
|
14011
14011
|
try {
|
|
14012
14012
|
const q = T.texture, ct = q.format, tt = q.type;
|
|
14013
14013
|
if (!Ct.textureFormatReadable(ct)) {
|
|
@@ -14021,16 +14021,16 @@ class By {
|
|
|
14021
14021
|
j >= 0 && j <= T.width - x && V >= 0 && V <= T.height - C && M.readPixels(j, V, x, C, te.convert(ct), te.convert(tt), J);
|
|
14022
14022
|
} finally {
|
|
14023
14023
|
const q = L !== null ? nt.get(L).__webglFramebuffer : null;
|
|
14024
|
-
|
|
14024
|
+
mt.bindFramebuffer(M.FRAMEBUFFER, q);
|
|
14025
14025
|
}
|
|
14026
14026
|
}
|
|
14027
14027
|
}, this.readRenderTargetPixelsAsync = function(T, j, V, x, C, J, P) {
|
|
14028
|
-
return
|
|
14028
|
+
return ht(this, null, function* () {
|
|
14029
14029
|
if (!(T && T.isWebGLRenderTarget))
|
|
14030
14030
|
throw new Error("THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not THREE.WebGLRenderTarget.");
|
|
14031
14031
|
let U = nt.get(T).__webglFramebuffer;
|
|
14032
14032
|
if (T.isWebGLCubeRenderTarget && P !== void 0 && (U = U[P]), U) {
|
|
14033
|
-
|
|
14033
|
+
mt.bindFramebuffer(M.FRAMEBUFFER, U);
|
|
14034
14034
|
try {
|
|
14035
14035
|
const q = T.texture, ct = q.format, tt = q.type;
|
|
14036
14036
|
if (!Ct.textureFormatReadable(ct))
|
|
@@ -14051,46 +14051,46 @@ class By {
|
|
|
14051
14051
|
}
|
|
14052
14052
|
} finally {
|
|
14053
14053
|
const q = L !== null ? nt.get(L).__webglFramebuffer : null;
|
|
14054
|
-
|
|
14054
|
+
mt.bindFramebuffer(M.FRAMEBUFFER, q);
|
|
14055
14055
|
}
|
|
14056
14056
|
}
|
|
14057
14057
|
});
|
|
14058
14058
|
}, this.copyFramebufferToTexture = function(T, j = null, V = 0) {
|
|
14059
14059
|
T.isTexture !== !0 && (console.warn("WebGLRenderer: copyFramebufferToTexture function signature has changed."), j = arguments[0] || null, T = arguments[1]);
|
|
14060
14060
|
const x = Math.pow(2, -V), C = Math.floor(T.image.width * x), J = Math.floor(T.image.height * x), P = j !== null ? j.x : 0, U = j !== null ? j.y : 0;
|
|
14061
|
-
ot.setTexture2D(T, 0), M.copyTexSubImage2D(M.TEXTURE_2D, V, 0, 0, P, U, C, J),
|
|
14061
|
+
ot.setTexture2D(T, 0), M.copyTexSubImage2D(M.TEXTURE_2D, V, 0, 0, P, U, C, J), mt.unbindTexture();
|
|
14062
14062
|
}, this.copyTextureToTexture = function(T, j, V = null, x = null, C = 0) {
|
|
14063
14063
|
T.isTexture !== !0 && (console.warn("WebGLRenderer: copyTextureToTexture function signature has changed."), x = arguments[0] || null, T = arguments[1], j = arguments[2], C = arguments[3] || 0, V = null);
|
|
14064
14064
|
let J, P, U, q, ct, tt;
|
|
14065
14065
|
V !== null ? (J = V.max.x - V.min.x, P = V.max.y - V.min.y, U = V.min.x, q = V.min.y) : (J = T.image.width, P = T.image.height, U = 0, q = 0), x !== null ? (ct = x.x, tt = x.y) : (ct = 0, tt = 0);
|
|
14066
14066
|
const $ = te.convert(j.format), it = te.convert(j.type);
|
|
14067
14067
|
ot.setTexture2D(j, 0), M.pixelStorei(M.UNPACK_FLIP_Y_WEBGL, j.flipY), M.pixelStorei(M.UNPACK_PREMULTIPLY_ALPHA_WEBGL, j.premultiplyAlpha), M.pixelStorei(M.UNPACK_ALIGNMENT, j.unpackAlignment);
|
|
14068
|
-
const Rt = M.getParameter(M.UNPACK_ROW_LENGTH), Lt = M.getParameter(M.UNPACK_IMAGE_HEIGHT), Ft = M.getParameter(M.UNPACK_SKIP_PIXELS), Nt = M.getParameter(M.UNPACK_SKIP_ROWS),
|
|
14069
|
-
M.pixelStorei(M.UNPACK_ROW_LENGTH, Jt.width), M.pixelStorei(M.UNPACK_IMAGE_HEIGHT, Jt.height), M.pixelStorei(M.UNPACK_SKIP_PIXELS, U), M.pixelStorei(M.UNPACK_SKIP_ROWS, q), T.isDataTexture ? M.texSubImage2D(M.TEXTURE_2D, C, ct, tt, J, P, $, it, Jt.data) : T.isCompressedTexture ? M.compressedTexSubImage2D(M.TEXTURE_2D, C, ct, tt, Jt.width, Jt.height, $, Jt.data) : M.texSubImage2D(M.TEXTURE_2D, C, ct, tt, J, P, $, it, Jt), M.pixelStorei(M.UNPACK_ROW_LENGTH, Rt), M.pixelStorei(M.UNPACK_IMAGE_HEIGHT, Lt), M.pixelStorei(M.UNPACK_SKIP_PIXELS, Ft), M.pixelStorei(M.UNPACK_SKIP_ROWS, Nt), M.pixelStorei(M.UNPACK_SKIP_IMAGES,
|
|
14068
|
+
const Rt = M.getParameter(M.UNPACK_ROW_LENGTH), Lt = M.getParameter(M.UNPACK_IMAGE_HEIGHT), Ft = M.getParameter(M.UNPACK_SKIP_PIXELS), Nt = M.getParameter(M.UNPACK_SKIP_ROWS), pt = M.getParameter(M.UNPACK_SKIP_IMAGES), Jt = T.isCompressedTexture ? T.mipmaps[C] : T.image;
|
|
14069
|
+
M.pixelStorei(M.UNPACK_ROW_LENGTH, Jt.width), M.pixelStorei(M.UNPACK_IMAGE_HEIGHT, Jt.height), M.pixelStorei(M.UNPACK_SKIP_PIXELS, U), M.pixelStorei(M.UNPACK_SKIP_ROWS, q), T.isDataTexture ? M.texSubImage2D(M.TEXTURE_2D, C, ct, tt, J, P, $, it, Jt.data) : T.isCompressedTexture ? M.compressedTexSubImage2D(M.TEXTURE_2D, C, ct, tt, Jt.width, Jt.height, $, Jt.data) : M.texSubImage2D(M.TEXTURE_2D, C, ct, tt, J, P, $, it, Jt), M.pixelStorei(M.UNPACK_ROW_LENGTH, Rt), M.pixelStorei(M.UNPACK_IMAGE_HEIGHT, Lt), M.pixelStorei(M.UNPACK_SKIP_PIXELS, Ft), M.pixelStorei(M.UNPACK_SKIP_ROWS, Nt), M.pixelStorei(M.UNPACK_SKIP_IMAGES, pt), C === 0 && j.generateMipmaps && M.generateMipmap(M.TEXTURE_2D), mt.unbindTexture();
|
|
14070
14070
|
}, this.copyTextureToTexture3D = function(T, j, V = null, x = null, C = 0) {
|
|
14071
14071
|
T.isTexture !== !0 && (console.warn("WebGLRenderer: copyTextureToTexture3D function signature has changed."), V = arguments[0] || null, x = arguments[1] || null, T = arguments[2], j = arguments[3], C = arguments[4] || 0);
|
|
14072
14072
|
let J, P, U, q, ct, tt, $, it, Rt;
|
|
14073
14073
|
const Lt = T.isCompressedTexture ? T.mipmaps[C] : T.image;
|
|
14074
14074
|
V !== null ? (J = V.max.x - V.min.x, P = V.max.y - V.min.y, U = V.max.z - V.min.z, q = V.min.x, ct = V.min.y, tt = V.min.z) : (J = Lt.width, P = Lt.height, U = Lt.depth, q = 0, ct = 0, tt = 0), x !== null ? ($ = x.x, it = x.y, Rt = x.z) : ($ = 0, it = 0, Rt = 0);
|
|
14075
14075
|
const Ft = te.convert(j.format), Nt = te.convert(j.type);
|
|
14076
|
-
let
|
|
14076
|
+
let pt;
|
|
14077
14077
|
if (j.isData3DTexture)
|
|
14078
|
-
ot.setTexture3D(j, 0),
|
|
14078
|
+
ot.setTexture3D(j, 0), pt = M.TEXTURE_3D;
|
|
14079
14079
|
else if (j.isDataArrayTexture || j.isCompressedArrayTexture)
|
|
14080
|
-
ot.setTexture2DArray(j, 0),
|
|
14080
|
+
ot.setTexture2DArray(j, 0), pt = M.TEXTURE_2D_ARRAY;
|
|
14081
14081
|
else {
|
|
14082
14082
|
console.warn("THREE.WebGLRenderer.copyTextureToTexture3D: only supports THREE.DataTexture3D and THREE.DataTexture2DArray.");
|
|
14083
14083
|
return;
|
|
14084
14084
|
}
|
|
14085
14085
|
M.pixelStorei(M.UNPACK_FLIP_Y_WEBGL, j.flipY), M.pixelStorei(M.UNPACK_PREMULTIPLY_ALPHA_WEBGL, j.premultiplyAlpha), M.pixelStorei(M.UNPACK_ALIGNMENT, j.unpackAlignment);
|
|
14086
14086
|
const Jt = M.getParameter(M.UNPACK_ROW_LENGTH), wt = M.getParameter(M.UNPACK_IMAGE_HEIGHT), Ze = M.getParameter(M.UNPACK_SKIP_PIXELS), we = M.getParameter(M.UNPACK_SKIP_ROWS), De = M.getParameter(M.UNPACK_SKIP_IMAGES);
|
|
14087
|
-
M.pixelStorei(M.UNPACK_ROW_LENGTH, Lt.width), M.pixelStorei(M.UNPACK_IMAGE_HEIGHT, Lt.height), M.pixelStorei(M.UNPACK_SKIP_PIXELS, q), M.pixelStorei(M.UNPACK_SKIP_ROWS, ct), M.pixelStorei(M.UNPACK_SKIP_IMAGES, tt), T.isDataTexture || T.isData3DTexture ? M.texSubImage3D(
|
|
14087
|
+
M.pixelStorei(M.UNPACK_ROW_LENGTH, Lt.width), M.pixelStorei(M.UNPACK_IMAGE_HEIGHT, Lt.height), M.pixelStorei(M.UNPACK_SKIP_PIXELS, q), M.pixelStorei(M.UNPACK_SKIP_ROWS, ct), M.pixelStorei(M.UNPACK_SKIP_IMAGES, tt), T.isDataTexture || T.isData3DTexture ? M.texSubImage3D(pt, C, $, it, Rt, J, P, U, Ft, Nt, Lt.data) : j.isCompressedArrayTexture ? M.compressedTexSubImage3D(pt, C, $, it, Rt, J, P, U, Ft, Lt.data) : M.texSubImage3D(pt, C, $, it, Rt, J, P, U, Ft, Nt, Lt), M.pixelStorei(M.UNPACK_ROW_LENGTH, Jt), M.pixelStorei(M.UNPACK_IMAGE_HEIGHT, wt), M.pixelStorei(M.UNPACK_SKIP_PIXELS, Ze), M.pixelStorei(M.UNPACK_SKIP_ROWS, we), M.pixelStorei(M.UNPACK_SKIP_IMAGES, De), C === 0 && j.generateMipmaps && M.generateMipmap(pt), mt.unbindTexture();
|
|
14088
14088
|
}, this.initRenderTarget = function(T) {
|
|
14089
14089
|
nt.get(T).__webglFramebuffer === void 0 && ot.setupRenderTarget(T);
|
|
14090
14090
|
}, this.initTexture = function(T) {
|
|
14091
|
-
T.isCubeTexture ? ot.setTextureCube(T, 0) : T.isData3DTexture ? ot.setTexture3D(T, 0) : T.isDataArrayTexture || T.isCompressedArrayTexture ? ot.setTexture2DArray(T, 0) : ot.setTexture2D(T, 0),
|
|
14091
|
+
T.isCubeTexture ? ot.setTextureCube(T, 0) : T.isData3DTexture ? ot.setTexture3D(T, 0) : T.isDataArrayTexture || T.isCompressedArrayTexture ? ot.setTexture2DArray(T, 0) : ot.setTexture2D(T, 0), mt.unbindTexture();
|
|
14092
14092
|
}, this.resetState = function() {
|
|
14093
|
-
g = 0, f = 0, L = null,
|
|
14093
|
+
g = 0, f = 0, L = null, mt.reset(), $t.reset();
|
|
14094
14094
|
}, typeof __THREE_DEVTOOLS__ != "undefined" && __THREE_DEVTOOLS__.dispatchEvent(new CustomEvent("observe", { detail: this }));
|
|
14095
14095
|
}
|
|
14096
14096
|
get coordinateSystem() {
|
|
@@ -14201,7 +14201,7 @@ class Kc {
|
|
|
14201
14201
|
}
|
|
14202
14202
|
}
|
|
14203
14203
|
const j0 = /* @__PURE__ */ new N();
|
|
14204
|
-
class
|
|
14204
|
+
class ys {
|
|
14205
14205
|
constructor(t, e, n, s = !1) {
|
|
14206
14206
|
this.isInterleavedBufferAttribute = !0, this.name = "", this.data = t, this.itemSize = e, this.offset = n, this.normalized = s;
|
|
14207
14207
|
}
|
|
@@ -14284,7 +14284,7 @@ class Xs {
|
|
|
14284
14284
|
}
|
|
14285
14285
|
return new ne(new this.array.constructor(e), this.itemSize, this.normalized);
|
|
14286
14286
|
} else
|
|
14287
|
-
return t.interleavedBuffers === void 0 && (t.interleavedBuffers = {}), t.interleavedBuffers[this.data.uuid] === void 0 && (t.interleavedBuffers[this.data.uuid] = this.data.clone(t)), new
|
|
14287
|
+
return t.interleavedBuffers === void 0 && (t.interleavedBuffers = {}), t.interleavedBuffers[this.data.uuid] === void 0 && (t.interleavedBuffers[this.data.uuid] = this.data.clone(t)), new ys(t.interleavedBuffers[this.data.uuid], this.itemSize, this.offset, this.normalized);
|
|
14288
14288
|
}
|
|
14289
14289
|
toJSON(t) {
|
|
14290
14290
|
if (t === void 0) {
|
|
@@ -14347,7 +14347,7 @@ let Ch = class extends be {
|
|
|
14347
14347
|
0,
|
|
14348
14348
|
1
|
|
14349
14349
|
]), n = new Kc(e, 5);
|
|
14350
|
-
El.setIndex([0, 1, 2, 0, 2, 3]), El.setAttribute("position", new
|
|
14350
|
+
El.setIndex([0, 1, 2, 0, 2, 3]), El.setAttribute("position", new ys(n, 3, 0, !1)), El.setAttribute("uv", new ys(n, 2, 3, !1));
|
|
14351
14351
|
}
|
|
14352
14352
|
this.geometry = El, this.material = t, this.center = new _(0.5, 0.5);
|
|
14353
14353
|
}
|
|
@@ -14727,7 +14727,7 @@ class XY {
|
|
|
14727
14727
|
this.list.length = 0, this.index = 0;
|
|
14728
14728
|
}
|
|
14729
14729
|
}
|
|
14730
|
-
const $i = /* @__PURE__ */ new Pt(), jm = /* @__PURE__ */ new Pt(), yY = /* @__PURE__ */ new Pt(), WY = /* @__PURE__ */ new lt(1, 1, 1), R5 = /* @__PURE__ */ new Pt(), Am = /* @__PURE__ */ new Jc(), Bd = /* @__PURE__ */ new W0(),
|
|
14730
|
+
const $i = /* @__PURE__ */ new Pt(), jm = /* @__PURE__ */ new Pt(), yY = /* @__PURE__ */ new Pt(), WY = /* @__PURE__ */ new lt(1, 1, 1), R5 = /* @__PURE__ */ new Pt(), Am = /* @__PURE__ */ new Jc(), Bd = /* @__PURE__ */ new W0(), Js = /* @__PURE__ */ new F0(), mo = /* @__PURE__ */ new N(), x5 = /* @__PURE__ */ new N(), VY = /* @__PURE__ */ new N(), Dm = /* @__PURE__ */ new XY(), z0 = /* @__PURE__ */ new Gt(), Pd = [];
|
|
14731
14731
|
function gY(i, t, e = 0) {
|
|
14732
14732
|
const n = t.itemSize;
|
|
14733
14733
|
if (i.isInterleavedBufferAttribute || i.array.constructor !== t.array.constructor) {
|
|
@@ -14811,7 +14811,7 @@ class Qy extends Gt {
|
|
|
14811
14811
|
for (let n = 0, s = e.length; n < s; n++) {
|
|
14812
14812
|
if (e[n].active === !1) continue;
|
|
14813
14813
|
const l = e[n].geometryIndex;
|
|
14814
|
-
this.getMatrixAt(n, $i), this.getBoundingSphereAt(l,
|
|
14814
|
+
this.getMatrixAt(n, $i), this.getBoundingSphereAt(l, Js).applyMatrix4($i), t.union(Js);
|
|
14815
14815
|
}
|
|
14816
14816
|
}
|
|
14817
14817
|
addInstance(t) {
|
|
@@ -15010,10 +15010,10 @@ class Qy extends Gt {
|
|
|
15010
15010
|
for (let X = 0, y = c.length; X < y; X++)
|
|
15011
15011
|
if (c[X].visible && c[X].active) {
|
|
15012
15012
|
const W = c[X].geometryIndex;
|
|
15013
|
-
this.getMatrixAt(X, $i), this.getBoundingSphereAt(W,
|
|
15013
|
+
this.getMatrixAt(X, $i), this.getBoundingSphereAt(W, Js).applyMatrix4($i);
|
|
15014
15014
|
let g = !1;
|
|
15015
|
-
if (u && (g = !Am.intersectsSphere(
|
|
15016
|
-
const f = VY.subVectors(
|
|
15015
|
+
if (u && (g = !Am.intersectsSphere(Js)), !g) {
|
|
15016
|
+
const f = VY.subVectors(Js.center, mo).dot(x5);
|
|
15017
15017
|
Dm.push(h[W], f, X);
|
|
15018
15018
|
}
|
|
15019
15019
|
}
|
|
@@ -15029,7 +15029,7 @@ class Qy extends Gt {
|
|
|
15029
15029
|
if (c[Z].visible && c[Z].active) {
|
|
15030
15030
|
const X = c[Z].geometryIndex;
|
|
15031
15031
|
let y = !1;
|
|
15032
|
-
if (u && (this.getMatrixAt(Z, $i), this.getBoundingSphereAt(X,
|
|
15032
|
+
if (u && (this.getMatrixAt(Z, $i), this.getBoundingSphereAt(X, Js).applyMatrix4($i), y = !Am.intersectsSphere(Js)), !y) {
|
|
15033
15033
|
const W = h[X];
|
|
15034
15034
|
d[G] = W.start * o, r[G] = W.count, b[G] = Z, G++;
|
|
15035
15035
|
}
|
|
@@ -16067,7 +16067,7 @@ class Au extends c0 {
|
|
|
16067
16067
|
return new Au(t.radius, t.height, t.radialSegments, t.heightSegments, t.openEnded, t.thetaStart, t.thetaLength);
|
|
16068
16068
|
}
|
|
16069
16069
|
}
|
|
16070
|
-
class
|
|
16070
|
+
class Vs extends Ot {
|
|
16071
16071
|
constructor(t = [], e = [], n = 1, s = 0) {
|
|
16072
16072
|
super(), this.type = "PolyhedronGeometry", this.parameters = {
|
|
16073
16073
|
vertices: t,
|
|
@@ -16145,10 +16145,10 @@ class Ws extends Ot {
|
|
|
16145
16145
|
return super.copy(t), this.parameters = Object.assign({}, t.parameters), this;
|
|
16146
16146
|
}
|
|
16147
16147
|
static fromJSON(t) {
|
|
16148
|
-
return new
|
|
16148
|
+
return new Vs(t.vertices, t.indices, t.radius, t.details);
|
|
16149
16149
|
}
|
|
16150
16150
|
}
|
|
16151
|
-
class Qc extends
|
|
16151
|
+
class Qc extends Vs {
|
|
16152
16152
|
constructor(t = 1, e = 0) {
|
|
16153
16153
|
const n = (1 + Math.sqrt(5)) / 2, s = 1 / n, l = [
|
|
16154
16154
|
// (±1, ±1, ±1)
|
|
@@ -16723,20 +16723,20 @@ class Ou extends Ot {
|
|
|
16723
16723
|
}
|
|
16724
16724
|
const z = R.length, E = w.length;
|
|
16725
16725
|
function Q(M, ft, gt) {
|
|
16726
|
-
let Ct,
|
|
16726
|
+
let Ct, mt, rt;
|
|
16727
16727
|
const nt = M.x - ft.x, ot = M.y - ft.y, F = gt.x - M.x, Y = gt.y - M.y, D = nt * nt + ot * ot, at = nt * Y - ot * F;
|
|
16728
16728
|
if (Math.abs(at) > Number.EPSILON) {
|
|
16729
|
-
const dt = Math.sqrt(D),
|
|
16730
|
-
Ct = Kt + nt * xt - M.x,
|
|
16731
|
-
const zt = Ct * Ct +
|
|
16729
|
+
const dt = Math.sqrt(D), bt = Math.sqrt(F * F + Y * Y), Kt = ft.x - ot / dt, vt = ft.y + nt / dt, kt = gt.x - Y / bt, At = gt.y + F / bt, xt = ((kt - Kt) * Y - (At - vt) * F) / (nt * Y - ot * F);
|
|
16730
|
+
Ct = Kt + nt * xt - M.x, mt = vt + ot * xt - M.y;
|
|
16731
|
+
const zt = Ct * Ct + mt * mt;
|
|
16732
16732
|
if (zt <= 2)
|
|
16733
|
-
return new _(Ct,
|
|
16733
|
+
return new _(Ct, mt);
|
|
16734
16734
|
rt = Math.sqrt(zt / 2);
|
|
16735
16735
|
} else {
|
|
16736
16736
|
let dt = !1;
|
|
16737
|
-
nt > Number.EPSILON ? F > Number.EPSILON && (dt = !0) : nt < -Number.EPSILON ? F < -Number.EPSILON && (dt = !0) : Math.sign(ot) === Math.sign(Y) && (dt = !0), dt ? (Ct = -ot,
|
|
16737
|
+
nt > Number.EPSILON ? F > Number.EPSILON && (dt = !0) : nt < -Number.EPSILON ? F < -Number.EPSILON && (dt = !0) : Math.sign(ot) === Math.sign(Y) && (dt = !0), dt ? (Ct = -ot, mt = nt, rt = Math.sqrt(D)) : (Ct = nt, mt = ot, rt = Math.sqrt(D / 2));
|
|
16738
16738
|
}
|
|
16739
|
-
return new _(Ct / rt,
|
|
16739
|
+
return new _(Ct / rt, mt / rt);
|
|
16740
16740
|
}
|
|
16741
16741
|
const et = [];
|
|
16742
16742
|
for (let M = 0, ft = K.length, gt = ft - 1, Ct = M + 1; M < ft; M++, gt++, Ct++)
|
|
@@ -16746,19 +16746,19 @@ class Ou extends Ot {
|
|
|
16746
16746
|
for (let M = 0, ft = v.length; M < ft; M++) {
|
|
16747
16747
|
const gt = v[M];
|
|
16748
16748
|
Vt = [];
|
|
16749
|
-
for (let Ct = 0,
|
|
16750
|
-
rt ===
|
|
16749
|
+
for (let Ct = 0, mt = gt.length, rt = mt - 1, nt = Ct + 1; Ct < mt; Ct++, rt++, nt++)
|
|
16750
|
+
rt === mt && (rt = 0), nt === mt && (nt = 0), Vt[Ct] = Q(gt[Ct], gt[rt], gt[nt]);
|
|
16751
16751
|
yt.push(Vt), Ut = Ut.concat(Vt);
|
|
16752
16752
|
}
|
|
16753
16753
|
for (let M = 0; M < Z; M++) {
|
|
16754
16754
|
const ft = M / Z, gt = m * Math.cos(ft * Math.PI / 2), Ct = b * Math.sin(ft * Math.PI / 2) + G;
|
|
16755
|
-
for (let
|
|
16756
|
-
const nt = H(K[
|
|
16755
|
+
for (let mt = 0, rt = K.length; mt < rt; mt++) {
|
|
16756
|
+
const nt = H(K[mt], et[mt], Ct);
|
|
16757
16757
|
St(nt.x, nt.y, -gt);
|
|
16758
16758
|
}
|
|
16759
|
-
for (let
|
|
16760
|
-
const nt = v[
|
|
16761
|
-
Vt = yt[
|
|
16759
|
+
for (let mt = 0, rt = v.length; mt < rt; mt++) {
|
|
16760
|
+
const nt = v[mt];
|
|
16761
|
+
Vt = yt[mt];
|
|
16762
16762
|
for (let ot = 0, F = nt.length; ot < F; ot++) {
|
|
16763
16763
|
const Y = H(nt[ot], Vt[ot], Ct);
|
|
16764
16764
|
St(Y.x, Y.y, -gt);
|
|
@@ -16777,13 +16777,13 @@ class Ou extends Ot {
|
|
|
16777
16777
|
}
|
|
16778
16778
|
for (let M = Z - 1; M >= 0; M--) {
|
|
16779
16779
|
const ft = M / Z, gt = m * Math.cos(ft * Math.PI / 2), Ct = b * Math.sin(ft * Math.PI / 2) + G;
|
|
16780
|
-
for (let
|
|
16781
|
-
const nt = H(K[
|
|
16780
|
+
for (let mt = 0, rt = K.length; mt < rt; mt++) {
|
|
16781
|
+
const nt = H(K[mt], et[mt], Ct);
|
|
16782
16782
|
St(nt.x, nt.y, h + gt);
|
|
16783
16783
|
}
|
|
16784
|
-
for (let
|
|
16785
|
-
const nt = v[
|
|
16786
|
-
Vt = yt[
|
|
16784
|
+
for (let mt = 0, rt = v.length; mt < rt; mt++) {
|
|
16785
|
+
const nt = v[mt];
|
|
16786
|
+
Vt = yt[mt];
|
|
16787
16787
|
for (let ot = 0, F = nt.length; ot < F; ot++) {
|
|
16788
16788
|
const Y = H(nt[ot], Vt[ot], Ct);
|
|
16789
16789
|
W ? St(Y.x, Y.y + y[r - 1].y, y[r - 1].x + gt) : St(Y.x, Y.y, h + gt);
|
|
@@ -16796,13 +16796,13 @@ class Ou extends Ot {
|
|
|
16796
16796
|
if (u) {
|
|
16797
16797
|
let ft = 0, gt = z * ft;
|
|
16798
16798
|
for (let Ct = 0; Ct < E; Ct++) {
|
|
16799
|
-
const
|
|
16800
|
-
Qt(
|
|
16799
|
+
const mt = w[Ct];
|
|
16800
|
+
Qt(mt[2] + gt, mt[1] + gt, mt[0] + gt);
|
|
16801
16801
|
}
|
|
16802
16802
|
ft = r + Z * 2, gt = z * ft;
|
|
16803
16803
|
for (let Ct = 0; Ct < E; Ct++) {
|
|
16804
|
-
const
|
|
16805
|
-
Qt(
|
|
16804
|
+
const mt = w[Ct];
|
|
16805
|
+
Qt(mt[0] + gt, mt[1] + gt, mt[2] + gt);
|
|
16806
16806
|
}
|
|
16807
16807
|
} else {
|
|
16808
16808
|
for (let ft = 0; ft < E; ft++) {
|
|
@@ -16821,8 +16821,8 @@ class Ou extends Ot {
|
|
|
16821
16821
|
let ft = 0;
|
|
16822
16822
|
Wt(K, ft), ft += K.length;
|
|
16823
16823
|
for (let gt = 0, Ct = v.length; gt < Ct; gt++) {
|
|
16824
|
-
const
|
|
16825
|
-
Wt(
|
|
16824
|
+
const mt = v[gt];
|
|
16825
|
+
Wt(mt, ft), ft += mt.length;
|
|
16826
16826
|
}
|
|
16827
16827
|
n.addGroup(M, s.length / 3 - M, 1);
|
|
16828
16828
|
}
|
|
@@ -16830,10 +16830,10 @@ class Ou extends Ot {
|
|
|
16830
16830
|
let gt = M.length;
|
|
16831
16831
|
for (; --gt >= 0; ) {
|
|
16832
16832
|
const Ct = gt;
|
|
16833
|
-
let
|
|
16834
|
-
|
|
16833
|
+
let mt = gt - 1;
|
|
16834
|
+
mt < 0 && (mt = M.length - 1);
|
|
16835
16835
|
for (let rt = 0, nt = r + Z * 2; rt < nt; rt++) {
|
|
16836
|
-
const ot = z * rt, F = z * (rt + 1), Y = ft + Ct + ot, D = ft +
|
|
16836
|
+
const ot = z * rt, F = z * (rt + 1), Y = ft + Ct + ot, D = ft + mt + ot, at = ft + mt + F, dt = ft + Ct + F;
|
|
16837
16837
|
se(Y, D, at, dt);
|
|
16838
16838
|
}
|
|
16839
16839
|
}
|
|
@@ -16843,12 +16843,12 @@ class Ou extends Ot {
|
|
|
16843
16843
|
}
|
|
16844
16844
|
function Qt(M, ft, gt) {
|
|
16845
16845
|
qt(M), qt(ft), qt(gt);
|
|
16846
|
-
const Ct = s.length / 3,
|
|
16847
|
-
he(
|
|
16846
|
+
const Ct = s.length / 3, mt = X.generateTopUV(n, s, Ct - 3, Ct - 2, Ct - 1);
|
|
16847
|
+
he(mt[0]), he(mt[1]), he(mt[2]);
|
|
16848
16848
|
}
|
|
16849
16849
|
function se(M, ft, gt, Ct) {
|
|
16850
16850
|
qt(M), qt(ft), qt(Ct), qt(ft), qt(gt), qt(Ct);
|
|
16851
|
-
const
|
|
16851
|
+
const mt = s.length / 3, rt = X.generateSideWallUV(n, s, mt - 6, mt - 3, mt - 2, mt - 1);
|
|
16852
16852
|
he(rt[0]), he(rt[1]), he(rt[3]), he(rt[1]), he(rt[2]), he(rt[3]);
|
|
16853
16853
|
}
|
|
16854
16854
|
function qt(M) {
|
|
@@ -16910,7 +16910,7 @@ function _Y(i, t, e) {
|
|
|
16910
16910
|
e.shapes.push(i.uuid);
|
|
16911
16911
|
return e.options = Object.assign({}, t), t.extrudePath !== void 0 && (e.options.extrudePath = t.extrudePath.toJSON()), e;
|
|
16912
16912
|
}
|
|
16913
|
-
class jc extends
|
|
16913
|
+
class jc extends Vs {
|
|
16914
16914
|
constructor(t = 1, e = 0) {
|
|
16915
16915
|
const n = (1 + Math.sqrt(5)) / 2, s = [
|
|
16916
16916
|
-1,
|
|
@@ -17020,7 +17020,7 @@ class jc extends Ws {
|
|
|
17020
17020
|
return new jc(t.radius, t.detail);
|
|
17021
17021
|
}
|
|
17022
17022
|
}
|
|
17023
|
-
class mi extends
|
|
17023
|
+
class mi extends Vs {
|
|
17024
17024
|
constructor(t = 1, e = 0) {
|
|
17025
17025
|
const n = [
|
|
17026
17026
|
1,
|
|
@@ -17176,7 +17176,7 @@ function qY(i, t) {
|
|
|
17176
17176
|
t.shapes.push(i.uuid);
|
|
17177
17177
|
return t;
|
|
17178
17178
|
}
|
|
17179
|
-
class
|
|
17179
|
+
class gs extends Ot {
|
|
17180
17180
|
constructor(t = 1, e = 32, n = 16, s = 0, l = Math.PI * 2, a = 0, o = Math.PI) {
|
|
17181
17181
|
super(), this.type = "SphereGeometry", this.parameters = {
|
|
17182
17182
|
radius: t,
|
|
@@ -17211,10 +17211,10 @@ class Vs extends Ot {
|
|
|
17211
17211
|
return super.copy(t), this.parameters = Object.assign({}, t.parameters), this;
|
|
17212
17212
|
}
|
|
17213
17213
|
static fromJSON(t) {
|
|
17214
|
-
return new
|
|
17214
|
+
return new gs(t.radius, t.widthSegments, t.heightSegments, t.phiStart, t.phiLength, t.thetaStart, t.thetaLength);
|
|
17215
17215
|
}
|
|
17216
17216
|
}
|
|
17217
|
-
class Dc extends
|
|
17217
|
+
class Dc extends Vs {
|
|
17218
17218
|
constructor(t = 1, e = 0) {
|
|
17219
17219
|
const n = [
|
|
17220
17220
|
1,
|
|
@@ -17427,10 +17427,10 @@ var J5 = /* @__PURE__ */ Object.freeze({
|
|
|
17427
17427
|
LatheGeometry: ja,
|
|
17428
17428
|
OctahedronGeometry: mi,
|
|
17429
17429
|
PlaneGeometry: Sn,
|
|
17430
|
-
PolyhedronGeometry:
|
|
17430
|
+
PolyhedronGeometry: Vs,
|
|
17431
17431
|
RingGeometry: Ac,
|
|
17432
17432
|
ShapeGeometry: _u,
|
|
17433
|
-
SphereGeometry:
|
|
17433
|
+
SphereGeometry: gs,
|
|
17434
17434
|
TetrahedronGeometry: Dc,
|
|
17435
17435
|
TorusGeometry: An,
|
|
17436
17436
|
TorusKnotGeometry: Oc,
|
|
@@ -17452,7 +17452,7 @@ class tW extends _e {
|
|
|
17452
17452
|
}
|
|
17453
17453
|
class n0 extends g0 {
|
|
17454
17454
|
constructor(t) {
|
|
17455
|
-
super(), this.isMeshStandardMaterial = !0, this.defines = { STANDARD: "" }, this.type = "MeshStandardMaterial", this.color = new lt(16777215), this.roughness = 1, this.metalness = 0, this.map = null, this.lightMap = null, this.lightMapIntensity = 1, this.aoMap = null, this.aoMapIntensity = 1, this.emissive = new lt(0), this.emissiveIntensity = 1, this.emissiveMap = null, this.bumpMap = null, this.bumpScale = 1, this.normalMap = null, this.normalMapType =
|
|
17455
|
+
super(), this.isMeshStandardMaterial = !0, this.defines = { STANDARD: "" }, this.type = "MeshStandardMaterial", this.color = new lt(16777215), this.roughness = 1, this.metalness = 0, this.map = null, this.lightMap = null, this.lightMapIntensity = 1, this.aoMap = null, this.aoMapIntensity = 1, this.emissive = new lt(0), this.emissiveIntensity = 1, this.emissiveMap = null, this.bumpMap = null, this.bumpScale = 1, this.normalMap = null, this.normalMapType = Ws, this.normalScale = new _(1, 1), this.displacementMap = null, this.displacementScale = 1, this.displacementBias = 0, this.roughnessMap = null, this.metalnessMap = null, this.alphaMap = null, this.envMap = null, this.envMapRotation = new E0(), this.envMapIntensity = 1, this.wireframe = !1, this.wireframeLinewidth = 1, this.wireframeLinecap = "round", this.wireframeLinejoin = "round", this.flatShading = !1, this.fog = !0, this.setValues(t);
|
|
17456
17456
|
}
|
|
17457
17457
|
copy(t) {
|
|
17458
17458
|
return super.copy(t), this.defines = { STANDARD: "" }, this.color.copy(t.color), this.roughness = t.roughness, this.metalness = t.metalness, this.map = t.map, this.lightMap = t.lightMap, this.lightMapIntensity = t.lightMapIntensity, this.aoMap = t.aoMap, this.aoMapIntensity = t.aoMapIntensity, this.emissive.copy(t.emissive), this.emissiveMap = t.emissiveMap, this.emissiveIntensity = t.emissiveIntensity, this.bumpMap = t.bumpMap, this.bumpScale = t.bumpScale, this.normalMap = t.normalMap, this.normalMapType = t.normalMapType, this.normalScale.copy(t.normalScale), this.displacementMap = t.displacementMap, this.displacementScale = t.displacementScale, this.displacementBias = t.displacementBias, this.roughnessMap = t.roughnessMap, this.metalnessMap = t.metalnessMap, this.alphaMap = t.alphaMap, this.envMap = t.envMap, this.envMapRotation.copy(t.envMapRotation), this.envMapIntensity = t.envMapIntensity, this.wireframe = t.wireframe, this.wireframeLinewidth = t.wireframeLinewidth, this.wireframeLinecap = t.wireframeLinecap, this.wireframeLinejoin = t.wireframeLinejoin, this.flatShading = t.flatShading, this.fog = t.fog, this;
|
|
@@ -17517,7 +17517,7 @@ class Hn extends n0 {
|
|
|
17517
17517
|
}
|
|
17518
17518
|
class eW extends g0 {
|
|
17519
17519
|
constructor(t) {
|
|
17520
|
-
super(), this.isMeshPhongMaterial = !0, this.type = "MeshPhongMaterial", this.color = new lt(16777215), this.specular = new lt(1118481), this.shininess = 30, this.map = null, this.lightMap = null, this.lightMapIntensity = 1, this.aoMap = null, this.aoMapIntensity = 1, this.emissive = new lt(0), this.emissiveIntensity = 1, this.emissiveMap = null, this.bumpMap = null, this.bumpScale = 1, this.normalMap = null, this.normalMapType =
|
|
17520
|
+
super(), this.isMeshPhongMaterial = !0, this.type = "MeshPhongMaterial", this.color = new lt(16777215), this.specular = new lt(1118481), this.shininess = 30, this.map = null, this.lightMap = null, this.lightMapIntensity = 1, this.aoMap = null, this.aoMapIntensity = 1, this.emissive = new lt(0), this.emissiveIntensity = 1, this.emissiveMap = null, this.bumpMap = null, this.bumpScale = 1, this.normalMap = null, this.normalMapType = Ws, this.normalScale = new _(1, 1), this.displacementMap = null, this.displacementScale = 1, this.displacementBias = 0, this.specularMap = null, this.alphaMap = null, this.envMap = null, this.envMapRotation = new E0(), this.combine = Ic, 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(t);
|
|
17521
17521
|
}
|
|
17522
17522
|
copy(t) {
|
|
17523
17523
|
return super.copy(t), this.color.copy(t.color), this.specular.copy(t.specular), this.shininess = t.shininess, this.map = t.map, this.lightMap = t.lightMap, this.lightMapIntensity = t.lightMapIntensity, this.aoMap = t.aoMap, this.aoMapIntensity = t.aoMapIntensity, this.emissive.copy(t.emissive), this.emissiveMap = t.emissiveMap, this.emissiveIntensity = t.emissiveIntensity, this.bumpMap = t.bumpMap, this.bumpScale = t.bumpScale, this.normalMap = t.normalMap, this.normalMapType = t.normalMapType, this.normalScale.copy(t.normalScale), this.displacementMap = t.displacementMap, this.displacementScale = t.displacementScale, this.displacementBias = t.displacementBias, this.specularMap = t.specularMap, this.alphaMap = t.alphaMap, this.envMap = t.envMap, this.envMapRotation.copy(t.envMapRotation), this.combine = t.combine, this.reflectivity = t.reflectivity, this.refractionRatio = t.refractionRatio, this.wireframe = t.wireframe, this.wireframeLinewidth = t.wireframeLinewidth, this.wireframeLinecap = t.wireframeLinecap, this.wireframeLinejoin = t.wireframeLinejoin, this.flatShading = t.flatShading, this.fog = t.fog, this;
|
|
@@ -17525,7 +17525,7 @@ class eW extends g0 {
|
|
|
17525
17525
|
}
|
|
17526
17526
|
class nW extends g0 {
|
|
17527
17527
|
constructor(t) {
|
|
17528
|
-
super(), this.isMeshToonMaterial = !0, this.defines = { TOON: "" }, this.type = "MeshToonMaterial", this.color = new lt(16777215), this.map = null, this.gradientMap = null, this.lightMap = null, this.lightMapIntensity = 1, this.aoMap = null, this.aoMapIntensity = 1, this.emissive = new lt(0), this.emissiveIntensity = 1, this.emissiveMap = null, this.bumpMap = null, this.bumpScale = 1, this.normalMap = null, this.normalMapType =
|
|
17528
|
+
super(), this.isMeshToonMaterial = !0, this.defines = { TOON: "" }, this.type = "MeshToonMaterial", this.color = new lt(16777215), this.map = null, this.gradientMap = null, this.lightMap = null, this.lightMapIntensity = 1, this.aoMap = null, this.aoMapIntensity = 1, this.emissive = new lt(0), this.emissiveIntensity = 1, this.emissiveMap = null, this.bumpMap = null, this.bumpScale = 1, this.normalMap = null, this.normalMapType = Ws, this.normalScale = new _(1, 1), this.displacementMap = null, this.displacementScale = 1, this.displacementBias = 0, this.alphaMap = null, this.wireframe = !1, this.wireframeLinewidth = 1, this.wireframeLinecap = "round", this.wireframeLinejoin = "round", this.fog = !0, this.setValues(t);
|
|
17529
17529
|
}
|
|
17530
17530
|
copy(t) {
|
|
17531
17531
|
return super.copy(t), this.color.copy(t.color), this.map = t.map, this.gradientMap = t.gradientMap, this.lightMap = t.lightMap, this.lightMapIntensity = t.lightMapIntensity, this.aoMap = t.aoMap, this.aoMapIntensity = t.aoMapIntensity, this.emissive.copy(t.emissive), this.emissiveMap = t.emissiveMap, this.emissiveIntensity = t.emissiveIntensity, this.bumpMap = t.bumpMap, this.bumpScale = t.bumpScale, this.normalMap = t.normalMap, this.normalMapType = t.normalMapType, this.normalScale.copy(t.normalScale), this.displacementMap = t.displacementMap, this.displacementScale = t.displacementScale, this.displacementBias = t.displacementBias, this.alphaMap = t.alphaMap, this.wireframe = t.wireframe, this.wireframeLinewidth = t.wireframeLinewidth, this.wireframeLinecap = t.wireframeLinecap, this.wireframeLinejoin = t.wireframeLinejoin, this.fog = t.fog, this;
|
|
@@ -17533,7 +17533,7 @@ class nW extends g0 {
|
|
|
17533
17533
|
}
|
|
17534
17534
|
class iW extends g0 {
|
|
17535
17535
|
constructor(t) {
|
|
17536
|
-
super(), this.isMeshNormalMaterial = !0, this.type = "MeshNormalMaterial", this.bumpMap = null, this.bumpScale = 1, this.normalMap = null, this.normalMapType =
|
|
17536
|
+
super(), this.isMeshNormalMaterial = !0, this.type = "MeshNormalMaterial", this.bumpMap = null, this.bumpScale = 1, this.normalMap = null, this.normalMapType = Ws, this.normalScale = new _(1, 1), this.displacementMap = null, this.displacementScale = 1, this.displacementBias = 0, this.wireframe = !1, this.wireframeLinewidth = 1, this.flatShading = !1, this.setValues(t);
|
|
17537
17537
|
}
|
|
17538
17538
|
copy(t) {
|
|
17539
17539
|
return super.copy(t), this.bumpMap = t.bumpMap, this.bumpScale = t.bumpScale, this.normalMap = t.normalMap, this.normalMapType = t.normalMapType, this.normalScale.copy(t.normalScale), this.displacementMap = t.displacementMap, this.displacementScale = t.displacementScale, this.displacementBias = t.displacementBias, this.wireframe = t.wireframe, this.wireframeLinewidth = t.wireframeLinewidth, this.flatShading = t.flatShading, this;
|
|
@@ -17541,7 +17541,7 @@ class iW extends g0 {
|
|
|
17541
17541
|
}
|
|
17542
17542
|
class sW extends g0 {
|
|
17543
17543
|
constructor(t) {
|
|
17544
|
-
super(), this.isMeshLambertMaterial = !0, this.type = "MeshLambertMaterial", this.color = new lt(16777215), this.map = null, this.lightMap = null, this.lightMapIntensity = 1, this.aoMap = null, this.aoMapIntensity = 1, this.emissive = new lt(0), this.emissiveIntensity = 1, this.emissiveMap = null, this.bumpMap = null, this.bumpScale = 1, this.normalMap = null, this.normalMapType =
|
|
17544
|
+
super(), this.isMeshLambertMaterial = !0, this.type = "MeshLambertMaterial", this.color = new lt(16777215), this.map = null, this.lightMap = null, this.lightMapIntensity = 1, this.aoMap = null, this.aoMapIntensity = 1, this.emissive = new lt(0), this.emissiveIntensity = 1, this.emissiveMap = null, this.bumpMap = null, this.bumpScale = 1, this.normalMap = null, this.normalMapType = Ws, this.normalScale = new _(1, 1), this.displacementMap = null, this.displacementScale = 1, this.displacementBias = 0, this.specularMap = null, this.alphaMap = null, this.envMap = null, this.envMapRotation = new E0(), this.combine = Ic, 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(t);
|
|
17545
17545
|
}
|
|
17546
17546
|
copy(t) {
|
|
17547
17547
|
return super.copy(t), this.color.copy(t.color), this.map = t.map, this.lightMap = t.lightMap, this.lightMapIntensity = t.lightMapIntensity, this.aoMap = t.aoMap, this.aoMapIntensity = t.aoMapIntensity, this.emissive.copy(t.emissive), this.emissiveMap = t.emissiveMap, this.emissiveIntensity = t.emissiveIntensity, this.bumpMap = t.bumpMap, this.bumpScale = t.bumpScale, this.normalMap = t.normalMap, this.normalMapType = t.normalMapType, this.normalScale.copy(t.normalScale), this.displacementMap = t.displacementMap, this.displacementScale = t.displacementScale, this.displacementBias = t.displacementBias, this.specularMap = t.specularMap, this.alphaMap = t.alphaMap, this.envMap = t.envMap, this.envMapRotation.copy(t.envMapRotation), this.combine = t.combine, this.reflectivity = t.reflectivity, this.refractionRatio = t.refractionRatio, this.wireframe = t.wireframe, this.wireframeLinewidth = t.wireframeLinewidth, this.wireframeLinecap = t.wireframeLinecap, this.wireframeLinejoin = t.wireframeLinejoin, this.flatShading = t.flatShading, this.fog = t.fog, this;
|
|
@@ -17549,7 +17549,7 @@ class sW extends g0 {
|
|
|
17549
17549
|
}
|
|
17550
17550
|
class lW extends g0 {
|
|
17551
17551
|
constructor(t) {
|
|
17552
|
-
super(), this.isMeshMatcapMaterial = !0, this.defines = { MATCAP: "" }, this.type = "MeshMatcapMaterial", this.color = new lt(16777215), this.matcap = null, this.map = null, this.bumpMap = null, this.bumpScale = 1, this.normalMap = null, this.normalMapType =
|
|
17552
|
+
super(), this.isMeshMatcapMaterial = !0, this.defines = { MATCAP: "" }, this.type = "MeshMatcapMaterial", this.color = new lt(16777215), this.matcap = null, this.map = null, this.bumpMap = null, this.bumpScale = 1, this.normalMap = null, this.normalMapType = Ws, this.normalScale = new _(1, 1), this.displacementMap = null, this.displacementScale = 1, this.displacementBias = 0, this.alphaMap = null, this.flatShading = !1, this.fog = !0, this.setValues(t);
|
|
17553
17553
|
}
|
|
17554
17554
|
copy(t) {
|
|
17555
17555
|
return super.copy(t), this.defines = { MATCAP: "" }, this.color.copy(t.color), this.matcap = t.matcap, this.map = t.map, this.bumpMap = t.bumpMap, this.bumpScale = t.bumpScale, this.normalMap = t.normalMap, this.normalMapType = t.normalMapType, this.normalScale.copy(t.normalScale), this.displacementMap = t.displacementMap, this.displacementScale = t.displacementScale, this.displacementBias = t.displacementBias, this.alphaMap = t.alphaMap, this.flatShading = t.flatShading, this.fog = t.fog, this;
|
|
@@ -18577,7 +18577,7 @@ class m9 extends H0 {
|
|
|
18577
18577
|
}, n, s), l;
|
|
18578
18578
|
}
|
|
18579
18579
|
}
|
|
18580
|
-
let
|
|
18580
|
+
let fs = class extends be {
|
|
18581
18581
|
constructor(t, e = 1) {
|
|
18582
18582
|
super(), this.isLight = !0, this.type = "Light", this.color = new lt(t), this.intensity = e;
|
|
18583
18583
|
}
|
|
@@ -18591,7 +18591,7 @@ let gs = class extends be {
|
|
|
18591
18591
|
return e.object.color = this.color.getHex(), e.object.intensity = this.intensity, this.groundColor !== void 0 && (e.object.groundColor = this.groundColor.getHex()), this.distance !== void 0 && (e.object.distance = this.distance), this.angle !== void 0 && (e.object.angle = this.angle), this.decay !== void 0 && (e.object.decay = this.decay), this.penumbra !== void 0 && (e.object.penumbra = this.penumbra), this.shadow !== void 0 && (e.object.shadow = this.shadow.toJSON()), this.target !== void 0 && (e.object.target = this.target.uuid), e;
|
|
18592
18592
|
}
|
|
18593
18593
|
};
|
|
18594
|
-
class p9 extends
|
|
18594
|
+
class p9 extends fs {
|
|
18595
18595
|
constructor(t, e, n) {
|
|
18596
18596
|
super(t, n), this.isHemisphereLight = !0, this.type = "HemisphereLight", this.position.copy(be.DEFAULT_UP), this.updateMatrix(), this.groundColor = new lt(e);
|
|
18597
18597
|
}
|
|
@@ -18665,7 +18665,7 @@ class cI extends b9 {
|
|
|
18665
18665
|
return super.copy(t), this.focus = t.focus, this;
|
|
18666
18666
|
}
|
|
18667
18667
|
}
|
|
18668
|
-
class $u extends
|
|
18668
|
+
class $u extends fs {
|
|
18669
18669
|
constructor(t, e, n = 0, s = Math.PI / 3, l = 0, a = 2) {
|
|
18670
18670
|
super(t, e), this.isSpotLight = !0, this.type = "SpotLight", this.position.copy(be.DEFAULT_UP), this.updateMatrix(), this.target = new be(), this.distance = n, this.angle = s, this.penumbra = l, this.decay = a, this.map = null, this.shadow = new cI();
|
|
18671
18671
|
}
|
|
@@ -18731,7 +18731,7 @@ class dI extends b9 {
|
|
|
18731
18731
|
l !== n.far && (n.far = l, n.updateProjectionMatrix()), bo.setFromMatrixPosition(t.matrixWorld), n.position.copy(bo), n1.copy(n.position), n1.add(this._cubeDirections[e]), n.up.copy(this._cubeUps[e]), n.lookAt(n1), n.updateMatrixWorld(), s.makeTranslation(-bo.x, -bo.y, -bo.z), k5.multiplyMatrices(n.projectionMatrix, n.matrixWorldInverse), this._frustum.setFromProjectionMatrix(k5);
|
|
18732
18732
|
}
|
|
18733
18733
|
}
|
|
18734
|
-
class _c extends
|
|
18734
|
+
class _c extends fs {
|
|
18735
18735
|
constructor(t, e, n = 0, s = 2) {
|
|
18736
18736
|
super(t, e), this.isPointLight = !0, this.type = "PointLight", this.distance = n, this.decay = s, this.shadow = new dI();
|
|
18737
18737
|
}
|
|
@@ -18753,7 +18753,7 @@ class rI extends b9 {
|
|
|
18753
18753
|
super(new wc(-5, 5, 5, -5, 0.5, 500)), this.isDirectionalLightShadow = !0;
|
|
18754
18754
|
}
|
|
18755
18755
|
}
|
|
18756
|
-
class tm extends
|
|
18756
|
+
class tm extends fs {
|
|
18757
18757
|
constructor(t, e) {
|
|
18758
18758
|
super(t, e), this.isDirectionalLight = !0, this.type = "DirectionalLight", this.position.copy(be.DEFAULT_UP), this.updateMatrix(), this.target = new be(), this.shadow = new rI();
|
|
18759
18759
|
}
|
|
@@ -18764,12 +18764,12 @@ class tm extends gs {
|
|
|
18764
18764
|
return super.copy(t), this.target = t.target.clone(), this.shadow = t.shadow.clone(), this;
|
|
18765
18765
|
}
|
|
18766
18766
|
}
|
|
18767
|
-
class Z9 extends
|
|
18767
|
+
class Z9 extends fs {
|
|
18768
18768
|
constructor(t, e) {
|
|
18769
18769
|
super(t, e), this.isAmbientLight = !0, this.type = "AmbientLight";
|
|
18770
18770
|
}
|
|
18771
18771
|
}
|
|
18772
|
-
class em extends
|
|
18772
|
+
class em extends fs {
|
|
18773
18773
|
constructor(t, e, n = 10, s = 10) {
|
|
18774
18774
|
super(t, e), this.isRectAreaLight = !0, this.type = "RectAreaLight", this.width = n, this.height = s;
|
|
18775
18775
|
}
|
|
@@ -18867,7 +18867,7 @@ class pW {
|
|
|
18867
18867
|
e[0] = 0.282095, e[1] = 0.488603 * s, e[2] = 0.488603 * l, e[3] = 0.488603 * n, e[4] = 1.092548 * n * s, e[5] = 1.092548 * s * l, e[6] = 0.315392 * (3 * l * l - 1), e[7] = 1.092548 * n * l, e[8] = 0.546274 * (n * n - s * s);
|
|
18868
18868
|
}
|
|
18869
18869
|
}
|
|
18870
|
-
class bW extends
|
|
18870
|
+
class bW extends fs {
|
|
18871
18871
|
constructor(t = new pW(), e = 1) {
|
|
18872
18872
|
super(void 0, e), this.isLightProbe = !0, this.sh = t;
|
|
18873
18873
|
}
|
|
@@ -18967,7 +18967,7 @@ class nm extends H0 {
|
|
|
18967
18967
|
return new e[t]();
|
|
18968
18968
|
}
|
|
18969
18969
|
}
|
|
18970
|
-
class
|
|
18970
|
+
class bs {
|
|
18971
18971
|
static decodeText(t) {
|
|
18972
18972
|
if (console.warn("THREE.LoaderUtils: decodeText() has been deprecated with r165 and will be removed with r175. Use TextDecoder instead."), typeof TextDecoder != "undefined")
|
|
18973
18973
|
return new TextDecoder().decode(t);
|
|
@@ -19037,7 +19037,7 @@ class G9 extends H0 {
|
|
|
19037
19037
|
let G;
|
|
19038
19038
|
if (b.isInterleavedBufferAttribute) {
|
|
19039
19039
|
const Z = s(t.data, b.data);
|
|
19040
|
-
G = new
|
|
19040
|
+
G = new ys(Z, b.itemSize, b.offset, b.normalized);
|
|
19041
19041
|
} else {
|
|
19042
19042
|
const Z = oa(b.type, b.array), p = b.isInstancedBufferAttribute ? Gl : ne;
|
|
19043
19043
|
G = new p(Z, b.itemSize, b.normalized);
|
|
@@ -19053,7 +19053,7 @@ class G9 extends H0 {
|
|
|
19053
19053
|
let y;
|
|
19054
19054
|
if (X.isInterleavedBufferAttribute) {
|
|
19055
19055
|
const W = s(t.data, X.data);
|
|
19056
|
-
y = new
|
|
19056
|
+
y = new ys(W, X.itemSize, X.offset, X.normalized);
|
|
19057
19057
|
} else {
|
|
19058
19058
|
const W = oa(X.type, X.array);
|
|
19059
19059
|
y = new ne(W, X.itemSize, X.normalized);
|
|
@@ -19082,7 +19082,7 @@ class X9 extends H0 {
|
|
|
19082
19082
|
super(t);
|
|
19083
19083
|
}
|
|
19084
19084
|
load(t, e, n, s) {
|
|
19085
|
-
const l = this, a = this.path === "" ?
|
|
19085
|
+
const l = this, a = this.path === "" ? bs.extractUrlBase(t) : this.path;
|
|
19086
19086
|
this.resourcePath = this.resourcePath || a;
|
|
19087
19087
|
const o = new nn(this.manager);
|
|
19088
19088
|
o.setPath(this.path), o.setRequestHeader(this.requestHeader), o.setWithCredentials(this.withCredentials), o.load(t, function(c) {
|
|
@@ -19102,8 +19102,8 @@ class X9 extends H0 {
|
|
|
19102
19102
|
}, n, s);
|
|
19103
19103
|
}
|
|
19104
19104
|
loadAsync(t, e) {
|
|
19105
|
-
return
|
|
19106
|
-
const n = this, s = this.path === "" ?
|
|
19105
|
+
return ht(this, null, function* () {
|
|
19106
|
+
const n = this, s = this.path === "" ? bs.extractUrlBase(t) : this.path;
|
|
19107
19107
|
this.resourcePath = this.resourcePath || s;
|
|
19108
19108
|
const l = new nn(this.manager);
|
|
19109
19109
|
l.setPath(this.path), l.setRequestHeader(this.requestHeader), l.setWithCredentials(this.withCredentials);
|
|
@@ -19129,7 +19129,7 @@ class X9 extends H0 {
|
|
|
19129
19129
|
return d;
|
|
19130
19130
|
}
|
|
19131
19131
|
parseAsync(t) {
|
|
19132
|
-
return
|
|
19132
|
+
return ht(this, null, function* () {
|
|
19133
19133
|
const e = this.parseAnimations(t.animations), n = this.parseShapes(t.shapes), s = this.parseGeometries(t.geometries, n), l = yield this.parseImagesAsync(t.images), a = this.parseTextures(t.textures, l), o = this.parseMaterials(t.materials, a), c = this.parseObject(t.object, s, o, a, e), d = this.parseSkeletons(t.skeletons, c);
|
|
19134
19134
|
return this.bindSkeletons(c, d), this.bindLightTargets(c), c;
|
|
19135
19135
|
});
|
|
@@ -19237,11 +19237,11 @@ class X9 extends H0 {
|
|
|
19237
19237
|
return s;
|
|
19238
19238
|
}
|
|
19239
19239
|
parseImagesAsync(t) {
|
|
19240
|
-
return
|
|
19240
|
+
return ht(this, null, function* () {
|
|
19241
19241
|
const e = this, n = {};
|
|
19242
19242
|
let s;
|
|
19243
19243
|
function l(a) {
|
|
19244
|
-
return
|
|
19244
|
+
return ht(this, null, function* () {
|
|
19245
19245
|
if (typeof a == "string") {
|
|
19246
19246
|
const o = a, c = /^(\/\/)|([a-z]+:(\/\/)?)/i.test(o) ? o : e.resourcePath + o;
|
|
19247
19247
|
return yield s.loadAsync(c);
|
|
@@ -19446,7 +19446,7 @@ const hI = {
|
|
|
19446
19446
|
}, U5 = {
|
|
19447
19447
|
NearestFilter: ze,
|
|
19448
19448
|
NearestMipmapNearestFilter: Nc,
|
|
19449
|
-
NearestMipmapLinearFilter:
|
|
19449
|
+
NearestMipmapLinearFilter: hs,
|
|
19450
19450
|
LinearFilter: Ne,
|
|
19451
19451
|
LinearMipmapNearestFilter: ol,
|
|
19452
19452
|
LinearMipmapLinearFilter: rn
|
|
@@ -19518,7 +19518,7 @@ class uI extends H0 {
|
|
|
19518
19518
|
}
|
|
19519
19519
|
}
|
|
19520
19520
|
}
|
|
19521
|
-
const B5 = /* @__PURE__ */ new Pt(), P5 = /* @__PURE__ */ new Pt(),
|
|
19521
|
+
const B5 = /* @__PURE__ */ new Pt(), P5 = /* @__PURE__ */ new Pt(), ws = /* @__PURE__ */ new Pt();
|
|
19522
19522
|
class mI {
|
|
19523
19523
|
constructor() {
|
|
19524
19524
|
this.type = "StereoCamera", this.aspect = 1, this.eyeSep = 0.064, this.cameraL = new t0(), this.cameraL.layers.enable(1), this.cameraL.matrixAutoUpdate = !1, this.cameraR = new t0(), this.cameraR.layers.enable(2), this.cameraR.matrixAutoUpdate = !1, this._cache = {
|
|
@@ -19534,10 +19534,10 @@ class mI {
|
|
|
19534
19534
|
update(t) {
|
|
19535
19535
|
const e = this._cache;
|
|
19536
19536
|
if (e.focus !== t.focus || e.fov !== t.fov || e.aspect !== t.aspect * this.aspect || e.near !== t.near || e.far !== t.far || e.zoom !== t.zoom || e.eyeSep !== this.eyeSep) {
|
|
19537
|
-
e.focus = t.focus, e.fov = t.fov, e.aspect = t.aspect * this.aspect, e.near = t.near, e.far = t.far, e.zoom = t.zoom, e.eyeSep = this.eyeSep,
|
|
19537
|
+
e.focus = t.focus, e.fov = t.fov, e.aspect = t.aspect * this.aspect, e.near = t.near, e.far = t.far, e.zoom = t.zoom, e.eyeSep = this.eyeSep, ws.copy(t.projectionMatrix);
|
|
19538
19538
|
const s = e.eyeSep / 2, l = s * e.near / e.focus, a = e.near * Math.tan(dl * e.fov * 0.5) / e.zoom;
|
|
19539
19539
|
let o, c;
|
|
19540
|
-
P5.elements[12] = -s, B5.elements[12] = s, o = -a * e.aspect + l, c = a * e.aspect + l,
|
|
19540
|
+
P5.elements[12] = -s, B5.elements[12] = s, o = -a * e.aspect + l, c = a * e.aspect + l, ws.elements[0] = 2 * e.near / (c - o), ws.elements[8] = (c + o) / (c - o), this.cameraL.projectionMatrix.copy(ws), o = -a * e.aspect - l, c = a * e.aspect - l, ws.elements[0] = 2 * e.near / (c - o), ws.elements[8] = (c + o) / (c - o), this.cameraR.projectionMatrix.copy(ws);
|
|
19541
19541
|
}
|
|
19542
19542
|
this.cameraL.matrixWorld.copy(t.matrixWorld).multiply(P5), this.cameraR.matrixWorld.copy(t.matrixWorld).multiply(B5);
|
|
19543
19543
|
}
|
|
@@ -19569,7 +19569,7 @@ class im {
|
|
|
19569
19569
|
function E5() {
|
|
19570
19570
|
return (typeof performance == "undefined" ? Date : performance).now();
|
|
19571
19571
|
}
|
|
19572
|
-
const
|
|
19572
|
+
const Ks = /* @__PURE__ */ new N(), Q5 = /* @__PURE__ */ new je(), pI = /* @__PURE__ */ new N(), ks = /* @__PURE__ */ new N();
|
|
19573
19573
|
class bI extends be {
|
|
19574
19574
|
constructor() {
|
|
19575
19575
|
super(), this.type = "AudioListener", this.context = y9.getContext(), this.gain = this.context.createGain(), this.gain.connect(this.context.destination), this.filter = null, this.timeDelta = 0, this._clock = new im();
|
|
@@ -19595,11 +19595,11 @@ class bI extends be {
|
|
|
19595
19595
|
updateMatrixWorld(t) {
|
|
19596
19596
|
super.updateMatrixWorld(t);
|
|
19597
19597
|
const e = this.context.listener, n = this.up;
|
|
19598
|
-
if (this.timeDelta = this._clock.getDelta(), this.matrixWorld.decompose(
|
|
19598
|
+
if (this.timeDelta = this._clock.getDelta(), this.matrixWorld.decompose(Ks, Q5, pI), ks.set(0, 0, -1).applyQuaternion(Q5), e.positionX) {
|
|
19599
19599
|
const s = this.context.currentTime + this.timeDelta;
|
|
19600
|
-
e.positionX.linearRampToValueAtTime(
|
|
19600
|
+
e.positionX.linearRampToValueAtTime(Ks.x, s), e.positionY.linearRampToValueAtTime(Ks.y, s), e.positionZ.linearRampToValueAtTime(Ks.z, s), e.forwardX.linearRampToValueAtTime(ks.x, s), e.forwardY.linearRampToValueAtTime(ks.y, s), e.forwardZ.linearRampToValueAtTime(ks.z, s), e.upX.linearRampToValueAtTime(n.x, s), e.upY.linearRampToValueAtTime(n.y, s), e.upZ.linearRampToValueAtTime(n.z, s);
|
|
19601
19601
|
} else
|
|
19602
|
-
e.setPosition(
|
|
19602
|
+
e.setPosition(Ks.x, Ks.y, Ks.z), e.setOrientation(ks.x, ks.y, ks.z, n.x, n.y, n.z);
|
|
19603
19603
|
}
|
|
19604
19604
|
}
|
|
19605
19605
|
class XW extends be {
|
|
@@ -19724,7 +19724,7 @@ class XW extends be {
|
|
|
19724
19724
|
return this.gain.gain.setTargetAtTime(t, this.context.currentTime, 0.01), this;
|
|
19725
19725
|
}
|
|
19726
19726
|
}
|
|
19727
|
-
const
|
|
19727
|
+
const zs = /* @__PURE__ */ new N(), j5 = /* @__PURE__ */ new je(), ZI = /* @__PURE__ */ new N(), Us = /* @__PURE__ */ new N();
|
|
19728
19728
|
class GI extends XW {
|
|
19729
19729
|
constructor(t) {
|
|
19730
19730
|
super(t), this.panner = this.context.createPanner(), this.panner.panningModel = "HRTF", this.panner.connect(this.gain);
|
|
@@ -19767,13 +19767,13 @@ class GI extends XW {
|
|
|
19767
19767
|
}
|
|
19768
19768
|
updateMatrixWorld(t) {
|
|
19769
19769
|
if (super.updateMatrixWorld(t), this.hasPlaybackControl === !0 && this.isPlaying === !1) return;
|
|
19770
|
-
this.matrixWorld.decompose(
|
|
19770
|
+
this.matrixWorld.decompose(zs, j5, ZI), Us.set(0, 0, 1).applyQuaternion(j5);
|
|
19771
19771
|
const e = this.panner;
|
|
19772
19772
|
if (e.positionX) {
|
|
19773
19773
|
const n = this.context.currentTime + this.listener.timeDelta;
|
|
19774
|
-
e.positionX.linearRampToValueAtTime(
|
|
19774
|
+
e.positionX.linearRampToValueAtTime(zs.x, n), e.positionY.linearRampToValueAtTime(zs.y, n), e.positionZ.linearRampToValueAtTime(zs.z, n), e.orientationX.linearRampToValueAtTime(Us.x, n), e.orientationY.linearRampToValueAtTime(Us.y, n), e.orientationZ.linearRampToValueAtTime(Us.z, n);
|
|
19775
19775
|
} else
|
|
19776
|
-
e.setPosition(
|
|
19776
|
+
e.setPosition(zs.x, zs.y, zs.z), e.setOrientation(Us.x, Us.y, Us.z);
|
|
19777
19777
|
}
|
|
19778
19778
|
}
|
|
19779
19779
|
class XI {
|
|
@@ -21168,7 +21168,7 @@ function gW(i) {
|
|
|
21168
21168
|
}
|
|
21169
21169
|
class fW extends Gt {
|
|
21170
21170
|
constructor(t, e, n) {
|
|
21171
|
-
const s = new
|
|
21171
|
+
const s = new gs(e, 4, 2), l = new Dt({ wireframe: !0, fog: !1, toneMapped: !1 });
|
|
21172
21172
|
super(s, l), this.light = t, this.color = n, this.type = "PointLightHelper", this.matrix = this.light.matrixWorld, this.matrixAutoUpdate = !1, this.update();
|
|
21173
21173
|
}
|
|
21174
21174
|
dispose() {
|
|
@@ -21556,7 +21556,7 @@ typeof window != "undefined" && (window.__THREE__ ? console.warn("WARNING: Multi
|
|
|
21556
21556
|
const f9 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
21557
21557
|
__proto__: null,
|
|
21558
21558
|
ACESFilmicToneMapping: ry,
|
|
21559
|
-
AddEquation:
|
|
21559
|
+
AddEquation: rs,
|
|
21560
21560
|
AddOperation: ay,
|
|
21561
21561
|
AdditiveAnimationBlendMode: U2,
|
|
21562
21562
|
AdditiveBlending: qo,
|
|
@@ -21645,7 +21645,7 @@ const f9 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
21645
21645
|
DecrementWrapStencilOp: gR,
|
|
21646
21646
|
DefaultLoadingManager: uW,
|
|
21647
21647
|
DepthFormat: cl,
|
|
21648
|
-
DepthStencilFormat:
|
|
21648
|
+
DepthStencilFormat: Xs,
|
|
21649
21649
|
DepthTexture: wu,
|
|
21650
21650
|
DetachedBindMode: py,
|
|
21651
21651
|
DirectionalLight: tm,
|
|
@@ -21707,13 +21707,13 @@ const f9 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
21707
21707
|
Int8BufferAttribute: Gx,
|
|
21708
21708
|
IntType: Cu,
|
|
21709
21709
|
InterleavedBuffer: Kc,
|
|
21710
|
-
InterleavedBufferAttribute:
|
|
21710
|
+
InterleavedBufferAttribute: ys,
|
|
21711
21711
|
Interpolant: Da,
|
|
21712
21712
|
InterpolateDiscrete: Sa,
|
|
21713
21713
|
InterpolateLinear: La,
|
|
21714
21714
|
InterpolateSmooth: vr,
|
|
21715
21715
|
InvertStencilOp: fR,
|
|
21716
|
-
KeepStencilOp:
|
|
21716
|
+
KeepStencilOp: js,
|
|
21717
21717
|
KeyframeTrack: ni,
|
|
21718
21718
|
LOD: Ey,
|
|
21719
21719
|
LatheGeometry: ja,
|
|
@@ -21724,7 +21724,7 @@ const f9 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
21724
21724
|
LessEqualDepth: ga,
|
|
21725
21725
|
LessEqualStencilFunc: LR,
|
|
21726
21726
|
LessStencilFunc: xR,
|
|
21727
|
-
Light:
|
|
21727
|
+
Light: fs,
|
|
21728
21728
|
LightProbe: bW,
|
|
21729
21729
|
Line: v0,
|
|
21730
21730
|
Line3: wI,
|
|
@@ -21745,7 +21745,7 @@ const f9 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
21745
21745
|
LinearToneMapping: oy,
|
|
21746
21746
|
LinearTransfer: ec,
|
|
21747
21747
|
Loader: H0,
|
|
21748
|
-
LoaderUtils:
|
|
21748
|
+
LoaderUtils: bs,
|
|
21749
21749
|
LoadingManager: qu,
|
|
21750
21750
|
LoopOnce: by,
|
|
21751
21751
|
LoopPingPong: Gy,
|
|
@@ -21778,7 +21778,7 @@ const f9 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
21778
21778
|
NearestFilter: ze,
|
|
21779
21779
|
NearestMipMapLinearFilter: mR,
|
|
21780
21780
|
NearestMipMapNearestFilter: uR,
|
|
21781
|
-
NearestMipmapLinearFilter:
|
|
21781
|
+
NearestMipmapLinearFilter: hs,
|
|
21782
21782
|
NearestMipmapNearestFilter: Nc,
|
|
21783
21783
|
NeutralToneMapping: my,
|
|
21784
21784
|
NeverCompare: Wy,
|
|
@@ -21819,7 +21819,7 @@ const f9 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
21819
21819
|
Points: Eu,
|
|
21820
21820
|
PointsMaterial: Pu,
|
|
21821
21821
|
PolarGridHelper: UI,
|
|
21822
|
-
PolyhedronGeometry:
|
|
21822
|
+
PolyhedronGeometry: Vs,
|
|
21823
21823
|
PositionalAudio: GI,
|
|
21824
21824
|
PropertyBinding: Le,
|
|
21825
21825
|
PropertyMixer: yW,
|
|
@@ -21898,7 +21898,7 @@ const f9 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
21898
21898
|
SkinnedMesh: q2,
|
|
21899
21899
|
Source: el,
|
|
21900
21900
|
Sphere: F0,
|
|
21901
|
-
SphereGeometry:
|
|
21901
|
+
SphereGeometry: gs,
|
|
21902
21902
|
Spherical: FI,
|
|
21903
21903
|
SphericalHarmonics3: pW,
|
|
21904
21904
|
SplineCurve: o9,
|
|
@@ -21920,7 +21920,7 @@ const f9 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
21920
21920
|
SubtractEquation: UX,
|
|
21921
21921
|
SubtractiveBlending: sp,
|
|
21922
21922
|
TOUCH: dR,
|
|
21923
|
-
TangentSpaceNormalMap:
|
|
21923
|
+
TangentSpaceNormalMap: Ws,
|
|
21924
21924
|
TetrahedronGeometry: Dc,
|
|
21925
21925
|
Texture: Je,
|
|
21926
21926
|
TextureLoader: m9,
|
|
@@ -21942,7 +21942,7 @@ const f9 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
21942
21942
|
UniformsLib: It,
|
|
21943
21943
|
UniformsUtils: Fc,
|
|
21944
21944
|
UnsignedByteType: L0,
|
|
21945
|
-
UnsignedInt248Type:
|
|
21945
|
+
UnsignedInt248Type: Gs,
|
|
21946
21946
|
UnsignedInt5999Type: F2,
|
|
21947
21947
|
UnsignedIntType: Xi,
|
|
21948
21948
|
UnsignedShort4444Type: Yu,
|
|
@@ -22147,18 +22147,18 @@ var rl = Object.freeze({
|
|
|
22147
22147
|
return !0;
|
|
22148
22148
|
}, i;
|
|
22149
22149
|
}()
|
|
22150
|
-
),
|
|
22150
|
+
), us = {
|
|
22151
22151
|
Linear: function(i, t) {
|
|
22152
|
-
var e = i.length - 1, n = e * t, s = Math.floor(n), l =
|
|
22152
|
+
var e = i.length - 1, n = e * t, s = Math.floor(n), l = us.Utils.Linear;
|
|
22153
22153
|
return t < 0 ? l(i[0], i[1], n) : t > 1 ? l(i[e], i[e - 1], e - n) : l(i[s], i[s + 1 > e ? e : s + 1], n - s);
|
|
22154
22154
|
},
|
|
22155
22155
|
Bezier: function(i, t) {
|
|
22156
|
-
for (var e = 0, n = i.length - 1, s = Math.pow, l =
|
|
22156
|
+
for (var e = 0, n = i.length - 1, s = Math.pow, l = us.Utils.Bernstein, a = 0; a <= n; a++)
|
|
22157
22157
|
e += s(1 - t, n - a) * s(t, a) * i[a] * l(n, a);
|
|
22158
22158
|
return e;
|
|
22159
22159
|
},
|
|
22160
22160
|
CatmullRom: function(i, t) {
|
|
22161
|
-
var e = i.length - 1, n = e * t, s = Math.floor(n), l =
|
|
22161
|
+
var e = i.length - 1, n = e * t, s = Math.floor(n), l = us.Utils.CatmullRom;
|
|
22162
22162
|
return i[0] === i[e] ? (t < 0 && (s = Math.floor(n = e * (1 + t))), l(i[(s - 1 + e) % e], i[s], i[(s + 1) % e], i[(s + 2) % e], n - s)) : t < 0 ? i[0] - (l(i[0], i[0], i[1], i[1], -n) - i[0]) : t > 1 ? i[e] - (l(i[e], i[e], i[e - 1], i[e - 1], n - e) - i[e]) : l(i[s ? s - 1 : 0], i[s], i[e < s + 1 ? e : s + 1], i[e < s + 2 ? e : s + 2], n - s);
|
|
22163
22163
|
},
|
|
22164
22164
|
Utils: {
|
|
@@ -22166,7 +22166,7 @@ var rl = Object.freeze({
|
|
|
22166
22166
|
return (t - i) * e + i;
|
|
22167
22167
|
},
|
|
22168
22168
|
Bernstein: function(i, t) {
|
|
22169
|
-
var e =
|
|
22169
|
+
var e = us.Utils.Factorial;
|
|
22170
22170
|
return e(i) / e(t) / e(i - t);
|
|
22171
22171
|
},
|
|
22172
22172
|
Factorial: /* @__PURE__ */ function() {
|
|
@@ -22198,7 +22198,7 @@ var rl = Object.freeze({
|
|
|
22198
22198
|
/** @class */
|
|
22199
22199
|
function() {
|
|
22200
22200
|
function i(t, e) {
|
|
22201
|
-
e === void 0 && (e = Gp), this._object = t, this._group = e, this._isPaused = !1, this._pauseStart = 0, this._valuesStart = {}, this._valuesEnd = {}, this._valuesStartRepeat = {}, this._duration = 1e3, this._isDynamic = !1, this._initialRepeat = 0, this._repeat = 0, this._yoyo = !1, this._isPlaying = !1, this._reversed = !1, this._delayTime = 0, this._startTime = 0, this._easingFunction = rl.Linear.None, this._interpolationFunction =
|
|
22201
|
+
e === void 0 && (e = Gp), this._object = t, this._group = e, this._isPaused = !1, this._pauseStart = 0, this._valuesStart = {}, this._valuesEnd = {}, this._valuesStartRepeat = {}, this._duration = 1e3, this._isDynamic = !1, this._initialRepeat = 0, this._repeat = 0, this._yoyo = !1, this._isPlaying = !1, this._reversed = !1, this._delayTime = 0, this._startTime = 0, this._easingFunction = rl.Linear.None, this._interpolationFunction = us.Linear, this._chainedTweens = [], this._onStartCallbackFired = !1, this._onEveryStartCallbackFired = !1, this._id = sm.nextId(), this._isChainStopped = !1, this._propertiesAreSetUp = !1, this._goToEnd = !1;
|
|
22202
22202
|
}
|
|
22203
22203
|
return i.prototype.getId = function() {
|
|
22204
22204
|
return this._id;
|
|
@@ -22297,7 +22297,7 @@ var rl = Object.freeze({
|
|
|
22297
22297
|
}, i.prototype.easing = function(t) {
|
|
22298
22298
|
return t === void 0 && (t = rl.Linear.None), this._easingFunction = t, this;
|
|
22299
22299
|
}, i.prototype.interpolation = function(t) {
|
|
22300
|
-
return t === void 0 && (t =
|
|
22300
|
+
return t === void 0 && (t = us.Linear), this._interpolationFunction = t, this;
|
|
22301
22301
|
}, i.prototype.chain = function() {
|
|
22302
22302
|
for (var t = [], e = 0; e < arguments.length; e++)
|
|
22303
22303
|
t[e] = arguments[e];
|
|
@@ -22367,7 +22367,7 @@ var rl = Object.freeze({
|
|
|
22367
22367
|
), LW = "23.1.2", CW = sm.nextId, yi = Gp, YW = yi.getAll.bind(yi), x9 = yi.removeAll.bind(yi), IW = yi.add.bind(yi), lm = yi.remove.bind(yi), S9 = yi.update.bind(yi), NW = {
|
|
22368
22368
|
Easing: rl,
|
|
22369
22369
|
Group: R9,
|
|
22370
|
-
Interpolation:
|
|
22370
|
+
Interpolation: us,
|
|
22371
22371
|
now: il,
|
|
22372
22372
|
Sequence: sm,
|
|
22373
22373
|
nextId: CW,
|
|
@@ -22383,7 +22383,7 @@ const EU = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
22383
22383
|
__proto__: null,
|
|
22384
22384
|
Easing: rl,
|
|
22385
22385
|
Group: R9,
|
|
22386
|
-
Interpolation:
|
|
22386
|
+
Interpolation: us,
|
|
22387
22387
|
Sequence: sm,
|
|
22388
22388
|
Tween: sl,
|
|
22389
22389
|
VERSION: LW,
|
|
@@ -24311,7 +24311,7 @@ function zh(i) {
|
|
|
24311
24311
|
var t = Ui(i[0] * i[0] + i[1] * i[1] + i[2] * i[2]);
|
|
24312
24312
|
i[0] /= t, i[1] /= t, i[2] /= t;
|
|
24313
24313
|
}
|
|
24314
|
-
var d0, cn, b0, Vn,
|
|
24314
|
+
var d0, cn, b0, Vn, Ds, jW, AW, Xa, Eo, cs, Ei, Ii = {
|
|
24315
24315
|
point: xp,
|
|
24316
24316
|
lineStart: mZ,
|
|
24317
24317
|
lineEnd: pZ,
|
|
@@ -24326,18 +24326,18 @@ var d0, cn, b0, Vn, As, jW, AW, Xa, Eo, os, Ei, Ii = {
|
|
|
24326
24326
|
}
|
|
24327
24327
|
};
|
|
24328
24328
|
function xp(i, t) {
|
|
24329
|
-
|
|
24329
|
+
cs.push(Ei = [d0 = i, b0 = i]), t < cn && (cn = t), t > Vn && (Vn = t);
|
|
24330
24330
|
}
|
|
24331
24331
|
function DW(i, t) {
|
|
24332
24332
|
var e = gl([i * ae, t * ae]);
|
|
24333
24333
|
if (Xa) {
|
|
24334
24334
|
var n = Ma(Xa, e), s = [n[1], -n[0], 0], l = Ma(s, n);
|
|
24335
24335
|
zh(l), l = kh(l);
|
|
24336
|
-
var a = i -
|
|
24337
|
-
r ^ (o *
|
|
24336
|
+
var a = i - Ds, o = a > 0 ? 1 : -1, c = l[0] * Z0 * o, d, r = e0(a) > 180;
|
|
24337
|
+
r ^ (o * Ds < c && c < o * i) ? (d = l[1] * Z0, d > Vn && (Vn = d)) : (c = (c + 360) % 360 - 180, r ^ (o * Ds < c && c < o * i) ? (d = -l[1] * Z0, d < cn && (cn = d)) : (t < cn && (cn = t), t > Vn && (Vn = t))), r ? i < Ds ? yn(d0, i) > yn(d0, b0) && (b0 = i) : yn(i, b0) > yn(d0, b0) && (d0 = i) : b0 >= d0 ? (i < d0 && (d0 = i), i > b0 && (b0 = i)) : i > Ds ? yn(d0, i) > yn(d0, b0) && (b0 = i) : yn(i, b0) > yn(d0, b0) && (d0 = i);
|
|
24338
24338
|
} else
|
|
24339
|
-
|
|
24340
|
-
t < cn && (cn = t), t > Vn && (Vn = t), Xa = e,
|
|
24339
|
+
cs.push(Ei = [d0 = i, b0 = i]);
|
|
24340
|
+
t < cn && (cn = t), t > Vn && (Vn = t), Xa = e, Ds = i;
|
|
24341
24341
|
}
|
|
24342
24342
|
function mZ() {
|
|
24343
24343
|
Ii.point = DW;
|
|
@@ -24347,7 +24347,7 @@ function pZ() {
|
|
|
24347
24347
|
}
|
|
24348
24348
|
function OW(i, t) {
|
|
24349
24349
|
if (Xa) {
|
|
24350
|
-
var e = i -
|
|
24350
|
+
var e = i - Ds;
|
|
24351
24351
|
Eo.add(e0(e) > 180 ? e + (e > 0 ? 360 : -360) : e);
|
|
24352
24352
|
} else
|
|
24353
24353
|
jW = i, AW = t;
|
|
@@ -24370,13 +24370,13 @@ function bZ(i, t) {
|
|
|
24370
24370
|
}
|
|
24371
24371
|
function _W(i) {
|
|
24372
24372
|
var t, e, n, s, l, a, o;
|
|
24373
|
-
if (Vn = b0 = -(d0 = cn = 1 / 0),
|
|
24374
|
-
for (
|
|
24375
|
-
s =
|
|
24373
|
+
if (Vn = b0 = -(d0 = cn = 1 / 0), cs = [], om(i, Ii), e = cs.length) {
|
|
24374
|
+
for (cs.sort($N), t = 1, n = cs[0], l = [n]; t < e; ++t)
|
|
24375
|
+
s = cs[t], bZ(n, s[0]) || bZ(n, s[1]) ? (yn(n[0], s[1]) > yn(n[0], n[1]) && (n[1] = s[1]), yn(s[0], n[1]) > yn(n[0], n[1]) && (n[0] = s[0])) : l.push(n = s);
|
|
24376
24376
|
for (a = -1 / 0, e = l.length - 1, t = 0, n = l[e]; t <= e; n = s, ++t)
|
|
24377
24377
|
s = l[t], (o = yn(n[1], s[0])) > a && (a = o, d0 = s[0], b0 = n[1]);
|
|
24378
24378
|
}
|
|
24379
|
-
return
|
|
24379
|
+
return cs = Ei = null, d0 === 1 / 0 || cn === 1 / 0 ? [[NaN, NaN], [NaN, NaN]] : [[d0, cn], [b0, Vn]];
|
|
24380
24380
|
}
|
|
24381
24381
|
var No, Uh, Bh, Ph, Eh, Qh, jh, Ah, Sp, Lp, Cp, qW, $W, O0, _0, q0, On = {
|
|
24382
24382
|
sphere: P0,
|
|
@@ -25674,7 +25674,7 @@ class Dv extends v0 {
|
|
|
25674
25674
|
this.geometry.dispose(), this.material.dispose(), this.children[0].geometry.dispose(), this.children[0].material.dispose();
|
|
25675
25675
|
}
|
|
25676
25676
|
}
|
|
25677
|
-
const
|
|
25677
|
+
const Bs = new g9(), B0 = new N(), es = new N(), l0 = new je(), JZ = {
|
|
25678
25678
|
X: new N(1, 0, 0),
|
|
25679
25679
|
Y: new N(0, 1, 0),
|
|
25680
25680
|
Z: new N(0, 0, 1)
|
|
@@ -25708,14 +25708,14 @@ class Ov extends be {
|
|
|
25708
25708
|
}
|
|
25709
25709
|
pointerHover(t) {
|
|
25710
25710
|
if (this.object === void 0 || this.dragging === !0) return;
|
|
25711
|
-
t !== null &&
|
|
25712
|
-
const e = r1(this._gizmo.picker[this.mode],
|
|
25711
|
+
t !== null && Bs.setFromCamera(t, this.camera);
|
|
25712
|
+
const e = r1(this._gizmo.picker[this.mode], Bs);
|
|
25713
25713
|
e ? this.axis = e.object.name : this.axis = null;
|
|
25714
25714
|
}
|
|
25715
25715
|
pointerDown(t) {
|
|
25716
25716
|
if (!(this.object === void 0 || this.dragging === !0 || t != null && t.button !== 0) && this.axis !== null) {
|
|
25717
|
-
t !== null &&
|
|
25718
|
-
const e = r1(this._plane,
|
|
25717
|
+
t !== null && Bs.setFromCamera(t, this.camera);
|
|
25718
|
+
const e = r1(this._plane, Bs, !0);
|
|
25719
25719
|
e && (this.object.updateMatrixWorld(), this.object.parent.updateMatrixWorld(), this._positionStart.copy(this.object.position), this._quaternionStart.copy(this.object.quaternion), this._scaleStart.copy(this.object.scale), this.object.matrixWorld.decompose(this.worldPositionStart, this.worldQuaternionStart, this._worldScaleStart), this.pointStart.copy(e.point).sub(this.worldPositionStart)), this.dragging = !0, wZ.mode = this.mode, this.dispatchEvent(wZ);
|
|
25720
25720
|
}
|
|
25721
25721
|
}
|
|
@@ -25723,8 +25723,8 @@ class Ov extends be {
|
|
|
25723
25723
|
const e = this.axis, n = this.mode, s = this.object;
|
|
25724
25724
|
let l = this.space;
|
|
25725
25725
|
if (n === "scale" ? l = "local" : (e === "E" || e === "XYZE" || e === "XYZ") && (l = "world"), s === void 0 || e === null || this.dragging === !1 || t !== null && t.button !== -1) return;
|
|
25726
|
-
t !== null &&
|
|
25727
|
-
const a = r1(this._plane,
|
|
25726
|
+
t !== null && Bs.setFromCamera(t, this.camera);
|
|
25727
|
+
const a = r1(this._plane, Bs, !0);
|
|
25728
25728
|
if (a) {
|
|
25729
25729
|
if (this.pointEnd.copy(a.point).sub(this.worldPositionStart), n === "translate")
|
|
25730
25730
|
this._offset.copy(this.pointEnd).sub(this.pointStart), l === "local" && e !== "XYZ" && this._offset.applyQuaternion(this._worldQuaternionInv), e.indexOf("X") === -1 && (this._offset.x = 0), e.indexOf("Y") === -1 && (this._offset.y = 0), e.indexOf("Z") === -1 && (this._offset.z = 0), l === "local" && e !== "XYZ" ? this._offset.applyQuaternion(this._quaternionStart).divide(this._parentScale) : this._offset.applyQuaternion(this._parentQuaternionInv).divide(this._parentScale), s.position.copy(this._offset).add(this._positionStart), this.translationSnap && (l === "local" && (s.position.applyQuaternion(l0.copy(this._quaternionStart).invert()), e.search("X") !== -1 && (s.position.x = Math.round(s.position.x / this.translationSnap) * this.translationSnap), e.search("Y") !== -1 && (s.position.y = Math.round(s.position.y / this.translationSnap) * this.translationSnap), e.search("Z") !== -1 && (s.position.z = Math.round(s.position.z / this.translationSnap) * this.translationSnap), s.position.applyQuaternion(this._quaternionStart)), l === "world" && (s.parent && s.position.add(B0.setFromMatrixPosition(s.parent.matrixWorld)), e.search("X") !== -1 && (s.position.x = Math.round(s.position.x / this.translationSnap) * this.translationSnap), e.search("Y") !== -1 && (s.position.y = Math.round(s.position.y / this.translationSnap) * this.translationSnap), e.search("Z") !== -1 && (s.position.z = Math.round(s.position.z / this.translationSnap) * this.translationSnap), s.parent && s.position.sub(B0.setFromMatrixPosition(s.parent.matrixWorld))));
|
|
@@ -25764,7 +25764,7 @@ class Ov extends be {
|
|
|
25764
25764
|
this.enabled && this.dragging && (this.object.position.copy(this._positionStart), this.object.quaternion.copy(this._quaternionStart), this.object.scale.copy(this._scaleStart), this.dispatchEvent(d1), this.dispatchEvent(kZ), this.pointStart.copy(this.pointEnd));
|
|
25765
25765
|
}
|
|
25766
25766
|
getRaycaster() {
|
|
25767
|
-
return
|
|
25767
|
+
return Bs;
|
|
25768
25768
|
}
|
|
25769
25769
|
// TODO: deprecate
|
|
25770
25770
|
getMode() {
|
|
@@ -25830,7 +25830,7 @@ function r1(i, t, e) {
|
|
|
25830
25830
|
return n[s];
|
|
25831
25831
|
return !1;
|
|
25832
25832
|
}
|
|
25833
|
-
const ur = new E0(), Oe = new N(0, 1, 0), zZ = new N(0, 0, 0), UZ = new Pt(), mr = new je(), kr = new je(), li = new N(), BZ = new Pt(), To = new N(1, 0, 0),
|
|
25833
|
+
const ur = new E0(), Oe = new N(0, 1, 0), zZ = new N(0, 0, 0), UZ = new Pt(), mr = new je(), kr = new je(), li = new N(), BZ = new Pt(), To = new N(1, 0, 0), Os = new N(0, 1, 0), Mo = new N(0, 0, 1), pr = new N(), Zo = new N(), Go = new N();
|
|
25834
25834
|
class nT extends be {
|
|
25835
25835
|
constructor() {
|
|
25836
25836
|
super(), this.isTransformControlsGizmo = !0, this.type = "TransformControlsGizmo";
|
|
@@ -25978,7 +25978,7 @@ class nT extends be {
|
|
|
25978
25978
|
]
|
|
25979
25979
|
}, R = {
|
|
25980
25980
|
XYZE: [
|
|
25981
|
-
[new Gt(new
|
|
25981
|
+
[new Gt(new gs(0.25, 10, 8), n)]
|
|
25982
25982
|
],
|
|
25983
25983
|
X: [
|
|
25984
25984
|
[new Gt(new An(0.5, 0.1, 4, 24), n), [0, 0, 0], [0, -Math.PI / 2, -Math.PI / 2]]
|
|
@@ -26080,10 +26080,10 @@ class nT extends be {
|
|
|
26080
26080
|
a.visible = !0, a.rotation.set(0, 0, 0), a.position.copy(this.worldPosition);
|
|
26081
26081
|
let o;
|
|
26082
26082
|
if (this.camera.isOrthographicCamera ? o = (this.camera.top - this.camera.bottom) / this.camera.zoom : o = this.worldPosition.distanceTo(this.cameraPosition) * Math.min(1.9 * Math.tan(Math.PI * this.camera.fov / 360) / this.camera.zoom, 7), a.scale.set(1, 1, 1).multiplyScalar(o * this.size / 4), a.tag === "helper") {
|
|
26083
|
-
a.visible = !1, a.name === "AXIS" ? (a.visible = !!this.axis, this.axis === "X" && (l0.setFromEuler(ur.set(0, 0, 0)), a.quaternion.copy(n).multiply(l0), Math.abs(Oe.copy(To).applyQuaternion(n).dot(this.eye)) > 0.9 && (a.visible = !1)), this.axis === "Y" && (l0.setFromEuler(ur.set(0, 0, Math.PI / 2)), a.quaternion.copy(n).multiply(l0), Math.abs(Oe.copy(
|
|
26083
|
+
a.visible = !1, a.name === "AXIS" ? (a.visible = !!this.axis, this.axis === "X" && (l0.setFromEuler(ur.set(0, 0, 0)), a.quaternion.copy(n).multiply(l0), Math.abs(Oe.copy(To).applyQuaternion(n).dot(this.eye)) > 0.9 && (a.visible = !1)), this.axis === "Y" && (l0.setFromEuler(ur.set(0, 0, Math.PI / 2)), a.quaternion.copy(n).multiply(l0), Math.abs(Oe.copy(Os).applyQuaternion(n).dot(this.eye)) > 0.9 && (a.visible = !1)), this.axis === "Z" && (l0.setFromEuler(ur.set(0, Math.PI / 2, 0)), a.quaternion.copy(n).multiply(l0), Math.abs(Oe.copy(Mo).applyQuaternion(n).dot(this.eye)) > 0.9 && (a.visible = !1)), this.axis === "XYZE" && (l0.setFromEuler(ur.set(0, Math.PI / 2, 0)), Oe.copy(this.rotationAxis), a.quaternion.setFromRotationMatrix(UZ.lookAt(zZ, Oe, Os)), a.quaternion.multiply(l0), a.visible = this.dragging), this.axis === "E" && (a.visible = !1)) : a.name === "START" ? (a.position.copy(this.worldPositionStart), a.visible = this.dragging) : a.name === "END" ? (a.position.copy(this.worldPosition), a.visible = this.dragging) : a.name === "DELTA" ? (a.position.copy(this.worldPositionStart), a.quaternion.copy(this.worldQuaternionStart), B0.set(1e-10, 1e-10, 1e-10).add(this.worldPositionStart).sub(this.worldPosition).multiplyScalar(-1), B0.applyQuaternion(this.worldQuaternionStart.clone().invert()), a.scale.copy(B0), a.visible = this.dragging) : (a.quaternion.copy(n), this.dragging ? a.position.copy(this.worldPositionStart) : a.position.copy(this.worldPosition), this.axis && (a.visible = this.axis.search(a.name) !== -1));
|
|
26084
26084
|
continue;
|
|
26085
26085
|
}
|
|
26086
|
-
a.quaternion.copy(n), this.mode === "translate" || this.mode === "scale" ? (a.name === "X" && Math.abs(Oe.copy(To).applyQuaternion(n).dot(this.eye)) > 0.99 && (a.scale.set(1e-10, 1e-10, 1e-10), a.visible = !1), a.name === "Y" && Math.abs(Oe.copy(
|
|
26086
|
+
a.quaternion.copy(n), this.mode === "translate" || this.mode === "scale" ? (a.name === "X" && Math.abs(Oe.copy(To).applyQuaternion(n).dot(this.eye)) > 0.99 && (a.scale.set(1e-10, 1e-10, 1e-10), a.visible = !1), a.name === "Y" && Math.abs(Oe.copy(Os).applyQuaternion(n).dot(this.eye)) > 0.99 && (a.scale.set(1e-10, 1e-10, 1e-10), a.visible = !1), a.name === "Z" && Math.abs(Oe.copy(Mo).applyQuaternion(n).dot(this.eye)) > 0.99 && (a.scale.set(1e-10, 1e-10, 1e-10), a.visible = !1), a.name === "XY" && Math.abs(Oe.copy(Mo).applyQuaternion(n).dot(this.eye)) < 0.2 && (a.scale.set(1e-10, 1e-10, 1e-10), a.visible = !1), a.name === "YZ" && Math.abs(Oe.copy(To).applyQuaternion(n).dot(this.eye)) < 0.2 && (a.scale.set(1e-10, 1e-10, 1e-10), a.visible = !1), a.name === "XZ" && Math.abs(Oe.copy(Os).applyQuaternion(n).dot(this.eye)) < 0.2 && (a.scale.set(1e-10, 1e-10, 1e-10), a.visible = !1)) : this.mode === "rotate" && (mr.copy(n), Oe.copy(this.eye).applyQuaternion(l0.copy(n).invert()), a.name.search("E") !== -1 && a.quaternion.setFromRotationMatrix(UZ.lookAt(this.eye, zZ, Os)), a.name === "X" && (l0.setFromAxisAngle(To, Math.atan2(-Oe.y, Oe.z)), l0.multiplyQuaternions(mr, l0), a.quaternion.copy(l0)), a.name === "Y" && (l0.setFromAxisAngle(Os, Math.atan2(Oe.x, Oe.z)), l0.multiplyQuaternions(mr, l0), a.quaternion.copy(l0)), a.name === "Z" && (l0.setFromAxisAngle(Mo, Math.atan2(Oe.y, Oe.x)), l0.multiplyQuaternions(mr, l0), a.quaternion.copy(l0))), a.visible = a.visible && (a.name.indexOf("X") === -1 || this.showX), a.visible = a.visible && (a.name.indexOf("Y") === -1 || this.showY), a.visible = a.visible && (a.name.indexOf("Z") === -1 || this.showZ), a.visible = a.visible && (a.name.indexOf("E") === -1 || this.showX && this.showY && this.showZ), a.material._color = a.material._color || a.material.color.clone(), a.material._opacity = a.material._opacity || a.material.opacity, a.material.color.copy(a.material._color), a.material.opacity = a.material._opacity, this.enabled && this.axis && (a.name === this.axis || this.axis.split("").some(function(c) {
|
|
26087
26087
|
return a.name === c;
|
|
26088
26088
|
})) && (a.material.color.setHex(16776960), a.material.opacity = 1);
|
|
26089
26089
|
}
|
|
@@ -26099,7 +26099,7 @@ class iT extends Gt {
|
|
|
26099
26099
|
}
|
|
26100
26100
|
updateMatrixWorld(t) {
|
|
26101
26101
|
let e = this.space;
|
|
26102
|
-
switch (this.position.copy(this.worldPosition), this.mode === "scale" && (e = "local"), pr.copy(To).applyQuaternion(e === "local" ? this.worldQuaternion : kr), Zo.copy(
|
|
26102
|
+
switch (this.position.copy(this.worldPosition), this.mode === "scale" && (e = "local"), pr.copy(To).applyQuaternion(e === "local" ? this.worldQuaternion : kr), Zo.copy(Os).applyQuaternion(e === "local" ? this.worldQuaternion : kr), Go.copy(Mo).applyQuaternion(e === "local" ? this.worldQuaternion : kr), Oe.copy(Zo), this.mode) {
|
|
26103
26103
|
case "translate":
|
|
26104
26104
|
case "scale":
|
|
26105
26105
|
switch (this.axis) {
|
|
@@ -26958,7 +26958,7 @@ uniform float opacity;varying vec2 vUv;void main(){vec4 texel=texture2D(inputBuf
|
|
|
26958
26958
|
*/
|
|
26959
26959
|
createDepthTexture() {
|
|
26960
26960
|
const i = this.depthTexture = new wu();
|
|
26961
|
-
return this.inputBuffer.depthTexture = i, this.inputBuffer.dispose(), this.inputBuffer.stencilBuffer ? (i.format =
|
|
26961
|
+
return this.inputBuffer.depthTexture = i, this.inputBuffer.dispose(), this.inputBuffer.stencilBuffer ? (i.format = Xs, i.type = Gs) : i.type = Xi, i;
|
|
26962
26962
|
}
|
|
26963
26963
|
/**
|
|
26964
26964
|
* Deletes the current depth texture.
|
|
@@ -27089,7 +27089,7 @@ uniform float opacity;varying vec2 vUv;void main(){vec4 texel=texture2D(inputBuf
|
|
|
27089
27089
|
i.dispose();
|
|
27090
27090
|
this.passes = [], this.inputBuffer !== null && this.inputBuffer.dispose(), this.outputBuffer !== null && this.outputBuffer.dispose(), this.deleteDepthTexture(), this.copyPass.dispose(), this.timer.dispose();
|
|
27091
27091
|
}
|
|
27092
|
-
},
|
|
27092
|
+
}, Zs = {
|
|
27093
27093
|
NONE: 0,
|
|
27094
27094
|
DEPTH: 1,
|
|
27095
27095
|
CONVOLUTION: 2
|
|
@@ -27110,7 +27110,7 @@ uniform float opacity;varying vec2 vUv;void main(){vec4 texel=texture2D(inputBuf
|
|
|
27110
27110
|
[Me.FRAGMENT_MAIN_IMAGE, null],
|
|
27111
27111
|
[Me.VERTEX_HEAD, null],
|
|
27112
27112
|
[Me.VERTEX_MAIN_SUPPORT, null]
|
|
27113
|
-
]), this.defines = /* @__PURE__ */ new Map(), this.uniforms = /* @__PURE__ */ new Map(), this.blendModes = /* @__PURE__ */ new Map(), this.extensions = /* @__PURE__ */ new Set(), this.attributes =
|
|
27113
|
+
]), this.defines = /* @__PURE__ */ new Map(), this.uniforms = /* @__PURE__ */ new Map(), this.blendModes = /* @__PURE__ */ new Map(), this.extensions = /* @__PURE__ */ new Set(), this.attributes = Zs.NONE, this.varyings = /* @__PURE__ */ new Set(), this.uvTransformation = !1, this.readDepth = !1, this.colorSpace = u0;
|
|
27114
27114
|
}
|
|
27115
27115
|
}, u1 = !1, _Z = class {
|
|
27116
27116
|
/**
|
|
@@ -28695,7 +28695,7 @@ uniform float radius;varying vec2 vUv;varying vec2 vUv0;varying vec2 vUv1;varyin
|
|
|
28695
28695
|
* @param {String} [options.vertexShader=null] - The vertex shader. Most effects don't need one.
|
|
28696
28696
|
*/
|
|
28697
28697
|
constructor(i, t, {
|
|
28698
|
-
attributes: e =
|
|
28698
|
+
attributes: e = Zs.NONE,
|
|
28699
28699
|
blendFunction: n = pe.NORMAL,
|
|
28700
28700
|
defines: s = /* @__PURE__ */ new Map(),
|
|
28701
28701
|
uniforms: l = /* @__PURE__ */ new Map(),
|
|
@@ -29824,7 +29824,7 @@ if(keep){gl_FragColor=texture2D(inputBuffer,vUv);}else{discard;}}`, V7 = class e
|
|
|
29824
29824
|
* @param {Object} [options] - The options. See {@link BloomEffect} for details.
|
|
29825
29825
|
*/
|
|
29826
29826
|
constructor(i, t, e) {
|
|
29827
|
-
super(e), this.setAttributes(this.getAttributes() |
|
|
29827
|
+
super(e), this.setAttributes(this.getAttributes() | Zs.DEPTH), this.camera = t, this.depthPass = new g7(i, t), this.clearPass = new K9(!0, !1, !1), this.clearPass.overrideClearColor = new lt(0), this.depthMaskPass = new Z7(new V7());
|
|
29828
29828
|
const n = this.depthMaskMaterial;
|
|
29829
29829
|
n.copyCameraSettings(t), n.depthBuffer1 = this.depthPass.texture, n.depthPacking1 = Mu, n.depthMode = $o, this.renderTargetMasked = new s0(1, 1, { depthBuffer: !1 }), this.renderTargetMasked.texture.name = "Bloom.Masked", this.selection = new yT(), this.selection.layer = 11, this._inverted = !1, this._ignoreBackground = !1;
|
|
29830
29830
|
}
|
|
@@ -30743,7 +30743,7 @@ function v7(i, t, e) {
|
|
|
30743
30743
|
const l = n !== void 0 && /mainImage/.test(n), a = n !== void 0 && /mainUv/.test(n);
|
|
30744
30744
|
if (e.attributes |= t.getAttributes(), n === void 0)
|
|
30745
30745
|
throw new Error(`Missing fragment shader (${t.name})`);
|
|
30746
|
-
if (a && e.attributes &
|
|
30746
|
+
if (a && e.attributes & Zs.CONVOLUTION)
|
|
30747
30747
|
throw new Error(`Effects that transform UVs are incompatible with convolution effects (${t.name})`);
|
|
30748
30748
|
if (!l && !a)
|
|
30749
30749
|
throw new Error(`Could not find mainImage or mainUv function (${t.name})`);
|
|
@@ -30778,7 +30778,7 @@ function v7(i, t, e) {
|
|
|
30778
30778
|
` : `color0 = sRGBToLinear(color0);
|
|
30779
30779
|
`), t.outputColorSpace !== dn ? e.colorSpace = t.outputColorSpace : t.inputColorSpace !== null && (e.colorSpace = t.inputColorSpace);
|
|
30780
30780
|
const X = /MainImage *\([\w\s,]*?depth[\w\s,]*?\)/;
|
|
30781
|
-
h += `${i}MainImage(color0, UV, `, e.attributes &
|
|
30781
|
+
h += `${i}MainImage(color0, UV, `, e.attributes & Zs.DEPTH && X.test(n) && (h += "depth, ", e.readDepth = !0), h += `color1);
|
|
30782
30782
|
`;
|
|
30783
30783
|
const y = i + "BlendOpacity";
|
|
30784
30784
|
e.uniforms.set(y, p.opacity), h += `color0 = blend${p.blendFunction}(color0, color1, ${y});
|
|
@@ -30860,9 +30860,9 @@ var m1 = class extends pn {
|
|
|
30860
30860
|
let t = 0;
|
|
30861
30861
|
for (const a of this.effects)
|
|
30862
30862
|
if (a.blendMode.blendFunction === pe.DST)
|
|
30863
|
-
i.attributes |= a.getAttributes() &
|
|
30863
|
+
i.attributes |= a.getAttributes() & Zs.DEPTH;
|
|
30864
30864
|
else {
|
|
30865
|
-
if (i.attributes & a.getAttributes() &
|
|
30865
|
+
if (i.attributes & a.getAttributes() & Zs.CONVOLUTION)
|
|
30866
30866
|
throw new Error(`Convolution effects cannot be merged (${a.name})`);
|
|
30867
30867
|
v7("e" + t++, a, i);
|
|
30868
30868
|
}
|
|
@@ -30871,7 +30871,7 @@ var m1 = class extends pn {
|
|
|
30871
30871
|
for (const a of i.blendModes.values())
|
|
30872
30872
|
e += a.getShaderCode().replace(l, `blend${a.blendFunction}`) + `
|
|
30873
30873
|
`;
|
|
30874
|
-
i.attributes &
|
|
30874
|
+
i.attributes & Zs.DEPTH ? (i.readDepth && (n = `float depth = readDepth(UV);
|
|
30875
30875
|
|
|
30876
30876
|
` + n), this.needsDepthTexture = this.getDepthTexture() === null) : this.needsDepthTexture = !1, i.colorSpace === ye && (n += `color0 = sRGBToLinear(color0);
|
|
30877
30877
|
`), i.uvTransformation ? (s = `vec2 transformedUv = vUv;
|
|
@@ -31200,7 +31200,7 @@ const o0 = {
|
|
|
31200
31200
|
LEFT: 1,
|
|
31201
31201
|
RIGHT: 2,
|
|
31202
31202
|
MIDDLE: 4
|
|
31203
|
-
},
|
|
31203
|
+
}, ut = Object.freeze({
|
|
31204
31204
|
NONE: 0,
|
|
31205
31205
|
ROTATE: 1,
|
|
31206
31206
|
TRUCK: 2,
|
|
@@ -31223,7 +31223,7 @@ const o0 = {
|
|
|
31223
31223
|
IN: 1,
|
|
31224
31224
|
OUT: -1
|
|
31225
31225
|
};
|
|
31226
|
-
function
|
|
31226
|
+
function Ps(i) {
|
|
31227
31227
|
return i.isPerspectiveCamera;
|
|
31228
31228
|
}
|
|
31229
31229
|
function as(i) {
|
|
@@ -31347,7 +31347,7 @@ let w7 = class {
|
|
|
31347
31347
|
}
|
|
31348
31348
|
};
|
|
31349
31349
|
const Zr = 1 / 8, K7 = /Mac/.test(navigator.platform);
|
|
31350
|
-
let le, sG, Gr, Z1, sn, ue, Te, $l, Vo, oi, ci,
|
|
31350
|
+
let le, sG, Gr, Z1, sn, ue, Te, $l, Vo, oi, ci, Es, lG, aG, In, go, ta, oG, G1, cG, X1, y1, Xr, zr = class Hp extends w7 {
|
|
31351
31351
|
/**
|
|
31352
31352
|
* Injects THREE as the dependency. You can then proceed to use CameraControls.
|
|
31353
31353
|
*
|
|
@@ -31389,14 +31389,14 @@ let le, sG, Gr, Z1, sn, ue, Te, $l, Vo, oi, ci, Ps, lG, aG, In, go, ta, oG, G1,
|
|
|
31389
31389
|
* @category Statics
|
|
31390
31390
|
*/
|
|
31391
31391
|
static install(t) {
|
|
31392
|
-
le = t.THREE, sG = Object.freeze(new le.Vector3(0, 0, 0)), Gr = Object.freeze(new le.Vector3(0, 1, 0)), Z1 = Object.freeze(new le.Vector3(0, 0, 1)), sn = new le.Vector2(), ue = new le.Vector3(), Te = new le.Vector3(), $l = new le.Vector3(), Vo = new le.Vector3(), oi = new le.Vector3(), ci = new le.Vector3(),
|
|
31392
|
+
le = t.THREE, sG = Object.freeze(new le.Vector3(0, 0, 0)), Gr = Object.freeze(new le.Vector3(0, 1, 0)), Z1 = Object.freeze(new le.Vector3(0, 0, 1)), sn = new le.Vector2(), ue = new le.Vector3(), Te = new le.Vector3(), $l = new le.Vector3(), Vo = new le.Vector3(), oi = new le.Vector3(), ci = new le.Vector3(), Es = new le.Vector3(), lG = new le.Vector3(), aG = new le.Vector3(), In = new le.Spherical(), go = new le.Spherical(), ta = new le.Box3(), oG = new le.Box3(), G1 = new le.Sphere(), cG = new le.Quaternion(), X1 = new le.Quaternion(), y1 = new le.Matrix4(), Xr = new le.Raycaster();
|
|
31393
31393
|
}
|
|
31394
31394
|
/**
|
|
31395
31395
|
* list all ACTIONs
|
|
31396
31396
|
* @category Statics
|
|
31397
31397
|
*/
|
|
31398
31398
|
static get ACTION() {
|
|
31399
|
-
return
|
|
31399
|
+
return ut;
|
|
31400
31400
|
}
|
|
31401
31401
|
/**
|
|
31402
31402
|
* Creates a `CameraControls` instance.
|
|
@@ -31417,9 +31417,9 @@ let le, sG, Gr, Z1, sn, ue, Te, $l, Vo, oi, ci, Ps, lG, aG, In, go, ta, oG, G1,
|
|
|
31417
31417
|
*/
|
|
31418
31418
|
constructor(t, e) {
|
|
31419
31419
|
super(), this.minPolarAngle = 0, this.maxPolarAngle = Math.PI, this.minAzimuthAngle = -1 / 0, this.maxAzimuthAngle = 1 / 0, this.minDistance = Number.EPSILON, this.maxDistance = 1 / 0, this.infinityDolly = !1, this.minZoom = 0.01, this.maxZoom = 1 / 0, this.smoothTime = 0.25, this.draggingSmoothTime = 0.125, this.maxSpeed = 1 / 0, this.azimuthRotateSpeed = 1, this.polarRotateSpeed = 1, this.dollySpeed = 1, this.dollyDragInverted = !1, this.truckSpeed = 2, this.dollyToCursor = !1, this.dragToOffset = !1, this.verticalDragToForward = !1, this.boundaryFriction = 0, this.restThreshold = 0.01, this.colliderMeshes = [], this.cancel = () => {
|
|
31420
|
-
}, this._enabled = !0, this._state =
|
|
31420
|
+
}, this._enabled = !0, this._state = ut.NONE, this._viewport = null, this._changedDolly = 0, this._changedZoom = 0, this._hasRested = !0, this._boundaryEnclosesCamera = !1, this._needsUpdate = !0, this._updatedLastTime = !1, this._elementRect = new DOMRect(), this._isDragging = !1, this._dragNeedsUpdate = !0, this._activePointers = [], this._lockedPointer = null, this._interactiveArea = new DOMRect(0, 0, 1, 1), this._isUserControllingRotate = !1, this._isUserControllingDolly = !1, this._isUserControllingTruck = !1, this._isUserControllingOffset = !1, this._isUserControllingZoom = !1, this._lastDollyDirection = _l.NONE, this._thetaVelocity = { value: 0 }, this._phiVelocity = { value: 0 }, this._radiusVelocity = { value: 0 }, this._targetVelocity = new le.Vector3(), this._focalOffsetVelocity = new le.Vector3(), this._zoomVelocity = { value: 0 }, this._truckInternal = (p, X, y) => {
|
|
31421
31421
|
let W, g;
|
|
31422
|
-
if (
|
|
31422
|
+
if (Ps(this._camera)) {
|
|
31423
31423
|
const f = ue.copy(this._camera.position).sub(this._target), L = this._camera.getEffectiveFOV() * Xo, I = f.length() * Math.tan(L * 0.5);
|
|
31424
31424
|
W = this.truckSpeed * p * I / this._elementRect.height, g = this.truckSpeed * X * I / this._elementRect.height;
|
|
31425
31425
|
} else if (as(this._camera)) {
|
|
@@ -31456,7 +31456,7 @@ let le, sG, Gr, Z1, sn, ue, Te, $l, Vo, oi, ci, Ps, lG, aG, In, go, ta, oG, G1,
|
|
|
31456
31456
|
), this._camera = t, this._yAxisUpSpace = new le.Quaternion().setFromUnitVectors(
|
|
31457
31457
|
this._camera.up,
|
|
31458
31458
|
Gr
|
|
31459
|
-
), this._yAxisUpSpaceInverse = this._yAxisUpSpace.clone().invert(), this._state =
|
|
31459
|
+
), this._yAxisUpSpaceInverse = this._yAxisUpSpace.clone().invert(), this._state = ut.NONE, this._target = new le.Vector3(), this._targetEnd = this._target.clone(), this._focalOffset = new le.Vector3(), this._focalOffsetEnd = this._focalOffset.clone(), this._spherical = new le.Spherical().setFromVector3(
|
|
31460
31460
|
ue.copy(this._camera.position).applyQuaternion(this._yAxisUpSpace)
|
|
31461
31461
|
), this._sphericalEnd = this._spherical.clone(), this._lastDistance = this._spherical.radius, this._zoom = this._camera.zoom, this._zoomEnd = this._zoom, this._lastZoom = this._zoom, this._nearPlaneCorners = [
|
|
31462
31462
|
new le.Vector3(),
|
|
@@ -31467,14 +31467,14 @@ let le, sG, Gr, Z1, sn, ue, Te, $l, Vo, oi, ci, Ps, lG, aG, In, go, ta, oG, G1,
|
|
|
31467
31467
|
new le.Vector3(-1 / 0, -1 / 0, -1 / 0),
|
|
31468
31468
|
new le.Vector3(1 / 0, 1 / 0, 1 / 0)
|
|
31469
31469
|
), this._cameraUp0 = this._camera.up.clone(), this._target0 = this._target.clone(), this._position0 = this._camera.position.clone(), this._zoom0 = this._zoom, this._focalOffset0 = this._focalOffset.clone(), this._dollyControlCoord = new le.Vector2(), this.mouseButtons = {
|
|
31470
|
-
left:
|
|
31471
|
-
middle:
|
|
31472
|
-
right:
|
|
31473
|
-
wheel:
|
|
31470
|
+
left: ut.ROTATE,
|
|
31471
|
+
middle: ut.DOLLY,
|
|
31472
|
+
right: ut.TRUCK,
|
|
31473
|
+
wheel: Ps(this._camera) ? ut.DOLLY : as(this._camera) ? ut.ZOOM : ut.NONE
|
|
31474
31474
|
}, this.touches = {
|
|
31475
|
-
one:
|
|
31476
|
-
two:
|
|
31477
|
-
three:
|
|
31475
|
+
one: ut.TOUCH_ROTATE,
|
|
31476
|
+
two: Ps(this._camera) ? ut.TOUCH_DOLLY_TRUCK : as(this._camera) ? ut.TOUCH_ZOOM_TRUCK : ut.NONE,
|
|
31477
|
+
three: ut.TOUCH_TRUCK
|
|
31478
31478
|
};
|
|
31479
31479
|
const n = new le.Vector2(), s = new le.Vector2(), l = new le.Vector2(), a = (p) => {
|
|
31480
31480
|
if (!this._enabled || !this._domElement) return;
|
|
@@ -31536,7 +31536,7 @@ let le, sG, Gr, Z1, sn, ue, Te, $l, Vo, oi, ci, Ps, lG, aG, In, go, ta, oG, G1,
|
|
|
31536
31536
|
if (X && this._disposePointer(X), p.pointerType === "touch")
|
|
31537
31537
|
switch (this._activePointers.length) {
|
|
31538
31538
|
case 0:
|
|
31539
|
-
this._state =
|
|
31539
|
+
this._state = ut.NONE;
|
|
31540
31540
|
break;
|
|
31541
31541
|
case 1:
|
|
31542
31542
|
this._state = this.touches.one;
|
|
@@ -31549,41 +31549,41 @@ let le, sG, Gr, Z1, sn, ue, Te, $l, Vo, oi, ci, Ps, lG, aG, In, go, ta, oG, G1,
|
|
|
31549
31549
|
break;
|
|
31550
31550
|
}
|
|
31551
31551
|
else
|
|
31552
|
-
this._state =
|
|
31552
|
+
this._state = ut.NONE;
|
|
31553
31553
|
b();
|
|
31554
31554
|
}
|
|
31555
31555
|
};
|
|
31556
31556
|
let d = -1;
|
|
31557
31557
|
const r = (p) => {
|
|
31558
|
-
if (!this._domElement || !this._enabled || this.mouseButtons.wheel ===
|
|
31558
|
+
if (!this._domElement || !this._enabled || this.mouseButtons.wheel === ut.NONE) return;
|
|
31559
31559
|
if (this._interactiveArea.left !== 0 || this._interactiveArea.top !== 0 || this._interactiveArea.width !== 1 || this._interactiveArea.height !== 1) {
|
|
31560
31560
|
const f = this._domElement.getBoundingClientRect(), L = (p.clientX - f.left) / (f.right - f.left), I = (p.clientY - f.top) / (f.bottom - f.top);
|
|
31561
31561
|
if (L < this._interactiveArea.left || L > this._interactiveArea.right || I < this._interactiveArea.top || I > this._interactiveArea.bottom)
|
|
31562
31562
|
return;
|
|
31563
31563
|
}
|
|
31564
|
-
if (p.preventDefault(), this.dollyToCursor || this.mouseButtons.wheel ===
|
|
31564
|
+
if (p.preventDefault(), this.dollyToCursor || this.mouseButtons.wheel === ut.ROTATE || this.mouseButtons.wheel === ut.TRUCK) {
|
|
31565
31565
|
const f = performance.now();
|
|
31566
31566
|
d - f < 1e3 && this._getClientRect(this._elementRect), d = f;
|
|
31567
31567
|
}
|
|
31568
31568
|
const X = K7 ? -1 : -3, y = p.deltaMode === 1 ? p.deltaY / X : p.deltaY / (X * 10), W = this.dollyToCursor ? (p.clientX - this._elementRect.x) / this._elementRect.width * 2 - 1 : 0, g = this.dollyToCursor ? (p.clientY - this._elementRect.y) / this._elementRect.height * -2 + 1 : 0;
|
|
31569
31569
|
switch (this.mouseButtons.wheel) {
|
|
31570
|
-
case
|
|
31570
|
+
case ut.ROTATE: {
|
|
31571
31571
|
this._rotateInternal(p.deltaX, p.deltaY), this._isUserControllingRotate = !0;
|
|
31572
31572
|
break;
|
|
31573
31573
|
}
|
|
31574
|
-
case
|
|
31574
|
+
case ut.TRUCK: {
|
|
31575
31575
|
this._truckInternal(p.deltaX, p.deltaY, !1), this._isUserControllingTruck = !0;
|
|
31576
31576
|
break;
|
|
31577
31577
|
}
|
|
31578
|
-
case
|
|
31578
|
+
case ut.OFFSET: {
|
|
31579
31579
|
this._truckInternal(p.deltaX, p.deltaY, !0), this._isUserControllingOffset = !0;
|
|
31580
31580
|
break;
|
|
31581
31581
|
}
|
|
31582
|
-
case
|
|
31582
|
+
case ut.DOLLY: {
|
|
31583
31583
|
this._dollyInternal(-y, W, g), this._isUserControllingDolly = !0;
|
|
31584
31584
|
break;
|
|
31585
31585
|
}
|
|
31586
|
-
case
|
|
31586
|
+
case ut.ZOOM: {
|
|
31587
31587
|
this._zoomInternal(-y, W, g), this._isUserControllingZoom = !0;
|
|
31588
31588
|
break;
|
|
31589
31589
|
}
|
|
@@ -31629,15 +31629,15 @@ let le, sG, Gr, Z1, sn, ue, Te, $l, Vo, oi, ci, Ps, lG, aG, In, go, ta, oG, G1,
|
|
|
31629
31629
|
}
|
|
31630
31630
|
else
|
|
31631
31631
|
!this._lockedPointer && (p.buttons & o0.LEFT) === o0.LEFT && (this._state = this._state | this.mouseButtons.left), (p.buttons & o0.MIDDLE) === o0.MIDDLE && (this._state = this._state | this.mouseButtons.middle), (p.buttons & o0.RIGHT) === o0.RIGHT && (this._state = this._state | this.mouseButtons.right);
|
|
31632
|
-
((this._state &
|
|
31632
|
+
((this._state & ut.ROTATE) === ut.ROTATE || (this._state & ut.TOUCH_ROTATE) === ut.TOUCH_ROTATE || (this._state & ut.TOUCH_DOLLY_ROTATE) === ut.TOUCH_DOLLY_ROTATE || (this._state & ut.TOUCH_ZOOM_ROTATE) === ut.TOUCH_ZOOM_ROTATE) && (this._sphericalEnd.theta = this._spherical.theta, this._sphericalEnd.phi = this._spherical.phi, this._thetaVelocity.value = 0, this._phiVelocity.value = 0), ((this._state & ut.TRUCK) === ut.TRUCK || (this._state & ut.TOUCH_TRUCK) === ut.TOUCH_TRUCK || (this._state & ut.TOUCH_DOLLY_TRUCK) === ut.TOUCH_DOLLY_TRUCK || (this._state & ut.TOUCH_ZOOM_TRUCK) === ut.TOUCH_ZOOM_TRUCK) && (this._targetEnd.copy(this._target), this._targetVelocity.set(0, 0, 0)), ((this._state & ut.DOLLY) === ut.DOLLY || (this._state & ut.TOUCH_DOLLY) === ut.TOUCH_DOLLY || (this._state & ut.TOUCH_DOLLY_TRUCK) === ut.TOUCH_DOLLY_TRUCK || (this._state & ut.TOUCH_DOLLY_OFFSET) === ut.TOUCH_DOLLY_OFFSET || (this._state & ut.TOUCH_DOLLY_ROTATE) === ut.TOUCH_DOLLY_ROTATE) && (this._sphericalEnd.radius = this._spherical.radius, this._radiusVelocity.value = 0), ((this._state & ut.ZOOM) === ut.ZOOM || (this._state & ut.TOUCH_ZOOM) === ut.TOUCH_ZOOM || (this._state & ut.TOUCH_ZOOM_TRUCK) === ut.TOUCH_ZOOM_TRUCK || (this._state & ut.TOUCH_ZOOM_OFFSET) === ut.TOUCH_ZOOM_OFFSET || (this._state & ut.TOUCH_ZOOM_ROTATE) === ut.TOUCH_ZOOM_ROTATE) && (this._zoomEnd = this._zoom, this._zoomVelocity.value = 0), ((this._state & ut.OFFSET) === ut.OFFSET || (this._state & ut.TOUCH_OFFSET) === ut.TOUCH_OFFSET || (this._state & ut.TOUCH_DOLLY_OFFSET) === ut.TOUCH_DOLLY_OFFSET || (this._state & ut.TOUCH_ZOOM_OFFSET) === ut.TOUCH_ZOOM_OFFSET) && (this._focalOffsetEnd.copy(this._focalOffset), this._focalOffsetVelocity.set(0, 0, 0)), this.dispatchEvent({ type: "controlstart" });
|
|
31633
31633
|
}
|
|
31634
31634
|
}, m = () => {
|
|
31635
31635
|
if (!this._enabled || !this._dragNeedsUpdate) return;
|
|
31636
31636
|
this._dragNeedsUpdate = !1, p1(this._activePointers, sn);
|
|
31637
31637
|
const p = this._domElement && this._domElement.ownerDocument.pointerLockElement === this._domElement ? this._lockedPointer || this._activePointers[0] : null, X = p ? -p.deltaX : s.x - sn.x, y = p ? -p.deltaY : s.y - sn.y;
|
|
31638
|
-
if (s.copy(sn), ((this._state &
|
|
31638
|
+
if (s.copy(sn), ((this._state & ut.ROTATE) === ut.ROTATE || (this._state & ut.TOUCH_ROTATE) === ut.TOUCH_ROTATE || (this._state & ut.TOUCH_DOLLY_ROTATE) === ut.TOUCH_DOLLY_ROTATE || (this._state & ut.TOUCH_ZOOM_ROTATE) === ut.TOUCH_ZOOM_ROTATE) && (this._rotateInternal(X, y), this._isUserControllingRotate = !0), (this._state & ut.DOLLY) === ut.DOLLY || (this._state & ut.ZOOM) === ut.ZOOM) {
|
|
31639
31639
|
const W = this.dollyToCursor ? (n.x - this._elementRect.x) / this._elementRect.width * 2 - 1 : 0, g = this.dollyToCursor ? (n.y - this._elementRect.y) / this._elementRect.height * -2 + 1 : 0, f = this.dollyDragInverted ? -1 : 1;
|
|
31640
|
-
(this._state &
|
|
31640
|
+
(this._state & ut.DOLLY) === ut.DOLLY ? (this._dollyInternal(
|
|
31641
31641
|
f * y * Zr,
|
|
31642
31642
|
W,
|
|
31643
31643
|
g
|
|
@@ -31647,13 +31647,13 @@ let le, sG, Gr, Z1, sn, ue, Te, $l, Vo, oi, ci, Ps, lG, aG, In, go, ta, oG, G1,
|
|
|
31647
31647
|
g
|
|
31648
31648
|
), this._isUserControllingZoom = !0);
|
|
31649
31649
|
}
|
|
31650
|
-
if ((this._state &
|
|
31650
|
+
if ((this._state & ut.TOUCH_DOLLY) === ut.TOUCH_DOLLY || (this._state & ut.TOUCH_ZOOM) === ut.TOUCH_ZOOM || (this._state & ut.TOUCH_DOLLY_TRUCK) === ut.TOUCH_DOLLY_TRUCK || (this._state & ut.TOUCH_ZOOM_TRUCK) === ut.TOUCH_ZOOM_TRUCK || (this._state & ut.TOUCH_DOLLY_OFFSET) === ut.TOUCH_DOLLY_OFFSET || (this._state & ut.TOUCH_ZOOM_OFFSET) === ut.TOUCH_ZOOM_OFFSET || (this._state & ut.TOUCH_DOLLY_ROTATE) === ut.TOUCH_DOLLY_ROTATE || (this._state & ut.TOUCH_ZOOM_ROTATE) === ut.TOUCH_ZOOM_ROTATE) {
|
|
31651
31651
|
const W = sn.x - this._activePointers[1].clientX, g = sn.y - this._activePointers[1].clientY, f = Math.sqrt(W * W + g * g), L = l.y - f;
|
|
31652
31652
|
l.set(0, f);
|
|
31653
31653
|
const I = this.dollyToCursor ? (s.x - this._elementRect.x) / this._elementRect.width * 2 - 1 : 0, S = this.dollyToCursor ? (s.y - this._elementRect.y) / this._elementRect.height * -2 + 1 : 0;
|
|
31654
|
-
(this._state &
|
|
31654
|
+
(this._state & ut.TOUCH_DOLLY) === ut.TOUCH_DOLLY || (this._state & ut.TOUCH_DOLLY_ROTATE) === ut.TOUCH_DOLLY_ROTATE || (this._state & ut.TOUCH_DOLLY_TRUCK) === ut.TOUCH_DOLLY_TRUCK || (this._state & ut.TOUCH_DOLLY_OFFSET) === ut.TOUCH_DOLLY_OFFSET ? (this._dollyInternal(L * Zr, I, S), this._isUserControllingDolly = !0) : (this._zoomInternal(L * Zr, I, S), this._isUserControllingZoom = !0);
|
|
31655
31655
|
}
|
|
31656
|
-
((this._state &
|
|
31656
|
+
((this._state & ut.TRUCK) === ut.TRUCK || (this._state & ut.TOUCH_TRUCK) === ut.TOUCH_TRUCK || (this._state & ut.TOUCH_DOLLY_TRUCK) === ut.TOUCH_DOLLY_TRUCK || (this._state & ut.TOUCH_ZOOM_TRUCK) === ut.TOUCH_ZOOM_TRUCK) && (this._truckInternal(X, y, !1), this._isUserControllingTruck = !0), ((this._state & ut.OFFSET) === ut.OFFSET || (this._state & ut.TOUCH_OFFSET) === ut.TOUCH_OFFSET || (this._state & ut.TOUCH_DOLLY_OFFSET) === ut.TOUCH_DOLLY_OFFSET || (this._state & ut.TOUCH_ZOOM_OFFSET) === ut.TOUCH_ZOOM_OFFSET) && (this._truckInternal(X, y, !0), this._isUserControllingOffset = !0), this.dispatchEvent({ type: "control" });
|
|
31657
31657
|
}, b = () => {
|
|
31658
31658
|
p1(this._activePointers, sn), s.copy(sn), this._dragNeedsUpdate = !1, (this._activePointers.length === 0 || this._activePointers.length === 1 && this._activePointers[0] === this._lockedPointer) && (this._isDragging = !1), this._activePointers.length === 0 && this._domElement && (this._domElement.ownerDocument.removeEventListener(
|
|
31659
31659
|
"pointermove",
|
|
@@ -31727,7 +31727,7 @@ let le, sG, Gr, Z1, sn, ue, Te, $l, Vo, oi, ci, Ps, lG, aG, In, go, ta, oG, G1,
|
|
|
31727
31727
|
Z
|
|
31728
31728
|
));
|
|
31729
31729
|
}, this.cancel = () => {
|
|
31730
|
-
this._state !==
|
|
31730
|
+
this._state !== ut.NONE && (this._state = ut.NONE, this._activePointers.length = 0, b());
|
|
31731
31731
|
}, e && this.connect(e), this.update(0);
|
|
31732
31732
|
}
|
|
31733
31733
|
/**
|
|
@@ -32163,7 +32163,7 @@ let le, sG, Gr, Z1, sn, ue, Te, $l, Vo, oi, ci, Ps, lG, aG, In, go, ta, oG, G1,
|
|
|
32163
32163
|
const G = oG.makeEmpty();
|
|
32164
32164
|
Te.copy(d.min).applyQuaternion(m), G.expandByPoint(Te), Te.copy(d.min).setX(d.max.x).applyQuaternion(m), G.expandByPoint(Te), Te.copy(d.min).setY(d.max.y).applyQuaternion(m), G.expandByPoint(Te), Te.copy(d.max).setZ(d.min.z).applyQuaternion(m), G.expandByPoint(Te), Te.copy(d.min).setZ(d.max.z).applyQuaternion(m), G.expandByPoint(Te), Te.copy(d.max).setY(d.min.y).applyQuaternion(m), G.expandByPoint(Te), Te.copy(d.max).setX(d.min.x).applyQuaternion(m), G.expandByPoint(Te), Te.copy(d.max).applyQuaternion(m), G.expandByPoint(Te), G.min.x -= s, G.min.y -= a, G.max.x += l, G.max.y += o, m.setFromUnitVectors(Z1, u), b && m.premultiply(X1.invert()), m.premultiply(this._yAxisUpSpace);
|
|
32165
32165
|
const Z = G.getSize(ue), p = G.getCenter(Te).applyQuaternion(m);
|
|
32166
|
-
if (
|
|
32166
|
+
if (Ps(this._camera)) {
|
|
32167
32167
|
const X = this.getDistanceToFitBox(
|
|
32168
32168
|
Z.x,
|
|
32169
32169
|
Z.y,
|
|
@@ -32196,7 +32196,7 @@ let le, sG, Gr, Z1, sn, ue, Te, $l, Vo, oi, ci, Ps, lG, aG, In, go, ta, oG, G1,
|
|
|
32196
32196
|
s.center.z,
|
|
32197
32197
|
e
|
|
32198
32198
|
)
|
|
32199
|
-
),
|
|
32199
|
+
), Ps(this._camera)) {
|
|
32200
32200
|
const l = this.getDistanceToFitSphere(s.radius);
|
|
32201
32201
|
n.push(this.dollyTo(l, e));
|
|
32202
32202
|
} else if (as(this._camera)) {
|
|
@@ -32365,9 +32365,9 @@ let le, sG, Gr, Z1, sn, ue, Te, $l, Vo, oi, ci, Ps, lG, aG, In, go, ta, oG, G1,
|
|
|
32365
32365
|
* @category Methods
|
|
32366
32366
|
*/
|
|
32367
32367
|
setOrbitPoint(t, e, n) {
|
|
32368
|
-
this._camera.updateMatrixWorld(), oi.setFromMatrixColumn(this._camera.matrixWorldInverse, 0), ci.setFromMatrixColumn(this._camera.matrixWorldInverse, 1),
|
|
32368
|
+
this._camera.updateMatrixWorld(), oi.setFromMatrixColumn(this._camera.matrixWorldInverse, 0), ci.setFromMatrixColumn(this._camera.matrixWorldInverse, 1), Es.setFromMatrixColumn(this._camera.matrixWorldInverse, 2);
|
|
32369
32369
|
const s = ue.set(t, e, n), l = s.distanceTo(this._camera.position), a = s.sub(this._camera.position);
|
|
32370
|
-
oi.multiplyScalar(a.x), ci.multiplyScalar(a.y),
|
|
32370
|
+
oi.multiplyScalar(a.x), ci.multiplyScalar(a.y), Es.multiplyScalar(a.z), ue.copy(oi).add(ci).add(Es), ue.z = ue.z + l, this.dollyTo(l, !1), this.setFocalOffset(-ue.x, ue.y, -ue.z, !1), this.moveTo(t, e, n, !1);
|
|
32371
32371
|
}
|
|
32372
32372
|
/**
|
|
32373
32373
|
* Set the boundary box that encloses the target of the camera. box3 is in THREE.Box3
|
|
@@ -32618,7 +32618,7 @@ let le, sG, Gr, Z1, sn, ue, Te, $l, Vo, oi, ci, Ps, lG, aG, In, go, ta, oG, G1,
|
|
|
32618
32618
|
);
|
|
32619
32619
|
}
|
|
32620
32620
|
if (this.dollyToCursor) {
|
|
32621
|
-
if (
|
|
32621
|
+
if (Ps(this._camera) && this._changedDolly !== 0) {
|
|
32622
32622
|
const r = this._spherical.radius - this._lastDistance, h = this._camera, u = this._getCameraDirection(Vo), m = ue.copy(u).cross(h.up).normalize();
|
|
32623
32623
|
m.lengthSq() === 0 && (m.x = 1);
|
|
32624
32624
|
const b = Te.crossVectors(m, u), G = this._sphericalEnd.radius * Math.tan(h.getEffectiveFOV() * Xo * 0.5), Z = (this._sphericalEnd.radius - r - this._sphericalEnd.radius) / this._sphericalEnd.radius, p = $l.copy(this._targetEnd).add(
|
|
@@ -32651,7 +32651,7 @@ let le, sG, Gr, Z1, sn, ue, Te, $l, Vo, oi, ci, Ps, lG, aG, In, go, ta, oG, G1,
|
|
|
32651
32651
|
}
|
|
32652
32652
|
this._camera.zoom !== this._zoom && (this._camera.zoom = this._zoom, this._camera.updateProjectionMatrix(), this._updateNearPlaneCorners(), this._needsUpdate = !0), this._dragNeedsUpdate = !0;
|
|
32653
32653
|
const c = this._collisionTest();
|
|
32654
|
-
this._spherical.radius = Math.min(this._spherical.radius, c), this._spherical.makeSafe(), this._camera.position.setFromSpherical(this._spherical).applyQuaternion(this._yAxisUpSpaceInverse).add(this._target), this._camera.lookAt(this._target), (!qe(this._focalOffset.x) || !qe(this._focalOffset.y) || !qe(this._focalOffset.z)) && (this._camera.updateMatrixWorld(), oi.setFromMatrixColumn(this._camera.matrix, 0), ci.setFromMatrixColumn(this._camera.matrix, 1),
|
|
32654
|
+
this._spherical.radius = Math.min(this._spherical.radius, c), this._spherical.makeSafe(), this._camera.position.setFromSpherical(this._spherical).applyQuaternion(this._yAxisUpSpaceInverse).add(this._target), this._camera.lookAt(this._target), (!qe(this._focalOffset.x) || !qe(this._focalOffset.y) || !qe(this._focalOffset.z)) && (this._camera.updateMatrixWorld(), oi.setFromMatrixColumn(this._camera.matrix, 0), ci.setFromMatrixColumn(this._camera.matrix, 1), Es.setFromMatrixColumn(this._camera.matrix, 2), oi.multiplyScalar(this._focalOffset.x), ci.multiplyScalar(-this._focalOffset.y), Es.multiplyScalar(this._focalOffset.z), ue.copy(oi).add(ci).add(Es), this._camera.position.add(ue)), this._boundaryEnclosesCamera && this._encloseToBoundary(
|
|
32655
32655
|
this._camera.position.copy(this._target),
|
|
32656
32656
|
ue.setFromSpherical(this._spherical).applyQuaternion(this._yAxisUpSpaceInverse),
|
|
32657
32657
|
1
|
|
@@ -32769,7 +32769,7 @@ let le, sG, Gr, Z1, sn, ue, Te, $l, Vo, oi, ci, Ps, lG, aG, In, go, ta, oG, G1,
|
|
|
32769
32769
|
}
|
|
32770
32770
|
}
|
|
32771
32771
|
_updateNearPlaneCorners() {
|
|
32772
|
-
if (
|
|
32772
|
+
if (Ps(this._camera)) {
|
|
32773
32773
|
const t = this._camera, e = t.near, n = t.getEffectiveFOV() * Xo, s = Math.tan(n * 0.5) * e, l = s * t.aspect;
|
|
32774
32774
|
this._nearPlaneCorners[0].set(-l, -s, 0), this._nearPlaneCorners[1].set(l, -s, 0), this._nearPlaneCorners[2].set(l, s, 0), this._nearPlaneCorners[3].set(-l, s, 0);
|
|
32775
32775
|
} else if (as(this._camera)) {
|
|
@@ -34191,7 +34191,7 @@ Ur.shim = function() {
|
|
|
34191
34191
|
Object.keys = Ur;
|
|
34192
34192
|
return Object.keys || Ur;
|
|
34193
34193
|
};
|
|
34194
|
-
var hm = Ur, gM = Error, fM = EvalError, RM = RangeError, xM = ReferenceError, CV = SyntaxError,
|
|
34194
|
+
var hm = Ur, gM = Error, fM = EvalError, RM = RangeError, xM = ReferenceError, CV = SyntaxError, Rs = TypeError, SM = URIError, td = function() {
|
|
34195
34195
|
if (typeof Symbol != "function" || typeof Object.getOwnPropertySymbols != "function")
|
|
34196
34196
|
return !1;
|
|
34197
34197
|
if (typeof Symbol.iterator == "symbol")
|
|
@@ -34258,7 +34258,7 @@ var hm = Ur, gM = Error, fM = EvalError, RM = RangeError, xM = ReferenceError, C
|
|
|
34258
34258
|
d.prototype = e.prototype, s.prototype = new d(), d.prototype = null;
|
|
34259
34259
|
}
|
|
34260
34260
|
return s;
|
|
34261
|
-
}, JM = HM, E9 = Function.prototype.bind || JM, wM = Function.prototype.call, KM = Object.prototype.hasOwnProperty, kM = E9, YV = kM.call(wM, KM), Re, zM = gM, UM = fM, BM = RM, PM = xM, wa = CV, ya =
|
|
34261
|
+
}, JM = HM, E9 = Function.prototype.bind || JM, wM = Function.prototype.call, KM = Object.prototype.hasOwnProperty, kM = E9, YV = kM.call(wM, KM), Re, zM = gM, UM = fM, BM = RM, PM = xM, wa = CV, ya = Rs, EM = SM, IV = Function, V1 = function(i) {
|
|
34262
34262
|
try {
|
|
34263
34263
|
return IV('"use strict"; return (' + i + ").constructor;")();
|
|
34264
34264
|
} catch (t) {
|
|
@@ -34497,7 +34497,7 @@ if (Pr)
|
|
|
34497
34497
|
} catch (i) {
|
|
34498
34498
|
Pr = null;
|
|
34499
34499
|
}
|
|
34500
|
-
var j9 = Pr, WG = Q9, aF = CV, na =
|
|
34500
|
+
var j9 = Pr, WG = Q9, aF = CV, na = Rs, VG = j9, A9 = function(t, e, n) {
|
|
34501
34501
|
if (!t || typeof t != "object" && typeof t != "function")
|
|
34502
34502
|
throw new na("`obj` must be an object or a function`");
|
|
34503
34503
|
if (typeof e != "string" && typeof e != "symbol")
|
|
@@ -34570,7 +34570,7 @@ FV.hasArrayLengthDefineBug = function() {
|
|
|
34570
34570
|
return !0;
|
|
34571
34571
|
}
|
|
34572
34572
|
};
|
|
34573
|
-
var HV = FV, pF = ii, fG = A9, bF = HV(), RG = j9, xG =
|
|
34573
|
+
var HV = FV, pF = ii, fG = A9, bF = HV(), RG = j9, xG = Rs, ZF = pF("%Math.floor%"), GF = function(t, e) {
|
|
34574
34574
|
if (typeof t != "function")
|
|
34575
34575
|
throw new xG("`fn` is not a function");
|
|
34576
34576
|
if (typeof e != "number" || e < 0 || e > 4294967295 || ZF(e) !== e)
|
|
@@ -34595,7 +34595,7 @@ var HV = FV, pF = ii, fG = A9, bF = HV(), RG = j9, xG = fs, ZF = pF("%Math.floor
|
|
|
34595
34595
|
)), t;
|
|
34596
34596
|
};
|
|
34597
34597
|
(function(i) {
|
|
34598
|
-
var t = E9, e = ii, n = GF, s =
|
|
34598
|
+
var t = E9, e = ii, n = GF, s = Rs, l = e("%Function.prototype.apply%"), a = e("%Function.prototype.call%"), o = e("%Reflect.apply%", !0) || t.call(a, l), c = Q9, d = e("%Math.max%");
|
|
34599
34599
|
i.exports = function(u) {
|
|
34600
34600
|
if (typeof u != "function")
|
|
34601
34601
|
throw new s("a function is required");
|
|
@@ -34696,7 +34696,7 @@ Wc.boundFunctionsHaveNames = function() {
|
|
|
34696
34696
|
return Wc() && typeof TF == "function" && function() {
|
|
34697
34697
|
}.bind().name !== "";
|
|
34698
34698
|
};
|
|
34699
|
-
var MF = Wc, CG = A9, FF = HV(), HF = MF.functionsHaveConfigurableNames(), JF =
|
|
34699
|
+
var MF = Wc, CG = A9, FF = HV(), HF = MF.functionsHaveConfigurableNames(), JF = Rs, wF = function(t, e) {
|
|
34700
34700
|
if (typeof t != "function")
|
|
34701
34701
|
throw new JF("`fn` is not a function");
|
|
34702
34702
|
var n = arguments.length > 2 && !!arguments[2];
|
|
@@ -34713,7 +34713,7 @@ var MF = Wc, CG = A9, FF = HV(), HF = MF.functionsHaveConfigurableNames(), JF =
|
|
|
34713
34713
|
"name",
|
|
34714
34714
|
e
|
|
34715
34715
|
)), t;
|
|
34716
|
-
}, KF = wF, kF =
|
|
34716
|
+
}, KF = wF, kF = Rs, zF = Object, EV = KF(function() {
|
|
34717
34717
|
if (this == null || this !== zF(this))
|
|
34718
34718
|
throw new kF("RegExp.prototype.flags getter called on non-object");
|
|
34719
34719
|
var t = "";
|
|
@@ -34766,7 +34766,7 @@ const o8 = {}, c8 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineP
|
|
|
34766
34766
|
__proto__: null,
|
|
34767
34767
|
default: o8
|
|
34768
34768
|
}, Symbol.toStringTag, { value: "Module" })), d8 = /* @__PURE__ */ tN(c8);
|
|
34769
|
-
var D9 = typeof Map == "function" && Map.prototype, R1 = Object.getOwnPropertyDescriptor && D9 ? Object.getOwnPropertyDescriptor(Map.prototype, "size") : null, eu = D9 && R1 && typeof R1.get == "function" ? R1.get : null, IG = D9 && Map.prototype.forEach, O9 = typeof Set == "function" && Set.prototype, x1 = Object.getOwnPropertyDescriptor && O9 ? Object.getOwnPropertyDescriptor(Set.prototype, "size") : null, nu = O9 && x1 && typeof x1.get == "function" ? x1.get : null, NG = O9 && Set.prototype.forEach, r8 = typeof WeakMap == "function" && WeakMap.prototype, Do = r8 ? WeakMap.prototype.has : null, h8 = typeof WeakSet == "function" && WeakSet.prototype, Oo = h8 ? WeakSet.prototype.has : null, u8 = typeof WeakRef == "function" && WeakRef.prototype, vG = u8 ? WeakRef.prototype.deref : null, m8 = Boolean.prototype.valueOf, p8 = Object.prototype.toString, b8 = Function.prototype.toString, Z8 = String.prototype.match, _9 = String.prototype.slice,
|
|
34769
|
+
var D9 = typeof Map == "function" && Map.prototype, R1 = Object.getOwnPropertyDescriptor && D9 ? Object.getOwnPropertyDescriptor(Map.prototype, "size") : null, eu = D9 && R1 && typeof R1.get == "function" ? R1.get : null, IG = D9 && Map.prototype.forEach, O9 = typeof Set == "function" && Set.prototype, x1 = Object.getOwnPropertyDescriptor && O9 ? Object.getOwnPropertyDescriptor(Set.prototype, "size") : null, nu = O9 && x1 && typeof x1.get == "function" ? x1.get : null, NG = O9 && Set.prototype.forEach, r8 = typeof WeakMap == "function" && WeakMap.prototype, Do = r8 ? WeakMap.prototype.has : null, h8 = typeof WeakSet == "function" && WeakSet.prototype, Oo = h8 ? WeakSet.prototype.has : null, u8 = typeof WeakRef == "function" && WeakRef.prototype, vG = u8 ? WeakRef.prototype.deref : null, m8 = Boolean.prototype.valueOf, p8 = Object.prototype.toString, b8 = Function.prototype.toString, Z8 = String.prototype.match, _9 = String.prototype.slice, ms = String.prototype.replace, G8 = String.prototype.toUpperCase, TG = String.prototype.toLowerCase, _V = RegExp.prototype.test, MG = Array.prototype.concat, ri = Array.prototype.join, X8 = Array.prototype.slice, FG = Math.floor, Qp = typeof BigInt == "function" ? BigInt.prototype.valueOf : null, S1 = Object.getOwnPropertySymbols, jp = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? Symbol.prototype.toString : null, Ka = typeof Symbol == "function" && typeof Symbol.iterator == "object", Q0 = typeof Symbol == "function" && Symbol.toStringTag && (typeof Symbol.toStringTag === Ka || !0) ? Symbol.toStringTag : null, qV = Object.prototype.propertyIsEnumerable, HG = (typeof Reflect == "function" ? Reflect.getPrototypeOf : Object.getPrototypeOf) || ([].__proto__ === Array.prototype ? function(i) {
|
|
34770
34770
|
return i.__proto__;
|
|
34771
34771
|
} : null);
|
|
34772
34772
|
function JG(i, t) {
|
|
@@ -34777,23 +34777,23 @@ function JG(i, t) {
|
|
|
34777
34777
|
var n = i < 0 ? -FG(-i) : FG(i);
|
|
34778
34778
|
if (n !== i) {
|
|
34779
34779
|
var s = String(n), l = _9.call(t, s.length + 1);
|
|
34780
|
-
return
|
|
34780
|
+
return ms.call(s, e, "$&_") + "." + ms.call(ms.call(l, /([0-9]{3})/g, "$&_"), /_$/, "");
|
|
34781
34781
|
}
|
|
34782
34782
|
}
|
|
34783
|
-
return
|
|
34783
|
+
return ms.call(t, e, "$&_");
|
|
34784
34784
|
}
|
|
34785
34785
|
var Ap = d8, wG = Ap.custom, KG = tg(wG) ? wG : null, y8 = function i(t, e, n, s) {
|
|
34786
34786
|
var l = e || {};
|
|
34787
|
-
if (
|
|
34787
|
+
if (ds(l, "quoteStyle") && l.quoteStyle !== "single" && l.quoteStyle !== "double")
|
|
34788
34788
|
throw new TypeError('option "quoteStyle" must be "single" or "double"');
|
|
34789
|
-
if (
|
|
34789
|
+
if (ds(l, "maxStringLength") && (typeof l.maxStringLength == "number" ? l.maxStringLength < 0 && l.maxStringLength !== 1 / 0 : l.maxStringLength !== null))
|
|
34790
34790
|
throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');
|
|
34791
|
-
var a =
|
|
34791
|
+
var a = ds(l, "customInspect") ? l.customInspect : !0;
|
|
34792
34792
|
if (typeof a != "boolean" && a !== "symbol")
|
|
34793
34793
|
throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");
|
|
34794
|
-
if (
|
|
34794
|
+
if (ds(l, "indent") && l.indent !== null && l.indent !== " " && !(parseInt(l.indent, 10) === l.indent && l.indent > 0))
|
|
34795
34795
|
throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');
|
|
34796
|
-
if (
|
|
34796
|
+
if (ds(l, "numericSeparator") && typeof l.numericSeparator != "boolean")
|
|
34797
34797
|
throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');
|
|
34798
34798
|
var o = l.numericSeparator;
|
|
34799
34799
|
if (typeof t == "undefined")
|
|
@@ -34827,7 +34827,7 @@ var Ap = d8, wG = Ap.custom, KG = tg(wG) ? wG : null, y8 = function i(t, e, n, s
|
|
|
34827
34827
|
var z = {
|
|
34828
34828
|
depth: l.depth
|
|
34829
34829
|
};
|
|
34830
|
-
return
|
|
34830
|
+
return ds(l, "quoteStyle") && (z.quoteStyle = l.quoteStyle), i(w, z, n + 1, s);
|
|
34831
34831
|
}
|
|
34832
34832
|
return i(w, l, n + 1, s);
|
|
34833
34833
|
}
|
|
@@ -34836,7 +34836,7 @@ var Ap = d8, wG = Ap.custom, KG = tg(wG) ? wG : null, y8 = function i(t, e, n, s
|
|
|
34836
34836
|
return "[Function" + (m ? ": " + m : " (anonymous)") + "]" + (b.length > 0 ? " { " + ri.call(b, ", ") + " }" : "");
|
|
34837
34837
|
}
|
|
34838
34838
|
if (tg(t)) {
|
|
34839
|
-
var G = Ka ?
|
|
34839
|
+
var G = Ka ? ms.call(String(t), /^(Symbol\(.*\))_[^)]*$/, "$1") : jp.call(t);
|
|
34840
34840
|
return typeof t == "object" && !Ka ? Ro(G) : G;
|
|
34841
34841
|
}
|
|
34842
34842
|
if (M8(t)) {
|
|
@@ -34891,7 +34891,7 @@ var Ap = d8, wG = Ap.custom, KG = tg(wG) ? wG : null, y8 = function i(t, e, n, s
|
|
|
34891
34891
|
if (typeof globalThis != "undefined" && t === globalThis || typeof vh != "undefined" && t === vh)
|
|
34892
34892
|
return "{ [object globalThis] }";
|
|
34893
34893
|
if (!V8(t) && !kG(t)) {
|
|
34894
|
-
var L = Vr(t, u), I = HG ? HG(t) === Object.prototype : t instanceof Object || t.constructor === Object, S = t instanceof Object ? "" : "null prototype", R = !I && Q0 && Object(t) === t && Q0 in t ? _9.call(
|
|
34894
|
+
var L = Vr(t, u), I = HG ? HG(t) === Object.prototype : t instanceof Object || t.constructor === Object, S = t instanceof Object ? "" : "null prototype", R = !I && Q0 && Object(t) === t && Q0 in t ? _9.call(xs(t), 8, -1) : S ? "Object" : "", v = I || typeof t.constructor != "function" ? "" : t.constructor.name ? t.constructor.name + " " : "", k = v + (R || S ? "[" + ri.call(MG.call([], R || [], S || []), ": ") + "] " : "");
|
|
34895
34895
|
return L.length === 0 ? k + "{}" : h ? k + "{" + Op(L, h) + "}" : k + "{ " + ri.call(L, ", ") + " }";
|
|
34896
34896
|
}
|
|
34897
34897
|
return String(t);
|
|
@@ -34901,28 +34901,28 @@ function $V(i, t, e) {
|
|
|
34901
34901
|
return n + i + n;
|
|
34902
34902
|
}
|
|
34903
34903
|
function W8(i) {
|
|
34904
|
-
return
|
|
34904
|
+
return ms.call(String(i), /"/g, """);
|
|
34905
34905
|
}
|
|
34906
34906
|
function Dp(i) {
|
|
34907
|
-
return
|
|
34907
|
+
return xs(i) === "[object Array]" && (!Q0 || !(typeof i == "object" && Q0 in i));
|
|
34908
34908
|
}
|
|
34909
34909
|
function V8(i) {
|
|
34910
|
-
return
|
|
34910
|
+
return xs(i) === "[object Date]" && (!Q0 || !(typeof i == "object" && Q0 in i));
|
|
34911
34911
|
}
|
|
34912
34912
|
function kG(i) {
|
|
34913
|
-
return
|
|
34913
|
+
return xs(i) === "[object RegExp]" && (!Q0 || !(typeof i == "object" && Q0 in i));
|
|
34914
34914
|
}
|
|
34915
34915
|
function g8(i) {
|
|
34916
|
-
return
|
|
34916
|
+
return xs(i) === "[object Error]" && (!Q0 || !(typeof i == "object" && Q0 in i));
|
|
34917
34917
|
}
|
|
34918
34918
|
function f8(i) {
|
|
34919
|
-
return
|
|
34919
|
+
return xs(i) === "[object String]" && (!Q0 || !(typeof i == "object" && Q0 in i));
|
|
34920
34920
|
}
|
|
34921
34921
|
function R8(i) {
|
|
34922
|
-
return
|
|
34922
|
+
return xs(i) === "[object Number]" && (!Q0 || !(typeof i == "object" && Q0 in i));
|
|
34923
34923
|
}
|
|
34924
34924
|
function x8(i) {
|
|
34925
|
-
return
|
|
34925
|
+
return xs(i) === "[object Boolean]" && (!Q0 || !(typeof i == "object" && Q0 in i));
|
|
34926
34926
|
}
|
|
34927
34927
|
function tg(i) {
|
|
34928
34928
|
if (Ka)
|
|
@@ -34949,10 +34949,10 @@ function S8(i) {
|
|
|
34949
34949
|
var L8 = Object.prototype.hasOwnProperty || function(i) {
|
|
34950
34950
|
return i in this;
|
|
34951
34951
|
};
|
|
34952
|
-
function
|
|
34952
|
+
function ds(i, t) {
|
|
34953
34953
|
return L8.call(i, t);
|
|
34954
34954
|
}
|
|
34955
|
-
function
|
|
34955
|
+
function xs(i) {
|
|
34956
34956
|
return p8.call(i);
|
|
34957
34957
|
}
|
|
34958
34958
|
function C8(i) {
|
|
@@ -35046,7 +35046,7 @@ function ng(i, t) {
|
|
|
35046
35046
|
var e = i.length - t.maxStringLength, n = "... " + e + " more character" + (e > 1 ? "s" : "");
|
|
35047
35047
|
return ng(_9.call(i, 0, t.maxStringLength), t) + n;
|
|
35048
35048
|
}
|
|
35049
|
-
var s =
|
|
35049
|
+
var s = ms.call(ms.call(i, /(['\\])/g, "\\$1"), /[\x00-\x1f]/g, F8);
|
|
35050
35050
|
return $V(s, "single", t);
|
|
35051
35051
|
}
|
|
35052
35052
|
function F8(i) {
|
|
@@ -35102,7 +35102,7 @@ function Vr(i, t) {
|
|
|
35102
35102
|
if (e) {
|
|
35103
35103
|
n.length = i.length;
|
|
35104
35104
|
for (var s = 0; s < i.length; s++)
|
|
35105
|
-
n[s] =
|
|
35105
|
+
n[s] = ds(i, s) ? t(i[s], i) : "";
|
|
35106
35106
|
}
|
|
35107
35107
|
var l = typeof S1 == "function" ? S1(i) : [], a;
|
|
35108
35108
|
if (Ka) {
|
|
@@ -35111,13 +35111,13 @@ function Vr(i, t) {
|
|
|
35111
35111
|
a["$" + l[o]] = l[o];
|
|
35112
35112
|
}
|
|
35113
35113
|
for (var c in i)
|
|
35114
|
-
|
|
35114
|
+
ds(i, c) && (e && String(Number(c)) === c && c < i.length || Ka && a["$" + c] instanceof Symbol || (_V.call(/[^\w$]/, c) ? n.push(t(c, i) + ": " + t(i[c], i)) : n.push(c + ": " + t(i[c], i))));
|
|
35115
35115
|
if (typeof S1 == "function")
|
|
35116
35116
|
for (var d = 0; d < l.length; d++)
|
|
35117
35117
|
qV.call(i, l[d]) && n.push("[" + t(l[d]) + "]: " + t(i[l[d]], i));
|
|
35118
35118
|
return n;
|
|
35119
35119
|
}
|
|
35120
|
-
var ig = ii, qa = Jn, w8 = y8, K8 =
|
|
35120
|
+
var ig = ii, qa = Jn, w8 = y8, K8 = Rs, gr = ig("%WeakMap%", !0), fr = ig("%Map%", !0), k8 = qa("WeakMap.prototype.get", !0), z8 = qa("WeakMap.prototype.set", !0), U8 = qa("WeakMap.prototype.has", !0), B8 = qa("Map.prototype.get", !0), P8 = qa("Map.prototype.set", !0), E8 = qa("Map.prototype.has", !0), q9 = function(i, t) {
|
|
35121
35121
|
for (var e = i, n; (n = e.next) !== null; e = n)
|
|
35122
35122
|
if (n.key === t)
|
|
35123
35123
|
return e.next = n.next, n.next = /** @type {NonNullable<typeof list.next>} */
|
|
@@ -35168,7 +35168,7 @@ var ig = ii, qa = Jn, w8 = y8, K8 = fs, gr = ig("%WeakMap%", !0), fr = ig("%Map%
|
|
|
35168
35168
|
}
|
|
35169
35169
|
};
|
|
35170
35170
|
return s;
|
|
35171
|
-
}, D8 = YV, xo = sg(), Ci =
|
|
35171
|
+
}, D8 = YV, xo = sg(), Ci = Rs, $9 = {
|
|
35172
35172
|
assert: function(i, t) {
|
|
35173
35173
|
if (!i || typeof i != "object" && typeof i != "function")
|
|
35174
35174
|
throw new Ci("`O` is not an object");
|
|
@@ -35919,7 +35919,7 @@ var XJ = Object.defineProperty, Pe = (i, t) => XJ(i, "name", { value: t, configu
|
|
|
35919
35919
|
constructor(t) {
|
|
35920
35920
|
this.direction = !1, this.compareProperties = !0;
|
|
35921
35921
|
var e, n, s;
|
|
35922
|
-
this.precision =
|
|
35922
|
+
this.precision = Ys(10, -((e = t == null ? void 0 : t.precision) != null ? e : 17)), this.direction = (n = t == null ? void 0 : t.direction) != null ? n : !1, this.compareProperties = (s = t == null ? void 0 : t.compareProperties) != null ? s : !0;
|
|
35923
35923
|
}
|
|
35924
35924
|
compare(t, e) {
|
|
35925
35925
|
if (t.type !== e.type || !Fo(t, e))
|
|
@@ -36049,11 +36049,11 @@ var Gn = 63710088e-1, vg = {
|
|
|
36049
36049
|
millimetres: 1e6,
|
|
36050
36050
|
yards: 1.195990046
|
|
36051
36051
|
};
|
|
36052
|
-
function
|
|
36052
|
+
function Ss(i, t, e = {}) {
|
|
36053
36053
|
const n = { type: "Feature" };
|
|
36054
36054
|
return (e.id === 0 || e.id) && (n.id = e.id), e.bbox && (n.bbox = e.bbox), n.properties = t || {}, n.geometry = i, n;
|
|
36055
36055
|
}
|
|
36056
|
-
Pe(
|
|
36056
|
+
Pe(Ss, "feature");
|
|
36057
36057
|
function WJ(i, t, e = {}) {
|
|
36058
36058
|
switch (i) {
|
|
36059
36059
|
case "Point":
|
|
@@ -36082,7 +36082,7 @@ function sb(i, t, e = {}) {
|
|
|
36082
36082
|
throw new Error("coordinates must be at least 2 numbers long");
|
|
36083
36083
|
if (!za(i[0]) || !za(i[1]))
|
|
36084
36084
|
throw new Error("coordinates must contain numbers");
|
|
36085
|
-
return
|
|
36085
|
+
return Ss({
|
|
36086
36086
|
type: "Point",
|
|
36087
36087
|
coordinates: i
|
|
36088
36088
|
}, t, e);
|
|
@@ -36107,7 +36107,7 @@ function lb(i, t, e = {}) {
|
|
|
36107
36107
|
if (s[s.length - 1][l] !== s[0][l])
|
|
36108
36108
|
throw new Error("First and last Position are not equivalent.");
|
|
36109
36109
|
}
|
|
36110
|
-
return
|
|
36110
|
+
return Ss({
|
|
36111
36111
|
type: "Polygon",
|
|
36112
36112
|
coordinates: i
|
|
36113
36113
|
}, t, e);
|
|
@@ -36123,7 +36123,7 @@ Pe(gJ, "polygons");
|
|
|
36123
36123
|
function ab(i, t, e = {}) {
|
|
36124
36124
|
if (i.length < 2)
|
|
36125
36125
|
throw new Error("coordinates must be an array of two or more positions");
|
|
36126
|
-
return
|
|
36126
|
+
return Ss({
|
|
36127
36127
|
type: "LineString",
|
|
36128
36128
|
coordinates: i
|
|
36129
36129
|
}, t, e);
|
|
@@ -36142,28 +36142,28 @@ function mm(i, t = {}) {
|
|
|
36142
36142
|
}
|
|
36143
36143
|
Pe(mm, "featureCollection");
|
|
36144
36144
|
function Tg(i, t, e = {}) {
|
|
36145
|
-
return
|
|
36145
|
+
return Ss({
|
|
36146
36146
|
type: "MultiLineString",
|
|
36147
36147
|
coordinates: i
|
|
36148
36148
|
}, t, e);
|
|
36149
36149
|
}
|
|
36150
36150
|
Pe(Tg, "multiLineString");
|
|
36151
36151
|
function Mg(i, t, e = {}) {
|
|
36152
|
-
return
|
|
36152
|
+
return Ss({
|
|
36153
36153
|
type: "MultiPoint",
|
|
36154
36154
|
coordinates: i
|
|
36155
36155
|
}, t, e);
|
|
36156
36156
|
}
|
|
36157
36157
|
Pe(Mg, "multiPoint");
|
|
36158
36158
|
function Fg(i, t, e = {}) {
|
|
36159
|
-
return
|
|
36159
|
+
return Ss({
|
|
36160
36160
|
type: "MultiPolygon",
|
|
36161
36161
|
coordinates: i
|
|
36162
36162
|
}, t, e);
|
|
36163
36163
|
}
|
|
36164
36164
|
Pe(Fg, "multiPolygon");
|
|
36165
36165
|
function RJ(i, t, e = {}) {
|
|
36166
|
-
return
|
|
36166
|
+
return Ss({
|
|
36167
36167
|
type: "GeometryCollection",
|
|
36168
36168
|
geometries: i
|
|
36169
36169
|
}, t, e);
|
|
@@ -36253,7 +36253,7 @@ function TJ(i) {
|
|
|
36253
36253
|
throw new Error("id must be a number or a string");
|
|
36254
36254
|
}
|
|
36255
36255
|
Pe(TJ, "validateId");
|
|
36256
|
-
var MJ = Object.defineProperty,
|
|
36256
|
+
var MJ = Object.defineProperty, Ls = (i, t) => MJ(i, "name", { value: t, configurable: !0 });
|
|
36257
36257
|
function wg(i) {
|
|
36258
36258
|
if (!i)
|
|
36259
36259
|
throw new Error("coord is required");
|
|
@@ -36267,7 +36267,7 @@ function wg(i) {
|
|
|
36267
36267
|
return [...i];
|
|
36268
36268
|
throw new Error("coord must be GeoJSON Point or an Array of numbers");
|
|
36269
36269
|
}
|
|
36270
|
-
|
|
36270
|
+
Ls(wg, "getCoord");
|
|
36271
36271
|
function Kg(i) {
|
|
36272
36272
|
if (Array.isArray(i))
|
|
36273
36273
|
return i;
|
|
@@ -36280,7 +36280,7 @@ function Kg(i) {
|
|
|
36280
36280
|
"coords must be GeoJSON Feature, Geometry Object or an Array"
|
|
36281
36281
|
);
|
|
36282
36282
|
}
|
|
36283
|
-
|
|
36283
|
+
Ls(Kg, "getCoords");
|
|
36284
36284
|
function kg(i) {
|
|
36285
36285
|
if (i.length > 1 && za(i[0]) && za(i[1]))
|
|
36286
36286
|
return !0;
|
|
@@ -36288,7 +36288,7 @@ function kg(i) {
|
|
|
36288
36288
|
return kg(i[0]);
|
|
36289
36289
|
throw new Error("coordinates must only contain numbers");
|
|
36290
36290
|
}
|
|
36291
|
-
|
|
36291
|
+
Ls(kg, "containsNumber");
|
|
36292
36292
|
function FJ(i, t, e) {
|
|
36293
36293
|
if (!t || !e)
|
|
36294
36294
|
throw new Error("type and name required");
|
|
@@ -36297,7 +36297,7 @@ function FJ(i, t, e) {
|
|
|
36297
36297
|
"Invalid input to " + e + ": must be a " + t + ", given " + i.type
|
|
36298
36298
|
);
|
|
36299
36299
|
}
|
|
36300
|
-
|
|
36300
|
+
Ls(FJ, "geojsonType");
|
|
36301
36301
|
function HJ(i, t, e) {
|
|
36302
36302
|
if (!i)
|
|
36303
36303
|
throw new Error("No feature passed");
|
|
@@ -36312,7 +36312,7 @@ function HJ(i, t, e) {
|
|
|
36312
36312
|
"Invalid input to " + e + ": must be a " + t + ", given " + i.geometry.type
|
|
36313
36313
|
);
|
|
36314
36314
|
}
|
|
36315
|
-
|
|
36315
|
+
Ls(HJ, "featureOf");
|
|
36316
36316
|
function JJ(i, t, e) {
|
|
36317
36317
|
if (!i)
|
|
36318
36318
|
throw new Error("No featureCollection passed");
|
|
@@ -36333,15 +36333,15 @@ function JJ(i, t, e) {
|
|
|
36333
36333
|
);
|
|
36334
36334
|
}
|
|
36335
36335
|
}
|
|
36336
|
-
|
|
36336
|
+
Ls(JJ, "collectionOf");
|
|
36337
36337
|
function zg(i) {
|
|
36338
36338
|
return i.type === "Feature" ? i.geometry : i;
|
|
36339
36339
|
}
|
|
36340
|
-
|
|
36340
|
+
Ls(zg, "getGeom");
|
|
36341
36341
|
function wJ(i, t) {
|
|
36342
36342
|
return i.type === "FeatureCollection" ? "FeatureCollection" : i.type === "GeometryCollection" ? "GeometryCollection" : i.type === "Feature" && i.geometry !== null ? i.geometry.type : i.type;
|
|
36343
36343
|
}
|
|
36344
|
-
|
|
36344
|
+
Ls(wJ, "getType");
|
|
36345
36345
|
var KJ = Object.defineProperty, kJ = (i, t) => KJ(i, "name", { value: t, configurable: !0 });
|
|
36346
36346
|
function Ug(i) {
|
|
36347
36347
|
const t = Kg(i);
|
|
@@ -36363,12 +36363,12 @@ function pm(i, t, e = 0) {
|
|
|
36363
36363
|
// z
|
|
36364
36364
|
];
|
|
36365
36365
|
}
|
|
36366
|
-
const
|
|
36366
|
+
const _s = /* @__PURE__ */ new Map(), UJ = (i = {}) => ({
|
|
36367
36367
|
generateTopUV(t, e, n, s, l) {
|
|
36368
36368
|
const a = e[n * 3], o = e[n * 3 + 1], c = e[s * 3], d = e[s * 3 + 1], r = e[l * 3], h = e[l * 3 + 1];
|
|
36369
36369
|
let u;
|
|
36370
|
-
if (
|
|
36371
|
-
u =
|
|
36370
|
+
if (_s.has(t))
|
|
36371
|
+
u = _s.get(t);
|
|
36372
36372
|
else {
|
|
36373
36373
|
let Z = i.box3;
|
|
36374
36374
|
if (!Z) {
|
|
@@ -36380,7 +36380,7 @@ const Os = /* @__PURE__ */ new Map(), UJ = (i = {}) => ({
|
|
|
36380
36380
|
i.split && (p.y /= i.split), u = {
|
|
36381
36381
|
box: Z,
|
|
36382
36382
|
size: p
|
|
36383
|
-
},
|
|
36383
|
+
}, _s.set(t, u);
|
|
36384
36384
|
}
|
|
36385
36385
|
const { box: m, size: b } = u, G = i.split ? 1 - i.split : 0;
|
|
36386
36386
|
return [
|
|
@@ -36401,8 +36401,8 @@ const Os = /* @__PURE__ */ new Map(), UJ = (i = {}) => ({
|
|
|
36401
36401
|
generateSideWallUV(t, e, n, s, l, a) {
|
|
36402
36402
|
const o = e[n * 3], c = e[n * 3 + 1], d = e[n * 3 + 2], r = e[s * 3], h = e[s * 3 + 1], u = e[s * 3 + 2], m = e[l * 3], b = e[l * 3 + 1], G = e[l * 3 + 2], Z = e[a * 3], p = e[a * 3 + 1], X = e[a * 3 + 2];
|
|
36403
36403
|
let y;
|
|
36404
|
-
if (
|
|
36405
|
-
y =
|
|
36404
|
+
if (_s.has(e))
|
|
36405
|
+
y = _s.get(e);
|
|
36406
36406
|
else {
|
|
36407
36407
|
const f = new W0();
|
|
36408
36408
|
f.setFromArray(e);
|
|
@@ -36410,7 +36410,7 @@ const Os = /* @__PURE__ */ new Map(), UJ = (i = {}) => ({
|
|
|
36410
36410
|
i.split && (L.z /= 1 - i.split), i.sideRepeat && (L.z /= i.sideRepeat), y = {
|
|
36411
36411
|
box: f,
|
|
36412
36412
|
size: L
|
|
36413
|
-
},
|
|
36413
|
+
}, _s.set(e, y);
|
|
36414
36414
|
}
|
|
36415
36415
|
const { box: W, size: g } = y;
|
|
36416
36416
|
return Math.abs(c - h) < Math.abs(o - r) ? [
|
|
@@ -36438,7 +36438,7 @@ const Os = /* @__PURE__ */ new Map(), UJ = (i = {}) => ({
|
|
|
36438
36438
|
];
|
|
36439
36439
|
}
|
|
36440
36440
|
}), BJ = () => {
|
|
36441
|
-
|
|
36441
|
+
_s.clear();
|
|
36442
36442
|
}, Ki = 11102230246251565e-32, U0 = 134217729, PJ = (3 + 8 * Ki) * Ki;
|
|
36443
36443
|
function K1(i, t, e, n, s) {
|
|
36444
36444
|
let l, a, o, c, d = t[0], r = n[0], h = 0, u = 0;
|
|
@@ -37259,7 +37259,7 @@ function Ww(i) {
|
|
|
37259
37259
|
const s = [];
|
|
37260
37260
|
let l = 1;
|
|
37261
37261
|
for (let h = 0, u = i.length; h < u; h++) {
|
|
37262
|
-
let m =
|
|
37262
|
+
let m = Ys(i[h][0], 2) + Ys(i[h][1], 2);
|
|
37263
37263
|
!isFinite(m) || m > 1e32 ? s.push(h) : m > l && (l = m);
|
|
37264
37264
|
}
|
|
37265
37265
|
const a = 1e6 * Qg(l);
|
|
@@ -39096,11 +39096,11 @@ class Zb extends Ot {
|
|
|
39096
39096
|
const Vt = z.length, Ut = Q.length;
|
|
39097
39097
|
function jt(rt, nt, ot) {
|
|
39098
39098
|
let F, Y, D;
|
|
39099
|
-
const at = rt.x - nt.x, dt = rt.y - nt.y,
|
|
39099
|
+
const at = rt.x - nt.x, dt = rt.y - nt.y, bt = ot.x - rt.x, Kt = ot.y - rt.y, vt = at * at + dt * dt, kt = at * Kt - dt * bt;
|
|
39100
39100
|
if (Math.abs(kt) > Number.EPSILON) {
|
|
39101
39101
|
const At = Math.sqrt(vt), xt = Math.sqrt(
|
|
39102
|
-
|
|
39103
|
-
), zt = nt.x - dt / At, Xe = nt.y + at / At, Et = ot.x - Kt / xt, Ht = ot.y +
|
|
39102
|
+
bt * bt + Kt * Kt
|
|
39103
|
+
), zt = nt.x - dt / At, Xe = nt.y + at / At, Et = ot.x - Kt / xt, Ht = ot.y + bt / xt, te = ((Et - zt) * Kt - (Ht - Xe) * bt) / (at * Kt - dt * bt);
|
|
39104
39104
|
F = zt + at * te - rt.x, Y = Xe + dt * te - rt.y;
|
|
39105
39105
|
const $t = F * F + Y * Y;
|
|
39106
39106
|
if ($t <= 2)
|
|
@@ -39108,7 +39108,7 @@ class Zb extends Ot {
|
|
|
39108
39108
|
D = Math.sqrt($t / 2);
|
|
39109
39109
|
} else {
|
|
39110
39110
|
let At = !1;
|
|
39111
|
-
at > Number.EPSILON ?
|
|
39111
|
+
at > Number.EPSILON ? bt > Number.EPSILON && (At = !0) : at < -Number.EPSILON ? bt < -Number.EPSILON && (At = !0) : Math.sign(dt) === Math.sign(Kt) && (At = !0), At ? (F = -dt, Y = at, D = Math.sqrt(vt)) : (F = at, Y = dt, D = Math.sqrt(vt / 2));
|
|
39112
39112
|
}
|
|
39113
39113
|
return new _(F / D, Y / D);
|
|
39114
39114
|
}
|
|
@@ -39133,7 +39133,7 @@ class Zb extends Ot {
|
|
|
39133
39133
|
for (let Y = 0, D = E.length; Y < D; Y++) {
|
|
39134
39134
|
const at = E[Y];
|
|
39135
39135
|
Wt = Xt[Y];
|
|
39136
|
-
for (let dt = 0,
|
|
39136
|
+
for (let dt = 0, bt = at.length; dt < bt; dt++) {
|
|
39137
39137
|
const Kt = yt(at[dt], Wt[dt], F);
|
|
39138
39138
|
M(Kt.x, Kt.y, -ot);
|
|
39139
39139
|
}
|
|
@@ -39158,7 +39158,7 @@ class Zb extends Ot {
|
|
|
39158
39158
|
for (let Y = 0, D = E.length; Y < D; Y++) {
|
|
39159
39159
|
const at = E[Y];
|
|
39160
39160
|
Wt = Xt[Y];
|
|
39161
|
-
for (let dt = 0,
|
|
39161
|
+
for (let dt = 0, bt = at.length; dt < bt; dt++) {
|
|
39162
39162
|
const Kt = yt(at[dt], Wt[dt], F);
|
|
39163
39163
|
R ? M(
|
|
39164
39164
|
Kt.x,
|
|
@@ -39218,7 +39218,7 @@ class Zb extends Ot {
|
|
|
39218
39218
|
let Y = ot - 1;
|
|
39219
39219
|
Y < 0 && (Y = rt.length - 1);
|
|
39220
39220
|
for (let D = 0, at = m + y * 2; D < at; D++) {
|
|
39221
|
-
const dt = Vt * D,
|
|
39221
|
+
const dt = Vt * D, bt = Vt * (D + 1), Kt = nt + F + dt, vt = nt + Y + dt, kt = nt + Y + bt, At = nt + F + bt;
|
|
39222
39222
|
gt(Kt, vt, kt, At);
|
|
39223
39223
|
}
|
|
39224
39224
|
}
|
|
@@ -39235,7 +39235,7 @@ class Zb extends Ot {
|
|
|
39235
39235
|
F - 2,
|
|
39236
39236
|
F - 1
|
|
39237
39237
|
);
|
|
39238
|
-
|
|
39238
|
+
mt(Y[0]), mt(Y[1]), mt(Y[2]);
|
|
39239
39239
|
}
|
|
39240
39240
|
function gt(rt, nt, ot, F) {
|
|
39241
39241
|
Ct(rt), Ct(nt), Ct(F), Ct(nt), Ct(ot), Ct(F);
|
|
@@ -39247,12 +39247,12 @@ class Zb extends Ot {
|
|
|
39247
39247
|
Y - 2,
|
|
39248
39248
|
Y - 1
|
|
39249
39249
|
);
|
|
39250
|
-
|
|
39250
|
+
mt(D[0]), mt(D[1]), mt(D[3]), mt(D[1]), mt(D[2]), mt(D[3]);
|
|
39251
39251
|
}
|
|
39252
39252
|
function Ct(rt) {
|
|
39253
39253
|
s.push(h[rt * 3 + 0]), s.push(h[rt * 3 + 1]), s.push(h[rt * 3 + 2]);
|
|
39254
39254
|
}
|
|
39255
|
-
function
|
|
39255
|
+
function mt(rt) {
|
|
39256
39256
|
l.push(rt.x), l.push(rt.y);
|
|
39257
39257
|
}
|
|
39258
39258
|
}
|
|
@@ -39498,7 +39498,7 @@ class jK extends Ge {
|
|
|
39498
39498
|
}, e);
|
|
39499
39499
|
}
|
|
39500
39500
|
create() {
|
|
39501
|
-
return
|
|
39501
|
+
return ht(this, null, function* () {
|
|
39502
39502
|
const { sprite: e } = this.options, n = this.getImage("#ffffff"), l = yield this.pencil.getPlugin("draw").draw(
|
|
39503
39503
|
"Image",
|
|
39504
39504
|
{
|
|
@@ -39538,7 +39538,7 @@ const E1 = {}, xc = (i) => {
|
|
|
39538
39538
|
let s = i.clone().add(t);
|
|
39539
39539
|
s = s.normalize().multiplyScalar(e);
|
|
39540
39540
|
let l;
|
|
39541
|
-
n <= 1 ? l = e / 5 * n : n > 1 && n < 2 ? l = e / 5 *
|
|
39541
|
+
n <= 1 ? l = e / 5 * n : n > 1 && n < 2 ? l = e / 5 * Ys(n, 2) : l = e / 5 * Ys(n, 1.5);
|
|
39542
39542
|
const a = i.clone().add(s).normalize().multiplyScalar(e + l), o = t.clone().add(s).normalize().multiplyScalar(e + l);
|
|
39543
39543
|
return new Bc(i, a, o, t);
|
|
39544
39544
|
}, mX = (i, t, e = 40) => {
|
|
@@ -39576,7 +39576,7 @@ class sf extends Ge {
|
|
|
39576
39576
|
};
|
|
39577
39577
|
}
|
|
39578
39578
|
create() {
|
|
39579
|
-
return
|
|
39579
|
+
return ht(this, null, function* () {
|
|
39580
39580
|
Q1 || (Q1 = AK(0.5));
|
|
39581
39581
|
const { color: e, lineWidth: n, globe: s } = this.options;
|
|
39582
39582
|
let { radius: l } = this.options;
|
|
@@ -39609,7 +39609,7 @@ class sf extends Ge {
|
|
|
39609
39609
|
});
|
|
39610
39610
|
}
|
|
39611
39611
|
instantiate() {
|
|
39612
|
-
return
|
|
39612
|
+
return ht(this, null, function* () {
|
|
39613
39613
|
this.update();
|
|
39614
39614
|
const e = yield this.line.instantiate(), n = yield this.drawController.instantiate(this, {
|
|
39615
39615
|
create: (s) => {
|
|
@@ -39716,7 +39716,7 @@ class OK extends Ge {
|
|
|
39716
39716
|
this.options = Tt({}, e);
|
|
39717
39717
|
}
|
|
39718
39718
|
create() {
|
|
39719
|
-
return
|
|
39719
|
+
return ht(this, null, function* () {
|
|
39720
39720
|
const s = new Sn(0.5, 5, 2, 2);
|
|
39721
39721
|
this.createGroup();
|
|
39722
39722
|
const l = this.options.material || new Dt({
|
|
@@ -39731,7 +39731,7 @@ class OK extends Ge {
|
|
|
39731
39731
|
}
|
|
39732
39732
|
class _K extends Ge {
|
|
39733
39733
|
create() {
|
|
39734
|
-
return
|
|
39734
|
+
return ht(this, null, function* () {
|
|
39735
39735
|
const t = new Sn(100, 100, 2, 2), e = new d9();
|
|
39736
39736
|
e.opacity = 0.5, e.depthWrite = !1, this.createMesh(t, e), this.object3d.receiveShadow = !0, this.position.z = 0.1, this.object3d.name = "阴影接受";
|
|
39737
39737
|
});
|
|
@@ -39744,7 +39744,7 @@ class lf extends Ge {
|
|
|
39744
39744
|
this.options = Tt({}, e);
|
|
39745
39745
|
}
|
|
39746
39746
|
create() {
|
|
39747
|
-
return
|
|
39747
|
+
return ht(this, null, function* () {
|
|
39748
39748
|
const e = this.pencil.getPlugin("loader"), n = this.options.src;
|
|
39749
39749
|
if (!n)
|
|
39750
39750
|
throw new Error("src is required");
|
|
@@ -39847,7 +39847,7 @@ class Gb extends Ge {
|
|
|
39847
39847
|
create() {
|
|
39848
39848
|
var n;
|
|
39849
39849
|
(n = this.options) != null && n.radius && (this.radius = this.options.radius);
|
|
39850
|
-
const e = new
|
|
39850
|
+
const e = new gs(this.radius, 128, 90);
|
|
39851
39851
|
this.createMesh(e, this.material), this.object3d.rotation.y = Math.PI / 180 * 90;
|
|
39852
39852
|
}
|
|
39853
39853
|
}
|
|
@@ -40079,10 +40079,10 @@ class bX extends H0 {
|
|
|
40079
40079
|
if (this.resourcePath !== "")
|
|
40080
40080
|
a = this.resourcePath;
|
|
40081
40081
|
else if (this.path !== "") {
|
|
40082
|
-
const d =
|
|
40083
|
-
a =
|
|
40082
|
+
const d = bs.extractUrlBase(t);
|
|
40083
|
+
a = bs.resolveURL(d, this.path);
|
|
40084
40084
|
} else
|
|
40085
|
-
a =
|
|
40085
|
+
a = bs.extractUrlBase(t);
|
|
40086
40086
|
this.manager.itemStart(t);
|
|
40087
40087
|
const o = function(d) {
|
|
40088
40088
|
s ? s(d) : console.error(d), l.manager.itemError(t), l.manager.itemEnd(t);
|
|
@@ -40745,7 +40745,7 @@ const Nn = {
|
|
|
40745
40745
|
9729: Ne,
|
|
40746
40746
|
9984: Nc,
|
|
40747
40747
|
9985: ol,
|
|
40748
|
-
9986:
|
|
40748
|
+
9986: hs,
|
|
40749
40749
|
9987: rn
|
|
40750
40750
|
}, XX = {
|
|
40751
40751
|
33071: G0,
|
|
@@ -40797,7 +40797,7 @@ function Uk(i) {
|
|
|
40797
40797
|
side: $n
|
|
40798
40798
|
})), i.DefaultMaterial;
|
|
40799
40799
|
}
|
|
40800
|
-
function
|
|
40800
|
+
function Qs(i, t, e) {
|
|
40801
40801
|
for (const n in e.extensions)
|
|
40802
40802
|
i[n] === void 0 && (t.userData.gltfExtensions = t.userData.gltfExtensions || {}, t.userData.gltfExtensions[n] = e.extensions[n]);
|
|
40803
40803
|
}
|
|
@@ -40923,7 +40923,7 @@ class Ak {
|
|
|
40923
40923
|
parser: n,
|
|
40924
40924
|
userData: {}
|
|
40925
40925
|
};
|
|
40926
|
-
return
|
|
40926
|
+
return Qs(l, o, s), Yi(o, s), Promise.all(n._invokeAll(function(c) {
|
|
40927
40927
|
return c.afterRoot && c.afterRoot(o);
|
|
40928
40928
|
})).then(function() {
|
|
40929
40929
|
for (const c of o.scenes)
|
|
@@ -41084,7 +41084,7 @@ class Ak {
|
|
|
41084
41084
|
return Promise.resolve(this.extensions[ge.KHR_BINARY_GLTF].body);
|
|
41085
41085
|
const s = this.options;
|
|
41086
41086
|
return new Promise(function(l, a) {
|
|
41087
|
-
n.load(
|
|
41087
|
+
n.load(bs.resolveURL(e.uri, s.path), l, void 0, function() {
|
|
41088
41088
|
a(new Error('THREE.GLTFLoader: Failed to load buffer "' + e.uri + '".'));
|
|
41089
41089
|
});
|
|
41090
41090
|
});
|
|
@@ -41119,7 +41119,7 @@ class Ak {
|
|
|
41119
41119
|
if (m && m !== h) {
|
|
41120
41120
|
const p = Math.floor(u / m), X = "InterleavedBuffer:" + s.bufferView + ":" + s.componentType + ":" + p + ":" + s.count;
|
|
41121
41121
|
let y = e.cache.get(X);
|
|
41122
|
-
y || (G = new d(o, p * m, s.count * m / r), y = new Kc(G, m / r), e.cache.add(X, y)), Z = new
|
|
41122
|
+
y || (G = new d(o, p * m, s.count * m / r), y = new Kc(G, m / r), e.cache.add(X, y)), Z = new ys(y, c, u % m / r, b);
|
|
41123
41123
|
} else
|
|
41124
41124
|
o === null ? G = new d(s.count * c) : G = new d(o, u, s.count * c), Z = new ne(G, c, b);
|
|
41125
41125
|
if (s.sparse !== void 0) {
|
|
@@ -41180,7 +41180,7 @@ class Ak {
|
|
|
41180
41180
|
e.isImageBitmapLoader === !0 && (b = function(G) {
|
|
41181
41181
|
const Z = new Je(G);
|
|
41182
41182
|
Z.needsUpdate = !0, u(Z);
|
|
41183
|
-
}), e.load(
|
|
41183
|
+
}), e.load(bs.resolveURL(h, l.path), b, void 0, m);
|
|
41184
41184
|
});
|
|
41185
41185
|
}).then(function(h) {
|
|
41186
41186
|
return d === !0 && o.revokeObjectURL(c), Yi(h, a), h.userData.mimeType = a.mimeType || Qk(a.uri), h;
|
|
@@ -41278,7 +41278,7 @@ class Ak {
|
|
|
41278
41278
|
}
|
|
41279
41279
|
return l.emissiveTexture !== void 0 && a !== Dt && d.push(e.assignTexture(o, "emissiveMap", l.emissiveTexture, ye)), Promise.all(d).then(function() {
|
|
41280
41280
|
const h = new a(o);
|
|
41281
|
-
return l.name && (h.name = l.name), Yi(h, l), e.associations.set(h, { materials: t }), l.extensions &&
|
|
41281
|
+
return l.name && (h.name = l.name), Yi(h, l), e.associations.set(h, { materials: t }), l.extensions && Qs(s, h, l), h;
|
|
41282
41282
|
});
|
|
41283
41283
|
}
|
|
41284
41284
|
/** When Object3D instances are targeted by animation, they need unique names. */
|
|
@@ -41342,7 +41342,7 @@ class Ak {
|
|
|
41342
41342
|
p = new Eu(G, X);
|
|
41343
41343
|
else
|
|
41344
41344
|
throw new Error("THREE.GLTFLoader: Primitive mode unsupported: " + Z.mode);
|
|
41345
|
-
Object.keys(p.geometry.morphAttributes).length > 0 && Pk(p, l), p.name = e.createUniqueName(l.name || "mesh_" + t), Yi(p, l), Z.extensions &&
|
|
41345
|
+
Object.keys(p.geometry.morphAttributes).length > 0 && Pk(p, l), p.name = e.createUniqueName(l.name || "mesh_" + t), Yi(p, l), Z.extensions && Qs(s, p, Z), e.assignFinalMaterial(p), h.push(p);
|
|
41346
41346
|
}
|
|
41347
41347
|
for (let m = 0, b = h.length; m < b; m++)
|
|
41348
41348
|
e.associations.set(h[m], {
|
|
@@ -41350,9 +41350,9 @@ class Ak {
|
|
|
41350
41350
|
primitives: m
|
|
41351
41351
|
});
|
|
41352
41352
|
if (h.length === 1)
|
|
41353
|
-
return l.extensions &&
|
|
41353
|
+
return l.extensions && Qs(s, h[0], l), h[0];
|
|
41354
41354
|
const u = new ui();
|
|
41355
|
-
l.extensions &&
|
|
41355
|
+
l.extensions && Qs(s, u, l), e.associations.set(u, { meshes: t });
|
|
41356
41356
|
for (let m = 0, b = h.length; m < b; m++)
|
|
41357
41357
|
u.add(h[m]);
|
|
41358
41358
|
return u;
|
|
@@ -41481,7 +41481,7 @@ class Ak {
|
|
|
41481
41481
|
if (l.isBone === !0 ? r = new Bu() : d.length > 1 ? r = new ui() : d.length === 1 ? r = d[0] : r = new be(), r !== d[0])
|
|
41482
41482
|
for (let h = 0, u = d.length; h < u; h++)
|
|
41483
41483
|
r.add(d[h]);
|
|
41484
|
-
if (l.name && (r.userData.name = l.name, r.name = a), Yi(r, l), l.extensions &&
|
|
41484
|
+
if (l.name && (r.userData.name = l.name, r.name = a), Yi(r, l), l.extensions && Qs(n, r, l), l.matrix !== void 0) {
|
|
41485
41485
|
const h = new Pt();
|
|
41486
41486
|
h.fromArray(l.matrix), r.applyMatrix4(h);
|
|
41487
41487
|
} else
|
|
@@ -41496,7 +41496,7 @@ class Ak {
|
|
|
41496
41496
|
*/
|
|
41497
41497
|
loadScene(t) {
|
|
41498
41498
|
const e = this.extensions, n = this.json.scenes[t], s = this, l = new ui();
|
|
41499
|
-
n.name && (l.name = s.createUniqueName(n.name)), Yi(l, n), n.extensions &&
|
|
41499
|
+
n.name && (l.name = s.createUniqueName(n.name)), Yi(l, n), n.extensions && Qs(e, l, n);
|
|
41500
41500
|
const a = n.nodes || [], o = [];
|
|
41501
41501
|
for (let c = 0, d = a.length; c < d; c++)
|
|
41502
41502
|
o.push(s.getDependency("node", a[c]));
|
|
@@ -42275,13 +42275,13 @@ class mz extends mW {
|
|
|
42275
42275
|
for (; $ <= tt; ) $ <<= 1;
|
|
42276
42276
|
for ($ >>= 1, it = $, $ >>= 1; $ >= 1; ) {
|
|
42277
42277
|
Rt = 0;
|
|
42278
|
-
const Lt = Rt + U * (P - it), Ft = U * $, Nt = U * it,
|
|
42278
|
+
const Lt = Rt + U * (P - it), Ft = U * $, Nt = U * it, pt = J * $, Jt = J * it;
|
|
42279
42279
|
let wt, Ze, we, De;
|
|
42280
42280
|
for (; Rt <= Lt; Rt += Nt) {
|
|
42281
42281
|
let Ue = Rt;
|
|
42282
42282
|
const _t = Rt + J * (C - it);
|
|
42283
42283
|
for (; Ue <= _t; Ue += Jt) {
|
|
42284
|
-
const Ee = Ue +
|
|
42284
|
+
const Ee = Ue + pt, w0 = Ue + Ft, Fe = w0 + pt;
|
|
42285
42285
|
ct ? (St(V[Ue + x], V[w0 + x]), wt = Wt.a, we = Wt.b, St(V[Ee + x], V[Fe + x]), Ze = Wt.a, De = Wt.b, St(wt, Ze), V[Ue + x] = Wt.a, V[Ee + x] = Wt.b, St(we, De), V[w0 + x] = Wt.a, V[Fe + x] = Wt.b) : (Qt(V[Ue + x], V[w0 + x]), wt = Wt.a, we = Wt.b, Qt(V[Ee + x], V[Fe + x]), Ze = Wt.a, De = Wt.b, Qt(wt, Ze), V[Ue + x] = Wt.a, V[Ee + x] = Wt.b, Qt(we, De), V[w0 + x] = Wt.a, V[Fe + x] = Wt.b);
|
|
42286
42286
|
}
|
|
42287
42287
|
if (C & $) {
|
|
@@ -42293,7 +42293,7 @@ class mz extends mW {
|
|
|
42293
42293
|
let Ue = Rt;
|
|
42294
42294
|
const _t = Rt + J * (C - it);
|
|
42295
42295
|
for (; Ue <= _t; Ue += Jt) {
|
|
42296
|
-
const Ee = Ue +
|
|
42296
|
+
const Ee = Ue + pt;
|
|
42297
42297
|
ct ? St(V[Ue + x], V[Ee + x]) : Qt(V[Ue + x], V[Ee + x]), wt = Wt.a, V[Ee + x] = Wt.b, V[Ue + x] = wt;
|
|
42298
42298
|
}
|
|
42299
42299
|
}
|
|
@@ -42306,23 +42306,23 @@ class mz extends mW {
|
|
|
42306
42306
|
const Rt = q, Lt = Math.trunc(J.value + (P + 7) / 8);
|
|
42307
42307
|
for (; J.value < Lt; )
|
|
42308
42308
|
for (Vt($, it, C, J), $ = yt.c, it = yt.lc; it >= 14; ) {
|
|
42309
|
-
const Nt = $ >> it - 14 & 16383,
|
|
42310
|
-
if (
|
|
42311
|
-
it -=
|
|
42309
|
+
const Nt = $ >> it - 14 & 16383, pt = x[Nt];
|
|
42310
|
+
if (pt.len)
|
|
42311
|
+
it -= pt.len, jt(pt.lit, U, $, it, C, J, ct, tt, Rt), $ = Ut.c, it = Ut.lc;
|
|
42312
42312
|
else {
|
|
42313
|
-
if (!
|
|
42313
|
+
if (!pt.p)
|
|
42314
42314
|
throw new Error("hufDecode issues");
|
|
42315
42315
|
let Jt;
|
|
42316
|
-
for (Jt = 0; Jt <
|
|
42317
|
-
const wt = E(V[
|
|
42316
|
+
for (Jt = 0; Jt < pt.lit; Jt++) {
|
|
42317
|
+
const wt = E(V[pt.p[Jt]]);
|
|
42318
42318
|
for (; it < wt && J.value < Lt; )
|
|
42319
42319
|
Vt($, it, C, J), $ = yt.c, it = yt.lc;
|
|
42320
|
-
if (it >= wt && Q(V[
|
|
42321
|
-
it -= wt, jt(
|
|
42320
|
+
if (it >= wt && Q(V[pt.p[Jt]]) == ($ >> it - wt & (1 << wt) - 1)) {
|
|
42321
|
+
it -= wt, jt(pt.p[Jt], U, $, it, C, J, ct, tt, Rt), $ = Ut.c, it = Ut.lc;
|
|
42322
42322
|
break;
|
|
42323
42323
|
}
|
|
42324
42324
|
}
|
|
42325
|
-
if (Jt ==
|
|
42325
|
+
if (Jt == pt.lit)
|
|
42326
42326
|
throw new Error("hufDecode issues");
|
|
42327
42327
|
}
|
|
42328
42328
|
}
|
|
@@ -42387,9 +42387,9 @@ class mz extends mW {
|
|
|
42387
42387
|
}
|
|
42388
42388
|
return C;
|
|
42389
42389
|
}
|
|
42390
|
-
function
|
|
42390
|
+
function mt(V, x, C, J, P, U) {
|
|
42391
42391
|
let q = new DataView(U.buffer);
|
|
42392
|
-
const ct = C[V.idx[0]].width, tt = C[V.idx[0]].height, $ = 3, it = Math.floor(ct / 8), Rt = Math.ceil(ct / 8), Lt = Math.ceil(tt / 8), Ft = ct - (Rt - 1) * 8, Nt = tt - (Lt - 1) * 8,
|
|
42392
|
+
const ct = C[V.idx[0]].width, tt = C[V.idx[0]].height, $ = 3, it = Math.floor(ct / 8), Rt = Math.ceil(ct / 8), Lt = Math.ceil(tt / 8), Ft = ct - (Rt - 1) * 8, Nt = tt - (Lt - 1) * 8, pt = { value: 0 }, Jt = new Array($), wt = new Array($), Ze = new Array($), we = new Array($), De = new Array($);
|
|
42393
42393
|
for (let _t = 0; _t < $; ++_t)
|
|
42394
42394
|
De[_t] = x[V.idx[_t]], Jt[_t] = _t < 1 ? 0 : Jt[_t - 1] + Rt * Lt, wt[_t] = new Float32Array(64), Ze[_t] = new Uint16Array(64), we[_t] = new Uint16Array(Rt * 64);
|
|
42395
42395
|
for (let _t = 0; _t < Lt; ++_t) {
|
|
@@ -42399,7 +42399,7 @@ class mz extends mW {
|
|
|
42399
42399
|
for (let Ye = 0; Ye < Rt; ++Ye) {
|
|
42400
42400
|
Ye == Rt - 1 && (w0 = Ft);
|
|
42401
42401
|
for (let Qe = 0; Qe < $; ++Qe)
|
|
42402
|
-
Ze[Qe].fill(0), Ze[Qe][0] = P[Jt[Qe]++], rt(
|
|
42402
|
+
Ze[Qe].fill(0), Ze[Qe][0] = P[Jt[Qe]++], rt(pt, J, Ze[Qe]), nt(Ze[Qe], wt[Qe]), ot(wt[Qe]);
|
|
42403
42403
|
F(wt);
|
|
42404
42404
|
for (let Qe = 0; Qe < $; ++Qe)
|
|
42405
42405
|
Y(wt[Qe], we[Qe], Ye * 64);
|
|
@@ -42474,7 +42474,7 @@ class mz extends mW {
|
|
|
42474
42474
|
const x = V.viewer.buffer.slice(V.offset.value, V.offset.value + V.size), C = new Uint8Array(Ct(x)), J = new Uint8Array(C.length);
|
|
42475
42475
|
return ft(C), gt(C, J), new DataView(J.buffer);
|
|
42476
42476
|
}
|
|
42477
|
-
function
|
|
42477
|
+
function bt(V) {
|
|
42478
42478
|
const x = V.array.slice(V.offset.value, V.offset.value + V.size), C = Ir(x), J = new Uint8Array(C.length);
|
|
42479
42479
|
return ft(C), gt(C, J), new DataView(J.buffer);
|
|
42480
42480
|
}
|
|
@@ -42482,7 +42482,7 @@ class mz extends mW {
|
|
|
42482
42482
|
const x = V.viewer, C = { value: V.offset.value }, J = new Uint16Array(V.columns * V.lines * (V.inputChannels.length * V.type)), P = new Uint8Array(8192);
|
|
42483
42483
|
let U = 0;
|
|
42484
42484
|
const q = new Array(V.inputChannels.length);
|
|
42485
|
-
for (let Nt = 0,
|
|
42485
|
+
for (let Nt = 0, pt = V.inputChannels.length; Nt < pt; Nt++)
|
|
42486
42486
|
q[Nt] = {}, q[Nt].start = U, q[Nt].end = q[Nt].start, q[Nt].nx = V.columns, q[Nt].ny = V.lines, q[Nt].size = V.type, U += q[Nt].nx * q[Nt].ny * q[Nt].size;
|
|
42487
42487
|
const ct = Zt(x, C), tt = Zt(x, C);
|
|
42488
42488
|
if (tt >= 8192)
|
|
@@ -42493,15 +42493,15 @@ class mz extends mW {
|
|
|
42493
42493
|
const $ = new Uint16Array(65536), it = R(P, $), Rt = Ht(x, C);
|
|
42494
42494
|
he(V.array, x, C, Rt, J, U);
|
|
42495
42495
|
for (let Nt = 0; Nt < V.inputChannels.length; ++Nt) {
|
|
42496
|
-
const
|
|
42496
|
+
const pt = q[Nt];
|
|
42497
42497
|
for (let Jt = 0; Jt < q[Nt].size; ++Jt)
|
|
42498
42498
|
se(
|
|
42499
42499
|
J,
|
|
42500
|
-
|
|
42501
|
-
|
|
42502
|
-
|
|
42503
|
-
|
|
42504
|
-
|
|
42500
|
+
pt.start + Jt,
|
|
42501
|
+
pt.nx,
|
|
42502
|
+
pt.size,
|
|
42503
|
+
pt.ny,
|
|
42504
|
+
pt.nx * pt.size,
|
|
42505
42505
|
it
|
|
42506
42506
|
);
|
|
42507
42507
|
}
|
|
@@ -42509,8 +42509,8 @@ class mz extends mW {
|
|
|
42509
42509
|
let Lt = 0;
|
|
42510
42510
|
const Ft = new Uint8Array(J.buffer.byteLength);
|
|
42511
42511
|
for (let Nt = 0; Nt < V.lines; Nt++)
|
|
42512
|
-
for (let
|
|
42513
|
-
const Jt = q[
|
|
42512
|
+
for (let pt = 0; pt < V.inputChannels.length; pt++) {
|
|
42513
|
+
const Jt = q[pt], wt = Jt.nx * Jt.size, Ze = new Uint8Array(J.buffer, Jt.end * 2, wt * 2);
|
|
42514
42514
|
Ft.set(Ze, Lt), Lt += wt * 2, Jt.end += wt;
|
|
42515
42515
|
}
|
|
42516
42516
|
return new DataView(Ft.buffer);
|
|
@@ -42560,27 +42560,27 @@ class mz extends mW {
|
|
|
42560
42560
|
const U = new Array();
|
|
42561
42561
|
let q = Zt(x, C) - 2;
|
|
42562
42562
|
for (; q > 0; ) {
|
|
42563
|
-
const
|
|
42563
|
+
const pt = At(x.buffer, C), Jt = $t(x, C), wt = Jt >> 2 & 3, Ze = (Jt >> 4) - 1, we = new Int8Array([Ze])[0], De = $t(x, C);
|
|
42564
42564
|
U.push({
|
|
42565
|
-
name:
|
|
42565
|
+
name: pt,
|
|
42566
42566
|
index: we,
|
|
42567
42567
|
type: De,
|
|
42568
42568
|
compression: wt
|
|
42569
|
-
}), q -=
|
|
42569
|
+
}), q -= pt.length + 3;
|
|
42570
42570
|
}
|
|
42571
42571
|
const ct = T.channels, tt = new Array(V.inputChannels.length);
|
|
42572
|
-
for (let
|
|
42573
|
-
const Jt = tt[
|
|
42572
|
+
for (let pt = 0; pt < V.inputChannels.length; ++pt) {
|
|
42573
|
+
const Jt = tt[pt] = {}, wt = ct[pt];
|
|
42574
42574
|
Jt.name = wt.name, Jt.compression = 0, Jt.decoded = !1, Jt.type = wt.pixelType, Jt.pLinear = wt.pLinear, Jt.width = V.columns, Jt.height = V.lines;
|
|
42575
42575
|
}
|
|
42576
42576
|
const $ = {
|
|
42577
42577
|
idx: new Array(3)
|
|
42578
42578
|
};
|
|
42579
|
-
for (let
|
|
42580
|
-
const Jt = tt[
|
|
42579
|
+
for (let pt = 0; pt < V.inputChannels.length; ++pt) {
|
|
42580
|
+
const Jt = tt[pt];
|
|
42581
42581
|
for (let wt = 0; wt < U.length; ++wt) {
|
|
42582
42582
|
const Ze = U[wt];
|
|
42583
|
-
Jt.name == Ze.name && (Jt.compression = Ze.compression, Ze.index >= 0 && ($.idx[Ze.index] =
|
|
42583
|
+
Jt.name == Ze.name && (Jt.compression = Ze.compression, Ze.index >= 0 && ($.idx[Ze.index] = pt), Jt.offset = pt);
|
|
42584
42584
|
}
|
|
42585
42585
|
}
|
|
42586
42586
|
let it, Rt, Lt;
|
|
@@ -42590,38 +42590,38 @@ class mz extends mW {
|
|
|
42590
42590
|
it = new Uint16Array(P.totalAcUncompressedCount), he(V.array, x, C, P.acCompressedSize, it, P.totalAcUncompressedCount);
|
|
42591
42591
|
break;
|
|
42592
42592
|
case 1:
|
|
42593
|
-
const
|
|
42593
|
+
const pt = V.array.slice(C.value, C.value + P.totalAcUncompressedCount), Jt = Ir(pt);
|
|
42594
42594
|
it = new Uint16Array(Jt.buffer), C.value += P.totalAcUncompressedCount;
|
|
42595
42595
|
break;
|
|
42596
42596
|
}
|
|
42597
42597
|
if (P.dcCompressedSize > 0) {
|
|
42598
|
-
const
|
|
42598
|
+
const pt = {
|
|
42599
42599
|
array: V.array,
|
|
42600
42600
|
offset: C,
|
|
42601
42601
|
size: P.dcCompressedSize
|
|
42602
42602
|
};
|
|
42603
|
-
Rt = new Uint16Array(pt
|
|
42603
|
+
Rt = new Uint16Array(bt(pt).buffer), C.value += P.dcCompressedSize;
|
|
42604
42604
|
}
|
|
42605
42605
|
if (P.rleRawSize > 0) {
|
|
42606
|
-
const
|
|
42606
|
+
const pt = V.array.slice(C.value, C.value + P.rleCompressedSize), Jt = Ir(pt);
|
|
42607
42607
|
Lt = Ct(Jt.buffer), C.value += P.rleCompressedSize;
|
|
42608
42608
|
}
|
|
42609
42609
|
let Ft = 0;
|
|
42610
42610
|
const Nt = new Array(tt.length);
|
|
42611
|
-
for (let
|
|
42612
|
-
Nt[
|
|
42613
|
-
for (let
|
|
42611
|
+
for (let pt = 0; pt < Nt.length; ++pt)
|
|
42612
|
+
Nt[pt] = new Array();
|
|
42613
|
+
for (let pt = 0; pt < V.lines; ++pt)
|
|
42614
42614
|
for (let Jt = 0; Jt < tt.length; ++Jt)
|
|
42615
42615
|
Nt[Jt].push(Ft), Ft += tt[Jt].width * V.type * 2;
|
|
42616
|
-
|
|
42617
|
-
for (let
|
|
42618
|
-
const Jt = tt[
|
|
42616
|
+
mt($, Nt, tt, it, Rt, J);
|
|
42617
|
+
for (let pt = 0; pt < tt.length; ++pt) {
|
|
42618
|
+
const Jt = tt[pt];
|
|
42619
42619
|
if (!Jt.decoded)
|
|
42620
42620
|
switch (Jt.compression) {
|
|
42621
42621
|
case 2:
|
|
42622
42622
|
let wt = 0, Ze = 0;
|
|
42623
42623
|
for (let we = 0; we < V.lines; ++we) {
|
|
42624
|
-
let De = Nt[
|
|
42624
|
+
let De = Nt[pt][wt];
|
|
42625
42625
|
for (let Ue = 0; Ue < Jt.width; ++Ue) {
|
|
42626
42626
|
for (let _t = 0; _t < 2 * Jt.type; ++_t)
|
|
42627
42627
|
J[De++] = Lt[Ze + _t * Jt.width * Jt.height];
|
|
@@ -42828,7 +42828,7 @@ class mz extends mW {
|
|
|
42828
42828
|
}
|
|
42829
42829
|
return J;
|
|
42830
42830
|
}
|
|
42831
|
-
function
|
|
42831
|
+
function Cs(V, x, C, J) {
|
|
42832
42832
|
const P = new Array(V);
|
|
42833
42833
|
for (let U = 0; U < V; U++) {
|
|
42834
42834
|
const q = 1 << U;
|
|
@@ -42851,9 +42851,9 @@ class mz extends mW {
|
|
|
42851
42851
|
for (let Rt = 0; Rt < V.lines; Rt++) {
|
|
42852
42852
|
const Lt = Rt * V.columns * V.totalBytes;
|
|
42853
42853
|
for (let Ft = 0; Ft < V.inputChannels.length; Ft++) {
|
|
42854
|
-
const Nt = T.channels[Ft].name,
|
|
42854
|
+
const Nt = T.channels[Ft].name, pt = V.channelByteOffsets[Nt] * V.columns, Jt = V.decodeChannels[Nt];
|
|
42855
42855
|
if (Jt === void 0) continue;
|
|
42856
|
-
C.value = Lt +
|
|
42856
|
+
C.value = Lt + pt;
|
|
42857
42857
|
const wt = (V.height - (1 + ct + Rt)) * V.outLineWidth;
|
|
42858
42858
|
for (let Ze = 0; Ze < V.columns; Ze++) {
|
|
42859
42859
|
const we = wt + (Ze + q) * V.outputChannels + Jt;
|
|
@@ -42875,9 +42875,9 @@ class mz extends mW {
|
|
|
42875
42875
|
if (it >= V.height) continue;
|
|
42876
42876
|
const Rt = tt * U, Lt = (V.height - 1 - it) * V.outLineWidth;
|
|
42877
42877
|
for (let Ft = 0; Ft < V.inputChannels.length; Ft++) {
|
|
42878
|
-
const Nt = T.channels[Ft].name,
|
|
42878
|
+
const Nt = T.channels[Ft].name, pt = V.channelByteOffsets[Nt] * V.columns, Jt = V.decodeChannels[Nt];
|
|
42879
42879
|
if (Jt !== void 0) {
|
|
42880
|
-
C.value = Rt +
|
|
42880
|
+
C.value = Rt + pt;
|
|
42881
42881
|
for (let wt = 0; wt < V.columns; wt++) {
|
|
42882
42882
|
const Ze = Lt + wt * V.outputChannels + Jt;
|
|
42883
42883
|
V.byteArray[Ze] = V.getter(ct, C);
|
|
@@ -42941,10 +42941,10 @@ class mz extends mW {
|
|
|
42941
42941
|
U.blockHeight = 1, U.uncompress = dt;
|
|
42942
42942
|
break;
|
|
42943
42943
|
case "ZIPS_COMPRESSION":
|
|
42944
|
-
U.blockHeight = 1, U.uncompress =
|
|
42944
|
+
U.blockHeight = 1, U.uncompress = bt;
|
|
42945
42945
|
break;
|
|
42946
42946
|
case "ZIP_COMPRESSION":
|
|
42947
|
-
U.blockHeight = 16, U.uncompress =
|
|
42947
|
+
U.blockHeight = 16, U.uncompress = bt;
|
|
42948
42948
|
break;
|
|
42949
42949
|
case "PIZ_COMPRESSION":
|
|
42950
42950
|
U.blockHeight = 32, U.uncompress = Kt;
|
|
@@ -43015,11 +43015,11 @@ class mz extends mW {
|
|
|
43015
43015
|
U.decodeChannels[it.name] !== void 0 && (U.channelByteOffsets[it.name] = $), $ += it.pixelType * 2;
|
|
43016
43016
|
if (U.totalBytes = $, U.outLineWidth = U.width * U.outputChannels, V.lineOrder === "INCREASING_Y" ? U.scanOrder = (it) => it : U.scanOrder = (it) => U.height - 1 - it, U.outputChannels == 4 ? (U.format = R0, U.colorSpace = u0) : (U.format = vc, U.colorSpace = dn), V.spec.singleTile) {
|
|
43017
43017
|
U.blockHeight = V.tiles.ySize, U.blockWidth = V.tiles.xSize;
|
|
43018
|
-
const it = dd(V.tiles, U.width, U.height), Rt =
|
|
43018
|
+
const it = dd(V.tiles, U.width, U.height), Rt = Cs(it, U.width, V.tiles.xSize, V.tiles.roundingMode), Lt = Cs(it, U.height, V.tiles.ySize, V.tiles.roundingMode);
|
|
43019
43019
|
U.tileCount = Rt[0] * Lt[0];
|
|
43020
43020
|
for (let Ft = 0; Ft < it; Ft++)
|
|
43021
43021
|
for (let Nt = 0; Nt < Lt[Ft]; Nt++)
|
|
43022
|
-
for (let
|
|
43022
|
+
for (let pt = 0; pt < Rt[Ft]; pt++)
|
|
43023
43023
|
Ve(x, J);
|
|
43024
43024
|
U.decode = rd.bind(U);
|
|
43025
43025
|
} else {
|
|
@@ -43067,7 +43067,7 @@ var pz = Object.defineProperty, bz = Object.defineProperties, Zz = Object.getOwn
|
|
|
43067
43067
|
for (var n of fu(i))
|
|
43068
43068
|
t.indexOf(n) < 0 && Zf.call(i, n) && (e[n] = i[n]);
|
|
43069
43069
|
return e;
|
|
43070
|
-
},
|
|
43070
|
+
}, ps = (i, t, e) => new Promise((n, s) => {
|
|
43071
43071
|
var l = (c) => {
|
|
43072
43072
|
try {
|
|
43073
43073
|
o(e.next(c));
|
|
@@ -43127,7 +43127,7 @@ class $a {
|
|
|
43127
43127
|
}), l;
|
|
43128
43128
|
}
|
|
43129
43129
|
instantiate(t) {
|
|
43130
|
-
return
|
|
43130
|
+
return ps(this, arguments, function* (e, {
|
|
43131
43131
|
create: n
|
|
43132
43132
|
} = {}) {
|
|
43133
43133
|
const { objectType: s, objectOptions: l } = e, [, a] = s.split("#"), o = yield this.draw(a, Gf(Xn({}, l || {}), {
|
|
@@ -43138,7 +43138,7 @@ class $a {
|
|
|
43138
43138
|
});
|
|
43139
43139
|
}
|
|
43140
43140
|
initGroup() {
|
|
43141
|
-
return
|
|
43141
|
+
return ps(this, null, function* () {
|
|
43142
43142
|
this.group || (this.group = yield this.draw("@Group", {
|
|
43143
43143
|
target: this.pencil.scene
|
|
43144
43144
|
})), this.prefabGroup || (this.prefabGroup = yield this.draw("@Group", {
|
|
@@ -43148,7 +43148,7 @@ class $a {
|
|
|
43148
43148
|
});
|
|
43149
43149
|
}
|
|
43150
43150
|
draw(t, e, n) {
|
|
43151
|
-
return
|
|
43151
|
+
return ps(this, null, function* () {
|
|
43152
43152
|
var s, l, a, o;
|
|
43153
43153
|
const c = this.objectNamesToFactories.get(t);
|
|
43154
43154
|
if (c) {
|
|
@@ -43167,7 +43167,7 @@ class $a {
|
|
|
43167
43167
|
});
|
|
43168
43168
|
}
|
|
43169
43169
|
addBaseObject(t, e, n) {
|
|
43170
|
-
return
|
|
43170
|
+
return ps(this, null, function* () {
|
|
43171
43171
|
yield t.create();
|
|
43172
43172
|
const s = t.objectType === "BaseObject#Node";
|
|
43173
43173
|
t.object3d && (n && t.setTop(n), e !== null ? (e.add(t.object3d), this.objMap.set(t.object3d, t)) : this.targetNullMap.set(t.object3d, t)), s && (t.drawGroupShow = this.nodeGroupVisible), t.render(), t.pm.resolve();
|
|
@@ -43314,7 +43314,7 @@ class Vz {
|
|
|
43314
43314
|
this.pool = e;
|
|
43315
43315
|
}
|
|
43316
43316
|
geoGeometry(t, e) {
|
|
43317
|
-
return
|
|
43317
|
+
return ps(this, null, function* () {
|
|
43318
43318
|
const { mesaage: n, cacheKey: s, userData: l, cacheVersion: a, cb: o, center: c } = Xn(Xn({}, this.options), e), d = this.pool, r = {
|
|
43319
43319
|
x: 0,
|
|
43320
43320
|
y: 0,
|
|
@@ -43346,7 +43346,7 @@ class Vz {
|
|
|
43346
43346
|
});
|
|
43347
43347
|
}
|
|
43348
43348
|
getCachedGeometry(t) {
|
|
43349
|
-
return
|
|
43349
|
+
return ps(this, null, function* () {
|
|
43350
43350
|
const { cacheKey: e, cacheVersion: n } = t;
|
|
43351
43351
|
if (e) {
|
|
43352
43352
|
const s = yield YN(e, this.store), l = n || this.options.cacheVersion;
|
|
@@ -43479,7 +43479,7 @@ class fz {
|
|
|
43479
43479
|
}), t;
|
|
43480
43480
|
}
|
|
43481
43481
|
loadAll() {
|
|
43482
|
-
return
|
|
43482
|
+
return ps(this, null, function* () {
|
|
43483
43483
|
const t = this.loadObj.filter((e) => !(this.delLoadArr.includes(e.src) || this.assets.has(e.src)));
|
|
43484
43484
|
return yield Promise.all(
|
|
43485
43485
|
t.map((e) => this.load(e.src, e))
|
|
@@ -43487,7 +43487,7 @@ class fz {
|
|
|
43487
43487
|
});
|
|
43488
43488
|
}
|
|
43489
43489
|
load(t, e) {
|
|
43490
|
-
return
|
|
43490
|
+
return ps(this, null, function* () {
|
|
43491
43491
|
var n;
|
|
43492
43492
|
const s = this.getAssetType(t);
|
|
43493
43493
|
if (!s)
|
|
@@ -43586,7 +43586,7 @@ function la(i) {
|
|
|
43586
43586
|
const t = new Dt();
|
|
43587
43587
|
return t.color.setScalar(i), t;
|
|
43588
43588
|
}
|
|
43589
|
-
const yf = "0.18.
|
|
43589
|
+
const yf = "0.18.16";
|
|
43590
43590
|
class xz {
|
|
43591
43591
|
constructor() {
|
|
43592
43592
|
A(this, "event", new TX());
|
|
@@ -43734,7 +43734,7 @@ const Yz = {
|
|
|
43734
43734
|
}, xX = {
|
|
43735
43735
|
NearestFilter: ze,
|
|
43736
43736
|
NearestMipmapNearestFilter: Nc,
|
|
43737
|
-
NearestMipmapLinearFilter:
|
|
43737
|
+
NearestMipmapLinearFilter: hs,
|
|
43738
43738
|
LinearFilter: Ne,
|
|
43739
43739
|
LinearMipmapNearestFilter: ol,
|
|
43740
43740
|
LinearMipmapLinearFilter: rn
|
|
@@ -44024,7 +44024,7 @@ class ff extends J0 {
|
|
|
44024
44024
|
this.type = "AddVis", this.visType = n, this.visOptions = s, n !== void 0 && (this.name = `Add Vis: ${n}`);
|
|
44025
44025
|
}
|
|
44026
44026
|
execute() {
|
|
44027
|
-
return
|
|
44027
|
+
return ht(this, null, function* () {
|
|
44028
44028
|
yield this.editor.viewport.setVis(this.visType, this.visOptions), this.editor.select(null);
|
|
44029
44029
|
});
|
|
44030
44030
|
}
|
|
@@ -44049,7 +44049,7 @@ class Rf extends J0 {
|
|
|
44049
44049
|
this.type = "AddObject", this.objectType = n, this.objectOptions = s, n !== void 0 && (this.name = `Add Object: ${n}`);
|
|
44050
44050
|
}
|
|
44051
44051
|
execute() {
|
|
44052
|
-
return
|
|
44052
|
+
return ht(this, null, function* () {
|
|
44053
44053
|
var s, l, a;
|
|
44054
44054
|
if (this.obj = yield this.editor.viewport.vis.drawController.draw(
|
|
44055
44055
|
this.objectType,
|
|
@@ -44107,7 +44107,7 @@ class xf extends J0 {
|
|
|
44107
44107
|
this.object.hide(), (e = this.editor.viewport.vis) == null || e.mList.removeObject3d(this.object.object3d), this.editor.select(null);
|
|
44108
44108
|
}
|
|
44109
44109
|
undo() {
|
|
44110
|
-
return
|
|
44110
|
+
return ht(this, null, function* () {
|
|
44111
44111
|
var e;
|
|
44112
44112
|
this.object.show(), (e = this.editor.viewport.vis) == null || e.mList.resetObject3d(this.object.object3d);
|
|
44113
44113
|
});
|
|
@@ -44128,7 +44128,7 @@ class Sf extends J0 {
|
|
|
44128
44128
|
this.type = "CopyObject", this.name = "Copy Object", this.object = n;
|
|
44129
44129
|
}
|
|
44130
44130
|
execute() {
|
|
44131
|
-
return
|
|
44131
|
+
return ht(this, null, function* () {
|
|
44132
44132
|
var a, o;
|
|
44133
44133
|
const e = this.editor.viewport.vis.mList, n = e.getObject3dName(this.object.object3d), s = yield this.object.instantiate();
|
|
44134
44134
|
this.copyObject = s, e.objectList.has(s.object3d) ? (a = this.editor.viewport.vis) == null || a.mList.changeObject3dName(
|
|
@@ -44150,7 +44150,7 @@ class Sf extends J0 {
|
|
|
44150
44150
|
});
|
|
44151
44151
|
}
|
|
44152
44152
|
undo() {
|
|
44153
|
-
return
|
|
44153
|
+
return ht(this, null, function* () {
|
|
44154
44154
|
var e, n;
|
|
44155
44155
|
(e = this.editor.viewport.vis) == null || e.mList.removeObject3d(this.copyObject.object3d), (n = this.copyObject) == null || n.erase(), this.editor.select(null);
|
|
44156
44156
|
});
|
|
@@ -44172,7 +44172,7 @@ class Hz extends J0 {
|
|
|
44172
44172
|
this.type = "SetSetting", this.updatable = !0, this.name = `Set Setting.${n}`, this.attributeName = n, this.newValue = s, e.viewport.vis && (this.oldValue = e.viewport.vis.settings[n]);
|
|
44173
44173
|
}
|
|
44174
44174
|
execute() {
|
|
44175
|
-
return
|
|
44175
|
+
return ht(this, null, function* () {
|
|
44176
44176
|
if (this.newValue === this.oldValue)
|
|
44177
44177
|
return;
|
|
44178
44178
|
const e = this.editor.viewport.vis;
|
|
@@ -44180,7 +44180,7 @@ class Hz extends J0 {
|
|
|
44180
44180
|
});
|
|
44181
44181
|
}
|
|
44182
44182
|
undo() {
|
|
44183
|
-
return
|
|
44183
|
+
return ht(this, null, function* () {
|
|
44184
44184
|
const e = this.editor.viewport.vis;
|
|
44185
44185
|
e.settings[this.attributeName] = this.oldValue, yield e.settings[this.attributeName], this.editor.emit("settingsChanged");
|
|
44186
44186
|
});
|
|
@@ -44268,7 +44268,7 @@ class Kz {
|
|
|
44268
44268
|
this.editor = t, this.undos = [], this.redos = [], this.lastCmdTime = Date.now(), this.idCounter = 0, this.historyDisabled = !1;
|
|
44269
44269
|
}
|
|
44270
44270
|
execute(t, e) {
|
|
44271
|
-
return
|
|
44271
|
+
return ht(this, null, function* () {
|
|
44272
44272
|
const n = this.undos[this.undos.length - 1], s = Date.now() - this.lastCmdTime;
|
|
44273
44273
|
n && n.updatable && t.updatable && n.object === t.object && n.type === t.type && n.attributeName === t.attributeName && n.name === t.name && n.objectUuid === t.objectUuid && n.materialSlot === t.materialSlot && s < 500 ? (n.update(t), t = n) : (this.undos.push(t), t.id = ++this.idCounter), t.name = e !== void 0 ? e : t.name, yield t.execute(), this.editor.playing || (t.json = t.toJSON()), this.lastCmdTime = Date.now(), this.redos = [], this.editor.emit("historyChanged", t);
|
|
44274
44274
|
});
|
|
@@ -44314,7 +44314,7 @@ class Kz {
|
|
|
44314
44314
|
}
|
|
44315
44315
|
}
|
|
44316
44316
|
executeUndos() {
|
|
44317
|
-
return
|
|
44317
|
+
return ht(this, null, function* () {
|
|
44318
44318
|
let t = 0;
|
|
44319
44319
|
for (const e of this.undos) {
|
|
44320
44320
|
e.fromJSON(e.json);
|
|
@@ -44350,7 +44350,7 @@ class kz {
|
|
|
44350
44350
|
this.options = e, this.editor = t;
|
|
44351
44351
|
}
|
|
44352
44352
|
setSaveCamera() {
|
|
44353
|
-
return
|
|
44353
|
+
return ht(this, null, function* () {
|
|
44354
44354
|
var s;
|
|
44355
44355
|
const t = this.vis.pencil, e = t.cameraPositon, n = t.cameraTarget;
|
|
44356
44356
|
yield this.editor.execute(
|
|
@@ -44367,7 +44367,7 @@ class kz {
|
|
|
44367
44367
|
});
|
|
44368
44368
|
}
|
|
44369
44369
|
addVis(n) {
|
|
44370
|
-
return
|
|
44370
|
+
return ht(this, arguments, function* (t, e = {}) {
|
|
44371
44371
|
this.replaceVis() && (yield this.editor.execute(new ff(this.editor, t, e)));
|
|
44372
44372
|
});
|
|
44373
44373
|
}
|
|
@@ -44379,7 +44379,7 @@ class kz {
|
|
|
44379
44379
|
return !0;
|
|
44380
44380
|
}
|
|
44381
44381
|
setVis(n) {
|
|
44382
|
-
return
|
|
44382
|
+
return ht(this, arguments, function* (t, e = {}) {
|
|
44383
44383
|
var a, o;
|
|
44384
44384
|
if (!this.options.visFactories && (this.editor.setViewportVis(t), !this.options.visFactories)) {
|
|
44385
44385
|
console.error("visFactories is not defined");
|
|
@@ -44394,6 +44394,8 @@ class kz {
|
|
|
44394
44394
|
type: "下载资源",
|
|
44395
44395
|
value: c / d * 100 | 0
|
|
44396
44396
|
}), c === d && (s = 0));
|
|
44397
|
+
}), this.vis.on("settingsChanged", () => {
|
|
44398
|
+
this.editor.emit("settingsChanged");
|
|
44397
44399
|
}), this.vis.on("show", () => {
|
|
44398
44400
|
this.editor.emit("visShow");
|
|
44399
44401
|
}), yield this.vis.init();
|
|
@@ -44425,13 +44427,13 @@ class kz {
|
|
|
44425
44427
|
});
|
|
44426
44428
|
}
|
|
44427
44429
|
addObj(n) {
|
|
44428
|
-
return
|
|
44430
|
+
return ht(this, arguments, function* (t, e = {}) {
|
|
44429
44431
|
const s = Ll[t].getInitOptions;
|
|
44430
44432
|
s && Object.assign(e, s(this.vis.pencil, e)), yield this.editor.execute(new Rf(this.editor, t, e));
|
|
44431
44433
|
});
|
|
44432
44434
|
}
|
|
44433
44435
|
removeObj(t) {
|
|
44434
|
-
return
|
|
44436
|
+
return ht(this, null, function* () {
|
|
44435
44437
|
const { vis: e } = this;
|
|
44436
44438
|
if (!e)
|
|
44437
44439
|
return;
|
|
@@ -44440,7 +44442,7 @@ class kz {
|
|
|
44440
44442
|
});
|
|
44441
44443
|
}
|
|
44442
44444
|
copyObj(t) {
|
|
44443
|
-
return
|
|
44445
|
+
return ht(this, null, function* () {
|
|
44444
44446
|
const { vis: e } = this;
|
|
44445
44447
|
if (!e)
|
|
44446
44448
|
return;
|
|
@@ -44478,7 +44480,7 @@ class kz {
|
|
|
44478
44480
|
(t = this.vis) == null || t.dispose(), this.options.visFactories = void 0, this.extendsOptions = {}, this.delLoadObj = void 0, this.vis = void 0, this.editor.history.clear();
|
|
44479
44481
|
}
|
|
44480
44482
|
}
|
|
44481
|
-
const
|
|
44483
|
+
const os = (i, t) => {
|
|
44482
44484
|
if (!i && !t) return 0;
|
|
44483
44485
|
if (!i && t) return -1;
|
|
44484
44486
|
if (i && !t) return 1;
|
|
@@ -44509,7 +44511,7 @@ const _s = (i, t) => {
|
|
|
44509
44511
|
name: i.name,
|
|
44510
44512
|
version: i.v
|
|
44511
44513
|
}
|
|
44512
|
-
}), (t = i.c) != null && t.key && delete i.c.key,
|
|
44514
|
+
}), (t = i.c) != null && t.key && delete i.c.key, os(i.c.version, "0.5.38") === -1 && ((e = i.v) != null && e.eo && Object.keys(i.v.eo).forEach((n) => {
|
|
44513
44515
|
[
|
|
44514
44516
|
"mouseLeft",
|
|
44515
44517
|
"mouseRight",
|
|
@@ -44522,7 +44524,7 @@ const _s = (i, t) => {
|
|
|
44522
44524
|
].includes(n) && (i.v.eo[n] = !!i.v.eo[n]);
|
|
44523
44525
|
}), i.h.u.forEach((n) => {
|
|
44524
44526
|
n.type === "SetSetting" && (n.attributeName === "阴影" && (n.attributeName = "shadowMap"), n.newValue = !!n.newValue, n.oldValue = !!n.oldValue);
|
|
44525
|
-
})),
|
|
44527
|
+
})), os(i.c.version, "0.7.14") === -1 && i.h.u.forEach((n) => {
|
|
44526
44528
|
n.objectUuid && (n.objectUuid = n.objectUuid.replace(
|
|
44527
44529
|
n.objectUuid[0],
|
|
44528
44530
|
n.objectUuid[0].toLowerCase()
|
|
@@ -44553,9 +44555,9 @@ const _s = (i, t) => {
|
|
|
44553
44555
|
parentBg: n
|
|
44554
44556
|
}), delete i.h.u[0].visOptions.worldBg;
|
|
44555
44557
|
}
|
|
44556
|
-
|
|
44558
|
+
os(i.c.version, "0.13.0") === -1 && i.h.u[0].visOptions.adcode === 0 && (i.h.u[0].visType = "world");
|
|
44557
44559
|
}
|
|
44558
|
-
if (
|
|
44560
|
+
if (os(i.c.version, "0.13.0") === -1 && i.h.u[0] && i.h.u[0].visType === "world" && (i.h.u[0].visType = "map", i.h.u[0].visOptions = {
|
|
44559
44561
|
adcode: 0,
|
|
44560
44562
|
mapDepth: 5,
|
|
44561
44563
|
lineWidth: 2,
|
|
@@ -44565,11 +44567,16 @@ const _s = (i, t) => {
|
|
|
44565
44567
|
const { adcode: n } = i.h.u[0].visOptions;
|
|
44566
44568
|
n === 35e4 && (i.h.u[0].visOptions.drillDownHideParent = !0);
|
|
44567
44569
|
}
|
|
44568
|
-
return
|
|
44570
|
+
return os(i.c.version, "0.18.1") === -1 && i.h.u[0] && i.h.u[0].visType === "earth3" && (i.h.u[0].visType = "earth", i.h.u[0].visOptions.style = "countryPlate"), os(i.c.version, "0.18.14") === -1 && i.h.u[0] && i.h.u[0].visType === "map" && i.h.u.forEach((n) => {
|
|
44569
44571
|
if (n.type === "SetSetting" && n.attributeName.startsWith("测试") && typeof n.newValue == "string" && n.newValue.includes(":::")) {
|
|
44570
44572
|
const s = n.newValue.split(":::")[1];
|
|
44571
44573
|
n.attributeName += ":::" + s, n.newValue = n.newValue.split(":::")[0], n.oldValue && typeof n.oldValue == "string" && (n.oldValue = n.oldValue.split(":::")[0]);
|
|
44572
44574
|
}
|
|
44575
|
+
}), os(i.c.version, "0.18.16") === -1 && i.h.u[0] && i.h.u[0].visType === "map" && i.h.u.forEach((n) => {
|
|
44576
|
+
if (n.type === "SetSetting" && n.attributeName.startsWith("测试") && n.attributeName.includes(":::") && !n.attributeName.includes("caId")) {
|
|
44577
|
+
const s = n.attributeName.split(":::")[1];
|
|
44578
|
+
n.attributeName = n.attributeName.replace(s, `caId.${s}`);
|
|
44579
|
+
}
|
|
44573
44580
|
}), i;
|
|
44574
44581
|
}, g2 = (i, t) => {
|
|
44575
44582
|
const e = x2(!0);
|
|
@@ -44701,12 +44708,12 @@ class Uz {
|
|
|
44701
44708
|
this.checkSelectOption(o), this.selectOption = o, this.emit("sceneGraphChanged");
|
|
44702
44709
|
}
|
|
44703
44710
|
execute(t, e) {
|
|
44704
|
-
return
|
|
44711
|
+
return ht(this, null, function* () {
|
|
44705
44712
|
yield this.history.execute(t, e);
|
|
44706
44713
|
});
|
|
44707
44714
|
}
|
|
44708
44715
|
fromJSON(t, e) {
|
|
44709
|
-
return
|
|
44716
|
+
return ht(this, null, function* () {
|
|
44710
44717
|
var n, s, l;
|
|
44711
44718
|
if (!this.storage) {
|
|
44712
44719
|
const a = JX.getInfo();
|
|
@@ -44720,7 +44727,7 @@ class Uz {
|
|
|
44720
44727
|
a = c;
|
|
44721
44728
|
} else
|
|
44722
44729
|
a = t;
|
|
44723
|
-
if (a = zz(a),
|
|
44730
|
+
if (a = zz(a), os(a.c.version, this.sdkVersion) === 1 && console.warn(
|
|
44724
44731
|
"vis-core 版本过低,可能会出现问题",
|
|
44725
44732
|
"json:" + a.c.version,
|
|
44726
44733
|
"sdk:" + this.sdkVersion
|
|
@@ -44837,20 +44844,20 @@ class ad extends xz {
|
|
|
44837
44844
|
loaderAdd(...e) {
|
|
44838
44845
|
}
|
|
44839
44846
|
initMaterial(...e) {
|
|
44840
|
-
return
|
|
44847
|
+
return ht(this, null, function* () {
|
|
44841
44848
|
});
|
|
44842
44849
|
}
|
|
44843
44850
|
initVis(...e) {
|
|
44844
|
-
return
|
|
44851
|
+
return ht(this, null, function* () {
|
|
44845
44852
|
});
|
|
44846
44853
|
}
|
|
44847
44854
|
init(...e) {
|
|
44848
|
-
return
|
|
44855
|
+
return ht(this, null, function* () {
|
|
44849
44856
|
yield this.initPencil(), this.loaderAdd(), yield this.loader.loadAll(), yield this.initMaterial(), yield this.initVis(), yield Promise.all(this.drawController.objectsPromise);
|
|
44850
44857
|
});
|
|
44851
44858
|
}
|
|
44852
44859
|
initPencil() {
|
|
44853
|
-
return
|
|
44860
|
+
return ht(this, null, function* () {
|
|
44854
44861
|
if (this.pencil) return;
|
|
44855
44862
|
this.devicePixelRatio = this.getDevicePixelRatio(), this.options.css2DContainer && (this.pencilConfig.css2DRendererParams = {
|
|
44856
44863
|
container: this.options.css2DContainer
|
|
@@ -44957,22 +44964,26 @@ class ad extends xz {
|
|
|
44957
44964
|
}),
|
|
44958
44965
|
{
|
|
44959
44966
|
set: (e, n, s) => {
|
|
44960
|
-
const { pencil: l } = this
|
|
44961
|
-
|
|
44967
|
+
const { pencil: l } = this;
|
|
44968
|
+
if (!(n in e) && !(n.replace(/(:::.+)\..*$/, "$1") in e))
|
|
44969
|
+
return Reflect.set({}, n, s);
|
|
44970
|
+
n === "mouseWheel" ? typeof s == "boolean" && (s = s ? l.cameraControls.mouseButtons.wheel : ln.NONE) : n === "mouseLeft" ? typeof s == "boolean" && (s = s ? l.cameraControls.mouseButtons.left : ln.NONE) : n === "mouseRight" && typeof s == "boolean" && (s = s ? l.cameraControls.mouseButtons.right : ln.NONE);
|
|
44971
|
+
const a = n.includes(":::");
|
|
44972
|
+
return Reflect.set(
|
|
44962
44973
|
e,
|
|
44963
|
-
a ? n.
|
|
44974
|
+
a ? n.replace(/(:::.+)\..*$/, "$1") : n,
|
|
44964
44975
|
this.handleSetting(n, s)
|
|
44965
|
-
)
|
|
44976
|
+
);
|
|
44966
44977
|
},
|
|
44967
44978
|
get: (e, n) => {
|
|
44968
|
-
const l = n.includes(":::") ? n.
|
|
44979
|
+
const l = n.includes(":::") ? n.replace(/(:::.+)\..*$/, "$1") : n, a = Reflect.get(e, l);
|
|
44969
44980
|
return a instanceof Promise ? a.then((o) => (Reflect.set(e, l, o), o)) : a;
|
|
44970
44981
|
}
|
|
44971
44982
|
}
|
|
44972
44983
|
);
|
|
44973
44984
|
}
|
|
44974
44985
|
handleSetting(e, n) {
|
|
44975
|
-
return
|
|
44986
|
+
return ht(this, null, function* () {
|
|
44976
44987
|
const { pencil: s } = this;
|
|
44977
44988
|
if (e === "mouseWheel" || e === "mouseLeft" || e === "mouseRight") {
|
|
44978
44989
|
if (yield this.settings.mouseNone, !this.settings.mouseNone) {
|
|
@@ -45001,7 +45012,7 @@ class ad extends xz {
|
|
|
45001
45012
|
this.showState && (this.playing ? this.drawController.hide() : (this.drawController.hidePrefab(), this.drawController.hide()), this.showState = !1, this.emit("hide"));
|
|
45002
45013
|
}
|
|
45003
45014
|
addCSS2D(s) {
|
|
45004
|
-
return
|
|
45015
|
+
return ht(this, arguments, function* (e, n = {}) {
|
|
45005
45016
|
typeof n == "string" && (n = { display: n }), n.display && (e.style.display = n.display);
|
|
45006
45017
|
let l = 0;
|
|
45007
45018
|
typeof n.onTop != "undefined" && (l = n.onTop);
|
|
@@ -45012,7 +45023,7 @@ class ad extends xz {
|
|
|
45012
45023
|
});
|
|
45013
45024
|
}
|
|
45014
45025
|
addCSS3D(s) {
|
|
45015
|
-
return
|
|
45026
|
+
return ht(this, arguments, function* (e, n = {}) {
|
|
45016
45027
|
n.display && (e.style.display = n.display);
|
|
45017
45028
|
let l = 0;
|
|
45018
45029
|
typeof n.onTop != "undefined" && (l = n.onTop);
|
|
@@ -45186,7 +45197,7 @@ class Yf extends Ge {
|
|
|
45186
45197
|
}
|
|
45187
45198
|
}
|
|
45188
45199
|
create() {
|
|
45189
|
-
return
|
|
45200
|
+
return ht(this, null, function* () {
|
|
45190
45201
|
const {
|
|
45191
45202
|
geojson: e,
|
|
45192
45203
|
extrudeLineGeojson: n,
|
|
@@ -45200,7 +45211,7 @@ class Yf extends Ge {
|
|
|
45200
45211
|
const d = this.pencil.getPlugin("draw");
|
|
45201
45212
|
if (a) {
|
|
45202
45213
|
const g = yield Promise.all(
|
|
45203
|
-
e.features.map((f) =>
|
|
45214
|
+
e.features.map((f) => ht(this, null, function* () {
|
|
45204
45215
|
const { properties: L } = f, I = `area-group-${this.getPropertiesKey(L)}`, S = yield d.draw("Group", {
|
|
45205
45216
|
target: this,
|
|
45206
45217
|
key: I
|
|
@@ -45290,12 +45301,12 @@ class Yf extends Ge {
|
|
|
45290
45301
|
return l.lineWidth = n, e.useMaterial(s), l;
|
|
45291
45302
|
}
|
|
45292
45303
|
addArea(e, n) {
|
|
45293
|
-
return
|
|
45304
|
+
return ht(this, null, function* () {
|
|
45294
45305
|
var h;
|
|
45295
45306
|
const { bbox: s, material: l, onTop: a, bboxOffset: o } = n, c = this.geojson2Meta(e), d = this.pencil.getPlugin("worker"), r = this.pencil.getPlugin("draw");
|
|
45296
45307
|
if (n.areaGroup)
|
|
45297
45308
|
return yield Promise.all(
|
|
45298
|
-
c.map((u) =>
|
|
45309
|
+
c.map((u) => ht(this, null, function* () {
|
|
45299
45310
|
var X;
|
|
45300
45311
|
const { coords: m, properties: b } = u, G = this.findGroup(this.getPropertiesKey(b)), Z = yield d.geoGeometry(
|
|
45301
45312
|
this.options.curvatureResolution ? "conicPolygon" : "extrudePolygon",
|
|
@@ -45353,7 +45364,7 @@ class Yf extends Ge {
|
|
|
45353
45364
|
return e.adcode || e.DistrictID || e.NAME_CN;
|
|
45354
45365
|
}
|
|
45355
45366
|
addPlane(e, n) {
|
|
45356
|
-
return
|
|
45367
|
+
return ht(this, null, function* () {
|
|
45357
45368
|
var G, Z, p;
|
|
45358
45369
|
const { material: s } = n, l = this.geojson2Meta({
|
|
45359
45370
|
type: "FeatureCollection",
|
|
@@ -45410,12 +45421,12 @@ class Yf extends Ge {
|
|
|
45410
45421
|
});
|
|
45411
45422
|
}
|
|
45412
45423
|
addLine(e, n) {
|
|
45413
|
-
return
|
|
45424
|
+
return ht(this, null, function* () {
|
|
45414
45425
|
var d;
|
|
45415
45426
|
const { material: s, onTop: l } = n, a = this.geojson2Meta(e), o = this.pencil.getPlugin("worker"), c = this.pencil.getPlugin("draw");
|
|
45416
45427
|
if (n.areaGroup)
|
|
45417
45428
|
return yield Promise.all(
|
|
45418
|
-
a.map((r) =>
|
|
45429
|
+
a.map((r) => ht(this, null, function* () {
|
|
45419
45430
|
var Z;
|
|
45420
45431
|
const { coords: h, properties: u } = r, m = this.findGroup(this.getPropertiesKey(u)), b = yield o.geoGeometry("line", {
|
|
45421
45432
|
mesaage: {
|
|
@@ -45598,10 +45609,10 @@ class If extends Ge {
|
|
|
45598
45609
|
this.options = e;
|
|
45599
45610
|
}
|
|
45600
45611
|
create() {
|
|
45601
|
-
return
|
|
45612
|
+
return ht(this, null, function* () {
|
|
45602
45613
|
const { depth: e } = this.options, n = this.pencil.installPlugins.get("materialList"), s = this.pencil.getPlugin("draw"), l = n.getMaterialObj("continents");
|
|
45603
45614
|
this.createGroup(), yield Promise.all(
|
|
45604
|
-
Rb.features.map((a) =>
|
|
45615
|
+
Rb.features.map((a) => ht(this, null, function* () {
|
|
45605
45616
|
const o = a.properties.name;
|
|
45606
45617
|
o === "大洋洲" && (a.geometry.coordinates[4] = [], a.geometry.coordinates[21] = []);
|
|
45607
45618
|
const c = qf(a).geometry.coordinates;
|
|
@@ -45678,7 +45689,7 @@ const Ez = Be(Tt({}, Ll), {
|
|
|
45678
45689
|
const t = this.loader;
|
|
45679
45690
|
t.add(["/image/map/jianbian.webp"]), t.add(["/image/map/hp2.webp", "/image/map/fx2.webp"]);
|
|
45680
45691
|
}, i.initMaterial = function() {
|
|
45681
|
-
return
|
|
45692
|
+
return ht(this, null, function* () {
|
|
45682
45693
|
const t = this.loader, e = this.mList, n = (() => {
|
|
45683
45694
|
const s = new n0({
|
|
45684
45695
|
// color: '#0d2425',
|
|
@@ -45714,9 +45725,9 @@ const Ez = Be(Tt({}, Ll), {
|
|
|
45714
45725
|
};
|
|
45715
45726
|
}, jz = (i) => {
|
|
45716
45727
|
if (i.initSettingsObj = Tt({
|
|
45717
|
-
"测试板块颜色.color:::
|
|
45718
|
-
"测试边框颜色.color:::
|
|
45719
|
-
"测试边框宽度:::
|
|
45728
|
+
"测试板块颜色.color:::caId": "ffffff",
|
|
45729
|
+
"测试边框颜色.color:::caId": "ffffff",
|
|
45730
|
+
"测试边框宽度:::caId": 0
|
|
45720
45731
|
}, i.initSettingsObj), i.options.extrudeLine) {
|
|
45721
45732
|
const t = {
|
|
45722
45733
|
type: "FeatureCollection",
|
|
@@ -45731,7 +45742,7 @@ const Ez = Be(Tt({}, Ll), {
|
|
|
45731
45742
|
return;
|
|
45732
45743
|
}
|
|
45733
45744
|
i.initMaterial = function() {
|
|
45734
|
-
return
|
|
45745
|
+
return ht(this, null, function* () {
|
|
45735
45746
|
const t = this.mList, e = (() => {
|
|
45736
45747
|
const n = new Dt({
|
|
45737
45748
|
name: "顶面",
|
|
@@ -45763,8 +45774,12 @@ const Ez = Be(Tt({}, Ll), {
|
|
|
45763
45774
|
});
|
|
45764
45775
|
};
|
|
45765
45776
|
}, Az = (i) => {
|
|
45766
|
-
i.
|
|
45767
|
-
|
|
45777
|
+
i.initSettingsObj = Tt({
|
|
45778
|
+
"测试板块颜色.color:::caId": "ffffff",
|
|
45779
|
+
"测试边框颜色.color:::caId": "ffffff",
|
|
45780
|
+
"测试边框宽度:::caId": 0
|
|
45781
|
+
}, i.initSettingsObj), i.options.continentsBg && (i.options.center = [104, 37.5]), i.options.lineOffset = 5e-3, i.loaderAdd = function() {
|
|
45782
|
+
return ht(this, null, function* () {
|
|
45768
45783
|
this.loader.add([
|
|
45769
45784
|
"/image/map/jianbian.webp",
|
|
45770
45785
|
"/image/map/hp.webp",
|
|
@@ -45772,7 +45787,7 @@ const Ez = Be(Tt({}, Ll), {
|
|
|
45772
45787
|
]), this.loaderAddBg();
|
|
45773
45788
|
});
|
|
45774
45789
|
}, i.initMaterial = function() {
|
|
45775
|
-
return
|
|
45790
|
+
return ht(this, null, function* () {
|
|
45776
45791
|
const t = this.loader, e = (() => {
|
|
45777
45792
|
const n = new n0({
|
|
45778
45793
|
name: "顶面",
|
|
@@ -45784,11 +45799,15 @@ const Ez = Be(Tt({}, Ll), {
|
|
|
45784
45799
|
}), l = new We({
|
|
45785
45800
|
color: new lt("#73FEDD"),
|
|
45786
45801
|
sizeAttenuation: 0,
|
|
45787
|
-
lineWidth: this.options.lineWidth
|
|
45802
|
+
lineWidth: this.options.lineWidth,
|
|
45803
|
+
//@ts-ignore
|
|
45804
|
+
depthWrite: !1
|
|
45788
45805
|
}), a = new We({
|
|
45789
45806
|
color: new lt("#00FFED"),
|
|
45790
45807
|
sizeAttenuation: 0,
|
|
45791
|
-
lineWidth: this.options.extrudeLineWidth
|
|
45808
|
+
lineWidth: this.options.extrudeLineWidth,
|
|
45809
|
+
//@ts-ignore
|
|
45810
|
+
depthWrite: !1
|
|
45792
45811
|
});
|
|
45793
45812
|
return {
|
|
45794
45813
|
topMat: n,
|
|
@@ -45802,11 +45821,11 @@ const Ez = Be(Tt({}, Ll), {
|
|
|
45802
45821
|
};
|
|
45803
45822
|
}, Dz = (i) => {
|
|
45804
45823
|
i.loaderAdd = function() {
|
|
45805
|
-
return
|
|
45824
|
+
return ht(this, null, function* () {
|
|
45806
45825
|
this.loader.add(["/image/map/jianbian.webp"]), this.loaderAddBg();
|
|
45807
45826
|
});
|
|
45808
45827
|
}, i.initMaterial = function() {
|
|
45809
|
-
return
|
|
45828
|
+
return ht(this, null, function* () {
|
|
45810
45829
|
const t = this.loader, e = (() => {
|
|
45811
45830
|
const n = new Dt({
|
|
45812
45831
|
name: "顶面",
|
|
@@ -45881,6 +45900,7 @@ const Ez = Be(Tt({}, Ll), {
|
|
|
45881
45900
|
labelLite: !1,
|
|
45882
45901
|
shadowMap: !1
|
|
45883
45902
|
});
|
|
45903
|
+
A(this, "caId");
|
|
45884
45904
|
A(this, "shadowMapLight");
|
|
45885
45905
|
}
|
|
45886
45906
|
get mapObj() {
|
|
@@ -45958,28 +45978,37 @@ const Ez = Be(Tt({}, Ll), {
|
|
|
45958
45978
|
})), this.pencilConfig = Pz, (this.getAdcodeShowLevel(this.options.adcode) === "province" || this.getAdcodeShowLevel(this.options.adcode) === "country") && (this.extendsOptions.parentBg = () => this.options.parentBg, this.extendsOptions.parentBgDepth = () => this.options.parentBgDepth, this.extendsOptions.continentsBg = () => this.options.continentsBg, this.extendsOptions.continentsBgDepth = () => this.options.continentsBgDepth), this.options.adcode === 0 ? jz(this) : this.options.style === "map2" || (this.options.adcode === 1e5 ? Az(this) : Dz(this));
|
|
45959
45979
|
}
|
|
45960
45980
|
handleSetting(e, n) {
|
|
45961
|
-
return
|
|
45962
|
-
if (yield
|
|
45981
|
+
return ht(this, null, function* () {
|
|
45982
|
+
if (yield Is(ba.prototype, this, "handleSetting").call(this, e, n), e === "label")
|
|
45963
45983
|
n === !1 ? (this.eraseLabels(), this.options.showLabel = !1) : (this.settings.labelLite = !1, yield this.settings.labelLite, this.options.showLabel = !0, yield this.drawLabels());
|
|
45964
45984
|
else if (e === "labelLite")
|
|
45965
45985
|
n === !1 ? (this.eraseLabels(), this.options.showLabel = !1) : (this.settings.label = !1, yield this.settings.label, this.options.showLabel = "lite", yield this.drawLabels());
|
|
45966
45986
|
else if (e === "shadowMap")
|
|
45967
45987
|
n === !1 ? this.shadowMapDisabled() : yield this.shadowMapEnabled();
|
|
45968
45988
|
else if (e.startsWith("测试板块颜色.color")) {
|
|
45969
|
-
const [, s] = e.split("
|
|
45970
|
-
|
|
45989
|
+
const [, s] = e.split("caId.");
|
|
45990
|
+
if (s) {
|
|
45991
|
+
const l = this.options.adcode === 0, a = l ? "ISO_A2" : "adcode";
|
|
45992
|
+
this.setAreaColorByProperty(a, l ? s : +s, n);
|
|
45993
|
+
}
|
|
45971
45994
|
} else if (e.startsWith("测试边框颜色.color")) {
|
|
45972
|
-
const [, s] = e.split("
|
|
45973
|
-
|
|
45995
|
+
const [, s] = e.split("caId.");
|
|
45996
|
+
if (s) {
|
|
45997
|
+
const l = this.options.adcode === 0, a = l ? "ISO_A2" : "adcode";
|
|
45998
|
+
this.setLineColorByProperty(a, l ? s : +s, n);
|
|
45999
|
+
}
|
|
45974
46000
|
} else if (e.startsWith("测试边框宽度")) {
|
|
45975
|
-
const [, s] = e.split("
|
|
45976
|
-
|
|
46001
|
+
const [, s] = e.split("caId.");
|
|
46002
|
+
if (s) {
|
|
46003
|
+
const l = this.options.adcode === 0, a = l ? "ISO_A2" : "adcode";
|
|
46004
|
+
this.setLineWidthByProperty(a, l ? s : +s, n);
|
|
46005
|
+
}
|
|
45977
46006
|
}
|
|
45978
46007
|
return n;
|
|
45979
46008
|
});
|
|
45980
46009
|
}
|
|
45981
46010
|
init() {
|
|
45982
|
-
return
|
|
46011
|
+
return ht(this, null, function* () {
|
|
45983
46012
|
const { adcode: e } = this.options;
|
|
45984
46013
|
this.options.center && (this.pcenter = this.options.center), this.projection = xc({
|
|
45985
46014
|
center: this.pcenter,
|
|
@@ -45990,7 +46019,7 @@ const Ez = Be(Tt({}, Ll), {
|
|
|
45990
46019
|
});
|
|
45991
46020
|
}
|
|
45992
46021
|
initVis(e) {
|
|
45993
|
-
return
|
|
46022
|
+
return ht(this, null, function* () {
|
|
45994
46023
|
var a;
|
|
45995
46024
|
if (this.options.parentBg) {
|
|
45996
46025
|
const o = vn[e].parent || 0, c = this.options.geojsonMap[o], d = this.options.bboxMap[o], r = this.mList.getMaterialObj("parentPlane"), h = yield this.drawController.draw("PlaneMap", {
|
|
@@ -46051,7 +46080,7 @@ const Ez = Be(Tt({}, Ll), {
|
|
|
46051
46080
|
(this.options.parentBg || this.options.continentsBg) && e.add(["/image/map/dian.webp"]);
|
|
46052
46081
|
}
|
|
46053
46082
|
initMaterialBg() {
|
|
46054
|
-
return
|
|
46083
|
+
return ht(this, null, function* () {
|
|
46055
46084
|
const e = this.loader;
|
|
46056
46085
|
if (this.options.parentBg) {
|
|
46057
46086
|
const n = (() => {
|
|
@@ -46210,7 +46239,7 @@ const Ez = Be(Tt({}, Ll), {
|
|
|
46210
46239
|
l && this.map.setLineWidth(l, s);
|
|
46211
46240
|
}
|
|
46212
46241
|
addAreaPlaneByProperty(l, a) {
|
|
46213
|
-
return
|
|
46242
|
+
return ht(this, arguments, function* (e, n, s = {}) {
|
|
46214
46243
|
var d, r, h;
|
|
46215
46244
|
if (!this.map) return;
|
|
46216
46245
|
const c = this.map.options.geojson.features.find(
|
|
@@ -46232,9 +46261,9 @@ const Ez = Be(Tt({}, Ll), {
|
|
|
46232
46261
|
});
|
|
46233
46262
|
}
|
|
46234
46263
|
show() {
|
|
46235
|
-
return
|
|
46264
|
+
return ht(this, null, function* () {
|
|
46236
46265
|
if (this.showState || this.options.disableInitShow) return;
|
|
46237
|
-
|
|
46266
|
+
Is(ba.prototype, this, "show").call(this);
|
|
46238
46267
|
const e = this.drawController.group;
|
|
46239
46268
|
this.mapHistory[0] && (e.position.z = -this.mapHistory[0].depth, yield new Promise((n) => {
|
|
46240
46269
|
new sl(e.position).to(
|
|
@@ -46245,17 +46274,26 @@ const Ez = Be(Tt({}, Ll), {
|
|
|
46245
46274
|
).start().onComplete(() => {
|
|
46246
46275
|
n(null);
|
|
46247
46276
|
});
|
|
46248
|
-
}), this.
|
|
46277
|
+
})), this.handlePickTest();
|
|
46278
|
+
});
|
|
46279
|
+
}
|
|
46280
|
+
handlePickTest() {
|
|
46281
|
+
return ht(this, null, function* () {
|
|
46282
|
+
this.playing || this.handlePick(
|
|
46249
46283
|
() => this.mapArea,
|
|
46250
46284
|
"click",
|
|
46251
|
-
(
|
|
46252
|
-
|
|
46253
|
-
|
|
46254
|
-
|
|
46285
|
+
(e) => ht(this, null, function* () {
|
|
46286
|
+
this.caId = e.userData.ISO_A2 || e.userData.adcode;
|
|
46287
|
+
const n = this.mapLine.find(
|
|
46288
|
+
(a) => a.userData.ISO_A2 === this.caId || a.userData.adcode === this.caId
|
|
46289
|
+
), l = e.object3d.material[0].color.getHexString();
|
|
46290
|
+
this.settings["测试板块颜色.color:::caId"] = "#" + l, yield this.settings["测试板块颜色.color:::caId"], this.settings["测试边框颜色.color:::caId"] = "#" + (n == null ? void 0 : n.material.color.getHexString()), yield this.settings["测试边框颜色.color:::caId"], this.settings["测试边框宽度:::caId"] = n == null ? void 0 : n.material.lineWidth, yield this.settings["测试边框宽度:::caId"], this.emit("settingsChanged");
|
|
46291
|
+
})
|
|
46292
|
+
);
|
|
46255
46293
|
});
|
|
46256
46294
|
}
|
|
46257
46295
|
hide() {
|
|
46258
|
-
return
|
|
46296
|
+
return ht(this, null, function* () {
|
|
46259
46297
|
if (!this.showState) return;
|
|
46260
46298
|
const e = this.drawController.group;
|
|
46261
46299
|
yield new Promise((n) => {
|
|
@@ -46268,12 +46306,12 @@ const Ez = Be(Tt({}, Ll), {
|
|
|
46268
46306
|
n(null);
|
|
46269
46307
|
});
|
|
46270
46308
|
}), setTimeout(() => {
|
|
46271
|
-
|
|
46309
|
+
Is(ba.prototype, this, "hide").call(this);
|
|
46272
46310
|
});
|
|
46273
46311
|
});
|
|
46274
46312
|
}
|
|
46275
46313
|
shadowMapEnabled() {
|
|
46276
|
-
return
|
|
46314
|
+
return ht(this, null, function* () {
|
|
46277
46315
|
this.pencil.scene.userData.shadowMapEnabled = !0;
|
|
46278
46316
|
const e = yield this.drawController.draw("Light", {
|
|
46279
46317
|
type: "SpotLight",
|
|
@@ -46345,7 +46383,7 @@ const Ez = Be(Tt({}, Ll), {
|
|
|
46345
46383
|
return !0;
|
|
46346
46384
|
}
|
|
46347
46385
|
clickArea(s) {
|
|
46348
|
-
return
|
|
46386
|
+
return ht(this, arguments, function* ({
|
|
46349
46387
|
adcodes: e,
|
|
46350
46388
|
duration: n = 1e3
|
|
46351
46389
|
}) {
|
|
@@ -46356,11 +46394,11 @@ const Ez = Be(Tt({}, Ll), {
|
|
|
46356
46394
|
});
|
|
46357
46395
|
}
|
|
46358
46396
|
drawLabels() {
|
|
46359
|
-
return
|
|
46397
|
+
return ht(this, null, function* () {
|
|
46360
46398
|
var n;
|
|
46361
46399
|
const e = this.options.showLabel;
|
|
46362
46400
|
!((n = this.mapArea) != null && n.length) || !e || (yield Promise.all(
|
|
46363
|
-
this.mapArea.map((s) =>
|
|
46401
|
+
this.mapArea.map((s) => ht(this, null, function* () {
|
|
46364
46402
|
let { name: l, adcode: a } = s.userData;
|
|
46365
46403
|
const { DistrictID: o, DistName: c, NAME_CN: d, CENTROID: r } = s.userData;
|
|
46366
46404
|
a = a || o, l = this.options.adcode === 0 ? d : l || c;
|
|
@@ -46410,7 +46448,7 @@ const Ez = Be(Tt({}, Ll), {
|
|
|
46410
46448
|
return np.features[0].geometry.coordinates.some((n) => S2(MX(e), Yc(n)));
|
|
46411
46449
|
}
|
|
46412
46450
|
handleDrillDown(s) {
|
|
46413
|
-
return
|
|
46451
|
+
return ht(this, arguments, function* ({
|
|
46414
46452
|
adcode: e,
|
|
46415
46453
|
duration: n
|
|
46416
46454
|
}) {
|
|
@@ -46491,7 +46529,7 @@ const Ez = Be(Tt({}, Ll), {
|
|
|
46491
46529
|
return Ya.euclideanModulo(l + Math.PI, s) - Math.PI;
|
|
46492
46530
|
}
|
|
46493
46531
|
fitTo(a) {
|
|
46494
|
-
return
|
|
46532
|
+
return ht(this, arguments, function* (e, {
|
|
46495
46533
|
polarAngle: n,
|
|
46496
46534
|
azimuthAngle: s,
|
|
46497
46535
|
enableTransition: l = !0
|
|
@@ -46558,7 +46596,7 @@ const Ez = Be(Tt({}, Ll), {
|
|
|
46558
46596
|
});
|
|
46559
46597
|
}
|
|
46560
46598
|
drawPlaneMap(o) {
|
|
46561
|
-
return
|
|
46599
|
+
return ht(this, arguments, function* ({
|
|
46562
46600
|
geojson: e,
|
|
46563
46601
|
extrudeLineGeojson: n,
|
|
46564
46602
|
bbox: s,
|
|
@@ -46593,7 +46631,7 @@ const Ez = Be(Tt({}, Ll), {
|
|
|
46593
46631
|
});
|
|
46594
46632
|
}
|
|
46595
46633
|
handleBack(e) {
|
|
46596
|
-
return
|
|
46634
|
+
return ht(this, null, function* () {
|
|
46597
46635
|
if (this.mapHistory.length > 1 && !this.isAnimating) {
|
|
46598
46636
|
this.isAnimating = !0;
|
|
46599
46637
|
const n = this.mapHistory.pop();
|
|
@@ -46615,7 +46653,7 @@ const Ez = Be(Tt({}, Ll), {
|
|
|
46615
46653
|
});
|
|
46616
46654
|
}
|
|
46617
46655
|
handleLookBack(e) {
|
|
46618
|
-
return
|
|
46656
|
+
return ht(this, null, function* () {
|
|
46619
46657
|
var a;
|
|
46620
46658
|
const { map: n, cameraPositon: s, cameraTarget: l } = this.mapObj;
|
|
46621
46659
|
s && l ? yield (a = this.pencil.cameraControls) == null ? void 0 : a.setLookAt(
|
|
@@ -46632,7 +46670,7 @@ const Ez = Be(Tt({}, Ll), {
|
|
|
46632
46670
|
});
|
|
46633
46671
|
}
|
|
46634
46672
|
setAdcode(s) {
|
|
46635
|
-
return
|
|
46673
|
+
return ht(this, arguments, function* ({ adcodes: e, duration: n }) {
|
|
46636
46674
|
const { adcodes: l } = this;
|
|
46637
46675
|
if (!(JSON.stringify(e) === JSON.stringify(l) || this.isAnimating))
|
|
46638
46676
|
if (JSON.stringify(e) === JSON.stringify([0]))
|
|
@@ -47202,7 +47240,7 @@ class Nf extends Ge {
|
|
|
47202
47240
|
}, e);
|
|
47203
47241
|
}
|
|
47204
47242
|
create() {
|
|
47205
|
-
return
|
|
47243
|
+
return ht(this, null, function* () {
|
|
47206
47244
|
const { width: e, height: n, color: s, map: l, material: a } = this.options, o = new Sn(e, n, 2, 2);
|
|
47207
47245
|
this.plane = o;
|
|
47208
47246
|
const c = a || new Dt({
|
|
@@ -47277,7 +47315,7 @@ class vf extends Ge {
|
|
|
47277
47315
|
this.options = Tt({}, e);
|
|
47278
47316
|
}
|
|
47279
47317
|
create() {
|
|
47280
|
-
return
|
|
47318
|
+
return ht(this, null, function* () {
|
|
47281
47319
|
const { json: e, projection: n, cacheKey: s, meters: l, grey: a, clip: o } = this.options, c = this.pencil.installPlugins.get("materialList"), d = this.pencil.getPlugin("worker"), r = this.pencil.getPlugin("draw"), h = a ? "-grey" : "";
|
|
47282
47320
|
this.createGroup();
|
|
47283
47321
|
const u = c.getMaterialObj("building" + h);
|
|
@@ -47333,7 +47371,7 @@ class vf extends Ge {
|
|
|
47333
47371
|
);
|
|
47334
47372
|
}
|
|
47335
47373
|
yield Promise.all(
|
|
47336
|
-
m.map((b) =>
|
|
47374
|
+
m.map((b) => ht(this, null, function* () {
|
|
47337
47375
|
const { h: G, z: Z } = b.userData, p = G + Z, X = p <= 20 ? "20" : p <= 60 ? "60" : "max";
|
|
47338
47376
|
let y = this.options.material;
|
|
47339
47377
|
y || (y = [u[X + "Top"], u[X + "Side"]]);
|
|
@@ -47364,7 +47402,7 @@ class Tf extends Ge {
|
|
|
47364
47402
|
this.options = Tt({}, e);
|
|
47365
47403
|
}
|
|
47366
47404
|
create() {
|
|
47367
|
-
return
|
|
47405
|
+
return ht(this, null, function* () {
|
|
47368
47406
|
this.createGroup();
|
|
47369
47407
|
const { json: e, projection: n, type: s, cacheKey: l, material: a, oArr: o, clip: c } = this.options, d = this.pencil.getPlugin("worker"), r = this.pencil.getPlugin("draw");
|
|
47370
47408
|
let h = l ? yield d.getCachedGeometry({
|
|
@@ -47424,7 +47462,7 @@ class Tf extends Ge {
|
|
|
47424
47462
|
);
|
|
47425
47463
|
}
|
|
47426
47464
|
yield Promise.all(
|
|
47427
|
-
h.map((u) =>
|
|
47465
|
+
h.map((u) => ht(this, null, function* () {
|
|
47428
47466
|
const { z: m } = u.userData, b = yield r.draw(
|
|
47429
47467
|
"ExtrudePolygon",
|
|
47430
47468
|
{
|
|
@@ -47453,7 +47491,7 @@ class Mf extends Ge {
|
|
|
47453
47491
|
this.options = Tt({}, e);
|
|
47454
47492
|
}
|
|
47455
47493
|
create() {
|
|
47456
|
-
return
|
|
47494
|
+
return ht(this, null, function* () {
|
|
47457
47495
|
const { clip: e, grey: n } = this.options;
|
|
47458
47496
|
this.createGroup();
|
|
47459
47497
|
const s = this.pencil.getPlugin("worker"), l = this.pencil.getPlugin("draw");
|
|
@@ -47507,7 +47545,7 @@ class Mf extends Ge {
|
|
|
47507
47545
|
);
|
|
47508
47546
|
}
|
|
47509
47547
|
yield Promise.all(
|
|
47510
|
-
u.map((m) =>
|
|
47548
|
+
u.map((m) => ht(this, null, function* () {
|
|
47511
47549
|
const b = yield l.draw(
|
|
47512
47550
|
"Line",
|
|
47513
47551
|
{
|
|
@@ -47639,7 +47677,7 @@ class Ff extends Ge {
|
|
|
47639
47677
|
return l.translateZ(1), l;
|
|
47640
47678
|
}
|
|
47641
47679
|
create() {
|
|
47642
|
-
return
|
|
47680
|
+
return ht(this, null, function* () {
|
|
47643
47681
|
const { scale: e = 0.03 } = this.options;
|
|
47644
47682
|
this.createGroup();
|
|
47645
47683
|
const n = this.pencil.getPlugin("loader"), s = "241, 241, 86", l = n.getAsset("/image/city/cylinder.webp"), a = iU(s), o = this.createRipple(a);
|
|
@@ -47665,11 +47703,11 @@ const Hf = Be(Tt({}, Ll), {
|
|
|
47665
47703
|
Target: Ff
|
|
47666
47704
|
}), sU = (i) => {
|
|
47667
47705
|
i.loaderAdd = function() {
|
|
47668
|
-
return
|
|
47706
|
+
return ht(this, null, function* () {
|
|
47669
47707
|
this.loaderAddBg();
|
|
47670
47708
|
});
|
|
47671
47709
|
}, i.initMaterial = function() {
|
|
47672
|
-
return
|
|
47710
|
+
return ht(this, null, function* () {
|
|
47673
47711
|
const t = (() => {
|
|
47674
47712
|
const e = new Dt({
|
|
47675
47713
|
name: "板块顶面",
|
|
@@ -47738,7 +47776,7 @@ const Hf = Be(Tt({}, Ll), {
|
|
|
47738
47776
|
}, i.loaderAdd = function() {
|
|
47739
47777
|
this.loader.add(["/image/map2/side.png"]);
|
|
47740
47778
|
}, i.initMaterial = function() {
|
|
47741
|
-
return
|
|
47779
|
+
return ht(this, null, function* () {
|
|
47742
47780
|
const t = this.loader, e = (() => {
|
|
47743
47781
|
const n = new Dt({
|
|
47744
47782
|
name: "板块顶面",
|
|
@@ -47790,7 +47828,7 @@ const Hf = Be(Tt({}, Ll), {
|
|
|
47790
47828
|
}
|
|
47791
47829
|
);
|
|
47792
47830
|
}, i.initMaterial = function() {
|
|
47793
|
-
return
|
|
47831
|
+
return ht(this, null, function* () {
|
|
47794
47832
|
const t = i.roomEnvMap, e = i.loader, n = (() => {
|
|
47795
47833
|
const l = new n0({
|
|
47796
47834
|
name: "顶面",
|
|
@@ -47874,7 +47912,7 @@ const Hf = Be(Tt({}, Ll), {
|
|
|
47874
47912
|
})();
|
|
47875
47913
|
i.mList.setMaterialObj("plane", s);
|
|
47876
47914
|
});
|
|
47877
|
-
}, i.initVis = (t) =>
|
|
47915
|
+
}, i.initVis = (t) => ht(void 0, null, function* () {
|
|
47878
47916
|
let e = 1e3, n = 1e3;
|
|
47879
47917
|
const s = new N(0, 0, 0);
|
|
47880
47918
|
if (i.options.parentBg) {
|
|
@@ -47935,7 +47973,7 @@ const Hf = Be(Tt({}, Ll), {
|
|
|
47935
47973
|
}
|
|
47936
47974
|
);
|
|
47937
47975
|
}, i.initMaterial = function() {
|
|
47938
|
-
return
|
|
47976
|
+
return ht(this, null, function* () {
|
|
47939
47977
|
if (!i.mList.getMaterialObj("building")) {
|
|
47940
47978
|
const t = ["20", "60", "max"].reduce(
|
|
47941
47979
|
(e, n) => {
|
|
@@ -48043,7 +48081,7 @@ class cU extends R2 {
|
|
|
48043
48081
|
);
|
|
48044
48082
|
}
|
|
48045
48083
|
initMaterialBg() {
|
|
48046
|
-
return
|
|
48084
|
+
return ht(this, null, function* () {
|
|
48047
48085
|
const e = this.roomEnvMap;
|
|
48048
48086
|
if (this.options.parentBg) {
|
|
48049
48087
|
if (this.options.adcode !== 1e5) {
|
|
@@ -48124,7 +48162,7 @@ class cU extends R2 {
|
|
|
48124
48162
|
});
|
|
48125
48163
|
}
|
|
48126
48164
|
initVis(e) {
|
|
48127
|
-
return
|
|
48165
|
+
return ht(this, null, function* () {
|
|
48128
48166
|
var a;
|
|
48129
48167
|
let n = 1e3, s = 1e3;
|
|
48130
48168
|
const l = new N(0, 0, 0);
|
|
@@ -48199,7 +48237,7 @@ class cU extends R2 {
|
|
|
48199
48237
|
});
|
|
48200
48238
|
}
|
|
48201
48239
|
drawPlaneMap(o) {
|
|
48202
|
-
return
|
|
48240
|
+
return ht(this, arguments, function* ({
|
|
48203
48241
|
geojson: e,
|
|
48204
48242
|
extrudeLineGeojson: n,
|
|
48205
48243
|
bbox: s,
|
|
@@ -48320,7 +48358,7 @@ class Jf extends ad {
|
|
|
48320
48358
|
);
|
|
48321
48359
|
}
|
|
48322
48360
|
initMaterial() {
|
|
48323
|
-
return
|
|
48361
|
+
return ht(this, null, function* () {
|
|
48324
48362
|
if (!this.mList.getMaterialObj("building")) {
|
|
48325
48363
|
const e = ["20", "60", "max"].reduce(
|
|
48326
48364
|
(s, l) => {
|
|
@@ -48429,7 +48467,7 @@ class Jf extends ad {
|
|
|
48429
48467
|
});
|
|
48430
48468
|
}
|
|
48431
48469
|
init() {
|
|
48432
|
-
return
|
|
48470
|
+
return ht(this, null, function* () {
|
|
48433
48471
|
const { jsonName: e, bbox: n, loaderAdd: s } = this.options;
|
|
48434
48472
|
yield this.initPencil(), s && this.loaderAdd(), this.loaderAddJson(e), yield this.loader.loadAll(), this.verticalDragToForward = !0, this.adcode = this.options.adcode, this.options.center && (this.pcenter = this.options.center), this.projection = xc({
|
|
48435
48473
|
center: this.pcenter,
|
|
@@ -48442,7 +48480,7 @@ class Jf extends ad {
|
|
|
48442
48480
|
return (s = (n = this.projection).invert) == null ? void 0 : s.call(n, [e.x, -e.z]);
|
|
48443
48481
|
}
|
|
48444
48482
|
fitTo(e, n = !0) {
|
|
48445
|
-
return
|
|
48483
|
+
return ht(this, null, function* () {
|
|
48446
48484
|
this.pencil.cameraControls.fitToBox(e.object3d, n), this.pencil.cameraControls.rotatePolarTo(
|
|
48447
48485
|
this.pencil.camera.up.z === 1 ? Math.PI / 180 * 70 : Math.PI / 180 * 160,
|
|
48448
48486
|
n
|
|
@@ -48450,7 +48488,7 @@ class Jf extends ad {
|
|
|
48450
48488
|
});
|
|
48451
48489
|
}
|
|
48452
48490
|
initVis() {
|
|
48453
|
-
return
|
|
48491
|
+
return ht(this, null, function* () {
|
|
48454
48492
|
const { fitTo: e, jsonName: n, bbox: s, planeOut: l } = this.options, a = this.adcode, o = this.loader, c = o.getAsset(`/city/Building${n}.json`), d = o.getAsset(`/city/Road${n}.json`), r = o.getAsset(`/city/River${n}.json`), h = o.getAsset(`/city/Grassland${n}.json`), u = {};
|
|
48455
48493
|
[
|
|
48456
48494
|
...(r == null ? void 0 : r.features) || [],
|
|
@@ -48520,7 +48558,7 @@ class Jf extends ad {
|
|
|
48520
48558
|
});
|
|
48521
48559
|
}
|
|
48522
48560
|
fitToTarget(e, n) {
|
|
48523
|
-
return
|
|
48561
|
+
return ht(this, null, function* () {
|
|
48524
48562
|
const s = this.drawController.getObject("Target", {
|
|
48525
48563
|
key: "cityTarget" + e
|
|
48526
48564
|
});
|
|
@@ -48554,7 +48592,7 @@ class Jf extends ad {
|
|
|
48554
48592
|
return Ya.euclideanModulo(l + Math.PI, s) - Math.PI;
|
|
48555
48593
|
}
|
|
48556
48594
|
lookAtTarget(e, n, s, l = 0) {
|
|
48557
|
-
return
|
|
48595
|
+
return ht(this, null, function* () {
|
|
48558
48596
|
const a = this.pencil.cameraControls.azimuthAngle, o = this.pencil.cameraControls.polarAngle, c = a !== l || o !== s;
|
|
48559
48597
|
yield Promise.all(
|
|
48560
48598
|
[
|
|
@@ -48570,7 +48608,7 @@ class Jf extends ad {
|
|
|
48570
48608
|
});
|
|
48571
48609
|
}
|
|
48572
48610
|
drawBuilding() {
|
|
48573
|
-
return
|
|
48611
|
+
return ht(this, arguments, function* (e = {}) {
|
|
48574
48612
|
var l;
|
|
48575
48613
|
if (!e.json) {
|
|
48576
48614
|
console.warn(" json:Building");
|
|
@@ -48606,7 +48644,7 @@ class Jf extends ad {
|
|
|
48606
48644
|
});
|
|
48607
48645
|
}
|
|
48608
48646
|
drawArea() {
|
|
48609
|
-
return
|
|
48647
|
+
return ht(this, arguments, function* (e = {}) {
|
|
48610
48648
|
var o;
|
|
48611
48649
|
if (!e.json) {
|
|
48612
48650
|
console.warn(" json:drawArea");
|
|
@@ -48644,7 +48682,7 @@ class Jf extends ad {
|
|
|
48644
48682
|
});
|
|
48645
48683
|
}
|
|
48646
48684
|
drawRoad() {
|
|
48647
|
-
return
|
|
48685
|
+
return ht(this, arguments, function* (e = {}) {
|
|
48648
48686
|
var a;
|
|
48649
48687
|
if (!e.json) {
|
|
48650
48688
|
console.warn(" json:Road");
|
|
@@ -48739,9 +48777,9 @@ const Ru = class Ru extends cU {
|
|
|
48739
48777
|
}, e)), this.pencilConfig = _z, this.pencilConfig.bloom = this.options.bloom;
|
|
48740
48778
|
}
|
|
48741
48779
|
init() {
|
|
48742
|
-
return
|
|
48780
|
+
return ht(this, null, function* () {
|
|
48743
48781
|
var e;
|
|
48744
|
-
if (yield
|
|
48782
|
+
if (yield Is(Ru.prototype, this, "init").call(this), this.showGroup = "map", this.options.adcode == 1e5 && (this.pencil.camera.far = 500, this.pencil.camera.updateProjectionMatrix()), this.on("handleDrillDown", (s) => ht(this, [s], function* ({ adcode: n }) {
|
|
48745
48783
|
const l = this.getAdcodeShowLevel(n) === "city";
|
|
48746
48784
|
this.options.initCity && l && this.initCityVis(n, {
|
|
48747
48785
|
clip: !!this.options.cityOnMap,
|
|
@@ -48753,7 +48791,7 @@ const Ru = class Ru extends cU {
|
|
|
48753
48791
|
if (this.options.allCity) {
|
|
48754
48792
|
const n = vn[this.mapInfo.adcode], s = n.level === "province" ? n.adcode : vn[this.mapInfo.adcode].parent, l = (e = aR.find((a) => a.adcode === s)) == null ? void 0 : e.subAreas;
|
|
48755
48793
|
l && (yield Promise.all(
|
|
48756
|
-
l.map((a) =>
|
|
48794
|
+
l.map((a) => ht(this, null, function* () {
|
|
48757
48795
|
yield this.initCityOnMap(a);
|
|
48758
48796
|
}))
|
|
48759
48797
|
));
|
|
@@ -48762,7 +48800,7 @@ const Ru = class Ru extends cU {
|
|
|
48762
48800
|
});
|
|
48763
48801
|
}
|
|
48764
48802
|
preInitCityVis() {
|
|
48765
|
-
return
|
|
48803
|
+
return ht(this, null, function* () {
|
|
48766
48804
|
const e = Object.keys(this.options.jsonNameObj);
|
|
48767
48805
|
for (let n = 0; n < e.length; n++)
|
|
48768
48806
|
yield this.initCityVis(Number(e[n]));
|
|
@@ -48770,7 +48808,7 @@ const Ru = class Ru extends cU {
|
|
|
48770
48808
|
});
|
|
48771
48809
|
}
|
|
48772
48810
|
initCityVis(s) {
|
|
48773
|
-
return
|
|
48811
|
+
return ht(this, arguments, function* (e, n = { clip: !1, grey: !1 }) {
|
|
48774
48812
|
var r;
|
|
48775
48813
|
(r = this.options.fixCity) != null && r[e] && (e = this.options.fixCity[e]);
|
|
48776
48814
|
const l = this.options.center, a = this.options.cityBboxMap[e];
|
|
@@ -48810,7 +48848,7 @@ const Ru = class Ru extends cU {
|
|
|
48810
48848
|
});
|
|
48811
48849
|
}
|
|
48812
48850
|
initCityOnMap(e) {
|
|
48813
|
-
return
|
|
48851
|
+
return ht(this, null, function* () {
|
|
48814
48852
|
if (this.getAdcodeShowLevel(e) !== "city") {
|
|
48815
48853
|
const l = vn[e].parent;
|
|
48816
48854
|
this.getAdcodeShowLevel(l) === "city" && (yield this.initCityOnMap(l));
|
|
@@ -48831,7 +48869,7 @@ const Ru = class Ru extends cU {
|
|
|
48831
48869
|
});
|
|
48832
48870
|
}
|
|
48833
48871
|
showCity(e, n) {
|
|
48834
|
-
return
|
|
48872
|
+
return ht(this, null, function* () {
|
|
48835
48873
|
var r;
|
|
48836
48874
|
let s, l, a = this.mapInfo.adcode, o = 0.03637926645733737, c = 0.9963693538268685, d = 0;
|
|
48837
48875
|
if (typeof e == "number" ? (a = e, s = n, console.warn(
|
|
@@ -48868,7 +48906,7 @@ const Ru = class Ru extends cU {
|
|
|
48868
48906
|
});
|
|
48869
48907
|
}
|
|
48870
48908
|
showMap(e) {
|
|
48871
|
-
return
|
|
48909
|
+
return ht(this, null, function* () {
|
|
48872
48910
|
if (this.isAnimating)
|
|
48873
48911
|
return;
|
|
48874
48912
|
e || (e = this.adcodes), this.showGroup === "city" && !this.options.cityOnMap && (this.fixNear(this.mapInfo.adcode), this.cityVis.group.hide(), this.group.show(), this.verticalDragToForward = !1), this.showGroup = "map", JSON.stringify(e) === JSON.stringify(this.adcodes) ? (this.emit("beforeDrillDown", [...this.adcodes]), this.options.cityOnMap ? yield this.handleLookBack() : yield this.fitTo(this.map), this.emit("afterDrillDown", [...this.adcodes])) : yield this.clickArea({
|
|
@@ -48913,7 +48951,7 @@ class mU extends Ge {
|
|
|
48913
48951
|
}, e);
|
|
48914
48952
|
}
|
|
48915
48953
|
create() {
|
|
48916
|
-
return
|
|
48954
|
+
return ht(this, null, function* () {
|
|
48917
48955
|
const { geojson: e, mats: n, hasSide: s } = this.options;
|
|
48918
48956
|
this.createGroup();
|
|
48919
48957
|
const l = this.pencil.getPlugin("worker"), a = this.pencil.getPlugin("draw"), { borderMat: o, topMat: c, outLine: d } = n, r = e.features.map((u) => {
|
|
@@ -48936,7 +48974,7 @@ class mU extends Ge {
|
|
|
48936
48974
|
bbox: this.options.bbox,
|
|
48937
48975
|
hasSide: s
|
|
48938
48976
|
},
|
|
48939
|
-
cb: (m) =>
|
|
48977
|
+
cb: (m) => ht(this, null, function* () {
|
|
48940
48978
|
const b = yield a.draw(
|
|
48941
48979
|
"ConicPolygon",
|
|
48942
48980
|
{
|
|
@@ -48955,7 +48993,7 @@ class mU extends Ge {
|
|
|
48955
48993
|
lineWidth: [1],
|
|
48956
48994
|
coordinatesArr: u.coords
|
|
48957
48995
|
},
|
|
48958
|
-
cb: (m) =>
|
|
48996
|
+
cb: (m) => ht(this, null, function* () {
|
|
48959
48997
|
const b = yield a.draw(
|
|
48960
48998
|
"Line",
|
|
48961
48999
|
{
|
|
@@ -49016,8 +49054,8 @@ class pU extends Ge {
|
|
|
49016
49054
|
}, e);
|
|
49017
49055
|
}
|
|
49018
49056
|
create() {
|
|
49019
|
-
return
|
|
49020
|
-
const e = this.pencil.installPlugins.get("materialList"), n = new
|
|
49057
|
+
return ht(this, null, function* () {
|
|
49058
|
+
const e = this.pencil.installPlugins.get("materialList"), n = new gs(this.options.radius, 128, 90), s = new Dt();
|
|
49021
49059
|
this.createMesh(n, s), this.scale.multiplyScalar(1.001), this.rotation.y = Math.PI / 180 * -90, this.object3d.name = "阴影面", e.setObject3d(this.object3d, "SphereShadow", {
|
|
49022
49060
|
baseObject: this
|
|
49023
49061
|
}), this.hide();
|
|
@@ -49056,7 +49094,7 @@ const bU = Be(Tt({}, Ll), {
|
|
|
49056
49094
|
colorCorrection: !1
|
|
49057
49095
|
});
|
|
49058
49096
|
}, i.initVis = function() {
|
|
49059
|
-
return
|
|
49097
|
+
return ht(this, null, function* () {
|
|
49060
49098
|
yield this.initLight();
|
|
49061
49099
|
const [, , , t] = yield Promise.all([
|
|
49062
49100
|
this.drawController.draw("Earth", {
|
|
@@ -49110,7 +49148,7 @@ const bU = Be(Tt({}, Ll), {
|
|
|
49110
49148
|
), yield this.pencil.cameraControls.dollyTo(99.11560932366835, !1);
|
|
49111
49149
|
});
|
|
49112
49150
|
}, i.initMaterial = function() {
|
|
49113
|
-
return
|
|
49151
|
+
return ht(this, null, function* () {
|
|
49114
49152
|
const t = this.loader, e = new n0({
|
|
49115
49153
|
side: He,
|
|
49116
49154
|
name: "顶面",
|
|
@@ -49165,7 +49203,7 @@ const bU = Be(Tt({}, Ll), {
|
|
|
49165
49203
|
};
|
|
49166
49204
|
}, XU = (i) => {
|
|
49167
49205
|
i.initVis = function() {
|
|
49168
|
-
return
|
|
49206
|
+
return ht(this, null, function* () {
|
|
49169
49207
|
yield this.initLight();
|
|
49170
49208
|
const [, t] = yield Promise.all([
|
|
49171
49209
|
this.drawController.draw("Earth", {
|
|
@@ -49185,7 +49223,7 @@ const bU = Be(Tt({}, Ll), {
|
|
|
49185
49223
|
this.map = t, yield this.pencil.cameraControls.rotateTo(1.8041576242193995, 1.2232045720480524, !1), yield this.pencil.cameraControls.dollyTo(99.11560932366835, !1), this.playing && (this.pencil.cameraControls.minPolarAngle = this.pencil.cameraControls.polarAngle, this.pencil.cameraControls.maxPolarAngle = this.pencil.cameraControls.polarAngle);
|
|
49186
49224
|
});
|
|
49187
49225
|
}, i.initMaterial = function() {
|
|
49188
|
-
return
|
|
49226
|
+
return ht(this, null, function* () {
|
|
49189
49227
|
const t = new n0({
|
|
49190
49228
|
side: He,
|
|
49191
49229
|
name: "侧面",
|
|
@@ -49247,12 +49285,12 @@ const bU = Be(Tt({}, Ll), {
|
|
|
49247
49285
|
}, yU[this.options.style](this);
|
|
49248
49286
|
}
|
|
49249
49287
|
handleSetting(e, n) {
|
|
49250
|
-
return
|
|
49251
|
-
return yield
|
|
49288
|
+
return ht(this, null, function* () {
|
|
49289
|
+
return yield Is(xu.prototype, this, "handleSetting").call(this, e, n), e === "测试板块颜色.color" ? this.setAreaEmissiveByProperty("ISO_A2", "CN", n) : e === "测试边框颜色.color" ? this.setLineColorByProperty("ISO_A2", "CN", n) : e === "测试立柱" && (typeof n == "boolean" && (n = ""), n ? this.addBar(n) : this.removeBar()), n;
|
|
49252
49290
|
});
|
|
49253
49291
|
}
|
|
49254
49292
|
initLight() {
|
|
49255
|
-
return
|
|
49293
|
+
return ht(this, null, function* () {
|
|
49256
49294
|
const [e, n] = yield Promise.all([
|
|
49257
49295
|
this.drawController.draw("Light", {
|
|
49258
49296
|
type: "RectAreaLight",
|
|
@@ -49362,7 +49400,7 @@ const bU = Be(Tt({}, Ll), {
|
|
|
49362
49400
|
l && this.map.setLineColor(l, s);
|
|
49363
49401
|
}
|
|
49364
49402
|
addAreaPlaneByProperty(e, n, s) {
|
|
49365
|
-
return
|
|
49403
|
+
return ht(this, null, function* () {
|
|
49366
49404
|
if (!this.map) return;
|
|
49367
49405
|
const a = this.map.options.geojson.features.find(
|
|
49368
49406
|
(o) => o.properties && o.properties[e] === n
|
|
@@ -49418,7 +49456,7 @@ const bU = Be(Tt({}, Ll), {
|
|
|
49418
49456
|
"马来西亚",
|
|
49419
49457
|
"俄罗斯"
|
|
49420
49458
|
];
|
|
49421
|
-
this.mapArea.filter((l) => s.includes(l.userData.NAME_CN)).forEach((l) =>
|
|
49459
|
+
this.mapArea.filter((l) => s.includes(l.userData.NAME_CN)).forEach((l) => ht(this, null, function* () {
|
|
49422
49460
|
const [a, o] = l.userData.CENTROID, c = this.getLocationPosition([a, o], 0.1), d = yield n.instantiate();
|
|
49423
49461
|
d.position.set(...c), d.object3d.lookAt(0, 0, 0), this.barArr.push(d);
|
|
49424
49462
|
}));
|
|
@@ -49446,7 +49484,7 @@ class WU extends Gb {
|
|
|
49446
49484
|
}
|
|
49447
49485
|
class VU extends Ge {
|
|
49448
49486
|
create() {
|
|
49449
|
-
return
|
|
49487
|
+
return ht(this, null, function* () {
|
|
49450
49488
|
const e = 249.75641025641025, n = this.pencil.getPlugin("loader"), s = this.pencil.getPlugin("draw"), l = yield s.draw("Image", {
|
|
49451
49489
|
texture: n.getAsset("/image/earth2/earth_circle.png"),
|
|
49452
49490
|
sprite: !0,
|
|
@@ -49474,7 +49512,7 @@ class VU extends Ge {
|
|
|
49474
49512
|
}
|
|
49475
49513
|
class gU extends Ge {
|
|
49476
49514
|
create() {
|
|
49477
|
-
return
|
|
49515
|
+
return ht(this, null, function* () {
|
|
49478
49516
|
const e = this.pencil.getPlugin("loader"), s = yield this.pencil.getPlugin("draw").draw(
|
|
49479
49517
|
"Image",
|
|
49480
49518
|
{
|
|
@@ -49498,7 +49536,7 @@ class fU extends Ge {
|
|
|
49498
49536
|
this.options = e;
|
|
49499
49537
|
}
|
|
49500
49538
|
create() {
|
|
49501
|
-
return
|
|
49539
|
+
return ht(this, null, function* () {
|
|
49502
49540
|
const e = this.pencil.getPlugin("loader"), s = yield this.pencil.getPlugin("draw").draw(
|
|
49503
49541
|
"Image",
|
|
49504
49542
|
{
|
|
@@ -49523,7 +49561,7 @@ class fU extends Ge {
|
|
|
49523
49561
|
}).start();
|
|
49524
49562
|
}
|
|
49525
49563
|
instantiate() {
|
|
49526
|
-
return
|
|
49564
|
+
return ht(this, null, function* () {
|
|
49527
49565
|
const e = yield this.icon.instantiate();
|
|
49528
49566
|
return yield this.drawController.instantiate(this, {
|
|
49529
49567
|
create: (s) => {
|
|
@@ -49575,7 +49613,7 @@ const RU = Be(Tt({}, Ll), {
|
|
|
49575
49613
|
]);
|
|
49576
49614
|
}
|
|
49577
49615
|
initVis() {
|
|
49578
|
-
return
|
|
49616
|
+
return ht(this, null, function* () {
|
|
49579
49617
|
yield Promise.all([
|
|
49580
49618
|
this.drawController.draw("Light", {
|
|
49581
49619
|
type: "PointLight",
|
|
@@ -49599,12 +49637,12 @@ const RU = Be(Tt({}, Ll), {
|
|
|
49599
49637
|
super.show(), this.animationIn();
|
|
49600
49638
|
}
|
|
49601
49639
|
handleSetting(e, n) {
|
|
49602
|
-
return
|
|
49603
|
-
return yield
|
|
49640
|
+
return ht(this, null, function* () {
|
|
49641
|
+
return yield Is(Su.prototype, this, "handleSetting").call(this, e, n), e === "autoRotate" && this.playing && (n ? this.autoRotateSpeed = -20 : this.autoRotateSpeed = 0, this.pencil.autoRotate(this.autoRotateSpeed)), n;
|
|
49604
49642
|
});
|
|
49605
49643
|
}
|
|
49606
49644
|
animationIn() {
|
|
49607
|
-
return
|
|
49645
|
+
return ht(this, null, function* () {
|
|
49608
49646
|
const e = this.pencil.cameraControls;
|
|
49609
49647
|
e.setPosition(0, 0, 1800, !1), yield e.rotatePolarTo(1.046, !1);
|
|
49610
49648
|
const n = this.drawController.getObject("Light"), s = new N();
|