iflow-engine-base-3d 4.0.0 → 4.0.2

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.
@@ -1,5 +1,5 @@
1
1
  import { S as ki, G as pe, P as Xt, O as Be, M as F, V as d, e as et, T as Vn, C as Vs, W as Li, a as Us, b as We, N as Bi, c as Ws, d as lt, f as W, Q as Te, E as Un, R as me, g as tt, h as Wn, B as R, i as zi, A as Gn, j as H, k as z, I as V, l as ri, m as ai, n as qn, o as Kn, L as Qt, p as Gs, q as qs, r as Ks, s as Yi, D as re, t as Xi, u as js, F as Ys, v as xe, w as jn, x as Yn, y as Ri, z as Xs, H as Xn, J as ae, K as Qs, U as $s, X as Et, Y as Zs, Z as Qn, _ as Js, $ as Ie, a0 as At, a1 as it, a2 as Xe, a3 as $t, a4 as Oi, a5 as Z, a6 as oe, a7 as St, a8 as eo, a9 as nt, aa as wi, ab as Ge, ac as Lt, ad as to, ae as io, af as bi, ag as pt, ah as no, ai as ut, aj as so, ak as oo, al as $n, am as Zt, an as Pt, ao as Jt, ap as ro, aq as Qi, ar as Tt, as as It, at as ao, au as lo, av as $i, aw as co, ax as ho, ay as uo, az as po, aA as mo, aB as go, aC as fo, aD as yo, aE as Mo, aF as vo, aG as Zn, aH as xo, aI as wo, aJ as bo, aK as Co, aL as Eo, aM as Ao, aN as So, aO as Po, aP as To, aQ as Io } from "./three-vendor-UroN9p1L.js";
2
- import { W as fe, C as _o, L as Mt, B as Zi, g as Oe, a as Do, E as ko, r as Lo } from "./sdk-runtime-BQIg-ngM.js";
2
+ import { W as fe, C as _o, L as Mt, B as Zi, g as Oe, a as Do, E as ko, r as Lo } from "./sdk-runtime-CqHiGQVN.js";
3
3
  import { r as ee, g as Bo } from "./sdk-assets-DHhjv3WO.js";
4
4
  import { a as ei, J as Ci, c as zo, b as Ro, P as li, q as Oo, k as Fo, n as Ji, E as en, S as No } from "./sdk-vendor-DYgn7sFs.js";
5
5
  class Ho {
@@ -442,8 +442,8 @@ class Uo {
442
442
  premultipliedAlpha: !1,
443
443
  stencil: !0,
444
444
  // iOS 保留 drawing buffer 会长期占用额外帧缓冲;移动端优先保证大模型稳定加载。
445
- preserveDrawingBuffer: !i
446
- }), this.renderer.setClearColor(0, 0), this.renderer.setSize(e, t, !1), this.renderer.setPixelRatio(Jn(this.engine)), this.renderer.domElement.style.width = "100%", this.renderer.domElement.style.width = "100%", this.renderer.domElement.style.height = "100%", this.renderer.domElement.style.display = "block", this.renderer.shadowMap.enabled = !i, this.renderer.shadowMap.type = Us, this.renderer.localClippingEnabled = !0, this.renderer.outputColorSpace = We, this.renderer.toneMapping = Bi, this.renderer.toneMappingExposure = Fi, this.engine.container.appendChild(this.renderer.domElement), this.renderer;
445
+ preserveDrawingBuffer: !0
446
+ }), this.renderer.setClearColor(0, 0), this.renderer.setSize(e, t, !1), this.renderer.setPixelRatio(Jn(this.engine)), this.renderer.domElement.style.width = "100%", this.renderer.domElement.style.width = "100%", this.renderer.domElement.style.height = "100%", this.renderer.domElement.style.display = "block", this.renderer.shadowMap.enabled = !0, this.renderer.shadowMap.type = Us, this.renderer.localClippingEnabled = !0, this.renderer.outputColorSpace = We, this.renderer.toneMapping = Bi, this.renderer.toneMappingExposure = Fi, this.engine.container.appendChild(this.renderer.domElement), this.renderer;
447
447
  }
448
448
  disposeRenderer() {
449
449
  this.watermark.dispose(), this.renderer?.dispose();
@@ -3485,7 +3485,7 @@ function ta(a) {
3485
3485
  typeof e?.close == "function" && e.close(), Array.isArray(a.mipmaps) && (a.mipmaps.length = 0), a.dispose(), a.source != null && (a.source.data = null);
3486
3486
  }
3487
3487
  function ws(a, e) {
3488
- if (e?.deviceModule?.isMobile?.() !== !0 || a == null)
3488
+ if (e?.deviceModule?.isMobile?.() !== !0 || e?.mobileMemoryProfile?.restrictTextureSize === !1 || a == null)
3489
3489
  return;
3490
3490
  const t = Array.isArray(a) ? a : [a], i = Number(e?.renderer?.capabilities?.maxTextureSize), n = Number(e?.mobileMemoryProfile?.maxTextureSize ?? 2048), s = Number.isFinite(i) ? Math.min(n, i) : n;
3491
3491
  t.forEach((o) => {
@@ -21017,18 +21017,25 @@ class Sh {
21017
21017
  }
21018
21018
  const Ph = Object.freeze({
21019
21019
  maxTextureSize: 1024,
21020
- samples: 0
21020
+ samples: 0,
21021
+ restrictTextureSize: !0
21021
21022
  }), Th = Object.freeze({
21022
21023
  maxTextureSize: 2048,
21023
- samples: 2
21024
+ samples: 4,
21025
+ restrictTextureSize: !0
21024
21026
  }), Ih = Object.freeze({
21025
21027
  maxTextureSize: 4096,
21026
- samples: 4
21028
+ samples: 4,
21029
+ restrictTextureSize: !0
21030
+ }), _h = Object.freeze({
21031
+ maxTextureSize: 4096,
21032
+ samples: 4,
21033
+ restrictTextureSize: !1
21027
21034
  });
21028
- function _h(a) {
21029
- return typeof a != "number" || !Number.isFinite(a) || a <= 4 ? Ph : a <= 6 ? Th : Ih;
21035
+ function Dh(a) {
21036
+ return typeof a != "number" || !Number.isFinite(a) || a <= 4 ? Ph : a <= 6 ? Th : a < 8 ? Ih : _h;
21030
21037
  }
21031
- class zh {
21038
+ class Rh {
21032
21039
  // 引擎参数
21033
21040
  options;
21034
21041
  mobileMemoryProfile;
@@ -21150,7 +21157,7 @@ class zh {
21150
21157
  // 引擎容器
21151
21158
  container;
21152
21159
  constructor(e) {
21153
- if (window.THREE = Vn, hr(), this.options = e, this.mobileMemoryProfile = _h(e.limit_memory), this.container = document.getElementById(e.containerId), !this.container)
21160
+ if (window.THREE = Vn, hr(), this.options = e, this.mobileMemoryProfile = Dh(e.limit_memory), this.container = document.getElementById(e.containerId), !this.container)
21154
21161
  throw new Error(`Container ${e.containerId} not found`);
21155
21162
  if (this.rxQuotaListMapper = new bh(this), this.filterLoaderModel = new Sh(this), this.engineModelModule = new Ua(this), this.engineModelModule.init(), this.deviceModule = new Vo(this), this.deviceType = this.deviceModule.getDeviceType(), this.cameraModule = new ie(this), this.sceneModule = new Ho(this), this.scene = this.sceneModule.scene, this.renderModule = new Uo(this), this.renderer = this.renderModule.createRenderer(), this.camera = this.cameraModule.perspectiveCamera, this.scene.camera = this.camera, this.renderer) {
21156
21163
  const o = this.renderer;
@@ -21508,6 +21515,6 @@ class zh {
21508
21515
  }
21509
21516
  }
21510
21517
  export {
21511
- zh as E,
21518
+ Rh as E,
21512
21519
  wh as M
21513
21520
  };
@@ -830,7 +830,7 @@ class Pt {
830
830
  e.stopImmediatePropagation();
831
831
  };
832
832
  }
833
- const Qe = "4.0.0", et = {
833
+ const Qe = "4.0.2", et = {
834
834
  version: Qe
835
835
  }, N = et.version;
836
836
  function ie() {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "iflow-engine-base-3d",
3
- "version": "4.0.0",
3
+ "version": "4.0.2",
4
4
  "description": "BIM Engine SDK for Vue2, Vue3, React and HTML",
5
5
  "main": "./dist/bim-engine-sdk.umd.js",
6
6
  "module": "./dist/bim-engine-sdk.es.js",