@roomle/web-sdk 3.10.1-alpha.3 → 4.0.0

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 (116) hide show
  1. package/lib/{BufferGeometry-Dj5loCTL.mjs → BufferGeometry-CnbfgBmz.mjs} +2 -2
  2. package/lib/{BufferGeometry-Dj5loCTL.mjs.map → BufferGeometry-CnbfgBmz.mjs.map} +1 -1
  3. package/lib/{GLTFExporter-CquK-kkI.mjs → GLTFExporter-BxcjPMva.mjs} +2 -2
  4. package/lib/{GLTFExporter-CquK-kkI.mjs.map → GLTFExporter-BxcjPMva.mjs.map} +1 -1
  5. package/lib/{GaussianBlurNode-CDYPio-x.mjs → GaussianBlurNode-8gO-I1qG.mjs} +14 -14
  6. package/lib/{GaussianBlurNode-CDYPio-x.mjs.map → GaussianBlurNode-8gO-I1qG.mjs.map} +1 -1
  7. package/lib/{Object3D-YXSPdGeJ.mjs → Object3D-DMaDdv-D.mjs} +1 -1
  8. package/lib/{Object3D-YXSPdGeJ.mjs.map → Object3D-DMaDdv-D.mjs.map} +1 -1
  9. package/lib/{PointLightHelper-g98giMRd.mjs → PointLightHelper-CahXSxiA.mjs} +4 -4
  10. package/lib/{PointLightHelper-g98giMRd.mjs.map → PointLightHelper-CahXSxiA.mjs.map} +1 -1
  11. package/lib/{SpotLightHelper-xR8lCZau.mjs → SpotLightHelper-BEqeYq1p.mjs} +3 -3
  12. package/lib/{SpotLightHelper-xR8lCZau.mjs.map → SpotLightHelper-BEqeYq1p.mjs.map} +1 -1
  13. package/lib/{USDZExporter-BMqBymZI.mjs → USDZExporter-ZZoG1mne.mjs} +3 -3
  14. package/lib/{USDZExporter-BMqBymZI.mjs.map → USDZExporter-ZZoG1mne.mjs.map} +1 -1
  15. package/lib/{Vector4-CqzXUndP.mjs → Vector4-BkA_VGid.mjs} +2 -2
  16. package/lib/{Vector4-CqzXUndP.mjs.map → Vector4-BkA_VGid.mjs.map} +1 -1
  17. package/lib/{api-Cjq6uyhy.mjs → api-CUyBdNba.mjs} +2 -2
  18. package/lib/{api-Cjq6uyhy.mjs.map → api-CUyBdNba.mjs.map} +1 -1
  19. package/lib/{asset-loader.worker-CHyN7JB1.mjs → asset-loader.worker-C_5RQYHp.mjs} +1 -1
  20. package/lib/asset-loader.worker-C_5RQYHp.mjs.map +1 -0
  21. package/lib/{banana-for-scale-Cs2s9dNp.mjs → banana-for-scale-B77S3z9R.mjs} +4 -4
  22. package/lib/{banana-for-scale-Cs2s9dNp.mjs.map → banana-for-scale-B77S3z9R.mjs.map} +1 -1
  23. package/lib/{budgeteer.sw-BCLEIWCW.mjs → budgeteer.sw-DxeAvd0v.mjs} +1 -1
  24. package/lib/budgeteer.sw-DxeAvd0v.mjs.map +1 -0
  25. package/lib/{common-utils-DeAwtH0V.mjs → common-utils-BiOW17Ao.mjs} +2 -2
  26. package/lib/{common-utils-DeAwtH0V.mjs.map → common-utils-BiOW17Ao.mjs.map} +1 -1
  27. package/lib/{component-dimensioning-DINSxpnW.mjs → component-dimensioning-DPyPzSsa.mjs} +7 -7
  28. package/lib/{component-dimensioning-DINSxpnW.mjs.map → component-dimensioning-DPyPzSsa.mjs.map} +1 -1
  29. package/lib/{component-raycast-helper-DiX3LOGg.mjs → component-raycast-helper-RiQIybsX.mjs} +5 -5
  30. package/lib/{component-raycast-helper-DiX3LOGg.mjs.map → component-raycast-helper-RiQIybsX.mjs.map} +1 -1
  31. package/lib/configurator-BBlZVIId.mjs +2 -0
  32. package/lib/{configurator-BC4t2q94.mjs → configurator-C_rsqn9l.mjs} +4 -4
  33. package/lib/{configurator-BC4t2q94.mjs.map → configurator-C_rsqn9l.mjs.map} +1 -1
  34. package/lib/{continuous-drawing-helper-BlGATN0C.mjs → continuous-drawing-helper-C_Yc0uuv.mjs} +3 -3
  35. package/lib/{continuous-drawing-helper-BlGATN0C.mjs.map → continuous-drawing-helper-C_Yc0uuv.mjs.map} +1 -1
  36. package/lib/{decorate-CTUwswpM.mjs → decorate-BAtqSPNS.mjs} +1 -1
  37. package/lib/{decorate-CTUwswpM.mjs.map → decorate-BAtqSPNS.mjs.map} +1 -1
  38. package/lib/dimensioning-helper-Bzf1sbpy.mjs +2 -0
  39. package/lib/{dimensioning-helper-DMop5qcu.mjs → dimensioning-helper-D9oxGkry.mjs} +5 -5
  40. package/lib/{dimensioning-helper-DMop5qcu.mjs.map → dimensioning-helper-D9oxGkry.mjs.map} +1 -1
  41. package/lib/{fflate.module-n0Jozp8Z.mjs → fflate.module-CTnSdWOb.mjs} +1 -1
  42. package/lib/{fflate.module-n0Jozp8Z.mjs.map → fflate.module-CTnSdWOb.mjs.map} +1 -1
  43. package/lib/{glb-viewer-ClwM-_6N.mjs → glb-viewer-A5vSLFZ5.mjs} +8 -8
  44. package/lib/{glb-viewer-ClwM-_6N.mjs.map → glb-viewer-A5vSLFZ5.mjs.map} +1 -1
  45. package/lib/glb-viewer-B4ILlvw0.mjs +2 -0
  46. package/lib/{highlight-coordinator-COSQsFCt.mjs → highlight-coordinator-CZEJGeXA.mjs} +4 -4
  47. package/lib/{highlight-coordinator-COSQsFCt.mjs.map → highlight-coordinator-CZEJGeXA.mjs.map} +1 -1
  48. package/lib/{homag-intelligence-7erRasyd.mjs → homag-intelligence-BdCDX7LF.mjs} +3 -3
  49. package/lib/{homag-intelligence-7erRasyd.mjs.map → homag-intelligence-BdCDX7LF.mjs.map} +1 -1
  50. package/lib/{imos-ix-poc-export-helper-ChN0ot1C.mjs → imos-ix-poc-export-helper-CaXXDNvP.mjs} +4 -4
  51. package/lib/{imos-ix-poc-export-helper-ChN0ot1C.mjs.map → imos-ix-poc-export-helper-CaXXDNvP.mjs.map} +1 -1
  52. package/lib/{kernel-C7YDLxq8.mjs → kernel-BWfRHWkW.mjs} +1 -1
  53. package/lib/{kernel-C7YDLxq8.mjs.map → kernel-BWfRHWkW.mjs.map} +1 -1
  54. package/lib/{kernel-utils-042AuCQh.mjs → kernel-utils-BYEsHVYJ.mjs} +2 -2
  55. package/lib/{kernel-utils-042AuCQh.mjs.map → kernel-utils-BYEsHVYJ.mjs.map} +1 -1
  56. package/lib/{layer-CFAr2mK_.mjs → layer-CIWL5ZW3.mjs} +1 -1
  57. package/lib/{layer-CFAr2mK_.mjs.map → layer-CIWL5ZW3.mjs.map} +1 -1
  58. package/lib/{main-dvJVxkY5.mjs → main-BUl8iCi1.mjs} +3149 -25886
  59. package/lib/main-BUl8iCi1.mjs.map +1 -0
  60. package/lib/{material-viewer-DsjLu7dY.mjs → material-viewer-C4SqVaGG.mjs} +7 -7
  61. package/lib/{material-viewer-DsjLu7dY.mjs.map → material-viewer-C4SqVaGG.mjs.map} +1 -1
  62. package/lib/packages-C9gO5mKk.mjs +10 -0
  63. package/lib/packages-C9gO5mKk.mjs.map +1 -0
  64. package/lib/planner-49YwTdiA.mjs +2 -0
  65. package/lib/{planner-mEOHjdf5.mjs → planner-t4QH26WW.mjs} +3 -3
  66. package/lib/{planner-mEOHjdf5.mjs.map → planner-t4QH26WW.mjs.map} +1 -1
  67. package/lib/{plugin-system-DRpL0Rer.mjs → plugin-system-COZJdJH_.mjs} +3 -3
  68. package/lib/{plugin-system-DRpL0Rer.mjs.map → plugin-system-COZJdJH_.mjs.map} +1 -1
  69. package/lib/roomle-headless.d.ts +142 -98
  70. package/lib/roomle-headless.js +74 -58
  71. package/lib/roomle-headless.js.map +1 -1
  72. package/lib/{roomle-renderer-BD3ZmpLS.mjs → roomle-renderer-DhLUaHJZ.mjs} +23 -10
  73. package/lib/roomle-renderer-DhLUaHJZ.mjs.map +1 -0
  74. package/lib/roomle-sdk.d.ts +123 -95
  75. package/lib/roomle-sdk.js +9 -9
  76. package/lib/{roomle-webgpu-renderer--zQziKoO.mjs → roomle-webgpu-renderer-CRGcdahn.mjs} +293 -240
  77. package/lib/roomle-webgpu-renderer-CRGcdahn.mjs.map +1 -0
  78. package/lib/{scene-renderer-DfFZINZw.mjs → scene-renderer-D5CfxCag.mjs} +7 -7
  79. package/lib/{scene-renderer-DfFZINZw.mjs.map → scene-renderer-D5CfxCag.mjs.map} +1 -1
  80. package/lib/{script-loader-CBi6aL4c.mjs → script-loader-D6IuUFjw.mjs} +3 -3
  81. package/lib/{script-loader-CBi6aL4c.mjs.map → script-loader-D6IuUFjw.mjs.map} +1 -1
  82. package/lib/{shading-settings-BOXM96zx.mjs → shading-settings-BEMqEGzB.mjs} +3 -3
  83. package/lib/{shading-settings-BOXM96zx.mjs.map → shading-settings-BEMqEGzB.mjs.map} +1 -1
  84. package/lib/{stats-helper-BjkO2TkP.mjs → stats-helper-DAfbSToL.mjs} +3 -3
  85. package/lib/{stats-helper-BjkO2TkP.mjs.map → stats-helper-DAfbSToL.mjs.map} +1 -1
  86. package/lib/svgo.browser-DYieWzyw.mjs +21270 -0
  87. package/lib/svgo.browser-DYieWzyw.mjs.map +1 -0
  88. package/lib/{three.core-tV_4n8Wg.mjs → three.core-DjCexDCp.mjs} +1 -1
  89. package/lib/{three.core-tV_4n8Wg.mjs.map → three.core-DjCexDCp.mjs.map} +1 -1
  90. package/lib/{three.module-DC5fF9Zl.mjs → three.module-CuRNgijg.mjs} +2 -2
  91. package/lib/{three.module-DC5fF9Zl.mjs.map → three.module-CuRNgijg.mjs.map} +1 -1
  92. package/lib/{three.tsl-Caqi2VRr.mjs → three.tsl-BIBER8nk.mjs} +49 -47
  93. package/lib/{three.tsl-Caqi2VRr.mjs.map → three.tsl-BIBER8nk.mjs.map} +1 -1
  94. package/lib/three.tsl-Q-21y0pO.mjs +2 -0
  95. package/lib/{three.webgpu-CT4fuV2X.mjs → three.webgpu-Bz4Xtk0X.mjs} +2 -2
  96. package/lib/{three.webgpu-CT4fuV2X.mjs.map → three.webgpu-Bz4Xtk0X.mjs.map} +1 -1
  97. package/lib/{three.webgpu-CxNhl3k-.mjs → three.webgpu-dtN0kDKB.mjs} +2 -2
  98. package/lib/{threejs-utils-CFcj19P1.mjs → threejs-utils-Dpvg3Czz.mjs} +5 -5
  99. package/lib/{threejs-utils-CFcj19P1.mjs.map → threejs-utils-Dpvg3Czz.mjs.map} +1 -1
  100. package/lib/{tools-core-DdgxDXwP.mjs → tools-core-BDOFf9le.mjs} +3 -3
  101. package/lib/{tools-core-DdgxDXwP.mjs.map → tools-core-BDOFf9le.mjs.map} +1 -1
  102. package/lib/workers-DcgrO-z7.mjs +6 -0
  103. package/lib/{workers-Dc-RTL8D.mjs.map → workers-DcgrO-z7.mjs.map} +1 -1
  104. package/package.json +1 -1
  105. package/lib/asset-loader.worker-CHyN7JB1.mjs.map +0 -1
  106. package/lib/budgeteer.sw-BCLEIWCW.mjs.map +0 -1
  107. package/lib/configurator-DrfzsCZi.mjs +0 -2
  108. package/lib/dimensioning-helper-BwBj5QDM.mjs +0 -2
  109. package/lib/glb-viewer-DDQoDXq6.mjs +0 -2
  110. package/lib/main-dvJVxkY5.mjs.map +0 -1
  111. package/lib/packages-DKHZt16c.mjs +0 -4
  112. package/lib/planner-Beg0IuiG.mjs +0 -2
  113. package/lib/roomle-renderer-BD3ZmpLS.mjs.map +0 -1
  114. package/lib/roomle-webgpu-renderer--zQziKoO.mjs.map +0 -1
  115. package/lib/three.tsl-Bb8l7rD7.mjs +0 -2
  116. package/lib/workers-Dc-RTL8D.mjs +0 -6
@@ -1,18 +1,18 @@
1
- import { Ar as e, Br as t, Cr as n, En as r, Gn as i, Hi as a, J as o, Jr as s, Kn as c, On as l, Qt as u, Tt as d, Wi as f, Y as p, _i as m, bi as h, ci as g, ct as _, g as v, gi as y, hi as b, hr as x, ht as S, in as C, jr as w, kr as T, mi as ee, mr as te, pi as ne, q as re, rt as E, sn as D, t as ie, vi as ae, w as O, wr as oe, xi as k, yi as se } from "./three.core-tV_4n8Wg.mjs";
2
- import { t as ce } from "./shading-settings-BOXM96zx.mjs";
3
- import { n as le, r as ue, t as de } from "./decorate-CTUwswpM.mjs";
4
- import { n as fe, r as pe } from "./roomle-renderer-BD3ZmpLS.mjs";
5
- import { Rt as A, Ut as me, Wn as he, Z as ge, bn as j, fr as _e, jn as ve, kt as ye, lr as be, un as xe, vn as Se, x as Ce } from "./three.webgpu-CT4fuV2X.mjs";
6
- import { A as we, B as Te, C as Ee, Ct as De, D as Oe, E as M, F as N, G as ke, H as Ae, I as je, J as Me, K as Ne, L as Pe, M as Fe, N as Ie, O as Le, P as Re, Q as ze, R as Be, S as Ve, St as He, T as Ue, U as We, V as Ge, W as Ke, Y as qe, Z as Je, _ as Ye, _t as Xe, a as Ze, at as Qe, b as $e, bt as P, c as et, ct as tt, d as nt, dt as rt, et as it, f as at, ft as F, g as ot, h as st, ht as I, i as L, it as ct, j as lt, k as ut, l as dt, lt as ft, m as pt, mt as R, n as z, nt as mt, o as ht, ot as gt, p as _t, pt as vt, q as yt, r as bt, rt as xt, s as St, t as Ct, tt as wt, u as Tt, ut as Et, v as Dt, vt as B, w as V, x as Ot, xt as kt, y as At, yt as H, z as jt } from "./three.tsl-Caqi2VRr.mjs";
1
+ import { Ar as e, Br as t, Cr as n, En as r, Gn as i, Hi as a, J as o, Jr as s, Kn as c, On as l, Qt as u, Tt as d, Wi as f, Y as p, _i as m, bi as h, ci as g, ct as _, g as v, gi as y, hi as b, hr as x, ht as S, in as C, jr as w, kr as T, mi as ee, mr as te, pi as ne, q as re, rt as E, sn as D, t as ie, vi as ae, w as O, wr as oe, xi as k, yi as se } from "./three.core-DjCexDCp.mjs";
2
+ import { t as ce } from "./shading-settings-BEMqEGzB.mjs";
3
+ import { n as le, r as ue, t as de } from "./decorate-BAtqSPNS.mjs";
4
+ import { a as A, n as fe, r as pe } from "./roomle-renderer-DhLUaHJZ.mjs";
5
+ import { Rt as j, Ut as me, Wn as he, Z as ge, bn as M, fr as _e, jn as ve, kt as ye, lr as be, un as xe, vn as Se, x as Ce } from "./three.webgpu-Bz4Xtk0X.mjs";
6
+ import { $ as we, A as Te, B as Ee, C as De, Ct as Oe, D as ke, E as N, F as Ae, G as je, H as Me, I as P, J as Ne, K as Pe, L as Fe, M as Ie, N as Le, O as Re, P as ze, R as Be, S as Ve, St as F, T as He, Tt as Ue, U as We, V as Ge, W as Ke, X as qe, Y as Je, Z as Ye, _ as Xe, _t as I, a as Ze, at as Qe, b as $e, bt as L, c as et, ct as tt, d as nt, dt as rt, et as it, f as at, ft as ot, g as st, gt as R, h as ct, ht as lt, i as z, it as ut, j as dt, k as ft, l as pt, m as mt, mt as B, n as V, nt as ht, o as gt, ot as _t, p as vt, pt as yt, q as bt, r as xt, rt as St, s as Ct, st as wt, t as Tt, u as Et, ut as Dt, v as Ot, w as H, wt as kt, x as At, xt as U, y as jt, yt as Mt, z as Nt } from "./three.tsl-BIBER8nk.mjs";
7
7
  //#region ../../node_modules/three/examples/jsm/tsl/display/OutlineNode.js
8
- var U = /* @__PURE__ */ new xe(), Mt = /* @__PURE__ */ new k(), Nt = /* @__PURE__ */ new k(1, 0), Pt = /* @__PURE__ */ new k(0, 1), W, Ft = class extends he {
8
+ var W = /* @__PURE__ */ new xe(), Pt = /* @__PURE__ */ new k(), Ft = /* @__PURE__ */ new k(1, 0), It = /* @__PURE__ */ new k(0, 1), G, Lt = class extends he {
9
9
  static get type() {
10
10
  return "OutlineNode";
11
11
  }
12
12
  constructor(e, t, n = {}) {
13
13
  super("vec4");
14
- let { selectedObjects: r = [], edgeThickness: i = M(1), edgeGlow: a = M(0), downSampleRatio: o = 2 } = n;
15
- this.scene = e, this.camera = t, this.selectedObjects = r, this.edgeThicknessNode = Te(i), this.edgeGlowNode = Te(a), this.downSampleRatio = o, this.updateBeforeType = me.FRAME, this._renderTargetDepthBuffer = new w(), this._renderTargetDepthBuffer.depthTexture = new p(), this._renderTargetDepthBuffer.depthTexture.type = _, this._renderTargetMaskBuffer = new w(), this._renderTargetMaskDownSampleBuffer = new w(1, 1, { depthBuffer: !1 }), this._renderTargetEdgeBuffer1 = new w(1, 1, { depthBuffer: !1 }), this._renderTargetEdgeBuffer2 = new w(1, 1, { depthBuffer: !1 }), this._renderTargetBlurBuffer1 = new w(1, 1, { depthBuffer: !1 }), this._renderTargetBlurBuffer2 = new w(1, 1, { depthBuffer: !1 }), this._renderTargetComposite = new w(1, 1, { depthBuffer: !1 }), this._cameraNear = ze("near", "float", t), this._cameraFar = ze("far", "float", t), this._blurDirection = I(new k()), this._depthTextureUniform = F(this._renderTargetDepthBuffer.depthTexture), this._maskTextureUniform = F(this._renderTargetMaskBuffer.texture), this._maskTextureDownsSampleUniform = F(this._renderTargetMaskDownSampleBuffer.texture), this._edge1TextureUniform = F(this._renderTargetEdgeBuffer1.texture), this._edge2TextureUniform = F(this._renderTargetEdgeBuffer2.texture), this._blurColorTextureUniform = F(this._renderTargetEdgeBuffer1.texture), this._visibleEdgeColor = H(1, 0, 0), this._hiddenEdgeColor = H(0, 1, 0), this._depthMaterial = new A(), this._depthMaterial.colorNode = st(0, 0, 0), this._depthMaterial.name = "OutlineNode.depth", this._depthSpriteMaterial = new ve(), this._depthSpriteMaterial.colorNode = st(0, 0, 0), this._depthSpriteMaterial.name = "OutlineNode.depthSprite", this._prepareMaskMaterial = new A(), this._prepareMaskMaterial.name = "OutlineNode.prepareMask", this._prepareMaskSpriteMaterial = new ve(), this._prepareMaskSpriteMaterial.name = "OutlineNode.prepareMaskSprite", this._materialCopy = new A(), this._materialCopy.name = "OutlineNode.copy", this._edgeDetectionMaterial = new A(), this._edgeDetectionMaterial.name = "OutlineNode.edgeDetection", this._separableBlurMaterial = new A(), this._separableBlurMaterial.name = "OutlineNode.separableBlur", this._separableBlurMaterial2 = new A(), this._separableBlurMaterial2.name = "OutlineNode.separableBlur2", this._compositeMaterial = new A(), this._compositeMaterial.name = "OutlineNode.composite", this._selectionCache = /* @__PURE__ */ new Set(), this._lastSelectionCount = 0, this._textureNode = Ne(this, this._renderTargetComposite.texture);
14
+ let { selectedObjects: r = [], edgeThickness: i = N(1), edgeGlow: a = N(0), downSampleRatio: o = 2 } = n;
15
+ this.scene = e, this.camera = t, this.selectedObjects = r, this.edgeThicknessNode = Ge(i), this.edgeGlowNode = Ge(a), this.downSampleRatio = o, this.updateBeforeType = me.FRAME, this._renderTargetDepthBuffer = new w(), this._renderTargetDepthBuffer.depthTexture = new p(), this._renderTargetDepthBuffer.depthTexture.type = _, this._renderTargetMaskBuffer = new w(), this._renderTargetMaskDownSampleBuffer = new w(1, 1, { depthBuffer: !1 }), this._renderTargetEdgeBuffer1 = new w(1, 1, { depthBuffer: !1 }), this._renderTargetEdgeBuffer2 = new w(1, 1, { depthBuffer: !1 }), this._renderTargetBlurBuffer1 = new w(1, 1, { depthBuffer: !1 }), this._renderTargetBlurBuffer2 = new w(1, 1, { depthBuffer: !1 }), this._renderTargetComposite = new w(1, 1, { depthBuffer: !1 }), this._cameraNear = it("near", "float", t), this._cameraFar = it("far", "float", t), this._blurDirection = I(new k()), this._depthTextureUniform = B(this._renderTargetDepthBuffer.depthTexture), this._maskTextureUniform = B(this._renderTargetMaskBuffer.texture), this._maskTextureDownsSampleUniform = B(this._renderTargetMaskDownSampleBuffer.texture), this._edge1TextureUniform = B(this._renderTargetEdgeBuffer1.texture), this._edge2TextureUniform = B(this._renderTargetEdgeBuffer2.texture), this._blurColorTextureUniform = B(this._renderTargetEdgeBuffer1.texture), this._visibleEdgeColor = U(1, 0, 0), this._hiddenEdgeColor = U(0, 1, 0), this._depthMaterial = new j(), this._depthMaterial.colorNode = ct(0, 0, 0), this._depthMaterial.name = "OutlineNode.depth", this._depthSpriteMaterial = new ve(), this._depthSpriteMaterial.colorNode = ct(0, 0, 0), this._depthSpriteMaterial.name = "OutlineNode.depthSprite", this._prepareMaskMaterial = new j(), this._prepareMaskMaterial.name = "OutlineNode.prepareMask", this._prepareMaskSpriteMaterial = new ve(), this._prepareMaskSpriteMaterial.name = "OutlineNode.prepareMaskSprite", this._materialCopy = new j(), this._materialCopy.name = "OutlineNode.copy", this._edgeDetectionMaterial = new j(), this._edgeDetectionMaterial.name = "OutlineNode.edgeDetection", this._separableBlurMaterial = new j(), this._separableBlurMaterial.name = "OutlineNode.separableBlur", this._separableBlurMaterial2 = new j(), this._separableBlurMaterial2.name = "OutlineNode.separableBlur2", this._compositeMaterial = new j(), this._compositeMaterial.name = "OutlineNode.composite", this._selectionCache = /* @__PURE__ */ new Set(), this._lastSelectionCount = 0, this._textureNode = bt(this, this._renderTargetComposite.texture);
16
16
  }
17
17
  get visibleEdge() {
18
18
  return this.r;
@@ -31,11 +31,11 @@ var U = /* @__PURE__ */ new xe(), Mt = /* @__PURE__ */ new k(), Nt = /* @__PURE_
31
31
  updateBefore(e) {
32
32
  let { renderer: t } = e, { camera: n, scene: r } = this;
33
33
  if (this._updateSelectionCache(), this._selectionCache.size === 0) {
34
- this._lastSelectionCount > 0 && (W = j.resetRendererState(t, W), t.setRenderTarget(this._renderTargetComposite), t.setClearColor(0, 0), t.clear(), j.restoreRendererState(t, W), this._lastSelectionCount = 0);
34
+ this._lastSelectionCount > 0 && (G = M.resetRendererState(t, G), t.setRenderTarget(this._renderTargetComposite), t.setClearColor(0, 0), t.clear(), M.restoreRendererState(t, G), this._lastSelectionCount = 0);
35
35
  return;
36
36
  }
37
- this._lastSelectionCount = this._selectionCache.size, W = j.resetRendererAndSceneState(t, r, W);
38
- let i = t.getDrawingBufferSize(Mt);
37
+ this._lastSelectionCount = this._selectionCache.size, G = M.resetRendererAndSceneState(t, r, G);
38
+ let i = t.getDrawingBufferSize(Pt);
39
39
  this.setSize(i.width, i.height), t.setClearColor(16777215, 1);
40
40
  let a = r.name;
41
41
  t.setRenderTarget(this._renderTargetDepthBuffer), t.setRenderObjectFunction((e, n, r, i, a, o, s, c) => {
@@ -48,33 +48,33 @@ var U = /* @__PURE__ */ new xe(), Mt = /* @__PURE__ */ new k(), Nt = /* @__PURE_
48
48
  let a = e.isSprite ? this._prepareMaskSpriteMaterial : this._prepareMaskMaterial;
49
49
  t.renderObject(e, n, r, i, a, o, s, c);
50
50
  }
51
- }), r.name = "Outline [ Selected Objects Pass ]", t.render(r, n), t.setRenderObjectFunction(W.renderObjectFunction), this._selectionCache.clear(), r.name = a, U.material = this._materialCopy, U.name = "Outline [ Downsample ]", t.setRenderTarget(this._renderTargetMaskDownSampleBuffer), U.render(t), U.material = this._edgeDetectionMaterial, U.name = "Outline [ Edge Detection ]", t.setRenderTarget(this._renderTargetEdgeBuffer1), U.render(t), this._blurColorTextureUniform.value = this._renderTargetEdgeBuffer1.texture, this._blurDirection.value.copy(Nt), U.material = this._separableBlurMaterial, U.name = "Outline [ Blur Half Resolution ]", t.setRenderTarget(this._renderTargetBlurBuffer1), U.render(t), this._blurColorTextureUniform.value = this._renderTargetBlurBuffer1.texture, this._blurDirection.value.copy(Pt), t.setRenderTarget(this._renderTargetEdgeBuffer1), U.render(t), this._blurColorTextureUniform.value = this._renderTargetEdgeBuffer1.texture, this._blurDirection.value.copy(Nt), U.material = this._separableBlurMaterial2, U.name = "Outline [ Blur Quarter Resolution ]", t.setRenderTarget(this._renderTargetBlurBuffer2), U.render(t), this._blurColorTextureUniform.value = this._renderTargetBlurBuffer2.texture, this._blurDirection.value.copy(Pt), t.setRenderTarget(this._renderTargetEdgeBuffer2), U.render(t), U.material = this._compositeMaterial, U.name = "Outline [ Blur Quarter Resolution ]", t.setRenderTarget(this._renderTargetComposite), U.render(t), j.restoreRendererAndSceneState(t, r, W);
51
+ }), r.name = "Outline [ Selected Objects Pass ]", t.render(r, n), t.setRenderObjectFunction(G.renderObjectFunction), this._selectionCache.clear(), r.name = a, W.material = this._materialCopy, W.name = "Outline [ Downsample ]", t.setRenderTarget(this._renderTargetMaskDownSampleBuffer), W.render(t), W.material = this._edgeDetectionMaterial, W.name = "Outline [ Edge Detection ]", t.setRenderTarget(this._renderTargetEdgeBuffer1), W.render(t), this._blurColorTextureUniform.value = this._renderTargetEdgeBuffer1.texture, this._blurDirection.value.copy(Ft), W.material = this._separableBlurMaterial, W.name = "Outline [ Blur Half Resolution ]", t.setRenderTarget(this._renderTargetBlurBuffer1), W.render(t), this._blurColorTextureUniform.value = this._renderTargetBlurBuffer1.texture, this._blurDirection.value.copy(It), t.setRenderTarget(this._renderTargetEdgeBuffer1), W.render(t), this._blurColorTextureUniform.value = this._renderTargetEdgeBuffer1.texture, this._blurDirection.value.copy(Ft), W.material = this._separableBlurMaterial2, W.name = "Outline [ Blur Quarter Resolution ]", t.setRenderTarget(this._renderTargetBlurBuffer2), W.render(t), this._blurColorTextureUniform.value = this._renderTargetBlurBuffer2.texture, this._blurDirection.value.copy(It), t.setRenderTarget(this._renderTargetEdgeBuffer2), W.render(t), W.material = this._compositeMaterial, W.name = "Outline [ Blur Quarter Resolution ]", t.setRenderTarget(this._renderTargetComposite), W.render(t), M.restoreRendererAndSceneState(t, r, G);
52
52
  }
53
53
  setup() {
54
54
  let e = () => {
55
- let e = this._depthTextureUniform.sample(xt), t;
56
- return t = this.camera.isPerspectiveCamera ? yt(e, this._cameraNear, this._cameraFar) : We(e, this._cameraNear, this._cameraFar), H(0, Me.z.lessThanEqual(t).select(1, 0), 1);
55
+ let e = this._depthTextureUniform.sample(Qe), t;
56
+ return t = this.camera.isPerspectiveCamera ? Ne(e, this._cameraNear, this._cameraFar) : Ke(e, this._cameraNear, this._cameraFar), U(0, Je.z.lessThanEqual(t).select(1, 0), 1);
57
57
  };
58
58
  this._prepareMaskMaterial.colorNode = e(), this._prepareMaskMaterial.needsUpdate = !0, this._prepareMaskSpriteMaterial.colorNode = e(), this._prepareMaskSpriteMaterial.needsUpdate = !0, this._materialCopy.fragmentNode = this._maskTextureUniform, this._materialCopy.needsUpdate = !0;
59
- let t = z(() => {
60
- let e = vt(this._maskTextureDownsSampleUniform), t = B(1).div(e).toVar(), n = P(1, 0, 0, 1).mul(P(t, t)), r = Xe(), i = this._maskTextureDownsSampleUniform.sample(r.add(n.xy)).toVar(), a = this._maskTextureDownsSampleUniform.sample(r.sub(n.xy)).toVar(), o = this._maskTextureDownsSampleUniform.sample(r.add(n.yw)).toVar(), s = this._maskTextureDownsSampleUniform.sample(r.sub(n.yw)).toVar(), c = B(jt(i.r.sub(a.r), .5), jt(o.r.sub(s.r), .5)).length();
61
- return P(je(je(i.g, a.g), je(o.g, s.g)).oneMinus().greaterThan(.001).select(this._visibleEdgeColor, this._hiddenEdgeColor), 1).mul(c);
59
+ let t = V(() => {
60
+ let e = lt(this._maskTextureDownsSampleUniform), t = L(1).div(e).toVar(), n = F(1, 0, 0, 1).mul(F(t, t)), r = Mt(), i = this._maskTextureDownsSampleUniform.sample(r.add(n.xy)).toVar(), a = this._maskTextureDownsSampleUniform.sample(r.sub(n.xy)).toVar(), o = this._maskTextureDownsSampleUniform.sample(r.add(n.yw)).toVar(), s = this._maskTextureDownsSampleUniform.sample(r.sub(n.yw)).toVar(), c = L(Ee(i.r.sub(a.r), .5), Ee(o.r.sub(s.r), .5)).length();
61
+ return F(Fe(Fe(i.g, a.g), Fe(o.g, s.g)).oneMinus().greaterThan(.001).select(this._visibleEdgeColor, this._hiddenEdgeColor), 1).mul(c);
62
62
  });
63
63
  this._edgeDetectionMaterial.fragmentNode = t(), this._edgeDetectionMaterial.needsUpdate = !0;
64
- let n = z(([e, t]) => M(.39894).mul(Ue(M(-.5).mul(e).mul(e).div(t.mul(t))).div(t))), r = z(([e]) => {
65
- let t = vt(this._maskTextureDownsSampleUniform), r = B(1).div(t).toVar(), i = Xe(), a = e.div(2).toVar(), o = n(0, a).toVar(), s = this._blurColorTextureUniform.sample(i).mul(o).toVar(), c = this._blurDirection.mul(r).mul(e).div(4).toVar(), l = c.toVar();
64
+ let n = V(([e, t]) => N(.39894).mul(He(N(-.5).mul(e).mul(e).div(t.mul(t))).div(t))), r = V(([e]) => {
65
+ let t = lt(this._maskTextureDownsSampleUniform), r = L(1).div(t).toVar(), i = Mt(), a = e.div(2).toVar(), o = n(0, a).toVar(), s = this._blurColorTextureUniform.sample(i).mul(o).toVar(), c = this._blurDirection.mul(r).mul(e).div(4).toVar(), l = c.toVar();
66
66
  return Ze({
67
- start: we(1),
68
- end: we(4),
67
+ start: dt(1),
68
+ end: dt(4),
69
69
  type: "int",
70
70
  condition: "<="
71
71
  }, ({ i: t }) => {
72
- let r = n(e.mul(M(t)).div(4), a), u = this._blurColorTextureUniform.sample(i.add(l)), d = this._blurColorTextureUniform.sample(i.sub(l));
72
+ let r = n(e.mul(N(t)).div(4), a), u = this._blurColorTextureUniform.sample(i.add(l)), d = this._blurColorTextureUniform.sample(i.sub(l));
73
73
  s.addAssign(u.add(d).mul(r)), o.addAssign(r.mul(2)), l.addAssign(c);
74
74
  }), s.div(o);
75
75
  });
76
76
  this._separableBlurMaterial.fragmentNode = r(this.edgeThicknessNode), this._separableBlurMaterial.needsUpdate = !0, this._separableBlurMaterial2.fragmentNode = r(4), this._separableBlurMaterial2.needsUpdate = !0;
77
- let i = z(() => {
77
+ let i = V(() => {
78
78
  let e = this._edge1TextureUniform, t = this._edge2TextureUniform, n = this._maskTextureUniform, r = e.add(t.mul(this.edgeGlowNode));
79
79
  return n.r.mul(r);
80
80
  });
@@ -88,7 +88,7 @@ var U = /* @__PURE__ */ new xe(), Mt = /* @__PURE__ */ new k(), Nt = /* @__PURE_
88
88
  (e.isMesh || e.isSprite) && this._selectionCache.add(e);
89
89
  });
90
90
  }
91
- }, It = (e, t, n) => new Ft(e, t, n), Lt = class {}, Rt = class e extends Lt {
91
+ }, Rt = (e, t, n) => new Lt(e, t, n), zt = class {}, Bt = class e extends zt {
92
92
  static {
93
93
  this.passId = "OutlineRenderPass";
94
94
  }
@@ -102,12 +102,12 @@ var U = /* @__PURE__ */ new xe(), Mt = /* @__PURE__ */ new k(), Nt = /* @__PURE_
102
102
  this.visibleEdgeColor.value = new O(e), this.hiddenEdgeColor.value = new O(t);
103
103
  }
104
104
  assemble(e, t, n, r, i) {
105
- let { visibleEdge: a, hiddenEdge: o } = It(n, r, {
105
+ let { visibleEdge: a, hiddenEdge: o } = Rt(n, r, {
106
106
  selectedObjects: this.selectedObjects,
107
107
  edgeThickness: this.edgeThickness,
108
108
  edgeGlow: this.edgeGlow
109
109
  }), s = a.mul(this.visibleEdgeColor).add(o.mul(this.hiddenEdgeColor)).mul(this.edgeStrength);
110
- return i === "outline" ? P(0, 0, 0, 0).add(s) : t.add(s);
110
+ return i === "outline" ? F(0, 0, 0, 0).add(s) : t.add(s);
111
111
  }
112
112
  addParametersToGUI(e, n) {
113
113
  let r = e.addFolder("Outline Settings");
@@ -117,20 +117,20 @@ var U = /* @__PURE__ */ new xe(), Mt = /* @__PURE__ */ new k(), Nt = /* @__PURE_
117
117
  this.hiddenEdgeColor.value.set(e), n();
118
118
  });
119
119
  }
120
- }, zt = class {
120
+ }, Vt = class {
121
121
  constructor(e, t) {
122
122
  this.uid = e, this.cid = e.match(/^(.*):f(\d+)$/)[1], this.name = t, this.timestamp = 0, this.cpu = 0, this.gpu = 0, this.fps = 0, this.children = [], this.parent = null;
123
123
  }
124
- }, Bt = class extends zt {
124
+ }, Ht = class extends Vt {
125
125
  constructor(e, t, n, r) {
126
126
  let i = t.name;
127
127
  i === "" && (t.isScene ? i = "Scene" : t.isQuadMesh && (i = "QuadMesh")), super(e, i), this.scene = t, this.camera = n, this.renderTarget = r, this.isRenderStats = !0;
128
128
  }
129
- }, Vt = class extends zt {
129
+ }, Ut = class extends Vt {
130
130
  constructor(e, t) {
131
131
  super(e, t.name), this.computeNode = t, this.isComputeStats = !0;
132
132
  }
133
- }, Ht = class extends ge {
133
+ }, Wt = class extends ge {
134
134
  constructor() {
135
135
  super(), this.currentFrame = null, this.currentRender = null, this.currentNodes = null, this.lastFrame = null, this.frames = [], this.framesLib = {}, this.maxFrames = 512, this._lastFinishTime = 0, this._resolveTimestampPromise = null, this.isRendererInspector = !0;
136
136
  }
@@ -219,7 +219,7 @@ var U = /* @__PURE__ */ new xe(), Mt = /* @__PURE__ */ new k(), Nt = /* @__PURE_
219
219
  beginCompute(e, t) {
220
220
  let n = this.getFrame();
221
221
  if (!n) return;
222
- let r = new Vt(e, t);
222
+ let r = new Ut(e, t);
223
223
  r.timestamp = performance.now(), r.parent = this.currentCompute || this.getParent(), n.computes.push(r), this.currentRender === null ? n.children.push(r) : this.currentRender.children.push(r), this.currentCompute = r;
224
224
  }
225
225
  finishCompute() {
@@ -230,7 +230,7 @@ var U = /* @__PURE__ */ new xe(), Mt = /* @__PURE__ */ new k(), Nt = /* @__PURE_
230
230
  beginRender(e, t, n, r) {
231
231
  let i = this.getFrame();
232
232
  if (!i) return;
233
- let a = new Bt(e, t, n, r);
233
+ let a = new Ht(e, t, n, r);
234
234
  a.timestamp = performance.now(), a.parent = this.getParent(), i.renders.push(a), this.currentRender === null ? i.children.push(a) : this.currentRender.children.push(a), this.currentRender = a;
235
235
  }
236
236
  finishRender() {
@@ -238,15 +238,15 @@ var U = /* @__PURE__ */ new xe(), Mt = /* @__PURE__ */ new k(), Nt = /* @__PURE_
238
238
  let e = this.currentRender;
239
239
  e.cpu = performance.now() - e.timestamp, this.currentRender = e.parent;
240
240
  }
241
- }, Ut = class {
241
+ }, Gt = class {
242
242
  static init() {
243
243
  if (document.getElementById("profiler-styles")) return;
244
244
  let e = document.createElement("style");
245
245
  e.id = "profiler-styles", e.textContent = "\n:root {\n --profiler-bg: #1e1e24f5;\n --profiler-header-bg: #2a2a33aa;\n --profiler-header: #2a2a33;\n --profiler-border: #4a4a5a;\n --text-primary: #e0e0e0;\n --text-secondary: #9a9aab;\n --accent-color: #00aaff;\n --color-green: #4caf50;\n --color-yellow: #ffc107;\n --color-red: #f44336;\n --color-fps: rgb(63, 81, 181);\n --color-call: rgba(255, 185, 34, 1);\n --font-family: 'Inter', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;\n --font-mono: 'Fira Code', 'Courier New', Courier, monospace;\n}\n\n@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600&family=Fira+Code&display=swap');\n\n#profiler-panel *, #profiler-toggle * {\n text-transform: initial;\n line-height: normal;\n box-sizing: border-box;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n}\n\n#profiler-toggle {\n position: fixed;\n top: 15px;\n right: 15px;\n background-color: rgba(30, 30, 36, 0.85);\n border: 1px solid #4a4a5a54;\n border-radius: 12px 6px 6px 12px;\n color: var(--text-primary);\n cursor: pointer;\n z-index: 1001;\n transition: all 0.2s ease-in-out;\n /*font-size: 14px;*/\n font-size: 15px;\n backdrop-filter: blur(8px);\n box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);\n display: flex;\n align-items: stretch;\n padding: 0;\n overflow: hidden;\n font-family: var(--font-family);\n}\n\n#profiler-toggle.position-right.panel-open {\n right: auto;\n left: 15px;\n border-radius: 6px 12px 12px 6px;\n flex-direction: row-reverse;\n}\n\n#profiler-toggle.position-right.panel-open #builtin-tabs-container {\n border-right: none;\n border-left: 1px solid #262636;\n}\n\n#profiler-toggle:hover {\n border-color: var(--accent-color);\n}\n\n#profiler-toggle.panel-open #toggle-icon {\n background-color: rgba(0, 170, 255, 0.2);\n color: var(--accent-color);\n}\n\n#toggle-icon {\n display: flex;\n align-items: center;\n justify-content: center;\n width: 40px;\n font-size: 20px;\n transition: background-color 0.2s;\n}\n\n#profiler-toggle:hover #toggle-icon {\n background-color: rgba(255, 255, 255, 0.05);\n}\n\n#profiler-toggle.panel-open:hover #toggle-icon {\n background-color: rgba(0, 170, 255, 0.3);\n}\n\n.toggle-separator {\n width: 1px;\n background-color: var(--profiler-border);\n}\n\n#toggle-text {\n display: flex;\n align-items: baseline;\n padding: 8px 14px;\n min-width: 80px;\n justify-content: right;\n}\n\n#toggle-text .fps-label {\n font-size: 0.7em;\n margin-left: 10px;\n color: #999;\n}\n\n#builtin-tabs-container {\n display: flex;\n align-items: stretch;\n gap: 0;\n border-right: 1px solid #262636;\n order: -1;\n}\n\n.builtin-tab-btn {\n background: transparent;\n border: none;\n color: var(--text-secondary);\n cursor: pointer;\n padding: 8px 14px;\n font-family: var(--font-family);\n font-size: 13px;\n font-weight: 600;\n transition: all 0.2s;\n display: flex;\n align-items: center;\n justify-content: center;\n min-width: 32px;\n position: relative;\n}\n\n.builtin-tab-btn svg {\n width: 20px;\n height: 20px;\n stroke: currentColor;\n}\n\n.builtin-tab-btn:hover {\n background-color: rgba(255, 255, 255, 0.08);\n color: var(--accent-color);\n}\n\n.builtin-tab-btn:active {\n background-color: rgba(255, 255, 255, 0.12);\n}\n\n.builtin-tab-btn.active {\n background-color: rgba(0, 170, 255, 0.2);\n color: var(--accent-color);\n}\n\n.builtin-tab-btn.active:hover {\n background-color: rgba(0, 170, 255, 0.3);\n}\n\n#profiler-mini-panel {\n position: fixed;\n top: 60px;\n right: 15px;\n background-color: rgba(30, 30, 36, 0.85);\n border: 1px solid #4a4a5a54;\n border-radius: 8px;\n color: var(--text-primary);\n z-index: 9999;\n backdrop-filter: blur(8px);\n box-shadow: 0 6px 24px rgba(0, 0, 0, 0.5);\n font-family: var(--font-family);\n font-size: 11px;\n width: 350px;\n max-height: calc(100vh - 100px);\n overflow-y: auto;\n overflow-x: hidden;\n display: none;\n opacity: 0;\n transform: translateY(-10px) scale(0.98);\n transition: opacity 0.25s cubic-bezier(0.4, 0, 0.2, 1), \n transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);\n}\n\n#profiler-mini-panel.position-right.panel-open {\n right: auto;\n left: 15px;\n}\n\n#profiler-mini-panel.visible {\n display: block;\n opacity: 1;\n transform: translateY(0) scale(1);\n}\n\n#profiler-mini-panel::-webkit-scrollbar {\n width: 6px;\n}\n\n#profiler-mini-panel::-webkit-scrollbar-track {\n background: transparent;\n}\n\n#profiler-mini-panel::-webkit-scrollbar-thumb {\n background: rgba(255, 255, 255, 0.15);\n border-radius: 3px;\n transition: background 0.2s;\n}\n\n#profiler-mini-panel::-webkit-scrollbar-thumb:hover {\n background: rgba(255, 255, 255, 0.25);\n}\n\n.mini-panel-content {\n padding: 0;\n font-size: 11px;\n line-height: 1.5;\n font-family: var(--font-mono);\n letter-spacing: 0.3px;\n user-select: none;\n -webkit-user-select: none;\n}\n\n.mini-panel-content .profiler-content {\n display: block !important;\n background: transparent;\n}\n\n.mini-panel-content .list-scroll-wrapper {\n max-height: calc(100vh - 120px);\n overflow-y: auto;\n overflow-x: hidden;\n width: 100%;\n}\n\n.mini-panel-content .list-scroll-wrapper::-webkit-scrollbar {\n width: 4px;\n}\n\n.mini-panel-content .list-scroll-wrapper::-webkit-scrollbar-track {\n background: transparent;\n}\n\n.mini-panel-content .list-scroll-wrapper::-webkit-scrollbar-thumb {\n background: rgba(255, 255, 255, 0.1);\n border-radius: 2px;\n}\n\n.mini-panel-content .list-scroll-wrapper::-webkit-scrollbar-thumb:hover {\n background: rgba(255, 255, 255, 0.2);\n}\n\n.mini-panel-content .parameters {\n background: transparent;\n border: none;\n box-shadow: none;\n padding: 4px;\n}\n\n.mini-panel-content .list-container.parameters {\n padding: 2px 6px 0px 6px !important;\n}\n\n.mini-panel-content .list-header {\n display: none;\n padding: 2px 4px;\n font-size: 11px;\n font-weight: 600;\n text-transform: uppercase;\n letter-spacing: 0.5px;\n}\n\n.mini-panel-content .list-item {\n border-bottom: 1px solid rgba(74, 74, 90, 0.2);\n transition: background-color 0.15s;\n}\n\n.mini-panel-content .list-item:last-child {\n border-bottom: none;\n}\n\n.mini-panel-content .list-item:hover {\n background-color: rgba(255, 255, 255, 0.04);\n}\n\n.mini-panel-content .list-item.actionable:hover {\n background-color: rgba(255, 255, 255, 0.06);\n cursor: pointer;\n}\n\n/* Style adjustments for lil-gui look */\n.mini-panel-content .item-row {\n padding: 3px 8px;\n min-height: 24px;\n}\n\n.mini-panel-content .list-item-row {\n padding: 1px 4px;\n gap: 8px;\n min-height: 21px;\n align-items: center;\n}\n\n.mini-panel-content input[type=\"checkbox\"] {\n width: 12px;\n height: 12px;\n}\n\n.mini-panel-content input[type=\"range\"] {\n height: 18px;\n}\n\n.mini-panel-content .value-number input,\n.mini-panel-content .value-slider input {\n background-color: rgba(0, 0, 0, 0.3);\n border: 1px solid rgba(74, 74, 90, 0.5);\n font-size: 10px;\n}\n\n.mini-panel-content .value-number input:focus,\n.mini-panel-content .value-slider input:focus {\n border-color: var(--accent-color);\n}\n\n.mini-panel-content .value-slider {\n gap: 6px;\n}\n\n/* Compact nested items */\n.mini-panel-content .list-item .list-item {\n margin-left: 8px;\n}\n\n.mini-panel-content .list-item .list-item .item-row,\n.mini-panel-content .list-item .list-item .list-item-row {\n padding: 2px 6px;\n min-height: 22px;\n}\n\n/* Compact collapsible headers */\n.mini-panel-content .collapsible .item-row,\n.mini-panel-content .list-item-row.collapsible {\n padding: 2px 8px;\n font-weight: 600;\n min-height: 16px;\n display: flex;\n align-items: center;\n}\n\n.mini-panel-content .collapsible-icon {\n font-size: 10px;\n width: 14px;\n height: 14px;\n}\n\n.mini-panel-content .param-control input[type=\"range\"] {\n height: 12px;\n margin-top: 1px;\n padding-top: 5px;\n user-select: none;\n -webkit-user-select: none;\n outline: none;\n}\n\n.mini-panel-content .param-control input[type=\"range\"]::-webkit-slider-thumb {\n width: 14px;\n height: 14px;\n margin-top: -5px;\n user-select: none;\n -webkit-user-select: none;\n}\n\n.mini-panel-content .param-control input[type=\"range\"]::-moz-range-thumb {\n width: 14px;\n height: 14px;\n user-select: none;\n -moz-user-select: none;\n}\n\n.mini-panel-content .list-children-container {\n padding-left: 0;\n}\n\n.mini-panel-content .param-control input[type=\"number\"] {\n flex-basis: 60px !important;\n}\n\n.mini-panel-content .param-control {\n align-items: center;\n}\n\n.mini-panel-content .param-control select {\n font-size: 11px;\n}\n\n.mini-panel-content .list-item-wrapper {\n margin-top: 0;\n margin-bottom: 0;\n}\n\n#profiler-panel {\n position: fixed;\n z-index: 1001 !important;\n bottom: 0;\n left: 0;\n right: 0;\n height: 350px;\n background-color: var(--profiler-bg);\n backdrop-filter: blur(8px);\n border-top: 2px solid var(--profiler-border);\n color: var(--text-primary);\n display: flex;\n flex-direction: column;\n z-index: 1000;\n /*box-shadow: 0 -5px 25px rgba(0, 0, 0, 0.5);*/\n transform: translateY(100%);\n transition: transform 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94), height 0.3s ease-out, width 0.3s ease-out;\n font-family: var(--font-mono);\n}\n\n#profiler-panel.resizing,\n#profiler-panel.dragging {\n transition: none;\n}\n\n#profiler-panel.visible {\n transform: translateY(0);\n}\n\n#profiler-panel.maximized {\n height: 100vh;\n}\n\n/* Position-specific styles */\n#profiler-panel.position-top {\n bottom: auto;\n top: 0;\n border-top: none;\n border-bottom: 2px solid var(--profiler-border);\n transform: translateY(-100%);\n}\n\n#profiler-panel.position-top.visible {\n transform: translateY(0);\n}\n\n#profiler-panel.position-bottom {\n /* Default position - already defined above */\n}\n\n#profiler-panel.position-left {\n top: 0;\n bottom: 0;\n left: 0;\n right: auto;\n width: 350px;\n height: 100%;\n border-top: none;\n border-right: 2px solid var(--profiler-border);\n transform: translateX(-100%);\n}\n\n#profiler-panel.position-left.visible {\n transform: translateX(0);\n}\n\n#profiler-panel.position-right {\n top: 0;\n bottom: 0;\n left: auto;\n right: 0;\n width: 350px;\n height: 100%;\n border-top: none;\n border-left: 2px solid var(--profiler-border);\n transform: translateX(100%);\n}\n\n#profiler-panel.position-right.visible {\n transform: translateX(0);\n}\n\n#profiler-panel.position-floating {\n border: 2px solid var(--profiler-border);\n border-radius: 8px;\n box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);\n transform: none !important;\n overflow: hidden;\n}\n\n#profiler-panel.position-floating.visible {\n transform: none !important;\n}\n\n#profiler-panel.position-floating .profiler-header {\n border-radius: 6px 6px 0 0;\n}\n\n#profiler-panel.position-floating .panel-resizer {\n bottom: 0;\n right: 0;\n top: auto;\n left: auto;\n width: 16px;\n height: 16px;\n cursor: nwse-resize;\n border-radius: 0 0 6px 0;\n}\n\n#profiler-panel.position-floating .panel-resizer::after {\n content: '';\n position: absolute;\n right: 2px;\n bottom: 2px;\n width: 10px;\n height: 10px;\n background: linear-gradient(135deg, transparent 0%, transparent 45%, var(--profiler-border) 45%, var(--profiler-border) 55%, transparent 55%);\n}\n\n\n.panel-resizer {\n position: absolute;\n top: -2px;\n left: 0;\n width: 100%;\n height: 5px;\n cursor: ns-resize;\n z-index: 1001;\n touch-action: none;\n}\n\n#profiler-panel.position-top .panel-resizer {\n top: auto;\n bottom: -2px;\n}\n\n#profiler-panel.position-left .panel-resizer {\n top: 0;\n left: auto;\n right: -2px;\n width: 5px;\n height: 100%;\n cursor: ew-resize;\n}\n\n#profiler-panel.position-right .panel-resizer {\n top: 0;\n left: -2px;\n right: auto;\n width: 5px;\n height: 100%;\n cursor: ew-resize;\n}\n\n.profiler-header {\n display: flex;\n background-color: var(--profiler-header-bg);\n border-bottom: 1px solid var(--profiler-border);\n flex-shrink: 0;\n justify-content: space-between;\n align-items: stretch;\n\n overflow-x: auto;\n overflow-y: hidden;\n width: calc(100% - 134px);\n height: 38px;\n user-select: none;\n -webkit-user-select: none;\n}\n\n/* Adjust header width based on panel position */\n#profiler-panel.position-right .profiler-header,\n#profiler-panel.position-left .profiler-header {\n width: calc(100% - 134px);\n}\n\n#profiler-panel.position-bottom .profiler-header,\n#profiler-panel.position-top .profiler-header {\n width: calc(100% - 134px);\n}\n\n/* Adjust header width when position toggle button is hidden (mobile) */\n#profiler-panel.hide-position-toggle .profiler-header {\n width: calc(100% - 90px);\n}\n\n/* ===== RULES FOR WHEN THERE ARE NO TABS ===== */\n\n/* Horizontal mode (bottom/top) without tabs */\n#profiler-panel.position-bottom.no-tabs:not(.maximized),\n#profiler-panel.position-top.no-tabs:not(.maximized) {\n height: 38px !important;\n min-height: 38px !important;\n}\n\n#profiler-panel.position-bottom.no-tabs .profiler-header,\n#profiler-panel.position-top.no-tabs .profiler-header {\n width: 100%;\n height: 38px;\n border-bottom: none;\n}\n\n#profiler-panel.position-bottom.no-tabs .profiler-content-wrapper,\n#profiler-panel.position-top.no-tabs .profiler-content-wrapper {\n display: none;\n}\n\n#profiler-panel.position-bottom.no-tabs .panel-resizer,\n#profiler-panel.position-top.no-tabs .panel-resizer {\n display: none;\n}\n\n/* Vertical mode (right/left) without tabs */\n#profiler-panel.position-right.no-tabs:not(.maximized),\n#profiler-panel.position-left.no-tabs:not(.maximized) {\n width: 45px !important;\n min-width: 45px !important;\n}\n\n/* Vertical layout for header when no tabs */\n#profiler-panel.position-right.no-tabs .profiler-header,\n#profiler-panel.position-left.no-tabs .profiler-header {\n width: 100%;\n flex-direction: column;\n height: 100%;\n border-bottom: none;\n}\n\n/* Vertical layout for controls when no tabs */\n#profiler-panel.position-right.no-tabs .profiler-controls,\n#profiler-panel.position-left.no-tabs .profiler-controls {\n position: static;\n flex-direction: column-reverse;\n justify-content: flex-end;\n width: 100%;\n height: 100%;\n border-bottom: none;\n border-left: none;\n background: transparent;\n}\n\n#profiler-panel.position-right.no-tabs .profiler-controls button,\n#profiler-panel.position-left.no-tabs .profiler-controls button {\n width: 100%;\n height: 45px;\n border-left: none;\n border-top: none;\n border-bottom: 1px solid var(--profiler-border);\n}\n\n#profiler-panel.position-right.no-tabs .profiler-content-wrapper,\n#profiler-panel.position-left.no-tabs .profiler-content-wrapper {\n display: none;\n}\n\n#profiler-panel.position-right.no-tabs .profiler-tabs,\n#profiler-panel.position-left.no-tabs .profiler-tabs {\n display: none;\n}\n\n#profiler-panel.position-right.no-tabs .panel-resizer,\n#profiler-panel.position-left.no-tabs .panel-resizer {\n display: none;\n}\n\n/* Hide position toggle on mobile without tabs */\n#profiler-panel.hide-position-toggle.position-right.no-tabs:not(.maximized),\n#profiler-panel.hide-position-toggle.position-left.no-tabs:not(.maximized) {\n width: 45px !important;\n min-width: 45px !important;\n}\n\n/* Hide drag indicator on mobile devices */\n#profiler-panel.is-mobile .tab-btn.active::before {\n display: none;\n}\n\n.profiler-header::-webkit-scrollbar {\n width: 8px;\n height: 8px;\n}\n\n.profiler-header::-webkit-scrollbar-track {\n background: transparent;\n}\n\n.profiler-header::-webkit-scrollbar-thumb {\n background-color: rgba(0, 0, 0, 0.25);\n border-radius: 10px;\n transition: background 0.3s ease;\n}\n\n.profiler-header::-webkit-scrollbar-thumb:hover {\n background-color: rgba(0, 0, 0, 0.4);\n}\n\n.profiler-header::-webkit-scrollbar-corner {\n background: transparent;\n}\n\n#profiler-panel.dragging .profiler-header {\n cursor: grabbing !important;\n}\n\n#profiler-panel.dragging {\n opacity: 0.8;\n}\n\n.profiler-tabs {\n display: flex;\n cursor: grab;\n position: relative;\n}\n\n.profiler-tabs:active {\n cursor: grabbing;\n}\n\n.profiler-tabs::-webkit-scrollbar {\n width: 8px;\n height: 8px;\n}\n\n.profiler-tabs::-webkit-scrollbar-track {\n background: transparent;\n}\n\n.profiler-tabs::-webkit-scrollbar-thumb {\n background-color: rgba(0, 0, 0, 0.25);\n border-radius: 10px;\n transition: background 0.3s ease;\n}\n\n.profiler-tabs::-webkit-scrollbar-thumb:hover {\n background-color: rgba(0, 0, 0, 0.4);\n}\n\n.profiler-tabs::-webkit-scrollbar-corner {\n background: transparent;\n}\n\n.profiler-controls {\n display: flex;\n position: absolute;\n right: 0;\n top: 0;\n height: 38px;\n background: var(--profiler-header-bg);\n border-bottom: 1px solid var(--profiler-border);\n}\n\n.tab-btn {\n position: relative;\n background: transparent;\n border: none;\n /*border-right: 1px solid var(--profiler-border);*/\n color: var(--text-secondary);\n padding: 8px 18px;\n cursor: default;\n display: flex;\n align-items: center;\n font-family: var(--font-family);\n font-weight: 600;\n font-size: 14px;\n user-select: none;\n transition: opacity 0.2s, transform 0.2s;\n touch-action: pan-x;\n}\n\n.tab-btn.active {\n border-bottom: 2px solid var(--accent-color);\n color: white;\n}\n\n.tab-btn.active::before {\n content: '⋮⋮';\n position: absolute;\n left: 3px;\n top: calc(50% - .1rem);\n transform: translateY(-50%);\n color: var(--profiler-border);\n font-size: 18px;\n letter-spacing: -2px;\n opacity: 0.6;\n}\n\n.tab-btn.no-detach.active::before {\n display: none;\n}\n\n#floating-btn,\n#maximize-btn,\n#hide-panel-btn {\n background: transparent;\n border: none;\n border-left: 1px solid var(--profiler-border);\n color: var(--text-secondary);\n width: 45px;\n height: 100%;\n cursor: pointer;\n transition: all 0.2s;\n display: flex;\n align-items: center;\n justify-content: center;\n flex-shrink: 0;\n}\n\n/* Disable transitions in vertical mode to avoid broken animations */\n#profiler-panel.position-right #floating-btn,\n#profiler-panel.position-right #maximize-btn,\n#profiler-panel.position-right #hide-panel-btn,\n#profiler-panel.position-left #floating-btn,\n#profiler-panel.position-left #maximize-btn,\n#profiler-panel.position-left #hide-panel-btn {\n transition: background-color 0.2s, color 0.2s;\n}\n\n#floating-btn:hover,\n#maximize-btn:hover,\n#hide-panel-btn:hover {\n background-color: rgba(255, 255, 255, 0.1);\n color: var(--text-primary);\n}\n\n/* Hide maximize button when there are no tabs */\n#profiler-panel.position-right.no-tabs #maximize-btn,\n#profiler-panel.position-left.no-tabs #maximize-btn,\n#profiler-panel.position-bottom.no-tabs #maximize-btn,\n#profiler-panel.position-top.no-tabs #maximize-btn {\n display: none !important;\n}\n\n.profiler-content-wrapper {\n flex-grow: 1;\n overflow: hidden;\n position: relative;\n}\n\n.profiler-content {\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n overflow-y: auto;\n font-size: 13px;\n visibility: hidden;\n opacity: 0;\n transition: opacity 0.2s, visibility 0.2s;\n box-sizing: border-box;\n display: flex;\n flex-direction: column;\n user-select: none;\n -webkit-user-select: none;\n}\n\n.profiler-content.active {\n visibility: visible;\n opacity: 1;\n}\n\n.profiler-content {\n overflow: auto; /* make sure scrollbars can appear */\n}\n\n.profiler-content::-webkit-scrollbar {\n width: 8px;\n height: 8px;\n}\n\n.profiler-content::-webkit-scrollbar-track {\n background: transparent;\n}\n\n.profiler-content::-webkit-scrollbar-thumb {\n background-color: rgba(0, 0, 0, 0.25);\n border-radius: 10px;\n transition: background 0.3s ease;\n}\n\n.profiler-content::-webkit-scrollbar-thumb:hover {\n background-color: rgba(0, 0, 0, 0.4);\n}\n\n.profiler-content::-webkit-scrollbar-corner {\n background: transparent;\n}\n\n.profiler-content {\n scrollbar-width: thin; /* \"auto\" | \"thin\" */\n scrollbar-color: rgba(0, 0, 0, 0.25) transparent;\n}\n\n.list-item-row {\n display: grid;\n align-items: center;\n padding: 4px 8px;\n border-radius: 3px;\n transition: background-color 0.2s;\n gap: 10px;\n border-bottom: none;\n user-select: none;\n -webkit-user-select: none;\n}\n\n.parameters .list-item-row {\n min-height: 31px;\n}\n\n.mini-panel-content .parameters .list-item-row {\n min-height: 21px;\n}\n\n.list-item-wrapper {\n margin-top: 2px;\n margin-bottom: 2px;\n user-select: none;\n -webkit-user-select: none;\n}\n\n.list-item-wrapper:first-child {\n /*margin-top: 0;*/\n}\n\n.list-item-wrapper:not(.header-wrapper):nth-child(odd) > .list-item-row {\n background-color: rgba(0,0,0,0.1);\n}\n\n.list-item-wrapper.header-wrapper>.list-item-row {\n color: var(--accent-color);\n background-color: rgba(0, 170, 255, 0.1);\n}\n\n.list-item-wrapper.header-wrapper>.list-item-row>.list-item-cell:first-child {\n font-weight: 600;\n line-height: 1;\n}\n\n.list-item-row.collapsible,\n.list-item-row.actionable {\n cursor: pointer;\n}\n\n.list-item-row.collapsible {\n background-color: rgba(0, 170, 255, 0.15) !important;\n min-height: 23px;\n}\n\n.list-item-row.collapsible.alert,\n.list-item-row.alert {\n background-color: rgba(244, 67, 54, 0.1) !important;\n}\n\n@media (hover: hover) {\n\n .list-item-row:hover:not(.collapsible):not(.no-hover),\n .list-item-row:hover:not(.no-hover),\n .list-item-row.actionable:hover,\n .list-item-row.collapsible.actionable:hover {\n background-color: rgba(255, 255, 255, 0.05) !important;\n }\n\n .list-item-row.collapsible:hover {\n background-color: rgba(0, 170, 255, 0.25) !important;\n }\n\n}\n\n.list-item-cell {\n white-space: pre;\n display: flex;\n align-items: center;\n user-select: none;\n -webkit-user-select: none;\n}\n\n.list-item-cell:not(:first-child) {\n justify-content: flex-end;\n font-weight: 600;\n}\n\n.list-header {\n display: grid;\n align-items: center;\n padding: 4px 8px;\n font-weight: 600;\n color: var(--text-secondary);\n padding-bottom: 6px;\n border-bottom: 1px solid var(--profiler-border);\n margin-bottom: 5px;\n gap: 10px;\n user-select: none;\n -webkit-user-select: none;\n}\n\n.list-item-wrapper.section-start {\n margin-top: 5px;\n margin-bottom: 5px;\n}\n\n.list-header .list-header-cell:not(:first-child) {\n text-align: right;\n}\n\n.list-children-container {\n padding-left: 1.5em;\n overflow: hidden;\n transition: max-height 0.1s ease-out;\n margin-top: 2px;\n}\n\n.list-children-container.closed {\n max-height: 0;\n}\n\n.item-toggler {\n display: inline-block;\n margin-right: 0.8em;\n text-align: left;\n}\n\n.list-item-row.open .item-toggler::before {\n content: '-';\n}\n\n.list-item-row:not(.open) .item-toggler::before {\n content: '+';\n}\n\n.list-item-cell .value.good {\n color: var(--color-green);\n}\n\n.list-item-cell .value.warn {\n color: var(--color-yellow);\n}\n\n.list-item-cell .value.bad {\n color: var(--color-red);\n}\n\n.list-scroll-wrapper {\n width: max-content;\n min-width: 100%;\n display: flex;\n flex-direction: column;\n min-height: 100%;\n}\n\n.list-container.parameters .list-item-row:not(.collapsible) {\n}\n\n.graph-container {\n width: 100%;\n box-sizing: border-box;\n padding: 8px 0;\n position: relative;\n}\n\n.graph-svg {\n width: 100%;\n height: 80px;\n background-color: var(--profiler-header);\n border: 1px solid var(--profiler-border);\n border-radius: 4px;\n}\n\n.graph-path {\n stroke-width: 2;\n fill-opacity: 0.4;\n}\n\n.console-header {\n padding: 10px;\n border-bottom: 1px solid var(--profiler-border);\n display: flex;\n gap: 20px;\n flex-shrink: 0;\n align-items: center;\n justify-content: space-between;\n}\n\n.console-buttons-group {\n display: flex;\n gap: 20px;\n}\n\n.console-filter-input {\n background-color: var(--profiler-bg);\n border: 1px solid var(--profiler-border);\n color: var(--text-primary);\n border-radius: 4px;\n padding: 4px 8px;\n font-family: var(--font-mono);\n flex-grow: 1;\n max-width: 300px;\n border-radius: 15px;\n}\n\n.console-filter-input:focus {\n outline: none;\n border-color: var(--text-secondary);\n}\n\n.console-copy-button {\n background: transparent;\n border: none;\n color: var(--text-secondary);\n cursor: pointer;\n padding: 4px;\n display: flex;\n align-items: center;\n justify-content: center;\n border-radius: 4px;\n transition: color 0.2s, background-color 0.2s;\n}\n\n.console-copy-button:hover {\n color: var(--text-primary);\n background-color: var(--profiler-hover);\n}\n\n.console-copy-button.copied {\n color: var(--color-green);\n}\n\n#console-log {\n display: flex;\n flex-direction: column;\n gap: 4px;\n padding: 10px;\n overflow-y: auto;\n flex-grow: 1;\n user-select: text;\n -webkit-user-select: text;\n}\n\n.log-message {\n padding: 2px 5px;\n white-space: pre-wrap;\n word-break: break-all;\n border-radius: 3px;\n line-height: 1.5 !important;\n}\n\n.log-message.hidden {\n display: none;\n}\n\n.log-message.info {\n color: var(--text-primary);\n}\n\n.log-message.warn {\n color: var(--color-yellow);\n}\n\n.log-message.error {\n color: #f9dedc;\n background-color: rgba(244, 67, 54, 0.1);\n}\n\n.log-prefix {\n color: var(--text-secondary);\n margin-right: 8px;\n}\n\n.log-code {\n background-color: rgba(255, 255, 255, 0.1);\n border-radius: 3px;\n padding: 1px 4px;\n}\n\n.thumbnail-container {\n display: flex;\n align-items: center;\n}\n\n.thumbnail-svg {\n width: 40px;\n height: 22.5px;\n flex-shrink: 0;\n margin-right: 8px;\n}\n\n.param-control {\n display: flex;\n align-items: center;\n justify-content: flex-end;\n gap: 10px;\n width: 100%;\n}\n\n.param-control input,\n.param-control select,\n.param-control button {\n background-color: var(--profiler-bg);\n border: 1px solid var(--profiler-border);\n color: var(--text-primary);\n border-radius: 4px;\n padding: 4px 6px;\n padding-bottom: 2px;\n font-family: var(--font-mono);\n width: 100%;\n box-sizing: border-box;\n}\n\n.param-control input:focus {\n outline: none;\n border-color: var(--accent-color);\n}\n\n.param-control select {\n padding-top: 3px;\n padding-bottom: 1px;\n}\n\n.param-control input[type=\"number\"] {\n cursor: ns-resize;\n}\n\n.param-control input[type=\"color\"] {\n padding: 2px;\n}\n\n.param-control button {\n cursor: pointer;\n transition: background-color 0.2s;\n}\n\n.param-control button:hover {\n background-color: var(--profiler-header);\n}\n\n.param-control-vector {\n display: flex;\n gap: 5px;\n}\n\n.custom-checkbox {\n display: inline-flex;\n align-items: center;\n cursor: pointer;\n gap: 8px;\n will-change: transform;\n}\n\n.custom-checkbox input {\n display: none;\n}\n\n.custom-checkbox .checkmark {\n width: 14px;\n height: 14px;\n border: 1px solid var(--accent-color);\n border-radius: 3px;\n display: inline-flex;\n justify-content: center;\n align-items: center;\n transition: background-color 0.2s, border-color 0.2s;\n}\n\n.custom-checkbox .checkmark::after {\n content: '';\n width: 6px;\n height: 6px;\n background-color: var(--accent-color);\n border-radius: 1px;\n display: block;\n transform: scale(0);\n transition: transform 0.2s;\n}\n\n.custom-checkbox input:checked+.checkmark {\n border-color: var(--accent-color);\n}\n\n.custom-checkbox input:checked+.checkmark::after {\n transform: scale(1);\n}\n\n.param-control input[type=\"range\"] {\n -webkit-appearance: none;\n appearance: none;\n width: 100%;\n height: 16px;\n background: var(--profiler-header);\n border-radius: 5px;\n border: 1px solid var(--profiler-border);\n outline: none;\n padding: 0px;\n padding-top: 8px;\n}\n\n.param-control input[type=\"range\"]::-webkit-slider-thumb {\n -webkit-appearance: none;\n appearance: none;\n width: 18px;\n height: 18px;\n background: var(--profiler-bg);\n border: 1px solid var(--accent-color);\n border-radius: 3px;\n cursor: pointer;\n margin-top: -8px;\n}\n\n.param-control input[type=\"range\"]::-moz-range-thumb {\n width: 18px;\n height: 18px;\n background: var(--profiler-bg);\n border: 2px solid var(--accent-color);\n border-radius: 3px;\n cursor: pointer;\n}\n\n.param-control input[type=\"range\"]::-moz-range-track {\n width: 100%;\n height: 16px;\n background: var(--profiler-header);\n border-radius: 5px;\n border: 1px solid var(--profiler-border);\n}\n\n/* Override .param-control styles for mini-panel-content */\n.mini-panel-content input,\n.mini-panel-content select,\n.mini-panel-content button {\n padding: 2px 4px;\n height: 21px;\n line-height: 1.4;\n padding-top: 4px;\n}\n\n.mini-panel-content .param-control input,\n.mini-panel-content .param-control select,\n.mini-panel-content .param-control button {\n background-color: #1e1e24c2;\n line-height: 1.0;\n}\n\n.mini-panel-content .param-control select {\n padding: 2px 2px;\n padding-top: 3px;\n}\n\n.mini-panel-content .param-control input[type=\"number\"]::-webkit-outer-spin-button,\n.mini-panel-content .param-control input[type=\"number\"]::-webkit-inner-spin-button {\n -webkit-appearance: none;\n margin: 0;\n}\n\n.mini-panel-content .param-control input[type=\"number\"] {\n -moz-appearance: textfield;\n}\n\n.mini-panel-content .list-item-cell span {\n position: relative;\n top: 1px;\n margin-left: 2px;\n}\n\n.mini-panel-content .custom-checkbox .checkmark {\n width: 12px;\n height: 12px;\n margin-bottom: 2px;\n will-change: transform;\n}\n\n.mini-panel-content .list-container.parameters .list-item-row:not(.collapsible) {\n margin-bottom: 2px;\n}\n\n@media screen and (max-width: 450px) and (orientation: portrait) {\n\n .console-filter-input {\n max-width: 100px;\n }\n\n}\n\n/* Touch device optimizations */\n@media (hover: none) and (pointer: coarse) {\n\n .panel-resizer {\n top: -10px !important;\n height: 20px !important;\n }\n\n #profiler-panel.position-top .panel-resizer {\n top: auto !important;\n bottom: -10px !important;\n height: 20px !important;\n }\n\n #profiler-panel.position-left .panel-resizer {\n right: -10px !important;\n width: 20px !important;\n height: 100% !important;\n }\n\n #profiler-panel.position-right .panel-resizer {\n left: -10px !important;\n width: 20px !important;\n height: 100% !important;\n }\n\n .detached-tab-resizer-top,\n .detached-tab-resizer-bottom {\n height: 10px !important;\n }\n\n .detached-tab-resizer-left,\n .detached-tab-resizer-right {\n width: 10px !important;\n }\n\n}\n\n.drag-preview-indicator {\n position: fixed;\n background-color: rgba(0, 170, 255, 0.2);\n border: 2px dashed var(--accent-color);\n z-index: 999;\n pointer-events: none;\n transition: all 0.2s ease-out;\n}\n\n/* Detached Tab Windows */\n.detached-tab-panel {\n position: fixed;\n width: 500px;\n height: 400px;\n background: var(--profiler-bg);\n border: 1px solid var(--profiler-border);\n border-radius: 8px;\n box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);\n z-index: 1002;\n display: flex;\n flex-direction: column;\n backdrop-filter: blur(10px);\n overflow: hidden;\n opacity: 1;\n visibility: visible;\n transition: opacity 0.2s, visibility 0.2s;\n}\n\n#profiler-panel:not(.visible) ~ * .detached-tab-panel,\nbody:has(#profiler-panel:not(.visible)) .detached-tab-panel {\n opacity: 0;\n visibility: hidden;\n pointer-events: none;\n}\n\n.detached-tab-header {\n background: var(--profiler-header-bg);\n padding: 0 7px 0 15px;\n font-family: var(--font-family);\n font-size: 14px;\n color: var(--text-primary);\n font-weight: 600;\n display: flex;\n justify-content: space-between;\n align-items: center;\n border-bottom: 1px solid var(--profiler-border);\n cursor: grab;\n user-select: none;\n height: 38px;\n flex-shrink: 0;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n touch-action: none;\n}\n\n.detached-tab-header:active {\n cursor: grabbing;\n}\n\n.detached-header-controls {\n display: flex;\n gap: 5px;\n}\n\n.detached-reattach-btn {\n background: transparent;\n border: none;\n color: var(--text-secondary);\n font-family: var(--font-family);\n font-size: 18px;\n line-height: 1;\n cursor: pointer;\n padding: 4px 8px;\n border-radius: 4px;\n transition: all 0.2s;\n display: flex;\n align-items: center;\n justify-content: center;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n}\n\n.detached-reattach-btn:hover {\n background: rgba(0, 170, 255, 0.2);\n color: var(--accent-color);\n}\n\n.detached-tab-content {\n flex: 1;\n overflow: auto;\n position: relative;\n background: var(--profiler-bg);\n}\n\n.detached-tab-content::-webkit-scrollbar {\n width: 8px;\n height: 8px;\n}\n\n.detached-tab-content::-webkit-scrollbar-track {\n background: transparent;\n}\n\n.detached-tab-content::-webkit-scrollbar-thumb {\n background-color: rgba(0, 0, 0, 0.25);\n border-radius: 10px;\n transition: background 0.3s ease;\n}\n\n.detached-tab-content::-webkit-scrollbar-thumb:hover {\n background-color: rgba(0, 0, 0, 0.4);\n}\n\n.detached-tab-content::-webkit-scrollbar-corner {\n background: transparent;\n}\n\n.detached-tab-content .profiler-content {\n display: block !important;\n height: 100%;\n visibility: visible !important;\n opacity: 1 !important;\n position: relative !important;\n}\n\n.detached-tab-content .profiler-content > * {\n font-family: var(--font-mono);\n color: var(--text-primary);\n}\n\n.detached-tab-resizer {\n position: absolute;\n bottom: 0;\n right: 0;\n width: 20px;\n height: 20px;\n cursor: nwse-resize;\n z-index: 10;\n touch-action: none;\n}\n\n.detached-tab-resizer::after {\n content: '';\n position: absolute;\n bottom: 2px;\n right: 2px;\n width: 12px;\n height: 12px;\n border-right: 2px solid var(--profiler-border);\n border-bottom: 2px solid var(--profiler-border);\n border-bottom-right-radius: 6px;\n opacity: 0.5;\n}\n\n.detached-tab-resizer:hover::after {\n opacity: 1;\n border-color: var(--accent-color);\n}\n\n/* Edge resizers */\n.detached-tab-resizer-top {\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n height: 5px;\n cursor: ns-resize;\n z-index: 10;\n touch-action: none;\n}\n\n.detached-tab-resizer-right {\n position: absolute;\n top: 0;\n right: 0;\n bottom: 0;\n width: 5px;\n cursor: ew-resize;\n z-index: 10;\n touch-action: none;\n}\n\n.detached-tab-resizer-bottom {\n position: absolute;\n bottom: 0;\n left: 0;\n right: 0;\n height: 5px;\n cursor: ns-resize;\n z-index: 10;\n touch-action: none;\n}\n\n.detached-tab-resizer-left {\n position: absolute;\n top: 0;\n left: 0;\n bottom: 0;\n width: 5px;\n cursor: ew-resize;\n z-index: 10;\n touch-action: none;\n}\n\n/* Input number spin buttons - hide arrows */\n/* Chrome, Safari, Edge, Opera */\n#profiler-panel input[type=\"number\"]::-webkit-outer-spin-button,\n#profiler-panel input[type=\"number\"]::-webkit-inner-spin-button,\n.detached-tab-content input[type=\"number\"]::-webkit-outer-spin-button,\n.detached-tab-content input[type=\"number\"]::-webkit-inner-spin-button {\n -webkit-appearance: none;\n margin: 0;\n}\n\n/* Firefox */\n#profiler-panel input[type=\"number\"],\n.detached-tab-content input[type=\"number\"] {\n -moz-appearance: textfield;\n}\n\n.panel-action-btn {\n background: transparent;\n color: var(--text-primary);\n border: 1px solid var(--profiler-border);\n border-radius: 4px;\n padding: 6px 12px;\n cursor: pointer;\n font-family: var(--font-family);\n font-size: 12px;\n transition: background-color 0.2s;\n display: flex;\n align-items: center;\n justify-content: center;\n}\n\n.panel-action-btn:hover {\n background-color: rgba(255, 255, 255, 0.05);\n}\n", document.head.appendChild(e);
246
246
  }
247
- }, Wt = class extends E {
247
+ }, Kt = class extends E {
248
248
  constructor(e) {
249
- super(), this.inspector = e, this.tabs = {}, this.activeTabId = null, this.isResizing = !1, this.lastHeightBottom = 350, this.lastWidthRight = 450, this.position = "bottom", this.detachedWindows = [], this.maxZIndex = 1002, this.nextTabOriginalIndex = 0, Ut.init(), this.setupShell(), this.setupResizing(), this.setupWindowResizeListener(), this.setupOrientationListener();
249
+ super(), this.inspector = e, this.tabs = {}, this.activeTabId = null, this.isResizing = !1, this.lastHeightBottom = 350, this.lastWidthRight = 450, this.position = "bottom", this.detachedWindows = [], this.maxZIndex = 1002, this.nextTabOriginalIndex = 0, Gt.init(), this.setupShell(), this.setupResizing(), this.setupWindowResizeListener(), this.setupOrientationListener();
250
250
  }
251
251
  getSize() {
252
252
  return this.panel.classList.contains("visible") === !1 || this.panel.classList.contains("no-tabs") ? {
@@ -604,7 +604,7 @@ var U = /* @__PURE__ */ new xe(), Mt = /* @__PURE__ */ new k(), Nt = /* @__PURE_
604
604
  });
605
605
  });
606
606
  try {
607
- xn("layout", e);
607
+ wn("layout", e);
608
608
  } catch (e) {
609
609
  console.warn("Failed to save profiler layout:", e);
610
610
  }
@@ -612,7 +612,7 @@ var U = /* @__PURE__ */ new xe(), Mt = /* @__PURE__ */ new k(), Nt = /* @__PURE_
612
612
  loadLayout() {
613
613
  this.isLoadingLayout = !0;
614
614
  try {
615
- let e = bn("layout");
615
+ let e = Cn("layout");
616
616
  if (Object.keys(e).length === 0) return;
617
617
  if (e.detachedTabs && e.detachedTabs.length > 0) {
618
618
  let t = window.innerWidth, n = window.innerHeight;
@@ -659,7 +659,7 @@ var U = /* @__PURE__ */ new xe(), Mt = /* @__PURE__ */ new k(), Nt = /* @__PURE_
659
659
  this.updatePanelSize();
660
660
  }
661
661
  }
662
- }, G = class extends E {
662
+ }, qt = class extends E {
663
663
  constructor(e, t = {}) {
664
664
  super(), this.id = e.toLowerCase(), this.button = document.createElement("button"), this.button.className = "tab-btn", this.button.textContent = e, this.content = document.createElement("div"), this.content.id = `${this.id}-content`, this.content.className = "profiler-content", this._isActive = !1, this.isVisible = !0, this.isDetached = !1, this.detachedWindow = null, this.allowDetach = t.allowDetach === void 0 ? !0 : t.allowDetach, this.builtin = t.builtin === void 0 ? !1 : t.builtin, this.icon = t.icon || null, this.builtinButton = null, this.miniContent = null, this.profiler = null, this.onVisibilityChange = null;
665
665
  }
@@ -699,7 +699,7 @@ var U = /* @__PURE__ */ new xe(), Mt = /* @__PURE__ */ new k(), Nt = /* @__PURE_
699
699
  this.builtinButton && this.builtinButton.classList.remove("active"), this.profiler && (Array.from(this.profiler.miniPanel.querySelectorAll(".mini-panel-content")).some((e) => e.style.display !== "none") || this.profiler.miniPanel.classList.remove("visible"), Array.from(this.profiler.builtinTabsContainer.querySelectorAll(".builtin-tab-btn")).some((e) => e.style.display !== "none") || (this.profiler.builtinTabsContainer.style.display = "none"));
700
700
  }
701
701
  }
702
- }, Gt = class {
702
+ }, Jt = class {
703
703
  constructor(...e) {
704
704
  this.headers = e, this.children = [], this.domElement = document.createElement("div"), this.domElement.className = "list-container", this.domElement.style.padding = "10px", this.id = `list-${Math.random().toString(36).slice(2, 11)}`, this.domElement.dataset.listId = this.id, this.gridStyleElement = document.createElement("style"), this.domElement.appendChild(this.gridStyleElement);
705
705
  let t = document.createElement("div");
@@ -723,7 +723,7 @@ var U = /* @__PURE__ */ new xe(), Mt = /* @__PURE__ */ new k(), Nt = /* @__PURE_
723
723
  let t = this.children.indexOf(e);
724
724
  return t !== -1 && (this.children.splice(t, 1), this.domElement.removeChild(e.domElement), e.parent = null), this;
725
725
  }
726
- }, Kt = class {
726
+ }, Yt = class {
727
727
  constructor(e = 512) {
728
728
  this.maxPoints = e, this.lines = {}, this.limit = 0, this.limitIndex = 0, this.domElement = document.createElementNS("http://www.w3.org/2000/svg", "svg"), this.domElement.setAttribute("class", "graph-svg");
729
729
  }
@@ -796,7 +796,7 @@ function J(e, t) {
796
796
  let n = e instanceof HTMLElement ? e : document.getElementById(e);
797
797
  n && n.textContent !== t && (n.textContent = t);
798
798
  }
799
- function qt(e) {
799
+ function Xt(e) {
800
800
  let t = e.lastIndexOf("/");
801
801
  return t === -1 ? {
802
802
  path: "",
@@ -806,7 +806,7 @@ function qt(e) {
806
806
  name: e.substring(t + 1).trim()
807
807
  };
808
808
  }
809
- function Jt(e) {
809
+ function Zt(e) {
810
810
  return e.replace(/([a-z0-9])([A-Z])/g, "$1 $2").trim();
811
811
  }
812
812
  function Y(e, t = 2) {
@@ -826,16 +826,16 @@ function Y(e, t = 2) {
826
826
  }
827
827
  //#endregion
828
828
  //#region ../../node_modules/three/examples/jsm/inspector/tabs/Performance.js
829
- var Yt = class extends G {
829
+ var Qt = class extends qt {
830
830
  constructor(e = {}) {
831
831
  super("Performance", e);
832
- let t = new Gt("Name", "CPU", "GPU", "Total");
832
+ let t = new Jt("Name", "CPU", "GPU", "Total");
833
833
  t.setGridStyle("minmax(200px, 2fr) 80px 80px 80px"), t.domElement.style.minWidth = "600px";
834
834
  let n = document.createElement("div");
835
835
  n.className = "list-scroll-wrapper", n.appendChild(t.domElement), this.content.appendChild(n);
836
836
  let r = document.createElement("div");
837
837
  r.className = "graph-container";
838
- let i = new Kt();
838
+ let i = new Yt();
839
839
  i.addLine("fps", "var( --color-fps )"), r.append(i.domElement);
840
840
  let a = new K("Graph Stats", q(), q(), q("graph-fps-counter"));
841
841
  t.add(a);
@@ -885,16 +885,16 @@ var Yt = class extends G {
885
885
  for (let e of this.notInUse.keys()) this.updateNotInUse(e);
886
886
  J("graph-fps-counter", e.fps.toFixed() + " FPS"), J(this.frameStats.data[1], t.cpu.toFixed(2)), J(this.frameStats.data[2], t.gpu.toFixed(2)), J(this.frameStats.data[3], t.total.toFixed(2)), J(this.miscellaneous.data[1], t.miscellaneous.toFixed(2)), J(this.miscellaneous.data[2], "-"), J(this.miscellaneous.data[3], t.miscellaneous.toFixed(2)), this.currentItem = null;
887
887
  }
888
- }, Xt = class extends G {
888
+ }, $t = class extends qt {
889
889
  constructor(e = {}) {
890
890
  super("Memory", e);
891
- let t = new Gt("Name", "Count", "Size");
891
+ let t = new Jt("Name", "Count", "Size");
892
892
  t.setGridStyle("minmax(200px, 2fr) 60px 100px"), t.domElement.style.minWidth = "300px";
893
893
  let n = document.createElement("div");
894
894
  n.className = "list-scroll-wrapper", n.appendChild(t.domElement), this.content.appendChild(n);
895
895
  let r = document.createElement("div");
896
896
  r.className = "graph-container";
897
- let i = new Kt();
897
+ let i = new Yt();
898
898
  i.addLine("total", "var( --color-yellow )"), r.append(i.domElement);
899
899
  let a = new K("Graph Stats", "", "");
900
900
  t.add(a);
@@ -913,7 +913,7 @@ var Yt = class extends G {
913
913
  let n = t.info.memory;
914
914
  J(this.memoryStats.data[2], Y(n.total)), J(this.attributes.data[1], n.attributes.toString()), J(this.attributes.data[2], Y(n.attributesSize)), J(this.geometries.data[1], n.geometries.toString()), J(this.indexAttributes.data[1], n.indexAttributes.toString()), J(this.indexAttributes.data[2], Y(n.indexAttributesSize)), J(this.indirectStorageAttributes.data[1], n.indirectStorageAttributes.toString()), J(this.indirectStorageAttributes.data[2], Y(n.indirectStorageAttributesSize)), J(this.programs.data[1], n.programs.toString()), J(this.programs.data[2], Y(n.programsSize)), J(this.readbackBuffers.data[1], n.readbackBuffers.toString()), J(this.readbackBuffers.data[2], Y(n.readbackBuffersSize)), J(this.renderTargets.data[1], n.renderTargets.toString()), J(this.storageAttributes.data[1], n.storageAttributes.toString()), J(this.storageAttributes.data[2], Y(n.storageAttributesSize)), J(this.textures.data[1], n.textures.toString()), J(this.textures.data[2], Y(n.texturesSize));
915
915
  }
916
- }, Zt = class extends G {
916
+ }, en = class extends qt {
917
917
  constructor(e = {}) {
918
918
  super("Console", e), this.filters = {
919
919
  info: !0,
@@ -1007,7 +1007,7 @@ var Yt = class extends G {
1007
1007
  onChange(e) {
1008
1008
  return this._onChangeFunction = e, this;
1009
1009
  }
1010
- }, Qt = class extends X {
1010
+ }, tn = class extends X {
1011
1011
  constructor({ value: e = 0, step: t = .1, min: n = -Infinity, max: r = Infinity }) {
1012
1012
  super(), this.input = document.createElement("input"), this.input.type = "number", this.input.value = e, this.input.step = t, this.input.min = n, this.input.max = r, this.input.addEventListener("change", this._onChangeValue.bind(this)), this.domElement.appendChild(this.input), this.addDragHandler();
1013
1013
  }
@@ -1038,7 +1038,7 @@ var Yt = class extends G {
1038
1038
  getValue() {
1039
1039
  return parseFloat(this.input.value);
1040
1040
  }
1041
- }, $t = class extends X {
1041
+ }, nn = class extends X {
1042
1042
  constructor({ value: e = !1 }) {
1043
1043
  super();
1044
1044
  let t = document.createElement("label");
@@ -1056,10 +1056,10 @@ var Yt = class extends G {
1056
1056
  getValue() {
1057
1057
  return this.checkbox.checked;
1058
1058
  }
1059
- }, en = class extends X {
1059
+ }, rn = class extends X {
1060
1060
  constructor({ value: e = 0, min: t = 0, max: n = 1, step: r = .01 }) {
1061
1061
  super(), this.slider = document.createElement("input"), this.slider.type = "range", this.slider.min = t, this.slider.max = n, this.slider.step = r;
1062
- let i = new Qt({
1062
+ let i = new tn({
1063
1063
  value: e,
1064
1064
  min: t,
1065
1065
  max: n,
@@ -1080,7 +1080,7 @@ var Yt = class extends G {
1080
1080
  step(e) {
1081
1081
  return this.slider.step = e, this.numberInput.step = e, this;
1082
1082
  }
1083
- }, tn = class extends X {
1083
+ }, an = class extends X {
1084
1084
  constructor({ options: e = [], value: t = "" }) {
1085
1085
  super();
1086
1086
  let n = document.createElement("select"), r = (e, r) => {
@@ -1095,7 +1095,7 @@ var Yt = class extends G {
1095
1095
  let e = this.options;
1096
1096
  return Array.isArray(e) ? e[this.select.selectedIndex] : e[this.select.value];
1097
1097
  }
1098
- }, nn = class extends X {
1098
+ }, on = class extends X {
1099
1099
  constructor({ value: e = "#ffffff" }) {
1100
1100
  super();
1101
1101
  let t = document.createElement("input");
@@ -1111,13 +1111,13 @@ var Yt = class extends G {
1111
1111
  let e = this._value;
1112
1112
  return typeof e == "string" && (e = parseInt(e.slice(1), 16)), e;
1113
1113
  }
1114
- }, rn = class extends X {
1114
+ }, sn = class extends X {
1115
1115
  constructor({ text: e = "Button", value: t = () => {} }) {
1116
1116
  super();
1117
1117
  let n = document.createElement("button");
1118
1118
  n.textContent = e, n.onclick = t, this.domElement.appendChild(n);
1119
1119
  }
1120
- }, an = class extends X {
1120
+ }, cn = class extends X {
1121
1121
  constructor({ value: e = "" }) {
1122
1122
  super();
1123
1123
  let t = document.createElement("input");
@@ -1131,7 +1131,7 @@ var Yt = class extends G {
1131
1131
  getValue() {
1132
1132
  return this.input.value;
1133
1133
  }
1134
- }, on = class e {
1134
+ }, ln = class e {
1135
1135
  constructor(e, t) {
1136
1136
  this.parameters = e, this.name = t, this.paramList = new K(t), this.objects = [];
1137
1137
  }
@@ -1160,7 +1160,7 @@ var Yt = class extends G {
1160
1160
  });
1161
1161
  }
1162
1162
  addString(e, t) {
1163
- let n = e[t], r = new an({ value: n });
1163
+ let n = e[t], r = new cn({ value: n });
1164
1164
  r.addEventListener("change", ({ value: n }) => {
1165
1165
  e[t] = n;
1166
1166
  });
@@ -1174,7 +1174,7 @@ var Yt = class extends G {
1174
1174
  return this.paramList.add(n.paramList), n;
1175
1175
  }
1176
1176
  addBoolean(e, t) {
1177
- let n = e[t], r = new $t({ value: n });
1177
+ let n = e[t], r = new nn({ value: n });
1178
1178
  r.addEventListener("change", ({ value: n }) => {
1179
1179
  e[t] = n;
1180
1180
  });
@@ -1190,7 +1190,7 @@ var Yt = class extends G {
1190
1190
  }), this._addParameter(e, t, r, a), r;
1191
1191
  }
1192
1192
  addSelect(e, t, n) {
1193
- let r = e[t], i = new tn({
1193
+ let r = e[t], i = new an({
1194
1194
  options: n,
1195
1195
  value: r
1196
1196
  });
@@ -1203,7 +1203,7 @@ var Yt = class extends G {
1203
1203
  return this.paramList.add(o), o.domElement.firstChild.classList.add("actionable"), this._addParameter(e, t, i, o), i;
1204
1204
  }
1205
1205
  addColor(e, t) {
1206
- let n = e[t], r = new nn({ value: n });
1206
+ let n = e[t], r = new on({ value: n });
1207
1207
  r.addEventListener("change", ({ value: n }) => {
1208
1208
  e[t] = n;
1209
1209
  });
@@ -1213,7 +1213,7 @@ var Yt = class extends G {
1213
1213
  return this.paramList.add(a), a.domElement.firstChild.classList.add("actionable"), this._addParameter(e, t, r, a), r;
1214
1214
  }
1215
1215
  addSlider(e, t, n = 0, r = 1, i = .01) {
1216
- let a = e[t], o = new en({
1216
+ let a = e[t], o = new rn({
1217
1217
  value: a,
1218
1218
  min: n,
1219
1219
  max: r,
@@ -1228,7 +1228,7 @@ var Yt = class extends G {
1228
1228
  return this.paramList.add(c), c.domElement.firstChild.classList.add("actionable"), this._addParameter(e, t, o, c), o;
1229
1229
  }
1230
1230
  addNumber(e, t, ...n) {
1231
- let r = e[t], [i, a] = n, o = new Qt({
1231
+ let r = e[t], [i, a] = n, o = new tn({
1232
1232
  value: r,
1233
1233
  min: i,
1234
1234
  max: a
@@ -1242,7 +1242,7 @@ var Yt = class extends G {
1242
1242
  return this.paramList.add(c), c.domElement.firstChild.classList.add("actionable"), this._addParameter(e, t, o, c), o;
1243
1243
  }
1244
1244
  addButton(e, t) {
1245
- let n = e[t], r = new rn({
1245
+ let n = e[t], r = new sn({
1246
1246
  text: t,
1247
1247
  value: n
1248
1248
  });
@@ -1252,54 +1252,54 @@ var Yt = class extends G {
1252
1252
  let i = new K(r.domElement);
1253
1253
  return i.itemRow.childNodes[0].style.gridColumn = "1 / -1", this.paramList.add(i), i.domElement.firstChild.classList.add("actionable"), r.name = (e) => (r.domElement.childNodes[0].textContent = e, r), this._registerParameter(e, t, r, i), r;
1254
1254
  }
1255
- }, sn = class extends G {
1255
+ }, un = class extends qt {
1256
1256
  constructor(e = {}) {
1257
1257
  super(e.name || "Parameters", e);
1258
- let t = new Gt("Property", "Value");
1258
+ let t = new Jt("Property", "Value");
1259
1259
  t.domElement.classList.add("parameters"), t.setGridStyle(".5fr 1fr"), t.domElement.style.minWidth = "300px";
1260
1260
  let n = document.createElement("div");
1261
1261
  n.className = "list-scroll-wrapper", n.appendChild(t.domElement), this.content.appendChild(n), this.paramList = t, this.groups = [];
1262
1262
  }
1263
1263
  createGroup(e) {
1264
- let t = new on(this, e);
1264
+ let t = new ln(this, e);
1265
1265
  return this.paramList.add(t.paramList), this.groups.push(t), t;
1266
1266
  }
1267
- }, cn = "../extensions/extensions.json", ln = _e.prototype.init;
1268
- function un(e) {
1267
+ }, dn = "../extensions/extensions.json", fn = _e.prototype.init;
1268
+ function pn(e) {
1269
1269
  e ? _e.prototype.init = async function() {
1270
1270
  if (this.backend.isWebGLBackend !== !0) {
1271
1271
  let e = this.backend.parameters;
1272
1272
  this.backend = new be(e);
1273
1273
  }
1274
- return ln.call(this);
1275
- } : _e.prototype.init = ln;
1274
+ return fn.call(this);
1275
+ } : _e.prototype.init = fn;
1276
1276
  }
1277
1277
  var Z = null;
1278
- function dn() {
1278
+ function mn() {
1279
1279
  if (Z !== null) return Z;
1280
- let e = bn("settings");
1280
+ let e = Cn("settings");
1281
1281
  return Z = {
1282
1282
  forceWebGL: e.forceWebGL === void 0 ? !1 : e.forceWebGL,
1283
1283
  captureStackTrace: e.captureStackTrace === void 0 ? !1 : e.captureStackTrace,
1284
1284
  activeExtensions: e.activeExtensions === void 0 ? {} : e.activeExtensions
1285
- }, Z.forceWebGL && un(!0), Z.captureStackTrace && (ye.captureStackTrace = !0), Z;
1285
+ }, Z.forceWebGL && pn(!0), Z.captureStackTrace && (ye.captureStackTrace = !0), Z;
1286
1286
  }
1287
- function fn() {
1288
- xn("settings", {
1287
+ function hn() {
1288
+ wn("settings", {
1289
1289
  forceWebGL: Z.forceWebGL,
1290
1290
  captureStackTrace: Z.captureStackTrace,
1291
1291
  activeExtensions: Z.activeExtensions
1292
1292
  });
1293
1293
  }
1294
- dn();
1295
- var pn = class extends sn {
1294
+ mn();
1295
+ var gn = class extends un {
1296
1296
  constructor() {
1297
1297
  super({ name: "Settings" }), this.extensions = {};
1298
- let e = dn(), t = this.createGroup("Renderer");
1298
+ let e = mn(), t = this.createGroup("Renderer");
1299
1299
  t.add(e, "forceWebGL").name("Force WebGL").onChange((e) => {
1300
- un(e), fn(), location.reload();
1300
+ pn(e), hn(), location.reload();
1301
1301
  }), t.add(e, "captureStackTrace").name("Capture Stack Trace").onChange((e) => {
1302
- ye.captureStackTrace = e, fn(), location.reload();
1302
+ ye.captureStackTrace = e, hn(), location.reload();
1303
1303
  });
1304
1304
  }
1305
1305
  init() {
@@ -1309,7 +1309,7 @@ var pn = class extends sn {
1309
1309
  this.setActiveExtension(n.name, e), e ? Z.activeExtensions[n.name] = {
1310
1310
  name: n.name,
1311
1311
  url: n.url
1312
- } : delete Z.activeExtensions[n.name], this._updateExtensionUI(n), fn();
1312
+ } : delete Z.activeExtensions[n.name], this._updateExtensionUI(n), hn();
1313
1313
  }), Z.activeExtensions[n.name] !== void 0 && n.ui.setValue(!0);
1314
1314
  });
1315
1315
  }
@@ -1329,7 +1329,7 @@ var pn = class extends sn {
1329
1329
  async _loadExtension(e, t) {
1330
1330
  if (t.active === !0) return;
1331
1331
  t.active = !0;
1332
- let n = await import(new URL(t.url, new URL(cn, import.meta.url)).href), r = n[Object.keys(n)[0]], i = new r();
1332
+ let n = await import(new URL(t.url, new URL(dn, import.meta.url)).href), r = n[Object.keys(n)[0]], i = new r();
1333
1333
  e.addTab(i), t.loaded = !0, t.tab = i, this._updateExtensionUI(t), this.dispatchEvent({
1334
1334
  type: "extensionadded",
1335
1335
  name: t.name,
@@ -1337,21 +1337,21 @@ var pn = class extends sn {
1337
1337
  });
1338
1338
  }
1339
1339
  async _getExtensions() {
1340
- let e = new URL(cn, import.meta.url);
1340
+ let e = new URL(dn, import.meta.url);
1341
1341
  return await fetch(e).then((e) => e.json());
1342
1342
  }
1343
- }, mn = /* @__PURE__ */ z(([e, t]) => {
1343
+ }, _n = /* @__PURE__ */ V(([e, t]) => {
1344
1344
  let n = I(0);
1345
- St(() => {
1345
+ Ct(() => {
1346
1346
  let { width: e, height: r } = t.value;
1347
1347
  n.value = e / r;
1348
1348
  });
1349
- let r = e.sub(.5), i = B(r.x.div(n), r.y).add(.5);
1350
- return H(i, ft(0, i.x).mul(ft(i.x, 1)).mul(ft(0, i.y)).mul(ft(i.y, 1)));
1351
- }), hn = class extends G {
1349
+ let r = e.sub(.5), i = L(r.x.div(n), r.y).add(.5);
1350
+ return U(i, rt(0, i.x).mul(rt(i.x, 1)).mul(rt(0, i.y)).mul(rt(i.y, 1)));
1351
+ }), vn = class extends qt {
1352
1352
  constructor(e = {}) {
1353
1353
  super("Viewer", e);
1354
- let t = new Gt("Viewer", "Name");
1354
+ let t = new Jt("Viewer", "Name");
1355
1355
  t.setGridStyle("150px minmax(200px, 2fr)"), t.domElement.style.minWidth = "400px";
1356
1356
  let n = document.createElement("div");
1357
1357
  n.className = "list-scroll-wrapper", n.appendChild(t.domElement), this.content.appendChild(n);
@@ -1375,12 +1375,12 @@ var pn = class extends sn {
1375
1375
  if (n === void 0) {
1376
1376
  let r = new Ce(document.createElement("canvas"));
1377
1377
  r.setPixelRatio(window.devicePixelRatio), r.setSize(140, 140);
1378
- let i = t.id, { path: a, name: o } = qt(Jt(t.getName() || "(unnamed)")), s = P(H(t.context({ getUV: (e) => {
1379
- let t = mn(xt, e), n = t.xy, r = t.z;
1378
+ let i = t.id, { path: a, name: o } = Xt(Zt(t.getName() || "(unnamed)")), s = F(U(t.context({ getUV: (e) => {
1379
+ let t = _n(Qe, e), n = t.xy, r = t.z;
1380
1380
  return n.mul(r);
1381
1381
  } })), 1);
1382
- s = it(s, 0, e.outputColorSpace), s = s.context({ inspector: !0 });
1383
- let c = new A();
1382
+ s = ht(s, 0, e.outputColorSpace), s = s.context({ inspector: !0 });
1383
+ let c = new j();
1384
1384
  c.outputNode = s;
1385
1385
  let l = new xe(c);
1386
1386
  l.name = "Viewer - " + o, n = {
@@ -1418,13 +1418,13 @@ var pn = class extends sn {
1418
1418
  a[o] === void 0 && (a[o] = 0), (e.parent === null || n.parent !== e || e.children.indexOf(n) !== a[o]) && e.add(n), a[o]++;
1419
1419
  } else n.parent || this.nodes.add(n);
1420
1420
  this.currentDataList = r;
1421
- let s = j.resetRendererState(t);
1422
- t.toneMapping = 0, t.outputColorSpace = u, t.setCanvasTarget(e.canvasTarget), e.quad.render(t), t.setCanvasTarget(i), j.restoreRendererState(t, s);
1421
+ let s = M.resetRendererState(t);
1422
+ t.toneMapping = 0, t.outputColorSpace = u, t.setCanvasTarget(e.canvasTarget), e.quad.render(t), t.setCanvasTarget(i), M.restoreRendererState(t, s);
1423
1423
  }
1424
1424
  }
1425
- }, gn = 500, _n = 60, vn = class extends G {
1425
+ }, yn = 500, bn = 60, xn = class extends qt {
1426
1426
  constructor(e = {}) {
1427
- super("Timeline", e), this.isRecording = !1, this.frames = [], this.baseTriangles = 0, this.currentFrame = null, this.isHierarchicalView = !0, this.callBlocks = /* @__PURE__ */ new WeakMap(), this.fallbackBlocks = [], this.originalBackend = null, this.originalMethods = /* @__PURE__ */ new Map(), this.renderer = null, this.graph = new Kt(gn), this.graph.addLine("fps", "var( --color-fps )"), this.graph.addLine("calls", "var( --color-call )"), this.graph.addLine("triangles", "var( --color-red )");
1427
+ super("Timeline", e), this.isRecording = !1, this.frames = [], this.baseTriangles = 0, this.currentFrame = null, this.isHierarchicalView = !0, this.callBlocks = /* @__PURE__ */ new WeakMap(), this.fallbackBlocks = [], this.originalBackend = null, this.originalMethods = /* @__PURE__ */ new Map(), this.renderer = null, this.graph = new Yt(yn), this.graph.addLine("fps", "var( --color-fps )"), this.graph.addLine("calls", "var( --color-call )"), this.graph.addLine("triangles", "var( --color-red )");
1428
1428
  let t = document.createElement("div");
1429
1429
  t.className = "list-scroll-wrapper", this.scrollWrapper = t, this.content.appendChild(t), this.buildHeader(), this.buildUI(), window.addEventListener("resize", () => {
1430
1430
  !this.isRecording && this.frames.length > 0 && this.renderSlider();
@@ -1437,8 +1437,8 @@ var pn = class extends sn {
1437
1437
  t.className = "console-copy-button", t.title = "Clear", t.innerHTML = "<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"14\" height=\"14\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><polyline points=\"3 6 5 6 21 6\"></polyline><path d=\"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6m3 0V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2\"></path><line x1=\"10\" y1=\"11\" x2=\"10\" y2=\"17\"></line><line x1=\"14\" y1=\"11\" x2=\"14\" y2=\"17\"></line></svg>", t.style.padding = "0 10px", t.style.lineHeight = "24px", t.style.display = "flex", t.style.alignItems = "center", t.addEventListener("click", () => this.clear()), this.viewModeButton = document.createElement("button"), this.viewModeButton.className = "console-copy-button", this.viewModeButton.title = "Toggle View Mode", this.viewModeButton.textContent = "Mode: Hierarchy", this.viewModeButton.style.padding = "0 10px", this.viewModeButton.style.lineHeight = "24px", this.viewModeButton.addEventListener("click", () => {
1438
1438
  this.isHierarchicalView = !this.isHierarchicalView, this.viewModeButton.textContent = this.isHierarchicalView ? "Mode: Hierarchy" : "Mode: Counts", this.selectedFrameIndex !== void 0 && this.selectedFrameIndex !== -1 && this.selectFrame(this.selectedFrameIndex);
1439
1439
  }), this.recordRefreshButton = document.createElement("button"), this.recordRefreshButton.className = "console-copy-button", this.recordRefreshButton.title = "Refresh & Record", this.recordRefreshButton.innerHTML = "<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"14\" height=\"14\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><path d=\"M21 12a9 9 0 1 1-9-9c2.52 0 4.93 1 6.74 2.74L21 8\"></path><path d=\"M21 3v5h-5\"></path><circle cx=\"12\" cy=\"12\" r=\"3\" fill=\"currentColor\"></circle></svg>", this.recordRefreshButton.style.padding = "0 10px", this.recordRefreshButton.style.lineHeight = "24px", this.recordRefreshButton.style.display = "flex", this.recordRefreshButton.style.alignItems = "center", this.recordRefreshButton.addEventListener("click", () => {
1440
- let e = bn("timeline");
1441
- e.recording = !0, xn("timeline", e), window.location.reload();
1440
+ let e = Cn("timeline");
1441
+ e.recording = !0, wn("timeline", e), window.location.reload();
1442
1442
  }), this.exportButton = document.createElement("button"), this.exportButton.className = "console-copy-button", this.exportButton.title = "Export", this.exportButton.innerHTML = "<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"14\" height=\"14\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><path d=\"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4\"></path><polyline points=\"7 10 12 15 17 10\"></polyline><line x1=\"12\" y1=\"15\" x2=\"12\" y2=\"3\"></line></svg>", this.exportButton.style.padding = "0 10px", this.exportButton.style.lineHeight = "24px", this.exportButton.style.display = "flex", this.exportButton.style.alignItems = "center", this.exportButton.addEventListener("click", () => this.exportData());
1443
1443
  let n = document.createElement("div");
1444
1444
  n.className = "console-buttons-group", n.appendChild(this.viewModeButton), n.appendChild(this.recordButton), n.appendChild(this.recordRefreshButton), n.appendChild(this.exportButton), n.appendChild(t), e.style.display = "flex", e.style.justifyContent = "space-between", e.style.padding = "6px", e.style.borderBottom = "1px solid var(--border-color)";
@@ -1520,8 +1520,8 @@ var pn = class extends sn {
1520
1520
  }
1521
1521
  setRenderer(e) {
1522
1522
  this.renderer = e;
1523
- let t = bn("timeline");
1524
- t.recording && (t.recording = !1, xn("timeline", t), this.toggleRecording());
1523
+ let t = Cn("timeline");
1524
+ t.recording && (t.recording = !1, wn("timeline", t), this.toggleRecording());
1525
1525
  }
1526
1526
  toggleRecording() {
1527
1527
  if (!this.renderer) {
@@ -1551,7 +1551,7 @@ var pn = class extends sn {
1551
1551
  for (let t = 0; t < n.length; t++) n[t] *= e;
1552
1552
  }
1553
1553
  }
1554
- let t = this.baseTriangles > 0 ? e / this.baseTriangles * _n : 0;
1554
+ let t = this.baseTriangles > 0 ? e / this.baseTriangles * bn : 0;
1555
1555
  this.graph.addPoint("calls", this.currentFrame.calls.length), this.graph.addPoint("fps", this.currentFrame.fps), this.graph.addPoint("triangles", t), this.graph.update();
1556
1556
  }
1557
1557
  if (this.currentFrame = {
@@ -1559,7 +1559,7 @@ var pn = class extends sn {
1559
1559
  calls: [],
1560
1560
  fps: 0,
1561
1561
  triangles: 0
1562
- }, this.frames.push(this.currentFrame), this.frames.length > gn && this.frames.shift(), !this.isManualScrubbing) {
1562
+ }, this.frames.push(this.currentFrame), this.frames.length > yn && this.frames.shift(), !this.isManualScrubbing) {
1563
1563
  if (this.isTrackingLatest) {
1564
1564
  let e = this.frames.length > 1 ? this.frames.length - 2 : 0;
1565
1565
  this.selectFrame(e);
@@ -1827,7 +1827,7 @@ var pn = class extends sn {
1827
1827
  r > t && (t = r);
1828
1828
  }
1829
1829
  for (let n = 0; n < e.length; n++) {
1830
- let r = e[n].triangles || 0, i = t > 0 ? r / t * _n : 0;
1830
+ let r = e[n].triangles || 0, i = t > 0 ? r / t * bn : 0;
1831
1831
  this.graph.addPoint("calls", e[n].calls.length), this.graph.addPoint("fps", e[n].fps || 0), this.graph.addPoint("triangles", i);
1832
1832
  }
1833
1833
  this.graph.update(), this.playhead.style.display = "block";
@@ -1920,27 +1920,27 @@ var pn = class extends sn {
1920
1920
  getColorForMethod(e) {
1921
1921
  return e.startsWith("begin") ? "var(--color-green)" : e.startsWith("finish") || e.startsWith("destroy") ? "var(--color-red)" : e.startsWith("draw") || e.startsWith("compute") || e.startsWith("create") || e.startsWith("generate") ? "var(--color-yellow)" : "var(--text-secondary)";
1922
1922
  }
1923
- }, yn = class extends Ht {
1923
+ }, Sn = class extends Wt {
1924
1924
  constructor() {
1925
1925
  super();
1926
- let e = new Wt(this);
1926
+ let e = new Kt(this);
1927
1927
  e.addEventListener("resize", (e) => this.dispatchEvent(e));
1928
- let t = new sn({
1928
+ let t = new un({
1929
1929
  builtin: !0,
1930
1930
  icon: "<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><path stroke=\"none\" d=\"M0 0h24v24H0z\" fill=\"none\"/><path d=\"M14 6m-2 0a2 2 0 1 0 4 0a2 2 0 1 0 -4 0\" /><path d=\"M4 6l8 0\" /><path d=\"M16 6l4 0\" /><path d=\"M8 12m-2 0a2 2 0 1 0 4 0a2 2 0 1 0 -4 0\" /><path d=\"M4 12l2 0\" /><path d=\"M10 12l10 0\" /><path d=\"M17 18m-2 0a2 2 0 1 0 4 0a2 2 0 1 0 -4 0\" /><path d=\"M4 18l11 0\" /><path d=\"M19 18l1 0\" /></svg>"
1931
1931
  });
1932
1932
  t.hide(), e.addTab(t);
1933
- let n = new hn();
1933
+ let n = new vn();
1934
1934
  n.hide(), e.addTab(n);
1935
- let r = new Yt();
1935
+ let r = new Qt();
1936
1936
  e.addTab(r);
1937
- let i = new Xt();
1937
+ let i = new $t();
1938
1938
  e.addTab(i);
1939
- let a = new vn();
1939
+ let a = new xn();
1940
1940
  e.addTab(a);
1941
- let o = new Zt();
1941
+ let o = new en();
1942
1942
  e.addTab(o);
1943
- let s = new pn();
1943
+ let s = new gn();
1944
1944
  e.addTab(s), e.loadLayout(), e.activeTabId || e.setActiveTab(r.id), this.statsData = /* @__PURE__ */ new Map(), this.profiler = e, this.performance = r, this.memory = i, this.console = o, this.parameters = t, this.viewer = n, this.timeline = a, this.settings = s, this.once = {}, this.extensionsData = /* @__PURE__ */ new WeakMap(), this.displayCycle = {
1945
1945
  text: {
1946
1946
  needsUpdate: !1,
@@ -2060,39 +2060,39 @@ var pn = class extends sn {
2060
2060
  e.time += this.nodeFrame.deltaTime, e.time >= e.duration && (e.needsUpdate = !0, e.time = 0);
2061
2061
  }
2062
2062
  static getItem(e) {
2063
- return console.warn("Inspector.getItem is deprecated. Use getItem directly instead."), bn(e);
2063
+ return console.warn("Inspector.getItem is deprecated. Use getItem directly instead."), Cn(e);
2064
2064
  }
2065
2065
  static setItem(e, t) {
2066
- console.warn("Inspector.setItem is deprecated. Use setItem directly instead."), xn(e, t);
2066
+ console.warn("Inspector.setItem is deprecated. Use setItem directly instead."), wn(e, t);
2067
2067
  }
2068
2068
  };
2069
- function bn(e) {
2069
+ function Cn(e) {
2070
2070
  return JSON.parse(localStorage.getItem("threejs-inspector") || "{}")[e] || {};
2071
2071
  }
2072
- function xn(e, t) {
2072
+ function wn(e, t) {
2073
2073
  let n = JSON.parse(localStorage.getItem("threejs-inspector") || "{}");
2074
2074
  t === null ? delete n[e] : n[e] = t, localStorage.setItem("threejs-inspector", JSON.stringify(n));
2075
2075
  }
2076
2076
  //#endregion
2077
2077
  //#region ../../node_modules/three/examples/jsm/tsl/display/SSGINode.js
2078
- var Sn = /* @__PURE__ */ new xe(), Cn = /* @__PURE__ */ new k(), wn = [
2078
+ var Tn = /* @__PURE__ */ new xe(), En = /* @__PURE__ */ new k(), Dn = [
2079
2079
  60,
2080
2080
  300,
2081
2081
  180,
2082
2082
  240,
2083
2083
  120,
2084
2084
  0
2085
- ], Tn = [
2085
+ ], On = [
2086
2086
  0,
2087
2087
  .5,
2088
2088
  .25,
2089
2089
  .75
2090
- ], En, Dn = class extends he {
2090
+ ], kn, An = class extends he {
2091
2091
  static get type() {
2092
2092
  return "SSGINode";
2093
2093
  }
2094
2094
  constructor(e, t, n, r) {
2095
- super("vec4"), this.beautyNode = e, this.depthNode = t, this.normalNode = n, this.updateBeforeType = ht.FRAME, this.sliceCount = I(1, "uint"), this.stepCount = I(12, "uint"), this.aoIntensity = I(1, "float"), this.giIntensity = I(10, "float"), this.radius = I(12, "float"), this.useScreenSpaceSampling = I(!0, "bool"), this.expFactor = I(2, "float"), this.thickness = I(1, "float"), this.useLinearThickness = I(!1, "bool"), this.backfaceLighting = I(0, "float"), this.useTemporalFiltering = !0, this._resolution = I(new k()), this._halfProjScale = I(1), this._temporalDirection = I(0), this._temporalOffset = I(0), this._cameraProjectionMatrix = I(r.projectionMatrix), this._cameraProjectionMatrixInverse = I(r.projectionMatrixInverse), this._cameraNear = ze("near", "float", r), this._cameraFar = ze("far", "float", r), this._camera = r, this._ssgiRenderTarget = new w(1, 1, { depthBuffer: !1 }), this._ssgiRenderTarget.texture.name = "SSGI", this._material = new A(), this._material.name = "SSGI", this._textureNode = Ne(this, this._ssgiRenderTarget.texture);
2095
+ super("vec4"), this.beautyNode = e, this.depthNode = t, this.normalNode = n, this.updateBeforeType = gt.FRAME, this.sliceCount = I(1, "uint"), this.stepCount = I(12, "uint"), this.aoIntensity = I(1, "float"), this.giIntensity = I(10, "float"), this.radius = I(12, "float"), this.useScreenSpaceSampling = I(!0, "bool"), this.expFactor = I(2, "float"), this.thickness = I(1, "float"), this.useLinearThickness = I(!1, "bool"), this.backfaceLighting = I(0, "float"), this.useTemporalFiltering = !0, this._resolution = I(new k()), this._halfProjScale = I(1), this._temporalDirection = I(0), this._temporalOffset = I(0), this._cameraProjectionMatrix = I(r.projectionMatrix), this._cameraProjectionMatrixInverse = I(r.projectionMatrixInverse), this._cameraNear = it("near", "float", r), this._cameraFar = it("far", "float", r), this._camera = r, this._ssgiRenderTarget = new w(1, 1, { depthBuffer: !1 }), this._ssgiRenderTarget.texture.name = "SSGI", this._material = new j(), this._material.name = "SSGI", this._textureNode = bt(this, this._ssgiRenderTarget.texture);
2096
2096
  }
2097
2097
  getTextureNode() {
2098
2098
  return this._textureNode;
@@ -2102,28 +2102,28 @@ var Sn = /* @__PURE__ */ new xe(), Cn = /* @__PURE__ */ new k(), wn = [
2102
2102
  }
2103
2103
  updateBefore(e) {
2104
2104
  let { renderer: t } = e;
2105
- En = j.resetRendererState(t, En);
2106
- let n = t.getDrawingBufferSize(Cn);
2105
+ kn = M.resetRendererState(t, kn);
2106
+ let n = t.getDrawingBufferSize(En);
2107
2107
  if (this.setSize(n.width, n.height), this.useTemporalFiltering === !0) {
2108
2108
  let t = e.frameId;
2109
- this._temporalDirection.value = wn[t % 6] / 360, this._temporalOffset.value = Tn[t % 4];
2109
+ this._temporalDirection.value = Dn[t % 6] / 360, this._temporalOffset.value = On[t % 4];
2110
2110
  } else this._temporalDirection.value = 1, this._temporalOffset.value = 1;
2111
- Sn.material = this._material, Sn.name = "SSGI", t.setClearColor(0, 1), t.setRenderTarget(this._ssgiRenderTarget), Sn.render(t), j.restoreRendererState(t, En);
2111
+ Tn.material = this._material, Tn.name = "SSGI", t.setClearColor(0, 1), t.setRenderTarget(this._ssgiRenderTarget), Tn.render(t), M.restoreRendererState(t, kn);
2112
2112
  }
2113
2113
  setup(e) {
2114
- let t = Xe(), n = R(32), r = R(0), i = (t) => {
2114
+ let t = Mt(), n = R(32), r = R(0), i = (t) => {
2115
2115
  let n = this.depthNode.sample(t).r;
2116
- return e.renderer.logarithmicDepthBuffer === !0 ? De(Ie(n, this._cameraNear, this._cameraFar), this._cameraNear, this._cameraFar) : n;
2117
- }, a = (e) => this.normalNode === null ? Le(e, this.depthNode.value, this._cameraProjectionMatrixInverse) : this.normalNode.sample(e).rgb.normalize(), o = (e) => this.beautyNode.sample(e), s = z(([e]) => M(.25).mul(rt(e.y, e.x).bitAnd(3))).setLayout({
2116
+ return e.renderer.logarithmicDepthBuffer === !0 ? Ue(ze(n, this._cameraNear, this._cameraFar), this._cameraNear, this._cameraFar) : n;
2117
+ }, a = (e) => this.normalNode === null ? ft(e, this.depthNode.value, this._cameraProjectionMatrixInverse) : this.normalNode.sample(e).rgb.normalize(), o = (e) => this.beautyNode.sample(e), s = V(([e]) => N(.25).mul(yt(e.y, e.x).bitAnd(3))).setLayout({
2118
2118
  name: "spatialOffsets",
2119
2119
  type: "float",
2120
2120
  inputs: [{
2121
2121
  name: "position",
2122
2122
  type: "vec2"
2123
2123
  }]
2124
- }), c = z(([e]) => {
2125
- let t = dt(e).mul(M(-.156583)).add(bt);
2126
- return t.mulAssign(tt(dt(e).oneMinus())), B(e.x.greaterThanEqual(0).select(t.x, et.sub(t.x)), e.y.greaterThanEqual(0).select(t.y, et.sub(t.y)));
2124
+ }), c = V(([e]) => {
2125
+ let t = pt(e).mul(N(-.156583)).add(xt);
2126
+ return t.mulAssign(Dt(pt(e).oneMinus())), L(e.x.greaterThanEqual(0).select(t.x, et.sub(t.x)), e.y.greaterThanEqual(0).select(t.y, et.sub(t.y)));
2127
2127
  }).setLayout({
2128
2128
  name: "GTAOFastAcos",
2129
2129
  type: "vec2",
@@ -2131,62 +2131,62 @@ var Sn = /* @__PURE__ */ new xe(), Cn = /* @__PURE__ */ new k(), wn = [
2131
2131
  name: "value",
2132
2132
  type: "vec2"
2133
2133
  }]
2134
- }), l = z(([e, t, s, l, u, d, f, p, m]) => {
2135
- let h = this.stepCount.toConst(), g = this.expFactor.toConst(), _ = this.thickness.toConst(), v = this.backfaceLighting.toConst(), y = M(0);
2136
- L(this.useScreenSpaceSampling.equal(!0), () => {
2137
- y.assign(t.mul(this._resolution.x.div(2)).div(M(16)));
2134
+ }), l = V(([e, t, s, l, u, d, f, p, m]) => {
2135
+ let h = this.stepCount.toConst(), g = this.expFactor.toConst(), _ = this.thickness.toConst(), v = this.backfaceLighting.toConst(), y = N(0);
2136
+ z(this.useScreenSpaceSampling.equal(!0), () => {
2137
+ y.assign(t.mul(this._resolution.x.div(2)).div(N(16)));
2138
2138
  }).Else(() => {
2139
- y.assign(N(t.mul(this._halfProjScale).div(s.z.negate()), M(h)));
2140
- }), y.divAssign(M(h).add(1));
2141
- let b = N(1, M(h.sub(1))).mul(y), x = e.equal(!0).select(B(1, -1), B(-1, 1)), S = e.equal(!0).select(1, -1), C = H(0);
2139
+ y.assign(P(t.mul(this._halfProjScale).div(s.z.negate()), N(h)));
2140
+ }), y.divAssign(N(h).add(1));
2141
+ let b = P(1, N(h.sub(1))).mul(y), x = e.equal(!0).select(L(1, -1), L(-1, 1)), S = e.equal(!0).select(1, -1), C = U(0);
2142
2142
  return Ze({
2143
2143
  start: R(0),
2144
2144
  end: h,
2145
2145
  type: "uint",
2146
2146
  condition: "<"
2147
2147
  }, ({ i: t }) => {
2148
- let h = qe(dt(jt(y, M(t).add(u)).div(b)), g).mul(b).toConst(), w = l.mul(N(h, M(t).add(1))).toConst(), T = d.add(w.mul(x)).toConst();
2149
- L(T.x.lessThanEqual(0).or(T.y.lessThanEqual(0)).or(T.x.greaterThanEqual(1)).or(T.y.greaterThanEqual(1)), () => {
2150
- Ct();
2148
+ let h = Ye(pt(Ee(y, N(t).add(u)).div(b)), g).mul(b).toConst(), w = l.mul(P(h, N(t).add(1))).toConst(), T = d.add(w.mul(x)).toConst();
2149
+ z(T.x.lessThanEqual(0).or(T.y.lessThanEqual(0)).or(T.x.greaterThanEqual(1)).or(T.y.greaterThanEqual(1)), () => {
2150
+ Tt();
2151
2151
  });
2152
- let ee = ut(T, i(T), this._cameraProjectionMatrixInverse).toConst(), te = ee.sub(s).normalize().toConst(), ne = this.useLinearThickness.equal(!0).select(ee.z.negate().div(this._cameraFar).clamp().mul(100), M(1)), re = Ae(ee.sub(ne.mul(f).mul(_)).sub(s)), E = B(V(te, f), V(re, f));
2153
- E = c(pt(E, -1, 1)), E = pt(Ee(jt(S, E.negate()).sub(m.sub(bt)), et)), E = e.equal(!0).select(E.yx, E.xy);
2154
- let D = E.x.toConst(), ie = E.y.toConst(), ae = R(E.mul(M(n))).toConst(), O = R(_t(ie.sub(D).mul(M(n)))).toConst(), oe = O.greaterThan(R(0)).select(R(ct(R(4294967295), R(32).sub(n).add(n.sub(O)))), R(0)).toConst().shiftLeft(ae);
2152
+ let ee = Te(T, i(T), this._cameraProjectionMatrixInverse).toConst(), te = ee.sub(s).normalize().toConst(), ne = this.useLinearThickness.equal(!0).select(ee.z.negate().div(this._cameraFar).clamp().mul(100), N(1)), re = We(ee.sub(ne.mul(f).mul(_)).sub(s)), E = L(H(te, f), H(re, f));
2153
+ E = c(mt(E, -1, 1)), E = mt(De(Ee(S, E.negate()).sub(m.sub(xt)), et)), E = e.equal(!0).select(E.yx, E.xy);
2154
+ let D = E.x.toConst(), ie = E.y.toConst(), ae = R(E.mul(N(n))).toConst(), O = R(vt(ie.sub(D).mul(N(n)))).toConst(), oe = O.greaterThan(R(0)).select(R(_t(R(4294967295), R(32).sub(n).add(n.sub(O)))), R(0)).toConst().shiftLeft(ae);
2155
2155
  oe = oe.bitAnd(r.bitNot()), r.assign(r.bitOr(oe));
2156
- let k = At(oe);
2157
- L(k.greaterThan(0), () => {
2156
+ let k = jt(oe);
2157
+ z(k.greaterThan(0), () => {
2158
2158
  let e = o(T);
2159
- L(Re(e).greaterThan(.001), () => {
2160
- let t = Ae(te), r = pt(V(p, t));
2161
- L(r.greaterThan(.001), () => {
2162
- let i = a(T), o = V(i, t.negate()), s = Qe(o).lessThan(0).select(dt(o).mul(v), dt(o));
2163
- o = v.greaterThan(0).and(V(i, f).greaterThan(0)).select(s, pt(o)), C.rgb.addAssign(M(k).div(M(n)).mul(e).mul(r).mul(o));
2159
+ z(Ae(e).greaterThan(.001), () => {
2160
+ let t = We(te), r = mt(H(p, t));
2161
+ z(r.greaterThan(.001), () => {
2162
+ let i = a(T), o = H(i, t.negate()), s = wt(o).lessThan(0).select(pt(o).mul(v), pt(o));
2163
+ o = v.greaterThan(0).and(H(i, f).greaterThan(0)).select(s, mt(o)), C.rgb.addAssign(N(k).div(N(n)).mul(e).mul(r).mul(o));
2164
2164
  });
2165
2165
  });
2166
2166
  });
2167
- }), H(C);
2168
- }), u = z(() => {
2167
+ }), U(C);
2168
+ }), u = V(() => {
2169
2169
  let e = i(t).toVar();
2170
2170
  e.greaterThanEqual(1).discard();
2171
- let o = ut(t, e, this._cameraProjectionMatrixInverse).toVar(), c = a(t).toVar(), u = Ae(o.xyz.negate()).toVar(), d = s(mt), f = lt(mt), p = this._temporalDirection.mul(.02), m = Oe(d.add(this._temporalOffset)).add(Je(t.add(p).mul(2).sub(1))), h = M(0), g = H(0), _ = this.sliceCount.toConst(), v = this.aoIntensity.toConst(), y = this.giIntensity.toConst(), b = this.radius.toConst();
2171
+ let o = Te(t, e, this._cameraProjectionMatrixInverse).toVar(), c = a(t).toVar(), u = We(o.xyz.negate()).toVar(), d = s(ut), f = Ie(ut), p = this._temporalDirection.mul(.02), m = Re(d.add(this._temporalOffset)).add(we(t.add(p).mul(2).sub(1))), h = N(0), g = U(0), _ = this.sliceCount.toConst(), v = this.aoIntensity.toConst(), y = this.giIntensity.toConst(), b = this.radius.toConst();
2172
2172
  Ze({
2173
2173
  start: R(0),
2174
2174
  end: _,
2175
2175
  type: "uint",
2176
2176
  condition: "<"
2177
2177
  }, ({ i: e }) => {
2178
- let i = jt(M(e).add(f).add(this._temporalDirection), et.div(M(_))).toConst(), a = H(B(Dt(i), gt(i)), 0).toConst(), s = a.xy.mul(M(1).div(this._resolution)).toConst(), d = Ae($e(a, u)).toConst(), p = $e(u, d).toConst(), v = c.sub(d.mul(V(c, d))).toConst(), y = pt(V(Ae(v).toConst(), u), -1, 1).toConst(), x = Qe(V(v, p)).negate().mul(Tt(y)).toConst();
2179
- r.assign(0), g.addAssign(l(at(!0), b, o, s, m, t, u, c, x)), g.addAssign(l(at(!1), b, o, s, m, t, u, c, x)), h.addAssign(M(At(r)).div(M(n)));
2180
- }), h.divAssign(M(_)), h.assign(qe(h.clamp().oneMinus(), v).clamp()), g.divAssign(M(_)), g.mulAssign(y);
2181
- let x = M(7).toConst(), S = Re(g), C = S.greaterThan(x).select(x.div(S), M(1));
2182
- return g.mulAssign(C), P(g, h);
2178
+ let i = Ee(N(e).add(f).add(this._temporalDirection), et.div(N(_))).toConst(), a = U(L(Ot(i), tt(i)), 0).toConst(), s = a.xy.mul(N(1).div(this._resolution)).toConst(), d = We($e(a, u)).toConst(), p = $e(u, d).toConst(), v = c.sub(d.mul(H(c, d))).toConst(), y = mt(H(We(v).toConst(), u), -1, 1).toConst(), x = wt(H(v, p)).negate().mul(Et(y)).toConst();
2179
+ r.assign(0), g.addAssign(l(at(!0), b, o, s, m, t, u, c, x)), g.addAssign(l(at(!1), b, o, s, m, t, u, c, x)), h.addAssign(N(jt(r)).div(N(n)));
2180
+ }), h.divAssign(N(_)), h.assign(Ye(h.clamp().oneMinus(), v).clamp()), g.divAssign(N(_)), g.mulAssign(y);
2181
+ let x = N(7).toConst(), S = Ae(g), C = S.greaterThan(x).select(x.div(S), N(1));
2182
+ return g.mulAssign(C), F(g, h);
2183
2183
  });
2184
2184
  return this._material.fragmentNode = u().context(e.getSharedContext()), this._material.needsUpdate = !0, this._textureNode;
2185
2185
  }
2186
2186
  dispose() {
2187
2187
  this._ssgiRenderTarget.dispose(), this._material.dispose();
2188
2188
  }
2189
- }, On = (e, t, n, r) => new Dn(Ye(e), t, n, r), kn = class e extends Lt {
2189
+ }, jn = (e, t, n, r) => new An(Xe(e), t, n, r), Mn = class e extends zt {
2190
2190
  static {
2191
2191
  this.passId = "SsgiRenderPass";
2192
2192
  }
@@ -2202,18 +2202,18 @@ var Sn = /* @__PURE__ */ new xe(), Cn = /* @__PURE__ */ new k(), wn = [
2202
2202
  }
2203
2203
  assemble(e, t, n, r, i) {
2204
2204
  if (!(r instanceof l)) return t;
2205
- e.setMRT(Be({
2206
- output: Ke,
2207
- diffuseColor: Ot,
2208
- normal: Ve(Ge),
2209
- velocity: kt
2205
+ e.setMRT(Nt({
2206
+ output: je,
2207
+ diffuseColor: At,
2208
+ normal: Ve(Me),
2209
+ velocity: Oe
2210
2210
  }));
2211
- let a = e.getTextureNode("output"), o = e.getTextureNode("diffuseColor"), s = e.getTextureNode("depth"), c = e.getTextureNode("normal"), u = On(a, s, wt((e) => ot(c.sample(e))), r);
2211
+ let a = e.getTextureNode("output"), o = e.getTextureNode("diffuseColor"), s = e.getTextureNode("depth"), c = e.getTextureNode("normal"), u = jn(a, s, St((e) => st(c.sample(e))), r);
2212
2212
  u.sliceCount = this.sliceCount, u.stepCount = this.stepCount, u.radius = this.radius, u.expFactor = this.expFactor, u.thickness = this.thickness, u.backfaceLighting = this.backfaceLighting, u.aoIntensity = this.aoIntensity, u.giIntensity = this.giIntensity, u.useLinearThickness = this.useLinearThickness, u.useScreenSpaceSampling = this.useScreenSpaceSampling;
2213
- let d = u.rgb, f = u.a, p = P(nt(a.rgb.mul(f), o.rgb.mul(d)), a.a);
2214
- return p.name = "Ssgi Composite", i === "ao only" ? P(H(f), 1) : i === "gi only" ? P(d, 1) : i === "direct lighting only" ? a : p;
2213
+ let d = u.rgb, f = u.a, p = F(nt(a.rgb.mul(f), o.rgb.mul(d)), a.a);
2214
+ return p.name = "Ssgi Composite", i === "ao only" ? F(U(f), 1) : i === "gi only" ? F(d, 1) : i === "direct lighting only" ? a : p;
2215
2215
  }
2216
- }, An = /* @__PURE__ */ new xe(), jn = /* @__PURE__ */ new k(), Mn, Nn = class extends he {
2216
+ }, Nn = /* @__PURE__ */ new xe(), Pn = /* @__PURE__ */ new k(), Fn, In = class extends he {
2217
2217
  static get type() {
2218
2218
  return "TRAANode";
2219
2219
  }
@@ -2225,7 +2225,7 @@ var Sn = /* @__PURE__ */ new xe(), Cn = /* @__PURE__ */ new k(), wn = [
2225
2225
  }), this._historyRenderTarget.texture.name = "TRAANode.history", this._resolveRenderTarget = new w(1, 1, {
2226
2226
  depthBuffer: !1,
2227
2227
  type: S
2228
- }), this._resolveRenderTarget.texture.name = "TRAANode.resolve", this._resolveMaterial = new A(), this._resolveMaterial.name = "TRAA.resolve", this._textureNode = Ne(this, this._resolveRenderTarget.texture), this._originalProjectionMatrix = new D(), this._cameraNearFar = I(new k()), this._cameraWorldMatrix = I(new D()), this._cameraWorldMatrixInverse = I(new D()), this._cameraProjectionMatrixInverse = I(new D()), this._previousCameraWorldMatrix = I(new D()), this._previousCameraProjectionMatrixInverse = I(new D()), this._previousDepthNode = F(new p(1, 1)), this._needsPostProcessingSync = !1, this._velocityNode = null;
2228
+ }), this._resolveRenderTarget.texture.name = "TRAANode.resolve", this._resolveMaterial = new j(), this._resolveMaterial.name = "TRAA.resolve", this._textureNode = bt(this, this._resolveRenderTarget.texture), this._originalProjectionMatrix = new D(), this._cameraNearFar = I(new k()), this._cameraWorldMatrix = I(new D()), this._cameraWorldMatrixInverse = I(new D()), this._cameraProjectionMatrixInverse = I(new D()), this._previousCameraWorldMatrix = I(new D()), this._previousCameraProjectionMatrixInverse = I(new D()), this._previousDepthNode = B(new p(1, 1)), this._needsPostProcessingSync = !1, this._velocityNode = null;
2229
2229
  }
2230
2230
  getTextureNode() {
2231
2231
  return this._textureNode;
@@ -2242,48 +2242,48 @@ var Sn = /* @__PURE__ */ new xe(), Cn = /* @__PURE__ */ new k(), wn = [
2242
2242
  offsetY: 0,
2243
2243
  width: e,
2244
2244
  height: t
2245
- }, r = Fn[this._jitterIndex];
2245
+ }, r = Rn[this._jitterIndex];
2246
2246
  this.camera.setViewOffset(n.fullWidth, n.fullHeight, n.offsetX + r[0] - .5, n.offsetY + r[1] - .5, n.width, n.height);
2247
2247
  }
2248
2248
  clearViewOffset() {
2249
- this.camera.clearViewOffset(), this._velocityNode.setProjectionMatrix(null), this._jitterIndex++, this._jitterIndex %= Fn.length - 1;
2249
+ this.camera.clearViewOffset(), this._velocityNode.setProjectionMatrix(null), this._jitterIndex++, this._jitterIndex %= Rn.length - 1;
2250
2250
  }
2251
2251
  updateBefore(e) {
2252
2252
  let { renderer: t } = e;
2253
2253
  this._previousCameraWorldMatrix.value.copy(this._cameraWorldMatrix.value), this._previousCameraProjectionMatrixInverse.value.copy(this._cameraProjectionMatrixInverse.value), this._cameraNearFar.value.set(this.camera.near, this.camera.far), this._cameraWorldMatrix.value.copy(this.camera.matrixWorld), this._cameraWorldMatrixInverse.value.copy(this.camera.matrixWorldInverse), this._cameraProjectionMatrixInverse.value.copy(this.camera.projectionMatrixInverse);
2254
2254
  let n = this.beautyNode.isRTTNode ? this.beautyNode.renderTarget : this.beautyNode.passNode.renderTarget, r = n.texture.width, i = n.texture.height;
2255
- this._needsPostProcessingSync === !0 && (this.setViewOffset(r, i), this._needsPostProcessingSync = !1), Mn = j.resetRendererState(t, Mn);
2255
+ this._needsPostProcessingSync === !0 && (this.setViewOffset(r, i), this._needsPostProcessingSync = !1), Fn = M.resetRendererState(t, Fn);
2256
2256
  let a = this._historyRenderTarget.width !== r || this._historyRenderTarget.height !== i;
2257
- this.setSize(r, i), a === !0 && (t.initRenderTarget(this._historyRenderTarget), t.initRenderTarget(this._resolveRenderTarget), t.copyTextureToTexture(n.texture, this._historyRenderTarget.texture)), t.setRenderTarget(this._resolveRenderTarget), An.material = this._resolveMaterial, An.name = "TRAA", An.render(t), t.setRenderTarget(null), t.copyTextureToTexture(this._resolveRenderTarget.texture, this._historyRenderTarget.texture);
2258
- let o = t.getDrawingBufferSize(jn);
2257
+ this.setSize(r, i), a === !0 && (t.initRenderTarget(this._historyRenderTarget), t.initRenderTarget(this._resolveRenderTarget), t.copyTextureToTexture(n.texture, this._historyRenderTarget.texture)), t.setRenderTarget(this._resolveRenderTarget), Nn.material = this._resolveMaterial, Nn.name = "TRAA", Nn.render(t), t.setRenderTarget(null), t.copyTextureToTexture(this._resolveRenderTarget.texture, this._historyRenderTarget.texture);
2258
+ let o = t.getDrawingBufferSize(Pn);
2259
2259
  if (this._historyRenderTarget.height === o.height && this._historyRenderTarget.width === o.width) {
2260
2260
  let e = this.depthNode.value;
2261
2261
  t.copyTextureToTexture(e, this._historyRenderTarget.depthTexture), this._previousDepthNode.value = this._historyRenderTarget.depthTexture;
2262
2262
  }
2263
- j.restoreRendererState(t, Mn);
2263
+ M.restoreRendererState(t, Fn);
2264
2264
  }
2265
2265
  setup(e) {
2266
2266
  let t = e.context.renderPipeline;
2267
2267
  t && (this._needsPostProcessingSync = !0, t.context.onBeforeRenderPipeline = () => {
2268
- let t = e.renderer.getDrawingBufferSize(jn);
2268
+ let t = e.renderer.getDrawingBufferSize(Pn);
2269
2269
  this.setViewOffset(t.width, t.height);
2270
2270
  }, t.context.onAfterRenderPipeline = () => {
2271
2271
  this.clearViewOffset();
2272
- }), e.renderer.reversedDepthBuffer === !0 && (this._historyRenderTarget.depthTexture.type = _), e.context.velocity === void 0 ? this._velocityNode = kt : this._velocityNode = e.context.velocity;
2272
+ }), e.renderer.reversedDepthBuffer === !0 && (this._historyRenderTarget.depthTexture.type = _), e.context.velocity === void 0 ? this._velocityNode = Oe : this._velocityNode = e.context.velocity;
2273
2273
  let n = (e) => {
2274
2274
  let { x: t, y: n } = this._cameraNearFar;
2275
- return De(Ie(e, t, n), t, n);
2276
- }, r = Et({
2275
+ return Ue(ze(e, t, n), t, n);
2276
+ }, r = ot({
2277
2277
  closestDepth: "float",
2278
2278
  closestPositionTexel: "vec2",
2279
2279
  farthestDepth: "float"
2280
- }), i = z(([t]) => {
2281
- let i = M(2).toVar(), a = B(0).toVar(), o = M(-1).toVar();
2280
+ }), i = V(([t]) => {
2281
+ let i = N(2).toVar(), a = L(0).toVar(), o = N(-1).toVar();
2282
2282
  for (let r = -1; r <= 1; ++r) for (let s = -1; s <= 1; ++s) {
2283
- let c = t.add(B(r, s)).toVar(), l = this.depthNode.load(c).r;
2284
- e.renderer.reversedDepthBuffer && (l = l.oneMinus()), e.renderer.logarithmicDepthBuffer && (l = n(l)), l = l.toVar(), L(l.lessThan(i), () => {
2283
+ let c = t.add(L(r, s)).toVar(), l = this.depthNode.load(c).r;
2284
+ e.renderer.reversedDepthBuffer && (l = l.oneMinus()), e.renderer.logarithmicDepthBuffer && (l = n(l)), l = l.toVar(), z(l.lessThan(i), () => {
2285
2285
  i.assign(l), a.assign(c);
2286
- }), L(l.greaterThan(o), () => {
2286
+ }), z(l.greaterThan(o), () => {
2287
2287
  o.assign(l);
2288
2288
  });
2289
2289
  }
@@ -2291,11 +2291,11 @@ var Sn = /* @__PURE__ */ new xe(), Cn = /* @__PURE__ */ new k(), wn = [
2291
2291
  }), a = (t) => {
2292
2292
  let r = this._previousDepthNode.sample(t).r;
2293
2293
  e.renderer.logarithmicDepthBuffer && (r = n(r));
2294
- let i = ut(t, r, this._previousCameraProjectionMatrixInverse), a = this._previousCameraWorldMatrix.mul(P(i, 1)).xyz, o = this._cameraWorldMatrixInverse.mul(P(a, 1)).z;
2295
- return this.camera.isOrthographicCamera ? He(o, this._cameraNearFar.x, this._cameraNearFar.y) : De(o, this._cameraNearFar.x, this._cameraNearFar.y);
2296
- }, o = z(([e, t, n, r]) => {
2297
- let i = r.rgb.add(n.rgb).mul(.5), a = r.rgb.sub(n.rgb).mul(.5).add(1e-7), o = t.sub(P(i, e.a)), s = o.xyz.div(a).abs(), c = N(s.x, s.y, s.z);
2298
- return c.greaterThan(1).select(P(i, e.a).add(o.div(c)), t);
2294
+ let i = Te(t, r, this._previousCameraProjectionMatrixInverse), a = this._previousCameraWorldMatrix.mul(F(i, 1)).xyz, o = this._cameraWorldMatrixInverse.mul(F(a, 1)).z;
2295
+ return this.camera.isOrthographicCamera ? kt(o, this._cameraNearFar.x, this._cameraNearFar.y) : Ue(o, this._cameraNearFar.x, this._cameraNearFar.y);
2296
+ }, o = V(([e, t, n, r]) => {
2297
+ let i = r.rgb.add(n.rgb).mul(.5), a = r.rgb.sub(n.rgb).mul(.5).add(1e-7), o = t.sub(F(i, e.a)), s = o.xyz.div(a).abs(), c = P(s.x, s.y, s.z);
2298
+ return c.greaterThan(1).select(F(i, e.a).add(o.div(c)), t);
2299
2299
  }).setLayout({
2300
2300
  name: "clipAABB",
2301
2301
  type: "vec4",
@@ -2317,7 +2317,7 @@ var Sn = /* @__PURE__ */ new xe(), Cn = /* @__PURE__ */ new k(), wn = [
2317
2317
  type: "vec4"
2318
2318
  }
2319
2319
  ]
2320
- }), s = z(([e, t, n, r]) => {
2320
+ }), s = V(([e, t, n, r]) => {
2321
2321
  let i = [
2322
2322
  [-1, -1],
2323
2323
  [-1, 1],
@@ -2329,13 +2329,13 @@ var Sn = /* @__PURE__ */ new xe(), Cn = /* @__PURE__ */ new k(), wn = [
2329
2329
  [-1, 0]
2330
2330
  ], a = t.toVar(), s = t.pow2().toVar();
2331
2331
  for (let [t, n] of i) {
2332
- let r = this.beautyNode.offset(Fe(t, n)).load(e).max(0);
2332
+ let r = this.beautyNode.offset(Le(t, n)).load(e).max(0);
2333
2333
  a.addAssign(r), s.addAssign(r.pow2());
2334
2334
  }
2335
- let c = M(i.length + 1), l = a.div(c), u = s.div(c).sub(l.pow2()).max(0).sqrt().mul(r), d = l.sub(u), f = l.add(u);
2335
+ let c = N(i.length + 1), l = a.div(c), u = s.div(c).sub(l.pow2()).max(0).sqrt().mul(r), d = l.sub(u), f = l.add(u);
2336
2336
  return o(l.clamp(d, f), n, d, f);
2337
- }), c = z(([e, t]) => {
2338
- let n = e.mul(t).fract().abs(), r = N(n, n.oneMinus());
2337
+ }), c = V(([e, t]) => {
2338
+ let n = e.mul(t).fract().abs(), r = P(n, n.oneMinus());
2339
2339
  return r.x.mul(r.y).oneMinus().div(.75);
2340
2340
  }).setLayout({
2341
2341
  name: "subpixelCorrection",
@@ -2347,12 +2347,12 @@ var Sn = /* @__PURE__ */ new xe(), Cn = /* @__PURE__ */ new k(), wn = [
2347
2347
  name: "textureSize",
2348
2348
  type: "ivec2"
2349
2349
  }]
2350
- }), l = z(([e, t, n]) => {
2351
- let r = n.oneMinus(), i = e.mul(M(1).div(N(e.r, e.g, e.b).add(1))), a = t.mul(M(1).div(N(t.r, t.g, t.b).add(1))), o = Re(i.rgb), s = Re(a.rgb);
2352
- return n.mulAssign(M(1).div(o.add(1))), r.mulAssign(M(1).div(s.add(1))), nt(e.mul(n), t.mul(r)).div(N(n.add(r), 1e-5)).toVar();
2353
- }), u = F(this._historyRenderTarget.texture), d = z(() => {
2354
- let e = Xe(), t = this.beautyNode.size(), n = e.mul(t), r = i(n), o = r.get("closestDepth"), d = r.get("closestPositionTexel"), f = r.get("farthestDepth"), p = this.velocityNode.load(d).xy.mul(B(.5, -.5)), m = e.sub(p), h = a(m), g = m.greaterThanEqual(0).all().and(m.lessThanEqual(1).all()), _ = f.sub(o).greaterThan(this.edgeDepthDiff), v = o.sub(h).greaterThan(this.depthThreshold), y = g.and(_.or(v.not())), b = this.beautyNode.sample(e), x = u.sample(e.sub(p)), S = e.sub(m).mul(t).length().div(this.maxVelocityLength).saturate(), C = M(.05).toVar();
2355
- return this.useSubpixelCorrection && C.addAssign(c(p, t).mul(.25)), C.assign(y.select(C.add(S).saturate(), 1)), l(b, s(n, b, x, Pe(.5, 1, S.oneMinus().pow2())), C);
2350
+ }), l = V(([e, t, n]) => {
2351
+ let r = n.oneMinus(), i = e.mul(N(1).div(P(e.r, e.g, e.b).add(1))), a = t.mul(N(1).div(P(t.r, t.g, t.b).add(1))), o = Ae(i.rgb), s = Ae(a.rgb);
2352
+ return n.mulAssign(N(1).div(o.add(1))), r.mulAssign(N(1).div(s.add(1))), nt(e.mul(n), t.mul(r)).div(P(n.add(r), 1e-5)).toVar();
2353
+ }), u = B(this._historyRenderTarget.texture), d = V(() => {
2354
+ let e = Mt(), t = this.beautyNode.size(), n = e.mul(t), r = i(n), o = r.get("closestDepth"), d = r.get("closestPositionTexel"), f = r.get("farthestDepth"), p = this.velocityNode.load(d).xy.mul(L(.5, -.5)), m = e.sub(p), h = a(m), g = m.greaterThanEqual(0).all().and(m.lessThanEqual(1).all()), _ = f.sub(o).greaterThan(this.edgeDepthDiff), v = o.sub(h).greaterThan(this.depthThreshold), y = g.and(_.or(v.not())), b = this.beautyNode.sample(e), x = u.sample(e.sub(p)), S = e.sub(m).mul(t).length().div(this.maxVelocityLength).saturate(), C = N(.05).toVar();
2355
+ return this.useSubpixelCorrection && C.addAssign(c(p, t).mul(.25)), C.assign(y.select(C.add(S).saturate(), 1)), l(b, s(n, b, x, Be(.5, 1, S.oneMinus().pow2())), C);
2356
2356
  });
2357
2357
  return this._resolveMaterial.colorNode = d(), this._textureNode;
2358
2358
  }
@@ -2360,12 +2360,12 @@ var Sn = /* @__PURE__ */ new xe(), Cn = /* @__PURE__ */ new k(), wn = [
2360
2360
  this._historyRenderTarget.dispose(), this._resolveRenderTarget.dispose(), this._resolveMaterial.dispose();
2361
2361
  }
2362
2362
  };
2363
- function Pn(e, t) {
2363
+ function Ln(e, t) {
2364
2364
  let n = 1, r = 0;
2365
2365
  for (; e > 0;) n /= t, r += e % t * n, e = Math.floor(e / t);
2366
2366
  return r;
2367
2367
  }
2368
- var Fn = /* @__PURE__ */ Array.from({ length: 32 }, (e, t) => [Pn(t + 1, 2), Pn(t + 1, 3)]), In = (e, t, n, r) => new Nn(Ye(e), t, n, r), Ln = class e extends Lt {
2368
+ var Rn = /* @__PURE__ */ Array.from({ length: 32 }, (e, t) => [Ln(t + 1, 2), Ln(t + 1, 3)]), zn = (e, t, n, r) => new In(Xe(e), t, n, r), Bn = class e extends zt {
2369
2369
  constructor(...t) {
2370
2370
  super(...t), this.passId = e.passId;
2371
2371
  }
@@ -2373,7 +2373,7 @@ var Fn = /* @__PURE__ */ Array.from({ length: 32 }, (e, t) => [Pn(t + 1, 2), Pn(
2373
2373
  this.passId = "TraaRenderPass";
2374
2374
  }
2375
2375
  assemble(e, t, n, r, i) {
2376
- return r instanceof l ? In(t, e.getTextureNode("depth"), e.getTextureNode("velocity"), r) : t;
2376
+ return r instanceof l ? zn(t, e.getTextureNode("depth"), e.getTextureNode("velocity"), r) : t;
2377
2377
  }
2378
2378
  addParametersToGUI(e, t) {}
2379
2379
  }, Q = {
@@ -2390,7 +2390,7 @@ var Fn = /* @__PURE__ */ Array.from({ length: 32 }, (e, t) => [Pn(t + 1, 2), Pn(
2390
2390
  Q.MEDIUM,
2391
2391
  Q.LOW,
2392
2392
  Q.LOWEST
2393
- ], Rn = $[0], zn = $[$.length - 1], Bn = Q.HIGHEST, Vn = new Map([
2393
+ ], Vn = $[0], Hn = $[$.length - 1], Un = Q.HIGHEST, Wn = new Map([
2394
2394
  [Q.HIGHEST, {
2395
2395
  maxPixelRatio: 1.5,
2396
2396
  ssgiPerformanceParameters: {
@@ -2433,7 +2433,7 @@ var Fn = /* @__PURE__ */ Array.from({ length: 32 }, (e, t) => [Pn(t + 1, 2), Pn(
2433
2433
  stepCount: 0
2434
2434
  }
2435
2435
  }]
2436
- ]), Hn = [
2436
+ ]), Gn = [
2437
2437
  {
2438
2438
  min: 70,
2439
2439
  max: Infinity,
@@ -2464,16 +2464,16 @@ var Fn = /* @__PURE__ */ Array.from({ length: 32 }, (e, t) => [Pn(t + 1, 2), Pn(
2464
2464
  max: 19,
2465
2465
  value: Q.LOWEST
2466
2466
  }
2467
- ], Un = (e) => Hn.find((t) => e >= t.min && e <= t.max).value, Wn = class {
2467
+ ], Kn = (e) => Gn.find((t) => e >= t.min && e <= t.max).value, qn = class {
2468
2468
  constructor(e) {
2469
- this.qualityLevel = Bn, this.qualityMap = Vn, this.fpsCounter = new pe(), this.applyQualityParametersCallback = e;
2469
+ this.qualityLevel = Un, this.qualityMap = Wn, this.fpsCounter = new pe(), this.applyQualityParametersCallback = e;
2470
2470
  }
2471
2471
  getQualityLevel() {
2472
2472
  return this.qualityLevel;
2473
2473
  }
2474
2474
  manageQualitySettings(e, t) {
2475
2475
  this.fpsCounter.update();
2476
- let n = this.fpsCounter.getFps(), r = n > 0 && n < e && this.qualityLevel !== zn, i = n > t && this.qualityLevel !== Rn, a = r ? "decrement" : i ? "increment" : void 0;
2476
+ let n = this.fpsCounter.getFps(), r = n > 0 && n < e && this.qualityLevel !== Hn, i = n > t && this.qualityLevel !== Vn, a = r ? "decrement" : i ? "increment" : void 0;
2477
2477
  if (a === void 0) {
2478
2478
  this.qualityChangePendingSince = void 0, this.qualityChangePendingDirection = void 0;
2479
2479
  return;
@@ -2513,17 +2513,52 @@ var Fn = /* @__PURE__ */ Array.from({ length: 32 }, (e, t) => [Pn(t + 1, 2), Pn(
2513
2513
  async autoDetectInitialQualityLevel() {
2514
2514
  let { getGPUTier: e } = await import("./dist-DGov-RNo.mjs"), t = await e({ benchmarksURL: "./benchmarks" });
2515
2515
  if (!t || !t.fps) {
2516
- console.info("Could not autodetect performance - no benchmark for graphics hardware. Defaulting to HIGHEST"), this.qualityLevel = Bn;
2516
+ console.info("Could not autodetect performance - no benchmark for graphics hardware. Defaulting to HIGHEST"), this.qualityLevel = Un;
2517
2517
  return;
2518
2518
  }
2519
- this.qualityLevel = Un(t.fps), console.info(`The initial quality setting has been set to ${this.qualityLevel} based on a benchmark performance of ${t.fps}fps of the graphics hardware.`);
2519
+ this.qualityLevel = Kn(t.fps), console.info(`The initial quality setting has been set to ${this.qualityLevel} based on a benchmark performance of ${t.fps}fps of the graphics hardware.`);
2520
+ }
2521
+ }, Jn = class e extends zt {
2522
+ static {
2523
+ this.passId = "FogRenderPass";
2520
2524
  }
2521
- }, Gn = class extends fe {
2525
+ constructor(t) {
2526
+ super(), this.passId = e.passId, this.sceneWithFog = void 0, this.fogColor = I(new O(t.color)), this.fogNearBlend = I(t.nearBlend), this.fogFarBlend = I(t.farBlend);
2527
+ }
2528
+ assemble(e, t, n, r, i) {
2529
+ if (!(r instanceof l) || i === "no fog") return this.removeSceneFog(), t;
2530
+ let a = e.getTextureNode("depth");
2531
+ if (i === "depth") return this.removeSceneFog(), F(U(a.r), 1);
2532
+ let o = I(r.projectionMatrixInverse), s = I(r.matrixWorld), c = Fe(I(r.far).onRenderUpdate(() => r.far), 50).sub(this.fogFarBlend), u = c.sub(this.fogNearBlend), d = F(Qe.x.mul(2).sub(1), Qe.y.mul(2).sub(1), a.r, 1), f = o.mul(d), p = f.xyz.div(f.w), m = s.mul(F(p, 1)).xyz.xz.length(), h = c.sub(m).div(c.sub(u)).clamp(0, 1);
2533
+ return this.addSceneFog(n, u, c), Be(F(this.fogColor, 1), t, h);
2534
+ }
2535
+ addSceneFog(e, t, n) {
2536
+ let r = qe.xz.length(), i = n.sub(r).div(n.sub(t)).clamp(0, 1).oneMinus();
2537
+ e.fogNode = ke(this.fogColor, i), this.sceneWithFog = e;
2538
+ }
2539
+ removeSceneFog() {
2540
+ this.sceneWithFog &&= (this.sceneWithFog.fogNode = null, void 0);
2541
+ }
2542
+ addParametersToGUI(e, n) {
2543
+ let r = e.addFolder("Fog Settings");
2544
+ r.add(this.fogNearBlend, "value", 0, 30, .1).name("near blend").onChange(() => n()), r.add(this.fogFarBlend, "value", 0, 30, .1).name("far blend").onChange(() => n()), r.addColor({ color: this.fogColor.value.getHex(t) }, "color").name("color").onChange((e) => {
2545
+ this.fogColor.value.set(e), n();
2546
+ });
2547
+ }
2548
+ }, Yn = {
2549
+ [A.NONE]: 0,
2550
+ [A.LINEAR]: 1,
2551
+ [A.REINHARD]: 2,
2552
+ [A.CINEON]: 3,
2553
+ [A.ACES_FILMIC]: 4,
2554
+ [A.AGX]: 6,
2555
+ [A.NEUTRAL]: 7
2556
+ }, Xn = class extends fe {
2522
2557
  constructor(e, t, n, r) {
2523
- super(e, t), this.passNeedsReassembly = !0, this.debugMode = "off", this.renderPasses = /* @__PURE__ */ new Map(), this.guiParameterGroups = /* @__PURE__ */ new Map(), this.lastRenderCamera = void 0, this.qualityManager = new Wn(this.applyQualityParameters.bind(this)), this.freezeFrames = 0, this.freezeRenderTarget = new w(), this.renderPipeline = new Se(t), this.enableRenderPasses(n, r), this._initData.featureFlags.webGpuConfig.autoDetectQualityLevel ? this.qualityManager.autoDetectInitialQualityLevel().then(() => this.qualityManager.applyCurrentQualityLevel(0)) : this.qualityManager.applyCurrentQualityLevel(0);
2558
+ super(e, t), this.passNeedsReassembly = !0, this.debugMode = "off", this.renderPasses = /* @__PURE__ */ new Map(), this.guiParameterGroups = /* @__PURE__ */ new Map(), this.lastRenderCamera = void 0, this.qualityManager = new qn(this.applyQualityParameters.bind(this)), this.freezeFrames = 0, this.freezeRenderTarget = new w(), this.renderPipeline = new Se(t), this.applyToneMappingConfig(), this.enableDefaultRenderPasses(n, r), this._initData.webGpuConfig.autoDetectQualityLevel ? this.qualityManager.autoDetectInitialQualityLevel().then(() => this.qualityManager.applyCurrentQualityLevel(0)) : this.qualityManager.applyCurrentQualityLevel(0);
2524
2559
  }
2525
- enableRenderPasses(e, t) {
2526
- e && this.enableSsgiPass(), t && this.enableOutline(t.outlineVisibleEdgeColor, t.outlineHiddenEdgeColor), e && this.enableTraaPass();
2560
+ enableDefaultRenderPasses(e, t) {
2561
+ e && this.enableSsgiPass(), t && this.enableOutline(t.outlineVisibleEdgeColor, t.outlineHiddenEdgeColor), e && this.enableTraaPass(), this._initData.webGpuConfig.fog.enabled && this.enableFogPass();
2527
2562
  }
2528
2563
  async addGroundShadowLightAndFloor(e) {
2529
2564
  await this._webGpuGroundShadowReflection.addToScene(e);
@@ -2538,23 +2573,20 @@ var Fn = /* @__PURE__ */ Array.from({ length: 32 }, (e, t) => [Pn(t + 1, 2), Pn(
2538
2573
  super.setCameraType(e), this.passNeedsReassembly = !0;
2539
2574
  }
2540
2575
  switchToConfigurator() {
2541
- super.switchToConfigurator(), this._webGpuGroundShadowReflection.setVisible(!0);
2576
+ super.switchToConfigurator(), this._webGpuGroundShadowReflection.setVisible(!0), this._initData.webGpuConfig.fog.enabled && this.enableFogPass(), this.passNeedsReassembly = !0;
2542
2577
  }
2543
2578
  switchToPlanner(e) {
2544
- super.switchToPlanner(e), this._webGpuGroundShadowReflection.setVisible(!1), this.passNeedsReassembly = !0;
2579
+ super.switchToPlanner(e), this._webGpuGroundShadowReflection.setVisible(!1), this.disableFogPass(), this.passNeedsReassembly = !0;
2545
2580
  }
2546
2581
  highlightObjects(e) {
2547
2582
  this.getOutlinePassOrUndefined()?.highlightObjects(e);
2548
2583
  }
2549
- loadLutImages(e) {
2550
- console.error("RoomleWebGPURenderer.loadLutImages is not implemented yet");
2551
- }
2552
2584
  render(e, t) {
2553
2585
  if (this.updateCameraProjectionMatrix(t), (this.passNeedsReassembly || this.lastRenderCamera !== t) && (this.renderPipeline.outputNode = this.assembleRenderPasses(e, t), this.renderPipeline.needsUpdate = !0, this.passNeedsReassembly = !1, this.lastRenderCamera = t), this.freezeFrames > 0) {
2554
2586
  this.freezeFrames--, this.renderToFreezeTarget();
2555
2587
  return;
2556
2588
  }
2557
- this.renderPipeline.render(), this.qualityManager.manageQualitySettings(this._initData.featureFlags.webGpuConfig.autoQualityMinFps, this._initData.featureFlags.webGpuConfig.autoQualityMaxFps);
2589
+ this.renderPipeline.render(), this.qualityManager.manageQualitySettings(this._initData.webGpuConfig.autoQualityMinFps, this._initData.webGpuConfig.autoQualityMaxFps);
2558
2590
  }
2559
2591
  renderToFreezeTarget() {
2560
2592
  let e = this.renderer.getRenderTarget();
@@ -2564,7 +2596,7 @@ var Fn = /* @__PURE__ */ Array.from({ length: 32 }, (e, t) => [Pn(t + 1, 2), Pn(
2564
2596
  (e instanceof r || e instanceof l) && e.updateProjectionMatrix();
2565
2597
  }
2566
2598
  assembleRenderPasses(e, t) {
2567
- let n = ke(e, t), r = n;
2599
+ let n = Pe(e, t), r = n;
2568
2600
  for (let i of this.renderPasses.values()) r = i.assemble(n, r, e, t, this.debugMode);
2569
2601
  return r;
2570
2602
  }
@@ -2576,7 +2608,7 @@ var Fn = /* @__PURE__ */ Array.from({ length: 32 }, (e, t) => [Pn(t + 1, 2), Pn(
2576
2608
  this.isConfiguratorMode && this._webGpuGroundShadowReflection.setReceiveShadow(e);
2577
2609
  }
2578
2610
  enableOutline(e, t) {
2579
- this.getOutlinePassOrUndefined() || this.addRenderPass(new Rt({
2611
+ this.getOutlinePassOrUndefined() || this.addRenderPass(new Bt({
2580
2612
  selectedObjects: [],
2581
2613
  visibleEdgeColor: e,
2582
2614
  hiddenEdgeColor: t,
@@ -2586,11 +2618,11 @@ var Fn = /* @__PURE__ */ Array.from({ length: 32 }, (e, t) => [Pn(t + 1, 2), Pn(
2586
2618
  }));
2587
2619
  }
2588
2620
  getOutlinePassOrUndefined() {
2589
- let e = this.renderPasses.get(Rt.passId);
2590
- if (e && e instanceof Rt) return e;
2621
+ let e = this.renderPasses.get(Bt.passId);
2622
+ if (e && e instanceof Bt) return e;
2591
2623
  }
2592
2624
  enableSsgiPass() {
2593
- this.renderPasses.get(kn.passId) || this.addRenderPass(new kn({
2625
+ this.renderPasses.get(Mn.passId) || this.addRenderPass(new Mn({
2594
2626
  sliceCount: 2,
2595
2627
  stepCount: 12,
2596
2628
  radius: 8,
@@ -2604,7 +2636,20 @@ var Fn = /* @__PURE__ */ Array.from({ length: 32 }, (e, t) => [Pn(t + 1, 2), Pn(
2604
2636
  }));
2605
2637
  }
2606
2638
  enableTraaPass() {
2607
- this.renderPasses.get(Ln.passId) || this.addRenderPass(new Ln());
2639
+ this.renderPasses.get(Bn.passId) || this.addRenderPass(new Bn());
2640
+ }
2641
+ enableFogPass() {
2642
+ if (this.renderPasses.get(Jn.passId)) return;
2643
+ let e = this._initData.webGpuConfig.fog;
2644
+ this.addRenderPass(new Jn({
2645
+ color: this._initData.colors.DEFAULT_BACKGROUND,
2646
+ nearBlend: e.nearBlend,
2647
+ farBlend: e.farBlend
2648
+ }));
2649
+ }
2650
+ disableFogPass() {
2651
+ let e = this.renderPasses.get(Jn.passId);
2652
+ !e || !(e instanceof Jn) || (e.removeSceneFog(), this.renderPasses.delete(Jn.passId));
2608
2653
  }
2609
2654
  applyQualityParameters(e, t) {
2610
2655
  this.freezeFrames = t;
@@ -2612,17 +2657,17 @@ var Fn = /* @__PURE__ */ Array.from({ length: 32 }, (e, t) => [Pn(t + 1, 2), Pn(
2612
2657
  this.renderer.setPixelRatio(Math.min(n, e.maxPixelRatio)), this.getSsgiPassOrUndefined()?.updatePerformanceParameters(e.ssgiPerformanceParameters), this.passNeedsReassembly = !0;
2613
2658
  }
2614
2659
  getSsgiPassOrUndefined() {
2615
- let e = this.renderPasses.get(kn.passId);
2616
- if (e && e instanceof kn) return e;
2660
+ let e = this.renderPasses.get(Mn.passId);
2661
+ if (e && e instanceof Mn) return e;
2617
2662
  }
2618
2663
  setShadingType(e) {
2619
2664
  e !== ce.DEFAULT && console.error("RoomleWebGPURenderer.setShadingType is not implemented yet");
2620
2665
  }
2621
2666
  showGUI(e) {
2622
- if (this.renderer.inspector instanceof yn) return;
2667
+ if (this.renderer.inspector instanceof Sn) return;
2623
2668
  let t = document.createElement("style");
2624
2669
  t.innerText = "#profiler-toggle,\n #profiler-mini-panel {\n left: 15px;\n right: auto !important;\n }", document.head.appendChild(t);
2625
- let n = new yn();
2670
+ let n = new Sn();
2626
2671
  this.renderer.inspector = n, this._domHelper.element?.appendChild(n.domElement), this.addDebugGUI(n, e), this.qualityManager.addGUI(n, e);
2627
2672
  let r = n.createParameters("Render Pass Settings");
2628
2673
  for (let t of this.renderPasses.values()) t.addParametersToGUI(r, e);
@@ -2635,10 +2680,18 @@ var Fn = /* @__PURE__ */ Array.from({ length: 32 }, (e, t) => [Pn(t + 1, 2), Pn(
2635
2680
  Outline: "outline",
2636
2681
  Direct: "direct lighting only",
2637
2682
  Ao: "ao only",
2638
- Gi: "gi only"
2683
+ Gi: "gi only",
2684
+ NoFog: "no fog",
2685
+ Depth: "depth"
2639
2686
  }).onChange((e) => {
2640
2687
  this.debugMode = e, this.passNeedsReassembly = !0, t();
2641
- });
2688
+ }), n.add({ reassembleRenderPasses: () => {
2689
+ this.passNeedsReassembly = !0, console.log("Reassembling render passes..."), t();
2690
+ } }, "reassembleRenderPasses");
2691
+ }
2692
+ applyToneMappingConfig() {
2693
+ let { toneMapping: e, toneMappingExposure: t } = this._initData.webGpuConfig;
2694
+ this.renderer.toneMapping = Yn[e], this.renderer.toneMappingExposure = t;
2642
2695
  }
2643
2696
  addToneMappingSettings(e, t) {
2644
2697
  let n = e.addFolder("Tone Mapping"), r = {
@@ -2661,7 +2714,7 @@ var Fn = /* @__PURE__ */ Array.from({ length: 32 }, (e, t) => [Pn(t + 1, 2), Pn(
2661
2714
  }
2662
2715
  getOrCreateGUIParameters(e) {
2663
2716
  let t = this.renderer.inspector;
2664
- if (t instanceof yn) return this.guiParameterGroups.get(e) ?? this.createAndCacheGUIParameters(t, e);
2717
+ if (t instanceof Sn) return this.guiParameterGroups.get(e) ?? this.createAndCacheGUIParameters(t, e);
2665
2718
  throw Error("Inspector GUI is not initialized. Call showGUI() before creating parameter groups.");
2666
2719
  }
2667
2720
  createAndCacheGUIParameters(e, t) {
@@ -2669,8 +2722,8 @@ var Fn = /* @__PURE__ */ Array.from({ length: 32 }, (e, t) => [Pn(t + 1, 2), Pn(
2669
2722
  return this.guiParameterGroups.set(t, n), n;
2670
2723
  }
2671
2724
  };
2672
- de([ue, le("design:type", Object)], Gn.prototype, "_domHelper", void 0), de([ue, le("design:type", Object)], Gn.prototype, "_webGpuGroundShadowReflection", void 0), de([ue, le("design:type", Object)], Gn.prototype, "_initData", void 0);
2725
+ de([ue, le("design:type", Object)], Xn.prototype, "_domHelper", void 0), de([ue, le("design:type", Object)], Xn.prototype, "_webGpuGroundShadowReflection", void 0), de([ue, le("design:type", Object)], Xn.prototype, "_initData", void 0);
2673
2726
  //#endregion
2674
- export { Gn as RoomleWebGPURenderer };
2727
+ export { Xn as RoomleWebGPURenderer };
2675
2728
 
2676
- //# sourceMappingURL=roomle-webgpu-renderer--zQziKoO.mjs.map
2729
+ //# sourceMappingURL=roomle-webgpu-renderer-CRGcdahn.mjs.map