@tomorrowevening/hermes 0.0.162 → 0.0.164
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/hermes.cjs.js +2 -2
- package/dist/hermes.css +1 -1
- package/dist/hermes.es.js +293 -291
- package/package.json +1 -1
package/dist/hermes.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Texture as Nh, OrthographicCamera as Ph, Scene as yu, MeshBasicMaterial as bn, BufferGeometry as Tn, Float32BufferAttribute as gn, Mesh as X, LinearSRGBColorSpace as Pa, ObjectLoader as ox, AnimationMixer as lx, AnimationClip as cx, WebGLRenderTarget as Dm, RGBAFormat as hx, EventDispatcher as xu, Clock as Fm, Group as jo, RepeatWrapping as zd, Color as vn, ColorManagement as ir, FrontSide as ux, BackSide as Om, DoubleSide as _u, ZeroFactor as Im, OneFactor as Bm, SrcColorFactor as Lm, OneMinusSrcColorFactor as Um, SrcAlphaFactor as km, OneMinusSrcAlphaFactor as zm, DstAlphaFactor as Gm, OneMinusDstAlphaFactor as Vm, DstColorFactor as Hm, OneMinusDstColorFactor as
|
|
1
|
+
import { Texture as Nh, OrthographicCamera as Ph, Scene as yu, MeshBasicMaterial as bn, BufferGeometry as Tn, Float32BufferAttribute as gn, Mesh as X, LinearSRGBColorSpace as Pa, ObjectLoader as ox, AnimationMixer as lx, AnimationClip as cx, WebGLRenderTarget as Dm, RGBAFormat as hx, EventDispatcher as xu, Clock as Fm, Group as jo, RepeatWrapping as zd, Color as vn, ColorManagement as ir, FrontSide as ux, BackSide as Om, DoubleSide as _u, ZeroFactor as Im, OneFactor as Bm, SrcColorFactor as Lm, OneMinusSrcColorFactor as Um, SrcAlphaFactor as km, OneMinusSrcAlphaFactor as zm, DstAlphaFactor as Gm, OneMinusDstAlphaFactor as Vm, DstColorFactor as Hm, OneMinusDstColorFactor as $m, SrcAlphaSaturateFactor as dx, ConstantColorFactor as Wm, OneMinusConstantColorFactor as jm, ConstantAlphaFactor as qm, OneMinusConstantAlphaFactor as Ym, AddEquation as px, SubtractEquation as fx, ReverseSubtractEquation as mx, MinEquation as gx, MaxEquation as yx, NoBlending as xx, NormalBlending as _x, AdditiveBlending as bx, SubtractiveBlending as Tx, MultiplyBlending as Sx, CustomBlending as vx, Line as Ls, LineBasicMaterial as bu, Controls as Xm, Vector3 as K, MOUSE as ur, TOUCH as nr, Quaternion as Jt, Spherical as Dh, Vector2 as yt, Ray as wx, Plane as Ex, MathUtils as Cx, ShaderMaterial as Zm, GLSL3 as Mx, PlaneGeometry as Km, Raycaster as Da, Object3D as Tr, CylinderGeometry as kt, BoxGeometry as Tt, OctahedronGeometry as Qa, TorusGeometry as Lr, SphereGeometry as Qm, Euler as Jm, Matrix4 as Rl, CatmullRomCurve3 as Gd, AxesHelper as Ax, MeshDepthMaterial as Rx, MeshNormalMaterial as Nx, Sphere as Px, Box3 as Dx, Vector4 as Fx, WebGLRenderer as da, PerspectiveCamera as Vd, CameraHelper as Ox, SkinnedMesh as Ix, SpotLightHelper as Bx, PointLightHelper as Lx, HemisphereLightHelper as Ux, DirectionalLightHelper as kx, SkeletonHelper as zx, SRGBColorSpace as Hd, NoToneMapping as $d, NoColorSpace as Gx, LinearToneMapping as Vx, ReinhardToneMapping as Hx, CineonToneMapping as $x, ACESFilmicToneMapping as Wx, AgXToneMapping as jx, NeutralToneMapping as qx, CustomToneMapping as Yx } from "three";
|
|
2
2
|
import { EffectPass as Xx, ShaderPass as Zx } from "postprocessing";
|
|
3
3
|
import { createRafDriver as Kx } from "@theatre/core";
|
|
4
4
|
import eg, { useState as Ne, useRef as Ge, useEffect as wn, useMemo as Sa, Component as Va, createRef as Ai, forwardRef as Qx } from "react";
|
|
@@ -18,7 +18,7 @@ function mt() {
|
|
|
18
18
|
function e_(a) {
|
|
19
19
|
return a.r !== void 0 && a.g !== void 0 && a.b !== void 0;
|
|
20
20
|
}
|
|
21
|
-
function
|
|
21
|
+
function Wd(a) {
|
|
22
22
|
const e = Math.round(a.r * 255), t = Math.round(a.g * 255), s = Math.round(a.b * 255), i = (l) => {
|
|
23
23
|
const c = l.toString(16);
|
|
24
24
|
return c.length === 1 ? "0" + c : c;
|
|
@@ -162,12 +162,12 @@ const r_ = ({ mobileTiers: a = [0, 15, 30, 60], desktopTiers: e = [0, 15, 30, 60
|
|
|
162
162
|
const Lt = (be = be.replace(/\([^)]+\)/, "")).match(/\d+/) || be.match(/(\W|^)([A-Za-z]{1,3})(\W|$)/g);
|
|
163
163
|
return (ot = Lt?.join("").replace(/\W|amd/g, "")) !== null && ot !== void 0 ? ot : "";
|
|
164
164
|
}(T);
|
|
165
|
-
let
|
|
166
|
-
|
|
167
|
-
const
|
|
168
|
-
if (
|
|
165
|
+
let W = k.filter(([, be]) => be === H);
|
|
166
|
+
W.length || (W = k.filter(([be]) => be.includes(T)));
|
|
167
|
+
const $ = W.length;
|
|
168
|
+
if ($ === 0) return;
|
|
169
169
|
const q = T.split(/[.,()\[\]/\s]/g).sort().filter((be, ot, Lt) => ot === 0 || be !== Lt[ot - 1]).join(" ");
|
|
170
|
-
let Z, [we, , , , ue] =
|
|
170
|
+
let Z, [we, , , , ue] = $ > 1 ? W.map((be) => [be, i_(q, be[2])]).sort(([, be], [, ot]) => be - ot)[0][0] : W[0], ge = Number.MAX_VALUE;
|
|
171
171
|
const { devicePixelRatio: ie } = window, Ee = c.width * ie * c.height * ie;
|
|
172
172
|
for (const be of ue) {
|
|
173
173
|
const [ot, Lt] = be, Ir = ot * Lt, Rn = Math.abs(Ee - Ir);
|
|
@@ -1575,8 +1575,10 @@ function M_(a, e) {
|
|
|
1575
1575
|
for (const t in e) a[t] = e[t];
|
|
1576
1576
|
}
|
|
1577
1577
|
function Xe(a, e, t) {
|
|
1578
|
-
if (a === void 0)
|
|
1578
|
+
if (a === void 0) {
|
|
1579
|
+
console.log(`Hermes - Can't set props: ${e}`, t);
|
|
1579
1580
|
return;
|
|
1581
|
+
}
|
|
1580
1582
|
const s = e.split("."), i = s.length;
|
|
1581
1583
|
if (typeof t != "object")
|
|
1582
1584
|
switch (i) {
|
|
@@ -1615,7 +1617,7 @@ function Xe(a, e, t) {
|
|
|
1615
1617
|
r = a[s[0]][s[1]][s[2]][s[3]][s[4]];
|
|
1616
1618
|
break;
|
|
1617
1619
|
}
|
|
1618
|
-
r != null
|
|
1620
|
+
r != null ? M_(r, t) : console.log(`Hermes - Can't set props because target isn't found: ${e}`, t);
|
|
1619
1621
|
}
|
|
1620
1622
|
}
|
|
1621
1623
|
function ig(a) {
|
|
@@ -2002,10 +2004,10 @@ function R_() {
|
|
|
2002
2004
|
var Me = z.displayName || z.name || "";
|
|
2003
2005
|
return Me !== "" ? j + "(" + Me + ")" : j;
|
|
2004
2006
|
}
|
|
2005
|
-
function
|
|
2007
|
+
function W(S) {
|
|
2006
2008
|
return S.displayName || "Context";
|
|
2007
2009
|
}
|
|
2008
|
-
function
|
|
2010
|
+
function $(S) {
|
|
2009
2011
|
if (S == null)
|
|
2010
2012
|
return null;
|
|
2011
2013
|
if (typeof S.tag == "number" && x("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof S == "function")
|
|
@@ -2030,19 +2032,19 @@ function R_() {
|
|
|
2030
2032
|
switch (S.$$typeof) {
|
|
2031
2033
|
case o:
|
|
2032
2034
|
var z = S;
|
|
2033
|
-
return
|
|
2035
|
+
return W(z) + ".Consumer";
|
|
2034
2036
|
case r:
|
|
2035
2037
|
var j = S;
|
|
2036
|
-
return
|
|
2038
|
+
return W(j._context) + ".Provider";
|
|
2037
2039
|
case l:
|
|
2038
2040
|
return H(S, S.render, "ForwardRef");
|
|
2039
2041
|
case u:
|
|
2040
2042
|
var te = S.displayName || null;
|
|
2041
|
-
return te !== null ? te :
|
|
2043
|
+
return te !== null ? te : $(S.type) || "Memo";
|
|
2042
2044
|
case d: {
|
|
2043
2045
|
var Me = S, Fe = Me._payload, ye = Me._init;
|
|
2044
2046
|
try {
|
|
2045
|
-
return
|
|
2047
|
+
return $(ye(Fe));
|
|
2046
2048
|
} catch {
|
|
2047
2049
|
return null;
|
|
2048
2050
|
}
|
|
@@ -2199,8 +2201,8 @@ function R_() {
|
|
|
2199
2201
|
} finally {
|
|
2200
2202
|
Kl = !1, Ir.current = Fe, Lt(), Error.prepareStackTrace = Me;
|
|
2201
2203
|
}
|
|
2202
|
-
var Pn = S ? S.displayName || S.name : "",
|
|
2203
|
-
return typeof S == "function" && Xa.set(S,
|
|
2204
|
+
var Pn = S ? S.displayName || S.name : "", Wi = Pn ? Ya(Pn) : "";
|
|
2205
|
+
return typeof S == "function" && Xa.set(S, Wi), Wi;
|
|
2204
2206
|
}
|
|
2205
2207
|
function L0(S, z, j) {
|
|
2206
2208
|
return Ed(S, !1);
|
|
@@ -2295,7 +2297,7 @@ function R_() {
|
|
|
2295
2297
|
__self: !0,
|
|
2296
2298
|
__source: !0
|
|
2297
2299
|
}, Pd, Dd;
|
|
2298
|
-
function
|
|
2300
|
+
function $0(S) {
|
|
2299
2301
|
if (Br.call(S, "ref")) {
|
|
2300
2302
|
var z = Object.getOwnPropertyDescriptor(S, "ref").get;
|
|
2301
2303
|
if (z && z.isReactWarning)
|
|
@@ -2303,7 +2305,7 @@ function R_() {
|
|
|
2303
2305
|
}
|
|
2304
2306
|
return S.ref !== void 0;
|
|
2305
2307
|
}
|
|
2306
|
-
function
|
|
2308
|
+
function W0(S) {
|
|
2307
2309
|
if (Br.call(S, "key")) {
|
|
2308
2310
|
var z = Object.getOwnPropertyDescriptor(S, "key").get;
|
|
2309
2311
|
if (z && z.isReactWarning)
|
|
@@ -2368,7 +2370,7 @@ function R_() {
|
|
|
2368
2370
|
function Z0(S, z, j, te, Me) {
|
|
2369
2371
|
{
|
|
2370
2372
|
var Fe, ye = {}, fe = null, Mt = null;
|
|
2371
|
-
j !== void 0 && (Rd(j), fe = "" + j),
|
|
2373
|
+
j !== void 0 && (Rd(j), fe = "" + j), W0(z) && (Rd(z.key), fe = "" + z.key), $0(z) && (Mt = z.ref, j0(z, Me));
|
|
2372
2374
|
for (Fe in z)
|
|
2373
2375
|
Br.call(z, Fe) && !H0.hasOwnProperty(Fe) && (ye[Fe] = z[Fe]);
|
|
2374
2376
|
if (S && S.defaultProps) {
|
|
@@ -2399,7 +2401,7 @@ function R_() {
|
|
|
2399
2401
|
function Od() {
|
|
2400
2402
|
{
|
|
2401
2403
|
if (Jl.current) {
|
|
2402
|
-
var S =
|
|
2404
|
+
var S = $(Jl.current.type);
|
|
2403
2405
|
if (S)
|
|
2404
2406
|
return `
|
|
2405
2407
|
|
|
@@ -2434,7 +2436,7 @@ Check the top-level render call using <` + j + ">.");
|
|
|
2434
2436
|
return;
|
|
2435
2437
|
Id[j] = !0;
|
|
2436
2438
|
var te = "";
|
|
2437
|
-
S && S._owner && S._owner !== Jl.current && (te = " It was passed a child from " +
|
|
2439
|
+
S && S._owner && S._owner !== Jl.current && (te = " It was passed a child from " + $(S._owner.type) + "."), Nn(S), x('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', j, te), Nn(null);
|
|
2438
2440
|
}
|
|
2439
2441
|
}
|
|
2440
2442
|
function Ld(S, z) {
|
|
@@ -2471,11 +2473,11 @@ Check the top-level render call using <` + j + ">.");
|
|
|
2471
2473
|
else
|
|
2472
2474
|
return;
|
|
2473
2475
|
if (j) {
|
|
2474
|
-
var te =
|
|
2476
|
+
var te = $(z);
|
|
2475
2477
|
k0(j, S.props, "prop", te, S);
|
|
2476
2478
|
} else if (z.PropTypes !== void 0 && !ec) {
|
|
2477
2479
|
ec = !0;
|
|
2478
|
-
var Me =
|
|
2480
|
+
var Me = $(z);
|
|
2479
2481
|
x("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", Me || "Unknown");
|
|
2480
2482
|
}
|
|
2481
2483
|
typeof z.getDefaultProps == "function" && !z.getDefaultProps.isReactClassApproved && x("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
|
|
@@ -2503,7 +2505,7 @@ Check the top-level render call using <` + j + ">.");
|
|
|
2503
2505
|
var Mt = K0();
|
|
2504
2506
|
Mt ? fe += Mt : fe += Od();
|
|
2505
2507
|
var Ye;
|
|
2506
|
-
S === null ? Ye = "null" : Ql(S) ? Ye = "array" : S !== void 0 && S.$$typeof === e ? (Ye = "<" + (
|
|
2508
|
+
S === null ? Ye = "null" : Ql(S) ? Ye = "array" : S !== void 0 && S.$$typeof === e ? (Ye = "<" + ($(S.type) || "Unknown") + " />", fe = " Did you accidentally export a JSX literal instead of a component?") : Ye = typeof S, x("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", Ye, fe);
|
|
2507
2509
|
}
|
|
2508
2510
|
var Qe = Z0(S, z, j, Me, Fe);
|
|
2509
2511
|
if (Qe == null)
|
|
@@ -2522,17 +2524,17 @@ Check the top-level render call using <` + j + ">.");
|
|
|
2522
2524
|
Ld(ns, S);
|
|
2523
2525
|
}
|
|
2524
2526
|
if (Br.call(z, "key")) {
|
|
2525
|
-
var
|
|
2527
|
+
var Wi = $(S), Ut = Object.keys(z).filter(function(ax) {
|
|
2526
2528
|
return ax !== "key";
|
|
2527
2529
|
}), sc = Ut.length > 0 ? "{key: someKey, " + Ut.join(": ..., ") + ": ...}" : "{key: someKey}";
|
|
2528
|
-
if (!Ud[
|
|
2530
|
+
if (!Ud[Wi + sc]) {
|
|
2529
2531
|
var rx = Ut.length > 0 ? "{" + Ut.join(": ..., ") + ": ...}" : "{}";
|
|
2530
2532
|
x(`A props object containing a "key" prop is being spread into JSX:
|
|
2531
2533
|
let props = %s;
|
|
2532
2534
|
<%s {...props} />
|
|
2533
2535
|
React keys must be passed directly to JSX without using spread:
|
|
2534
2536
|
let props = %s;
|
|
2535
|
-
<%s key={someKey} {...props} />`, sc,
|
|
2537
|
+
<%s key={someKey} {...props} />`, sc, Wi, rx, Wi), Ud[Wi + sc] = !0;
|
|
2536
2538
|
}
|
|
2537
2539
|
}
|
|
2538
2540
|
return S === s ? ex(Qe) : J0(Qe), Qe;
|
|
@@ -2738,7 +2740,7 @@ function rg(a) {
|
|
|
2738
2740
|
const r = a.three.getScene(a.child.uuid);
|
|
2739
2741
|
if (r !== null) {
|
|
2740
2742
|
const o = r.getObjectByProperty("uuid", a.child.uuid);
|
|
2741
|
-
o !== void 0
|
|
2743
|
+
o !== void 0 ? e.current.style.opacity = o.visible ? "1" : "0.25" : console.log(`Hermes - Can't find child: ${a.child.uuid}`);
|
|
2742
2744
|
} else
|
|
2743
2745
|
console.log(`Hermes - Can't find Scene: ${a.child.uuid}`);
|
|
2744
2746
|
}
|
|
@@ -2945,8 +2947,8 @@ function L_(a) {
|
|
|
2945
2947
|
window.removeEventListener("mousemove", T), window.removeEventListener("mouseup", b), x(!1);
|
|
2946
2948
|
}
|
|
2947
2949
|
function T(N) {
|
|
2948
|
-
const k = n.current.getBoundingClientRect(), H = rn(0, 99, N.clientX - k.left) / 99,
|
|
2949
|
-
a.onChange({ target: { value: { x:
|
|
2950
|
+
const k = n.current.getBoundingClientRect(), H = rn(0, 99, N.clientX - k.left) / 99, W = 1 - rn(0, 99, N.clientY - k.top) / 99, $ = vs(Fa(m.min, m.max, H), 3), q = vs(Fa(m.min, m.max, W), 3);
|
|
2951
|
+
a.onChange({ target: { value: { x: $, y: q } } }), d($), f(q);
|
|
2950
2952
|
}
|
|
2951
2953
|
function E() {
|
|
2952
2954
|
const N = Number(s.current.value);
|
|
@@ -3075,10 +3077,10 @@ function V_(a, e, t) {
|
|
|
3075
3077
|
function H_(a, e) {
|
|
3076
3078
|
return a + Math.floor(Math.random() * (e - a + 1));
|
|
3077
3079
|
}
|
|
3078
|
-
function
|
|
3080
|
+
function $_(a, e) {
|
|
3079
3081
|
return a + Math.random() * (e - a);
|
|
3080
3082
|
}
|
|
3081
|
-
function
|
|
3083
|
+
function W_(a) {
|
|
3082
3084
|
return a * (0.5 - Math.random());
|
|
3083
3085
|
}
|
|
3084
3086
|
function j_(a) {
|
|
@@ -3309,7 +3311,7 @@ const K_ = {
|
|
|
3309
3311
|
* @param {number} high - The upper value boundary
|
|
3310
3312
|
* @return {number} A random float.
|
|
3311
3313
|
*/
|
|
3312
|
-
randFloat:
|
|
3314
|
+
randFloat: $_,
|
|
3313
3315
|
/**
|
|
3314
3316
|
* Returns a random integer from `<-range/2, range/2>` interval.
|
|
3315
3317
|
*
|
|
@@ -3318,7 +3320,7 @@ const K_ = {
|
|
|
3318
3320
|
* @param {number} range - Defines the value range.
|
|
3319
3321
|
* @return {number} A random float.
|
|
3320
3322
|
*/
|
|
3321
|
-
randFloatSpread:
|
|
3323
|
+
randFloatSpread: W_,
|
|
3322
3324
|
/**
|
|
3323
3325
|
* Returns a deterministic pseudo-random float in the interval `[0, 1]`.
|
|
3324
3326
|
*
|
|
@@ -3909,7 +3911,7 @@ const sb = [
|
|
|
3909
3911
|
},
|
|
3910
3912
|
{
|
|
3911
3913
|
title: "One Minus Dst Color",
|
|
3912
|
-
value:
|
|
3914
|
+
value: $m
|
|
3913
3915
|
},
|
|
3914
3916
|
{
|
|
3915
3917
|
title: "Src Alpha Saturate",
|
|
@@ -3917,7 +3919,7 @@ const sb = [
|
|
|
3917
3919
|
},
|
|
3918
3920
|
{
|
|
3919
3921
|
title: "Constant Color",
|
|
3920
|
-
value:
|
|
3922
|
+
value: Wm
|
|
3921
3923
|
},
|
|
3922
3924
|
{
|
|
3923
3925
|
title: "One Minus Constant Color",
|
|
@@ -3970,11 +3972,11 @@ const sb = [
|
|
|
3970
3972
|
},
|
|
3971
3973
|
{
|
|
3972
3974
|
title: "One Minus Dst Color",
|
|
3973
|
-
value:
|
|
3975
|
+
value: $m
|
|
3974
3976
|
},
|
|
3975
3977
|
{
|
|
3976
3978
|
title: "Constant Color",
|
|
3977
|
-
value:
|
|
3979
|
+
value: Wm
|
|
3978
3980
|
},
|
|
3979
3981
|
{
|
|
3980
3982
|
title: "One Minus Constant Color",
|
|
@@ -4476,7 +4478,7 @@ function fb(a) {
|
|
|
4476
4478
|
}
|
|
4477
4479
|
function qo(a) {
|
|
4478
4480
|
let e = a.value;
|
|
4479
|
-
e !== void 0 && (e.isColor !== void 0 ? e =
|
|
4481
|
+
e !== void 0 && (e.isColor !== void 0 ? e = Wd(a.value) : a.type === "color" && (e = Wd(new vn().setStyle(a.value, Pa))));
|
|
4480
4482
|
const [t, s] = Ne(e), i = Ge(null), n = (c) => {
|
|
4481
4483
|
let h = c.target.value;
|
|
4482
4484
|
if (a.type === "boolean")
|
|
@@ -4982,7 +4984,7 @@ class As {
|
|
|
4982
4984
|
return t.delete(e[e.length - 1]);
|
|
4983
4985
|
}
|
|
4984
4986
|
}
|
|
4985
|
-
const lg = "177", xb = 0, _b = 1, bb = 2, Tb = 0, Sb = 1, Yo = 3, ii = 0,
|
|
4987
|
+
const lg = "177", xb = 0, _b = 1, bb = 2, Tb = 0, Sb = 1, Yo = 3, ii = 0, Wt = 1, dr = 2, vr = 0, ni = 1, cl = 2, hl = 3, ul = 4, wa = 5, Es = 100, cg = 101, hg = 102, vb = 103, wb = 104, Ri = 200, ug = 201, dg = 202, pg = 203, dl = 204, pl = 205, fg = 206, mg = 207, gg = 208, yg = 209, xg = 210, _g = 0, bg = 1, Tg = 2, fl = 3, Sg = 4, vg = 5, wg = 6, Eg = 7, Pl = 0, Eb = 1, Cb = 2, pr = 0, Mb = 1, Ab = 2, Rb = 3, Nb = 4, Pb = 6, Db = 7, wu = 300, Oa = 301, ml = 302, Eu = 303, Cu = 304, Uh = 306, wr = 1e3, Ii = 1001, Er = 1002, ut = 1003, Cg = 1004, Ia = 1005, is = 1006, kh = 1007, ri = 1008, Ft = 1009, Ea = 1010, Ca = 1011, rr = 1012, Nt = 1013, Ze = 1014, ss = 1015, cs = 1016, Fb = 1017, Ob = 1018, Li = 1020, Mg = 35902, Ib = 1021, Mu = 1022, hs = 1023, Gs = 1026, ai = 1027, Au = 1028, Ru = 1029, mn = 1030, Nu = 1031, Bb = 1032, Pu = 1033, oc = 33776, Xo = 33777, Zo = 33778, Ko = 33779, ap = 35840, op = 35841, lp = 35842, cp = 35843, hp = 36196, zh = 37492, Gh = 37496, Vh = 37808, Hh = 37809, $h = 37810, Wh = 37811, jh = 37812, qh = 37813, Yh = 37814, Xh = 37815, Zh = 37816, Kh = 37817, Qh = 37818, Jh = 37819, eu = 37820, tu = 37821, lc = 36492, Lb = 36283, up = 36284, dp = 36285, pp = 36286, Ui = 0, Ub = 1, ui = "", es = "srgb", fr = "srgb-linear", gl = "linear", se = "srgb", kb = 0, on = 7680, zb = 7681, Gb = 7682, Vb = 7683, Hb = 34055, $b = 34056, Wb = 5386, jb = 512, qb = 513, Yb = 514, Xb = 515, Zb = 516, Kb = 517, Qb = 518, su = 519, Ag = 512, Du = 513, Rg = 514, Ng = 515, Pg = 516, Dg = 517, Fg = 518, Og = 519, yl = 35044, ar = 35048, Vt = 2e3, ki = 2001;
|
|
4986
4988
|
class qt {
|
|
4987
4989
|
/**
|
|
4988
4990
|
* Constructs a new 3x3 matrix. The arguments are supposed to be
|
|
@@ -7660,8 +7662,8 @@ class Be {
|
|
|
7660
7662
|
* @return {Matrix4} A reference to this matrix.
|
|
7661
7663
|
*/
|
|
7662
7664
|
multiplyMatrices(e, t) {
|
|
7663
|
-
const s = e.elements, i = t.elements, n = this.elements, r = s[0], o = s[4], l = s[8], c = s[12], h = s[1], u = s[5], d = s[9], p = s[13], f = s[2], m = s[6], y = s[10], g = s[14], x = s[3], _ = s[7], b = s[11], T = s[15], E = i[0], v = i[4], A = i[8], N = i[12], k = i[1], H = i[5],
|
|
7664
|
-
return n[0] = r * E + o * k + l * q + c * ge, n[4] = r * v + o * H + l * Z + c * ie, n[8] = r * A + o *
|
|
7665
|
+
const s = e.elements, i = t.elements, n = this.elements, r = s[0], o = s[4], l = s[8], c = s[12], h = s[1], u = s[5], d = s[9], p = s[13], f = s[2], m = s[6], y = s[10], g = s[14], x = s[3], _ = s[7], b = s[11], T = s[15], E = i[0], v = i[4], A = i[8], N = i[12], k = i[1], H = i[5], W = i[9], $ = i[13], q = i[2], Z = i[6], we = i[10], ue = i[14], ge = i[3], ie = i[7], Ee = i[11], ze = i[15];
|
|
7666
|
+
return n[0] = r * E + o * k + l * q + c * ge, n[4] = r * v + o * H + l * Z + c * ie, n[8] = r * A + o * W + l * we + c * Ee, n[12] = r * N + o * $ + l * ue + c * ze, n[1] = h * E + u * k + d * q + p * ge, n[5] = h * v + u * H + d * Z + p * ie, n[9] = h * A + u * W + d * we + p * Ee, n[13] = h * N + u * $ + d * ue + p * ze, n[2] = f * E + m * k + y * q + g * ge, n[6] = f * v + m * H + y * Z + g * ie, n[10] = f * A + m * W + y * we + g * Ee, n[14] = f * N + m * $ + y * ue + g * ze, n[3] = x * E + _ * k + b * q + T * ge, n[7] = x * v + _ * H + b * Z + T * ie, n[11] = x * A + _ * W + b * we + T * Ee, n[15] = x * N + _ * $ + b * ue + T * ze, this;
|
|
7665
7667
|
}
|
|
7666
7668
|
/**
|
|
7667
7669
|
* Multiplies every component of the matrix by the given scalar.
|
|
@@ -10300,7 +10302,7 @@ class xT {
|
|
|
10300
10302
|
this.reset(), this.calls = 0, this.render.calls = 0, this.compute.calls = 0, this.render.timestamp = 0, this.compute.timestamp = 0, this.memory.geometries = 0, this.memory.textures = 0;
|
|
10301
10303
|
}
|
|
10302
10304
|
}
|
|
10303
|
-
class
|
|
10305
|
+
class $g {
|
|
10304
10306
|
/**
|
|
10305
10307
|
* Constructs a new pipeline.
|
|
10306
10308
|
*
|
|
@@ -10310,7 +10312,7 @@ class Wg {
|
|
|
10310
10312
|
this.cacheKey = e, this.usedTimes = 0;
|
|
10311
10313
|
}
|
|
10312
10314
|
}
|
|
10313
|
-
class _T extends
|
|
10315
|
+
class _T extends $g {
|
|
10314
10316
|
/**
|
|
10315
10317
|
* Constructs a new render pipeline.
|
|
10316
10318
|
*
|
|
@@ -10322,7 +10324,7 @@ class _T extends Wg {
|
|
|
10322
10324
|
super(e), this.vertexProgram = t, this.fragmentProgram = s;
|
|
10323
10325
|
}
|
|
10324
10326
|
}
|
|
10325
|
-
class bT extends
|
|
10327
|
+
class bT extends $g {
|
|
10326
10328
|
/**
|
|
10327
10329
|
* Constructs a new render pipeline.
|
|
10328
10330
|
*
|
|
@@ -10818,10 +10820,10 @@ class AT {
|
|
|
10818
10820
|
* @return {number} The cache key.
|
|
10819
10821
|
*/
|
|
10820
10822
|
getCacheKey() {
|
|
10821
|
-
return
|
|
10823
|
+
return Wg(this);
|
|
10822
10824
|
}
|
|
10823
10825
|
}
|
|
10824
|
-
function
|
|
10826
|
+
function Wg(a) {
|
|
10825
10827
|
const { textures: e, activeCubeFace: t } = a, s = [t];
|
|
10826
10828
|
for (const i of e)
|
|
10827
10829
|
s.push(i.id);
|
|
@@ -12474,7 +12476,7 @@ const ro = {
|
|
|
12474
12476
|
analyze: "setup",
|
|
12475
12477
|
generate: "analyze"
|
|
12476
12478
|
};
|
|
12477
|
-
let
|
|
12479
|
+
let $T = 0;
|
|
12478
12480
|
class ae extends En {
|
|
12479
12481
|
static get type() {
|
|
12480
12482
|
return "Node";
|
|
@@ -12485,7 +12487,7 @@ class ae extends En {
|
|
|
12485
12487
|
* @param {?string} nodeType - The node type.
|
|
12486
12488
|
*/
|
|
12487
12489
|
constructor(e = null) {
|
|
12488
|
-
super(), this.nodeType = e, this.updateType = he.NONE, this.updateBeforeType = he.NONE, this.updateAfterType = he.NONE, this.uuid = K_.generateUUID(), this.version = 0, this.global = !1, this.parents = !1, this.isNode = !0, this._cacheKey = null, this._cacheKeyVersion = 0, Object.defineProperty(this, "id", { value:
|
|
12490
|
+
super(), this.nodeType = e, this.updateType = he.NONE, this.updateBeforeType = he.NONE, this.updateAfterType = he.NONE, this.uuid = K_.generateUUID(), this.version = 0, this.global = !1, this.parents = !1, this.isNode = !0, this._cacheKey = null, this._cacheKeyVersion = 0, Object.defineProperty(this, "id", { value: $T++ });
|
|
12489
12491
|
}
|
|
12490
12492
|
/**
|
|
12491
12493
|
* Set this property to `true` when the node should be regenerated.
|
|
@@ -13037,7 +13039,7 @@ class jg extends ae {
|
|
|
13037
13039
|
return e.format(n, i, t);
|
|
13038
13040
|
}
|
|
13039
13041
|
}
|
|
13040
|
-
class
|
|
13042
|
+
class WT extends nt {
|
|
13041
13043
|
static get type() {
|
|
13042
13044
|
return "JoinNode";
|
|
13043
13045
|
}
|
|
@@ -13465,7 +13467,7 @@ const Ol = { bool: ku, uint: zu, ints: Gu, float: Fl }, Ip = new Map([...ku, ...
|
|
|
13465
13467
|
return aS(i) === a ? U(i) : U(new jg(i, a));
|
|
13466
13468
|
}
|
|
13467
13469
|
const s = t.map((i) => nu(i));
|
|
13468
|
-
return U(new
|
|
13470
|
+
return U(new WT(s, a));
|
|
13469
13471
|
};
|
|
13470
13472
|
}, Bp = (a) => typeof a == "object" && a !== null ? a.value : a, oS = (a) => a != null ? a.nodeType || a.convertTo || (typeof a == "string" ? a : null) : null;
|
|
13471
13473
|
function ma(a, e) {
|
|
@@ -13675,8 +13677,8 @@ class Qg extends ae {
|
|
|
13675
13677
|
super.deserialize(e), this.name = e.name, this.version = e.version, this.shared = e.shared;
|
|
13676
13678
|
}
|
|
13677
13679
|
}
|
|
13678
|
-
const wS = (a) => new Qg(a),
|
|
13679
|
-
class
|
|
13680
|
+
const wS = (a) => new Qg(a), $u = (a, e = 0) => new Qg(a, !0, e), ES = /* @__PURE__ */ $u("frame"), Q = /* @__PURE__ */ $u("render"), Jg = /* @__PURE__ */ wS("object");
|
|
13681
|
+
class $a extends Uu {
|
|
13680
13682
|
static get type() {
|
|
13681
13683
|
return "UniformNode";
|
|
13682
13684
|
}
|
|
@@ -13742,7 +13744,7 @@ class Wa extends Uu {
|
|
|
13742
13744
|
}
|
|
13743
13745
|
const J = (a, e) => {
|
|
13744
13746
|
const t = oS(e || a), s = a && a.isNode === !0 ? a.node && a.node.value || a.value : a;
|
|
13745
|
-
return U(new
|
|
13747
|
+
return U(new $a(s, t));
|
|
13746
13748
|
};
|
|
13747
13749
|
class Re extends ae {
|
|
13748
13750
|
static get type() {
|
|
@@ -13766,7 +13768,7 @@ class Re extends ae {
|
|
|
13766
13768
|
return this.varying === !0 ? (t = e.getVaryingFromNode(this, this.name), t.needsInterpolation = !0) : t = e.getVarFromNode(this, this.name), e.getPropertyName(t);
|
|
13767
13769
|
}
|
|
13768
13770
|
}
|
|
13769
|
-
const ey = (a, e) => U(new Re(a, e)), Sl = (a, e) => U(new Re(a, e, !0)), Se = /* @__PURE__ */ G(Re, "vec4", "DiffuseColor"), Up = /* @__PURE__ */ G(Re, "vec3", "EmissiveColor"), ei = /* @__PURE__ */ G(Re, "float", "Roughness"), vl = /* @__PURE__ */ G(Re, "float", "Metalness"), ru = /* @__PURE__ */ G(Re, "float", "Clearcoat"), wl = /* @__PURE__ */ G(Re, "float", "ClearcoatRoughness"), lr = /* @__PURE__ */ G(Re, "vec3", "Sheen"),
|
|
13771
|
+
const ey = (a, e) => U(new Re(a, e)), Sl = (a, e) => U(new Re(a, e, !0)), Se = /* @__PURE__ */ G(Re, "vec4", "DiffuseColor"), Up = /* @__PURE__ */ G(Re, "vec3", "EmissiveColor"), ei = /* @__PURE__ */ G(Re, "float", "Roughness"), vl = /* @__PURE__ */ G(Re, "float", "Metalness"), ru = /* @__PURE__ */ G(Re, "float", "Clearcoat"), wl = /* @__PURE__ */ G(Re, "float", "ClearcoatRoughness"), lr = /* @__PURE__ */ G(Re, "vec3", "Sheen"), Wu = /* @__PURE__ */ G(Re, "float", "SheenRoughness"), ju = /* @__PURE__ */ G(Re, "float", "Iridescence"), ty = /* @__PURE__ */ G(Re, "float", "IridescenceIOR"), sy = /* @__PURE__ */ G(Re, "float", "IridescenceThickness"), au = /* @__PURE__ */ G(Re, "float", "AlphaT"), ln = /* @__PURE__ */ G(Re, "float", "Anisotropy"), Qo = /* @__PURE__ */ G(Re, "vec3", "AnisotropyT"), xr = /* @__PURE__ */ G(Re, "vec3", "AnisotropyB"), Qt = /* @__PURE__ */ G(Re, "color", "SpecularColor"), El = /* @__PURE__ */ G(Re, "float", "SpecularF90"), ou = /* @__PURE__ */ G(Re, "float", "Shininess"), Ma = /* @__PURE__ */ G(Re, "vec4", "Output"), yc = /* @__PURE__ */ G(Re, "float", "dashSize"), kp = /* @__PURE__ */ G(Re, "float", "gapSize"), Jo = /* @__PURE__ */ G(Re, "float", "IOR"), lu = /* @__PURE__ */ G(Re, "float", "Transmission"), iy = /* @__PURE__ */ G(Re, "float", "Thickness"), ny = /* @__PURE__ */ G(Re, "float", "AttenuationDistance"), ry = /* @__PURE__ */ G(Re, "color", "AttenuationColor"), ay = /* @__PURE__ */ G(Re, "float", "Dispersion");
|
|
13770
13772
|
class CS extends nt {
|
|
13771
13773
|
static get type() {
|
|
13772
13774
|
return "FunctionCallNode";
|
|
@@ -13833,7 +13835,7 @@ const AS = {
|
|
|
13833
13835
|
">=": "greaterThanEqual",
|
|
13834
13836
|
"%": "mod"
|
|
13835
13837
|
};
|
|
13836
|
-
class
|
|
13838
|
+
class We extends nt {
|
|
13837
13839
|
static get type() {
|
|
13838
13840
|
return "OperatorNode";
|
|
13839
13841
|
}
|
|
@@ -13847,9 +13849,9 @@ class $e extends nt {
|
|
|
13847
13849
|
*/
|
|
13848
13850
|
constructor(e, t, s, ...i) {
|
|
13849
13851
|
if (super(), i.length > 0) {
|
|
13850
|
-
let n = new
|
|
13852
|
+
let n = new We(e, t, s);
|
|
13851
13853
|
for (let r = 0; r < i.length - 1; r++)
|
|
13852
|
-
n = new
|
|
13854
|
+
n = new We(e, n, i[r]);
|
|
13853
13855
|
t = n, s = i[i.length - 1];
|
|
13854
13856
|
}
|
|
13855
13857
|
this.op = e, this.aNode = t, this.bNode = s, this.isOperatorNode = !0;
|
|
@@ -13934,7 +13936,7 @@ class $e extends nt {
|
|
|
13934
13936
|
super.deserialize(e), this.op = e.op;
|
|
13935
13937
|
}
|
|
13936
13938
|
}
|
|
13937
|
-
const Bt = /* @__PURE__ */ L(
|
|
13939
|
+
const Bt = /* @__PURE__ */ L(We, "+").setParameterLength(2, 1 / 0).setName("add"), Pt = /* @__PURE__ */ L(We, "-").setParameterLength(2, 1 / 0).setName("sub"), pe = /* @__PURE__ */ L(We, "*").setParameterLength(2, 1 / 0).setName("mul"), Hs = /* @__PURE__ */ L(We, "/").setParameterLength(2, 1 / 0).setName("div"), Bl = /* @__PURE__ */ L(We, "%").setParameterLength(2).setName("mod"), oy = /* @__PURE__ */ L(We, "==").setParameterLength(2).setName("equal"), RS = /* @__PURE__ */ L(We, "!=").setParameterLength(2).setName("notEqual"), NS = /* @__PURE__ */ L(We, "<").setParameterLength(2).setName("lessThan"), PS = /* @__PURE__ */ L(We, ">").setParameterLength(2).setName("greaterThan"), DS = /* @__PURE__ */ L(We, "<=").setParameterLength(2).setName("lessThanEqual"), FS = /* @__PURE__ */ L(We, ">=").setParameterLength(2).setName("greaterThanEqual"), OS = /* @__PURE__ */ L(We, "&&").setParameterLength(2, 1 / 0).setName("and"), IS = /* @__PURE__ */ L(We, "||").setParameterLength(2, 1 / 0).setName("or"), BS = /* @__PURE__ */ L(We, "!").setParameterLength(1).setName("not"), LS = /* @__PURE__ */ L(We, "^^").setParameterLength(2).setName("xor"), US = /* @__PURE__ */ L(We, "&").setParameterLength(2).setName("bitAnd"), kS = /* @__PURE__ */ L(We, "~").setParameterLength(2).setName("bitNot"), zS = /* @__PURE__ */ L(We, "|").setParameterLength(2).setName("bitOr"), GS = /* @__PURE__ */ L(We, "^").setParameterLength(2).setName("bitXor"), VS = /* @__PURE__ */ L(We, "<<").setParameterLength(2).setName("shiftLeft"), HS = /* @__PURE__ */ L(We, ">>").setParameterLength(2).setName("shiftRight"), $S = B(([a]) => (a.addAssign(1), a)), WS = B(([a]) => (a.subAssign(1), a)), jS = /* @__PURE__ */ B(([a]) => {
|
|
13938
13940
|
const e = ke(a).toConst();
|
|
13939
13941
|
return a.addAssign(1), e;
|
|
13940
13942
|
}), qS = /* @__PURE__ */ B(([a]) => {
|
|
@@ -13962,8 +13964,8 @@ F("bitOr", zS);
|
|
|
13962
13964
|
F("bitXor", GS);
|
|
13963
13965
|
F("shiftLeft", VS);
|
|
13964
13966
|
F("shiftRight", HS);
|
|
13965
|
-
F("incrementBefore",
|
|
13966
|
-
F("decrementBefore",
|
|
13967
|
+
F("incrementBefore", $S);
|
|
13968
|
+
F("decrementBefore", WS);
|
|
13967
13969
|
F("increment", jS);
|
|
13968
13970
|
F("decrement", qS);
|
|
13969
13971
|
const YS = (a, e) => (console.warn('THREE.TSL: "remainder()" is deprecated. Use "mod( int( ... ) )" instead.'), Bl(a, e)), XS = (a, e) => (console.warn('THREE.TSL: "modInt()" is deprecated. Use "mod( int( ... ) )" instead.'), Bl(ke(a), ke(e)));
|
|
@@ -15042,7 +15044,7 @@ class vy {
|
|
|
15042
15044
|
};
|
|
15043
15045
|
}
|
|
15044
15046
|
}
|
|
15045
|
-
class
|
|
15047
|
+
class $v extends Uu {
|
|
15046
15048
|
static get type() {
|
|
15047
15049
|
return "BufferAttributeNode";
|
|
15048
15050
|
}
|
|
@@ -15134,7 +15136,7 @@ class Wv extends Uu {
|
|
|
15134
15136
|
return this.instanced = e, this;
|
|
15135
15137
|
}
|
|
15136
15138
|
}
|
|
15137
|
-
const td = (a, e = null, t = 0, s = 0) => U(new
|
|
15139
|
+
const td = (a, e = null, t = 0, s = 0) => U(new $v(a, e, t, s)), Wv = (a, e = null, t = 0, s = 0) => td(a, e, t, s).setUsage(ar), zp = (a, e = null, t = 0, s = 0) => td(a, e, t, s).setInstanced(!0), Gp = (a, e = null, t = 0, s = 0) => Wv(a, e, t, s).setInstanced(!0);
|
|
15138
15140
|
F("toAttribute", (a) => td(a.value));
|
|
15139
15141
|
class jv extends ae {
|
|
15140
15142
|
static get type() {
|
|
@@ -15732,7 +15734,7 @@ class cw extends ae {
|
|
|
15732
15734
|
}
|
|
15733
15735
|
}
|
|
15734
15736
|
const Cs = (...a) => U(new cw(gr(a, "int"))).toStack(), hw = () => Ar("break").toStack();
|
|
15735
|
-
class
|
|
15737
|
+
class Wa {
|
|
15736
15738
|
/**
|
|
15737
15739
|
* Constructs a new bounding box.
|
|
15738
15740
|
*
|
|
@@ -15999,7 +16001,7 @@ class $a {
|
|
|
15999
16001
|
intersectsTriangle(e) {
|
|
16000
16002
|
if (this.isEmpty())
|
|
16001
16003
|
return !1;
|
|
16002
|
-
this.getCenter(
|
|
16004
|
+
this.getCenter($r), oo.subVectors(this.max, $r), kn.subVectors(e.a, $r), zn.subVectors(e.b, $r), Gn.subVectors(e.c, $r), bi.subVectors(zn, kn), Ti.subVectors(Gn, zn), qi.subVectors(kn, Gn);
|
|
16003
16005
|
let t = [
|
|
16004
16006
|
0,
|
|
16005
16007
|
-bi.z,
|
|
@@ -16141,7 +16143,7 @@ const Ys = [
|
|
|
16141
16143
|
/* @__PURE__ */ new R(),
|
|
16142
16144
|
/* @__PURE__ */ new R(),
|
|
16143
16145
|
/* @__PURE__ */ new R()
|
|
16144
|
-
], xs = /* @__PURE__ */ new R(), ao = /* @__PURE__ */ new
|
|
16146
|
+
], xs = /* @__PURE__ */ new R(), ao = /* @__PURE__ */ new Wa(), kn = /* @__PURE__ */ new R(), zn = /* @__PURE__ */ new R(), Gn = /* @__PURE__ */ new R(), bi = /* @__PURE__ */ new R(), Ti = /* @__PURE__ */ new R(), qi = /* @__PURE__ */ new R(), $r = /* @__PURE__ */ new R(), oo = /* @__PURE__ */ new R(), lo = /* @__PURE__ */ new R(), Yi = /* @__PURE__ */ new R();
|
|
16145
16147
|
function _c(a, e, t, s, i) {
|
|
16146
16148
|
for (let n = 0, r = a.length - 3; n <= r; n += 3) {
|
|
16147
16149
|
Yi.fromArray(a, n);
|
|
@@ -16151,7 +16153,7 @@ function _c(a, e, t, s, i) {
|
|
|
16151
16153
|
}
|
|
16152
16154
|
return !0;
|
|
16153
16155
|
}
|
|
16154
|
-
const uw = /* @__PURE__ */ new
|
|
16156
|
+
const uw = /* @__PURE__ */ new Wa(), Wr = /* @__PURE__ */ new R(), bc = /* @__PURE__ */ new R();
|
|
16155
16157
|
class Ul {
|
|
16156
16158
|
/**
|
|
16157
16159
|
* Constructs a new sphere.
|
|
@@ -16316,11 +16318,11 @@ class Ul {
|
|
|
16316
16318
|
expandByPoint(e) {
|
|
16317
16319
|
if (this.isEmpty())
|
|
16318
16320
|
return this.center.copy(e), this.radius = 0, this;
|
|
16319
|
-
|
|
16320
|
-
const t =
|
|
16321
|
+
Wr.subVectors(e, this.center);
|
|
16322
|
+
const t = Wr.lengthSq();
|
|
16321
16323
|
if (t > this.radius * this.radius) {
|
|
16322
16324
|
const s = Math.sqrt(t), i = (s - this.radius) * 0.5;
|
|
16323
|
-
this.center.addScaledVector(
|
|
16325
|
+
this.center.addScaledVector(Wr, i / s), this.radius += i;
|
|
16324
16326
|
}
|
|
16325
16327
|
return this;
|
|
16326
16328
|
}
|
|
@@ -16331,7 +16333,7 @@ class Ul {
|
|
|
16331
16333
|
* @return {Sphere} A reference to this sphere.
|
|
16332
16334
|
*/
|
|
16333
16335
|
union(e) {
|
|
16334
|
-
return e.isEmpty() ? this : this.isEmpty() ? (this.copy(e), this) : (this.center.equals(e.center) === !0 ? this.radius = Math.max(this.radius, e.radius) : (bc.subVectors(e.center, this.center).setLength(e.radius), this.expandByPoint(
|
|
16336
|
+
return e.isEmpty() ? this : this.isEmpty() ? (this.copy(e), this) : (this.center.equals(e.center) === !0 ? this.radius = Math.max(this.radius, e.radius) : (bc.subVectors(e.center, this.center).setLength(e.radius), this.expandByPoint(Wr.copy(e.center).add(bc)), this.expandByPoint(Wr.copy(e.center).sub(bc))), this);
|
|
16335
16337
|
}
|
|
16336
16338
|
/**
|
|
16337
16339
|
* Returns `true` if this sphere is equal with the given one.
|
|
@@ -16383,7 +16385,7 @@ class Pe extends ae {
|
|
|
16383
16385
|
* @param {?Object3D} [object3d=null] - The 3D object.
|
|
16384
16386
|
*/
|
|
16385
16387
|
constructor(e, t = null) {
|
|
16386
|
-
super(), this.scope = e, this.object3d = t, this.updateType = he.OBJECT, this.uniformNode = new
|
|
16388
|
+
super(), this.scope = e, this.object3d = t, this.updateType = he.OBJECT, this.uniformNode = new $a(null);
|
|
16387
16389
|
}
|
|
16388
16390
|
/**
|
|
16389
16391
|
* Overwritten since the node type is inferred from the scope.
|
|
@@ -16447,7 +16449,7 @@ Pe.VIEW_POSITION = "viewPosition";
|
|
|
16447
16449
|
Pe.DIRECTION = "direction";
|
|
16448
16450
|
Pe.RADIUS = "radius";
|
|
16449
16451
|
const dw = /* @__PURE__ */ L(Pe, Pe.POSITION).setParameterLength(1);
|
|
16450
|
-
class Cy extends
|
|
16452
|
+
class Cy extends $a {
|
|
16451
16453
|
static get type() {
|
|
16452
16454
|
return "BufferNode";
|
|
16453
16455
|
}
|
|
@@ -16624,7 +16626,7 @@ class mw extends ae {
|
|
|
16624
16626
|
return this.name;
|
|
16625
16627
|
}
|
|
16626
16628
|
}
|
|
16627
|
-
const kl = L(mw).setParameterLength(1), Ay = /* @__PURE__ */ J(0, "uint").label("u_cameraIndex").setGroup(
|
|
16629
|
+
const kl = L(mw).setParameterLength(1), Ay = /* @__PURE__ */ J(0, "uint").label("u_cameraIndex").setGroup($u("cameraIndex")).toVarying("v_cameraIndex"), un = /* @__PURE__ */ J("float").label("cameraNear").setGroup(Q).onRenderUpdate(({ camera: a }) => a.near), dn = /* @__PURE__ */ J("float").label("cameraFar").setGroup(Q).onRenderUpdate(({ camera: a }) => a.far), id = /* @__PURE__ */ B(({ camera: a }) => {
|
|
16628
16630
|
let e;
|
|
16629
16631
|
if (a.isArrayCamera && a.cameras.length > 0) {
|
|
16630
16632
|
const t = [];
|
|
@@ -16673,10 +16675,10 @@ gs.POSITION;
|
|
|
16673
16675
|
gs.SCALE;
|
|
16674
16676
|
gs.VIEW_POSITION;
|
|
16675
16677
|
gs.RADIUS;
|
|
16676
|
-
const yw = /* @__PURE__ */ J(new qt()).onObjectUpdate(({ object: a }, e) => e.value.getNormalMatrix(a.matrixWorld)), zl = /* @__PURE__ */ B((a) => a.renderer.overrideNodes.modelViewMatrix || xw).once()().toVar("modelViewMatrix"), xw = /* @__PURE__ */ gi.mul(Sn), Hp = /* @__PURE__ */ B((a) => (a.context.isHighPrecisionModelViewMatrix = !0, J("mat4").onObjectUpdate(({ object: e, camera: t }) => e.modelViewMatrix.multiplyMatrices(t.matrixWorldInverse, e.matrixWorld)))).once()().toVar("highpModelViewMatrix"),
|
|
16678
|
+
const yw = /* @__PURE__ */ J(new qt()).onObjectUpdate(({ object: a }, e) => e.value.getNormalMatrix(a.matrixWorld)), zl = /* @__PURE__ */ B((a) => a.renderer.overrideNodes.modelViewMatrix || xw).once()().toVar("modelViewMatrix"), xw = /* @__PURE__ */ gi.mul(Sn), Hp = /* @__PURE__ */ B((a) => (a.context.isHighPrecisionModelViewMatrix = !0, J("mat4").onObjectUpdate(({ object: e, camera: t }) => e.modelViewMatrix.multiplyMatrices(t.matrixWorldInverse, e.matrixWorld)))).once()().toVar("highpModelViewMatrix"), $p = /* @__PURE__ */ B((a) => {
|
|
16677
16679
|
const e = a.context.isHighPrecisionModelViewMatrix;
|
|
16678
16680
|
return J("mat3").onObjectUpdate(({ object: t, camera: s }) => (e !== !0 && t.modelViewMatrix.multiplyMatrices(s.matrixWorldInverse, t.matrixWorld), t.normalMatrix.getNormalMatrix(t.modelViewMatrix)));
|
|
16679
|
-
}).once()().toVar("highpModelNormalViewMatrix"), Gl = /* @__PURE__ */ Gi("position", "vec3"), vt = /* @__PURE__ */ Gl.toVarying("positionLocal"),
|
|
16681
|
+
}).once()().toVar("highpModelNormalViewMatrix"), Gl = /* @__PURE__ */ Gi("position", "vec3"), vt = /* @__PURE__ */ Gl.toVarying("positionLocal"), Wp = /* @__PURE__ */ Gl.toVarying("positionPrevious"), ka = /* @__PURE__ */ B((a) => Sn.mul(vt).xyz.toVarying(a.getNamespace("v_positionWorld")), "vec3").once("POSITION")(), Ry = /* @__PURE__ */ B((a) => vt.transformDirection(Sn).toVarying(a.getNamespace("v_positionWorldDirection")).normalize().toVar("positionWorldDirection"), "vec3").once("POSITION")(), st = /* @__PURE__ */ B((a) => a.context.setupPositionView().toVarying(a.getNamespace("v_positionView")), "vec3").once("POSITION")(), qe = /* @__PURE__ */ st.negate().toVarying("v_positionViewDirection").normalize().toVar("positionViewDirection");
|
|
16680
16682
|
class _w extends nt {
|
|
16681
16683
|
static get type() {
|
|
16682
16684
|
return "EquirectUVNode";
|
|
@@ -16707,14 +16709,14 @@ class bw extends ae {
|
|
|
16707
16709
|
}
|
|
16708
16710
|
generate(e) {
|
|
16709
16711
|
const { renderer: t, material: s } = e;
|
|
16710
|
-
return t.coordinateSystem === Vt && s.side ===
|
|
16712
|
+
return t.coordinateSystem === Vt && s.side === Wt ? "false" : e.getFrontFacing();
|
|
16711
16713
|
}
|
|
16712
16714
|
}
|
|
16713
|
-
const Tw = /* @__PURE__ */ G(bw), Vl = /* @__PURE__ */ O(Tw).mul(2).sub(1), Py = /* @__PURE__ */ Gi("normal", "vec3"),
|
|
16715
|
+
const Tw = /* @__PURE__ */ G(bw), Vl = /* @__PURE__ */ O(Tw).mul(2).sub(1), Py = /* @__PURE__ */ Gi("normal", "vec3"), $s = /* @__PURE__ */ B((a) => a.geometry.hasAttribute("normal") === !1 ? (console.warn('THREE.TSL: Vertex attribute "normal" not found on geometry.'), I(0, 1, 0)) : Py, "vec3").once()().toVar("normalLocal"), Sw = /* @__PURE__ */ st.dFdx().cross(st.dFdy()).normalize().toVar("normalFlat"), Ws = /* @__PURE__ */ B((a) => {
|
|
16714
16716
|
let e;
|
|
16715
|
-
return a.material.flatShading === !0 ? e = Sw : e = Rs(Dy(
|
|
16717
|
+
return a.material.flatShading === !0 ? e = Sw : e = Rs(Dy($s), "v_normalView").normalize(), e;
|
|
16716
16718
|
}, "vec3").once()().toVar("normalView"), nd = /* @__PURE__ */ B((a) => {
|
|
16717
|
-
let e =
|
|
16719
|
+
let e = Ws.transformDirection(gi);
|
|
16718
16720
|
return a.material.flatShading !== !0 && (e = Rs(e, "v_normalWorld")), e;
|
|
16719
16721
|
}, "vec3").once()().normalize().toVar("normalWorld"), tt = /* @__PURE__ */ B((a) => {
|
|
16720
16722
|
let e = a.context.setupNormal().context({ getUV: null });
|
|
@@ -16748,7 +16750,7 @@ class ww extends nt {
|
|
|
16748
16750
|
}
|
|
16749
16751
|
}
|
|
16750
16752
|
const Ew = /* @__PURE__ */ G(ww);
|
|
16751
|
-
class Cw extends
|
|
16753
|
+
class Cw extends $a {
|
|
16752
16754
|
static get type() {
|
|
16753
16755
|
return "MaxMipLevelNode";
|
|
16754
16756
|
}
|
|
@@ -16911,7 +16913,7 @@ class Nw extends ae {
|
|
|
16911
16913
|
}
|
|
16912
16914
|
}
|
|
16913
16915
|
const br = /* @__PURE__ */ L(Nw).setParameterLength(1, 2), Oy = /* @__PURE__ */ new Et();
|
|
16914
|
-
class Fr extends
|
|
16916
|
+
class Fr extends $a {
|
|
16915
16917
|
static get type() {
|
|
16916
16918
|
return "TextureNode";
|
|
16917
16919
|
}
|
|
@@ -17862,8 +17864,8 @@ const jp = /* @__PURE__ */ new ms(), vc = /* @__PURE__ */ new Be(), Gw = /* @__P
|
|
|
17862
17864
|
}).onObjectUpdate(function({ material: a, scene: e }) {
|
|
17863
17865
|
const t = e.environment !== null && a.envMap === null ? e.environmentRotation : a.envMapRotation;
|
|
17864
17866
|
return t ? (jp.copy(t), vc.makeRotationFromEuler(jp)) : vc.identity(), vc;
|
|
17865
|
-
}), Vw = /* @__PURE__ */ qe.negate().reflect(tt), Hw = /* @__PURE__ */ qe.negate().refract(tt, Gw),
|
|
17866
|
-
class
|
|
17867
|
+
}), Vw = /* @__PURE__ */ qe.negate().reflect(tt), Hw = /* @__PURE__ */ qe.negate().refract(tt, Gw), $w = /* @__PURE__ */ Vw.transformDirection(gi).toVar("reflectVector"), Ww = /* @__PURE__ */ Hw.transformDirection(gi).toVar("reflectVector");
|
|
17868
|
+
class $l extends Et {
|
|
17867
17869
|
/**
|
|
17868
17870
|
* Constructs a new cube texture.
|
|
17869
17871
|
*
|
|
@@ -17893,7 +17895,7 @@ class Wl extends Et {
|
|
|
17893
17895
|
this.image = e;
|
|
17894
17896
|
}
|
|
17895
17897
|
}
|
|
17896
|
-
const jw = /* @__PURE__ */ new
|
|
17898
|
+
const jw = /* @__PURE__ */ new $l();
|
|
17897
17899
|
class qw extends Fr {
|
|
17898
17900
|
static get type() {
|
|
17899
17901
|
return "CubeTextureNode";
|
|
@@ -17925,7 +17927,7 @@ class qw extends Fr {
|
|
|
17925
17927
|
*/
|
|
17926
17928
|
getDefaultUV() {
|
|
17927
17929
|
const e = this.value;
|
|
17928
|
-
return e.mapping === Oa ?
|
|
17930
|
+
return e.mapping === Oa ? $w : e.mapping === ml ? Ww : (console.error('THREE.CubeTextureNode: Mapping "%s" not supported.', e.mapping), I(0, 0, 0));
|
|
17929
17931
|
}
|
|
17930
17932
|
/**
|
|
17931
17933
|
* Overwritten with an empty implementation since the `updateMatrix` flag is ignored
|
|
@@ -18133,7 +18135,7 @@ class Zw extends ad {
|
|
|
18133
18135
|
const Fi = (a, e, t = null) => U(new Zw(a, e, t)), Vy = /* @__PURE__ */ B((a) => (a.geometry.hasAttribute("tangent") === !1 && a.geometry.computeTangents(), Gi("tangent", "vec4")))(), od = /* @__PURE__ */ Vy.xyz.toVar("tangentLocal"), Hy = /* @__PURE__ */ zl.mul(re(od, 0)).xyz.toVarying("v_tangentView").normalize().toVar("tangentView"), Kw = /* @__PURE__ */ B(([a, e], t) => {
|
|
18134
18136
|
let s = a.mul(Vy.w).xyz;
|
|
18135
18137
|
return t.material.flatShading !== !0 && (s = Rs(s, e)), s;
|
|
18136
|
-
}).once(), Qw = Kw(
|
|
18138
|
+
}).once(), Qw = Kw(Ws.cross(Hy), "v_bitangentView").normalize().toVar("bitangentView"), ya = /* @__PURE__ */ It(Hy, Qw, Ws), Jw = /* @__PURE__ */ (() => {
|
|
18137
18139
|
let a = xr.cross(qe);
|
|
18138
18140
|
return a = a.cross(xr).normalize(), a = Ve(a, tt, ln.mul(ei.oneMinus()).oneMinus().pow2().pow2()).normalize(), a;
|
|
18139
18141
|
})(), eE = /* @__PURE__ */ B((a) => {
|
|
@@ -18160,7 +18162,7 @@ class tE extends nt {
|
|
|
18160
18162
|
let n = null;
|
|
18161
18163
|
return t === Ub ? n = Dy(i) : t === Ui && (e.hasGeometryAttribute("tangent") === !0 ? n = ya.mul(i).normalize() : n = eE({
|
|
18162
18164
|
eye_pos: st,
|
|
18163
|
-
surf_norm:
|
|
18165
|
+
surf_norm: Ws,
|
|
18164
18166
|
mapN: i,
|
|
18165
18167
|
uv: ja()
|
|
18166
18168
|
})), n;
|
|
@@ -18193,7 +18195,7 @@ class nE extends nt {
|
|
|
18193
18195
|
const e = this.scaleNode !== null ? this.scaleNode : 1, t = sE({ textureNode: this.textureNode, bumpScale: e });
|
|
18194
18196
|
return iE({
|
|
18195
18197
|
surf_pos: st,
|
|
18196
|
-
surf_norm:
|
|
18198
|
+
surf_norm: Ws,
|
|
18197
18199
|
dHdxy: t
|
|
18198
18200
|
});
|
|
18199
18201
|
}
|
|
@@ -18283,7 +18285,7 @@ class D extends ae {
|
|
|
18283
18285
|
const n = this.getFloat("emissiveIntensity"), r = this.getColor(s).mul(n);
|
|
18284
18286
|
t.emissiveMap && t.emissiveMap.isTexture === !0 ? i = r.mul(this.getTexture(s)) : i = r;
|
|
18285
18287
|
} else if (s === D.NORMAL)
|
|
18286
|
-
t.normalMap ? (i = Yp(this.getTexture("normal"), this.getCache("normalScale", "vec2")), i.normalMapType = t.normalMapType) : t.bumpMap ? i = rE(this.getTexture("bump").r, this.getFloat("bumpScale")) : i =
|
|
18288
|
+
t.normalMap ? (i = Yp(this.getTexture("normal"), this.getCache("normalScale", "vec2")), i.normalMapType = t.normalMapType) : t.bumpMap ? i = rE(this.getTexture("bump").r, this.getFloat("bumpScale")) : i = Ws;
|
|
18287
18289
|
else if (s === D.CLEARCOAT) {
|
|
18288
18290
|
const n = this.getFloat(s);
|
|
18289
18291
|
t.clearcoatMap && t.clearcoatMap.isTexture === !0 ? i = n.mul(this.getTexture(s).r) : i = n;
|
|
@@ -18291,7 +18293,7 @@ class D extends ae {
|
|
|
18291
18293
|
const n = this.getFloat(s);
|
|
18292
18294
|
t.clearcoatRoughnessMap && t.clearcoatRoughnessMap.isTexture === !0 ? i = n.mul(this.getTexture(s).r) : i = n;
|
|
18293
18295
|
} else if (s === D.CLEARCOAT_NORMAL)
|
|
18294
|
-
t.clearcoatNormalMap ? i = Yp(this.getTexture(s), this.getCache(s + "Scale", "vec2")) : i =
|
|
18296
|
+
t.clearcoatNormalMap ? i = Yp(this.getTexture(s), this.getCache(s + "Scale", "vec2")) : i = Ws;
|
|
18295
18297
|
else if (s === D.SHEEN) {
|
|
18296
18298
|
const n = this.getColor("sheenColor").mul(this.getFloat("sheen"));
|
|
18297
18299
|
t.sheenColorMap && t.sheenColorMap.isTexture === !0 ? i = n.mul(this.getTexture("sheenColor").rgb) : i = n;
|
|
@@ -18369,9 +18371,9 @@ D.POINT_SIZE = "size";
|
|
|
18369
18371
|
D.DISPERSION = "dispersion";
|
|
18370
18372
|
D.LIGHT_MAP = "light";
|
|
18371
18373
|
D.AO = "ao";
|
|
18372
|
-
const aE = /* @__PURE__ */ G(D, D.ALPHA_TEST), oE = /* @__PURE__ */ G(D, D.COLOR), lE = /* @__PURE__ */ G(D, D.SHININESS), cE = /* @__PURE__ */ G(D, D.EMISSIVE),
|
|
18374
|
+
const aE = /* @__PURE__ */ G(D, D.ALPHA_TEST), oE = /* @__PURE__ */ G(D, D.COLOR), lE = /* @__PURE__ */ G(D, D.SHININESS), cE = /* @__PURE__ */ G(D, D.EMISSIVE), $y = /* @__PURE__ */ G(D, D.OPACITY), hE = /* @__PURE__ */ G(D, D.SPECULAR), Zp = /* @__PURE__ */ G(D, D.SPECULAR_INTENSITY), uE = /* @__PURE__ */ G(D, D.SPECULAR_COLOR), il = /* @__PURE__ */ G(D, D.SPECULAR_STRENGTH), Ec = /* @__PURE__ */ G(D, D.REFLECTIVITY), dE = /* @__PURE__ */ G(D, D.ROUGHNESS), pE = /* @__PURE__ */ G(D, D.METALNESS), fE = /* @__PURE__ */ G(D, D.NORMAL), mE = /* @__PURE__ */ G(D, D.CLEARCOAT), gE = /* @__PURE__ */ G(D, D.CLEARCOAT_ROUGHNESS), yE = /* @__PURE__ */ G(D, D.CLEARCOAT_NORMAL), xE = /* @__PURE__ */ G(D, D.ROTATION), _E = /* @__PURE__ */ G(D, D.SHEEN), bE = /* @__PURE__ */ G(D, D.SHEEN_ROUGHNESS), TE = /* @__PURE__ */ G(D, D.ANISOTROPY), SE = /* @__PURE__ */ G(D, D.IRIDESCENCE), vE = /* @__PURE__ */ G(D, D.IRIDESCENCE_IOR), wE = /* @__PURE__ */ G(D, D.IRIDESCENCE_THICKNESS), EE = /* @__PURE__ */ G(D, D.TRANSMISSION), CE = /* @__PURE__ */ G(D, D.THICKNESS), ME = /* @__PURE__ */ G(D, D.IOR), AE = /* @__PURE__ */ G(D, D.ATTENUATION_DISTANCE), RE = /* @__PURE__ */ G(D, D.ATTENUATION_COLOR), NE = /* @__PURE__ */ G(D, D.LINE_SCALE), PE = /* @__PURE__ */ G(D, D.LINE_DASH_SIZE), DE = /* @__PURE__ */ G(D, D.LINE_GAP_SIZE);
|
|
18373
18375
|
D.LINE_WIDTH;
|
|
18374
|
-
const FE = /* @__PURE__ */ G(D, D.LINE_DASH_OFFSET), OE = /* @__PURE__ */ G(D, D.POINT_SIZE), IE = /* @__PURE__ */ G(D, D.DISPERSION),
|
|
18376
|
+
const FE = /* @__PURE__ */ G(D, D.LINE_DASH_OFFSET), OE = /* @__PURE__ */ G(D, D.POINT_SIZE), IE = /* @__PURE__ */ G(D, D.DISPERSION), Wy = /* @__PURE__ */ G(D, D.LIGHT_MAP), BE = /* @__PURE__ */ G(D, D.AO), Xr = /* @__PURE__ */ J(new ce()).onReference(function(a) {
|
|
18375
18377
|
return a.material;
|
|
18376
18378
|
}).onRenderUpdate(function({ material: a }) {
|
|
18377
18379
|
this.value.set(a.anisotropy * Math.cos(a.anisotropyRotation), a.anisotropy * Math.sin(a.anisotropyRotation));
|
|
@@ -18466,8 +18468,8 @@ class kE extends ae {
|
|
|
18466
18468
|
}
|
|
18467
18469
|
const o = n.mul(vt).xyz;
|
|
18468
18470
|
if (vt.assign(o), e.hasGeometryAttribute("normal")) {
|
|
18469
|
-
const l = vw(
|
|
18470
|
-
|
|
18471
|
+
const l = vw($s, n);
|
|
18472
|
+
$s.assign(l);
|
|
18471
18473
|
}
|
|
18472
18474
|
this.instanceColorNode !== null && Sl("vec3", "vInstanceColor").assign(this.instanceColorNode);
|
|
18473
18475
|
}
|
|
@@ -18546,12 +18548,12 @@ class VE extends ae {
|
|
|
18546
18548
|
}
|
|
18547
18549
|
const u = It(c);
|
|
18548
18550
|
vt.assign(c.mul(vt));
|
|
18549
|
-
const d =
|
|
18550
|
-
|
|
18551
|
+
const d = $s.div(I(u[0].dot(u[0]), u[1].dot(u[1]), u[2].dot(u[2]))), p = u.mul(d).xyz;
|
|
18552
|
+
$s.assign(p), e.hasGeometryAttribute("tangent") && od.mulAssign(u);
|
|
18551
18553
|
}
|
|
18552
18554
|
}
|
|
18553
18555
|
const HE = /* @__PURE__ */ L(VE).setParameterLength(1), Kp = /* @__PURE__ */ new WeakMap();
|
|
18554
|
-
class
|
|
18556
|
+
class $E extends ae {
|
|
18555
18557
|
static get type() {
|
|
18556
18558
|
return "SkinningNode";
|
|
18557
18559
|
}
|
|
@@ -18586,7 +18588,7 @@ class WE extends ae {
|
|
|
18586
18588
|
* @param {Node<vec3>} [normal=normalLocal] - The vertex normal in local space.
|
|
18587
18589
|
* @return {Node<vec3>} The transformed vertex normal.
|
|
18588
18590
|
*/
|
|
18589
|
-
getSkinnedNormal(e = this.boneMatricesNode, t =
|
|
18591
|
+
getSkinnedNormal(e = this.boneMatricesNode, t = $s) {
|
|
18590
18592
|
const { skinIndexNode: s, skinWeightNode: i, bindMatrixNode: n, bindMatrixInverseNode: r } = this, o = e.element(s.x), l = e.element(s.y), c = e.element(s.z), h = e.element(s.w);
|
|
18591
18593
|
let u = Bt(
|
|
18592
18594
|
i.x.mul(o),
|
|
@@ -18604,7 +18606,7 @@ class WE extends ae {
|
|
|
18604
18606
|
*/
|
|
18605
18607
|
getPreviousSkinnedPosition(e) {
|
|
18606
18608
|
const t = e.object;
|
|
18607
|
-
return this.previousBoneMatricesNode === null && (t.skeleton.previousBoneMatrices = new Float32Array(t.skeleton.boneMatrices), this.previousBoneMatricesNode = qp("skeleton.previousBoneMatrices", "mat4", t.skeleton.bones.length)), this.getSkinnedPosition(this.previousBoneMatricesNode,
|
|
18609
|
+
return this.previousBoneMatricesNode === null && (t.skeleton.previousBoneMatrices = new Float32Array(t.skeleton.boneMatrices), this.previousBoneMatricesNode = qp("skeleton.previousBoneMatrices", "mat4", t.skeleton.bones.length)), this.getSkinnedPosition(this.previousBoneMatricesNode, Wp);
|
|
18608
18610
|
}
|
|
18609
18611
|
/**
|
|
18610
18612
|
* Returns `true` if bone matrices from the previous frame are required. Relevant
|
|
@@ -18624,11 +18626,11 @@ class WE extends ae {
|
|
|
18624
18626
|
* @return {Node<vec3>} The transformed vertex position.
|
|
18625
18627
|
*/
|
|
18626
18628
|
setup(e) {
|
|
18627
|
-
this.needsPreviousBoneMatrices(e) &&
|
|
18629
|
+
this.needsPreviousBoneMatrices(e) && Wp.assign(this.getPreviousSkinnedPosition(e));
|
|
18628
18630
|
const t = this.getSkinnedPosition();
|
|
18629
18631
|
if (this.toPositionNode && this.toPositionNode.assign(t), e.hasGeometryAttribute("normal")) {
|
|
18630
18632
|
const s = this.getSkinnedNormal();
|
|
18631
|
-
|
|
18633
|
+
$s.assign(s), e.hasGeometryAttribute("tangent") && od.assign(s);
|
|
18632
18634
|
}
|
|
18633
18635
|
return t;
|
|
18634
18636
|
}
|
|
@@ -18653,7 +18655,7 @@ class WE extends ae {
|
|
|
18653
18655
|
Kp.get(t) !== e.frameId && (Kp.set(t, e.frameId), this.previousBoneMatricesNode !== null && t.previousBoneMatrices.set(t.boneMatrices), t.update());
|
|
18654
18656
|
}
|
|
18655
18657
|
}
|
|
18656
|
-
const
|
|
18658
|
+
const WE = (a) => U(new $E(a));
|
|
18657
18659
|
class jE extends Et {
|
|
18658
18660
|
/**
|
|
18659
18661
|
* Constructs a new data array texture.
|
|
@@ -18741,7 +18743,7 @@ class YE extends ae {
|
|
|
18741
18743
|
*/
|
|
18742
18744
|
setup(e) {
|
|
18743
18745
|
const { geometry: t } = e, s = t.morphAttributes.position !== void 0, i = t.hasAttribute("normal") && t.morphAttributes.normal !== void 0, n = t.morphAttributes.position || t.morphAttributes.normal || t.morphAttributes.color, r = n !== void 0 ? n.length : 0, { texture: o, stride: l, size: c } = qE(t);
|
|
18744
|
-
s === !0 && vt.mulAssign(this.morphBaseInfluence), i === !0 &&
|
|
18746
|
+
s === !0 && vt.mulAssign(this.morphBaseInfluence), i === !0 && $s.mulAssign(this.morphBaseInfluence);
|
|
18745
18747
|
const h = ke(c.width);
|
|
18746
18748
|
Cs(r, ({ i: u }) => {
|
|
18747
18749
|
const d = O(0).toVar();
|
|
@@ -18753,7 +18755,7 @@ class YE extends ae {
|
|
|
18753
18755
|
width: h,
|
|
18754
18756
|
depth: u,
|
|
18755
18757
|
offset: ke(0)
|
|
18756
|
-
})), i === !0 &&
|
|
18758
|
+
})), i === !0 && $s.addAssign(Qp({
|
|
18757
18759
|
bufferMap: o,
|
|
18758
18760
|
influence: d,
|
|
18759
18761
|
stride: l,
|
|
@@ -19410,9 +19412,9 @@ class it extends jt {
|
|
|
19410
19412
|
*/
|
|
19411
19413
|
setupPosition(e) {
|
|
19412
19414
|
const { object: t, geometry: s } = e;
|
|
19413
|
-
if ((s.morphAttributes.position || s.morphAttributes.normal || s.morphAttributes.color) && XE(t).toStack(), t.isSkinnedMesh === !0 &&
|
|
19415
|
+
if ((s.morphAttributes.position || s.morphAttributes.normal || s.morphAttributes.color) && XE(t).toStack(), t.isSkinnedMesh === !0 && WE(t).toStack(), this.displacementMap) {
|
|
19414
19416
|
const i = Fi("displacementMap", "texture"), n = Fi("displacementScale", "float"), r = Fi("displacementBias", "float");
|
|
19415
|
-
vt.addAssign(
|
|
19417
|
+
vt.addAssign($s.normalize().mul(i.x.mul(n).add(r)));
|
|
19416
19418
|
}
|
|
19417
19419
|
return t.isBatchedMesh && HE(t).toStack(), t.isInstancedMesh && t.instanceMatrix && t.instanceMatrix.isInstancedBufferAttribute === !0 && GE(t).toStack(), this.positionNode !== null && vt.assign(Xv(this.positionNode, "POSITION")), vt;
|
|
19418
19420
|
}
|
|
@@ -19426,7 +19428,7 @@ class it extends jt {
|
|
|
19426
19428
|
this.maskNode !== null && Vu(this.maskNode).not().discard();
|
|
19427
19429
|
let s = this.colorNode ? re(this.colorNode) : oE;
|
|
19428
19430
|
this.vertexColors === !0 && t.hasAttribute("color") && (s = s.mul(lC())), e.instanceColor && (s = Sl("vec3", "vInstanceColor").mul(s)), e.isBatchedMesh && e._colorsTexture && (s = Sl("vec3", "vBatchColor").mul(s)), Se.assign(s);
|
|
19429
|
-
const i = this.opacityNode ? O(this.opacityNode) :
|
|
19431
|
+
const i = this.opacityNode ? O(this.opacityNode) : $y;
|
|
19430
19432
|
Se.a.assign(Se.a.mul(i));
|
|
19431
19433
|
let n = null;
|
|
19432
19434
|
(this.alphaTestNode !== null || this.alphaTest > 0) && (n = this.alphaTestNode !== null ? O(this.alphaTestNode) : aE, Se.a.lessThanEqual(n).discard()), this.alphaHash === !0 && Se.a.lessThan(aC(vt)).discard(), this.transparent === !1 && this.blending === ni && this.alphaToCoverage === !1 ? Se.a.assign(1) : n === null && Se.a.lessThanEqual(0).discard();
|
|
@@ -19474,7 +19476,7 @@ class it extends jt {
|
|
|
19474
19476
|
*/
|
|
19475
19477
|
setupLightMap(e) {
|
|
19476
19478
|
let t = null;
|
|
19477
|
-
return e.material.lightMap && (t = new JE(
|
|
19479
|
+
return e.material.lightMap && (t = new JE(Wy)), t;
|
|
19478
19480
|
}
|
|
19479
19481
|
/**
|
|
19480
19482
|
* Setups the lights node based on the scene, environment and material.
|
|
@@ -19597,7 +19599,7 @@ class it extends jt {
|
|
|
19597
19599
|
}
|
|
19598
19600
|
}
|
|
19599
19601
|
let cC = 0;
|
|
19600
|
-
const rs = /* @__PURE__ */ new Be(), Mc = /* @__PURE__ */ new dt(), Vn = /* @__PURE__ */ new R(), Kt = /* @__PURE__ */ new
|
|
19602
|
+
const rs = /* @__PURE__ */ new Be(), Mc = /* @__PURE__ */ new dt(), Vn = /* @__PURE__ */ new R(), Kt = /* @__PURE__ */ new Wa(), Zr = /* @__PURE__ */ new Wa(), pt = /* @__PURE__ */ new R();
|
|
19601
19603
|
class yi extends En {
|
|
19602
19604
|
/**
|
|
19603
19605
|
* Constructs a new geometry.
|
|
@@ -19848,7 +19850,7 @@ class yi extends En {
|
|
|
19848
19850
|
* You may need to recompute the bounding box if the geometry vertices are modified.
|
|
19849
19851
|
*/
|
|
19850
19852
|
computeBoundingBox() {
|
|
19851
|
-
this.boundingBox === null && (this.boundingBox = new
|
|
19853
|
+
this.boundingBox === null && (this.boundingBox = new Wa());
|
|
19852
19854
|
const e = this.attributes.position, t = this.morphAttributes.position;
|
|
19853
19855
|
if (e && e.isGLBufferAttribute) {
|
|
19854
19856
|
console.error("THREE.BufferGeometry.computeBoundingBox(): GLBufferAttribute requires a manual bounding box.", this), this.boundingBox.set(
|
|
@@ -19929,12 +19931,12 @@ class yi extends En {
|
|
|
19929
19931
|
count: e.count
|
|
19930
19932
|
}]);
|
|
19931
19933
|
for (let A = 0, N = x.length; A < N; ++A) {
|
|
19932
|
-
const k = x[A], H = k.start,
|
|
19933
|
-
for (let
|
|
19934
|
+
const k = x[A], H = k.start, W = k.count;
|
|
19935
|
+
for (let $ = H, q = H + W; $ < q; $ += 3)
|
|
19934
19936
|
g(
|
|
19935
|
-
e.getX(
|
|
19936
|
-
e.getX(
|
|
19937
|
-
e.getX(
|
|
19937
|
+
e.getX($ + 0),
|
|
19938
|
+
e.getX($ + 1),
|
|
19939
|
+
e.getX($ + 2)
|
|
19938
19940
|
);
|
|
19939
19941
|
}
|
|
19940
19942
|
const _ = new R(), b = new R(), T = new R(), E = new R();
|
|
@@ -19946,9 +19948,9 @@ class yi extends En {
|
|
|
19946
19948
|
r.setXYZW(A, _.x, _.y, _.z, H);
|
|
19947
19949
|
}
|
|
19948
19950
|
for (let A = 0, N = x.length; A < N; ++A) {
|
|
19949
|
-
const k = x[A], H = k.start,
|
|
19950
|
-
for (let
|
|
19951
|
-
v(e.getX(
|
|
19951
|
+
const k = x[A], H = k.start, W = k.count;
|
|
19952
|
+
for (let $ = H, q = H + W; $ < q; $ += 3)
|
|
19953
|
+
v(e.getX($ + 0)), v(e.getX($ + 1)), v(e.getX($ + 2));
|
|
19952
19954
|
}
|
|
19953
19955
|
}
|
|
19954
19956
|
/**
|
|
@@ -20385,7 +20387,7 @@ class hC {
|
|
|
20385
20387
|
return new this.constructor().copy(this);
|
|
20386
20388
|
}
|
|
20387
20389
|
}
|
|
20388
|
-
const _s = /* @__PURE__ */ new R(), Zs = /* @__PURE__ */ new R(), Pc = /* @__PURE__ */ new R(), Ks = /* @__PURE__ */ new R(), Hn = /* @__PURE__ */ new R(),
|
|
20390
|
+
const _s = /* @__PURE__ */ new R(), Zs = /* @__PURE__ */ new R(), Pc = /* @__PURE__ */ new R(), Ks = /* @__PURE__ */ new R(), Hn = /* @__PURE__ */ new R(), $n = /* @__PURE__ */ new R(), tf = /* @__PURE__ */ new R(), Dc = /* @__PURE__ */ new R(), Fc = /* @__PURE__ */ new R(), Oc = /* @__PURE__ */ new R(), Ic = /* @__PURE__ */ new me(), Bc = /* @__PURE__ */ new me(), Lc = /* @__PURE__ */ new me();
|
|
20389
20391
|
class Ms {
|
|
20390
20392
|
/**
|
|
20391
20393
|
* Constructs a new triangle.
|
|
@@ -20638,29 +20640,29 @@ class Ms {
|
|
|
20638
20640
|
closestPointToPoint(e, t) {
|
|
20639
20641
|
const s = this.a, i = this.b, n = this.c;
|
|
20640
20642
|
let r, o;
|
|
20641
|
-
Hn.subVectors(i, s),
|
|
20642
|
-
const l = Hn.dot(Dc), c =
|
|
20643
|
+
Hn.subVectors(i, s), $n.subVectors(n, s), Dc.subVectors(e, s);
|
|
20644
|
+
const l = Hn.dot(Dc), c = $n.dot(Dc);
|
|
20643
20645
|
if (l <= 0 && c <= 0)
|
|
20644
20646
|
return t.copy(s);
|
|
20645
20647
|
Fc.subVectors(e, i);
|
|
20646
|
-
const h = Hn.dot(Fc), u =
|
|
20648
|
+
const h = Hn.dot(Fc), u = $n.dot(Fc);
|
|
20647
20649
|
if (h >= 0 && u <= h)
|
|
20648
20650
|
return t.copy(i);
|
|
20649
20651
|
const d = l * u - h * c;
|
|
20650
20652
|
if (d <= 0 && l >= 0 && h <= 0)
|
|
20651
20653
|
return r = l / (l - h), t.copy(s).addScaledVector(Hn, r);
|
|
20652
20654
|
Oc.subVectors(e, n);
|
|
20653
|
-
const p = Hn.dot(Oc), f =
|
|
20655
|
+
const p = Hn.dot(Oc), f = $n.dot(Oc);
|
|
20654
20656
|
if (f >= 0 && p <= f)
|
|
20655
20657
|
return t.copy(n);
|
|
20656
20658
|
const m = p * c - l * f;
|
|
20657
20659
|
if (m <= 0 && c >= 0 && f <= 0)
|
|
20658
|
-
return o = c / (c - f), t.copy(s).addScaledVector(
|
|
20660
|
+
return o = c / (c - f), t.copy(s).addScaledVector($n, o);
|
|
20659
20661
|
const y = h * f - p * u;
|
|
20660
20662
|
if (y <= 0 && u - h >= 0 && p - f >= 0)
|
|
20661
20663
|
return tf.subVectors(n, i), o = (u - h) / (u - h + (p - f)), t.copy(i).addScaledVector(tf, o);
|
|
20662
20664
|
const g = 1 / (y + m + d);
|
|
20663
|
-
return r = m * g, o = d * g, t.copy(s).addScaledVector(Hn, r).addScaledVector(
|
|
20665
|
+
return r = m * g, o = d * g, t.copy(s).addScaledVector(Hn, r).addScaledVector($n, o);
|
|
20664
20666
|
}
|
|
20665
20667
|
/**
|
|
20666
20668
|
* Returns `true` if this triangle is equal with the given one.
|
|
@@ -20791,7 +20793,7 @@ class fi extends dt {
|
|
|
20791
20793
|
}
|
|
20792
20794
|
function uC(a, e, t, s, i, n, r, o) {
|
|
20793
20795
|
let l;
|
|
20794
|
-
if (e.side ===
|
|
20796
|
+
if (e.side === Wt ? l = s.intersectTriangle(r, n, i, !0, o) : l = s.intersectTriangle(i, n, r, e.side === ii, o), l === null) return null;
|
|
20795
20797
|
yo.copy(o), yo.applyMatrix4(a.matrixWorld);
|
|
20796
20798
|
const c = t.ray.origin.distanceTo(yo);
|
|
20797
20799
|
return c < t.near || c > t.far ? null : {
|
|
@@ -20923,14 +20925,14 @@ class cd extends fi {
|
|
|
20923
20925
|
e.render(this, kc);
|
|
20924
20926
|
}
|
|
20925
20927
|
}
|
|
20926
|
-
const
|
|
20928
|
+
const Wl = 1 / 6, qy = (a) => pe(Wl, pe(a, pe(a, a.negate().add(3)).sub(3)).add(1)), hu = (a) => pe(Wl, pe(a, pe(a, pe(3, a).sub(6))).add(4)), Yy = (a) => pe(Wl, pe(a, pe(a, pe(-3, a).add(3)).add(3)).add(1)), uu = (a) => pe(Wl, Ll(a, 3)), af = (a) => qy(a).add(hu(a)), of = (a) => Yy(a).add(uu(a)), lf = (a) => Bt(-1, hu(a).div(qy(a).add(hu(a)))), cf = (a) => Bt(1, uu(a).div(Yy(a).add(uu(a)))), hf = (a, e, t) => {
|
|
20927
20929
|
const s = a.uvNode, i = pe(s, e.zw).add(0.5), n = _n(i), r = Hi(i), o = af(r.x), l = of(r.x), c = lf(r.x), h = cf(r.x), u = lf(r.y), d = cf(r.y), p = V(n.x.add(c), n.y.add(u)).sub(0.5).mul(e.xy), f = V(n.x.add(h), n.y.add(u)).sub(0.5).mul(e.xy), m = V(n.x.add(c), n.y.add(d)).sub(0.5).mul(e.xy), y = V(n.x.add(h), n.y.add(d)).sub(0.5).mul(e.xy), g = af(r.y).mul(Bt(o.mul(a.sample(p).level(t)), l.mul(a.sample(f).level(t)))), x = of(r.y).mul(Bt(o.mul(a.sample(m).level(t)), l.mul(a.sample(y).level(t))));
|
|
20928
20930
|
return g.add(x);
|
|
20929
20931
|
}, fC = /* @__PURE__ */ B(([a, e = O(3)]) => {
|
|
20930
20932
|
const t = V(a.size(ke(e))), s = V(a.size(ke(e.add(1)))), i = Hs(1, t), n = Hs(1, s), r = hf(a, re(i, t), _n(e)), o = hf(a, re(n, s), Yu(e));
|
|
20931
20933
|
return Hi(e).mix(r, o);
|
|
20932
20934
|
}), Kr = /* @__PURE__ */ new ms(), zc = /* @__PURE__ */ new Be();
|
|
20933
|
-
class
|
|
20935
|
+
class $t extends ae {
|
|
20934
20936
|
static get type() {
|
|
20935
20937
|
return "SceneNode";
|
|
20936
20938
|
}
|
|
@@ -20940,7 +20942,7 @@ class Wt extends ae {
|
|
|
20940
20942
|
* @param {('backgroundBlurriness'|'backgroundIntensity'|'backgroundRotation')} scope - The scope defines the type of scene property that is accessed.
|
|
20941
20943
|
* @param {?Scene} [scene=null] - A reference to the scene.
|
|
20942
20944
|
*/
|
|
20943
|
-
constructor(e =
|
|
20945
|
+
constructor(e = $t.BACKGROUND_BLURRINESS, t = null) {
|
|
20944
20946
|
super(), this.scope = e, this.scene = t;
|
|
20945
20947
|
}
|
|
20946
20948
|
/**
|
|
@@ -20953,16 +20955,16 @@ class Wt extends ae {
|
|
|
20953
20955
|
setup(e) {
|
|
20954
20956
|
const t = this.scope, s = this.scene !== null ? this.scene : e.scene;
|
|
20955
20957
|
let i;
|
|
20956
|
-
return t ===
|
|
20958
|
+
return t === $t.BACKGROUND_BLURRINESS ? i = Ie("backgroundBlurriness", "float", s) : t === $t.BACKGROUND_INTENSITY ? i = Ie("backgroundIntensity", "float", s) : t === $t.BACKGROUND_ROTATION ? i = J("mat4").label("backgroundRotation").setGroup(Q).onRenderUpdate(() => {
|
|
20957
20959
|
const n = s.background;
|
|
20958
20960
|
return n !== null && n.isTexture && n.mapping !== wu ? (Kr.copy(s.backgroundRotation), Kr.x *= -1, Kr.y *= -1, Kr.z *= -1, zc.makeRotationFromEuler(Kr)) : zc.identity(), zc;
|
|
20959
20961
|
}) : console.error("THREE.SceneNode: Unknown scope:", t), i;
|
|
20960
20962
|
}
|
|
20961
20963
|
}
|
|
20962
|
-
|
|
20963
|
-
|
|
20964
|
-
|
|
20965
|
-
const mC = /* @__PURE__ */ G(
|
|
20964
|
+
$t.BACKGROUND_BLURRINESS = "backgroundBlurriness";
|
|
20965
|
+
$t.BACKGROUND_INTENSITY = "backgroundIntensity";
|
|
20966
|
+
$t.BACKGROUND_ROTATION = "backgroundRotation";
|
|
20967
|
+
const mC = /* @__PURE__ */ G($t, $t.BACKGROUND_BLURRINESS), uf = /* @__PURE__ */ G($t, $t.BACKGROUND_INTENSITY), gC = /* @__PURE__ */ G($t, $t.BACKGROUND_ROTATION), yC = B(({ texture: a, uv: e }) => {
|
|
20966
20968
|
const s = I().toVar();
|
|
20967
20969
|
return Ke(e.x.lessThan(1e-4), () => {
|
|
20968
20970
|
s.assign(I(1, 0, 0));
|
|
@@ -21781,17 +21783,17 @@ function VC(a, e) {
|
|
|
21781
21783
|
function HC(a, e = {}) {
|
|
21782
21784
|
return e.background = a.background, e.backgroundNode = a.backgroundNode, e.overrideMaterial = a.overrideMaterial, e;
|
|
21783
21785
|
}
|
|
21784
|
-
function
|
|
21786
|
+
function $C(a, e) {
|
|
21785
21787
|
return e = HC(a, e), a.background = null, a.backgroundNode = null, a.overrideMaterial = null, e;
|
|
21786
21788
|
}
|
|
21787
|
-
function
|
|
21789
|
+
function WC(a, e) {
|
|
21788
21790
|
a.background = e.background, a.backgroundNode = e.backgroundNode, a.overrideMaterial = e.overrideMaterial;
|
|
21789
21791
|
}
|
|
21790
21792
|
function jC(a, e, t) {
|
|
21791
|
-
return t = GC(a, t), t =
|
|
21793
|
+
return t = GC(a, t), t = $C(e, t), t;
|
|
21792
21794
|
}
|
|
21793
21795
|
function qC(a, e, t) {
|
|
21794
|
-
VC(a, t),
|
|
21796
|
+
VC(a, t), WC(e, t);
|
|
21795
21797
|
}
|
|
21796
21798
|
const ff = /* @__PURE__ */ new WeakMap(), YC = /* @__PURE__ */ B(({ depthTexture: a, shadowCoord: e, depthLayer: t }) => {
|
|
21797
21799
|
let s = _e(a, e.xy).label("t_basic");
|
|
@@ -21887,12 +21889,12 @@ const ff = /* @__PURE__ */ new WeakMap(), YC = /* @__PURE__ */ B(({ depthTexture
|
|
|
21887
21889
|
e = new it(), e.colorNode = re(0, 0, 0, 1), e.depthNode = t, e.isShadowPassMaterial = !0, e.name = "ShadowMaterial", e.fog = !1, ff.set(a, e);
|
|
21888
21890
|
}
|
|
21889
21891
|
return e;
|
|
21890
|
-
}, mf = /* @__PURE__ */ new As(),
|
|
21891
|
-
|
|
21892
|
-
let i = mf.get(
|
|
21892
|
+
}, mf = /* @__PURE__ */ new As(), Wn = [], tM = (a, e, t, s) => {
|
|
21893
|
+
Wn[0] = a, Wn[1] = e;
|
|
21894
|
+
let i = mf.get(Wn);
|
|
21893
21895
|
return (i === void 0 || i.shadowType !== t || i.useVelocity !== s) && (i = (n, r, o, l, c, h, ...u) => {
|
|
21894
21896
|
(n.castShadow === !0 || n.receiveShadow && t === Yo) && (s && (kg(n).useVelocity = !0), n.onBeforeShadow(a, n, o, e.camera, l, r.overrideMaterial, h), a.renderObject(n, r, o, l, c, h, ...u), n.onAfterShadow(a, n, o, e.camera, l, r.overrideMaterial, h));
|
|
21895
|
-
}, i.shadowType = t, i.useVelocity = s, mf.set(
|
|
21897
|
+
}, i.shadowType = t, i.useVelocity = s, mf.set(Wn, i)), Wn[0] = null, Wn[1] = null, i;
|
|
21896
21898
|
}, sM = /* @__PURE__ */ B(({ samples: a, radius: e, size: t, shadowPass: s, depthLayer: i }) => {
|
|
21897
21899
|
const n = O(0).toVar("meanVertical"), r = O(0).toVar("squareMeanVertical"), o = a.lessThanEqual(O(1)).select(O(0), O(2).div(a.sub(1))), l = a.lessThanEqual(O(1)).select(O(0), O(-1));
|
|
21898
21900
|
Cs({ start: ke(0), end: ke(a), type: "int", condition: "<" }, ({ i: h }) => {
|
|
@@ -22328,7 +22330,7 @@ class pM extends Mn {
|
|
|
22328
22330
|
});
|
|
22329
22331
|
}
|
|
22330
22332
|
}
|
|
22331
|
-
const yf = /* @__PURE__ */ O(1), du = /* @__PURE__ */ O(-2), So = /* @__PURE__ */ O(0.8), Hc = /* @__PURE__ */ O(-1), vo = /* @__PURE__ */ O(0.4),
|
|
22333
|
+
const yf = /* @__PURE__ */ O(1), du = /* @__PURE__ */ O(-2), So = /* @__PURE__ */ O(0.8), Hc = /* @__PURE__ */ O(-1), vo = /* @__PURE__ */ O(0.4), $c = /* @__PURE__ */ O(2), wo = /* @__PURE__ */ O(0.305), Wc = /* @__PURE__ */ O(3), xf = /* @__PURE__ */ O(0.21), fM = /* @__PURE__ */ O(4), _f = /* @__PURE__ */ O(4), mM = /* @__PURE__ */ O(16), gM = /* @__PURE__ */ B(([a]) => {
|
|
22332
22334
|
const e = I(ls(a)).toVar(), t = O(-1).toVar();
|
|
22333
22335
|
return Ke(e.x.greaterThan(e.z), () => {
|
|
22334
22336
|
Ke(e.x.greaterThan(e.y), () => {
|
|
@@ -22376,11 +22378,11 @@ const yf = /* @__PURE__ */ O(1), du = /* @__PURE__ */ O(-2), So = /* @__PURE__ *
|
|
|
22376
22378
|
return Ke(a.greaterThanEqual(So), () => {
|
|
22377
22379
|
e.assign(yf.sub(a).mul(Hc.sub(du)).div(yf.sub(So)).add(du));
|
|
22378
22380
|
}).ElseIf(a.greaterThanEqual(vo), () => {
|
|
22379
|
-
e.assign(So.sub(a).mul(
|
|
22381
|
+
e.assign(So.sub(a).mul($c.sub(Hc)).div(So.sub(vo)).add(Hc));
|
|
22380
22382
|
}).ElseIf(a.greaterThanEqual(wo), () => {
|
|
22381
|
-
e.assign(vo.sub(a).mul(
|
|
22383
|
+
e.assign(vo.sub(a).mul(Wc.sub($c)).div(vo.sub(wo)).add($c));
|
|
22382
22384
|
}).ElseIf(a.greaterThanEqual(xf), () => {
|
|
22383
|
-
e.assign(wo.sub(a).mul(fM.sub(
|
|
22385
|
+
e.assign(wo.sub(a).mul(fM.sub(Wc)).div(wo.sub(xf)).add(Wc));
|
|
22384
22386
|
}).Else(() => {
|
|
22385
22387
|
e.assign(O(-2).mul(li(pe(1.16, a))));
|
|
22386
22388
|
}), e;
|
|
@@ -22636,13 +22638,13 @@ class qa extends yi {
|
|
|
22636
22638
|
let d = 0, p = 0;
|
|
22637
22639
|
f("z", "y", "x", -1, -1, s, t, e, r, n, 0), f("z", "y", "x", 1, -1, s, t, -e, r, n, 1), f("x", "z", "y", 1, 1, e, s, t, i, r, 2), f("x", "z", "y", 1, -1, e, s, -t, i, r, 3), f("x", "y", "z", 1, -1, e, t, s, i, n, 4), f("x", "y", "z", -1, -1, e, t, -s, i, n, 5), this.setIndex(l), this.setAttribute("position", new Ot(c, 3)), this.setAttribute("normal", new Ot(h, 3)), this.setAttribute("uv", new Ot(u, 2));
|
|
22638
22640
|
function f(m, y, g, x, _, b, T, E, v, A, N) {
|
|
22639
|
-
const k = b / v, H = T / A,
|
|
22641
|
+
const k = b / v, H = T / A, W = b / 2, $ = T / 2, q = E / 2, Z = v + 1, we = A + 1;
|
|
22640
22642
|
let ue = 0, ge = 0;
|
|
22641
22643
|
const ie = new R();
|
|
22642
22644
|
for (let Ee = 0; Ee < we; Ee++) {
|
|
22643
|
-
const ze = Ee * H -
|
|
22645
|
+
const ze = Ee * H - $;
|
|
22644
22646
|
for (let at = 0; at < Z; at++) {
|
|
22645
|
-
const be = at * k -
|
|
22647
|
+
const be = at * k - W;
|
|
22646
22648
|
ie[m] = be * x, ie[y] = ze * _, ie[g] = q, c.push(ie.x, ie.y, ie.z), ie[m] = 0, ie[y] = 0, ie[g] = E > 0 ? 1 : -1, h.push(ie.x, ie.y, ie.z), u.push(at / v), u.push(1 - Ee / A), ue += 1;
|
|
22647
22649
|
}
|
|
22648
22650
|
}
|
|
@@ -22886,7 +22888,7 @@ class EM {
|
|
|
22886
22888
|
if (u === null) {
|
|
22887
22889
|
const f = new Oi({
|
|
22888
22890
|
name: "PMREM.Background",
|
|
22889
|
-
side:
|
|
22891
|
+
side: Wt,
|
|
22890
22892
|
depthWrite: !1,
|
|
22891
22893
|
depthTest: !1
|
|
22892
22894
|
});
|
|
@@ -23011,8 +23013,8 @@ function CM(a) {
|
|
|
23011
23013
|
0
|
|
23012
23014
|
], H = wM[v];
|
|
23013
23015
|
_.set(k, y * m * H), b.set(p, g * m * H);
|
|
23014
|
-
const
|
|
23015
|
-
T.set(
|
|
23016
|
+
const W = [H, H, H, H, H, H];
|
|
23017
|
+
T.set(W, x * m * H);
|
|
23016
23018
|
}
|
|
23017
23019
|
const E = new yi();
|
|
23018
23020
|
E.setAttribute("position", new ds(_, y)), E.setAttribute("uv", new ds(b, g)), E.setAttribute("faceIndex", new ds(T, x)), e.push(E), i.push(new fi(E, null)), n > cr && n--;
|
|
@@ -23250,7 +23252,7 @@ const Ga = /* @__PURE__ */ B(({ f0: a, f90: e, dotVH: t }) => {
|
|
|
23250
23252
|
}), zM = /* @__PURE__ */ B((a) => {
|
|
23251
23253
|
if (a.geometry.hasAttribute("normal") === !1)
|
|
23252
23254
|
return O(0);
|
|
23253
|
-
const e =
|
|
23255
|
+
const e = Ws.dFdx().abs().max(Ws.dFdy().abs());
|
|
23254
23256
|
return e.x.max(e.y).max(e.z);
|
|
23255
23257
|
}), o0 = /* @__PURE__ */ B((a) => {
|
|
23256
23258
|
const { roughness: e } = a, t = zM();
|
|
@@ -23361,7 +23363,7 @@ class VM extends Vi {
|
|
|
23361
23363
|
let p = jy;
|
|
23362
23364
|
p = p.setZ(p.w);
|
|
23363
23365
|
const f = new it();
|
|
23364
|
-
f.name = "Background.material", f.side =
|
|
23366
|
+
f.name = "Background.material", f.side = Wt, f.depthTest = !1, f.depthWrite = !1, f.allowOverride = !1, f.fog = !1, f.lights = !1, f.vertexNode = p, f.colorNode = d, l.backgroundMeshNode = d, l.backgroundMesh = h = new fi(new dd(1, 32, 32), f), h.frustumCulled = !1, h.name = "Background.mesh", h.onBeforeRender = function(y, g, x) {
|
|
23365
23367
|
this.matrixWorld.copyPosition(x.matrixWorld);
|
|
23366
23368
|
}, n.addEventListener("dispose", m);
|
|
23367
23369
|
}
|
|
@@ -23391,7 +23393,7 @@ class fu {
|
|
|
23391
23393
|
this.name = e, this.bindings = t, this.index = s, this.bindingsReference = i, this.id = HM++;
|
|
23392
23394
|
}
|
|
23393
23395
|
}
|
|
23394
|
-
class
|
|
23396
|
+
class $M {
|
|
23395
23397
|
/**
|
|
23396
23398
|
* Constructs a new node builder state.
|
|
23397
23399
|
*
|
|
@@ -23440,7 +23442,7 @@ function l0(a) {
|
|
|
23440
23442
|
}
|
|
23441
23443
|
return e;
|
|
23442
23444
|
}
|
|
23443
|
-
function
|
|
23445
|
+
function WM(a) {
|
|
23444
23446
|
const e = [];
|
|
23445
23447
|
for (let t = 0; t < a.length; t++)
|
|
23446
23448
|
e.push(a[t].clone());
|
|
@@ -23484,7 +23486,7 @@ class YM extends jt {
|
|
|
23484
23486
|
}, this.index0AttributeName = void 0, this.uniformsNeedUpdate = !1, this.glslVersion = null, e !== void 0 && this.setValues(e);
|
|
23485
23487
|
}
|
|
23486
23488
|
copy(e) {
|
|
23487
|
-
return super.copy(e), this.fragmentShader = e.fragmentShader, this.vertexShader = e.vertexShader, this.uniforms = l0(e.uniforms), this.uniformsGroups =
|
|
23489
|
+
return super.copy(e), this.fragmentShader = e.fragmentShader, this.vertexShader = e.vertexShader, this.uniforms = l0(e.uniforms), this.uniformsGroups = WM(e.uniformsGroups), this.defines = Object.assign({}, e.defines), this.wireframe = e.wireframe, this.wireframeLinewidth = e.wireframeLinewidth, this.fog = e.fog, this.lights = e.lights, this.clipping = e.clipping, this.extensions = Object.assign({}, e.extensions), this.glslVersion = e.glslVersion, this;
|
|
23488
23490
|
}
|
|
23489
23491
|
toJSON(e) {
|
|
23490
23492
|
const t = super.toJSON(e);
|
|
@@ -23601,7 +23603,7 @@ class ZM extends XM {
|
|
|
23601
23603
|
constructor(e = 1, t = {}) {
|
|
23602
23604
|
super(e, e, t), this.isWebGLCubeRenderTarget = !0;
|
|
23603
23605
|
const s = { width: e, height: e, depth: 1 }, i = [s, s, s, s, s, s];
|
|
23604
|
-
this.texture = new
|
|
23606
|
+
this.texture = new $l(i), this._setTextureOptions(t), this.texture.isRenderTargetTexture = !0;
|
|
23605
23607
|
}
|
|
23606
23608
|
/**
|
|
23607
23609
|
* Converts the given equirectangular texture to a cube map.
|
|
@@ -23664,7 +23666,7 @@ class ZM extends XM {
|
|
|
23664
23666
|
uniforms: l0(s.uniforms),
|
|
23665
23667
|
vertexShader: s.vertexShader,
|
|
23666
23668
|
fragmentShader: s.fragmentShader,
|
|
23667
|
-
side:
|
|
23669
|
+
side: Wt,
|
|
23668
23670
|
blending: vr
|
|
23669
23671
|
});
|
|
23670
23672
|
n.uniforms.tEquirect.value = t;
|
|
@@ -23707,7 +23709,7 @@ class h0 extends ZM {
|
|
|
23707
23709
|
const s = t.minFilter, i = t.generateMipmaps;
|
|
23708
23710
|
t.generateMipmaps = !0, this.texture.type = t.type, this.texture.colorSpace = t.colorSpace, this.texture.generateMipmaps = t.generateMipmaps, this.texture.minFilter = t.minFilter, this.texture.magFilter = t.magFilter;
|
|
23709
23711
|
const n = new qa(5, 5, 5), r = Ny(Ry), o = new it();
|
|
23710
|
-
o.colorNode = _e(t, r, 0), o.side =
|
|
23712
|
+
o.colorNode = _e(t, r, 0), o.side = Wt, o.blending = vr;
|
|
23711
23713
|
const l = new fi(n, o), c = new Ou();
|
|
23712
23714
|
c.add(l), t.minFilter === ri && (t.minFilter = is);
|
|
23713
23715
|
const h = new c0(1, 10, this), u = e.getMRT();
|
|
@@ -23726,7 +23728,7 @@ class KM extends nt {
|
|
|
23726
23728
|
*/
|
|
23727
23729
|
constructor(e) {
|
|
23728
23730
|
super("vec3"), this.envNode = e, this._cubeTexture = null, this._cubeTextureNode = za(null);
|
|
23729
|
-
const t = new
|
|
23731
|
+
const t = new $l();
|
|
23730
23732
|
t.isRenderTargetTexture = !0, this._defaultTexture = t, this.updateBeforeType = he.RENDER;
|
|
23731
23733
|
}
|
|
23732
23734
|
updateBefore(e) {
|
|
@@ -23953,7 +23955,7 @@ class iA {
|
|
|
23953
23955
|
this.name = e, this.members = t, this.output = !1;
|
|
23954
23956
|
}
|
|
23955
23957
|
}
|
|
23956
|
-
class
|
|
23958
|
+
class $i {
|
|
23957
23959
|
/**
|
|
23958
23960
|
* Constructs a new uniform.
|
|
23959
23961
|
*
|
|
@@ -23980,7 +23982,7 @@ class Wi {
|
|
|
23980
23982
|
return this.value;
|
|
23981
23983
|
}
|
|
23982
23984
|
}
|
|
23983
|
-
class nA extends
|
|
23985
|
+
class nA extends $i {
|
|
23984
23986
|
/**
|
|
23985
23987
|
* Constructs a new Number uniform.
|
|
23986
23988
|
*
|
|
@@ -23991,7 +23993,7 @@ class nA extends Wi {
|
|
|
23991
23993
|
super(e, t), this.isNumberUniform = !0, this.boundary = 4, this.itemSize = 1;
|
|
23992
23994
|
}
|
|
23993
23995
|
}
|
|
23994
|
-
class rA extends
|
|
23996
|
+
class rA extends $i {
|
|
23995
23997
|
/**
|
|
23996
23998
|
* Constructs a new Number uniform.
|
|
23997
23999
|
*
|
|
@@ -24002,7 +24004,7 @@ class rA extends Wi {
|
|
|
24002
24004
|
super(e, t), this.isVector2Uniform = !0, this.boundary = 8, this.itemSize = 2;
|
|
24003
24005
|
}
|
|
24004
24006
|
}
|
|
24005
|
-
class aA extends
|
|
24007
|
+
class aA extends $i {
|
|
24006
24008
|
/**
|
|
24007
24009
|
* Constructs a new Number uniform.
|
|
24008
24010
|
*
|
|
@@ -24013,7 +24015,7 @@ class aA extends Wi {
|
|
|
24013
24015
|
super(e, t), this.isVector3Uniform = !0, this.boundary = 16, this.itemSize = 3;
|
|
24014
24016
|
}
|
|
24015
24017
|
}
|
|
24016
|
-
class oA extends
|
|
24018
|
+
class oA extends $i {
|
|
24017
24019
|
/**
|
|
24018
24020
|
* Constructs a new Number uniform.
|
|
24019
24021
|
*
|
|
@@ -24024,7 +24026,7 @@ class oA extends Wi {
|
|
|
24024
24026
|
super(e, t), this.isVector4Uniform = !0, this.boundary = 16, this.itemSize = 4;
|
|
24025
24027
|
}
|
|
24026
24028
|
}
|
|
24027
|
-
class lA extends
|
|
24029
|
+
class lA extends $i {
|
|
24028
24030
|
/**
|
|
24029
24031
|
* Constructs a new Number uniform.
|
|
24030
24032
|
*
|
|
@@ -24035,7 +24037,7 @@ class lA extends Wi {
|
|
|
24035
24037
|
super(e, t), this.isColorUniform = !0, this.boundary = 16, this.itemSize = 3;
|
|
24036
24038
|
}
|
|
24037
24039
|
}
|
|
24038
|
-
class cA extends
|
|
24040
|
+
class cA extends $i {
|
|
24039
24041
|
/**
|
|
24040
24042
|
* Constructs a new Number uniform.
|
|
24041
24043
|
*
|
|
@@ -24046,7 +24048,7 @@ class cA extends Wi {
|
|
|
24046
24048
|
super(e, t), this.isMatrix2Uniform = !0, this.boundary = 8, this.itemSize = 4;
|
|
24047
24049
|
}
|
|
24048
24050
|
}
|
|
24049
|
-
class hA extends
|
|
24051
|
+
class hA extends $i {
|
|
24050
24052
|
/**
|
|
24051
24053
|
* Constructs a new Number uniform.
|
|
24052
24054
|
*
|
|
@@ -24057,7 +24059,7 @@ class hA extends Wi {
|
|
|
24057
24059
|
super(e, t), this.isMatrix3Uniform = !0, this.boundary = 48, this.itemSize = 12;
|
|
24058
24060
|
}
|
|
24059
24061
|
}
|
|
24060
|
-
class uA extends
|
|
24062
|
+
class uA extends $i {
|
|
24061
24063
|
/**
|
|
24062
24064
|
* Constructs a new Number uniform.
|
|
24063
24065
|
*
|
|
@@ -26199,7 +26201,7 @@ const x0 = /* @__PURE__ */ B((a) => {
|
|
|
26199
26201
|
{ name: "dotNL", type: "float" }
|
|
26200
26202
|
]
|
|
26201
26203
|
}), GA = /* @__PURE__ */ B(({ lightDirection: a }) => {
|
|
26202
|
-
const e = a.add(qe).normalize(), t = tt.dot(a).clamp(), s = tt.dot(qe).clamp(), i = tt.dot(e).clamp(), n = kA({ roughness:
|
|
26204
|
+
const e = a.add(qe).normalize(), t = tt.dot(a).clamp(), s = tt.dot(qe).clamp(), i = tt.dot(e).clamp(), n = kA({ roughness: Wu, dotNH: i }), r = zA({ dotNV: s, dotNL: t });
|
|
26203
26205
|
return lr.mul(n).mul(r);
|
|
26204
26206
|
}), VA = /* @__PURE__ */ B(({ N: a, V: e, roughness: t }) => {
|
|
26205
26207
|
const n = 78125e-7, r = a.dot(e).saturate(), o = V(t, r.oneMinus().sqrt());
|
|
@@ -26267,15 +26269,15 @@ const x0 = /* @__PURE__ */ B((a) => {
|
|
|
26267
26269
|
{ name: "ior", type: "float" },
|
|
26268
26270
|
{ name: "modelMatrix", type: "mat4" }
|
|
26269
26271
|
]
|
|
26270
|
-
}),
|
|
26272
|
+
}), $A = /* @__PURE__ */ B(([a, e]) => a.mul(pi(e.mul(2).sub(2), 0, 1))).setLayout({
|
|
26271
26273
|
name: "applyIorToRoughness",
|
|
26272
26274
|
type: "float",
|
|
26273
26275
|
inputs: [
|
|
26274
26276
|
{ name: "roughness", type: "float" },
|
|
26275
26277
|
{ name: "ior", type: "float" }
|
|
26276
26278
|
]
|
|
26277
|
-
}),
|
|
26278
|
-
const n = (s.side ===
|
|
26279
|
+
}), WA = /* @__PURE__ */ By(), jA = /* @__PURE__ */ By(), kf = /* @__PURE__ */ B(([a, e, t], { material: s }) => {
|
|
26280
|
+
const n = (s.side === Wt ? WA : jA).sample(a), r = li(cu.x).mul($A(e, t));
|
|
26279
26281
|
return fC(n, r);
|
|
26280
26282
|
}), zf = /* @__PURE__ */ B(([a, e, t]) => (Ke(t.notEqual(0), () => {
|
|
26281
26283
|
const s = cy(e).negate().div(t);
|
|
@@ -26294,10 +26296,10 @@ const x0 = /* @__PURE__ */ B((a) => {
|
|
|
26294
26296
|
m = re().toVar(), y = I().toVar();
|
|
26295
26297
|
const T = h.sub(1).mul(f.mul(0.025)), E = I(h.sub(T), h, h.add(T));
|
|
26296
26298
|
Cs({ start: 0, end: 3 }, ({ i: v }) => {
|
|
26297
|
-
const A = E.element(v), N = Uf(a, e, u, A, o), k = r.add(N), H = c.mul(l.mul(re(k, 1))),
|
|
26298
|
-
|
|
26299
|
-
const
|
|
26300
|
-
m.element(v).assign(
|
|
26299
|
+
const A = E.element(v), N = Uf(a, e, u, A, o), k = r.add(N), H = c.mul(l.mul(re(k, 1))), W = V(H.xy.div(H.w)).toVar();
|
|
26300
|
+
W.addAssign(1), W.divAssign(2), W.assign(V(W.x, W.y.oneMinus()));
|
|
26301
|
+
const $ = kf(W, t, A);
|
|
26302
|
+
m.element(v).assign($.element(v)), m.a.addAssign($.a), y.element(v).assign(s.element(v).mul(zf(ci(N), d, p).element(v)));
|
|
26301
26303
|
}), m.a.divAssign(3);
|
|
26302
26304
|
} else {
|
|
26303
26305
|
const T = Uf(a, e, u, h, o), E = r.add(T), v = c.mul(l.mul(re(E, 1))), A = V(v.xy.div(v.w)).toVar();
|
|
@@ -26486,7 +26488,7 @@ class _0 extends Yl {
|
|
|
26486
26488
|
QA({
|
|
26487
26489
|
normal: tt,
|
|
26488
26490
|
viewDir: qe,
|
|
26489
|
-
roughness:
|
|
26491
|
+
roughness: Wu
|
|
26490
26492
|
})
|
|
26491
26493
|
)), this.clearcoat === !0) {
|
|
26492
26494
|
const h = ga.dot(qe).clamp(), u = x0({
|
|
@@ -26628,7 +26630,7 @@ class JA extends Vi {
|
|
|
26628
26630
|
* @return {NodeBuilderState} The node builder state.
|
|
26629
26631
|
*/
|
|
26630
26632
|
_createNodeBuilderState(e) {
|
|
26631
|
-
return new
|
|
26633
|
+
return new $M(
|
|
26632
26634
|
e.vertexShader,
|
|
26633
26635
|
e.fragmentShader,
|
|
26634
26636
|
e.computeShader,
|
|
@@ -27348,16 +27350,16 @@ class yd extends yi {
|
|
|
27348
27350
|
const v = (t - e) / s;
|
|
27349
27351
|
for (let A = 0; A <= n; A++) {
|
|
27350
27352
|
const N = [], k = A / n, H = k * (t - e) + e;
|
|
27351
|
-
for (let
|
|
27352
|
-
const
|
|
27353
|
-
T.x = H * Z, T.y = -k * s + y, T.z = H * we, u.push(T.x, T.y, T.z), b.set(Z, v, we).normalize(), d.push(b.x, b.y, b.z), p.push(
|
|
27353
|
+
for (let W = 0; W <= i; W++) {
|
|
27354
|
+
const $ = W / i, q = $ * l + o, Z = Math.sin(q), we = Math.cos(q);
|
|
27355
|
+
T.x = H * Z, T.y = -k * s + y, T.z = H * we, u.push(T.x, T.y, T.z), b.set(Z, v, we).normalize(), d.push(b.x, b.y, b.z), p.push($, 1 - k), N.push(f++);
|
|
27354
27356
|
}
|
|
27355
27357
|
m.push(N);
|
|
27356
27358
|
}
|
|
27357
27359
|
for (let A = 0; A < i; A++)
|
|
27358
27360
|
for (let N = 0; N < n; N++) {
|
|
27359
|
-
const k = m[N][A], H = m[N + 1][A],
|
|
27360
|
-
(e > 0 || N !== 0) && (h.push(k, H,
|
|
27361
|
+
const k = m[N][A], H = m[N + 1][A], W = m[N + 1][A + 1], $ = m[N][A + 1];
|
|
27362
|
+
(e > 0 || N !== 0) && (h.push(k, H, $), E += 3), (t > 0 || N !== n - 1) && (h.push(H, W, $), E += 3);
|
|
27361
27363
|
}
|
|
27362
27364
|
c.addGroup(g, E, 0), g += E;
|
|
27363
27365
|
}
|
|
@@ -27365,16 +27367,16 @@ class yd extends yi {
|
|
|
27365
27367
|
const T = f, E = new ce(), v = new R();
|
|
27366
27368
|
let A = 0;
|
|
27367
27369
|
const N = b === !0 ? e : t, k = b === !0 ? 1 : -1;
|
|
27368
|
-
for (let
|
|
27370
|
+
for (let W = 1; W <= i; W++)
|
|
27369
27371
|
u.push(0, y * k, 0), d.push(0, k, 0), p.push(0.5, 0.5), f++;
|
|
27370
27372
|
const H = f;
|
|
27371
|
-
for (let
|
|
27372
|
-
const q =
|
|
27373
|
+
for (let W = 0; W <= i; W++) {
|
|
27374
|
+
const q = W / i * l + o, Z = Math.cos(q), we = Math.sin(q);
|
|
27373
27375
|
v.x = N * we, v.y = y * k, v.z = N * Z, u.push(v.x, v.y, v.z), d.push(0, k, 0), E.x = Z * 0.5 + 0.5, E.y = we * 0.5 * k + 0.5, p.push(E.x, E.y), f++;
|
|
27374
27376
|
}
|
|
27375
|
-
for (let
|
|
27376
|
-
const
|
|
27377
|
-
b === !0 ? h.push(q, q + 1,
|
|
27377
|
+
for (let W = 0; W < i; W++) {
|
|
27378
|
+
const $ = T + W, q = H + W;
|
|
27379
|
+
b === !0 ? h.push(q, q + 1, $) : h.push(q + 1, q, $), A += 3;
|
|
27378
27380
|
}
|
|
27379
27381
|
c.addGroup(g, A, b === !0 ? 1 : 2), g += A;
|
|
27380
27382
|
}
|
|
@@ -27438,7 +27440,7 @@ class xd extends yi {
|
|
|
27438
27440
|
return new xd(e.width, e.height, e.widthSegments, e.heightSegments);
|
|
27439
27441
|
}
|
|
27440
27442
|
}
|
|
27441
|
-
const Hf = /* @__PURE__ */ new R(),
|
|
27443
|
+
const Hf = /* @__PURE__ */ new R(), $f = /* @__PURE__ */ new R();
|
|
27442
27444
|
class oR extends En {
|
|
27443
27445
|
/**
|
|
27444
27446
|
* Constructs a new XR manager.
|
|
@@ -27691,7 +27693,7 @@ class oR extends En {
|
|
|
27691
27693
|
}
|
|
27692
27694
|
);
|
|
27693
27695
|
u.autoAllocateDepthBuffer = !0;
|
|
27694
|
-
const d = new Oi({ color: 16777215, side:
|
|
27696
|
+
const d = new Oi({ color: 16777215, side: Wt });
|
|
27695
27697
|
d.map = u.texture, d.map.offset.y = 1, d.map.repeat.y = -1;
|
|
27696
27698
|
const p = new fi(h, d);
|
|
27697
27699
|
p.position.copy(i), p.quaternion.copy(n);
|
|
@@ -27710,7 +27712,7 @@ class oR extends En {
|
|
|
27710
27712
|
renderTarget: u
|
|
27711
27713
|
};
|
|
27712
27714
|
if (this._layers.push(f), this._session !== null) {
|
|
27713
|
-
f.plane.material = new Oi({ color: 16777215, side:
|
|
27715
|
+
f.plane.material = new Oi({ color: 16777215, side: Wt }), f.plane.material.blending = wa, f.plane.material.blendEquation = Es, f.plane.material.blendSrc = Ri, f.plane.material.blendDst = Ri, f.xrlayer = this._createXRLayer(f);
|
|
27714
27716
|
const m = this._session.renderState.layers;
|
|
27715
27717
|
m.unshift(f.xrlayer), this._session.updateRenderState({ layers: m });
|
|
27716
27718
|
} else
|
|
@@ -27797,7 +27799,7 @@ class oR extends En {
|
|
|
27797
27799
|
}
|
|
27798
27800
|
), this._xrRenderTarget.hasExternalTextures = !0, this._xrRenderTarget.depth = this._useMultiview ? 2 : 1, this._supportsLayers = e.enabledFeatures.includes("layers"), this._referenceSpace = await e.requestReferenceSpace(this.getReferenceSpaceType()), this._supportsLayers)
|
|
27799
27801
|
for (const m of this._layers)
|
|
27800
|
-
m.plane.material = new Oi({ color: 16777215, side: m.type === "cylinder" ?
|
|
27802
|
+
m.plane.material = new Oi({ color: 16777215, side: m.type === "cylinder" ? Wt : ii }), m.plane.material.blending = wa, m.plane.material.blendEquation = Es, m.plane.material.blendSrc = Ri, m.plane.material.blendDst = Ri, m.xrlayer = this._createXRLayer(m), d.unshift(m.xrlayer);
|
|
27801
27803
|
e.updateRenderState({ layers: d });
|
|
27802
27804
|
} else {
|
|
27803
27805
|
const r = {
|
|
@@ -27839,9 +27841,9 @@ class oR extends En {
|
|
|
27839
27841
|
depthFar: n.far
|
|
27840
27842
|
}), this._currentDepthNear = n.near, this._currentDepthFar = n.far), r.layers.mask = e.layers.mask | 2, o.layers.mask = e.layers.mask | 4, n.layers.mask = r.layers.mask | o.layers.mask;
|
|
27841
27843
|
const l = e.parent, c = n.cameras;
|
|
27842
|
-
|
|
27844
|
+
Wf(n, l);
|
|
27843
27845
|
for (let h = 0; h < c.length; h++)
|
|
27844
|
-
|
|
27846
|
+
Wf(c[h], l);
|
|
27845
27847
|
c.length === 2 ? lR(n, r, o) : n.projectionMatrix.copy(r.projectionMatrix), cR(e, n, l);
|
|
27846
27848
|
}
|
|
27847
27849
|
/**
|
|
@@ -27857,8 +27859,8 @@ class oR extends En {
|
|
|
27857
27859
|
}
|
|
27858
27860
|
}
|
|
27859
27861
|
function lR(a, e, t) {
|
|
27860
|
-
Hf.setFromMatrixPosition(e.matrixWorld),
|
|
27861
|
-
const s = Hf.distanceTo(
|
|
27862
|
+
Hf.setFromMatrixPosition(e.matrixWorld), $f.setFromMatrixPosition(t.matrixWorld);
|
|
27863
|
+
const s = Hf.distanceTo($f), i = e.projectionMatrix.elements, n = t.projectionMatrix.elements, r = i[14] / (i[10] - 1), o = i[14] / (i[10] + 1), l = (i[9] + 1) / i[5], c = (i[9] - 1) / i[5], h = (i[8] - 1) / i[0], u = (n[8] + 1) / n[0], d = r * h, p = r * u, f = s / (-h + u), m = f * -h;
|
|
27862
27864
|
if (e.matrixWorld.decompose(a.position, a.quaternion, a.scale), a.translateX(m), a.translateZ(f), a.matrixWorld.compose(a.position, a.quaternion, a.scale), a.matrixWorldInverse.copy(a.matrixWorld).invert(), i[10] === -1)
|
|
27863
27865
|
a.projectionMatrix.copy(e.projectionMatrix), a.projectionMatrixInverse.copy(e.projectionMatrixInverse);
|
|
27864
27866
|
else {
|
|
@@ -27866,7 +27868,7 @@ function lR(a, e, t) {
|
|
|
27866
27868
|
a.projectionMatrix.makePerspective(x, _, b, T, y, g), a.projectionMatrixInverse.copy(a.projectionMatrix).invert();
|
|
27867
27869
|
}
|
|
27868
27870
|
}
|
|
27869
|
-
function
|
|
27871
|
+
function Wf(a, e) {
|
|
27870
27872
|
e === null ? a.matrixWorld.copy(a.matrix) : a.matrixWorld.multiplyMatrices(e.matrixWorld, a.matrix), a.matrixWorldInverse.copy(a.matrixWorld).invert();
|
|
27871
27873
|
}
|
|
27872
27874
|
function cR(a, e, t) {
|
|
@@ -28426,7 +28428,7 @@ class mR {
|
|
|
28426
28428
|
* @type {boolean}
|
|
28427
28429
|
*/
|
|
28428
28430
|
set highPrecision(e) {
|
|
28429
|
-
e === !0 ? (this.overrideNodes.modelViewMatrix = Hp, this.overrideNodes.modelNormalViewMatrix =
|
|
28431
|
+
e === !0 ? (this.overrideNodes.modelViewMatrix = Hp, this.overrideNodes.modelNormalViewMatrix = $p) : this.highPrecision && (this.overrideNodes.modelViewMatrix = null, this.overrideNodes.modelNormalViewMatrix = null);
|
|
28430
28432
|
}
|
|
28431
28433
|
/**
|
|
28432
28434
|
* Returns whether high precision is enabled or not.
|
|
@@ -28435,7 +28437,7 @@ class mR {
|
|
|
28435
28437
|
* @type {boolean}
|
|
28436
28438
|
*/
|
|
28437
28439
|
get highPrecision() {
|
|
28438
|
-
return this.overrideNodes.modelViewMatrix === Hp && this.overrideNodes.modelNormalViewMatrix ===
|
|
28440
|
+
return this.overrideNodes.modelViewMatrix === Hp && this.overrideNodes.modelNormalViewMatrix === $p;
|
|
28439
28441
|
}
|
|
28440
28442
|
/**
|
|
28441
28443
|
* Sets the given MRT configuration.
|
|
@@ -28566,8 +28568,8 @@ Reason: ${e.reason}`), console.error(t), this._isDeviceLost = !0;
|
|
|
28566
28568
|
this._currentRenderContext = f, this._currentRenderObjectFunction = this._renderObjectFunction || this.renderObject, this.info.calls++, this.info.render.calls++, this.info.render.frameCalls++, n.renderId = this.info.calls;
|
|
28567
28569
|
const m = this.coordinateSystem, y = this.xr;
|
|
28568
28570
|
if (t.coordinateSystem !== m && y.isPresenting === !1 && (t.coordinateSystem = m, t.updateProjectionMatrix(), t.isArrayCamera))
|
|
28569
|
-
for (const
|
|
28570
|
-
|
|
28571
|
+
for (const $ of t.cameras)
|
|
28572
|
+
$.coordinateSystem = m, $.updateProjectionMatrix();
|
|
28571
28573
|
e.matrixWorldAutoUpdate === !0 && e.updateMatrixWorld(), t.parent === null && t.matrixWorldAutoUpdate === !0 && t.updateMatrixWorld(), y.enabled === !0 && y.isPresenting === !0 && (y.cameraAutoUpdate === !0 && y.updateCamera(t), t = y.getCamera());
|
|
28572
28574
|
let g = this._viewport, x = this._scissor, _ = this._pixelRatio;
|
|
28573
28575
|
p !== null && (g = p.viewport, x = p.scissor, _ = 1), this.getDrawingBufferSize(Po), ih.set(0, 0, Po.width, Po.height);
|
|
@@ -28578,8 +28580,8 @@ Reason: ${e.reason}`), console.error(t), this._isDeviceLost = !0;
|
|
|
28578
28580
|
const v = this._renderLists.get(e, t);
|
|
28579
28581
|
if (v.begin(), this._projectObject(e, t, 0, v, f.clippingContext), v.finish(), this.sortObjects === !0 && v.sort(this._opaqueSort, this._transparentSort), p !== null) {
|
|
28580
28582
|
this._textures.updateRenderTarget(p, d);
|
|
28581
|
-
const
|
|
28582
|
-
f.textures =
|
|
28583
|
+
const $ = this._textures.get(p);
|
|
28584
|
+
f.textures = $.textures, f.depthTexture = $.depthTexture, f.width = $.width, f.height = $.height, f.renderTarget = p, f.depth = p.depthBuffer, f.stencil = p.stencilBuffer;
|
|
28583
28585
|
} else
|
|
28584
28586
|
f.textures = null, f.depthTexture = null, f.width = this.domElement.width, f.height = this.domElement.height, f.depth = this.depth, f.stencil = this.stencil;
|
|
28585
28587
|
f.width >>= d, f.height >>= d, f.activeCubeFace = u, f.activeMipmapLevel = d, f.occlusionQueryCount = v.occlusionQueryCount, this._background.update(c, v, f), f.camera = t, this.backend.beginRender(f);
|
|
@@ -28588,9 +28590,9 @@ Reason: ${e.reason}`), console.error(t), this._isDeviceLost = !0;
|
|
|
28588
28590
|
lightsNode: N,
|
|
28589
28591
|
transparentDoublePass: k,
|
|
28590
28592
|
transparent: H,
|
|
28591
|
-
opaque:
|
|
28593
|
+
opaque: W
|
|
28592
28594
|
} = v;
|
|
28593
|
-
return A.length > 0 && this._renderBundles(A, c, N), this.opaque === !0 &&
|
|
28595
|
+
return A.length > 0 && this._renderBundles(A, c, N), this.opaque === !0 && W.length > 0 && this._renderObjects(W, t, c, N), this.transparent === !0 && H.length > 0 && this._renderTransparents(H, k, t, c, N), this.backend.finishRender(f), n.renderId = r, this._currentRenderContext = o, this._currentRenderObjectFunction = l, i !== null && (this.setRenderTarget(h, u, d), this._renderOutput(p)), c.onAfterRender(this, e, t, p), f;
|
|
28594
28596
|
}
|
|
28595
28597
|
_setXRLayerSize(e, t) {
|
|
28596
28598
|
this._width = e, this._height = t, this.setViewport(0, 0, e, t);
|
|
@@ -29305,7 +29307,7 @@ Reason: ${e.reason}`), console.error(t), this._isDeviceLost = !0;
|
|
|
29305
29307
|
_renderTransparents(e, t, s, i, n) {
|
|
29306
29308
|
if (t.length > 0) {
|
|
29307
29309
|
for (const { material: r } of t)
|
|
29308
|
-
r.side =
|
|
29310
|
+
r.side = Wt;
|
|
29309
29311
|
this._renderObjects(t, s, i, n, "backSide");
|
|
29310
29312
|
for (const { material: r } of t)
|
|
29311
29313
|
r.side = ii;
|
|
@@ -29351,7 +29353,7 @@ Reason: ${e.reason}`), console.error(t), this._isDeviceLost = !0;
|
|
|
29351
29353
|
const p = t.overrideMaterial;
|
|
29352
29354
|
n.positionNode && n.positionNode.isNode && (h = p.positionNode, p.positionNode = n.positionNode), p.alphaTest = n.alphaTest, p.alphaMap = n.alphaMap, p.transparent = n.transparent || n.transmission > 0, p.isShadowPassMaterial && (p.side = n.shadowSide === null ? n.side : n.shadowSide, n.depthNode && n.depthNode.isNode && (d = p.depthNode, p.depthNode = n.depthNode), n.castShadowNode && n.castShadowNode.isNode && (u = p.colorNode, p.colorNode = n.castShadowNode), n.castShadowPositionNode && n.castShadowPositionNode.isNode && (h = p.positionNode, p.positionNode = n.castShadowPositionNode)), n = p;
|
|
29353
29355
|
}
|
|
29354
|
-
n.transparent === !0 && n.side === dr && n.forceSinglePass === !1 ? (n.side =
|
|
29356
|
+
n.transparent === !0 && n.side === dr && n.forceSinglePass === !1 ? (n.side = Wt, this._handleObjectFunction(e, n, t, s, o, r, l, "backSide"), n.side = ii, this._handleObjectFunction(e, n, t, s, o, r, l, c), n.side = dr) : this._handleObjectFunction(e, n, t, s, o, r, l, c), h !== void 0 && (t.overrideMaterial.positionNode = h), d !== void 0 && (t.overrideMaterial.depthNode = d), u !== void 0 && (t.overrideMaterial.colorNode = u), e.onAfterRender(this, t, s, i, n, r);
|
|
29355
29357
|
}
|
|
29356
29358
|
/**
|
|
29357
29359
|
* This method represents the default `_handleObjectFunction` implementation which creates
|
|
@@ -31596,7 +31598,7 @@ class PR {
|
|
|
31596
31598
|
setMaterial(e, t, s) {
|
|
31597
31599
|
const { gl: i } = this;
|
|
31598
31600
|
e.side === dr ? this.disable(i.CULL_FACE) : this.enable(i.CULL_FACE);
|
|
31599
|
-
let n = e.side ===
|
|
31601
|
+
let n = e.side === Wt;
|
|
31600
31602
|
t && (n = !n), this.setFlipSided(n), e.blending === ni && e.transparent === !1 ? this.setBlending(vr) : this.setBlending(e.blending, e.blendEquation, e.blendSrc, e.blendDst, e.blendEquationAlpha, e.blendSrcAlpha, e.blendDstAlpha, e.premultipliedAlpha), this.setDepthFunc(e.depthFunc), this.setDepthTest(e.depthTest), this.setDepthMask(e.depthWrite), this.setColorMask(e.colorWrite);
|
|
31601
31603
|
const r = e.stencilWrite;
|
|
31602
31604
|
if (this.setStencilTest(r), r && (this.setStencilMask(e.stencilWriteMask), this.setStencilFunc(e.stencilFunc, e.stencilRef, e.stencilFuncMask), this.setStencilOp(e.stencilFail, e.stencilZFail, e.stencilZPass)), this.setPolygonOffset(e.polygonOffset, e.polygonOffsetFactor, e.polygonOffsetUnits), e.alphaToCoverage === !0 && this.backend.renderer.samples > 1 ? this.enable(i.SAMPLE_ALPHA_TO_COVERAGE) : this.disable(i.SAMPLE_ALPHA_TO_COVERAGE), s > 0 && this.currentClippingPlanes !== s)
|
|
@@ -31816,12 +31818,12 @@ class DR {
|
|
|
31816
31818
|
if (e === Gh) return r === se ? n.COMPRESSED_SRGB8_ALPHA8_ETC2_EAC : n.COMPRESSED_RGBA8_ETC2_EAC;
|
|
31817
31819
|
} else
|
|
31818
31820
|
return null;
|
|
31819
|
-
if (e === Vh || e === Hh || e ===
|
|
31821
|
+
if (e === Vh || e === Hh || e === $h || e === Wh || e === jh || e === qh || e === Yh || e === Xh || e === Zh || e === Kh || e === Qh || e === Jh || e === eu || e === tu)
|
|
31820
31822
|
if (n = i.get("WEBGL_compressed_texture_astc"), n !== null) {
|
|
31821
31823
|
if (e === Vh) return r === se ? n.COMPRESSED_SRGB8_ALPHA8_ASTC_4x4_KHR : n.COMPRESSED_RGBA_ASTC_4x4_KHR;
|
|
31822
31824
|
if (e === Hh) return r === se ? n.COMPRESSED_SRGB8_ALPHA8_ASTC_5x4_KHR : n.COMPRESSED_RGBA_ASTC_5x4_KHR;
|
|
31823
|
-
if (e ===
|
|
31824
|
-
if (e ===
|
|
31825
|
+
if (e === $h) return r === se ? n.COMPRESSED_SRGB8_ALPHA8_ASTC_5x5_KHR : n.COMPRESSED_RGBA_ASTC_5x5_KHR;
|
|
31826
|
+
if (e === Wh) return r === se ? n.COMPRESSED_SRGB8_ALPHA8_ASTC_6x5_KHR : n.COMPRESSED_RGBA_ASTC_6x5_KHR;
|
|
31825
31827
|
if (e === jh) return r === se ? n.COMPRESSED_SRGB8_ALPHA8_ASTC_6x6_KHR : n.COMPRESSED_RGBA_ASTC_6x6_KHR;
|
|
31826
31828
|
if (e === qh) return r === se ? n.COMPRESSED_SRGB8_ALPHA8_ASTC_8x5_KHR : n.COMPRESSED_RGBA_ASTC_8x5_KHR;
|
|
31827
31829
|
if (e === Yh) return r === se ? n.COMPRESSED_SRGB8_ALPHA8_ASTC_8x6_KHR : n.COMPRESSED_RGBA_ASTC_8x6_KHR;
|
|
@@ -32107,17 +32109,17 @@ class FR {
|
|
|
32107
32109
|
f = Math.floor(v.width * q), m = Math.floor(v.height * q), e.isDataArrayTexture || e.isArrayTexture ? y = v.depth : e.isData3DTexture ? y = Math.floor(v.depth * q) : y = 1, g = 0, x = 0, _ = 0;
|
|
32108
32110
|
}
|
|
32109
32111
|
i !== null ? (b = i.x, T = i.y, E = i.z) : (b = 0, T = 0, E = 0), o.pixelStorei(o.UNPACK_FLIP_Y_WEBGL, t.flipY), o.pixelStorei(o.UNPACK_PREMULTIPLY_ALPHA_WEBGL, t.premultiplyAlpha), o.pixelStorei(o.UNPACK_ALIGNMENT, t.unpackAlignment);
|
|
32110
|
-
const A = o.getParameter(o.UNPACK_ROW_LENGTH), N = o.getParameter(o.UNPACK_IMAGE_HEIGHT), k = o.getParameter(o.UNPACK_SKIP_PIXELS), H = o.getParameter(o.UNPACK_SKIP_ROWS),
|
|
32112
|
+
const A = o.getParameter(o.UNPACK_ROW_LENGTH), N = o.getParameter(o.UNPACK_IMAGE_HEIGHT), k = o.getParameter(o.UNPACK_SKIP_PIXELS), H = o.getParameter(o.UNPACK_SKIP_ROWS), W = o.getParameter(o.UNPACK_SKIP_IMAGES);
|
|
32111
32113
|
o.pixelStorei(o.UNPACK_ROW_LENGTH, v.width), o.pixelStorei(o.UNPACK_IMAGE_HEIGHT, v.height), o.pixelStorei(o.UNPACK_SKIP_PIXELS, g), o.pixelStorei(o.UNPACK_SKIP_ROWS, x), o.pixelStorei(o.UNPACK_SKIP_IMAGES, _);
|
|
32112
|
-
const
|
|
32114
|
+
const $ = t.isDataArrayTexture || t.isData3DTexture || t.isArrayTexture;
|
|
32113
32115
|
if (e.isRenderTargetTexture || e.isDepthTexture) {
|
|
32114
32116
|
const q = l.get(e), Z = l.get(t), we = l.get(q.renderTarget), ue = l.get(Z.renderTarget), ge = we.framebuffers[q.cacheKey], ie = ue.framebuffers[Z.cacheKey];
|
|
32115
32117
|
c.bindFramebuffer(o.READ_FRAMEBUFFER, ge), c.bindFramebuffer(o.DRAW_FRAMEBUFFER, ie);
|
|
32116
32118
|
let Ee = o.COLOR_BUFFER_BIT;
|
|
32117
32119
|
e.isDepthTexture && (Ee = o.DEPTH_BUFFER_BIT), o.blitFramebuffer(g, x, f, m, b, T, f, m, Ee, o.NEAREST), c.bindFramebuffer(o.READ_FRAMEBUFFER, null), c.bindFramebuffer(o.DRAW_FRAMEBUFFER, null);
|
|
32118
32120
|
} else
|
|
32119
|
-
|
|
32120
|
-
o.pixelStorei(o.UNPACK_ROW_LENGTH, A), o.pixelStorei(o.UNPACK_IMAGE_HEIGHT, N), o.pixelStorei(o.UNPACK_SKIP_PIXELS, k), o.pixelStorei(o.UNPACK_SKIP_ROWS, H), o.pixelStorei(o.UNPACK_SKIP_IMAGES,
|
|
32121
|
+
$ ? e.isDataTexture || e.isData3DTexture ? o.texSubImage3D(u, r, b, T, E, f, m, y, p, d, v.data) : t.isCompressedArrayTexture ? o.compressedTexSubImage3D(u, r, b, T, E, f, m, y, p, v.data) : o.texSubImage3D(u, r, b, T, E, f, m, y, p, d, v) : e.isDataTexture ? o.texSubImage2D(u, r, b, T, f, m, p, d, v.data) : e.isCompressedTexture ? o.compressedTexSubImage2D(u, r, b, T, v.width, v.height, p, v.data) : o.texSubImage2D(u, r, b, T, f, m, p, d, v);
|
|
32122
|
+
o.pixelStorei(o.UNPACK_ROW_LENGTH, A), o.pixelStorei(o.UNPACK_IMAGE_HEIGHT, N), o.pixelStorei(o.UNPACK_SKIP_PIXELS, k), o.pixelStorei(o.UNPACK_SKIP_ROWS, H), o.pixelStorei(o.UNPACK_SKIP_IMAGES, W), r === 0 && t.generateMipmaps && o.generateMipmap(u), c.unbindTexture();
|
|
32121
32123
|
}
|
|
32122
32124
|
/**
|
|
32123
32125
|
* Copies the current bound framebuffer to the given texture.
|
|
@@ -32914,12 +32916,12 @@ class sm extends M0 {
|
|
|
32914
32916
|
}
|
|
32915
32917
|
v.indexesGPU = we;
|
|
32916
32918
|
}
|
|
32917
|
-
const k = this.get(N), H = this.renderer.getPixelRatio(),
|
|
32918
|
-
if (
|
|
32919
|
-
const Z = this.get(
|
|
32919
|
+
const k = this.get(N), H = this.renderer.getPixelRatio(), W = this._currentContext.renderTarget, $ = this._isRenderCameraDepthArray(this._currentContext), q = this._currentContext.activeCubeFace;
|
|
32920
|
+
if ($) {
|
|
32921
|
+
const Z = this.get(W.depthTexture);
|
|
32920
32922
|
if (Z.clearedRenderId !== this.renderer._nodes.nodeFrame.renderId) {
|
|
32921
32923
|
Z.clearedRenderId = this.renderer._nodes.nodeFrame.renderId;
|
|
32922
|
-
const { stencilBuffer: we } =
|
|
32924
|
+
const { stencilBuffer: we } = W;
|
|
32923
32925
|
for (let ue = 0, ge = A.length; ue < ge; ue++)
|
|
32924
32926
|
this.renderer._activeCubeFace = ue, this._currentContext.activeCubeFace = ue, this._setFramebuffer(this._currentContext), this.clear(!1, !0, we, this._currentContext, !1);
|
|
32925
32927
|
this.renderer._activeCubeFace = q, this._currentContext.activeCubeFace = q;
|
|
@@ -32928,7 +32930,7 @@ class sm extends M0 {
|
|
|
32928
32930
|
for (let Z = 0, we = A.length; Z < we; Z++) {
|
|
32929
32931
|
const ue = A[Z];
|
|
32930
32932
|
if (t.layers.test(ue.layers)) {
|
|
32931
|
-
|
|
32933
|
+
$ && (this.renderer._activeCubeFace = Z, this._currentContext.activeCubeFace = Z, this._setFramebuffer(this._currentContext));
|
|
32932
32934
|
const ge = ue.viewport;
|
|
32933
32935
|
if (ge !== void 0) {
|
|
32934
32936
|
const ie = ge.x * H, Ee = ge.y * H, ze = ge.width * H, at = ge.height * H;
|
|
@@ -33379,7 +33381,7 @@ void main() {}`
|
|
|
33379
33381
|
if (e.textures !== null) {
|
|
33380
33382
|
const n = e.renderTarget, r = this.get(n), { samples: o, depthBuffer: l, stencilBuffer: c } = n, h = n.isWebGLCubeRenderTarget === !0, u = n.isRenderTarget3D === !0, d = n.depth > 1, p = n.isXRRenderTarget === !0, f = p === !0 && n.hasExternalTextures === !0;
|
|
33381
33383
|
let m = r.msaaFrameBuffer, y = r.depthRenderbuffer;
|
|
33382
|
-
const g = this.extensions.get("WEBGL_multisampled_render_to_texture"), x = this.extensions.get("OVR_multiview2"), _ = this._useMultisampledExtension(n), b =
|
|
33384
|
+
const g = this.extensions.get("WEBGL_multisampled_render_to_texture"), x = this.extensions.get("OVR_multiview2"), _ = this._useMultisampledExtension(n), b = Wg(e);
|
|
33383
33385
|
let T;
|
|
33384
33386
|
if (h ? (r.cubeFramebuffers || (r.cubeFramebuffers = {}), T = r.cubeFramebuffers[b]) : p && f === !1 ? T = this._xrFramebuffer : (r.framebuffers || (r.framebuffers = {}), T = r.framebuffers[b]), T === void 0) {
|
|
33385
33387
|
T = t.createFramebuffer(), s.bindFramebuffer(t.FRAMEBUFFER, T);
|
|
@@ -33393,14 +33395,14 @@ void main() {}`
|
|
|
33393
33395
|
for (let N = 0; N < E.length; N++) {
|
|
33394
33396
|
const k = E[N], H = this.get(k);
|
|
33395
33397
|
H.renderTarget = e.renderTarget, H.cacheKey = b;
|
|
33396
|
-
const
|
|
33398
|
+
const W = t.COLOR_ATTACHMENT0 + N;
|
|
33397
33399
|
if (n.multiview)
|
|
33398
|
-
x.framebufferTextureMultisampleMultiviewOVR(t.FRAMEBUFFER,
|
|
33400
|
+
x.framebufferTextureMultisampleMultiviewOVR(t.FRAMEBUFFER, W, H.textureGPU, 0, o, 0, 2);
|
|
33399
33401
|
else if (u || d) {
|
|
33400
|
-
const
|
|
33401
|
-
t.framebufferTextureLayer(t.FRAMEBUFFER,
|
|
33402
|
+
const $ = this.renderer._activeCubeFace;
|
|
33403
|
+
t.framebufferTextureLayer(t.FRAMEBUFFER, W, H.textureGPU, 0, $);
|
|
33402
33404
|
} else
|
|
33403
|
-
_ ? g.framebufferTexture2DMultisampleEXT(t.FRAMEBUFFER,
|
|
33405
|
+
_ ? g.framebufferTexture2DMultisampleEXT(t.FRAMEBUFFER, W, t.TEXTURE_2D, H.textureGPU, 0, o) : t.framebufferTexture2D(t.FRAMEBUFFER, W, t.TEXTURE_2D, H.textureGPU, 0);
|
|
33404
33406
|
}
|
|
33405
33407
|
s.drawBuffers(e, T);
|
|
33406
33408
|
}
|
|
@@ -33455,8 +33457,8 @@ void main() {}`
|
|
|
33455
33457
|
const v = [], A = e.textures;
|
|
33456
33458
|
for (let N = 0; N < A.length; N++) {
|
|
33457
33459
|
if (v[N] = t.createRenderbuffer(), t.bindRenderbuffer(t.RENDERBUFFER, v[N]), E.push(t.COLOR_ATTACHMENT0 + N), l) {
|
|
33458
|
-
const
|
|
33459
|
-
E.push(
|
|
33460
|
+
const W = c ? t.DEPTH_STENCIL_ATTACHMENT : t.DEPTH_ATTACHMENT;
|
|
33461
|
+
E.push(W);
|
|
33460
33462
|
}
|
|
33461
33463
|
const k = e.textures[N], H = this.get(k);
|
|
33462
33464
|
t.renderbufferStorageMultisample(t.RENDERBUFFER, o, H.glInternalFormat, e.width, e.height), t.framebufferRenderbuffer(t.FRAMEBUFFER, t.COLOR_ATTACHMENT0 + N, t.RENDERBUFFER, v[N]);
|
|
@@ -33864,7 +33866,7 @@ class HR extends GR {
|
|
|
33864
33866
|
return this.nodeUniform.value;
|
|
33865
33867
|
}
|
|
33866
33868
|
}
|
|
33867
|
-
class
|
|
33869
|
+
class $R extends Vi {
|
|
33868
33870
|
/**
|
|
33869
33871
|
* Constructs a new utility object.
|
|
33870
33872
|
*
|
|
@@ -34116,7 +34118,7 @@ fn main( @location( 0 ) vTex : vec2<f32> ) -> @location( 0 ) vec4<f32> {
|
|
|
34116
34118
|
}
|
|
34117
34119
|
}
|
|
34118
34120
|
}
|
|
34119
|
-
const
|
|
34121
|
+
const WR = {
|
|
34120
34122
|
[Ag]: "never",
|
|
34121
34123
|
[Du]: "less",
|
|
34122
34124
|
[Rg]: "equal",
|
|
@@ -34150,7 +34152,7 @@ class qR {
|
|
|
34150
34152
|
mipmapFilter: this._convertFilterMode(e.minFilter),
|
|
34151
34153
|
maxAnisotropy: 1
|
|
34152
34154
|
};
|
|
34153
|
-
n.magFilter === fn.Linear && n.minFilter === fn.Linear && n.mipmapFilter === fn.Linear && (n.maxAnisotropy = e.anisotropy), e.isDepthTexture && e.compareFunction !== null && (n.compare =
|
|
34155
|
+
n.magFilter === fn.Linear && n.minFilter === fn.Linear && n.mipmapFilter === fn.Linear && (n.maxAnisotropy = e.anisotropy), e.isDepthTexture && e.compareFunction !== null && (n.compare = WR[e.compareFunction]), i.sampler = s.createSampler(n);
|
|
34154
34156
|
}
|
|
34155
34157
|
/**
|
|
34156
34158
|
* Creates a default texture for the given texture that can be used
|
|
@@ -34375,7 +34377,7 @@ class qR {
|
|
|
34375
34377
|
_getDefaultCubeTextureGPU(e) {
|
|
34376
34378
|
let t = this.defaultTexture[e];
|
|
34377
34379
|
if (t === void 0) {
|
|
34378
|
-
const s = new
|
|
34380
|
+
const s = new $l();
|
|
34379
34381
|
s.minFilter = ut, s.magFilter = ut, this.createTexture(s, { width: 1, height: 1, depth: 6 }), this.defaultCubeTexture[e] = t = s;
|
|
34380
34382
|
}
|
|
34381
34383
|
return this.backend.get(t).texture;
|
|
@@ -34453,7 +34455,7 @@ class qR {
|
|
|
34453
34455
|
*/
|
|
34454
34456
|
_getPassUtils() {
|
|
34455
34457
|
let e = this._passUtils;
|
|
34456
|
-
return e === null && (this._passUtils = e = new
|
|
34458
|
+
return e === null && (this._passUtils = e = new $R(this.backend.device)), e;
|
|
34457
34459
|
}
|
|
34458
34460
|
/**
|
|
34459
34461
|
* Generates mipmaps for the given GPU texture.
|
|
@@ -34696,10 +34698,10 @@ function gu(a, e = null) {
|
|
|
34696
34698
|
case Hh:
|
|
34697
34699
|
r = n === se ? w.ASTC5x4UnormSRGB : w.ASTC5x4Unorm;
|
|
34698
34700
|
break;
|
|
34699
|
-
case
|
|
34701
|
+
case $h:
|
|
34700
34702
|
r = n === se ? w.ASTC5x5UnormSRGB : w.ASTC5x5Unorm;
|
|
34701
34703
|
break;
|
|
34702
|
-
case
|
|
34704
|
+
case Wh:
|
|
34703
34705
|
r = n === se ? w.ASTC6x5UnormSRGB : w.ASTC6x5Unorm;
|
|
34704
34706
|
break;
|
|
34705
34707
|
case jh:
|
|
@@ -36695,8 +36697,8 @@ class c1 {
|
|
|
36695
36697
|
*/
|
|
36696
36698
|
createRenderPipeline(e, t) {
|
|
36697
36699
|
const { object: s, material: i, geometry: n, pipeline: r } = e, { vertexProgram: o, fragmentProgram: l } = r, c = this.backend, h = c.device, u = c.utils, d = c.get(r), p = [];
|
|
36698
|
-
for (const
|
|
36699
|
-
const q = c.get(
|
|
36700
|
+
for (const $ of e.getBindings()) {
|
|
36701
|
+
const q = c.get($);
|
|
36700
36702
|
p.push(q.layout);
|
|
36701
36703
|
}
|
|
36702
36704
|
const f = c.attributeUtils.createShaderVertexBuffers(e);
|
|
@@ -36711,9 +36713,9 @@ class c1 {
|
|
|
36711
36713
|
});
|
|
36712
36714
|
const g = this._getColorWriteMask(i), x = [];
|
|
36713
36715
|
if (e.context.textures !== null) {
|
|
36714
|
-
const
|
|
36715
|
-
for (let q = 0; q <
|
|
36716
|
-
const Z = u.getTextureFormatGPU(
|
|
36716
|
+
const $ = e.context.textures;
|
|
36717
|
+
for (let q = 0; q < $.length; q++) {
|
|
36718
|
+
const Z = u.getTextureFormatGPU($[q]);
|
|
36717
36719
|
x.push({
|
|
36718
36720
|
format: Z,
|
|
36719
36721
|
blend: m,
|
|
@@ -36721,9 +36723,9 @@ class c1 {
|
|
|
36721
36723
|
});
|
|
36722
36724
|
}
|
|
36723
36725
|
} else {
|
|
36724
|
-
const
|
|
36726
|
+
const $ = u.getCurrentColorFormat(e.context);
|
|
36725
36727
|
x.push({
|
|
36726
|
-
format:
|
|
36728
|
+
format: $,
|
|
36727
36729
|
blend: m,
|
|
36728
36730
|
writeMask: g
|
|
36729
36731
|
});
|
|
@@ -36740,16 +36742,16 @@ class c1 {
|
|
|
36740
36742
|
layout: h.createPipelineLayout({
|
|
36741
36743
|
bindGroupLayouts: p
|
|
36742
36744
|
})
|
|
36743
|
-
}, k = {}, H = e.context.depth,
|
|
36744
|
-
if ((H === !0 ||
|
|
36745
|
+
}, k = {}, H = e.context.depth, W = e.context.stencil;
|
|
36746
|
+
if ((H === !0 || W === !0) && (H === !0 && (k.format = v, k.depthWriteEnabled = i.depthWrite, k.depthCompare = E), W === !0 && (k.stencilFront = y, k.stencilBack = {}, k.stencilReadMask = i.stencilFuncMask, k.stencilWriteMask = i.stencilWriteMask), i.polygonOffset === !0 && (k.depthBias = i.polygonOffsetUnits, k.depthBiasSlopeScale = i.polygonOffsetFactor, k.depthBiasClamp = 0), N.depthStencil = k), t === null)
|
|
36745
36747
|
d.pipeline = h.createRenderPipeline(N);
|
|
36746
36748
|
else {
|
|
36747
|
-
const
|
|
36749
|
+
const $ = new Promise((q) => {
|
|
36748
36750
|
h.createRenderPipelineAsync(N).then((Z) => {
|
|
36749
36751
|
d.pipeline = Z, q();
|
|
36750
36752
|
});
|
|
36751
36753
|
});
|
|
36752
|
-
t.push(
|
|
36754
|
+
t.push($);
|
|
36753
36755
|
}
|
|
36754
36756
|
}
|
|
36755
36757
|
/**
|
|
@@ -36969,7 +36971,7 @@ class c1 {
|
|
|
36969
36971
|
case zb:
|
|
36970
36972
|
t = Ei.Replace;
|
|
36971
36973
|
break;
|
|
36972
|
-
case
|
|
36974
|
+
case Wb:
|
|
36973
36975
|
t = Ei.Invert;
|
|
36974
36976
|
break;
|
|
36975
36977
|
case Gb:
|
|
@@ -36981,7 +36983,7 @@ class c1 {
|
|
|
36981
36983
|
case Hb:
|
|
36982
36984
|
t = Ei.IncrementWrap;
|
|
36983
36985
|
break;
|
|
36984
|
-
case
|
|
36986
|
+
case $b:
|
|
36985
36987
|
t = Ei.DecrementWrap;
|
|
36986
36988
|
break;
|
|
36987
36989
|
default:
|
|
@@ -37035,7 +37037,7 @@ class c1 {
|
|
|
37035
37037
|
case ii:
|
|
37036
37038
|
i.frontFace = ch.CCW, i.cullMode = hh.Back;
|
|
37037
37039
|
break;
|
|
37038
|
-
case
|
|
37040
|
+
case Wt:
|
|
37039
37041
|
i.frontFace = ch.CCW, i.cullMode = hh.Front;
|
|
37040
37042
|
break;
|
|
37041
37043
|
case dr:
|
|
@@ -38607,7 +38609,7 @@ class x1 extends P0 {
|
|
|
38607
38609
|
}
|
|
38608
38610
|
if (this.useSheen) {
|
|
38609
38611
|
const t = this.sheenNode ? I(this.sheenNode) : _E, s = this.sheenRoughnessNode ? O(this.sheenRoughnessNode) : bE;
|
|
38610
|
-
lr.assign(t),
|
|
38612
|
+
lr.assign(t), Wu.assign(s);
|
|
38611
38613
|
}
|
|
38612
38614
|
if (this.useIridescence) {
|
|
38613
38615
|
const t = this.iridescenceNode ? O(this.iridescenceNode) : SE, s = this.iridescenceIORNode ? O(this.iridescenceIORNode) : vE, i = this.iridescenceThicknessNode ? O(this.iridescenceThicknessNode) : wE;
|
|
@@ -38752,7 +38754,7 @@ class C1 extends it {
|
|
|
38752
38754
|
* @return {Node<vec3>} The normal node.
|
|
38753
38755
|
*/
|
|
38754
38756
|
setupNormal() {
|
|
38755
|
-
return
|
|
38757
|
+
return Ws;
|
|
38756
38758
|
}
|
|
38757
38759
|
/**
|
|
38758
38760
|
* Overwritten since this type of material uses {@link BasicEnvironmentNode}
|
|
@@ -38774,7 +38776,7 @@ class C1 extends it {
|
|
|
38774
38776
|
*/
|
|
38775
38777
|
setupLightMap(e) {
|
|
38776
38778
|
let t = null;
|
|
38777
|
-
return e.material.lightMap && (t = new w1(
|
|
38779
|
+
return e.material.lightMap && (t = new w1(Wy)), t;
|
|
38778
38780
|
}
|
|
38779
38781
|
/**
|
|
38780
38782
|
* The material overwrites this method because `lights` is set to `true` but
|
|
@@ -38879,7 +38881,7 @@ class D1 extends it {
|
|
|
38879
38881
|
* based on the normal data.
|
|
38880
38882
|
*/
|
|
38881
38883
|
setupDiffuseColor() {
|
|
38882
|
-
const e = this.opacityNode ? O(this.opacityNode) :
|
|
38884
|
+
const e = this.opacityNode ? O(this.opacityNode) : $y;
|
|
38883
38885
|
Se.assign(Ju(re(Aw(tt), e), es));
|
|
38884
38886
|
}
|
|
38885
38887
|
}
|
|
@@ -39086,8 +39088,8 @@ class H1 extends jt {
|
|
|
39086
39088
|
return super.copy(e), this.color.copy(e.color), this.map = e.map, this.alphaMap = e.alphaMap, this.size = e.size, this.sizeAttenuation = e.sizeAttenuation, this.fog = e.fog, this;
|
|
39087
39089
|
}
|
|
39088
39090
|
}
|
|
39089
|
-
const
|
|
39090
|
-
class
|
|
39091
|
+
const $1 = /* @__PURE__ */ new H1();
|
|
39092
|
+
class W1 extends F0 {
|
|
39091
39093
|
static get type() {
|
|
39092
39094
|
return "PointsNodeMaterial";
|
|
39093
39095
|
}
|
|
@@ -39097,7 +39099,7 @@ class $1 extends F0 {
|
|
|
39097
39099
|
* @param {Object} [parameters] - The configuration parameter.
|
|
39098
39100
|
*/
|
|
39099
39101
|
constructor(e) {
|
|
39100
|
-
super(), this.sizeNode = null, this.isPointsNodeMaterial = !0, this.setDefaultValues(
|
|
39102
|
+
super(), this.sizeNode = null, this.isPointsNodeMaterial = !0, this.setDefaultValues($1), this.setValues(e);
|
|
39101
39103
|
}
|
|
39102
39104
|
setupPositionView() {
|
|
39103
39105
|
const { positionNode: e } = this;
|
|
@@ -39779,7 +39781,7 @@ class lN extends b0 {
|
|
|
39779
39781
|
* Constructs a new standard node library.
|
|
39780
39782
|
*/
|
|
39781
39783
|
constructor() {
|
|
39782
|
-
super(), this.addMaterial(f1, "MeshPhongMaterial"), this.addMaterial(P0, "MeshStandardMaterial"), this.addMaterial(x1, "MeshPhysicalMaterial"), this.addMaterial(v1, "MeshToonMaterial"), this.addMaterial(C1, "MeshBasicMaterial"), this.addMaterial(R1, "MeshLambertMaterial"), this.addMaterial(D1, "MeshNormalMaterial"), this.addMaterial(I1, "MeshMatcapMaterial"), this.addMaterial(L1, "LineBasicMaterial"), this.addMaterial(z1, "LineDashedMaterial"), this.addMaterial(
|
|
39784
|
+
super(), this.addMaterial(f1, "MeshPhongMaterial"), this.addMaterial(P0, "MeshStandardMaterial"), this.addMaterial(x1, "MeshPhysicalMaterial"), this.addMaterial(v1, "MeshToonMaterial"), this.addMaterial(C1, "MeshBasicMaterial"), this.addMaterial(R1, "MeshLambertMaterial"), this.addMaterial(D1, "MeshNormalMaterial"), this.addMaterial(I1, "MeshMatcapMaterial"), this.addMaterial(L1, "LineBasicMaterial"), this.addMaterial(z1, "LineDashedMaterial"), this.addMaterial(W1, "PointsMaterial"), this.addMaterial(F0, "SpriteMaterial"), this.addMaterial(X1, "ShadowMaterial"), this.addLight(pM, K1), this.addLight(TA, J1), this.addLight(SA, eN), this.addLight(fd, vd), this.addLight(CA, sN), this.addLight(MA, iN), this.addLight(AA, rN), this.addLight(vA, aN), this.addLight(EA, oN), this.addToneMapping(TC, Mb), this.addToneMapping(SC, Ab), this.addToneMapping(vC, Rb), this.addToneMapping(EC, Nb), this.addToneMapping(RC, Pb), this.addToneMapping(NC, Db);
|
|
39783
39785
|
}
|
|
39784
39786
|
}
|
|
39785
39787
|
class Bo extends mR {
|
|
@@ -40384,8 +40386,8 @@ function ym(a, e, t, s, i = 1 / 0, n, r) {
|
|
|
40384
40386
|
h = a.x - p, u = a.y - f, d = a.z - m;
|
|
40385
40387
|
const E = (t.x + o * p) * n, v = (t.y + o * f) * n, A = (t.z + o * m) * n;
|
|
40386
40388
|
t.x = (t.x - o * E) * c, t.y = (t.y - o * v) * c, t.z = (t.z - o * A) * c, r.x = h + (p + E) * c, r.y = u + (f + v) * c, r.z = d + (m + A) * c;
|
|
40387
|
-
const N = y - a.x, k = g - a.y, H = x - a.z,
|
|
40388
|
-
return N *
|
|
40389
|
+
const N = y - a.x, k = g - a.y, H = x - a.z, W = r.x - y, $ = r.y - g, q = r.z - x;
|
|
40390
|
+
return N * W + k * $ + H * q > 0 && (r.x = y, r.y = g, r.z = x, t.x = (r.x - y) / n, t.y = (r.y - g) / n, t.z = (r.z - x) / n), r;
|
|
40389
40391
|
}
|
|
40390
40392
|
function yh(a, e) {
|
|
40391
40393
|
e.set(0, 0), a.forEach((t) => {
|
|
@@ -41920,7 +41922,7 @@ class FN extends Zm {
|
|
|
41920
41922
|
});
|
|
41921
41923
|
}
|
|
41922
41924
|
}
|
|
41923
|
-
const nn = new Da(), St = new K(), Ci = new K(),
|
|
41925
|
+
const nn = new Da(), St = new K(), Ci = new K(), $e = new Jt(), vm = {
|
|
41924
41926
|
X: new K(1, 0, 0),
|
|
41925
41927
|
Y: new K(0, 1, 0),
|
|
41926
41928
|
Z: new K(0, 0, 1)
|
|
@@ -41992,7 +41994,7 @@ class ON extends Xm {
|
|
|
41992
41994
|
const r = Ch(this._plane, nn, !0);
|
|
41993
41995
|
if (r) {
|
|
41994
41996
|
if (this.pointEnd.copy(r.point).sub(this.worldPositionStart), s === "translate")
|
|
41995
|
-
this._offset.copy(this.pointEnd).sub(this.pointStart), n === "local" && t !== "XYZ" && this._offset.applyQuaternion(this._worldQuaternionInv), t.indexOf("X") === -1 && (this._offset.x = 0), t.indexOf("Y") === -1 && (this._offset.y = 0), t.indexOf("Z") === -1 && (this._offset.z = 0), n === "local" && t !== "XYZ" ? this._offset.applyQuaternion(this._quaternionStart).divide(this._parentScale) : this._offset.applyQuaternion(this._parentQuaternionInv).divide(this._parentScale), i.position.copy(this._offset).add(this._positionStart), this.translationSnap && (n === "local" && (i.position.applyQuaternion(
|
|
41997
|
+
this._offset.copy(this.pointEnd).sub(this.pointStart), n === "local" && t !== "XYZ" && this._offset.applyQuaternion(this._worldQuaternionInv), t.indexOf("X") === -1 && (this._offset.x = 0), t.indexOf("Y") === -1 && (this._offset.y = 0), t.indexOf("Z") === -1 && (this._offset.z = 0), n === "local" && t !== "XYZ" ? this._offset.applyQuaternion(this._quaternionStart).divide(this._parentScale) : this._offset.applyQuaternion(this._parentQuaternionInv).divide(this._parentScale), i.position.copy(this._offset).add(this._positionStart), this.translationSnap && (n === "local" && (i.position.applyQuaternion($e.copy(this._quaternionStart).invert()), t.search("X") !== -1 && (i.position.x = Math.round(i.position.x / this.translationSnap) * this.translationSnap), t.search("Y") !== -1 && (i.position.y = Math.round(i.position.y / this.translationSnap) * this.translationSnap), t.search("Z") !== -1 && (i.position.z = Math.round(i.position.z / this.translationSnap) * this.translationSnap), i.position.applyQuaternion(this._quaternionStart)), n === "world" && (i.parent && i.position.add(St.setFromMatrixPosition(i.parent.matrixWorld)), t.search("X") !== -1 && (i.position.x = Math.round(i.position.x / this.translationSnap) * this.translationSnap), t.search("Y") !== -1 && (i.position.y = Math.round(i.position.y / this.translationSnap) * this.translationSnap), t.search("Z") !== -1 && (i.position.z = Math.round(i.position.z / this.translationSnap) * this.translationSnap), i.parent && i.position.sub(St.setFromMatrixPosition(i.parent.matrixWorld)))), i.position.x = Math.max(this.minX, Math.min(this.maxX, i.position.x)), i.position.y = Math.max(this.minY, Math.min(this.maxY, i.position.y)), i.position.z = Math.max(this.minZ, Math.min(this.maxZ, i.position.z));
|
|
41996
41998
|
else if (s === "scale") {
|
|
41997
41999
|
if (t.search("XYZ") !== -1) {
|
|
41998
42000
|
let o = this.pointEnd.length() / this.pointStart.length();
|
|
@@ -42004,7 +42006,7 @@ class ON extends Xm {
|
|
|
42004
42006
|
this._offset.copy(this.pointEnd).sub(this.pointStart);
|
|
42005
42007
|
const o = 20 / this.worldPosition.distanceTo(St.setFromMatrixPosition(this.camera.matrixWorld));
|
|
42006
42008
|
let l = !1;
|
|
42007
|
-
t === "XYZE" ? (this.rotationAxis.copy(this._offset).cross(this.eye).normalize(), this.rotationAngle = this._offset.dot(St.copy(this.rotationAxis).cross(this.eye)) * o) : (t === "X" || t === "Y" || t === "Z") && (this.rotationAxis.copy(vm[t]), St.copy(vm[t]), n === "local" && St.applyQuaternion(this.worldQuaternion), St.cross(this.eye), St.length() === 0 ? l = !0 : this.rotationAngle = this._offset.dot(St.normalize()) * o), (t === "E" || l) && (this.rotationAxis.copy(this.eye), this.rotationAngle = this.pointEnd.angleTo(this.pointStart), this._startNorm.copy(this.pointStart).normalize(), this._endNorm.copy(this.pointEnd).normalize(), this.rotationAngle *= this._endNorm.cross(this._startNorm).dot(this.eye) < 0 ? 1 : -1), this.rotationSnap && (this.rotationAngle = Math.round(this.rotationAngle / this.rotationSnap) * this.rotationSnap), n === "local" && t !== "E" && t !== "XYZE" ? (i.quaternion.copy(this._quaternionStart), i.quaternion.multiply(
|
|
42009
|
+
t === "XYZE" ? (this.rotationAxis.copy(this._offset).cross(this.eye).normalize(), this.rotationAngle = this._offset.dot(St.copy(this.rotationAxis).cross(this.eye)) * o) : (t === "X" || t === "Y" || t === "Z") && (this.rotationAxis.copy(vm[t]), St.copy(vm[t]), n === "local" && St.applyQuaternion(this.worldQuaternion), St.cross(this.eye), St.length() === 0 ? l = !0 : this.rotationAngle = this._offset.dot(St.normalize()) * o), (t === "E" || l) && (this.rotationAxis.copy(this.eye), this.rotationAngle = this.pointEnd.angleTo(this.pointStart), this._startNorm.copy(this.pointStart).normalize(), this._endNorm.copy(this.pointEnd).normalize(), this.rotationAngle *= this._endNorm.cross(this._startNorm).dot(this.eye) < 0 ? 1 : -1), this.rotationSnap && (this.rotationAngle = Math.round(this.rotationAngle / this.rotationSnap) * this.rotationSnap), n === "local" && t !== "E" && t !== "XYZE" ? (i.quaternion.copy(this._quaternionStart), i.quaternion.multiply($e.setFromAxisAngle(this.rotationAxis, this.rotationAngle)).normalize()) : (this.rotationAxis.applyQuaternion(this._parentQuaternionInv), i.quaternion.copy($e.setFromAxisAngle(this.rotationAxis, this.rotationAngle)), i.quaternion.multiply(this._quaternionStart).normalize());
|
|
42008
42010
|
}
|
|
42009
42011
|
this.dispatchEvent(Eh), this.dispatchEvent(Cm);
|
|
42010
42012
|
}
|
|
@@ -42145,7 +42147,7 @@ function Ch(a, e, t) {
|
|
|
42145
42147
|
return s[i];
|
|
42146
42148
|
return !1;
|
|
42147
42149
|
}
|
|
42148
|
-
const Vo = new Jm(), Oe = new K(0, 1, 0), Mm = new K(0, 0, 0), Am = new Rl(), Ho = new Jt(), nl = new Jt(), Is = new K(), Rm = new Rl(), ba = new K(1, 0, 0), hn = new K(0, 1, 0), Ta = new K(0, 0, 1),
|
|
42150
|
+
const Vo = new Jm(), Oe = new K(0, 1, 0), Mm = new K(0, 0, 0), Am = new Rl(), Ho = new Jt(), nl = new Jt(), Is = new K(), Rm = new Rl(), ba = new K(1, 0, 0), hn = new K(0, 1, 0), Ta = new K(0, 0, 1), $o = new K(), ha = new K(), ua = new K();
|
|
42149
42151
|
class zN extends Tr {
|
|
42150
42152
|
constructor(e) {
|
|
42151
42153
|
super(), this.isTransformControlsRoot = !0, this.controls = e, this.visible = !1;
|
|
@@ -42350,7 +42352,7 @@ class GN extends Tr {
|
|
|
42350
42352
|
XYZ: [
|
|
42351
42353
|
[new X(new Tt(0.1, 0.1, 0.1), u.clone())]
|
|
42352
42354
|
]
|
|
42353
|
-
},
|
|
42355
|
+
}, W = {
|
|
42354
42356
|
X: [
|
|
42355
42357
|
[new X(new kt(0.2, 0, 0.6, 4), s), [0.3, 0, 0], [0, 0, -Math.PI / 2]],
|
|
42356
42358
|
[new X(new kt(0.2, 0, 0.6, 4), s), [-0.3, 0, 0], [0, 0, Math.PI / 2]]
|
|
@@ -42375,7 +42377,7 @@ class GN extends Tr {
|
|
|
42375
42377
|
XYZ: [
|
|
42376
42378
|
[new X(new Tt(0.2, 0.2, 0.2), s), [0, 0, 0]]
|
|
42377
42379
|
]
|
|
42378
|
-
},
|
|
42380
|
+
}, $ = {
|
|
42379
42381
|
X: [
|
|
42380
42382
|
[new Ls(g, i.clone()), [-1e3, 0, 0], null, [1e6, 1, 1], "helper"]
|
|
42381
42383
|
],
|
|
@@ -42397,7 +42399,7 @@ class GN extends Tr {
|
|
|
42397
42399
|
}
|
|
42398
42400
|
return we;
|
|
42399
42401
|
}
|
|
42400
|
-
this.gizmo = {}, this.picker = {}, this.helper = {}, this.add(this.gizmo.translate = q(T)), this.add(this.gizmo.rotate = q(A)), this.add(this.gizmo.scale = q(H)), this.add(this.picker.translate = q(E)), this.add(this.picker.rotate = q(k)), this.add(this.picker.scale = q(
|
|
42402
|
+
this.gizmo = {}, this.picker = {}, this.helper = {}, this.add(this.gizmo.translate = q(T)), this.add(this.gizmo.rotate = q(A)), this.add(this.gizmo.scale = q(H)), this.add(this.picker.translate = q(E)), this.add(this.picker.rotate = q(k)), this.add(this.picker.scale = q(W)), this.add(this.helper.translate = q(v)), this.add(this.helper.rotate = q(N)), this.add(this.helper.scale = q($)), this.picker.translate.visible = !1, this.picker.rotate.visible = !1, this.picker.scale.visible = !1;
|
|
42401
42403
|
}
|
|
42402
42404
|
// updateMatrixWorld will update transformations and appearance of individual handles
|
|
42403
42405
|
updateMatrixWorld(e) {
|
|
@@ -42410,10 +42412,10 @@ class GN extends Tr {
|
|
|
42410
42412
|
r.visible = !0, r.rotation.set(0, 0, 0), r.position.copy(this.worldPosition);
|
|
42411
42413
|
let o;
|
|
42412
42414
|
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), r.scale.set(1, 1, 1).multiplyScalar(o * this.size / 4), r.tag === "helper") {
|
|
42413
|
-
r.visible = !1, r.name === "AXIS" ? (r.visible = !!this.axis, this.axis === "X" && (
|
|
42415
|
+
r.visible = !1, r.name === "AXIS" ? (r.visible = !!this.axis, this.axis === "X" && ($e.setFromEuler(Vo.set(0, 0, 0)), r.quaternion.copy(s).multiply($e), Math.abs(Oe.copy(ba).applyQuaternion(s).dot(this.eye)) > 0.9 && (r.visible = !1)), this.axis === "Y" && ($e.setFromEuler(Vo.set(0, 0, Math.PI / 2)), r.quaternion.copy(s).multiply($e), Math.abs(Oe.copy(hn).applyQuaternion(s).dot(this.eye)) > 0.9 && (r.visible = !1)), this.axis === "Z" && ($e.setFromEuler(Vo.set(0, Math.PI / 2, 0)), r.quaternion.copy(s).multiply($e), Math.abs(Oe.copy(Ta).applyQuaternion(s).dot(this.eye)) > 0.9 && (r.visible = !1)), this.axis === "XYZE" && ($e.setFromEuler(Vo.set(0, Math.PI / 2, 0)), Oe.copy(this.rotationAxis), r.quaternion.setFromRotationMatrix(Am.lookAt(Mm, Oe, hn)), r.quaternion.multiply($e), r.visible = this.dragging), this.axis === "E" && (r.visible = !1)) : r.name === "START" ? (r.position.copy(this.worldPositionStart), r.visible = this.dragging) : r.name === "END" ? (r.position.copy(this.worldPosition), r.visible = this.dragging) : r.name === "DELTA" ? (r.position.copy(this.worldPositionStart), r.quaternion.copy(this.worldQuaternionStart), St.set(1e-10, 1e-10, 1e-10).add(this.worldPositionStart).sub(this.worldPosition).multiplyScalar(-1), St.applyQuaternion(this.worldQuaternionStart.clone().invert()), r.scale.copy(St), r.visible = this.dragging) : (r.quaternion.copy(s), this.dragging ? r.position.copy(this.worldPositionStart) : r.position.copy(this.worldPosition), this.axis && (r.visible = this.axis.search(r.name) !== -1));
|
|
42414
42416
|
continue;
|
|
42415
42417
|
}
|
|
42416
|
-
r.quaternion.copy(s), this.mode === "translate" || this.mode === "scale" ? (r.name === "X" && Math.abs(Oe.copy(ba).applyQuaternion(s).dot(this.eye)) > 0.99 && (r.scale.set(1e-10, 1e-10, 1e-10), r.visible = !1), r.name === "Y" && Math.abs(Oe.copy(hn).applyQuaternion(s).dot(this.eye)) > 0.99 && (r.scale.set(1e-10, 1e-10, 1e-10), r.visible = !1), r.name === "Z" && Math.abs(Oe.copy(Ta).applyQuaternion(s).dot(this.eye)) > 0.99 && (r.scale.set(1e-10, 1e-10, 1e-10), r.visible = !1), r.name === "XY" && Math.abs(Oe.copy(Ta).applyQuaternion(s).dot(this.eye)) < 0.2 && (r.scale.set(1e-10, 1e-10, 1e-10), r.visible = !1), r.name === "YZ" && Math.abs(Oe.copy(ba).applyQuaternion(s).dot(this.eye)) < 0.2 && (r.scale.set(1e-10, 1e-10, 1e-10), r.visible = !1), r.name === "XZ" && Math.abs(Oe.copy(hn).applyQuaternion(s).dot(this.eye)) < 0.2 && (r.scale.set(1e-10, 1e-10, 1e-10), r.visible = !1)) : this.mode === "rotate" && (Ho.copy(s), Oe.copy(this.eye).applyQuaternion(
|
|
42418
|
+
r.quaternion.copy(s), this.mode === "translate" || this.mode === "scale" ? (r.name === "X" && Math.abs(Oe.copy(ba).applyQuaternion(s).dot(this.eye)) > 0.99 && (r.scale.set(1e-10, 1e-10, 1e-10), r.visible = !1), r.name === "Y" && Math.abs(Oe.copy(hn).applyQuaternion(s).dot(this.eye)) > 0.99 && (r.scale.set(1e-10, 1e-10, 1e-10), r.visible = !1), r.name === "Z" && Math.abs(Oe.copy(Ta).applyQuaternion(s).dot(this.eye)) > 0.99 && (r.scale.set(1e-10, 1e-10, 1e-10), r.visible = !1), r.name === "XY" && Math.abs(Oe.copy(Ta).applyQuaternion(s).dot(this.eye)) < 0.2 && (r.scale.set(1e-10, 1e-10, 1e-10), r.visible = !1), r.name === "YZ" && Math.abs(Oe.copy(ba).applyQuaternion(s).dot(this.eye)) < 0.2 && (r.scale.set(1e-10, 1e-10, 1e-10), r.visible = !1), r.name === "XZ" && Math.abs(Oe.copy(hn).applyQuaternion(s).dot(this.eye)) < 0.2 && (r.scale.set(1e-10, 1e-10, 1e-10), r.visible = !1)) : this.mode === "rotate" && (Ho.copy(s), Oe.copy(this.eye).applyQuaternion($e.copy(s).invert()), r.name.search("E") !== -1 && r.quaternion.setFromRotationMatrix(Am.lookAt(this.eye, Mm, hn)), r.name === "X" && ($e.setFromAxisAngle(ba, Math.atan2(-Oe.y, Oe.z)), $e.multiplyQuaternions(Ho, $e), r.quaternion.copy($e)), r.name === "Y" && ($e.setFromAxisAngle(hn, Math.atan2(Oe.x, Oe.z)), $e.multiplyQuaternions(Ho, $e), r.quaternion.copy($e)), r.name === "Z" && ($e.setFromAxisAngle(Ta, Math.atan2(Oe.y, Oe.x)), $e.multiplyQuaternions(Ho, $e), r.quaternion.copy($e))), r.visible = r.visible && (r.name.indexOf("X") === -1 || this.showX), r.visible = r.visible && (r.name.indexOf("Y") === -1 || this.showY), r.visible = r.visible && (r.name.indexOf("Z") === -1 || this.showZ), r.visible = r.visible && (r.name.indexOf("E") === -1 || this.showX && this.showY && this.showZ), r.material._color = r.material._color || r.material.color.clone(), r.material._opacity = r.material._opacity || r.material.opacity, r.material.color.copy(r.material._color), r.material.opacity = r.material._opacity, this.enabled && this.axis && (r.name === this.axis || this.axis.split("").some(function(l) {
|
|
42417
42419
|
return r.name === l;
|
|
42418
42420
|
})) && (r.material.color.setHex(16776960), r.material.opacity = 1);
|
|
42419
42421
|
}
|
|
@@ -42429,12 +42431,12 @@ class VN extends X {
|
|
|
42429
42431
|
}
|
|
42430
42432
|
updateMatrixWorld(e) {
|
|
42431
42433
|
let t = this.space;
|
|
42432
|
-
switch (this.position.copy(this.worldPosition), this.mode === "scale" && (t = "local"),
|
|
42434
|
+
switch (this.position.copy(this.worldPosition), this.mode === "scale" && (t = "local"), $o.copy(ba).applyQuaternion(t === "local" ? this.worldQuaternion : nl), ha.copy(hn).applyQuaternion(t === "local" ? this.worldQuaternion : nl), ua.copy(Ta).applyQuaternion(t === "local" ? this.worldQuaternion : nl), Oe.copy(ha), this.mode) {
|
|
42433
42435
|
case "translate":
|
|
42434
42436
|
case "scale":
|
|
42435
42437
|
switch (this.axis) {
|
|
42436
42438
|
case "X":
|
|
42437
|
-
Oe.copy(this.eye).cross(
|
|
42439
|
+
Oe.copy(this.eye).cross($o), Is.copy($o).cross(Oe);
|
|
42438
42440
|
break;
|
|
42439
42441
|
case "Y":
|
|
42440
42442
|
Oe.copy(this.eye).cross(ha), Is.copy(ha).cross(Oe);
|
|
@@ -42446,7 +42448,7 @@ class VN extends X {
|
|
|
42446
42448
|
Is.copy(ua);
|
|
42447
42449
|
break;
|
|
42448
42450
|
case "YZ":
|
|
42449
|
-
Is.copy(
|
|
42451
|
+
Is.copy($o);
|
|
42450
42452
|
break;
|
|
42451
42453
|
case "XZ":
|
|
42452
42454
|
Oe.copy(ua), Is.copy(ha);
|
|
@@ -42865,8 +42867,8 @@ class Ah extends Tr {
|
|
|
42865
42867
|
e.name, e.visible = this.draggable.visible;
|
|
42866
42868
|
};
|
|
42867
42869
|
}
|
|
42868
|
-
let
|
|
42869
|
-
class
|
|
42870
|
+
let Wo = 0;
|
|
42871
|
+
class $N extends Tr {
|
|
42870
42872
|
defaultScale = 10;
|
|
42871
42873
|
currentSpline = null;
|
|
42872
42874
|
_camera;
|
|
@@ -42952,8 +42954,8 @@ class WN extends Tr {
|
|
|
42952
42954
|
e.draggableScale = this.defaultScale, e.hideTransform(), this.group?.current !== null && e.initDebug(this.group.current), this.add(e), this.currentSpline = e;
|
|
42953
42955
|
}
|
|
42954
42956
|
createSpline = (e = []) => {
|
|
42955
|
-
const t = `Spline ${
|
|
42956
|
-
return s.addPoints(e), this.addSpline(s),
|
|
42957
|
+
const t = `Spline ${Wo + 1}`, s = new Ah(t, this._camera);
|
|
42958
|
+
return s.addPoints(e), this.addSpline(s), Wo++, s;
|
|
42957
42959
|
};
|
|
42958
42960
|
createSplineFromArray = (e) => {
|
|
42959
42961
|
const t = [];
|
|
@@ -42976,12 +42978,12 @@ class WN extends Tr {
|
|
|
42976
42978
|
});
|
|
42977
42979
|
};
|
|
42978
42980
|
onAddSpline = (e) => {
|
|
42979
|
-
const t = JSON.parse(e.value), s = `Spline ${
|
|
42981
|
+
const t = JSON.parse(e.value), s = `Spline ${Wo + 1}`, i = [];
|
|
42980
42982
|
t.points.forEach((r) => {
|
|
42981
42983
|
i.push(new K(r[0], r[1], r[2]));
|
|
42982
42984
|
});
|
|
42983
42985
|
const n = new Ah(s, this.camera);
|
|
42984
|
-
n.addPoints(i), this.addSpline(n),
|
|
42986
|
+
n.addPoints(i), this.addSpline(n), Wo++;
|
|
42985
42987
|
};
|
|
42986
42988
|
isMouseDown = !1;
|
|
42987
42989
|
enableClickToDraw() {
|
|
@@ -43055,7 +43057,7 @@ const Nm = [
|
|
|
43055
43057
|
"Side by Side",
|
|
43056
43058
|
"Stacked",
|
|
43057
43059
|
"Quad"
|
|
43058
|
-
],
|
|
43060
|
+
], WN = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACgAAAAoCAYAAACM/rhtAAAACXBIWXMAAAsTAAALEwEAmpwYAAAC60lEQVRYhe2YT4hNcRTHP48xpmYaNAvRyEQxEhnKQljYsRm9/EmSyJiMFAsMZWNhJYoNIUVJ2VGiyb9ZzIpMpkQSahbGv9GMYWrM+1rc2zjvzvvdd+99rzdvMd+6de75nd+5387vnN/v/G5KEuWMKRNNIB8mCRaKiiL5qQb2ApuBuUAV0Ad0AJeB3sSeJRX6LJbULTf6JTUn9Z+KWMUpPyp/Avoa4CNQZ3Sj/lNpdL/xottR7AjOkHRUUpekN5I6JbVLavDH75lIfZN0UFKTpCWS0pJem/HeJBEMG6yV1ONYtgFJbZJ+GF1jDh+zJb03NuliEuwMkMo4yErS2RA/LcbuYVyCrm1mA7Dal/8Cu4FG4JD/HsTTkCy6a+SVMTPQuc1sBKb78nHghi+/A+YBxwL2lbhRY+ThuARdEVxu5JdGFvACr0otdoZ8Y4+Rn0Sn5sFFsMvI6YB9MzA1YJ8mN8k1wAHzfj4uQVdyrpI0aJL7oqTtkq4FiqPLyCOSbktqlbRL0jlJQ2b8QdwCUZ4qvhRStZL0XFK1pMd57CRvq5mfhKBriRfiFUMY6oD7eOdwPlQAN4G10dfWg+uouwXsiOssAj4AC+JMcEWwvnAuOTEr7gTXPmg34zagOwkbIIOXAo9CbDYBrcBXYN+4UUdy2sRflyS5zVNlfPX7ugpJW5V9nI7mmh+lYU0lCZ2B3TOnAVuAk0BTwC5nuhWro46KauBOQJch5OpRaoIW34GreGf+YZdRqS9NAj4Bp4ClQDvwOWxCqSM4ADQEdKE5XvbXzlITrAVe4TW+M6NMKDXBFLAMuAD0ACfIc7pMZBXXA2cY3/xmodQRHAL2A2+NLtj8ZiEKwUL/z2WMPAJcAVYALWSf8dZuDFGWeBHwKxm3sWYhiGG8Tfo6sA2vSfiSy4GrH3wGrDcfKSSKKf6v1E9yF0XK9Q1XBPuMXMw8HXTonQFwETwNzMFr64v1jzgFHIk9ybHEZYPJo65QlD3Bf2/Q/eaHPiSWAAAAAElFTkSuQmCC", jN = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACgAAAAoCAYAAACM/rhtAAAACXBIWXMAAAsTAAALEwEAmpwYAAAETklEQVRYhe2YXYhVVRTHf3d0/JhyUrMpFbImM+whSa3Mynww+4AeIgiKoozooQ+KyMyXIAujF6OXqHyI6iEKKYgIP/owsjSFqCkprdDUTEcjbWZ0HHV+Pex1ucfb9Z57Z9REXHA4Z++99l7/s/ZZ/7X2KaiczNLwfwPIk9MA+yunNMAG4DHgV+BvoB3YFff2TPstYEyfrajVroI6Sr1GvahsbJC63HzZq04pmztSvU5tVRuqYRiYg78JeBR4HPg5ntdmxovz9wJfA3uAxuibDLQCA+IqynnAQuBuYCnwMLC1rx48U12U8cZqdWqMDcx4cI16qTpYbVKHqa+ovWUeHKsujn7VL9ULq2HI+wY7gVeBJdGeFu3J4ZUiy/cAXeHRRuAQsC/GC0B3eG4BcH/0tUV7czUAeVsMsBF4Kha9HZgCvAncAuwPnXHA0wFuGLANuDrGuoGDwFxgTqzzQ7RX5FrP2eLsdb76vnogtme6+nE8H1YPlQXHwbi3q9eqn0e7Tb25VrsF68vFY0lb1AGcDTwItGQ8tQM4AIwGmqP/EPAu8A0wElgJfFGzxTo8mKWXu9Rd4ZF96jvqjSbauEC9Sn1O3R463epLaku99voCsFXdkAH3kNpcQW+IiT/bQne3eufxBtioPqP2mKhioXpWzpxb1T8C5Ifh4ZptVoriRmAIKdrI3Lujf3bobAPeJpF0NVkKrAFuI9HTOBIxnxFrF4OgQKKr/dnJlQA+AcwABgOHA4zAamA5cE7orQL+zAEHiWI+A2bFC7aSguheYCgpqAphZz3wSB7AecCICv2TgH8oFRib4gVqka0k0h8CXAxMBW6ooDejFoCvA9OBQUAvKWM0kDz4XUZvNKXtyZMWUl7vBbaQXq457PeEziDgx/KJlQAuIPFdMcEXv5OdYWBP9M8k8VpnDQCvB4aTSrCNJB5cSdrW3tBpIJVnR0qdUTxAfdGUOVTnmwqEanNmqltC/9OgqePKg5eom8PgdvW+oJ9Kupera0O3U50TL3lcAaI+oHaF4R3qa6Z822wq0Saq89T1lmSxOrxeW/Xm4uGkiqQDmECKuKHxHW0HdpMiewSpvGqKeR8Ay0iBsYIjg6261PE2o9Q3Yqv+MqWxO9R1Hl12qs+q49Vlppy82pSr+5xJKsko4AXgHlJ0t5NIeg3wLXAlqZhtIUV8J6nmWwX8QiLjdhL5TwMWkY4R6/rrwYKlMr1Y321QZ/vfwBijPqm+rF4Wc7PjE9QllurGVeoV5gRNHsAm9fnMom3qrKPoTjKdMXaYyrFygEWQ72XWW24qhPu8xcUc2UU6O8wFPjmK7jhgPHAuMJGUGQ6U6WwE5sfzTXGvei7KA9hFOiR9D/wOfFVFt4dS2tpfRe83Ur7/CPiJakfOGgBCypubatArl2r8VfOax/LfzABKtePAzHO/5FgC7KBEzB2kOrDfUm8mOeFySv9+OyFyGmB/5aQH+C9BVKmVCNuMZgAAAABJRU5ErkJggg==", qN = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABUAAAAVCAYAAACpF6WWAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAQ0lEQVQ4jWP8////fwYqAxYozUhFM/8zkaKYWIWkGEq0b0ZdSjQY5i79TyWagRGaTUdzFEEw6lLqGzqwLoVVJ1StpwA9sBwbUqAh5gAAAABJRU5ErkJggg==";
|
|
43059
43061
|
class ht extends Va {
|
|
43060
43062
|
static instance = null;
|
|
43061
43063
|
app;
|
|
@@ -43344,7 +43346,7 @@ class ht extends Va {
|
|
|
43344
43346
|
wh,
|
|
43345
43347
|
{
|
|
43346
43348
|
name: "cameraHelper",
|
|
43347
|
-
icon:
|
|
43349
|
+
icon: WN,
|
|
43348
43350
|
selected: this.cameraVisibility,
|
|
43349
43351
|
height: 24,
|
|
43350
43352
|
top: 2,
|
|
@@ -43418,7 +43420,7 @@ class ht extends Va {
|
|
|
43418
43420
|
this.tlCam = this.cameras.get(s.getItem(`${i}_tlCam`)), this.trCam = this.cameras.get(s.getItem(`${i}_trCam`)), this.blCam = this.cameras.get(s.getItem(`${i}_blCam`)), this.brCam = this.cameras.get(s.getItem(`${i}_brCam`)), this.tlCam === void 0 && (this.tlCam = this.cameras.get("Debug")), this.trCam === void 0 && (this.trCam = this.cameras.get("Orthographic")), this.blCam === void 0 && (this.blCam = this.cameras.get("Front")), this.brCam === void 0 && (this.brCam = this.cameras.get("Top"));
|
|
43419
43421
|
}
|
|
43420
43422
|
setupTools() {
|
|
43421
|
-
this.splineEditor = new
|
|
43423
|
+
this.splineEditor = new $N(this.currentCamera, this.app), this.splineEditor.initDebug(), this.helpersContainer.add(this.splineEditor);
|
|
43422
43424
|
}
|
|
43423
43425
|
// Public
|
|
43424
43426
|
play() {
|
|
@@ -44143,7 +44145,7 @@ class KN extends Va {
|
|
|
44143
44145
|
localClippingEnabled = !1;
|
|
44144
44146
|
clearColor = new vn(0);
|
|
44145
44147
|
clearAlpha = 1;
|
|
44146
|
-
toneMapping =
|
|
44148
|
+
toneMapping = $d;
|
|
44147
44149
|
toneMappingExposure = 1;
|
|
44148
44150
|
type = "";
|
|
44149
44151
|
constructor(e) {
|
|
@@ -44291,7 +44293,7 @@ class KN extends Va {
|
|
|
44291
44293
|
options: [
|
|
44292
44294
|
{
|
|
44293
44295
|
title: "None ",
|
|
44294
|
-
value:
|
|
44296
|
+
value: $d
|
|
44295
44297
|
},
|
|
44296
44298
|
{
|
|
44297
44299
|
title: "Linear ",
|
|
@@ -44303,11 +44305,11 @@ class KN extends Va {
|
|
|
44303
44305
|
},
|
|
44304
44306
|
{
|
|
44305
44307
|
title: "Cineon ",
|
|
44306
|
-
value:
|
|
44308
|
+
value: $x
|
|
44307
44309
|
},
|
|
44308
44310
|
{
|
|
44309
44311
|
title: "ACES Filmic",
|
|
44310
|
-
value:
|
|
44312
|
+
value: Wx
|
|
44311
44313
|
},
|
|
44312
44314
|
{
|
|
44313
44315
|
title: "AgX",
|
|
@@ -44537,7 +44539,7 @@ export {
|
|
|
44537
44539
|
MP as SceneInspector,
|
|
44538
44540
|
QN as SidePanel,
|
|
44539
44541
|
Ah as Spline,
|
|
44540
|
-
|
|
44542
|
+
$N as SplineEditor,
|
|
44541
44543
|
AP as ThreeEditor,
|
|
44542
44544
|
Y as ToolEvents,
|
|
44543
44545
|
xt as Transform,
|
|
@@ -44545,7 +44547,7 @@ export {
|
|
|
44545
44547
|
al as capitalize,
|
|
44546
44548
|
rn as clamp,
|
|
44547
44549
|
dP as clearComposerGroups,
|
|
44548
|
-
|
|
44550
|
+
Wd as colorToHex,
|
|
44549
44551
|
Jx as copyToClipboard,
|
|
44550
44552
|
cP as cubicBezier,
|
|
44551
44553
|
SP as customizeTheatreElements,
|