@spiffcommerce/preview 5.3.7 → 5.3.8-rc.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.esm.js CHANGED
@@ -4,16 +4,16 @@ import { NullEngine as Ce } from "@babylonjs/core/Engines/nullEngine";
4
4
  import { HighlightLayer as ye } from "@babylonjs/core/Layers/highlightLayer";
5
5
  import { SceneLoader as fe } from "@babylonjs/core/Loading/sceneLoader";
6
6
  import { CubeTexture as te } from "@babylonjs/core/Materials/Textures/cubeTexture";
7
- import { Color4 as f, Color3 as w } from "@babylonjs/core/Maths/math.color";
8
- import { Vector3 as m, Quaternion as y, Vector2 as ie, Matrix as se } from "@babylonjs/core/Maths/math.vector";
7
+ import { Color4 as b, Color3 as w } from "@babylonjs/core/Maths/math.color";
8
+ import { Vector3 as g, Quaternion as y, Vector2 as ie, Matrix as ne } from "@babylonjs/core/Maths/math.vector";
9
9
  import { DracoCompression as Me } from "@babylonjs/core/Meshes/Compression/dracoCompression";
10
10
  import { Observable as C } from "@babylonjs/core/Misc/observable";
11
- import { Tools as Pe } from "@babylonjs/core/Misc/tools";
12
- import { Scene as xe } from "@babylonjs/core/scene";
11
+ import { Tools as xe } from "@babylonjs/core/Misc/tools";
12
+ import { Scene as Pe } from "@babylonjs/core/scene";
13
13
  import { GLTF2 as Ae } from "@babylonjs/loaders/glTF";
14
14
  import { PBRMaterial as F } from "@babylonjs/core/Materials/PBR/pbrMaterial";
15
15
  import { MirrorTexture as Re } from "@babylonjs/core/Materials/Textures/mirrorTexture";
16
- import { Color3 as Te, Vector3 as ne, Plane as Ee } from "@babylonjs/core/Maths/math";
16
+ import { Color3 as Te, Vector3 as se, Plane as Ee } from "@babylonjs/core/Maths/math";
17
17
  import { ReflectionProbe as Oe } from "@babylonjs/core/Probes/reflectionProbe";
18
18
  import { GlowLayer as Le } from "@babylonjs/core/Layers/glowLayer";
19
19
  import { ActionManager as R } from "@babylonjs/core/Actions/actionManager";
@@ -24,10 +24,10 @@ import { DynamicTexture as Fe } from "@babylonjs/core/Materials/Textures/dynamic
24
24
  import { Texture as Be } from "@babylonjs/core/Materials/Textures/texture";
25
25
  import { Animation as v } from "@babylonjs/core/Animations/animation";
26
26
  import { QuadraticEase as De, EasingFunction as ke } from "@babylonjs/core/Animations/easing";
27
- import { AssetsManager as ze } from "@babylonjs/core/Misc/assetsManager";
27
+ import { AssetsManager as qe } from "@babylonjs/core/Misc/assetsManager";
28
28
  import { ColorCurves as ae } from "@babylonjs/core/Materials/colorCurves";
29
- import { ImageProcessingConfiguration as x } from "@babylonjs/core/Materials/imageProcessingConfiguration";
30
- import { DefaultRenderingPipeline as Ve } from "@babylonjs/core/PostProcesses/RenderPipeline";
29
+ import { ImageProcessingConfiguration as P } from "@babylonjs/core/Materials/imageProcessingConfiguration";
30
+ import { DefaultRenderingPipeline as ze } from "@babylonjs/core/PostProcesses/RenderPipeline";
31
31
  import { DepthOfFieldEffectBlurLevel as T } from "@babylonjs/core/PostProcesses/depthOfFieldEffect";
32
32
  import "@babylonjs/core/Rendering/depthRendererSceneComponent";
33
33
  import "@babylonjs/core/Engines/Extensions/engine.views";
@@ -39,32 +39,32 @@ import "@babylonjs/core/Animations/animatable";
39
39
  import "@babylonjs/core/Misc/screenshotTools";
40
40
  import "@babylonjs/core/Rendering/boundingBoxRenderer";
41
41
  import "@babylonjs/loaders/glTF/2.0/Extensions";
42
- var I = /* @__PURE__ */ ((s) => (s[s.Orbit = 0] = "Orbit", s[s.Pan = 1] = "Pan", s))(I || {}), S = /* @__PURE__ */ ((s) => (s.None = "None", s.RemoveWhenSelected = "RemoveWhenSelected", s.ApplyWhenSelected = "ApplyWhenSelected", s))(S || {});
42
+ var I = /* @__PURE__ */ ((n) => (n[n.Orbit = 0] = "Orbit", n[n.Pan = 1] = "Pan", n))(I || {}), S = /* @__PURE__ */ ((n) => (n.None = "None", n.RemoveWhenSelected = "RemoveWhenSelected", n.ApplyWhenSelected = "ApplyWhenSelected", n))(S || {});
43
43
  class oe {
44
44
  constructor(e) {
45
45
  this.getSceneClearColor = () => {
46
- var i, r, o, a;
47
- const t = (i = this.customOptions) != null && i.transparentBackground || (r = this.customOptions) != null && r.backgroundImage ? 0 : 1;
48
- if (this.customOptions && ((o = this.customOptions) != null && o.transparentBackground) || (a = this.customOptions) != null && a.backgroundImage)
49
- return new f(0, 0, 0, t).toLinearSpace();
46
+ var i, s, a, o;
47
+ const t = (i = this.customOptions) != null && i.transparentBackground || (s = this.customOptions) != null && s.backgroundImage ? 0 : 1;
48
+ if (this.customOptions && ((a = this.customOptions) != null && a.transparentBackground) || (o = this.customOptions) != null && o.backgroundImage)
49
+ return new b(0, 0, 0, t).toLinearSpace();
50
50
  if (this.customOptions && this.customOptions.backgroundColor) {
51
- const n = w.FromHexString(
51
+ const r = w.FromHexString(
52
52
  this.customOptions.backgroundColor
53
53
  );
54
- return new f(
55
- n.r,
56
- n.g,
57
- n.b,
54
+ return new b(
55
+ r.r,
56
+ r.g,
57
+ r.b,
58
58
  t
59
59
  ).toLinearSpace();
60
60
  }
61
- return new f(0.98, 0.98, 0.98, t).toLinearSpace();
62
- }, this.highlightColorFromConfig = () => this.customOptions && this.customOptions.highlightColor ? this.hexToColor4(this.customOptions.highlightColor) : new f(0.98, 0.98, 0.98, 1).toLinearSpace(), this.hexToColor4 = (t, i = 1) => {
63
- const r = w.FromHexString(t);
64
- return new f(
65
- r.r,
66
- r.g,
67
- r.b,
61
+ return new b(0.98, 0.98, 0.98, t).toLinearSpace();
62
+ }, this.highlightColorFromConfig = () => this.customOptions && this.customOptions.highlightColor ? this.hexToColor4(this.customOptions.highlightColor) : new b(0.98, 0.98, 0.98, 1).toLinearSpace(), this.hexToColor4 = (t, i = 1) => {
63
+ const s = w.FromHexString(t);
64
+ return new b(
65
+ s.r,
66
+ s.g,
67
+ s.b,
68
68
  i
69
69
  ).toLinearSpace();
70
70
  }, this.customOptions = e;
@@ -80,14 +80,14 @@ class oe {
80
80
  * Configuration related to the scene
81
81
  */
82
82
  get scene() {
83
- var e, t, i, r, o;
83
+ var e, t, i, s, a;
84
84
  return {
85
85
  clearColor: this.getSceneClearColor(),
86
86
  transparentBackground: ((e = this.customOptions) == null ? void 0 : e.transparentBackground) || ((t = this.customOptions) == null ? void 0 : t.backgroundImage),
87
87
  environment: {
88
88
  file: ((i = this.customOptions) == null ? void 0 : i.environmentFile) ?? "assets/model-viewer/default.env",
89
- intensity: ((r = this.customOptions) == null ? void 0 : r.environmentIntensity) ?? 1,
90
- rotationY: (((o = this.customOptions) == null ? void 0 : o.environmentRotationY) ?? 0) * (Math.PI / 180)
89
+ intensity: ((s = this.customOptions) == null ? void 0 : s.environmentIntensity) ?? 1,
90
+ rotationY: (((a = this.customOptions) == null ? void 0 : a.environmentRotationY) ?? 0) * (Math.PI / 180)
91
91
  // Convert to radians
92
92
  }
93
93
  };
@@ -96,7 +96,7 @@ class oe {
96
96
  * Configuration related to the camera used to view and interact with the scene.
97
97
  */
98
98
  get camera() {
99
- var e, t, i, r, o, a, n, l, c, d, u, g, p;
99
+ var e, t, i, s, a, o, r, l, d, h, u, m, p;
100
100
  return {
101
101
  autoOrientation: ((e = this.customOptions) == null ? void 0 : e.disableAutomaticOrientation) ?? !0,
102
102
  autoRotation: {
@@ -105,13 +105,13 @@ class oe {
105
105
  },
106
106
  limits: {
107
107
  min: {
108
- alpha: (r = this.customOptions) != null && r.lowerAlphaLimitDeg ? ((o = this.customOptions) == null ? void 0 : o.lowerAlphaLimitDeg) * Math.PI / 180 : void 0,
109
- beta: (a = this.customOptions) != null && a.lowerBetaLimitDeg ? ((n = this.customOptions) == null ? void 0 : n.lowerBetaLimitDeg) * Math.PI / 180 : void 0,
108
+ alpha: (s = this.customOptions) != null && s.lowerAlphaLimitDeg ? ((a = this.customOptions) == null ? void 0 : a.lowerAlphaLimitDeg) * Math.PI / 180 : void 0,
109
+ beta: (o = this.customOptions) != null && o.lowerBetaLimitDeg ? ((r = this.customOptions) == null ? void 0 : r.lowerBetaLimitDeg) * Math.PI / 180 : void 0,
110
110
  radius: (l = this.customOptions) == null ? void 0 : l.minZoomOverride
111
111
  },
112
112
  max: {
113
- alpha: (c = this.customOptions) != null && c.upperAlphaLimitDeg ? ((d = this.customOptions) == null ? void 0 : d.upperAlphaLimitDeg) * Math.PI / 180 : void 0,
114
- beta: (u = this.customOptions) != null && u.upperBetaLimitDeg ? ((g = this.customOptions) == null ? void 0 : g.upperBetaLimitDeg) * Math.PI / 180 : void 0,
113
+ alpha: (d = this.customOptions) != null && d.upperAlphaLimitDeg ? ((h = this.customOptions) == null ? void 0 : h.upperAlphaLimitDeg) * Math.PI / 180 : void 0,
114
+ beta: (u = this.customOptions) != null && u.upperBetaLimitDeg ? ((m = this.customOptions) == null ? void 0 : m.upperBetaLimitDeg) * Math.PI / 180 : void 0,
115
115
  radius: (p = this.customOptions) == null ? void 0 : p.maxZoomOverride
116
116
  }
117
117
  }
@@ -129,10 +129,10 @@ class oe {
129
129
  };
130
130
  }
131
131
  get lighting() {
132
- var e, t, i, r;
132
+ var e, t, i, s;
133
133
  return {
134
134
  exposure: ((t = (e = this.customOptions) == null ? void 0 : e.lighting) == null ? void 0 : t.exposure) ?? 0.9,
135
- contrast: ((r = (i = this.customOptions) == null ? void 0 : i.lighting) == null ? void 0 : r.contrast) ?? 1.6
135
+ contrast: ((s = (i = this.customOptions) == null ? void 0 : i.lighting) == null ? void 0 : s.contrast) ?? 1.6
136
136
  };
137
137
  }
138
138
  get emissiveGlowIntensity() {
@@ -140,12 +140,12 @@ class oe {
140
140
  return ((e = this.customOptions) == null ? void 0 : e.emissiveGlowIntensity) ?? 0.5;
141
141
  }
142
142
  }
143
- class P {
143
+ class x {
144
144
  /**
145
145
  * Returns the resolution expected for generated textures.
146
146
  */
147
147
  static getDynamicTextureResolution() {
148
- return this.getIsMobile() || !P.offscreenRenderingSupported() ? {
148
+ return this.getIsMobile() || !x.offscreenRenderingSupported() ? {
149
149
  width: 1024,
150
150
  height: 1024
151
151
  } : {
@@ -181,7 +181,7 @@ class P {
181
181
  }
182
182
  }
183
183
  }
184
- const Ge = 128, h = {
184
+ const Ve = 128, c = {
185
185
  antiAliasing: {
186
186
  samples: 4,
187
187
  fxaaEnabled: !1
@@ -253,11 +253,11 @@ class Ne {
253
253
  return this.loader.loadNodeAsync(
254
254
  e,
255
255
  t,
256
- function(r) {
257
- t.extras && Object.keys(t.extras).forEach((o) => {
258
- const a = t.extras[o];
259
- r.metadata[o] = a;
260
- }), i(r);
256
+ function(s) {
257
+ t.extras && Object.keys(t.extras).forEach((a) => {
258
+ const o = t.extras[a];
259
+ s.metadata[a] = o;
260
+ }), i(s);
261
261
  }
262
262
  );
263
263
  }
@@ -315,55 +315,55 @@ class Ne {
315
315
  * @param scene The scene to parse.
316
316
  */
317
317
  applyReflections(e) {
318
- function t(o) {
319
- const a = [];
320
- return o.transformNodes.forEach((n) => {
321
- n.metadata && n.metadata.reflective && a.push(...n.getChildMeshes());
322
- }), o.meshes.forEach((n) => {
323
- n.metadata && n.metadata.reflective && !a.includes(n) && a.push(n);
324
- }), a;
318
+ function t(a) {
319
+ const o = [];
320
+ return a.transformNodes.forEach((r) => {
321
+ r.metadata && r.metadata.reflective && o.push(...r.getChildMeshes());
322
+ }), a.meshes.forEach((r) => {
323
+ r.metadata && r.metadata.reflective && !o.includes(r) && o.push(r);
324
+ }), o;
325
325
  }
326
- function i(o, a = 1) {
327
- const n = o.material;
328
- if (!n)
326
+ function i(a, o = 1) {
327
+ const r = a.material;
328
+ if (!r)
329
329
  return;
330
330
  const l = new Re(
331
331
  "mirror",
332
- P.getMirrorTextureResolution(),
332
+ x.getMirrorTextureResolution(),
333
333
  e,
334
334
  !0
335
335
  );
336
336
  l.renderList = t(e);
337
- const c = o.getVerticesData("normal");
338
- if (!c)
337
+ const d = a.getVerticesData("normal");
338
+ if (!d)
339
339
  throw new Error(
340
- "Mirror attribute specified on: " + o.name + "But no normals exist to generate a mirror from!"
340
+ "Mirror attribute specified on: " + a.name + "But no normals exist to generate a mirror from!"
341
341
  );
342
- o.computeWorldMatrix(!0);
343
- const d = o.getWorldMatrix(), u = ne.TransformNormal(
344
- new ne(c[0], c[1], c[2]),
345
- d
346
- ).normalize(), g = Ee.FromPositionAndNormal(
347
- o.position,
342
+ a.computeWorldMatrix(!0);
343
+ const h = a.getWorldMatrix(), u = se.TransformNormal(
344
+ new se(d[0], d[1], d[2]),
345
+ h
346
+ ).normalize(), m = Ee.FromPositionAndNormal(
347
+ a.position,
348
348
  u.scale(-1)
349
349
  );
350
- l.mirrorPlane = g, l.level = a, n.reflectionTexture = l;
350
+ l.mirrorPlane = m, l.level = o, r.reflectionTexture = l;
351
351
  }
352
- function r(o) {
353
- const a = o.material, n = new Oe(
354
- "probe-" + a.name,
355
- Ge,
352
+ function s(a) {
353
+ const o = a.material, r = new Oe(
354
+ "probe-" + o.name,
355
+ Ve,
356
356
  e
357
357
  );
358
- n.attachToMesh(o), n.renderList && n.renderList.push(...t(e)), a.reflectionTexture = n.cubeTexture;
358
+ r.attachToMesh(a), r.renderList && r.renderList.push(...t(e)), o.reflectionTexture = r.cubeTexture;
359
359
  }
360
- e.meshes.forEach((o) => {
361
- const a = o.metadata;
362
- a && (a.mirrorTexture && i(o, a.mirrorTexture), a.reflectionProbe && r(o));
360
+ e.meshes.forEach((a) => {
361
+ const o = a.metadata;
362
+ o && (o.mirrorTexture && i(a, o.mirrorTexture), o.reflectionProbe && s(a));
363
363
  });
364
364
  }
365
365
  }
366
- class He {
366
+ class Ge {
367
367
  constructor(e, t) {
368
368
  this.scene = e, this.intensity = t, this.meshCount = 0;
369
369
  }
@@ -386,182 +386,190 @@ class He {
386
386
  }
387
387
  }
388
388
  const le = /* @__PURE__ */ new Map();
389
- async function be(s, e, t) {
390
- const i = le.get(s);
389
+ async function be(n, e, t) {
390
+ const i = le.get(n);
391
391
  if (i && i.scene.uid === e.uid)
392
392
  return i;
393
393
  {
394
- const r = await fe.LoadAssetContainerAsync(
395
- s,
394
+ const s = await fe.LoadAssetContainerAsync(
395
+ n,
396
396
  void 0,
397
397
  e,
398
398
  t
399
399
  );
400
- return le.set(s, r), r;
400
+ return le.set(n, s), s;
401
401
  }
402
402
  }
403
- function qe(s, e, t, i, r = "") {
404
- t.forEach((o) => {
405
- const a = o.getID(), n = o.getName(), l = P.getDynamicTextureResolution();
406
- s.filter((d) => d.name === r + n).forEach((d) => {
407
- const u = i.get(a), g = !1;
403
+ function He(n, e, t, i, s = "") {
404
+ t.forEach((a) => {
405
+ const o = a.getID(), r = a.getName(), l = x.getDynamicTextureResolution();
406
+ n.filter((h) => h.name === s + r).forEach((h) => {
407
+ const u = i.get(o), m = !1;
408
408
  if (u)
409
- he(d, u), u.update(g);
409
+ he(h, u), u.update(m);
410
410
  else {
411
411
  const p = _e(
412
- n,
412
+ r,
413
413
  e,
414
414
  l.width,
415
415
  l.height
416
416
  );
417
- i.set(a, p), o.setStaticContext(
417
+ i.set(o, p), a.setStaticContext(
418
418
  p.getContext()
419
- ), he(d, p), p.onLoadObservable.addOnce(() => {
420
- p.update(g);
419
+ ), he(h, p), p.onLoadObservable.addOnce(() => {
420
+ p.update(m);
421
421
  });
422
422
  }
423
423
  });
424
424
  });
425
425
  }
426
- function _e(s, e, t, i) {
427
- const r = new Fe(
428
- s,
426
+ function _e(n, e, t, i) {
427
+ const s = new Fe(
428
+ n,
429
429
  { width: t, height: i },
430
430
  e,
431
- P.shouldMipMap(),
431
+ x.shouldMipMap(),
432
432
  Be.TRILINEAR_SAMPLINGMODE,
433
433
  pe.TEXTUREFORMAT_RGBA
434
- ), o = r.getContext();
435
- return o && (o.fillStyle = "#f5f5f5", o.fillRect(0, 0, t, i), r.update()), r;
434
+ ), a = s.getContext();
435
+ return a && (a.fillStyle = "#f5f5f5", a.fillRect(0, 0, t, i), s.update()), s;
436
436
  }
437
- function he(s, e) {
438
- if (s instanceof F) {
439
- const t = s, i = t.albedoTexture;
437
+ function he(n, e) {
438
+ if (n instanceof F) {
439
+ const t = n, i = t.albedoTexture;
440
440
  i ? (e.wrapU = i.wrapU, e.wrapV = i.wrapV) : (e.wrapU = 1, e.wrapV = 1), t.albedoTexture = e;
441
441
  } else {
442
- const t = s, i = t.diffuseTexture;
442
+ const t = n, i = t.diffuseTexture;
443
443
  i && (e.wrapU = i.wrapU, e.wrapV = i.wrapV), t.diffuseTexture = e;
444
444
  }
445
445
  }
446
446
  function Ke() {
447
- const s = () => Math.floor((1 + Math.random()) * 65536).toString(16).substring(1);
448
- return s() + s() + "-" + s() + "-" + s() + "-" + s() + "-" + s() + s() + s();
447
+ const n = () => Math.floor((1 + Math.random()) * 65536).toString(16).substring(1);
448
+ return n() + n() + "-" + n() + "-" + n() + "-" + n() + "-" + n() + n() + n();
449
449
  }
450
450
  const M = 60, ce = 1;
451
- function de(s) {
452
- return s.targetedAnimations.map((t) => t.animation.framePerSecond).reduce((t, i) => t + i, 0) / s.targetedAnimations.length || 0;
451
+ function de(n) {
452
+ return n.targetedAnimations.map((t) => t.animation.framePerSecond).reduce((t, i) => t + i, 0) / n.targetedAnimations.length || 0;
453
453
  }
454
- function We(s, e, t, i, r) {
455
- const o = r ? s.filter((a) => a.name === r) : s;
454
+ function We(n, e, t, i, s, a) {
455
+ const o = s ? n.filter((h) => h.name === s) : n;
456
456
  if (o.length === 0) {
457
- console.warn(`No animations found for name: ${r}`);
457
+ console.warn(`No animations found for name: ${s}`);
458
458
  return;
459
459
  }
460
+ let r = 0;
461
+ const l = () => {
462
+ r++, r === o.length && a && a();
463
+ }, d = (h, u, m, p, f) => {
464
+ h.stop(), h.start(u, m, p, f), a && (u == !1 || u === void 0 && !h.loopAnimation ? h.onAnimationGroupEndObservable.addOnce(() => {
465
+ l();
466
+ }) : h.onAnimationLoopObservable.addOnce(() => {
467
+ l();
468
+ }));
469
+ };
460
470
  if (i !== void 0 && t !== void 0 && i === t) {
461
- o.forEach((a) => {
462
- a.stop();
463
- const n = de(a), l = i * n;
464
- a.start(e, ce, l, l);
471
+ o.forEach((h) => {
472
+ const u = de(h), m = i * u;
473
+ d(h, !1, ce, m, m);
465
474
  });
466
475
  return;
467
476
  }
468
- o.forEach((a) => {
469
- a.stop();
470
- const n = de(a), l = i !== void 0 ? i * n : void 0, c = t !== void 0 ? t * n : void 0;
471
- a.start(e, ce, l, c);
477
+ o.forEach((h) => {
478
+ const u = de(h), m = i !== void 0 ? i * u : void 0, p = t !== void 0 ? t * u : void 0;
479
+ d(h, e, ce, m, p);
472
480
  });
473
481
  }
474
- function ve(s) {
475
- s.forEach((e) => {
482
+ function ve(n) {
483
+ n.forEach((e) => {
476
484
  e.stop();
477
485
  });
478
486
  }
479
- function Ue(s) {
480
- const e = s.animationGroups;
487
+ function Ue(n) {
488
+ const e = n.animationGroups;
481
489
  ve(e);
482
490
  }
483
- function Ye(s, e, t) {
491
+ function Ye(n, e, t) {
484
492
  return new Promise((i) => {
485
- s.stopAnimation(e), e.animations = [], Math.abs(e.alpha) > 2 * Math.PI && (e.alpha = Qe(e.alpha, 0, 2 * Math.PI));
486
- const r = [], o = t.target, a = 0, n = o ? 1 : 0;
487
- if (t.target && Object.keys(t.target).length > 0 && r.push(
493
+ n.stopAnimation(e), e.animations = [], Math.abs(e.alpha) > 2 * Math.PI && (e.alpha = Qe(e.alpha, 0, 2 * Math.PI));
494
+ const s = [], a = t.target, o = 0, r = a ? 1 : 0;
495
+ if (t.target && Object.keys(t.target).length > 0 && s.push(
488
496
  A(
489
497
  "cameraTargetLerp",
490
498
  "target",
491
- new m().copyFrom(e.target),
492
- new m(
499
+ new g().copyFrom(e.target),
500
+ new g(
493
501
  t.target.x,
494
502
  t.target.y,
495
503
  t.target.z
496
504
  ),
497
505
  v.ANIMATIONTYPE_VECTOR3,
498
- a
506
+ o
499
507
  )
500
- ), r.push(
508
+ ), s.push(
501
509
  A(
502
510
  "cameraAlphaLerp",
503
511
  "alpha",
504
512
  e.alpha,
505
513
  ue(t.lonDeg),
506
514
  v.ANIMATIONTYPE_FLOAT,
507
- n
515
+ r
508
516
  )
509
- ), r.push(
517
+ ), s.push(
510
518
  A(
511
519
  "cameraBetaLerp",
512
520
  "beta",
513
521
  e.beta,
514
522
  ue(t.latDeg),
515
523
  v.ANIMATIONTYPE_FLOAT,
516
- n
524
+ r
517
525
  )
518
526
  ), t.radius !== void 0) {
519
- const d = Math.max(0.01, t.radius);
520
- r.push(
527
+ const h = Math.max(0.01, t.radius);
528
+ s.push(
521
529
  A(
522
530
  "cameraRadiusLerp",
523
531
  "radius",
524
532
  e.radius,
525
- d,
533
+ h,
526
534
  v.ANIMATIONTYPE_FLOAT,
527
- n
535
+ r
528
536
  )
529
537
  );
530
538
  }
531
- e.animations.push(...r);
532
- const c = e.useAutoRotationBehavior;
533
- e.disableAutoRotationBehavior(), s.beginAnimation(
539
+ e.animations.push(...s);
540
+ const d = e.useAutoRotationBehavior;
541
+ e.disableAutoRotationBehavior(), n.beginAnimation(
534
542
  e,
535
543
  0,
536
- o ? M * 2 : M,
544
+ a ? M * 2 : M,
537
545
  !1,
538
546
  1,
539
547
  () => {
540
- e.animations = [], c && e.enableAutoRotationBehavior(), i();
548
+ e.animations = [], d && e.enableAutoRotationBehavior(), i();
541
549
  }
542
550
  );
543
551
  });
544
552
  }
545
- function ue(s) {
546
- return s * Math.PI / 180;
553
+ function ue(n) {
554
+ return n * Math.PI / 180;
547
555
  }
548
- function A(s, e, t, i, r, o = 0, a = v.ANIMATIONLOOPMODE_CONSTANT) {
549
- const n = new De();
550
- n.setEasingMode(ke.EASINGMODE_EASEINOUT);
556
+ function A(n, e, t, i, s, a = 0, o = v.ANIMATIONLOOPMODE_CONSTANT) {
557
+ const r = new De();
558
+ r.setEasingMode(ke.EASINGMODE_EASEINOUT);
551
559
  const l = new v(
552
- s,
560
+ n,
553
561
  e,
554
562
  M,
555
- r,
556
- a
557
- ), c = [];
558
- return o > 0 && c.push({ frame: 0, value: t }), c.push({ frame: M * o, value: t }), c.push({
559
- frame: M * (o + 1),
563
+ s,
564
+ o
565
+ ), d = [];
566
+ return a > 0 && d.push({ frame: 0, value: t }), d.push({ frame: M * a, value: t }), d.push({
567
+ frame: M * (a + 1),
560
568
  value: i
561
- }), l.setKeys(c), l.setEasingFunction(n), l;
569
+ }), l.setKeys(d), l.setEasingFunction(r), l;
562
570
  }
563
- function Qe(s, e, t) {
564
- return s < e ? s = t - (e - s) % (t - e) : s = e + (s - e) % (t - e);
571
+ function Qe(n, e, t) {
572
+ return n < e ? n = t - (e - n) % (t - e) : n = e + (n - e) % (t - e);
565
573
  }
566
574
  const Ze = {
567
575
  albedoTexture: "albedoMap",
@@ -573,7 +581,7 @@ const Ze = {
573
581
  refractionTexture: "refractionMap",
574
582
  reflectionTexture: "reflectionMap"
575
583
  };
576
- function $e(s, e, t, i) {
584
+ function $e(n, e, t, i) {
577
585
  [
578
586
  "albedoTexture",
579
587
  "bumpTexture",
@@ -583,49 +591,49 @@ function $e(s, e, t, i) {
583
591
  "metallicTexture",
584
592
  "refractionTexture",
585
593
  "reflectionTexture"
586
- ].forEach((o) => {
594
+ ].forEach((a) => {
587
595
  je(
588
- o,
589
- s,
596
+ a,
597
+ n,
590
598
  e,
591
599
  t,
592
600
  i
593
601
  );
594
- }), et(s, e);
602
+ }), et(n, e);
595
603
  }
596
- function je(s, e, t, i, r) {
597
- const o = Ze[s];
598
- if (!o)
604
+ function je(n, e, t, i, s) {
605
+ const a = Ze[n];
606
+ if (!a)
599
607
  throw new Error("Unexpected texture name encountered.");
600
- const a = e[o], n = a == null ? void 0 : a.fileLink;
601
- n ? s === "reflectionTexture" ? n.endsWith(".env") || n.endsWith(".dds") ? i.addCubeTextureTask(
602
- s,
608
+ const o = e[a], r = o == null ? void 0 : o.fileLink;
609
+ r ? n === "reflectionTexture" ? r.endsWith(".env") || r.endsWith(".dds") ? i.addCubeTextureTask(
603
610
  n,
611
+ r,
604
612
  void 0,
605
613
  !1,
606
614
  void 0,
607
615
  !0
608
- ) : n.endsWith(".hdr") ? i.addHDRCubeTextureTask(
609
- s,
616
+ ) : r.endsWith(".hdr") ? i.addHDRCubeTextureTask(
610
617
  n,
618
+ r,
611
619
  128,
612
620
  !1,
613
621
  !0,
614
622
  !1
615
- ) : i.addTextureTask(s, n, !1, !1) : i.addTextureTask(s, n, !1, !1) : r && t[s] && (t[s] && t[s].dispose(), t[s] = null, Xe(s, t));
623
+ ) : i.addTextureTask(n, r, !1, !1) : i.addTextureTask(n, r, !1, !1) : s && t[n] && (t[n] && t[n].dispose(), t[n] = null, Xe(n, t));
616
624
  }
617
- function Xe(s, e) {
618
- s === "opacityTexture" && (e.useAlphaFromAlbedoTexture = !0), s === "metallicTexture" && (e.useRoughnessFromMetallicTextureAlpha = !1, e.useRoughnessFromMetallicTextureGreen = !1, e.useMetallnessFromMetallicTextureBlue = !1), s === "refractionTexture" && (e.subSurface.isRefractionEnabled = !1, e.subSurface.refractionIntensity = 1), s === "reflectionTexture" && (e.environmentIntensity = 1), s === "emissiveTexture" && (e.emissiveIntensity = 0, e.emissiveColor = new w(0, 0, 0), e.reflectionTexture);
625
+ function Xe(n, e) {
626
+ n === "opacityTexture" && (e.useAlphaFromAlbedoTexture = !0), n === "metallicTexture" && (e.useRoughnessFromMetallicTextureAlpha = !1, e.useRoughnessFromMetallicTextureGreen = !1, e.useMetallnessFromMetallicTextureBlue = !1), n === "refractionTexture" && (e.subSurface.isRefractionEnabled = !1, e.subSurface.refractionIntensity = 1), n === "reflectionTexture" && (e.environmentIntensity = 1), n === "emissiveTexture" && (e.emissiveIntensity = 0, e.emissiveColor = new w(0, 0, 0), e.reflectionTexture);
619
627
  }
620
- function Je(s, e, t, i) {
628
+ function Je(n, e, t, i) {
621
629
  if (!e) {
622
630
  console.error("Failed to apply texture to material: material is null.");
623
631
  return;
624
632
  }
625
- s === "opacityTexture" && (e.useAlphaFromAlbedoTexture = !1), s === "metallicTexture" && (e.useRoughnessFromMetallicTextureAlpha = !1, e.useRoughnessFromMetallicTextureGreen = !0, e.useMetallnessFromMetallicTextureBlue = !0), s === "refractionTexture" && (e.subSurface.isRefractionEnabled = !0, e.subSurface.refractionIntensity = t.refractionIntensity || 1), s === "reflectionTexture" && (e.environmentIntensity = t.reflectionIntensity || 1, i.isCube && (i.rotationY = t.reflectionRotation ? t.reflectionRotation * Math.PI / 180 : 0)), e[s] = i, s === "emissiveTexture" && (e.emissiveColor = new w(1, 1, 1), e.emissiveIntensity = 1);
633
+ n === "opacityTexture" && (e.useAlphaFromAlbedoTexture = !1), n === "metallicTexture" && (e.useRoughnessFromMetallicTextureAlpha = !1, e.useRoughnessFromMetallicTextureGreen = !0, e.useMetallnessFromMetallicTextureBlue = !0), n === "refractionTexture" && (e.subSurface.isRefractionEnabled = !0, e.subSurface.refractionIntensity = t.refractionIntensity || 1), n === "reflectionTexture" && (e.environmentIntensity = t.reflectionIntensity || 1, i.isCube && (i.rotationY = t.reflectionRotation ? t.reflectionRotation * Math.PI / 180 : 0)), e[n] = i, n === "emissiveTexture" && (e.emissiveColor = new w(1, 1, 1), e.emissiveIntensity = 1);
626
634
  }
627
- function et(s, e) {
628
- s.clearCoat && (s.clearCoat === S.RemoveWhenSelected ? (e.clearCoat.isEnabled = !1, e.clearCoat.indexOfRefraction = 1.5) : s.clearCoat === S.ApplyWhenSelected && (e.clearCoat.isEnabled = !0, e.clearCoat.indexOfRefraction = s.clearCoatIOR || e.clearCoat.indexOfRefraction));
635
+ function et(n, e) {
636
+ n.clearCoat && (n.clearCoat === S.RemoveWhenSelected ? (e.clearCoat.isEnabled = !1, e.clearCoat.indexOfRefraction = 1.5) : n.clearCoat === S.ApplyWhenSelected && (e.clearCoat.isEnabled = !0, e.clearCoat.indexOfRefraction = n.clearCoatIOR || e.clearCoat.indexOfRefraction));
629
637
  }
630
638
  class tt {
631
639
  constructor(e, t, i) {
@@ -640,45 +648,45 @@ class tt {
640
648
  * instead remove material textures when they aren't defined. this is useful for material editor applications
641
649
  * where we want to undo changes are remove effects from display.
642
650
  */
643
- async applyMaterial(e, t, i, r) {
644
- return new Promise((o) => {
645
- const a = this.materialVariantMap.get(e);
651
+ async applyMaterial(e, t, i, s) {
652
+ return new Promise((a) => {
653
+ const o = this.materialVariantMap.get(e);
646
654
  this.materialVariantMap.set(e, {
647
- ...a,
655
+ ...o,
648
656
  ...t
649
657
  });
650
- const n = this.renameClonedAsset(e), l = this.scene.materials.filter(
651
- (d) => d.name === n
658
+ const r = this.renameClonedAsset(e), l = this.scene.materials.filter(
659
+ (h) => h.name === r
652
660
  );
653
661
  if (l.length === 0) {
654
- o();
662
+ a();
655
663
  return;
656
664
  }
657
- const c = new ze(this.scene);
658
- c.useDefaultLoadingScreen = !1, l.forEach(
659
- (d) => $e(
665
+ const d = new qe(this.scene);
666
+ d.useDefaultLoadingScreen = !1, l.forEach(
667
+ (h) => $e(
660
668
  t,
669
+ h,
661
670
  d,
662
- c,
663
- r
671
+ s
664
672
  )
665
- ), c.onProgress = (d, u, g) => {
666
- i && i(d / u * 100, 100, g.name);
667
- }, c.onFinish = (d) => {
668
- d.forEach((u) => {
669
- const g = u;
673
+ ), d.onProgress = (h, u, m) => {
674
+ i && i(h / u * 100, 100, m.name);
675
+ }, d.onFinish = (h) => {
676
+ h.forEach((u) => {
677
+ const m = u;
670
678
  i && i(100, 100, u.name), this.scene.materials.filter(
671
- (b) => b.name === n
679
+ (f) => f.name === r
672
680
  ).forEach(
673
- (b) => Je(
681
+ (f) => Je(
674
682
  u.name,
675
- b,
683
+ f,
676
684
  t,
677
- g.texture
685
+ m.texture
678
686
  )
679
687
  );
680
- }), o();
681
- }, c.loadAsync();
688
+ }), a();
689
+ }, d.loadAsync();
682
690
  });
683
691
  }
684
692
  /**
@@ -688,21 +696,21 @@ class tt {
688
696
  * @param model The details for the new model, when undefined we should remove the variant associated to the given key.
689
697
  * @param onProgress A load progress callback that can be used for loading bars and event timing.
690
698
  */
691
- async applyModel(e, t, i, r) {
692
- var l, c;
699
+ async applyModel(e, t, i, s) {
700
+ var l, d;
693
701
  if (i && t && !this.keysThatRemovedBaseModel.includes(e) && this.keysThatRemovedBaseModel.push(e), !i)
694
702
  return this.keysThatRemovedBaseModel.includes(e) && this.keysThatRemovedBaseModel.length === 1 && await this.setBaseModelEnabled(!0), (l = this.loadedContainerForKey.get(e)) == null || l.dispose(), this.loadedContainerForKey.delete(e), this.loadedMaterialsForKey.delete(e), this.keysThatRemovedBaseModel = this.keysThatRemovedBaseModel.filter(
695
- (d) => d !== e
703
+ (h) => h !== e
696
704
  ), Promise.resolve(void 0);
697
- const a = (await be(i, this.scene, r)).instantiateModelsToScene(
705
+ const o = (await be(i, this.scene, s)).instantiateModelsToScene(
698
706
  this.renameClonedAsset,
699
707
  !0
700
708
  );
701
- this.loadedContainerForKey.has(e) && ((c = this.loadedContainerForKey.get(e)) == null || c.dispose(), this.loadedContainerForKey.delete(e), this.loadedMaterialsForKey.delete(e)), t && await this.setBaseModelEnabled(!1), this.loadedContainerForKey.set(e, a), this.loadedMaterialsForKey.set(e, we(a));
702
- const n = [];
703
- return this.materialVariantMap.forEach(async (d, u) => {
704
- n.push(this.applyMaterial(u, d));
705
- }), await Promise.all(n), a;
709
+ this.loadedContainerForKey.has(e) && ((d = this.loadedContainerForKey.get(e)) == null || d.dispose(), this.loadedContainerForKey.delete(e), this.loadedMaterialsForKey.delete(e)), t && await this.setBaseModelEnabled(!1), this.loadedContainerForKey.set(e, o), this.loadedMaterialsForKey.set(e, we(o));
710
+ const r = [];
711
+ return this.materialVariantMap.forEach(async (h, u) => {
712
+ r.push(this.applyMaterial(u, h));
713
+ }), await Promise.all(r), o;
706
714
  }
707
715
  dispose() {
708
716
  this.loadedContainerForKey.forEach((e) => e == null ? void 0 : e.dispose()), this.loadedContainerForKey.clear(), this.loadedMaterialsForKey.forEach(
@@ -724,19 +732,19 @@ class tt {
724
732
  }), e;
725
733
  }
726
734
  }
727
- function we(s) {
735
+ function we(n) {
728
736
  const e = [];
729
- return s.rootNodes.forEach((t) => {
737
+ return n.rootNodes.forEach((t) => {
730
738
  t.getChildMeshes().forEach((i) => {
731
- i.material && !e.includes(i.material) && e.push(i.material), i.subMeshes && i.subMeshes.forEach((r) => {
732
- const o = r.getMaterial(!1);
733
- o && !e.includes(o) && e.push(o);
739
+ i.material && !e.includes(i.material) && e.push(i.material), i.subMeshes && i.subMeshes.forEach((s) => {
740
+ const a = s.getMaterial(!1);
741
+ a && !e.includes(a) && e.push(a);
734
742
  });
735
743
  });
736
744
  }), e;
737
745
  }
738
- function me(s, e = "") {
739
- return s.map((t) => ({
746
+ function me(n, e = "") {
747
+ return n.map((t) => ({
740
748
  name: t.name.substring(e.length),
741
749
  loop: t.loopAnimation,
742
750
  to: t.to,
@@ -745,45 +753,45 @@ function me(s, e = "") {
745
753
  }
746
754
  class it {
747
755
  constructor(e) {
748
- this.metadata = /* @__PURE__ */ new Map(), this.materialSelectedObservable = new C(), this.materialDeselectedObservable = new C(), this.materialVariantObservable = new C(), this.modelVariantObservable = new C(), this.materialReadyToLoadCallbacks = /* @__PURE__ */ new Map(), this.modelReadyToLoadCallbacks = /* @__PURE__ */ new Map(), this.dynamicTextures = /* @__PURE__ */ new Map(), this.queuedMaterialChanges = /* @__PURE__ */ new Map(), this.materialChangesInProgress = [], this.queuedModelChanges = /* @__PURE__ */ new Map(), this.modelChangesInProgress = [], this.animations = [], this.initialized = !1, this.materials = [];
756
+ this.metadata = /* @__PURE__ */ new Map(), this.materialSelectedObservable = new C(), this.materialDeselectedObservable = new C(), this.materialVariantObservable = new C(), this.modelVariantObservable = new C(), this.materialReadyToLoadCallbacks = /* @__PURE__ */ new Map(), this.modelReadyToLoadCallbacks = /* @__PURE__ */ new Map(), this.dynamicTextures = /* @__PURE__ */ new Map(), this.queuedMaterialChanges = /* @__PURE__ */ new Map(), this.materialChangesInProgress = [], this.queuedModelChanges = /* @__PURE__ */ new Map(), this.modelChangesInProgress = [], this.isExecutingAnimation = !1, this.animations = [], this.initialized = !1, this.materials = [];
749
757
  const {
750
758
  enablePicking: t,
751
759
  modelDetails: i,
752
- previewService: r,
753
- progressHandler: o,
754
- scene: a
760
+ previewService: s,
761
+ progressHandler: a,
762
+ scene: o
755
763
  } = e;
756
- this.enablePicking = t, this.contextService = i.contextService, this.id = Ke(), this.previewService = r, this.scene = a, this.variantManager = new tt(
757
- a,
764
+ this.enablePicking = t, this.contextService = i.contextService, this.id = Ke(), this.previewService = s, this.scene = o, this.variantManager = new tt(
765
+ o,
758
766
  this.renameClonedAsset.bind(this),
759
767
  this.setBaseModelEnabled.bind(this)
760
768
  ), this.transformRoot = new Se("root", this.scene);
761
- const n = async () => {
769
+ const r = async () => {
762
770
  if (!i.model)
763
771
  throw new Error(
764
772
  "Model container constructed with no URL. This is currently unsupported."
765
773
  );
766
774
  return this.assetContainer = await be(
767
775
  i.model,
768
- a,
769
- o
776
+ o,
777
+ a
770
778
  ), this.initialized = !0, await this.instantiate(), this;
771
779
  };
772
- this.importPromise = n();
780
+ this.importPromise = r();
773
781
  }
774
782
  //#region Interface implementation
775
- async applyMaterialVariant(e, t, i, r) {
783
+ async applyMaterialVariant(e, t, i, s) {
776
784
  if (!this.initialized) {
777
785
  if (this.materialReadyToLoadCallbacks.has(e)) {
778
- const a = this.materialReadyToLoadCallbacks.get(e);
779
- a == null || a.set(
786
+ const o = this.materialReadyToLoadCallbacks.get(e);
787
+ o == null || o.set(
780
788
  t,
781
789
  this.applyMaterialVariant.bind(
782
790
  this,
783
791
  e,
784
792
  t,
785
793
  i,
786
- r
794
+ s
787
795
  )
788
796
  );
789
797
  } else {
@@ -791,54 +799,54 @@ class it {
791
799
  e,
792
800
  /* @__PURE__ */ new Map()
793
801
  );
794
- const a = this.materialReadyToLoadCallbacks.get(e);
795
- a == null || a.set(
802
+ const o = this.materialReadyToLoadCallbacks.get(e);
803
+ o == null || o.set(
796
804
  t,
797
805
  this.applyMaterialVariant.bind(
798
806
  this,
799
807
  e,
800
808
  t,
801
809
  i,
802
- r
810
+ s
803
811
  )
804
812
  );
805
813
  }
806
814
  return;
807
815
  }
808
- const o = async () => {
816
+ const a = async () => {
809
817
  await this.variantManager.applyMaterial(
810
818
  e,
811
819
  i,
812
- (a, n, l) => {
820
+ (o, r, l) => {
813
821
  this.materialVariantObservable.notifyObservers({
814
- remainingCount: a,
815
- totalCount: n,
822
+ remainingCount: o,
823
+ totalCount: r,
816
824
  taskName: l
817
825
  });
818
826
  },
819
- r
827
+ s
820
828
  );
821
829
  };
822
830
  if (this.materialChangesInProgress.includes(e)) {
823
831
  if (this.queuedMaterialChanges.has(e)) {
824
- const a = this.queuedMaterialChanges.get(e);
825
- a == null || a.set(t, o);
832
+ const o = this.queuedMaterialChanges.get(e);
833
+ o == null || o.set(t, a);
826
834
  } else {
827
835
  this.queuedMaterialChanges.set(
828
836
  e,
829
837
  /* @__PURE__ */ new Map()
830
838
  );
831
- const a = this.queuedMaterialChanges.get(e);
832
- a == null || a.set(t, o);
839
+ const o = this.queuedMaterialChanges.get(e);
840
+ o == null || o.set(t, a);
833
841
  }
834
842
  return;
835
843
  }
836
- if (this.materialChangesInProgress.push(e), await o(), this.queuedMaterialChanges.has(e)) {
837
- const a = this.queuedMaterialChanges.get(e);
838
- if (!a)
844
+ if (this.materialChangesInProgress.push(e), await a(), this.queuedMaterialChanges.has(e)) {
845
+ const o = this.queuedMaterialChanges.get(e);
846
+ if (!o)
839
847
  throw new Error("Target material is undefined");
840
- a.forEach(async (n) => {
841
- await n();
848
+ o.forEach(async (r) => {
849
+ await r();
842
850
  }), this.queuedMaterialChanges.delete(e);
843
851
  }
844
852
  this.materialChangesInProgress.splice(
@@ -859,56 +867,66 @@ class it {
859
867
  );
860
868
  return;
861
869
  }
862
- const r = () => this.variantManager.applyModel(
870
+ const s = () => this.variantManager.applyModel(
863
871
  e,
864
872
  i,
865
873
  t == null ? void 0 : t.model,
866
- (n) => {
874
+ (r) => {
867
875
  this.modelVariantObservable.notifyObservers({
868
- ...n,
876
+ ...r,
869
877
  key: e
870
878
  });
871
879
  }
872
880
  );
873
881
  if (this.modelChangesInProgress.includes(e)) {
874
- this.queuedModelChanges.set(e, r);
882
+ this.queuedModelChanges.set(e, s);
875
883
  return;
876
884
  }
877
- const a = await (async () => {
885
+ const o = await (async () => {
878
886
  this.modelChangesInProgress.push(e);
879
- let n = await r();
887
+ let r = await s();
880
888
  if (this.queuedModelChanges.has(e)) {
881
889
  const l = this.queuedModelChanges.get(e);
882
890
  if (!l)
883
891
  throw new Error("Queued change resolved undefined");
884
- n = await l(), this.queuedModelChanges.delete(e);
892
+ r = await l(), this.queuedModelChanges.delete(e);
885
893
  }
886
894
  return this.modelChangesInProgress.splice(
887
895
  this.modelChangesInProgress.indexOf(e),
888
896
  1
889
- ), n;
897
+ ), r;
890
898
  })();
891
- this.modelInstance && ve(this.modelInstance.animationGroups), this.contextService || (this.contextService = t == null ? void 0 : t.contextService), a ? this.configureModelInstance(a) : this.configureGlowLayer();
899
+ this.modelInstance && ve(this.modelInstance.animationGroups), this.contextService || (this.contextService = t == null ? void 0 : t.contextService), o ? this.configureModelInstance(o) : this.configureGlowLayer();
892
900
  }
893
901
  dispose() {
894
902
  var e;
895
903
  this.destroyInstance(), this.variantManager.dispose(), this.dynamicTextures.forEach((t) => t == null ? void 0 : t.dispose()), this.dynamicTextures.clear(), this.materials.forEach((t) => t && (t == null ? void 0 : t.dispose())), this.materials = [], (e = this.transformRoot) == null || e.dispose(), this.transformRoot = void 0, this.previewService.modelUnloaded(this);
896
904
  }
897
905
  executeAnimation(e) {
898
- if (!this.previewService.getInitializationComplete()) {
899
- this.queuedModelAnimation = e;
900
- return;
901
- }
902
- this.modelInstance && We(
903
- [
904
- ...this.modelInstance.animationGroups,
905
- ...this.variantManager.getAnimationGroups()
906
- ],
907
- e.loop,
908
- e.to,
909
- e.from,
910
- e.name ? this.renameClonedAsset(e.name) : void 0
911
- );
906
+ if (!this.previewService.getInitializationComplete())
907
+ return this.queuedModelAnimation = e, Promise.resolve();
908
+ if (!this.modelInstance)
909
+ return Promise.resolve();
910
+ let t = () => {
911
+ };
912
+ const i = async () => {
913
+ this.isExecutingAnimation = !0, await new Promise((s) => {
914
+ We(
915
+ [
916
+ ...this.modelInstance.animationGroups,
917
+ ...this.variantManager.getAnimationGroups()
918
+ ],
919
+ e.loop,
920
+ e.to,
921
+ e.from,
922
+ e.name ? this.renameClonedAsset(e.name) : void 0,
923
+ s
924
+ );
925
+ }), this.isExecutingAnimation = !1, this.queuedAnimationFunction && this.queuedAnimationFunction(), this.queuedAnimationFunction = void 0, t();
926
+ };
927
+ return this.isExecutingAnimation ? (this.queuedAnimationFunction = i, new Promise((s) => {
928
+ t = s;
929
+ })) : i();
912
930
  }
913
931
  getAnimations(e) {
914
932
  return [
@@ -952,7 +970,7 @@ class it {
952
970
  set position(e) {
953
971
  if (!this.transformRoot)
954
972
  throw new Error("ModelContainer disposed prior to setting position!");
955
- this.transformRoot.position = new m(e.x, e.y, e.z);
973
+ this.transformRoot.position = new g(e.x, e.y, e.z);
956
974
  }
957
975
  get rotation() {
958
976
  var e;
@@ -977,7 +995,7 @@ class it {
977
995
  set scale(e) {
978
996
  if (!this.transformRoot)
979
997
  throw new Error("ModelContainer disposed prior to setting scale!");
980
- this.transformRoot.scaling = new m(e.x, e.y, e.z);
998
+ this.transformRoot.scaling = new g(e.x, e.y, e.z);
981
999
  }
982
1000
  //#endregion
983
1001
  //#region Custom implementation functions
@@ -985,8 +1003,8 @@ class it {
985
1003
  e.rootNodes.forEach((t) => {
986
1004
  t.getChildMeshes(!1).forEach((i) => {
987
1005
  i.name === "targetcube_t" || i.name === "backgroundShell" || (i.actionManager || (i.actionManager = new R(this.scene)), i.actionManager.registerAction(
988
- new re(R.OnPointerOverTrigger, (r) => {
989
- r.meshUnderPointer && i.material && this.materialSelectedObservable.notifyObservers({
1006
+ new re(R.OnPointerOverTrigger, (s) => {
1007
+ s.meshUnderPointer && i.material && this.materialSelectedObservable.notifyObservers({
990
1008
  id: i.material.id,
991
1009
  name: this.stripIdFromName(i.material.name)
992
1010
  });
@@ -1025,16 +1043,16 @@ class it {
1025
1043
  this.materials.some(e) || this.variantManager.getAllMaterials().some(e) ? this.previewService.getGlowLayerManager().includeMeshes(this.getAllMeshes()) : this.previewService.getGlowLayerManager().removeMeshes(this.getAllMeshes());
1026
1044
  }
1027
1045
  configureModelInstance(e) {
1028
- var o;
1046
+ var a;
1029
1047
  if (!this.transformRoot)
1030
1048
  throw new Error(
1031
1049
  "Transform disposed! This should never happen unless there is a race condition present!"
1032
1050
  );
1033
- const t = this.transformRoot.position, i = this.transformRoot.rotationQuaternion, r = this.transformRoot.scaling;
1034
- this.transformRoot.position = m.Zero(), this.transformRoot.rotationQuaternion = y.Identity(), this.transformRoot.scaling = m.One();
1035
- for (const a of e.rootNodes)
1036
- a.parent = this.transformRoot;
1037
- this.transformRoot.position = t, this.transformRoot.rotationQuaternion = i, this.transformRoot.scaling = r, this.canvasPanels = ((o = this.contextService) == null ? void 0 : o.getAll()) || /* @__PURE__ */ new Map(), qe(
1051
+ const t = this.transformRoot.position, i = this.transformRoot.rotationQuaternion, s = this.transformRoot.scaling;
1052
+ this.transformRoot.position = g.Zero(), this.transformRoot.rotationQuaternion = y.Identity(), this.transformRoot.scaling = g.One();
1053
+ for (const o of e.rootNodes)
1054
+ o.parent = this.transformRoot;
1055
+ this.transformRoot.position = t, this.transformRoot.rotationQuaternion = i, this.transformRoot.scaling = s, this.canvasPanels = ((a = this.contextService) == null ? void 0 : a.getAll()) || /* @__PURE__ */ new Map(), He(
1038
1056
  this.materials.concat(this.variantManager.getAllMaterials()),
1039
1057
  this.scene,
1040
1058
  this.canvasPanels,
@@ -1078,8 +1096,8 @@ class it {
1078
1096
  var e;
1079
1097
  (e = this.canvasPanels) == null || e.forEach(
1080
1098
  (t, i) => {
1081
- const r = this.dynamicTextures.get(i);
1082
- r && t.getStaticContextDirty() && r.isReady() && (r.update(!1), t.setStaticContextDirty(!1));
1099
+ const s = this.dynamicTextures.get(i);
1100
+ s && t.getStaticContextDirty() && s.isReady() && (s.update(!1), t.setStaticContextDirty(!1));
1083
1101
  }
1084
1102
  );
1085
1103
  }
@@ -1109,22 +1127,25 @@ class it {
1109
1127
  Array.from(this.modelReadyToLoadCallbacks.values()).map(
1110
1128
  (e) => e()
1111
1129
  )
1112
- ), this.modelReadyToLoadCallbacks.clear(), this.queuedModelAnimation && (this.executeAnimation(this.queuedModelAnimation), this.queuedModelAnimation = void 0);
1130
+ ), this.modelReadyToLoadCallbacks.clear(), console.log(
1131
+ "ModelContainer ready, executing queued animation",
1132
+ this.queuedModelAnimation
1133
+ ), this.queuedModelAnimation && (this.executeAnimation(this.queuedModelAnimation), this.queuedModelAnimation = void 0);
1113
1134
  }
1114
1135
  //#endregion
1115
1136
  }
1116
1137
  class B extends ge {
1117
- constructor(e, t, i, r, o, a, n, l) {
1138
+ constructor(e, t, i, s, a, o, r, l) {
1118
1139
  super(
1119
1140
  e,
1120
1141
  t,
1121
1142
  i,
1122
- r,
1123
- o,
1143
+ s,
1124
1144
  a,
1145
+ o,
1125
1146
  l
1126
- ), this.lastFocus = new m(0, 0, 0), this.panDenominator = 1, this.minZ = 0.01, this.setRadius(this.radius), this.enableFramingBehavior(), this.wheelDeltaPercentage = 0.01, this.pinchDeltaPercentage = 5e-3, this.useNaturalPinchZoom = !0, n.camera.autoOrientation && (this.alpha += Math.PI), n && (n.camera.limits.min.beta && (this.lowerBetaLimit = n.camera.limits.min.beta), n.camera.limits.max.beta && (this.upperBetaLimit = n.camera.limits.max.beta), n.camera.limits.min.alpha && (this.lowerAlphaLimit = n.camera.limits.min.alpha), n.camera.limits.max.alpha && (this.upperAlphaLimit = n.camera.limits.max.alpha), n.camera.limits.min.radius && (this.lowerRadiusLimit = n.camera.limits.min.radius), n.camera.limits.max.radius && (this.upperRadiusLimit = n.camera.limits.max.radius), n.camera.autoRotation.enabled && this.enableAutoRotationBehavior(
1127
- n.camera.autoRotation.idleTimeMs
1147
+ ), this.lastFocus = new g(0, 0, 0), this.panDenominator = 1, this.minZ = 0.01, this.updateRadiusBounds(this.radius), this.enableFramingBehavior(), this.wheelDeltaPercentage = 0.01, this.pinchDeltaPercentage = 5e-3, this.useNaturalPinchZoom = !0, r.camera.autoOrientation && (this.alpha += Math.PI), r && (r.camera.limits.min.beta && (this.lowerBetaLimit = r.camera.limits.min.beta), r.camera.limits.max.beta && (this.upperBetaLimit = r.camera.limits.max.beta), r.camera.limits.min.alpha && (this.lowerAlphaLimit = r.camera.limits.min.alpha), r.camera.limits.max.alpha && (this.upperAlphaLimit = r.camera.limits.max.alpha), r.camera.limits.min.radius && (this.lowerRadiusLimit = r.camera.limits.min.radius), r.camera.limits.max.radius && (this.upperRadiusLimit = r.camera.limits.max.radius), r.camera.autoRotation.enabled && this.enableAutoRotationBehavior(
1148
+ r.camera.autoRotation.idleTimeMs
1128
1149
  ));
1129
1150
  }
1130
1151
  /**
@@ -1161,14 +1182,14 @@ class B extends ge {
1161
1182
  rerunFramingBehavior(e, t) {
1162
1183
  const i = this.getFramingBehavior();
1163
1184
  i.framingTime = t || 800;
1164
- const r = () => {
1185
+ const s = () => {
1165
1186
  e && e();
1166
- }, o = E(this._scene), a = o.max.subtract(o.min), n = o.min.add(a.scale(0.5));
1167
- this.setRadius(a.length() * 1.5), this.wheelPrecision = 100 / this.radius, this.panningInertia = 0, this.panningOriginTarget.copyFrom(n), this.panDenominator = a.length(), i.zoomOnBoundingInfo(
1168
- o.min,
1169
- o.max,
1187
+ }, a = E(this._scene), o = a.max.subtract(a.min), r = a.min.add(o.scale(0.5));
1188
+ this.updateRadiusBounds(o.length() * 1.5), this.wheelPrecision = 100 / this.radius, this.panningInertia = 0, this.panningOriginTarget.copyFrom(r), this.panDenominator = o.length(), i.zoomOnBoundingInfo(
1189
+ a.min,
1190
+ a.max,
1170
1191
  void 0,
1171
- r
1192
+ s
1172
1193
  ), i.framingTime = 0;
1173
1194
  }
1174
1195
  /**
@@ -1187,8 +1208,8 @@ class B extends ge {
1187
1208
  disableAutoRotationBehavior() {
1188
1209
  this.useAutoRotationBehavior = !1;
1189
1210
  }
1190
- setRadius(e) {
1191
- this.radius = e, this.maxZ = this.radius * 1e3, this.lowerRadiusLimit = this.radius * 0.01, this.upperRadiusLimit = 1.5 * this.radius, this.wheelPrecision = 100 / this.radius, this.pinchPrecision = 300 / this.radius;
1211
+ updateRadiusBounds(e) {
1212
+ this.maxZ = e * 1e3, this.lowerRadiusLimit = e * 0.01, this.upperRadiusLimit = 1.5 * e, this.wheelPrecision = 100 / e, this.pinchPrecision = 300 / e;
1192
1213
  }
1193
1214
  /**
1194
1215
  * A static function used to instantiate a single product camera instance on a scene. This camera will assume
@@ -1198,39 +1219,39 @@ class B extends ge {
1198
1219
  * @param assignActive If true the camera will be assigned as the active camera on the scene.
1199
1220
  */
1200
1221
  static create(e, t, i) {
1201
- const r = E(e), o = r.max.subtract(r.min), a = r.min.add(o.scale(0.5)), n = new B(
1222
+ const s = E(e), a = s.max.subtract(s.min), o = s.min.add(a.scale(0.5)), r = new B(
1202
1223
  "ProductCamera",
1203
1224
  -(Math.PI / 2),
1204
1225
  Math.PI / 2,
1205
- o.length() * 1.5,
1206
- a,
1226
+ a.length() * 1.5,
1227
+ o,
1207
1228
  e,
1208
1229
  t
1209
1230
  );
1210
- return n.panningInertia = 0, n.panningOriginTarget.copyFrom(a), n.panDenominator = o.length(), n.onAfterCheckInputsObservable.add(() => {
1211
- n.panningSensibility = 1e3 / n.panDenominator;
1212
- }), i && (e.activeCamera = n), n;
1231
+ return r.panningInertia = 0, r.panningOriginTarget.copyFrom(o), r.panDenominator = a.length(), r.onAfterCheckInputsObservable.add(() => {
1232
+ r.panningSensibility = 1e3 / r.panDenominator;
1233
+ }), i && (e.activeCamera = r), r;
1213
1234
  }
1214
1235
  }
1215
- function E(s) {
1216
- if (s.meshes.length === 0)
1236
+ function E(n) {
1237
+ if (n.meshes.length === 0)
1217
1238
  return {
1218
- min: new m(-1, -1, -1),
1219
- max: new m(1, 1, 1)
1239
+ min: new g(-1, -1, -1),
1240
+ max: new g(1, 1, 1)
1220
1241
  };
1221
- const e = s.meshes.filter((t) => t.name.toLowerCase().endsWith("_t") || t.name.toLowerCase().includes("_t_"));
1222
- return s.getWorldExtends((t) => t.isVisible && t.isEnabled() && (e.length === 0 || e.includes(t)));
1242
+ const e = n.meshes.filter((t) => t.name.toLowerCase().endsWith("_t") || t.name.toLowerCase().includes("_t_"));
1243
+ return n.getWorldExtends((t) => t.isVisible && t.isEnabled() && (e.length === 0 || e.includes(t)));
1223
1244
  }
1224
- class st {
1245
+ class nt {
1225
1246
  constructor(e, t = !1, i = void 0) {
1226
- this.renderingPipeline = new Ve(
1247
+ this.renderingPipeline = new ze(
1227
1248
  "default",
1228
1249
  t,
1229
1250
  e,
1230
1251
  i ? [i] : void 0,
1231
1252
  !1
1232
1253
  // Disable automatic build
1233
- ), this.renderingPipeline.isSupported && (this.renderingPipeline.prepare(), this.setConfiguration(h));
1254
+ ), this.renderingPipeline.isSupported && (this.renderingPipeline.prepare(), this.setConfiguration(c));
1234
1255
  }
1235
1256
  dispose() {
1236
1257
  this.renderingPipeline.dispose();
@@ -1239,16 +1260,16 @@ class st {
1239
1260
  return this.currentConfiguration;
1240
1261
  }
1241
1262
  setConfiguration(e) {
1242
- var t, i, r, o, a, n, l, c, d, u, g, p, b, D, k, z, V, G, N, H, q, _, K, W, U, Y, Q, Z, $, j, X, J, ee;
1263
+ var t, i, s, a, o, r, l, d, h, u, m, p, f, D, k, q, z, V, N, G, H, _, K, W, U, Y, Q, Z, $, j, X, J, ee;
1243
1264
  if (this.renderingPipeline.isSupported) {
1244
- if (this.renderingPipeline.samples = ((t = e.antiAliasing) == null ? void 0 : t.samples) ?? h.antiAliasing.samples, this.renderingPipeline.fxaaEnabled = ((i = e.antiAliasing) == null ? void 0 : i.fxaaEnabled) ?? h.antiAliasing.fxaaEnabled, this.renderingPipeline.bloomEnabled = ((r = e.bloom) == null ? void 0 : r.enabled) ?? h.bloom.enabled, this.renderingPipeline.bloomKernel = ((o = e.bloom) == null ? void 0 : o.kernel) ?? h.bloom.kernel, this.renderingPipeline.bloomScale = ((a = e.bloom) == null ? void 0 : a.scale) ?? h.bloom.scale, this.renderingPipeline.bloomThreshold = ((n = e.bloom) == null ? void 0 : n.threshold) ?? h.bloom.threshold, this.renderingPipeline.bloomWeight = ((l = e.bloom) == null ? void 0 : l.weight) ?? h.bloom.weight, this.renderingPipeline.chromaticAberrationEnabled = ((c = e.chromaticAberration) == null ? void 0 : c.enabled) ?? h.chromaticAberration.enabled, this.renderingPipeline.chromaticAberration.aberrationAmount = ((d = e.chromaticAberration) == null ? void 0 : d.aberrationAmount) ?? h.chromaticAberration.aberrationAmount, this.renderingPipeline.chromaticAberration.radialIntensity = ((u = e.chromaticAberration) == null ? void 0 : u.radialIntensity) ?? h.chromaticAberration.radialIntensity, this.renderingPipeline.chromaticAberration.direction = (g = e.chromaticAberration) != null && g.direction ? new ie(
1265
+ if (this.renderingPipeline.samples = ((t = e.antiAliasing) == null ? void 0 : t.samples) ?? c.antiAliasing.samples, this.renderingPipeline.fxaaEnabled = ((i = e.antiAliasing) == null ? void 0 : i.fxaaEnabled) ?? c.antiAliasing.fxaaEnabled, this.renderingPipeline.bloomEnabled = ((s = e.bloom) == null ? void 0 : s.enabled) ?? c.bloom.enabled, this.renderingPipeline.bloomKernel = ((a = e.bloom) == null ? void 0 : a.kernel) ?? c.bloom.kernel, this.renderingPipeline.bloomScale = ((o = e.bloom) == null ? void 0 : o.scale) ?? c.bloom.scale, this.renderingPipeline.bloomThreshold = ((r = e.bloom) == null ? void 0 : r.threshold) ?? c.bloom.threshold, this.renderingPipeline.bloomWeight = ((l = e.bloom) == null ? void 0 : l.weight) ?? c.bloom.weight, this.renderingPipeline.chromaticAberrationEnabled = ((d = e.chromaticAberration) == null ? void 0 : d.enabled) ?? c.chromaticAberration.enabled, this.renderingPipeline.chromaticAberration.aberrationAmount = ((h = e.chromaticAberration) == null ? void 0 : h.aberrationAmount) ?? c.chromaticAberration.aberrationAmount, this.renderingPipeline.chromaticAberration.radialIntensity = ((u = e.chromaticAberration) == null ? void 0 : u.radialIntensity) ?? c.chromaticAberration.radialIntensity, this.renderingPipeline.chromaticAberration.direction = (m = e.chromaticAberration) != null && m.direction ? new ie(
1245
1266
  e.chromaticAberration.direction.x,
1246
1267
  e.chromaticAberration.direction.y
1247
1268
  ) : new ie(
1248
- h.chromaticAberration.direction.x,
1249
- h.chromaticAberration.direction.y
1250
- ), this.renderingPipeline.imageProcessing.colorCurvesEnabled = ((p = e.colorCurves) == null ? void 0 : p.enabled) ?? h.colorCurves.enabled, this.renderingPipeline.imageProcessing.colorCurves = e.colorCurves ? this.updateColorCurve(e.colorCurves) : new ae(), this.renderingPipeline.depthOfFieldEnabled = ((b = e.depthOfField) == null ? void 0 : b.enabled) ?? h.depthOfField.enabled, e.depthOfField)
1251
- switch (e.depthOfField.blurLevel ?? h.depthOfField.blurLevel) {
1269
+ c.chromaticAberration.direction.x,
1270
+ c.chromaticAberration.direction.y
1271
+ ), this.renderingPipeline.imageProcessing.colorCurvesEnabled = ((p = e.colorCurves) == null ? void 0 : p.enabled) ?? c.colorCurves.enabled, this.renderingPipeline.imageProcessing.colorCurves = e.colorCurves ? this.updateColorCurve(e.colorCurves) : new ae(), this.renderingPipeline.depthOfFieldEnabled = ((f = e.depthOfField) == null ? void 0 : f.enabled) ?? c.depthOfField.enabled, e.depthOfField)
1272
+ switch (e.depthOfField.blurLevel ?? c.depthOfField.blurLevel) {
1252
1273
  case "Low":
1253
1274
  this.renderingPipeline.depthOfFieldBlurLevel = T.Low;
1254
1275
  break;
@@ -1259,35 +1280,35 @@ class st {
1259
1280
  this.renderingPipeline.depthOfFieldBlurLevel = T.High;
1260
1281
  break;
1261
1282
  }
1262
- if (this.renderingPipeline.depthOfField.focalLength = ((D = e.depthOfField) == null ? void 0 : D.focalLength) ?? h.depthOfField.focalLength, this.renderingPipeline.depthOfField.fStop = ((k = e.depthOfField) == null ? void 0 : k.fStop) ?? h.depthOfField.fStop, this.renderingPipeline.depthOfField.focusDistance = ((z = e.depthOfField) == null ? void 0 : z.focusDistance) ?? h.depthOfField.focusDistance, this.renderingPipeline.depthOfField.lensSize = ((V = e.depthOfField) == null ? void 0 : V.lensSize) ?? h.depthOfField.lensSize, this.renderingPipeline.grainEnabled = ((G = e.grain) == null ? void 0 : G.enabled) ?? h.grain.enabled, this.renderingPipeline.grain.animated = ((N = e.grain) == null ? void 0 : N.animated) ?? h.grain.animated, this.renderingPipeline.grain.intensity = ((H = e.grain) == null ? void 0 : H.intensity) ?? h.grain.intensity, this.renderingPipeline.imageProcessing.contrast = ((q = e.misc) == null ? void 0 : q.contrast) ?? h.misc.contrast, this.renderingPipeline.imageProcessing.exposure = ((_ = e.misc) == null ? void 0 : _.exposure) ?? h.misc.exposure, this.renderingPipeline.imageProcessing.toneMappingEnabled = ((K = e.misc) == null ? void 0 : K.toneMappingEnabled) ?? h.misc.toneMappingEnabled, this.renderingPipeline.imageProcessing.toneMappingEnabled)
1263
- switch (e.misc.toneMappingType ?? h.misc.toneMappingType) {
1283
+ if (this.renderingPipeline.depthOfField.focalLength = ((D = e.depthOfField) == null ? void 0 : D.focalLength) ?? c.depthOfField.focalLength, this.renderingPipeline.depthOfField.fStop = ((k = e.depthOfField) == null ? void 0 : k.fStop) ?? c.depthOfField.fStop, this.renderingPipeline.depthOfField.focusDistance = ((q = e.depthOfField) == null ? void 0 : q.focusDistance) ?? c.depthOfField.focusDistance, this.renderingPipeline.depthOfField.lensSize = ((z = e.depthOfField) == null ? void 0 : z.lensSize) ?? c.depthOfField.lensSize, this.renderingPipeline.grainEnabled = ((V = e.grain) == null ? void 0 : V.enabled) ?? c.grain.enabled, this.renderingPipeline.grain.animated = ((N = e.grain) == null ? void 0 : N.animated) ?? c.grain.animated, this.renderingPipeline.grain.intensity = ((G = e.grain) == null ? void 0 : G.intensity) ?? c.grain.intensity, this.renderingPipeline.imageProcessing.contrast = ((H = e.misc) == null ? void 0 : H.contrast) ?? c.misc.contrast, this.renderingPipeline.imageProcessing.exposure = ((_ = e.misc) == null ? void 0 : _.exposure) ?? c.misc.exposure, this.renderingPipeline.imageProcessing.toneMappingEnabled = ((K = e.misc) == null ? void 0 : K.toneMappingEnabled) ?? c.misc.toneMappingEnabled, this.renderingPipeline.imageProcessing.toneMappingEnabled)
1284
+ switch (e.misc.toneMappingType ?? c.misc.toneMappingType) {
1264
1285
  case "Standard":
1265
- this.renderingPipeline.imageProcessing.toneMappingType = x.TONEMAPPING_STANDARD;
1286
+ this.renderingPipeline.imageProcessing.toneMappingType = P.TONEMAPPING_STANDARD;
1266
1287
  break;
1267
1288
  case "ACES":
1268
- this.renderingPipeline.imageProcessing.toneMappingType = x.TONEMAPPING_ACES;
1289
+ this.renderingPipeline.imageProcessing.toneMappingType = P.TONEMAPPING_ACES;
1269
1290
  break;
1270
1291
  }
1271
- if (this.renderingPipeline.sharpenEnabled = ((W = e.sharpen) == null ? void 0 : W.enabled) ?? h.sharpen.enabled, this.renderingPipeline.sharpen.colorAmount = ((U = e.sharpen) == null ? void 0 : U.colorAmount) ?? h.sharpen.colorAmount, this.renderingPipeline.sharpen.edgeAmount = ((Y = e.sharpen) == null ? void 0 : Y.edgeAmount) ?? h.sharpen.edgeAmount, this.renderingPipeline.imageProcessing.vignetteEnabled = ((Q = e.vignette) == null ? void 0 : Q.enabled) ?? h.vignette.enabled, (Z = e.vignette) != null && Z.center ? (this.renderingPipeline.imageProcessing.vignetteCenterX = e.vignette.center.x, this.renderingPipeline.imageProcessing.vignetteCenterY = e.vignette.center.y) : (this.renderingPipeline.imageProcessing.vignetteCenterX = h.vignette.center.x, this.renderingPipeline.imageProcessing.vignetteCenterY = h.vignette.center.y), e.vignette)
1272
- switch ((($ = e.vignette) == null ? void 0 : $.blendMode) ?? h.vignette.blendMode) {
1292
+ if (this.renderingPipeline.sharpenEnabled = ((W = e.sharpen) == null ? void 0 : W.enabled) ?? c.sharpen.enabled, this.renderingPipeline.sharpen.colorAmount = ((U = e.sharpen) == null ? void 0 : U.colorAmount) ?? c.sharpen.colorAmount, this.renderingPipeline.sharpen.edgeAmount = ((Y = e.sharpen) == null ? void 0 : Y.edgeAmount) ?? c.sharpen.edgeAmount, this.renderingPipeline.imageProcessing.vignetteEnabled = ((Q = e.vignette) == null ? void 0 : Q.enabled) ?? c.vignette.enabled, (Z = e.vignette) != null && Z.center ? (this.renderingPipeline.imageProcessing.vignetteCenterX = e.vignette.center.x, this.renderingPipeline.imageProcessing.vignetteCenterY = e.vignette.center.y) : (this.renderingPipeline.imageProcessing.vignetteCenterX = c.vignette.center.x, this.renderingPipeline.imageProcessing.vignetteCenterY = c.vignette.center.y), e.vignette)
1293
+ switch ((($ = e.vignette) == null ? void 0 : $.blendMode) ?? c.vignette.blendMode) {
1273
1294
  case "Multiply":
1274
- this.renderingPipeline.imageProcessing.vignetteBlendMode = x.VIGNETTEMODE_MULTIPLY;
1295
+ this.renderingPipeline.imageProcessing.vignetteBlendMode = P.VIGNETTEMODE_MULTIPLY;
1275
1296
  break;
1276
1297
  case "Opaque":
1277
- this.renderingPipeline.imageProcessing.vignetteBlendMode = x.VIGNETTEMODE_OPAQUE;
1298
+ this.renderingPipeline.imageProcessing.vignetteBlendMode = P.VIGNETTEMODE_OPAQUE;
1278
1299
  break;
1279
1300
  }
1280
- (j = e.vignette) != null && j.colorRgba ? this.renderingPipeline.imageProcessing.vignetteColor = new f(
1301
+ (j = e.vignette) != null && j.colorRgba ? this.renderingPipeline.imageProcessing.vignetteColor = new b(
1281
1302
  e.vignette.colorRgba.r,
1282
1303
  e.vignette.colorRgba.g,
1283
1304
  e.vignette.colorRgba.b,
1284
1305
  e.vignette.colorRgba.a
1285
- ) : (X = e.vignette) != null && X.colorHex ? this.renderingPipeline.imageProcessing.vignetteColor = f.FromHexString(e.vignette.colorHex) : this.renderingPipeline.imageProcessing.vignetteColor = new f(
1286
- h.vignette.colorRgba.r,
1287
- h.vignette.colorRgba.g,
1288
- h.vignette.colorRgba.b,
1289
- h.vignette.colorRgba.a
1290
- ), this.renderingPipeline.imageProcessing.vignetteStretch = ((J = e.vignette) == null ? void 0 : J.stretch) ?? h.vignette.stretch, this.renderingPipeline.imageProcessing.vignetteWeight = ((ee = e.vignette) == null ? void 0 : ee.weight) ?? h.vignette.weight, this.renderingPipeline.prepare(), this.currentConfiguration = e;
1306
+ ) : (X = e.vignette) != null && X.colorHex ? this.renderingPipeline.imageProcessing.vignetteColor = b.FromHexString(e.vignette.colorHex) : this.renderingPipeline.imageProcessing.vignetteColor = new b(
1307
+ c.vignette.colorRgba.r,
1308
+ c.vignette.colorRgba.g,
1309
+ c.vignette.colorRgba.b,
1310
+ c.vignette.colorRgba.a
1311
+ ), this.renderingPipeline.imageProcessing.vignetteStretch = ((J = e.vignette) == null ? void 0 : J.stretch) ?? c.vignette.stretch, this.renderingPipeline.imageProcessing.vignetteWeight = ((ee = e.vignette) == null ? void 0 : ee.weight) ?? c.vignette.weight, this.renderingPipeline.prepare(), this.currentConfiguration = e;
1291
1312
  }
1292
1313
  }
1293
1314
  updateColorCurve(e) {
@@ -1295,44 +1316,44 @@ class st {
1295
1316
  return t.globalDensity = e.globalDensity ?? t.globalDensity, t.globalExposure = e.globalExposure ?? t.globalExposure, t.globalHue = e.globalHue ?? t.globalHue, t.globalSaturation = e.globalSaturation ?? t.globalSaturation, t.highlightsDensity = e.highlightsDensity ?? t.highlightsDensity, t.highlightsExposure = e.highlightsExposure ?? t.highlightsExposure, t.highlightsHue = e.highlightsHue ?? t.highlightsHue, t.highlightsSaturation = e.highlightsSaturation ?? t.highlightsSaturation, t.midtonesDensity = e.midtonesDensity ?? t.midtonesDensity, t.midtonesExposure = e.midtonesExposure ?? t.midtonesExposure, t.midtonesHue = e.midtonesHue ?? t.midtonesHue, t.midtonesSaturation = e.midtonesSaturation ?? t.midtonesSaturation, t.shadowsDensity = e.shadowsDensity ?? t.shadowsDensity, t.shadowsExposure = e.shadowsExposure ?? t.shadowsExposure, t.shadowsHue = e.shadowsHue ?? t.shadowsHue, t.shadowsSaturation = e.shadowsSaturation ?? t.shadowsSaturation, t;
1296
1317
  }
1297
1318
  }
1298
- Ae.GLTFLoader.RegisterExtension("glbPostProcessor", function(s) {
1299
- return new Ne(s);
1319
+ Ae.GLTFLoader.RegisterExtension("glbPostProcessor", function(n) {
1320
+ return new Ne(n);
1300
1321
  });
1301
- fe.OnPluginActivatedObservable.add((s) => {
1302
- if (s.name === "gltf") {
1303
- const e = s;
1322
+ fe.OnPluginActivatedObservable.add((n) => {
1323
+ if (n.name === "gltf") {
1324
+ const e = n;
1304
1325
  e.transparencyAsCoverage = !0;
1305
1326
  }
1306
1327
  });
1307
- function O(s) {
1308
- return new m(s.x, s.y, s.z);
1328
+ function O(n) {
1329
+ return new g(n.x, n.y, n.z);
1309
1330
  }
1310
- function L(s) {
1311
- return { x: s.x, y: s.y, z: s.z };
1331
+ function L(n) {
1332
+ return { x: n.x, y: n.y, z: n.z };
1312
1333
  }
1313
1334
  class Wt {
1314
1335
  constructor(e) {
1315
1336
  var l;
1316
- this.focusLostNotified = !1, this.focusLostObservable = new C(), this.modelLoadEventCallbacks = [], this.modelContainers = /* @__PURE__ */ new Map(), this.plugins = [], this.initComplete = !1, this.currentCameraAnimationPromise = Promise.resolve(), this.renderLoop = () => {
1317
- this.engine.views && (this.modelContainers.forEach((c) => {
1318
- c.updateDynamicTextures();
1337
+ this.focusLostNotified = !1, this.focusLostObservable = new C(), this.modelLoadEventCallbacks = [], this.modelContainers = /* @__PURE__ */ new Map(), this.plugins = [], this.initComplete = !1, this.isAnimatingCamera = !1, this.renderLoop = () => {
1338
+ this.engine.views && (this.modelContainers.forEach((d) => {
1339
+ d.updateDynamicTextures();
1319
1340
  }), this.scene.render(), !this.camera.target.equalsWithEpsilon(this.camera.lastFocus, 0.1) && !this.focusLostNotified && (this.focusLostObservable.notifyObservers(void 0), this.focusLostNotified = !0), this.screenshotPrepareResolve && (this.screenshotPrepareResolve(), this.screenshotPrepareResolve = void 0));
1320
1341
  }, this.configuration = new oe(e);
1321
1342
  const i = (() => {
1322
1343
  if (!(e != null && e.noRender))
1323
1344
  return this.configuration.createCanvas();
1324
- })(), r = "1.5.6";
1345
+ })(), s = "1.5.6";
1325
1346
  Me.Configuration = {
1326
1347
  decoder: {
1327
- wasmUrl: `https://www.gstatic.com/draco/versioned/decoders/${r}/draco_wasm_wrapper_gltf.js`,
1328
- wasmBinaryUrl: `https://www.gstatic.com/draco/versioned/decoders/${r}/draco_decoder_gltf.wasm`,
1329
- fallbackUrl: `https://www.gstatic.com/draco/versioned/decoders/${r}/draco_decoder_gltf.js`
1348
+ wasmUrl: `https://www.gstatic.com/draco/versioned/decoders/${s}/draco_wasm_wrapper_gltf.js`,
1349
+ wasmBinaryUrl: `https://www.gstatic.com/draco/versioned/decoders/${s}/draco_decoder_gltf.wasm`,
1350
+ fallbackUrl: `https://www.gstatic.com/draco/versioned/decoders/${s}/draco_decoder_gltf.js`
1330
1351
  }
1331
1352
  }, i && (i.getContext("webgl2") || i.getContext("webgl"));
1332
- const o = console.log;
1353
+ const a = console.log;
1333
1354
  console.log = () => {
1334
1355
  };
1335
- const a = i ? new pe(i, !0, {
1356
+ const o = i ? new pe(i, !0, {
1336
1357
  adaptToDeviceRatio: !0,
1337
1358
  limitDeviceRatio: 2,
1338
1359
  premultipliedAlpha: !1,
@@ -1341,23 +1362,23 @@ class Wt {
1341
1362
  stencil: this.configuration.highlights.enabled,
1342
1363
  forceSRGBBufferSupportState: !0
1343
1364
  }) : new Ce();
1344
- console.log = o, a.hideLoadingUI(), window.addEventListener("resize", this.fireResizeEvent.bind(this)), this.engine = a, this.scene = new xe(a), this.scene.autoClear = !0, this.scene.autoClearDepthAndStencil = !0, this.camera = B.create(this.scene, this.configuration), this.scene.activeCamera = this.camera, this.renderingPipeline = new st(
1365
+ console.log = a, o.hideLoadingUI(), window.addEventListener("resize", this.fireResizeEvent.bind(this)), this.engine = o, this.scene = new Pe(o), this.scene.autoClear = !0, this.scene.autoClearDepthAndStencil = !0, this.camera = B.create(this.scene, this.configuration), this.scene.activeCamera = this.camera, this.renderingPipeline = new nt(
1345
1366
  this.scene,
1346
1367
  !1,
1347
1368
  this.camera
1348
1369
  ), this.scene.clearColor = this.configuration.scene.clearColor;
1349
- const n = te.CreateFromPrefilteredData(
1370
+ const r = te.CreateFromPrefilteredData(
1350
1371
  this.configuration.scene.environment.file,
1351
1372
  this.scene
1352
1373
  );
1353
- n.rotationY = this.configuration.scene.environment.rotationY, this.scene.environmentTexture = n, this.scene.environmentIntensity = this.configuration.scene.environment.intensity, (l = this.configuration.options) != null && l.renderingPipelineConfiguration ? this.renderingPipeline.setConfiguration(
1374
+ r.rotationY = this.configuration.scene.environment.rotationY, this.scene.environmentTexture = r, this.scene.environmentIntensity = this.configuration.scene.environment.intensity, (l = this.configuration.options) != null && l.renderingPipelineConfiguration ? this.renderingPipeline.setConfiguration(
1354
1375
  this.configuration.options.renderingPipelineConfiguration
1355
- ) : (this.scene.imageProcessingConfiguration.exposure = this.configuration.lighting.exposure, this.scene.imageProcessingConfiguration.contrast = this.configuration.lighting.contrast), this.glowLayerManager = new He(
1376
+ ) : (this.scene.imageProcessingConfiguration.exposure = this.configuration.lighting.exposure, this.scene.imageProcessingConfiguration.contrast = this.configuration.lighting.contrast), this.glowLayerManager = new Ge(
1356
1377
  this.scene,
1357
1378
  this.configuration.emissiveGlowIntensity
1358
- ), this.initPromise = new Promise((c) => {
1379
+ ), this.initPromise = new Promise((d) => {
1359
1380
  this.scene.onReadyObservable.addOnce(() => {
1360
- this.initComplete = !0, c();
1381
+ this.initComplete = !0, d();
1361
1382
  });
1362
1383
  }), this.engine.runRenderLoop(this.renderLoop);
1363
1384
  }
@@ -1402,18 +1423,20 @@ class Wt {
1402
1423
  this.plugins.forEach((e) => e.dispose(!0)), this.renderingPipeline.dispose(), this.engine && this.engine.dispose(), window.removeEventListener("resize", this.fireResizeEvent);
1403
1424
  }
1404
1425
  executeCameraAnimation(e) {
1405
- if (!this.camera || this.scene.activeCamera !== this.camera) {
1406
- this.queuedCameraAnimation = e;
1407
- return;
1408
- }
1409
- const t = () => Ye(
1410
- this.scene,
1411
- this.scene.activeCamera,
1412
- e
1413
- );
1414
- this.currentCameraAnimationPromise.then(() => {
1415
- this.currentCameraAnimationPromise = t();
1416
- });
1426
+ if (!this.camera || this.scene.activeCamera !== this.camera)
1427
+ return this.queuedCameraAnimation = e, Promise.resolve();
1428
+ let t = () => {
1429
+ };
1430
+ const i = async () => {
1431
+ this.isAnimatingCamera = !0, await Ye(
1432
+ this.scene,
1433
+ this.scene.activeCamera,
1434
+ e
1435
+ ), this.isAnimatingCamera = !1, this.queuedAnimationFunction && this.queuedAnimationFunction(), this.queuedAnimationFunction = void 0, t();
1436
+ };
1437
+ return this.isAnimatingCamera ? (this.queuedAnimationFunction = i, new Promise((s) => {
1438
+ t = s;
1439
+ })) : i();
1417
1440
  }
1418
1441
  getCameraPose() {
1419
1442
  if (this.scene && this.camera)
@@ -1429,7 +1452,7 @@ class Wt {
1429
1452
  };
1430
1453
  }
1431
1454
  setCameraPose(e) {
1432
- this.scene && this.camera && (this.camera.target = new m(
1455
+ this.scene && this.camera && (this.camera.target = new g(
1433
1456
  e.target.x,
1434
1457
  e.target.y,
1435
1458
  e.target.z
@@ -1444,16 +1467,22 @@ class Wt {
1444
1467
  e === I.Orbit ? this.reattachControls(this.engine.views[0].target, 2) : this.reattachControls(this.engine.views[0].target, 0);
1445
1468
  }
1446
1469
  animateToLastCameraFocus() {
1447
- const e = () => new Promise((t) => {
1448
- const i = () => {
1449
- const r = this.configuration;
1450
- this.camera.rerunFramingBehavior(() => {
1451
- this.focusLostNotified = !1, r.camera.limits.min.radius && (this.camera.lowerRadiusLimit = r.camera.limits.min.radius), r.camera.limits.max.radius && (this.camera.upperRadiusLimit = r.camera.limits.max.radius), t();
1452
- });
1453
- };
1454
- this.scene.onAfterRenderObservable.addOnce(i);
1455
- });
1456
- return this.currentCameraAnimationPromise.then(() => (this.currentCameraAnimationPromise = e(), this.currentCameraAnimationPromise));
1470
+ let e = () => {
1471
+ };
1472
+ const t = async () => {
1473
+ this.isAnimatingCamera = !0, await new Promise((i) => {
1474
+ const s = () => {
1475
+ const a = this.configuration;
1476
+ this.camera.rerunFramingBehavior(() => {
1477
+ this.focusLostNotified = !1, a.camera.limits.min.radius && (this.camera.lowerRadiusLimit = a.camera.limits.min.radius), a.camera.limits.max.radius && (this.camera.upperRadiusLimit = a.camera.limits.max.radius), i();
1478
+ });
1479
+ };
1480
+ this.scene.onAfterRenderObservable.addOnce(s);
1481
+ }), this.isAnimatingCamera = !1, this.queuedAnimationFunction && this.queuedAnimationFunction(), this.queuedAnimationFunction = void 0, e();
1482
+ };
1483
+ return this.isAnimatingCamera ? (this.queuedAnimationFunction = t, new Promise((i) => {
1484
+ e = i;
1485
+ })) : t();
1457
1486
  }
1458
1487
  setAutoRotation(e) {
1459
1488
  !this.configuration.camera.autoRotation.enabled || !this.camera || (e ? this.camera.enableAutoRotationBehavior(
@@ -1471,13 +1500,13 @@ class Wt {
1471
1500
  0,
1472
1501
  0,
1473
1502
  0,
1474
- m.Zero(),
1503
+ g.Zero(),
1475
1504
  this.scene
1476
1505
  );
1477
1506
  try {
1478
- const r = t.latDeg * Math.PI / 180, o = t.lonDeg * Math.PI / 180;
1479
- i.target = t.target ? new m(t.target.x, t.target.y, t.target.z) : m.Zero(), i.alpha = o, i.beta = r, i.radius = t.radius || this.camera.radius, i.minZ = 0.01, this.scene.render();
1480
- const a = await Pe.CreateScreenshotUsingRenderTargetAsync(
1507
+ const s = t.latDeg * Math.PI / 180, a = t.lonDeg * Math.PI / 180;
1508
+ i.target = t.target ? new g(t.target.x, t.target.y, t.target.z) : g.Zero(), i.alpha = a, i.beta = s, i.radius = t.radius || this.camera.radius, i.minZ = 0.01, this.scene.render();
1509
+ const o = await xe.CreateScreenshotUsingRenderTargetAsync(
1481
1510
  this.engine,
1482
1511
  i,
1483
1512
  e,
@@ -1485,7 +1514,7 @@ class Wt {
1485
1514
  2,
1486
1515
  !0
1487
1516
  );
1488
- return i.dispose(), a;
1517
+ return i.dispose(), o;
1489
1518
  } catch {
1490
1519
  throw i.isDisposed() || i.dispose(), new Error("Failed to render screenshot");
1491
1520
  }
@@ -1494,32 +1523,32 @@ class Wt {
1494
1523
  const e = this.configuration;
1495
1524
  if (!e)
1496
1525
  return !0;
1497
- const t = e.camera.limits.min.alpha, i = e.camera.limits.max.alpha, r = e.camera.limits.min.beta, o = e.camera.limits.max.beta;
1498
- if (t === void 0 || i === void 0 || r === void 0 || o === void 0)
1526
+ const t = e.camera.limits.min.alpha, i = e.camera.limits.max.alpha, s = e.camera.limits.min.beta, a = e.camera.limits.max.beta;
1527
+ if (t === void 0 || i === void 0 || s === void 0 || a === void 0)
1499
1528
  return !0;
1500
- const a = [t, i], n = [r, o], l = a.every((d) => d === t), c = n.every((d) => d === r);
1501
- return !l && !c;
1529
+ const o = [t, i], r = [s, a], l = o.every((h) => h === t), d = r.every((h) => h === s);
1530
+ return !l && !d;
1502
1531
  }
1503
1532
  fireResizeEvent() {
1504
1533
  this.getNumViewports() > 0 && this.engine.resize();
1505
1534
  }
1506
1535
  setHighlights(e, t) {
1507
- var r;
1508
- e.length === 0 && ((r = this.highlightLayer) == null || r.dispose(), this.highlightLayer = void 0), this.highlightLayer || (this.highlightLayer = new ye("highlights", this.scene, {
1536
+ var s;
1537
+ e.length === 0 && ((s = this.highlightLayer) == null || s.dispose(), this.highlightLayer = void 0), this.highlightLayer || (this.highlightLayer = new ye("highlights", this.scene, {
1509
1538
  isStroke: !0,
1510
1539
  blurVerticalSize: 0.85,
1511
1540
  blurHorizontalSize: 0.85
1512
1541
  }), this.highlightLayer.innerGlow = !0, this.highlightLayer.outerGlow = !1), this.highlightLayer.removeAllMeshes();
1513
1542
  const i = t ? new w(t[0], t[1], t[2]).toLinearSpace() : void 0;
1514
- e.forEach((o) => {
1515
- const a = this.scene.materials.find(
1516
- (n) => n.name === o.name && n.id === o.id
1543
+ e.forEach((a) => {
1544
+ const o = this.scene.materials.find(
1545
+ (r) => r.name === a.name && r.id === a.id
1517
1546
  );
1518
- a && a.getBindedMeshes().forEach(
1519
- (n) => {
1547
+ o && o.getBindedMeshes().forEach(
1548
+ (r) => {
1520
1549
  var l;
1521
1550
  return (l = this.highlightLayer) == null ? void 0 : l.addMesh(
1522
- n,
1551
+ r,
1523
1552
  i || w.FromHexString("#fcba03")
1524
1553
  );
1525
1554
  }
@@ -1538,9 +1567,12 @@ class Wt {
1538
1567
  progressHandler: t
1539
1568
  });
1540
1569
  return i.getInitializationPromise().then(() => {
1541
- this.modelContainers.size <= 1 && this.camera.rerunFramingBehavior(void 0, 1), Ue(this.scene), this.queuedCameraAnimation && (this.executeCameraAnimation(this.queuedCameraAnimation), this.queuedCameraAnimation = void 0);
1542
- }), this.configuration.highlights.enabled && (i.registerMaterialSelectedCallback((r) => {
1543
- this.setHighlights([r]);
1570
+ this.modelContainers.size <= 1 && this.camera.rerunFramingBehavior(void 0, 1), Ue(this.scene), console.log(
1571
+ "Model loaded, executing queued camera animation",
1572
+ this.queuedCameraAnimation
1573
+ ), this.queuedCameraAnimation && (this.executeCameraAnimation(this.queuedCameraAnimation), this.queuedCameraAnimation = void 0);
1574
+ }), this.configuration.highlights.enabled && (i.registerMaterialSelectedCallback((s) => {
1575
+ this.setHighlights([s]);
1544
1576
  }), i.registerMaterialDeselectedCallback(() => {
1545
1577
  this.setHighlights([]);
1546
1578
  })), this.modelContainers.set(i.getId(), i), this.triggerModelLoadEvent({
@@ -1563,7 +1595,7 @@ class Wt {
1563
1595
  }
1564
1596
  unregisterPlugin(e) {
1565
1597
  const t = this.plugins.indexOf(e);
1566
- t > -1 && this.plugins.splice(t, 1).forEach((r) => r.dispose(!1));
1598
+ t > -1 && this.plugins.splice(t, 1).forEach((s) => s.dispose(!1));
1567
1599
  }
1568
1600
  getGlowLayerManager() {
1569
1601
  return this.glowLayerManager;
@@ -1581,28 +1613,28 @@ class Wt {
1581
1613
  * Flips a transform around the origin.
1582
1614
  */
1583
1615
  flipTransform(e, t, i) {
1584
- const r = se.Compose(
1616
+ const s = ne.Compose(
1585
1617
  O(i || { x: 1, y: 1, z: 1 }),
1586
1618
  y.FromEulerVector(
1587
1619
  O(t || { x: 0, y: 0, z: 0 })
1588
1620
  ),
1589
1621
  O(e || { x: 0, y: 0, z: 0 })
1590
- ), o = se.RotationAxis(m.Up(), Math.PI), a = r.multiply(o), n = m.Zero(), l = y.Identity(), c = m.Zero();
1591
- return a.decompose(c, l, n), l.multiplyInPlace(y.FromEulerAngles(0, Math.PI, 0)), {
1592
- position: L(n),
1622
+ ), a = ne.RotationAxis(g.Up(), Math.PI), o = s.multiply(a), r = g.Zero(), l = y.Identity(), d = g.Zero();
1623
+ return o.decompose(d, l, r), l.multiplyInPlace(y.FromEulerAngles(0, Math.PI, 0)), {
1624
+ position: L(r),
1593
1625
  rotation: L(l.toEulerAngles()),
1594
- scale: L(c)
1626
+ scale: L(d)
1595
1627
  };
1596
1628
  }
1597
1629
  updatePreviewOptions(e) {
1598
- var r;
1630
+ var s;
1599
1631
  const t = new oe(e);
1600
1632
  this.configuration.highlights.enabled !== t.highlights.enabled && this.engine.setStencilBuffer(t.highlights.enabled), this.scene.clearColor = t.scene.clearColor;
1601
1633
  let i = this.scene.environmentTexture;
1602
1634
  this.configuration.scene.environment.file !== t.scene.environment.file && (i = te.CreateFromPrefilteredData(
1603
1635
  t.scene.environment.file,
1604
1636
  this.scene
1605
- ), i.rotationY = this.configuration.scene.environment.rotationY, this.scene.environmentTexture = i), i.rotationY = t.scene.environment.rotationY, this.scene.environmentIntensity = t.scene.environment.intensity, (r = t.options) != null && r.renderingPipelineConfiguration ? this.renderingPipeline.setConfiguration(
1637
+ ), i.rotationY = this.configuration.scene.environment.rotationY, this.scene.environmentTexture = i), i.rotationY = t.scene.environment.rotationY, this.scene.environmentIntensity = t.scene.environment.intensity, (s = t.options) != null && s.renderingPipelineConfiguration ? this.renderingPipeline.setConfiguration(
1606
1638
  t.options.renderingPipelineConfiguration
1607
1639
  ) : (this.scene.imageProcessingConfiguration.exposure = t.lighting.exposure, this.scene.imageProcessingConfiguration.contrast = t.lighting.contrast), this.glowLayerManager.setIntensity(t.emissiveGlowIntensity), this.configuration = t;
1608
1640
  }
@@ -1623,8 +1655,8 @@ class Wt {
1623
1655
  export {
1624
1656
  S as MaterialEffectMode,
1625
1657
  I as ProductCameraRig,
1626
- Ge as REFLECTION_PROBE_RESOLUTION,
1627
- P as RenderingConfiguration,
1658
+ Ve as REFLECTION_PROBE_RESOLUTION,
1659
+ x as RenderingConfiguration,
1628
1660
  Wt as SpiffCommerce3DPreviewService,
1629
- h as renderingPipelineDefaults
1661
+ c as renderingPipelineDefaults
1630
1662
  };