@roomle/web-sdk 3.5.0-alpha.1 → 3.5.0-alpha.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (67) hide show
  1. package/lib/{BufferGeometry-D0oTDT7-.mjs → BufferGeometry-BxcX1nu5.mjs} +170 -178
  2. package/lib/BufferGeometry-BxcX1nu5.mjs.map +1 -0
  3. package/lib/ConfiguratorKernel.wasm +0 -0
  4. package/lib/{GLTFExporter-D4ZDRRKY.mjs → GLTFExporter-BSDjg1BT.mjs} +10 -10
  5. package/lib/GLTFExporter-BSDjg1BT.mjs.map +1 -0
  6. package/lib/{PointLightHelper-ByJXr8_S.mjs → PointLightHelper-BGqd0srT.mjs} +19 -19
  7. package/lib/PointLightHelper-BGqd0srT.mjs.map +1 -0
  8. package/lib/RoomleCore.wasm +0 -0
  9. package/lib/RoomleToolsCore.wasm +0 -0
  10. package/lib/{SpotLightHelper-BO8HVIGi.mjs → SpotLightHelper-47gHbfRQ.mjs} +24 -24
  11. package/lib/SpotLightHelper-47gHbfRQ.mjs.map +1 -0
  12. package/lib/USDZExporter-xB9Bc_vW.mjs +545 -0
  13. package/lib/USDZExporter-xB9Bc_vW.mjs.map +1 -0
  14. package/lib/{banana-for-scale-Dqbv6lzU.mjs → banana-for-scale-CE_VgshX.mjs} +2 -2
  15. package/lib/{banana-for-scale-Dqbv6lzU.mjs.map → banana-for-scale-CE_VgshX.mjs.map} +1 -1
  16. package/lib/{component-dimensioning-DArrRqRX.mjs → component-dimensioning-Dr-a4146.mjs} +2 -2
  17. package/lib/{component-dimensioning-DArrRqRX.mjs.map → component-dimensioning-Dr-a4146.mjs.map} +1 -1
  18. package/lib/{continuous-drawing-helper-Y55SCE7o.mjs → continuous-drawing-helper-_3JpRL0X.mjs} +2 -2
  19. package/lib/{continuous-drawing-helper-Y55SCE7o.mjs.map → continuous-drawing-helper-_3JpRL0X.mjs.map} +1 -1
  20. package/lib/homag-intelligence-C0Jgym-0.mjs +547 -0
  21. package/lib/homag-intelligence-C0Jgym-0.mjs.map +1 -0
  22. package/lib/{imos-ix-poc-export-helper-BVRtbeMx.mjs → imos-ix-poc-export-helper-Be_OLiO2.mjs} +2 -2
  23. package/lib/{imos-ix-poc-export-helper-BVRtbeMx.mjs.map → imos-ix-poc-export-helper-Be_OLiO2.mjs.map} +1 -1
  24. package/lib/{index-BChueysR.mjs → index-CbfKx2cg.mjs} +14926 -12761
  25. package/lib/index-CbfKx2cg.mjs.map +1 -0
  26. package/lib/{material-viewer-wqVgzOjV.mjs → material-viewer-BzigD_S4.mjs} +2 -2
  27. package/lib/{material-viewer-wqVgzOjV.mjs.map → material-viewer-BzigD_S4.mjs.map} +1 -1
  28. package/lib/roomle-sdk.d.ts +61 -21
  29. package/lib/roomle-sdk.js +20 -20
  30. package/lib/static/roomle-core-hsc/ConfiguratorKernel.wasm +0 -0
  31. package/lib/static/roomle-core-hsc/RoomleCore.wasm +0 -0
  32. package/lib/static/roomle-core-hsc/RoomleServiceCore.wasm +0 -0
  33. package/lib/static/roomle-core-hsc/RoomleToolsCore.wasm +0 -0
  34. package/lib/static/roomle-core-hsc/configuratorCoreInterface.d.ts +5 -1
  35. package/lib/static/roomle-core-hsc/embind/configuratorCoreInterface.d.ts +5 -1
  36. package/lib/static/roomle-core-hsc/embind/plannerCoreInterface.d.ts +12 -7
  37. package/lib/static/roomle-core-hsc/embind/plannerCoreInterface.js +6 -2
  38. package/lib/static/roomle-core-hsc/embind/plannerCoreInterface.js.map +1 -1
  39. package/lib/static/roomle-core-hsc/package.json +1 -1
  40. package/lib/static/roomle-core-hsc/plannerCoreInterface.d.ts +12 -7
  41. package/lib/static/roomle-core-hsc/plannerCoreInterface.js +6 -2
  42. package/lib/static/roomle-core-hsc/plannerCoreInterface.js.map +1 -1
  43. package/lib/static/roomle-core-hsc/src/embind/configuratorCoreInterface.d.ts +5 -1
  44. package/lib/static/roomle-core-hsc/src/embind/plannerCoreInterface.d.ts +12 -7
  45. package/lib/static/roomle-core-hsc/src/embind/plannerCoreInterface.js +6 -2
  46. package/lib/static/roomle-core-hsc/src/embind/plannerCoreInterface.js.map +1 -1
  47. package/lib/static/roomle-core-hsc/wasm_modern/ConfiguratorKernel.wasm +0 -0
  48. package/lib/static/roomle-core-hsc/wasm_modern/RoomleCore.wasm +0 -0
  49. package/lib/static/roomle-core-hsc/wasm_modern/RoomleServiceCore.wasm +0 -0
  50. package/lib/static/roomle-core-hsc/wasm_modern/RoomleToolsCore.wasm +0 -0
  51. package/lib/{stats-helper-DviRZn-8.mjs → stats-helper-CFEfAd7f.mjs} +2 -2
  52. package/lib/{stats-helper-DviRZn-8.mjs.map → stats-helper-CFEfAd7f.mjs.map} +1 -1
  53. package/lib/{three.webgpu-6wDTD4-D.mjs → three.webgpu-1Evy-xH4.mjs} +7222 -4817
  54. package/lib/three.webgpu-1Evy-xH4.mjs.map +1 -0
  55. package/lib/{tools-core-C46gKA9O.mjs → tools-core-DpmhtPqx.mjs} +2 -2
  56. package/lib/{tools-core-C46gKA9O.mjs.map → tools-core-DpmhtPqx.mjs.map} +1 -1
  57. package/package.json +3 -3
  58. package/lib/BufferGeometry-D0oTDT7-.mjs.map +0 -1
  59. package/lib/GLTFExporter-D4ZDRRKY.mjs.map +0 -1
  60. package/lib/PointLightHelper-ByJXr8_S.mjs.map +0 -1
  61. package/lib/SpotLightHelper-BO8HVIGi.mjs.map +0 -1
  62. package/lib/USDZExporter-BwVvXYc-.mjs +0 -545
  63. package/lib/USDZExporter-BwVvXYc-.mjs.map +0 -1
  64. package/lib/homag-intelligence-B45l7Siw.mjs +0 -1626
  65. package/lib/homag-intelligence-B45l7Siw.mjs.map +0 -1
  66. package/lib/index-BChueysR.mjs.map +0 -1
  67. package/lib/three.webgpu-6wDTD4-D.mjs.map +0 -1
@@ -1,6 +1,6 @@
1
- import { X as d, a4 as dt, a5 as E, a6 as ot, a7 as tt, a8 as pt, a9 as Rt, aa as X, ab as it, ac as Dt, ad as Ct, ae as Tt, af as ft, a3 as gt, ag as mt, ah as xt, ai as bt, aj as yt, ak as Ft, al as O, am as St, an as vt, a1 as j, ao as J, ap as S, Z as zt, W as Nt, aq as ht, Y as Ot } from "./index-BChueysR.mjs";
2
- const D = /* @__PURE__ */ new d(), et = /* @__PURE__ */ new d(), G = /* @__PURE__ */ new d(), v = /* @__PURE__ */ new d(), st = /* @__PURE__ */ new d(), V = /* @__PURE__ */ new d(), nt = /* @__PURE__ */ new d();
3
- class _t {
1
+ import { V as d, a1 as ft, a2 as v, a3 as lt, a4 as et, a5 as gt, a6 as mt, a7 as Rt, N, a8 as L, a9 as st, aa as zt, ab as Tt, ac as kt, ad as xt, a0 as bt, ae as yt, af as Ft, ag as St, ah as At, ai as Mt, aj as I, ak as Bt, al as Et, _ as Q, am as W, an as S, ao as Nt, W as Ot, O as It, ap as ut, aq as _, Q as Pt } from "./index-CbfKx2cg.mjs";
2
+ const R = /* @__PURE__ */ new d(), nt = /* @__PURE__ */ new d(), H = /* @__PURE__ */ new d(), z = /* @__PURE__ */ new d(), rt = /* @__PURE__ */ new d(), U = /* @__PURE__ */ new d(), at = /* @__PURE__ */ new d();
3
+ class Vt {
4
4
  /**
5
5
  * Constructs a new ray.
6
6
  *
@@ -55,7 +55,7 @@ class _t {
55
55
  * @return {Ray} A reference to this ray.
56
56
  */
57
57
  recast(t) {
58
- return this.origin.copy(this.at(t, D)), this;
58
+ return this.origin.copy(this.at(t, R)), this;
59
59
  }
60
60
  /**
61
61
  * Returns the point along this ray that is closest to the given point.
@@ -85,8 +85,8 @@ class _t {
85
85
  * @return {number} The squared distance.
86
86
  */
87
87
  distanceSqToPoint(t) {
88
- const e = D.subVectors(t, this.origin).dot(this.direction);
89
- return e < 0 ? this.origin.distanceToSquared(t) : (D.copy(this.origin).addScaledVector(this.direction, e), D.distanceToSquared(t));
88
+ const e = R.subVectors(t, this.origin).dot(this.direction);
89
+ return e < 0 ? this.origin.distanceToSquared(t) : (R.copy(this.origin).addScaledVector(this.direction, e), R.distanceToSquared(t));
90
90
  }
91
91
  /**
92
92
  * Returns the squared distance between this ray and the given line segment.
@@ -98,24 +98,24 @@ class _t {
98
98
  * @return {number} The squared distance.
99
99
  */
100
100
  distanceSqToSegment(t, e, i, s) {
101
- et.copy(t).add(e).multiplyScalar(0.5), G.copy(e).sub(t).normalize(), v.copy(this.origin).sub(et);
102
- const n = t.distanceTo(e) * 0.5, r = -this.direction.dot(G), o = v.dot(this.direction), h = -v.dot(G), l = v.lengthSq(), c = Math.abs(1 - r * r);
103
- let u, a, f, x;
101
+ nt.copy(t).add(e).multiplyScalar(0.5), H.copy(e).sub(t).normalize(), z.copy(this.origin).sub(nt);
102
+ const n = t.distanceTo(e) * 0.5, r = -this.direction.dot(H), o = z.dot(this.direction), h = -z.dot(H), l = z.lengthSq(), c = Math.abs(1 - r * r);
103
+ let u, a, p, x;
104
104
  if (c > 0)
105
105
  if (u = r * h - o, a = r * o - h, x = n * c, u >= 0)
106
106
  if (a >= -x)
107
107
  if (a <= x) {
108
108
  const y = 1 / c;
109
- u *= y, a *= y, f = u * (u + r * a + 2 * o) + a * (r * u + a + 2 * h) + l;
109
+ u *= y, a *= y, p = u * (u + r * a + 2 * o) + a * (r * u + a + 2 * h) + l;
110
110
  } else
111
- a = n, u = Math.max(0, -(r * a + o)), f = -u * u + a * (a + 2 * h) + l;
111
+ a = n, u = Math.max(0, -(r * a + o)), p = -u * u + a * (a + 2 * h) + l;
112
112
  else
113
- a = -n, u = Math.max(0, -(r * a + o)), f = -u * u + a * (a + 2 * h) + l;
113
+ a = -n, u = Math.max(0, -(r * a + o)), p = -u * u + a * (a + 2 * h) + l;
114
114
  else
115
- a <= -x ? (u = Math.max(0, -(-r * n + o)), a = u > 0 ? -n : Math.min(Math.max(-n, -h), n), f = -u * u + a * (a + 2 * h) + l) : a <= x ? (u = 0, a = Math.min(Math.max(-n, -h), n), f = a * (a + 2 * h) + l) : (u = Math.max(0, -(r * n + o)), a = u > 0 ? n : Math.min(Math.max(-n, -h), n), f = -u * u + a * (a + 2 * h) + l);
115
+ a <= -x ? (u = Math.max(0, -(-r * n + o)), a = u > 0 ? -n : Math.min(Math.max(-n, -h), n), p = -u * u + a * (a + 2 * h) + l) : a <= x ? (u = 0, a = Math.min(Math.max(-n, -h), n), p = a * (a + 2 * h) + l) : (u = Math.max(0, -(r * n + o)), a = u > 0 ? n : Math.min(Math.max(-n, -h), n), p = -u * u + a * (a + 2 * h) + l);
116
116
  else
117
- a = r > 0 ? -n : n, u = Math.max(0, -(r * a + o)), f = -u * u + a * (a + 2 * h) + l;
118
- return i && i.copy(this.origin).addScaledVector(this.direction, u), s && s.copy(et).addScaledVector(G, a), f;
117
+ a = r > 0 ? -n : n, u = Math.max(0, -(r * a + o)), p = -u * u + a * (a + 2 * h) + l;
118
+ return i && i.copy(this.origin).addScaledVector(this.direction, u), s && s.copy(nt).addScaledVector(H, a), p;
119
119
  }
120
120
  /**
121
121
  * Intersects this ray with the given sphere, returning the intersection
@@ -126,8 +126,8 @@ class _t {
126
126
  * @return {?Vector3} The intersection point.
127
127
  */
128
128
  intersectSphere(t, e) {
129
- D.subVectors(t.center, this.origin);
130
- const i = D.dot(this.direction), s = D.dot(D) - i * i, n = t.radius * t.radius;
129
+ R.subVectors(t.center, this.origin);
130
+ const i = R.dot(this.direction), s = R.dot(R) - i * i, n = t.radius * t.radius;
131
131
  if (s > n) return null;
132
132
  const r = Math.sqrt(n - s), o = i - r, h = i + r;
133
133
  return h < 0 ? null : o < 0 ? this.at(h, e) : this.at(o, e);
@@ -197,7 +197,7 @@ class _t {
197
197
  * @return {boolean} Whether this ray intersects with the given box or not.
198
198
  */
199
199
  intersectsBox(t) {
200
- return this.intersectBox(t, D) !== null;
200
+ return this.intersectBox(t, R) !== null;
201
201
  }
202
202
  /**
203
203
  * Intersects this ray with the given triangle, returning the intersection
@@ -211,8 +211,8 @@ class _t {
211
211
  * @return {?Vector3} The intersection point.
212
212
  */
213
213
  intersectTriangle(t, e, i, s, n) {
214
- st.subVectors(e, t), V.subVectors(i, t), nt.crossVectors(st, V);
215
- let r = this.direction.dot(nt), o;
214
+ rt.subVectors(e, t), U.subVectors(i, t), at.crossVectors(rt, U);
215
+ let r = this.direction.dot(at), o;
216
216
  if (r > 0) {
217
217
  if (s) return null;
218
218
  o = 1;
@@ -220,14 +220,14 @@ class _t {
220
220
  o = -1, r = -r;
221
221
  else
222
222
  return null;
223
- v.subVectors(this.origin, t);
224
- const h = o * this.direction.dot(V.crossVectors(v, V));
223
+ z.subVectors(this.origin, t);
224
+ const h = o * this.direction.dot(U.crossVectors(z, U));
225
225
  if (h < 0)
226
226
  return null;
227
- const l = o * this.direction.dot(st.cross(v));
227
+ const l = o * this.direction.dot(rt.cross(z));
228
228
  if (l < 0 || h + l > r)
229
229
  return null;
230
- const c = -o * v.dot(nt);
230
+ const c = -o * z.dot(at);
231
231
  return c < 0 ? null : this.at(c / r, n);
232
232
  }
233
233
  /**
@@ -257,16 +257,7 @@ class _t {
257
257
  return new this.constructor().copy(this);
258
258
  }
259
259
  }
260
- function It(p) {
261
- for (let t = p.length - 1; t >= 0; --t)
262
- if (p[t] >= 65535) return !0;
263
- return !1;
264
- }
265
- const At = {};
266
- function Mt(p) {
267
- p in At || (At[p] = !0, console.warn(p));
268
- }
269
- const Bt = /* @__PURE__ */ new ot().set(
260
+ const wt = /* @__PURE__ */ new lt().set(
270
261
  0.4123908,
271
262
  0.3575843,
272
263
  0.1804808,
@@ -276,7 +267,7 @@ const Bt = /* @__PURE__ */ new ot().set(
276
267
  0.0193308,
277
268
  0.1191948,
278
269
  0.9505322
279
- ), wt = /* @__PURE__ */ new ot().set(
270
+ ), Ct = /* @__PURE__ */ new lt().set(
280
271
  3.2409699,
281
272
  -1.5373832,
282
273
  -0.4986108,
@@ -287,10 +278,10 @@ const Bt = /* @__PURE__ */ new ot().set(
287
278
  -0.203977,
288
279
  1.0569715
289
280
  );
290
- function Ht() {
291
- const p = {
281
+ function qt() {
282
+ const f = {
292
283
  enabled: !0,
293
- workingColorSpace: dt,
284
+ workingColorSpace: ft,
294
285
  /**
295
286
  * Implementations of supported color spaces.
296
287
  *
@@ -311,7 +302,7 @@ function Ht() {
311
302
  */
312
303
  spaces: {},
313
304
  convert: function(s, n, r) {
314
- return this.enabled === !1 || n === r || !n || !r || (this.spaces[n].transfer === tt && (s.r = H(s.r), s.g = H(s.g), s.b = H(s.b)), this.spaces[n].primaries !== this.spaces[r].primaries && (s.applyMatrix3(this.spaces[n].toXYZ), s.applyMatrix3(this.spaces[r].fromXYZ)), this.spaces[r].transfer === tt && (s.r = P(s.r), s.g = P(s.g), s.b = P(s.b))), s;
305
+ return this.enabled === !1 || n === r || !n || !r || (this.spaces[n].transfer === et && (s.r = q(s.r), s.g = q(s.g), s.b = q(s.b)), this.spaces[n].primaries !== this.spaces[r].primaries && (s.applyMatrix3(this.spaces[n].toXYZ), s.applyMatrix3(this.spaces[r].fromXYZ)), this.spaces[r].transfer === et && (s.r = Z(s.r), s.g = Z(s.g), s.b = Z(s.b))), s;
315
306
  },
316
307
  workingToColorSpace: function(s, n) {
317
308
  return this.convert(s, this.workingColorSpace, n);
@@ -323,7 +314,7 @@ function Ht() {
323
314
  return this.spaces[s].primaries;
324
315
  },
325
316
  getTransfer: function(s) {
326
- return s === Rt ? pt : this.spaces[s].transfer;
317
+ return s === Rt ? gt : this.spaces[s].transfer;
327
318
  },
328
319
  getToneMappingMode: function(s) {
329
320
  return this.spaces[s].outputColorSpaceConfig.toneMappingMode || "standard";
@@ -346,42 +337,42 @@ function Ht() {
346
337
  },
347
338
  // Deprecated
348
339
  fromWorkingColorSpace: function(s, n) {
349
- return Mt("THREE.ColorManagement: .fromWorkingColorSpace() has been renamed to .workingToColorSpace()."), p.workingToColorSpace(s, n);
340
+ return mt("ColorManagement: .fromWorkingColorSpace() has been renamed to .workingToColorSpace()."), f.workingToColorSpace(s, n);
350
341
  },
351
342
  toWorkingColorSpace: function(s, n) {
352
- return Mt("THREE.ColorManagement: .toWorkingColorSpace() has been renamed to .colorSpaceToWorking()."), p.colorSpaceToWorking(s, n);
343
+ return mt("ColorManagement: .toWorkingColorSpace() has been renamed to .colorSpaceToWorking()."), f.colorSpaceToWorking(s, n);
353
344
  }
354
345
  }, t = [0.64, 0.33, 0.3, 0.6, 0.15, 0.06], e = [0.2126, 0.7152, 0.0722], i = [0.3127, 0.329];
355
- return p.define({
356
- [dt]: {
346
+ return f.define({
347
+ [ft]: {
357
348
  primaries: t,
358
349
  whitePoint: i,
359
- transfer: pt,
360
- toXYZ: Bt,
361
- fromXYZ: wt,
350
+ transfer: gt,
351
+ toXYZ: wt,
352
+ fromXYZ: Ct,
362
353
  luminanceCoefficients: e,
363
- workingColorSpaceConfig: { unpackColorSpace: E },
364
- outputColorSpaceConfig: { drawingBufferColorSpace: E }
354
+ workingColorSpaceConfig: { unpackColorSpace: v },
355
+ outputColorSpaceConfig: { drawingBufferColorSpace: v }
365
356
  },
366
- [E]: {
357
+ [v]: {
367
358
  primaries: t,
368
359
  whitePoint: i,
369
- transfer: tt,
370
- toXYZ: Bt,
371
- fromXYZ: wt,
360
+ transfer: et,
361
+ toXYZ: wt,
362
+ fromXYZ: Ct,
372
363
  luminanceCoefficients: e,
373
- outputColorSpaceConfig: { drawingBufferColorSpace: E }
364
+ outputColorSpaceConfig: { drawingBufferColorSpace: v }
374
365
  }
375
- }), p;
366
+ }), f;
376
367
  }
377
- const k = /* @__PURE__ */ Ht();
378
- function H(p) {
379
- return p < 0.04045 ? p * 0.0773993808 : Math.pow(p * 0.9478672986 + 0.0521327014, 2.4);
368
+ const k = /* @__PURE__ */ qt();
369
+ function q(f) {
370
+ return f < 0.04045 ? f * 0.0773993808 : Math.pow(f * 0.9478672986 + 0.0521327014, 2.4);
380
371
  }
381
- function P(p) {
382
- return p < 31308e-7 ? p * 12.92 : 1.055 * Math.pow(p, 0.41666) - 0.055;
372
+ function Z(f) {
373
+ return f < 31308e-7 ? f * 12.92 : 1.055 * Math.pow(f, 0.41666) - 0.055;
383
374
  }
384
- const kt = {
375
+ const vt = {
385
376
  aliceblue: 15792383,
386
377
  antiquewhite: 16444375,
387
378
  aqua: 65535,
@@ -530,11 +521,11 @@ const kt = {
530
521
  whitesmoke: 16119285,
531
522
  yellow: 16776960,
532
523
  yellowgreen: 10145074
533
- }, z = { h: 0, s: 0, l: 0 }, Y = { h: 0, s: 0, l: 0 };
534
- function rt(p, t, e) {
535
- return e < 0 && (e += 1), e > 1 && (e -= 1), e < 1 / 6 ? p + (t - p) * 6 * e : e < 1 / 2 ? t : e < 2 / 3 ? p + (t - p) * 6 * (2 / 3 - e) : p;
524
+ }, E = { h: 0, s: 0, l: 0 }, j = { h: 0, s: 0, l: 0 };
525
+ function ot(f, t, e) {
526
+ return e < 0 && (e += 1), e > 1 && (e -= 1), e < 1 / 6 ? f + (t - f) * 6 * e : e < 1 / 2 ? t : e < 2 / 3 ? f + (t - f) * 6 * (2 / 3 - e) : f;
536
527
  }
537
- class lt {
528
+ class ct {
538
529
  /**
539
530
  * Constructs a new color.
540
531
  *
@@ -582,7 +573,7 @@ class lt {
582
573
  * @param {string} [colorSpace=SRGBColorSpace] - The color space.
583
574
  * @return {Color} A reference to this color.
584
575
  */
585
- setHex(t, e = E) {
576
+ setHex(t, e = v) {
586
577
  return t = Math.floor(t), this.r = (t >> 16 & 255) / 255, this.g = (t >> 8 & 255) / 255, this.b = (t & 255) / 255, k.colorSpaceToWorking(this, e), this;
587
578
  }
588
579
  /**
@@ -607,27 +598,27 @@ class lt {
607
598
  * @return {Color} A reference to this color.
608
599
  */
609
600
  setHSL(t, e, i, s = k.workingColorSpace) {
610
- if (t = Dt(t, 1), e = X(e, 0, 1), i = X(i, 0, 1), e === 0)
601
+ if (t = zt(t, 1), e = L(e, 0, 1), i = L(i, 0, 1), e === 0)
611
602
  this.r = this.g = this.b = i;
612
603
  else {
613
604
  const n = i <= 0.5 ? i * (1 + e) : i + e - i * e, r = 2 * i - n;
614
- this.r = rt(r, n, t + 1 / 3), this.g = rt(r, n, t), this.b = rt(r, n, t - 1 / 3);
605
+ this.r = ot(r, n, t + 1 / 3), this.g = ot(r, n, t), this.b = ot(r, n, t - 1 / 3);
615
606
  }
616
607
  return k.colorSpaceToWorking(this, s), this;
617
608
  }
618
609
  /**
619
610
  * Sets this color from a CSS-style string. For example, `rgb(250, 0,0)`,
620
611
  * `rgb(100%, 0%, 0%)`, `hsl(0, 100%, 50%)`, `#ff0000`, `#f00`, or `red` ( or
621
- * any [X11 color name]{@link https://en.wikipedia.org/wiki/X11_color_names#Color_name_chart} -
612
+ * any [X11 color name](https://en.wikipedia.org/wiki/X11_color_names#Color_name_chart) -
622
613
  * all 140 color names are supported).
623
614
  *
624
615
  * @param {string} style - Color as a CSS-style string.
625
616
  * @param {string} [colorSpace=SRGBColorSpace] - The color space.
626
617
  * @return {Color} A reference to this color.
627
618
  */
628
- setStyle(t, e = E) {
619
+ setStyle(t, e = v) {
629
620
  function i(n) {
630
- n !== void 0 && parseFloat(n) < 1 && console.warn("THREE.Color: Alpha component of " + t + " will be ignored.");
621
+ n !== void 0 && parseFloat(n) < 1 && N("Color: Alpha component of " + t + " will be ignored.");
631
622
  }
632
623
  let s;
633
624
  if (s = /^(\w+)\(([^\)]*)\)/.exec(t)) {
@@ -662,7 +653,7 @@ class lt {
662
653
  );
663
654
  break;
664
655
  default:
665
- console.warn("THREE.Color: Unknown color model " + t);
656
+ N("Color: Unknown color model " + t);
666
657
  }
667
658
  } else if (s = /^\#([A-Fa-f\d]+)$/.exec(t)) {
668
659
  const n = s[1], r = n.length;
@@ -675,7 +666,7 @@ class lt {
675
666
  );
676
667
  if (r === 6)
677
668
  return this.setHex(parseInt(n, 16), e);
678
- console.warn("THREE.Color: Invalid hex color " + t);
669
+ N("Color: Invalid hex color " + t);
679
670
  } else if (t && t.length > 0)
680
671
  return this.setColorName(t, e);
681
672
  return this;
@@ -693,9 +684,9 @@ class lt {
693
684
  * @param {string} [colorSpace=SRGBColorSpace] - The color space.
694
685
  * @return {Color} A reference to this color.
695
686
  */
696
- setColorName(t, e = E) {
697
- const i = kt[t.toLowerCase()];
698
- return i !== void 0 ? this.setHex(i, e) : console.warn("THREE.Color: Unknown color " + t), this;
687
+ setColorName(t, e = v) {
688
+ const i = vt[t.toLowerCase()];
689
+ return i !== void 0 ? this.setHex(i, e) : N("Color: Unknown color " + t), this;
699
690
  }
700
691
  /**
701
692
  * Returns a new color with copied values from this instance.
@@ -722,7 +713,7 @@ class lt {
722
713
  * @return {Color} A reference to this color.
723
714
  */
724
715
  copySRGBToLinear(t) {
725
- return this.r = H(t.r), this.g = H(t.g), this.b = H(t.b), this;
716
+ return this.r = q(t.r), this.g = q(t.g), this.b = q(t.b), this;
726
717
  }
727
718
  /**
728
719
  * Copies the given color into this color, and then converts this color from
@@ -732,7 +723,7 @@ class lt {
732
723
  * @return {Color} A reference to this color.
733
724
  */
734
725
  copyLinearToSRGB(t) {
735
- return this.r = P(t.r), this.g = P(t.g), this.b = P(t.b), this;
726
+ return this.r = Z(t.r), this.g = Z(t.g), this.b = Z(t.b), this;
736
727
  }
737
728
  /**
738
729
  * Converts this color from `SRGBColorSpace` to `LinearSRGBColorSpace`.
@@ -756,8 +747,8 @@ class lt {
756
747
  * @param {string} [colorSpace=SRGBColorSpace] - The color space.
757
748
  * @return {number} The hexadecimal value.
758
749
  */
759
- getHex(t = E) {
760
- return k.workingToColorSpace(F.copy(this), t), Math.round(X(F.r * 255, 0, 255)) * 65536 + Math.round(X(F.g * 255, 0, 255)) * 256 + Math.round(X(F.b * 255, 0, 255));
750
+ getHex(t = v) {
751
+ return k.workingToColorSpace(F.copy(this), t), Math.round(L(F.r * 255, 0, 255)) * 65536 + Math.round(L(F.g * 255, 0, 255)) * 256 + Math.round(L(F.b * 255, 0, 255));
761
752
  }
762
753
  /**
763
754
  * Returns the hexadecimal value of this color as a string (for example, 'FFFFFF').
@@ -765,7 +756,7 @@ class lt {
765
756
  * @param {string} [colorSpace=SRGBColorSpace] - The color space.
766
757
  * @return {string} The hexadecimal value as a string.
767
758
  */
768
- getHexString(t = E) {
759
+ getHexString(t = v) {
769
760
  return ("000000" + this.getHex(t).toString(16)).slice(-6);
770
761
  }
771
762
  /**
@@ -816,10 +807,10 @@ class lt {
816
807
  * @param {string} [colorSpace=SRGBColorSpace] - The color space.
817
808
  * @return {string} The CSS representation of this color.
818
809
  */
819
- getStyle(t = E) {
810
+ getStyle(t = v) {
820
811
  k.workingToColorSpace(F.copy(this), t);
821
812
  const e = F.r, i = F.g, s = F.b;
822
- return t !== E ? `color(${t} ${e.toFixed(3)} ${i.toFixed(3)} ${s.toFixed(3)})` : `rgb(${Math.round(e * 255)},${Math.round(i * 255)},${Math.round(s * 255)})`;
813
+ return t !== v ? `color(${t} ${e.toFixed(3)} ${i.toFixed(3)} ${s.toFixed(3)})` : `rgb(${Math.round(e * 255)},${Math.round(i * 255)},${Math.round(s * 255)})`;
823
814
  }
824
815
  /**
825
816
  * Adds the given HSL values to this color's values.
@@ -832,7 +823,7 @@ class lt {
832
823
  * @return {Color} A reference to this color.
833
824
  */
834
825
  offsetHSL(t, e, i) {
835
- return this.getHSL(z), this.setHSL(z.h + t, z.s + e, z.l + i);
826
+ return this.getHSL(E), this.setHSL(E.h + t, E.s + e, E.l + i);
836
827
  }
837
828
  /**
838
829
  * Adds the RGB values of the given color to the RGB values of this color.
@@ -926,8 +917,8 @@ class lt {
926
917
  * @return {Color} A reference to this color.
927
918
  */
928
919
  lerpHSL(t, e) {
929
- this.getHSL(z), t.getHSL(Y);
930
- const i = it(z.h, Y.h, e), s = it(z.s, Y.s, e), n = it(z.l, Y.l, e);
920
+ this.getHSL(E), t.getHSL(j);
921
+ const i = st(E.h, j.h, e), s = st(E.s, j.s, e), n = st(E.l, j.l, e);
931
922
  return this.setHSL(i, s, n), this;
932
923
  }
933
924
  /**
@@ -1002,15 +993,15 @@ class lt {
1002
993
  yield this.r, yield this.g, yield this.b;
1003
994
  }
1004
995
  }
1005
- const F = /* @__PURE__ */ new lt();
1006
- lt.NAMES = kt;
1007
- let Pt = 0;
1008
- class Gt extends Ct {
996
+ const F = /* @__PURE__ */ new ct();
997
+ ct.NAMES = vt;
998
+ let Zt = 0;
999
+ class Yt extends Tt {
1009
1000
  /**
1010
1001
  * Constructs a new material.
1011
1002
  */
1012
1003
  constructor() {
1013
- super(), this.isMaterial = !0, Object.defineProperty(this, "id", { value: Pt++ }), this.uuid = Tt(), this.name = "", this.type = "Material", this.blending = ft, this.side = gt, this.vertexColors = !1, this.opacity = 1, this.transparent = !1, this.alphaHash = !1, this.blendSrc = mt, this.blendDst = xt, this.blendEquation = bt, this.blendSrcAlpha = null, this.blendDstAlpha = null, this.blendEquationAlpha = null, this.blendColor = new lt(0, 0, 0), this.blendAlpha = 0, this.depthFunc = yt, this.depthTest = !0, this.depthWrite = !0, this.stencilWriteMask = 255, this.stencilFunc = Ft, this.stencilRef = 0, this.stencilFuncMask = 255, this.stencilFail = O, this.stencilZFail = O, this.stencilZPass = O, this.stencilWrite = !1, this.clippingPlanes = null, this.clipIntersection = !1, this.clipShadows = !1, this.shadowSide = null, this.colorWrite = !0, this.precision = null, this.polygonOffset = !1, this.polygonOffsetFactor = 0, this.polygonOffsetUnits = 0, this.dithering = !1, this.alphaToCoverage = !1, this.premultipliedAlpha = !1, this.forceSinglePass = !1, this.allowOverride = !0, this.visible = !0, this.toneMapped = !0, this.userData = {}, this.version = 0, this._alphaTest = 0;
1004
+ super(), this.isMaterial = !0, Object.defineProperty(this, "id", { value: Zt++ }), this.uuid = kt(), this.name = "", this.type = "Material", this.blending = xt, this.side = bt, this.vertexColors = !1, this.opacity = 1, this.transparent = !1, this.alphaHash = !1, this.blendSrc = yt, this.blendDst = Ft, this.blendEquation = St, this.blendSrcAlpha = null, this.blendDstAlpha = null, this.blendEquationAlpha = null, this.blendColor = new ct(0, 0, 0), this.blendAlpha = 0, this.depthFunc = At, this.depthTest = !0, this.depthWrite = !0, this.stencilWriteMask = 255, this.stencilFunc = Mt, this.stencilRef = 0, this.stencilFuncMask = 255, this.stencilFail = I, this.stencilZFail = I, this.stencilZPass = I, this.stencilWrite = !1, this.clippingPlanes = null, this.clipIntersection = !1, this.clipShadows = !1, this.shadowSide = null, this.colorWrite = !0, this.precision = null, this.polygonOffset = !1, this.polygonOffsetFactor = 0, this.polygonOffsetUnits = 0, this.dithering = !1, this.alphaToCoverage = !1, this.premultipliedAlpha = !1, this.forceSinglePass = !1, this.allowOverride = !0, this.visible = !0, this.toneMapped = !0, this.userData = {}, this.version = 0, this._alphaTest = 0;
1014
1005
  }
1015
1006
  /**
1016
1007
  * Sets the alpha value to be used when running an alpha test. The material
@@ -1047,7 +1038,7 @@ class Gt extends Ct {
1047
1038
  *
1048
1039
  * This method can only be used when rendering with {@link WebGLRenderer}. The
1049
1040
  * recommended approach when customizing materials is to use `WebGPURenderer` with the new
1050
- * Node Material system and [TSL]{@link https://github.com/mrdoob/three.js/wiki/Three.js-Shading-Language}.
1041
+ * Node Material system and [TSL](https://github.com/mrdoob/three.js/wiki/Three.js-Shading-Language).
1051
1042
  *
1052
1043
  * @param {{vertexShader:string,fragmentShader:string,uniforms:Object}} shaderobject - The object holds the uniforms and the vertex and fragment shader source.
1053
1044
  * @param {WebGLRenderer} renderer - A reference to the renderer.
@@ -1078,12 +1069,12 @@ class Gt extends Ct {
1078
1069
  for (const e in t) {
1079
1070
  const i = t[e];
1080
1071
  if (i === void 0) {
1081
- console.warn(`THREE.Material: parameter '${e}' has value of undefined.`);
1072
+ N(`Material: parameter '${e}' has value of undefined.`);
1082
1073
  continue;
1083
1074
  }
1084
1075
  const s = this[e];
1085
1076
  if (s === void 0) {
1086
- console.warn(`THREE.Material: '${e}' is not a property of THREE.${this.type}.`);
1077
+ N(`Material: '${e}' is not a property of THREE.${this.type}.`);
1087
1078
  continue;
1088
1079
  }
1089
1080
  s && s.isColor ? s.set(i) : s && s.isVector3 && i && i.isVector3 ? s.copy(i) : this[e] = i;
@@ -1109,7 +1100,7 @@ class Gt extends Ct {
1109
1100
  generator: "Material.toJSON"
1110
1101
  }
1111
1102
  };
1112
- i.uuid = this.uuid, i.type = this.type, this.name !== "" && (i.name = this.name), this.color && this.color.isColor && (i.color = this.color.getHex()), this.roughness !== void 0 && (i.roughness = this.roughness), this.metalness !== void 0 && (i.metalness = this.metalness), this.sheen !== void 0 && (i.sheen = this.sheen), this.sheenColor && this.sheenColor.isColor && (i.sheenColor = this.sheenColor.getHex()), this.sheenRoughness !== void 0 && (i.sheenRoughness = this.sheenRoughness), this.emissive && this.emissive.isColor && (i.emissive = this.emissive.getHex()), this.emissiveIntensity !== void 0 && this.emissiveIntensity !== 1 && (i.emissiveIntensity = this.emissiveIntensity), this.specular && this.specular.isColor && (i.specular = this.specular.getHex()), this.specularIntensity !== void 0 && (i.specularIntensity = this.specularIntensity), this.specularColor && this.specularColor.isColor && (i.specularColor = this.specularColor.getHex()), this.shininess !== void 0 && (i.shininess = this.shininess), this.clearcoat !== void 0 && (i.clearcoat = this.clearcoat), this.clearcoatRoughness !== void 0 && (i.clearcoatRoughness = this.clearcoatRoughness), this.clearcoatMap && this.clearcoatMap.isTexture && (i.clearcoatMap = this.clearcoatMap.toJSON(t).uuid), this.clearcoatRoughnessMap && this.clearcoatRoughnessMap.isTexture && (i.clearcoatRoughnessMap = this.clearcoatRoughnessMap.toJSON(t).uuid), this.clearcoatNormalMap && this.clearcoatNormalMap.isTexture && (i.clearcoatNormalMap = this.clearcoatNormalMap.toJSON(t).uuid, i.clearcoatNormalScale = this.clearcoatNormalScale.toArray()), this.sheenColorMap && this.sheenColorMap.isTexture && (i.sheenColorMap = this.sheenColorMap.toJSON(t).uuid), this.sheenRoughnessMap && this.sheenRoughnessMap.isTexture && (i.sheenRoughnessMap = this.sheenRoughnessMap.toJSON(t).uuid), this.dispersion !== void 0 && (i.dispersion = this.dispersion), this.iridescence !== void 0 && (i.iridescence = this.iridescence), this.iridescenceIOR !== void 0 && (i.iridescenceIOR = this.iridescenceIOR), this.iridescenceThicknessRange !== void 0 && (i.iridescenceThicknessRange = this.iridescenceThicknessRange), this.iridescenceMap && this.iridescenceMap.isTexture && (i.iridescenceMap = this.iridescenceMap.toJSON(t).uuid), this.iridescenceThicknessMap && this.iridescenceThicknessMap.isTexture && (i.iridescenceThicknessMap = this.iridescenceThicknessMap.toJSON(t).uuid), this.anisotropy !== void 0 && (i.anisotropy = this.anisotropy), this.anisotropyRotation !== void 0 && (i.anisotropyRotation = this.anisotropyRotation), this.anisotropyMap && this.anisotropyMap.isTexture && (i.anisotropyMap = this.anisotropyMap.toJSON(t).uuid), this.map && this.map.isTexture && (i.map = this.map.toJSON(t).uuid), this.matcap && this.matcap.isTexture && (i.matcap = this.matcap.toJSON(t).uuid), this.alphaMap && this.alphaMap.isTexture && (i.alphaMap = this.alphaMap.toJSON(t).uuid), this.lightMap && this.lightMap.isTexture && (i.lightMap = this.lightMap.toJSON(t).uuid, i.lightMapIntensity = this.lightMapIntensity), this.aoMap && this.aoMap.isTexture && (i.aoMap = this.aoMap.toJSON(t).uuid, i.aoMapIntensity = this.aoMapIntensity), this.bumpMap && this.bumpMap.isTexture && (i.bumpMap = this.bumpMap.toJSON(t).uuid, i.bumpScale = this.bumpScale), this.normalMap && this.normalMap.isTexture && (i.normalMap = this.normalMap.toJSON(t).uuid, i.normalMapType = this.normalMapType, i.normalScale = this.normalScale.toArray()), this.displacementMap && this.displacementMap.isTexture && (i.displacementMap = this.displacementMap.toJSON(t).uuid, i.displacementScale = this.displacementScale, i.displacementBias = this.displacementBias), this.roughnessMap && this.roughnessMap.isTexture && (i.roughnessMap = this.roughnessMap.toJSON(t).uuid), this.metalnessMap && this.metalnessMap.isTexture && (i.metalnessMap = this.metalnessMap.toJSON(t).uuid), this.emissiveMap && this.emissiveMap.isTexture && (i.emissiveMap = this.emissiveMap.toJSON(t).uuid), this.specularMap && this.specularMap.isTexture && (i.specularMap = this.specularMap.toJSON(t).uuid), this.specularIntensityMap && this.specularIntensityMap.isTexture && (i.specularIntensityMap = this.specularIntensityMap.toJSON(t).uuid), this.specularColorMap && this.specularColorMap.isTexture && (i.specularColorMap = this.specularColorMap.toJSON(t).uuid), this.envMap && this.envMap.isTexture && (i.envMap = this.envMap.toJSON(t).uuid, this.combine !== void 0 && (i.combine = this.combine)), this.envMapRotation !== void 0 && (i.envMapRotation = this.envMapRotation.toArray()), this.envMapIntensity !== void 0 && (i.envMapIntensity = this.envMapIntensity), this.reflectivity !== void 0 && (i.reflectivity = this.reflectivity), this.refractionRatio !== void 0 && (i.refractionRatio = this.refractionRatio), this.gradientMap && this.gradientMap.isTexture && (i.gradientMap = this.gradientMap.toJSON(t).uuid), this.transmission !== void 0 && (i.transmission = this.transmission), this.transmissionMap && this.transmissionMap.isTexture && (i.transmissionMap = this.transmissionMap.toJSON(t).uuid), this.thickness !== void 0 && (i.thickness = this.thickness), this.thicknessMap && this.thicknessMap.isTexture && (i.thicknessMap = this.thicknessMap.toJSON(t).uuid), this.attenuationDistance !== void 0 && this.attenuationDistance !== 1 / 0 && (i.attenuationDistance = this.attenuationDistance), this.attenuationColor !== void 0 && (i.attenuationColor = this.attenuationColor.getHex()), this.size !== void 0 && (i.size = this.size), this.shadowSide !== null && (i.shadowSide = this.shadowSide), this.sizeAttenuation !== void 0 && (i.sizeAttenuation = this.sizeAttenuation), this.blending !== ft && (i.blending = this.blending), this.side !== gt && (i.side = this.side), this.vertexColors === !0 && (i.vertexColors = !0), this.opacity < 1 && (i.opacity = this.opacity), this.transparent === !0 && (i.transparent = !0), this.blendSrc !== mt && (i.blendSrc = this.blendSrc), this.blendDst !== xt && (i.blendDst = this.blendDst), this.blendEquation !== bt && (i.blendEquation = this.blendEquation), this.blendSrcAlpha !== null && (i.blendSrcAlpha = this.blendSrcAlpha), this.blendDstAlpha !== null && (i.blendDstAlpha = this.blendDstAlpha), this.blendEquationAlpha !== null && (i.blendEquationAlpha = this.blendEquationAlpha), this.blendColor && this.blendColor.isColor && (i.blendColor = this.blendColor.getHex()), this.blendAlpha !== 0 && (i.blendAlpha = this.blendAlpha), this.depthFunc !== yt && (i.depthFunc = this.depthFunc), this.depthTest === !1 && (i.depthTest = this.depthTest), this.depthWrite === !1 && (i.depthWrite = this.depthWrite), this.colorWrite === !1 && (i.colorWrite = this.colorWrite), this.stencilWriteMask !== 255 && (i.stencilWriteMask = this.stencilWriteMask), this.stencilFunc !== Ft && (i.stencilFunc = this.stencilFunc), this.stencilRef !== 0 && (i.stencilRef = this.stencilRef), this.stencilFuncMask !== 255 && (i.stencilFuncMask = this.stencilFuncMask), this.stencilFail !== O && (i.stencilFail = this.stencilFail), this.stencilZFail !== O && (i.stencilZFail = this.stencilZFail), this.stencilZPass !== O && (i.stencilZPass = this.stencilZPass), this.stencilWrite === !0 && (i.stencilWrite = this.stencilWrite), this.rotation !== void 0 && this.rotation !== 0 && (i.rotation = this.rotation), this.polygonOffset === !0 && (i.polygonOffset = !0), this.polygonOffsetFactor !== 0 && (i.polygonOffsetFactor = this.polygonOffsetFactor), this.polygonOffsetUnits !== 0 && (i.polygonOffsetUnits = this.polygonOffsetUnits), this.linewidth !== void 0 && this.linewidth !== 1 && (i.linewidth = this.linewidth), this.dashSize !== void 0 && (i.dashSize = this.dashSize), this.gapSize !== void 0 && (i.gapSize = this.gapSize), this.scale !== void 0 && (i.scale = this.scale), this.dithering === !0 && (i.dithering = !0), this.alphaTest > 0 && (i.alphaTest = this.alphaTest), this.alphaHash === !0 && (i.alphaHash = !0), this.alphaToCoverage === !0 && (i.alphaToCoverage = !0), this.premultipliedAlpha === !0 && (i.premultipliedAlpha = !0), this.forceSinglePass === !0 && (i.forceSinglePass = !0), this.wireframe === !0 && (i.wireframe = !0), this.wireframeLinewidth > 1 && (i.wireframeLinewidth = this.wireframeLinewidth), this.wireframeLinecap !== "round" && (i.wireframeLinecap = this.wireframeLinecap), this.wireframeLinejoin !== "round" && (i.wireframeLinejoin = this.wireframeLinejoin), this.flatShading === !0 && (i.flatShading = !0), this.visible === !1 && (i.visible = !1), this.toneMapped === !1 && (i.toneMapped = !1), this.fog === !1 && (i.fog = !1), Object.keys(this.userData).length > 0 && (i.userData = this.userData);
1103
+ i.uuid = this.uuid, i.type = this.type, this.name !== "" && (i.name = this.name), this.color && this.color.isColor && (i.color = this.color.getHex()), this.roughness !== void 0 && (i.roughness = this.roughness), this.metalness !== void 0 && (i.metalness = this.metalness), this.sheen !== void 0 && (i.sheen = this.sheen), this.sheenColor && this.sheenColor.isColor && (i.sheenColor = this.sheenColor.getHex()), this.sheenRoughness !== void 0 && (i.sheenRoughness = this.sheenRoughness), this.emissive && this.emissive.isColor && (i.emissive = this.emissive.getHex()), this.emissiveIntensity !== void 0 && this.emissiveIntensity !== 1 && (i.emissiveIntensity = this.emissiveIntensity), this.specular && this.specular.isColor && (i.specular = this.specular.getHex()), this.specularIntensity !== void 0 && (i.specularIntensity = this.specularIntensity), this.specularColor && this.specularColor.isColor && (i.specularColor = this.specularColor.getHex()), this.shininess !== void 0 && (i.shininess = this.shininess), this.clearcoat !== void 0 && (i.clearcoat = this.clearcoat), this.clearcoatRoughness !== void 0 && (i.clearcoatRoughness = this.clearcoatRoughness), this.clearcoatMap && this.clearcoatMap.isTexture && (i.clearcoatMap = this.clearcoatMap.toJSON(t).uuid), this.clearcoatRoughnessMap && this.clearcoatRoughnessMap.isTexture && (i.clearcoatRoughnessMap = this.clearcoatRoughnessMap.toJSON(t).uuid), this.clearcoatNormalMap && this.clearcoatNormalMap.isTexture && (i.clearcoatNormalMap = this.clearcoatNormalMap.toJSON(t).uuid, i.clearcoatNormalScale = this.clearcoatNormalScale.toArray()), this.sheenColorMap && this.sheenColorMap.isTexture && (i.sheenColorMap = this.sheenColorMap.toJSON(t).uuid), this.sheenRoughnessMap && this.sheenRoughnessMap.isTexture && (i.sheenRoughnessMap = this.sheenRoughnessMap.toJSON(t).uuid), this.dispersion !== void 0 && (i.dispersion = this.dispersion), this.iridescence !== void 0 && (i.iridescence = this.iridescence), this.iridescenceIOR !== void 0 && (i.iridescenceIOR = this.iridescenceIOR), this.iridescenceThicknessRange !== void 0 && (i.iridescenceThicknessRange = this.iridescenceThicknessRange), this.iridescenceMap && this.iridescenceMap.isTexture && (i.iridescenceMap = this.iridescenceMap.toJSON(t).uuid), this.iridescenceThicknessMap && this.iridescenceThicknessMap.isTexture && (i.iridescenceThicknessMap = this.iridescenceThicknessMap.toJSON(t).uuid), this.anisotropy !== void 0 && (i.anisotropy = this.anisotropy), this.anisotropyRotation !== void 0 && (i.anisotropyRotation = this.anisotropyRotation), this.anisotropyMap && this.anisotropyMap.isTexture && (i.anisotropyMap = this.anisotropyMap.toJSON(t).uuid), this.map && this.map.isTexture && (i.map = this.map.toJSON(t).uuid), this.matcap && this.matcap.isTexture && (i.matcap = this.matcap.toJSON(t).uuid), this.alphaMap && this.alphaMap.isTexture && (i.alphaMap = this.alphaMap.toJSON(t).uuid), this.lightMap && this.lightMap.isTexture && (i.lightMap = this.lightMap.toJSON(t).uuid, i.lightMapIntensity = this.lightMapIntensity), this.aoMap && this.aoMap.isTexture && (i.aoMap = this.aoMap.toJSON(t).uuid, i.aoMapIntensity = this.aoMapIntensity), this.bumpMap && this.bumpMap.isTexture && (i.bumpMap = this.bumpMap.toJSON(t).uuid, i.bumpScale = this.bumpScale), this.normalMap && this.normalMap.isTexture && (i.normalMap = this.normalMap.toJSON(t).uuid, i.normalMapType = this.normalMapType, i.normalScale = this.normalScale.toArray()), this.displacementMap && this.displacementMap.isTexture && (i.displacementMap = this.displacementMap.toJSON(t).uuid, i.displacementScale = this.displacementScale, i.displacementBias = this.displacementBias), this.roughnessMap && this.roughnessMap.isTexture && (i.roughnessMap = this.roughnessMap.toJSON(t).uuid), this.metalnessMap && this.metalnessMap.isTexture && (i.metalnessMap = this.metalnessMap.toJSON(t).uuid), this.emissiveMap && this.emissiveMap.isTexture && (i.emissiveMap = this.emissiveMap.toJSON(t).uuid), this.specularMap && this.specularMap.isTexture && (i.specularMap = this.specularMap.toJSON(t).uuid), this.specularIntensityMap && this.specularIntensityMap.isTexture && (i.specularIntensityMap = this.specularIntensityMap.toJSON(t).uuid), this.specularColorMap && this.specularColorMap.isTexture && (i.specularColorMap = this.specularColorMap.toJSON(t).uuid), this.envMap && this.envMap.isTexture && (i.envMap = this.envMap.toJSON(t).uuid, this.combine !== void 0 && (i.combine = this.combine)), this.envMapRotation !== void 0 && (i.envMapRotation = this.envMapRotation.toArray()), this.envMapIntensity !== void 0 && (i.envMapIntensity = this.envMapIntensity), this.reflectivity !== void 0 && (i.reflectivity = this.reflectivity), this.refractionRatio !== void 0 && (i.refractionRatio = this.refractionRatio), this.gradientMap && this.gradientMap.isTexture && (i.gradientMap = this.gradientMap.toJSON(t).uuid), this.transmission !== void 0 && (i.transmission = this.transmission), this.transmissionMap && this.transmissionMap.isTexture && (i.transmissionMap = this.transmissionMap.toJSON(t).uuid), this.thickness !== void 0 && (i.thickness = this.thickness), this.thicknessMap && this.thicknessMap.isTexture && (i.thicknessMap = this.thicknessMap.toJSON(t).uuid), this.attenuationDistance !== void 0 && this.attenuationDistance !== 1 / 0 && (i.attenuationDistance = this.attenuationDistance), this.attenuationColor !== void 0 && (i.attenuationColor = this.attenuationColor.getHex()), this.size !== void 0 && (i.size = this.size), this.shadowSide !== null && (i.shadowSide = this.shadowSide), this.sizeAttenuation !== void 0 && (i.sizeAttenuation = this.sizeAttenuation), this.blending !== xt && (i.blending = this.blending), this.side !== bt && (i.side = this.side), this.vertexColors === !0 && (i.vertexColors = !0), this.opacity < 1 && (i.opacity = this.opacity), this.transparent === !0 && (i.transparent = !0), this.blendSrc !== yt && (i.blendSrc = this.blendSrc), this.blendDst !== Ft && (i.blendDst = this.blendDst), this.blendEquation !== St && (i.blendEquation = this.blendEquation), this.blendSrcAlpha !== null && (i.blendSrcAlpha = this.blendSrcAlpha), this.blendDstAlpha !== null && (i.blendDstAlpha = this.blendDstAlpha), this.blendEquationAlpha !== null && (i.blendEquationAlpha = this.blendEquationAlpha), this.blendColor && this.blendColor.isColor && (i.blendColor = this.blendColor.getHex()), this.blendAlpha !== 0 && (i.blendAlpha = this.blendAlpha), this.depthFunc !== At && (i.depthFunc = this.depthFunc), this.depthTest === !1 && (i.depthTest = this.depthTest), this.depthWrite === !1 && (i.depthWrite = this.depthWrite), this.colorWrite === !1 && (i.colorWrite = this.colorWrite), this.stencilWriteMask !== 255 && (i.stencilWriteMask = this.stencilWriteMask), this.stencilFunc !== Mt && (i.stencilFunc = this.stencilFunc), this.stencilRef !== 0 && (i.stencilRef = this.stencilRef), this.stencilFuncMask !== 255 && (i.stencilFuncMask = this.stencilFuncMask), this.stencilFail !== I && (i.stencilFail = this.stencilFail), this.stencilZFail !== I && (i.stencilZFail = this.stencilZFail), this.stencilZPass !== I && (i.stencilZPass = this.stencilZPass), this.stencilWrite === !0 && (i.stencilWrite = this.stencilWrite), this.rotation !== void 0 && this.rotation !== 0 && (i.rotation = this.rotation), this.polygonOffset === !0 && (i.polygonOffset = !0), this.polygonOffsetFactor !== 0 && (i.polygonOffsetFactor = this.polygonOffsetFactor), this.polygonOffsetUnits !== 0 && (i.polygonOffsetUnits = this.polygonOffsetUnits), this.linewidth !== void 0 && this.linewidth !== 1 && (i.linewidth = this.linewidth), this.dashSize !== void 0 && (i.dashSize = this.dashSize), this.gapSize !== void 0 && (i.gapSize = this.gapSize), this.scale !== void 0 && (i.scale = this.scale), this.dithering === !0 && (i.dithering = !0), this.alphaTest > 0 && (i.alphaTest = this.alphaTest), this.alphaHash === !0 && (i.alphaHash = !0), this.alphaToCoverage === !0 && (i.alphaToCoverage = !0), this.premultipliedAlpha === !0 && (i.premultipliedAlpha = !0), this.forceSinglePass === !0 && (i.forceSinglePass = !0), this.allowOverride === !1 && (i.allowOverride = !1), this.wireframe === !0 && (i.wireframe = !0), this.wireframeLinewidth > 1 && (i.wireframeLinewidth = this.wireframeLinewidth), this.wireframeLinecap !== "round" && (i.wireframeLinecap = this.wireframeLinecap), this.wireframeLinejoin !== "round" && (i.wireframeLinejoin = this.wireframeLinejoin), this.flatShading === !0 && (i.flatShading = !0), this.visible === !1 && (i.visible = !1), this.toneMapped === !1 && (i.toneMapped = !1), this.fog === !1 && (i.fog = !1), Object.keys(this.userData).length > 0 && (i.userData = this.userData);
1113
1104
  function s(n) {
1114
1105
  const r = [];
1115
1106
  for (const o in n) {
@@ -1148,7 +1139,7 @@ class Gt extends Ct {
1148
1139
  for (let n = 0; n !== s; ++n)
1149
1140
  i[n] = e[n].clone();
1150
1141
  }
1151
- return this.clippingPlanes = i, this.clipIntersection = t.clipIntersection, this.clipShadows = t.clipShadows, this.shadowSide = t.shadowSide, this.colorWrite = t.colorWrite, this.precision = t.precision, this.polygonOffset = t.polygonOffset, this.polygonOffsetFactor = t.polygonOffsetFactor, this.polygonOffsetUnits = t.polygonOffsetUnits, this.dithering = t.dithering, this.alphaTest = t.alphaTest, this.alphaHash = t.alphaHash, this.alphaToCoverage = t.alphaToCoverage, this.premultipliedAlpha = t.premultipliedAlpha, this.forceSinglePass = t.forceSinglePass, this.visible = t.visible, this.toneMapped = t.toneMapped, this.userData = JSON.parse(JSON.stringify(t.userData)), this;
1142
+ return this.clippingPlanes = i, this.clipIntersection = t.clipIntersection, this.clipShadows = t.clipShadows, this.shadowSide = t.shadowSide, this.colorWrite = t.colorWrite, this.precision = t.precision, this.polygonOffset = t.polygonOffset, this.polygonOffsetFactor = t.polygonOffsetFactor, this.polygonOffsetUnits = t.polygonOffsetUnits, this.dithering = t.dithering, this.alphaTest = t.alphaTest, this.alphaHash = t.alphaHash, this.alphaToCoverage = t.alphaToCoverage, this.premultipliedAlpha = t.premultipliedAlpha, this.forceSinglePass = t.forceSinglePass, this.allowOverride = t.allowOverride, this.visible = t.visible, this.toneMapped = t.toneMapped, this.userData = JSON.parse(JSON.stringify(t.userData)), this;
1152
1143
  }
1153
1144
  /**
1154
1145
  * Frees the GPU-related resources allocated by this instance. Call this
@@ -1171,9 +1162,9 @@ class Gt extends Ct {
1171
1162
  t === !0 && this.version++;
1172
1163
  }
1173
1164
  }
1174
- const m = /* @__PURE__ */ new d(), U = /* @__PURE__ */ new j();
1175
- let qt = 0;
1176
- class q {
1165
+ const m = /* @__PURE__ */ new d(), $ = /* @__PURE__ */ new Q();
1166
+ let Xt = 0;
1167
+ class X {
1177
1168
  /**
1178
1169
  * Constructs a new buffer attribute.
1179
1170
  *
@@ -1184,7 +1175,7 @@ class q {
1184
1175
  constructor(t, e, i = !1) {
1185
1176
  if (Array.isArray(t))
1186
1177
  throw new TypeError("THREE.BufferAttribute: array should be a Typed Array.");
1187
- this.isBufferAttribute = !0, Object.defineProperty(this, "id", { value: qt++ }), this.name = "", this.array = t, this.itemSize = e, this.count = t !== void 0 ? t.length / e : 0, this.normalized = i, this.usage = St, this.updateRanges = [], this.gpuType = vt, this.version = 0;
1178
+ this.isBufferAttribute = !0, Object.defineProperty(this, "id", { value: Xt++ }), this.name = "", this.array = t, this.itemSize = e, this.count = t !== void 0 ? t.length / e : 0, this.normalized = i, this.usage = Bt, this.updateRanges = [], this.gpuType = Et, this.version = 0;
1188
1179
  }
1189
1180
  /**
1190
1181
  * A callback function that is executed after the renderer has transferred the attribute
@@ -1271,7 +1262,7 @@ class q {
1271
1262
  applyMatrix3(t) {
1272
1263
  if (this.itemSize === 2)
1273
1264
  for (let e = 0, i = this.count; e < i; e++)
1274
- U.fromBufferAttribute(this, e), U.applyMatrix3(t), this.setXY(e, U.x, U.y);
1265
+ $.fromBufferAttribute(this, e), $.applyMatrix3(t), this.setXY(e, $.x, $.y);
1275
1266
  else if (this.itemSize === 3)
1276
1267
  for (let e = 0, i = this.count; e < i; e++)
1277
1268
  m.fromBufferAttribute(this, e), m.applyMatrix3(t), this.setXYZ(e, m.x, m.y, m.z);
@@ -1332,7 +1323,7 @@ class q {
1332
1323
  */
1333
1324
  getComponent(t, e) {
1334
1325
  let i = this.array[t * this.itemSize + e];
1335
- return this.normalized && (i = J(i, this.array)), i;
1326
+ return this.normalized && (i = W(i, this.array)), i;
1336
1327
  }
1337
1328
  /**
1338
1329
  * Sets the given value to the given component of the vector at the given index.
@@ -1353,7 +1344,7 @@ class q {
1353
1344
  */
1354
1345
  getX(t) {
1355
1346
  let e = this.array[t * this.itemSize];
1356
- return this.normalized && (e = J(e, this.array)), e;
1347
+ return this.normalized && (e = W(e, this.array)), e;
1357
1348
  }
1358
1349
  /**
1359
1350
  * Sets the x component of the vector at the given index.
@@ -1373,7 +1364,7 @@ class q {
1373
1364
  */
1374
1365
  getY(t) {
1375
1366
  let e = this.array[t * this.itemSize + 1];
1376
- return this.normalized && (e = J(e, this.array)), e;
1367
+ return this.normalized && (e = W(e, this.array)), e;
1377
1368
  }
1378
1369
  /**
1379
1370
  * Sets the y component of the vector at the given index.
@@ -1393,7 +1384,7 @@ class q {
1393
1384
  */
1394
1385
  getZ(t) {
1395
1386
  let e = this.array[t * this.itemSize + 2];
1396
- return this.normalized && (e = J(e, this.array)), e;
1387
+ return this.normalized && (e = W(e, this.array)), e;
1397
1388
  }
1398
1389
  /**
1399
1390
  * Sets the z component of the vector at the given index.
@@ -1413,7 +1404,7 @@ class q {
1413
1404
  */
1414
1405
  getW(t) {
1415
1406
  let e = this.array[t * this.itemSize + 3];
1416
- return this.normalized && (e = J(e, this.array)), e;
1407
+ return this.normalized && (e = W(e, this.array)), e;
1417
1408
  }
1418
1409
  /**
1419
1410
  * Sets the w component of the vector at the given index.
@@ -1492,10 +1483,10 @@ class q {
1492
1483
  array: Array.from(this.array),
1493
1484
  normalized: this.normalized
1494
1485
  };
1495
- return this.name !== "" && (t.name = this.name), this.usage !== St && (t.usage = this.usage), t;
1486
+ return this.name !== "" && (t.name = this.name), this.usage !== Bt && (t.usage = this.usage), t;
1496
1487
  }
1497
1488
  }
1498
- class Zt extends q {
1489
+ class Jt extends X {
1499
1490
  /**
1500
1491
  * Constructs a new buffer attribute.
1501
1492
  *
@@ -1507,7 +1498,7 @@ class Zt extends q {
1507
1498
  super(new Uint16Array(t), e, i);
1508
1499
  }
1509
1500
  }
1510
- class Xt extends q {
1501
+ class Lt extends X {
1511
1502
  /**
1512
1503
  * Constructs a new buffer attribute.
1513
1504
  *
@@ -1519,7 +1510,7 @@ class Xt extends q {
1519
1510
  super(new Uint32Array(t), e, i);
1520
1511
  }
1521
1512
  }
1522
- class Jt extends q {
1513
+ class Wt extends X {
1523
1514
  /**
1524
1515
  * Constructs a new buffer attribute.
1525
1516
  *
@@ -1531,14 +1522,14 @@ class Jt extends q {
1531
1522
  super(new Float32Array(t), e, i);
1532
1523
  }
1533
1524
  }
1534
- let Lt = 0;
1535
- const B = /* @__PURE__ */ new zt(), at = /* @__PURE__ */ new Nt(), I = /* @__PURE__ */ new d(), A = /* @__PURE__ */ new ht(), L = /* @__PURE__ */ new ht(), b = /* @__PURE__ */ new d();
1536
- class Et extends Ct {
1525
+ let _t = 0;
1526
+ const B = /* @__PURE__ */ new Ot(), ht = /* @__PURE__ */ new It(), P = /* @__PURE__ */ new d(), A = /* @__PURE__ */ new ut(), G = /* @__PURE__ */ new ut(), b = /* @__PURE__ */ new d();
1527
+ class Dt extends Tt {
1537
1528
  /**
1538
1529
  * Constructs a new geometry.
1539
1530
  */
1540
1531
  constructor() {
1541
- super(), this.isBufferGeometry = !0, Object.defineProperty(this, "id", { value: Lt++ }), this.uuid = Tt(), this.name = "", this.type = "BufferGeometry", this.index = null, this.indirect = null, this.attributes = {}, this.morphAttributes = {}, this.morphTargetsRelative = !1, this.groups = [], this.boundingBox = null, this.boundingSphere = null, this.drawRange = { start: 0, count: 1 / 0 }, this.userData = {};
1532
+ super(), this.isBufferGeometry = !0, Object.defineProperty(this, "id", { value: _t++ }), this.uuid = kt(), this.name = "", this.type = "BufferGeometry", this.index = null, this.indirect = null, this.indirectOffset = 0, this.attributes = {}, this.morphAttributes = {}, this.morphTargetsRelative = !1, this.groups = [], this.boundingBox = null, this.boundingSphere = null, this.drawRange = { start: 0, count: 1 / 0 }, this.userData = {};
1542
1533
  }
1543
1534
  /**
1544
1535
  * Returns the index of this geometry.
@@ -1555,16 +1546,17 @@ class Et extends Ct {
1555
1546
  * @return {BufferGeometry} A reference to this instance.
1556
1547
  */
1557
1548
  setIndex(t) {
1558
- return Array.isArray(t) ? this.index = new (It(t) ? Xt : Zt)(t, 1) : this.index = t, this;
1549
+ return Array.isArray(t) ? this.index = new (Nt(t) ? Lt : Jt)(t, 1) : this.index = t, this;
1559
1550
  }
1560
1551
  /**
1561
1552
  * Sets the given indirect attribute to this geometry.
1562
1553
  *
1563
1554
  * @param {BufferAttribute} indirect - The attribute holding indirect draw calls.
1555
+ * @param {number|Array<number>} [indirectOffset=0] - The offset, in bytes, into the indirect drawing buffer where the value data begins. If an array is provided, multiple indirect draw calls will be made for each offset.
1564
1556
  * @return {BufferGeometry} A reference to this instance.
1565
1557
  */
1566
- setIndirect(t) {
1567
- return this.indirect = t, this;
1558
+ setIndirect(t, e = 0) {
1559
+ return this.indirect = t, this.indirectOffset = e, this;
1568
1560
  }
1569
1561
  /**
1570
1562
  * Returns the indirect attribute of this geometry.
@@ -1654,7 +1646,7 @@ class Et extends Ct {
1654
1646
  e !== void 0 && (e.applyMatrix4(t), e.needsUpdate = !0);
1655
1647
  const i = this.attributes.normal;
1656
1648
  if (i !== void 0) {
1657
- const n = new ot().getNormalMatrix(t);
1649
+ const n = new lt().getNormalMatrix(t);
1658
1650
  i.applyNormalMatrix(n), i.needsUpdate = !0;
1659
1651
  }
1660
1652
  const s = this.attributes.tangent;
@@ -1737,7 +1729,7 @@ class Et extends Ct {
1737
1729
  * @return {BufferGeometry} A reference to this instance.
1738
1730
  */
1739
1731
  lookAt(t) {
1740
- return at.lookAt(t), at.updateMatrix(), this.applyMatrix4(at.matrix), this;
1732
+ return ht.lookAt(t), ht.updateMatrix(), this.applyMatrix4(ht.matrix), this;
1741
1733
  }
1742
1734
  /**
1743
1735
  * Center the geometry based on its bounding box.
@@ -1745,7 +1737,7 @@ class Et extends Ct {
1745
1737
  * @return {BufferGeometry} A reference to this instance.
1746
1738
  */
1747
1739
  center() {
1748
- return this.computeBoundingBox(), this.boundingBox.getCenter(I).negate(), this.translate(I.x, I.y, I.z), this;
1740
+ return this.computeBoundingBox(), this.boundingBox.getCenter(P).negate(), this.translate(P.x, P.y, P.z), this;
1749
1741
  }
1750
1742
  /**
1751
1743
  * Defines a geometry by creating a `position` attribute based on the given array of points. The array
@@ -1766,14 +1758,14 @@ class Et extends Ct {
1766
1758
  const r = t[s];
1767
1759
  i.push(r.x, r.y, r.z || 0);
1768
1760
  }
1769
- this.setAttribute("position", new Jt(i, 3));
1761
+ this.setAttribute("position", new Wt(i, 3));
1770
1762
  } else {
1771
1763
  const i = Math.min(t.length, e.count);
1772
1764
  for (let s = 0; s < i; s++) {
1773
1765
  const n = t[s];
1774
1766
  e.setXYZ(s, n.x, n.y, n.z || 0);
1775
1767
  }
1776
- t.length > e.count && console.warn("THREE.BufferGeometry: Buffer size too small for points data. Use .dispose() and create a new geometry."), e.needsUpdate = !0;
1768
+ t.length > e.count && N("BufferGeometry: Buffer size too small for points data. Use .dispose() and create a new geometry."), e.needsUpdate = !0;
1777
1769
  }
1778
1770
  return this;
1779
1771
  }
@@ -1783,10 +1775,10 @@ class Et extends Ct {
1783
1775
  * You may need to recompute the bounding box if the geometry vertices are modified.
1784
1776
  */
1785
1777
  computeBoundingBox() {
1786
- this.boundingBox === null && (this.boundingBox = new ht());
1778
+ this.boundingBox === null && (this.boundingBox = new ut());
1787
1779
  const t = this.attributes.position, e = this.morphAttributes.position;
1788
1780
  if (t && t.isGLBufferAttribute) {
1789
- console.error("THREE.BufferGeometry.computeBoundingBox(): GLBufferAttribute requires a manual bounding box.", this), this.boundingBox.set(
1781
+ _("BufferGeometry.computeBoundingBox(): GLBufferAttribute requires a manual bounding box.", this), this.boundingBox.set(
1790
1782
  new d(-1 / 0, -1 / 0, -1 / 0),
1791
1783
  new d(1 / 0, 1 / 0, 1 / 0)
1792
1784
  );
@@ -1800,7 +1792,7 @@ class Et extends Ct {
1800
1792
  }
1801
1793
  } else
1802
1794
  this.boundingBox.makeEmpty();
1803
- (isNaN(this.boundingBox.min.x) || isNaN(this.boundingBox.min.y) || isNaN(this.boundingBox.min.z)) && console.error('THREE.BufferGeometry.computeBoundingBox(): Computed min/max have NaN values. The "position" attribute is likely to have NaN values.', this);
1795
+ (isNaN(this.boundingBox.min.x) || isNaN(this.boundingBox.min.y) || isNaN(this.boundingBox.min.z)) && _('BufferGeometry.computeBoundingBox(): Computed min/max have NaN values. The "position" attribute is likely to have NaN values.', this);
1804
1796
  }
1805
1797
  /**
1806
1798
  * Computes the bounding sphere of the geometry, and updates the `boundingSphere` member.
@@ -1808,10 +1800,10 @@ class Et extends Ct {
1808
1800
  * You may need to recompute the bounding sphere if the geometry vertices are modified.
1809
1801
  */
1810
1802
  computeBoundingSphere() {
1811
- this.boundingSphere === null && (this.boundingSphere = new Ot());
1803
+ this.boundingSphere === null && (this.boundingSphere = new Pt());
1812
1804
  const t = this.attributes.position, e = this.morphAttributes.position;
1813
1805
  if (t && t.isGLBufferAttribute) {
1814
- console.error("THREE.BufferGeometry.computeBoundingSphere(): GLBufferAttribute requires a manual bounding sphere.", this), this.boundingSphere.set(new d(), 1 / 0);
1806
+ _("BufferGeometry.computeBoundingSphere(): GLBufferAttribute requires a manual bounding sphere.", this), this.boundingSphere.set(new d(), 1 / 0);
1815
1807
  return;
1816
1808
  }
1817
1809
  if (t) {
@@ -1819,7 +1811,7 @@ class Et extends Ct {
1819
1811
  if (A.setFromBufferAttribute(t), e)
1820
1812
  for (let n = 0, r = e.length; n < r; n++) {
1821
1813
  const o = e[n];
1822
- L.setFromBufferAttribute(o), this.morphTargetsRelative ? (b.addVectors(A.min, L.min), A.expandByPoint(b), b.addVectors(A.max, L.max), A.expandByPoint(b)) : (A.expandByPoint(L.min), A.expandByPoint(L.max));
1814
+ G.setFromBufferAttribute(o), this.morphTargetsRelative ? (b.addVectors(A.min, G.min), A.expandByPoint(b), b.addVectors(A.max, G.max), A.expandByPoint(b)) : (A.expandByPoint(G.min), A.expandByPoint(G.max));
1823
1815
  }
1824
1816
  A.getCenter(i);
1825
1817
  let s = 0;
@@ -1829,9 +1821,9 @@ class Et extends Ct {
1829
1821
  for (let n = 0, r = e.length; n < r; n++) {
1830
1822
  const o = e[n], h = this.morphTargetsRelative;
1831
1823
  for (let l = 0, c = o.count; l < c; l++)
1832
- b.fromBufferAttribute(o, l), h && (I.fromBufferAttribute(t, l), b.add(I)), s = Math.max(s, i.distanceToSquared(b));
1824
+ b.fromBufferAttribute(o, l), h && (P.fromBufferAttribute(t, l), b.add(P)), s = Math.max(s, i.distanceToSquared(b));
1833
1825
  }
1834
- this.boundingSphere.radius = Math.sqrt(s), isNaN(this.boundingSphere.radius) && console.error('THREE.BufferGeometry.computeBoundingSphere(): Computed radius is NaN. The "position" attribute is likely to have NaN values.', this);
1826
+ this.boundingSphere.radius = Math.sqrt(s), isNaN(this.boundingSphere.radius) && _('BufferGeometry.computeBoundingSphere(): Computed radius is NaN. The "position" attribute is likely to have NaN values.', this);
1835
1827
  }
1836
1828
  }
1837
1829
  /**
@@ -1844,46 +1836,46 @@ class Et extends Ct {
1844
1836
  computeTangents() {
1845
1837
  const t = this.index, e = this.attributes;
1846
1838
  if (t === null || e.position === void 0 || e.normal === void 0 || e.uv === void 0) {
1847
- console.error("THREE.BufferGeometry: .computeTangents() failed. Missing required attributes (index, position, normal or uv)");
1839
+ _("BufferGeometry: .computeTangents() failed. Missing required attributes (index, position, normal or uv)");
1848
1840
  return;
1849
1841
  }
1850
1842
  const i = e.position, s = e.normal, n = e.uv;
1851
- this.hasAttribute("tangent") === !1 && this.setAttribute("tangent", new q(new Float32Array(4 * i.count), 4));
1843
+ this.hasAttribute("tangent") === !1 && this.setAttribute("tangent", new X(new Float32Array(4 * i.count), 4));
1852
1844
  const r = this.getAttribute("tangent"), o = [], h = [];
1853
1845
  for (let g = 0; g < i.count; g++)
1854
1846
  o[g] = new d(), h[g] = new d();
1855
- const l = new d(), c = new d(), u = new d(), a = new j(), f = new j(), x = new j(), y = new d(), R = new d();
1856
- function W(g, M, w) {
1857
- l.fromBufferAttribute(i, g), c.fromBufferAttribute(i, M), u.fromBufferAttribute(i, w), a.fromBufferAttribute(n, g), f.fromBufferAttribute(n, M), x.fromBufferAttribute(n, w), c.sub(l), u.sub(l), f.sub(a), x.sub(a);
1858
- const C = 1 / (f.x * x.y - x.x * f.y);
1859
- isFinite(C) && (y.copy(c).multiplyScalar(x.y).addScaledVector(u, -f.y).multiplyScalar(C), R.copy(u).multiplyScalar(f.x).addScaledVector(c, -x.x).multiplyScalar(C), o[g].add(y), o[M].add(y), o[w].add(y), h[g].add(R), h[M].add(R), h[w].add(R));
1847
+ const l = new d(), c = new d(), u = new d(), a = new Q(), p = new Q(), x = new Q(), y = new d(), D = new d();
1848
+ function V(g, M, w) {
1849
+ l.fromBufferAttribute(i, g), c.fromBufferAttribute(i, M), u.fromBufferAttribute(i, w), a.fromBufferAttribute(n, g), p.fromBufferAttribute(n, M), x.fromBufferAttribute(n, w), c.sub(l), u.sub(l), p.sub(a), x.sub(a);
1850
+ const C = 1 / (p.x * x.y - x.x * p.y);
1851
+ isFinite(C) && (y.copy(c).multiplyScalar(x.y).addScaledVector(u, -p.y).multiplyScalar(C), D.copy(u).multiplyScalar(p.x).addScaledVector(c, -x.x).multiplyScalar(C), o[g].add(y), o[M].add(y), o[w].add(y), h[g].add(D), h[M].add(D), h[w].add(D));
1860
1852
  }
1861
- let N = this.groups;
1862
- N.length === 0 && (N = [{
1853
+ let O = this.groups;
1854
+ O.length === 0 && (O = [{
1863
1855
  start: 0,
1864
1856
  count: t.count
1865
1857
  }]);
1866
- for (let g = 0, M = N.length; g < M; ++g) {
1867
- const w = N[g], C = w.start, Q = w.count;
1868
- for (let T = C, K = C + Q; T < K; T += 3)
1869
- W(
1858
+ for (let g = 0, M = O.length; g < M; ++g) {
1859
+ const w = O[g], C = w.start, tt = w.count;
1860
+ for (let T = C, it = C + tt; T < it; T += 3)
1861
+ V(
1870
1862
  t.getX(T + 0),
1871
1863
  t.getX(T + 1),
1872
1864
  t.getX(T + 2)
1873
1865
  );
1874
1866
  }
1875
- const Z = new d(), ut = new d(), _ = new d(), ct = new d();
1876
- function $(g) {
1877
- _.fromBufferAttribute(s, g), ct.copy(_);
1867
+ const J = new d(), dt = new d(), Y = new d(), pt = new d();
1868
+ function K(g) {
1869
+ Y.fromBufferAttribute(s, g), pt.copy(Y);
1878
1870
  const M = o[g];
1879
- Z.copy(M), Z.sub(_.multiplyScalar(_.dot(M))).normalize(), ut.crossVectors(ct, M);
1880
- const C = ut.dot(h[g]) < 0 ? -1 : 1;
1881
- r.setXYZW(g, Z.x, Z.y, Z.z, C);
1871
+ J.copy(M), J.sub(Y.multiplyScalar(Y.dot(M))).normalize(), dt.crossVectors(pt, M);
1872
+ const C = dt.dot(h[g]) < 0 ? -1 : 1;
1873
+ r.setXYZW(g, J.x, J.y, J.z, C);
1882
1874
  }
1883
- for (let g = 0, M = N.length; g < M; ++g) {
1884
- const w = N[g], C = w.start, Q = w.count;
1885
- for (let T = C, K = C + Q; T < K; T += 3)
1886
- $(t.getX(T + 0)), $(t.getX(T + 1)), $(t.getX(T + 2));
1875
+ for (let g = 0, M = O.length; g < M; ++g) {
1876
+ const w = O[g], C = w.start, tt = w.count;
1877
+ for (let T = C, it = C + tt; T < it; T += 3)
1878
+ K(t.getX(T + 0)), K(t.getX(T + 1)), K(t.getX(T + 2));
1887
1879
  }
1888
1880
  }
1889
1881
  /**
@@ -1897,18 +1889,18 @@ class Et extends Ct {
1897
1889
  if (e !== void 0) {
1898
1890
  let i = this.getAttribute("normal");
1899
1891
  if (i === void 0)
1900
- i = new q(new Float32Array(e.count * 3), 3), this.setAttribute("normal", i);
1892
+ i = new X(new Float32Array(e.count * 3), 3), this.setAttribute("normal", i);
1901
1893
  else
1902
- for (let a = 0, f = i.count; a < f; a++)
1894
+ for (let a = 0, p = i.count; a < p; a++)
1903
1895
  i.setXYZ(a, 0, 0, 0);
1904
1896
  const s = new d(), n = new d(), r = new d(), o = new d(), h = new d(), l = new d(), c = new d(), u = new d();
1905
1897
  if (t)
1906
- for (let a = 0, f = t.count; a < f; a += 3) {
1907
- const x = t.getX(a + 0), y = t.getX(a + 1), R = t.getX(a + 2);
1908
- s.fromBufferAttribute(e, x), n.fromBufferAttribute(e, y), r.fromBufferAttribute(e, R), c.subVectors(r, n), u.subVectors(s, n), c.cross(u), o.fromBufferAttribute(i, x), h.fromBufferAttribute(i, y), l.fromBufferAttribute(i, R), o.add(c), h.add(c), l.add(c), i.setXYZ(x, o.x, o.y, o.z), i.setXYZ(y, h.x, h.y, h.z), i.setXYZ(R, l.x, l.y, l.z);
1898
+ for (let a = 0, p = t.count; a < p; a += 3) {
1899
+ const x = t.getX(a + 0), y = t.getX(a + 1), D = t.getX(a + 2);
1900
+ s.fromBufferAttribute(e, x), n.fromBufferAttribute(e, y), r.fromBufferAttribute(e, D), c.subVectors(r, n), u.subVectors(s, n), c.cross(u), o.fromBufferAttribute(i, x), h.fromBufferAttribute(i, y), l.fromBufferAttribute(i, D), o.add(c), h.add(c), l.add(c), i.setXYZ(x, o.x, o.y, o.z), i.setXYZ(y, h.x, h.y, h.z), i.setXYZ(D, l.x, l.y, l.z);
1909
1901
  }
1910
1902
  else
1911
- for (let a = 0, f = e.count; a < f; a += 3)
1903
+ for (let a = 0, p = e.count; a < p; a += 3)
1912
1904
  s.fromBufferAttribute(e, a + 0), n.fromBufferAttribute(e, a + 1), r.fromBufferAttribute(e, a + 2), c.subVectors(r, n), u.subVectors(s, n), c.cross(u), i.setXYZ(a + 0, c.x, c.y, c.z), i.setXYZ(a + 1, c.x, c.y, c.z), i.setXYZ(a + 2, c.x, c.y, c.z);
1913
1905
  this.normalizeNormals(), i.needsUpdate = !0;
1914
1906
  }
@@ -1931,17 +1923,17 @@ class Et extends Ct {
1931
1923
  toNonIndexed() {
1932
1924
  function t(o, h) {
1933
1925
  const l = o.array, c = o.itemSize, u = o.normalized, a = new l.constructor(h.length * c);
1934
- let f = 0, x = 0;
1935
- for (let y = 0, R = h.length; y < R; y++) {
1936
- o.isInterleavedBufferAttribute ? f = h[y] * o.data.stride + o.offset : f = h[y] * c;
1937
- for (let W = 0; W < c; W++)
1938
- a[x++] = l[f++];
1926
+ let p = 0, x = 0;
1927
+ for (let y = 0, D = h.length; y < D; y++) {
1928
+ o.isInterleavedBufferAttribute ? p = h[y] * o.data.stride + o.offset : p = h[y] * c;
1929
+ for (let V = 0; V < c; V++)
1930
+ a[x++] = l[p++];
1939
1931
  }
1940
- return new q(a, c, u);
1932
+ return new X(a, c, u);
1941
1933
  }
1942
1934
  if (this.index === null)
1943
- return console.warn("THREE.BufferGeometry.toNonIndexed(): BufferGeometry is already non-indexed."), this;
1944
- const e = new Et(), i = this.index.array, s = this.attributes;
1935
+ return N("BufferGeometry.toNonIndexed(): BufferGeometry is already non-indexed."), this;
1936
+ const e = new Dt(), i = this.index.array, s = this.attributes;
1945
1937
  for (const o in s) {
1946
1938
  const h = s[o], l = t(h, i);
1947
1939
  e.setAttribute(o, l);
@@ -1950,8 +1942,8 @@ class Et extends Ct {
1950
1942
  for (const o in n) {
1951
1943
  const h = [], l = n[o];
1952
1944
  for (let c = 0, u = l.length; c < u; c++) {
1953
- const a = l[c], f = t(a, i);
1954
- h.push(f);
1945
+ const a = l[c], p = t(a, i);
1946
+ h.push(p);
1955
1947
  }
1956
1948
  e.morphAttributes[o] = h;
1957
1949
  }
@@ -1998,8 +1990,8 @@ class Et extends Ct {
1998
1990
  for (const h in this.morphAttributes) {
1999
1991
  const l = this.morphAttributes[h], c = [];
2000
1992
  for (let u = 0, a = l.length; u < a; u++) {
2001
- const f = l[u];
2002
- c.push(f.toJSON(t.data));
1993
+ const p = l[u];
1994
+ c.push(p.toJSON(t.data));
2003
1995
  }
2004
1996
  c.length > 0 && (s[h] = c, n = !0);
2005
1997
  }
@@ -2037,7 +2029,7 @@ class Et extends Ct {
2037
2029
  const n = t.morphAttributes;
2038
2030
  for (const l in n) {
2039
2031
  const c = [], u = n[l];
2040
- for (let a = 0, f = u.length; a < f; a++)
2032
+ for (let a = 0, p = u.length; a < p; a++)
2041
2033
  c.push(u[a].clone(e));
2042
2034
  this.morphAttributes[l] = c;
2043
2035
  }
@@ -2063,10 +2055,10 @@ class Et extends Ct {
2063
2055
  }
2064
2056
  }
2065
2057
  export {
2066
- Et as B,
2067
- lt as C,
2068
- Jt as F,
2069
- Gt as M,
2070
- _t as R
2058
+ Dt as B,
2059
+ ct as C,
2060
+ Wt as F,
2061
+ Yt as M,
2062
+ Vt as R
2071
2063
  };
2072
- //# sourceMappingURL=BufferGeometry-D0oTDT7-.mjs.map
2064
+ //# sourceMappingURL=BufferGeometry-BxcX1nu5.mjs.map