ss-component-new 1.2.97 → 1.2.99
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/MTLLoader-B4z0XNO-.js +304 -0
- package/dist/MTLLoader-n_3HPhif.cjs +2 -0
- package/dist/OBJLoader-C_JaUegI.cjs +5 -0
- package/dist/OBJLoader-Dilcv9TL.js +356 -0
- package/dist/{OrbitControls-B85G8nPk.cjs → OrbitControls-8LBwRzcq.cjs} +1 -1
- package/dist/{OrbitControls-DFhYzlF3.js → OrbitControls-Cz47Q27N.js} +1 -1
- package/dist/{animationData-DfKVkFbz.js → animationData-C8lM4zZj.js} +1 -1
- package/dist/{animationData-DxBvEqB1.cjs → animationData-CKcPDmLp.cjs} +1 -1
- package/dist/{iconfont-C7kE-QbU.cjs → iconfont-B1cUqs_N.cjs} +1 -1
- package/dist/{iconfont-WOKNi2xx.js → iconfont-CUWS5tNH.js} +2 -2
- package/dist/{index-D0hovh9R.cjs → index-2hqZ_tND.cjs} +1 -1
- package/dist/{index-331j518H.cjs → index-AuEh0RiU.cjs} +1 -1
- package/dist/{index-D_igus4A.cjs → index-B2UPNwqJ.cjs} +1 -1
- package/dist/{index-BYk9Fb6p.js → index-BCvmfE-Q.js} +3 -3
- package/dist/{index-DeOwZgqL.js → index-BDw8DIQx.js} +130 -130
- package/dist/{index-CqI3frdZ.js → index-BPv8txj6.js} +6 -6
- package/dist/{index-DgZVeYqH.js → index-BQaejVqo.js} +1 -1
- package/dist/{index-DSPjcpWK.cjs → index-Ba16ouw0.cjs} +1 -1
- package/dist/{index-D_RGoDln.js → index-BaSO3EEl.js} +3 -3
- package/dist/{index-DHZMd8iK.cjs → index-BdSiNUC0.cjs} +1 -1
- package/dist/{index-BDxPlbe2.cjs → index-BfU8GMj1.cjs} +1 -1
- package/dist/{index-Cppt0AsF.cjs → index-BjKKDSDx.cjs} +1 -1
- package/dist/{index-C-dlFxRJ.cjs → index-BqgfejIC.cjs} +1 -1
- package/dist/{index-BODyH6MD.js → index-BxONUPjM.js} +1 -1
- package/dist/{index-BFzMf0GC.js → index-Byp3gJNW.js} +1 -1
- package/dist/{index-DJ6qg2Mo.js → index-C7ZsHeLt.js} +3 -3
- package/dist/{index-B-AhHUV1.js → index-C9p_wwJ7.js} +6 -6
- package/dist/{index-BoTiP0aV.js → index-CKlt750z.js} +1 -1
- package/dist/{index-CQRJ3pLh.cjs → index-CQwDw3-2.cjs} +1 -1
- package/dist/{index-hhS08X8b.js → index-CR1Ng5ip.js} +3 -3
- package/dist/{index-D6u590uA.cjs → index-CZIqVNof.cjs} +1 -1
- package/dist/{index-iErxMZBi.cjs → index-C_208RkZ.cjs} +1 -1
- package/dist/{index-S1LIIzCa.cjs → index-CqZ1E-Mt.cjs} +1 -1
- package/dist/{index-DHjtOySN.js → index-CrNsPd4D.js} +2 -2
- package/dist/{index-DrzK0O_g.cjs → index-CvQCAGWI.cjs} +1 -1
- package/dist/{index-Cnk_4Zz5.cjs → index-CyCcPnZb.cjs} +1 -1
- package/dist/{index-BI7g3c_u.js → index-CyE5qCBb.js} +13 -13
- package/dist/{index-DHBoRe9V.cjs → index-D32pAhQk.cjs} +1 -1
- package/dist/{index-DRfVnLTN.js → index-DAUjjqaD.js} +391 -391
- package/dist/{index-DbDM-XfB.cjs → index-DQTlc6Gq.cjs} +1 -1
- package/dist/{index-B_zjoT4m.js → index-DTilOAv_.js} +2 -2
- package/dist/{index-_PP-dSm3.cjs → index-D_22J0ok.cjs} +1 -1
- package/dist/{index-iZ9BRKg5.js → index-DboUMA_C.js} +1 -1
- package/dist/{index-BXv3aZ7v.js → index-DgMQpO6g.js} +1 -1
- package/dist/{index-CPAXrzNY.cjs → index-Dh6GqpZF.cjs} +1 -1
- package/dist/{index-CZPnP0uy.cjs → index-DhqEoDPT.cjs} +1 -1
- package/dist/{index-CeGM8aBH.js → index-DlwlGkyt.js} +2 -2
- package/dist/{index-6sZXjGGz.cjs → index-DtDmxPdD.cjs} +1 -1
- package/dist/{index-kLDMroPk.js → index-GxmJC9kr.js} +1 -1
- package/dist/{index-CLOUp_4j.cjs → index-XKn5AuYT.cjs} +1 -1
- package/dist/{index-Cr5if46q.js → index-mEKMjplD.js} +1 -1
- package/dist/{index-Bhha7SY3.js → index-vglZ0qjT.js} +1 -1
- package/dist/{index.vue_vue_type_style_index_0_scoped_0b6f1a18_lang-DSlAeFA3.cjs → index.vue_vue_type_style_index_0_scoped_0b6f1a18_lang-DKwCF412.cjs} +1 -1
- package/dist/{index.vue_vue_type_style_index_0_scoped_0b6f1a18_lang-ERjMISIK.js → index.vue_vue_type_style_index_0_scoped_0b6f1a18_lang-DqIuWlps.js} +6 -6
- package/dist/{index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-3GcG1eTD.js → index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-CICG8Qah.js} +8908 -8949
- package/dist/{index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-Dzyqt2Z-.cjs → index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-K6lh7Rrj.cjs} +302 -302
- package/dist/{index.vue_vue_type_style_index_0_scoped_92477073_lang-mJB_yl_P.js → index.vue_vue_type_style_index_0_scoped_92477073_lang-Cpyo5jke.js} +3 -3
- package/dist/{index.vue_vue_type_style_index_0_scoped_92477073_lang-DODc2KPN.cjs → index.vue_vue_type_style_index_0_scoped_92477073_lang-Cq8VF9uK.cjs} +1 -1
- package/dist/{index.vue_vue_type_style_index_1_lang-BH0DRFVE.js → index.vue_vue_type_style_index_1_lang-B_HCEX9y.js} +6 -5
- package/dist/{index.vue_vue_type_style_index_1_lang-BRFs_L5R.cjs → index.vue_vue_type_style_index_1_lang-rTLLuvuo.cjs} +5 -5
- package/dist/loaderUtil-B0djdt91.js +5 -0
- package/dist/loaderUtil-CaWWb8db.cjs +1 -0
- package/dist/{main-Z5UMyCj6.js → main-DHx-3OSy.js} +2 -2
- package/dist/{main-B541MQH8.cjs → main-DS156sQ4.cjs} +1 -1
- package/dist/ss-component.cjs +1 -1
- package/dist/ss-component.css +1 -1
- package/dist/ss-component.js +9 -9
- package/dist/ss-component2.cjs +1 -1
- package/dist/ss-component2.js +10 -10
- package/dist/{threeModel-tKq0hvaK.cjs → threeModel-CfIK1rQB.cjs} +1 -1
- package/dist/{threeModel-BcjGbIJZ.js → threeModel-WYCdw_Ff.js} +4 -4
- package/dist/{threePreview-BnPMGQ2H.js → threePreview-C29AR7Mr.js} +310 -305
- package/dist/threePreview-Ci8TnUQ8.cjs +1 -0
- package/dist/{threeSceneView-DVUTlm6F.cjs → threeSceneView-C2MDCMux.cjs} +2 -2
- package/dist/{threeSceneView-BUD002PP.js → threeSceneView-F15mW1mm.js} +7 -7
- package/dist/threeSceneViewForCPMPIP-DK4G_ZpP.js +687 -0
- package/dist/threeSceneViewForCPMPIP-DuPZn_qv.cjs +5 -0
- package/dist/threeTrackPathView-C4eBUMef.cjs +370 -0
- package/dist/{threeTrackPathView-DDCEu3Gx.js → threeTrackPathView-DMj6YGxT.js} +436 -427
- package/dist/{threeViewerHost-BVeUteVd.js → threeViewerHost-C9ipsMff.js} +2 -2
- package/dist/{threeViewerHost-Sda_AoRw.cjs → threeViewerHost-CW6JmOUJ.cjs} +2 -2
- package/dist/{urdfTree-Br9VYqKp.cjs → urdfTree-CTiMB7ge.cjs} +1 -1
- package/dist/{urdfTree-DaWvX-6R.js → urdfTree-DGEACy9-.js} +1 -1
- package/dist/{workpieceTreePanel-BdRaFNRp.js → workpieceTreePanel-C1gy5a8r.js} +53 -52
- package/dist/workpieceTreePanel-Ded0Gqke.cjs +1 -0
- package/package.json +1 -1
- package/dist/MTLLoader-DnouUI-8.js +0 -657
- package/dist/MTLLoader-zZDM0NQh.cjs +0 -6
- package/dist/obj/model.mtl +0 -42
- package/dist/obj/model.obj +0 -26110
- package/dist/threePreview-DD0br2ae.cjs +0 -1
- package/dist/threeSceneViewForCPMPIP-BYYbyqD7.cjs +0 -5
- package/dist/threeSceneViewForCPMPIP-D4RC4BAo.js +0 -683
- package/dist/threeTrackPathView-BvUihuyk.cjs +0 -370
- package/dist/workpieceTreePanel-Z3aVdOWB.cjs +0 -1
- package/public/obj/model.mtl +0 -42
- package/public/obj/model.obj +0 -26110
|
@@ -1,14 +1,15 @@
|
|
|
1
|
-
import { ref as
|
|
2
|
-
import { u as
|
|
3
|
-
import { J as
|
|
4
|
-
import { E as
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
|
|
9
|
-
|
|
1
|
+
import { ref as V, shallowRef as Ve, defineComponent as ze, watch as ee, onMounted as Xe, nextTick as qe, onBeforeUnmount as We, resolveComponent as Ye, createElementBlock as ne, openBlock as te, createElementVNode as L, withDirectives as X, createCommentVNode as me, createVNode as U, unref as w, renderSlot as ge, toDisplayString as Te, withCtx as $e, isRef as J, vModelRadio as Q, vShow as Je } from "vue";
|
|
2
|
+
import { u as Qe, a as Ze, b as en } from "./iconfont-CUWS5tNH.js";
|
|
3
|
+
import { J as nn, K as le, N as Ne, O as tn, Q as Y, R as Ie, U as O, Y as Ce, C as j, Z as P, f as $, _ as sn, n as rn, D as on, r as Z, V as K, $ as an, a0 as Oe, a1 as cn, a2 as ve, a3 as ln, a4 as un, a5 as se, a6 as fn, a7 as ke, a8 as dn, a9 as hn, aa as pn, ab as ue, ac as Pe, ad as fe, ae as mn, af as gn, ag as Tn, ah as re, ai as xn, v as Fe, p as Rn, aj as W, ak as En, w as An, al as _n, k as De, am as Ln, y as Mn, an as wn, ao as yn, u as ie, P as bn, s as Sn, ap as Nn, aq as In, ar as Cn, as as On, at as vn, au as He, av as kn, aw as xe, ax as Re, ay as Ee, az as Ae, aA as _e, aB as Pn, aC as Fn, B as Ue, aD as Dn, o as Hn } from "./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-CICG8Qah.js";
|
|
4
|
+
import { E as Le } from "./index-BUYYl2Pc.js";
|
|
5
|
+
import { O as Un } from "./OBJLoader-Dilcv9TL.js";
|
|
6
|
+
import { M as Gn, S as jn } from "./MTLLoader-B4z0XNO-.js";
|
|
7
|
+
import { T as B } from "./svgIcon-D-_fXUBL.js";
|
|
8
|
+
import { _ as Bn } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
9
|
+
function Me(f, n) {
|
|
10
|
+
if (n === nn)
|
|
10
11
|
return console.warn("THREE.BufferGeometryUtils.toTrianglesDrawMode(): Geometry already defined as triangles."), f;
|
|
11
|
-
if (n ===
|
|
12
|
+
if (n === le || n === Ne) {
|
|
12
13
|
let e = f.getIndex();
|
|
13
14
|
if (e === null) {
|
|
14
15
|
const r = [], a = f.getAttribute("position");
|
|
@@ -20,7 +21,7 @@ function Le(f, n) {
|
|
|
20
21
|
return console.error("THREE.BufferGeometryUtils.toTrianglesDrawMode(): Undefined position attribute. Processing not possible."), f;
|
|
21
22
|
}
|
|
22
23
|
const i = e.count - 2, t = [];
|
|
23
|
-
if (n ===
|
|
24
|
+
if (n === le)
|
|
24
25
|
for (let r = 1; r <= i; r++)
|
|
25
26
|
t.push(e.getX(0)), t.push(e.getX(r)), t.push(e.getX(r + 1));
|
|
26
27
|
else
|
|
@@ -32,7 +33,7 @@ function Le(f, n) {
|
|
|
32
33
|
} else
|
|
33
34
|
return console.error("THREE.BufferGeometryUtils.toTrianglesDrawMode(): Unknown draw mode:", n), f;
|
|
34
35
|
}
|
|
35
|
-
class
|
|
36
|
+
class Kn extends tn {
|
|
36
37
|
/**
|
|
37
38
|
* Constructs a new glTF loader.
|
|
38
39
|
*
|
|
@@ -40,39 +41,39 @@ class jn extends en {
|
|
|
40
41
|
*/
|
|
41
42
|
constructor(n) {
|
|
42
43
|
super(n), this.dracoLoader = null, this.ktx2Loader = null, this.meshoptDecoder = null, this.pluginCallbacks = [], this.register(function(e) {
|
|
43
|
-
return new
|
|
44
|
-
}), this.register(function(e) {
|
|
45
|
-
return new qn(e);
|
|
46
|
-
}), this.register(function(e) {
|
|
47
|
-
return new tt(e);
|
|
44
|
+
return new Wn(e);
|
|
48
45
|
}), this.register(function(e) {
|
|
49
|
-
return new
|
|
46
|
+
return new Yn(e);
|
|
50
47
|
}), this.register(function(e) {
|
|
51
48
|
return new rt(e);
|
|
52
49
|
}), this.register(function(e) {
|
|
53
|
-
return new
|
|
50
|
+
return new it(e);
|
|
54
51
|
}), this.register(function(e) {
|
|
55
|
-
return new
|
|
52
|
+
return new ot(e);
|
|
56
53
|
}), this.register(function(e) {
|
|
57
54
|
return new Jn(e);
|
|
58
55
|
}), this.register(function(e) {
|
|
59
56
|
return new Qn(e);
|
|
60
|
-
}), this.register(function(e) {
|
|
61
|
-
return new zn(e);
|
|
62
57
|
}), this.register(function(e) {
|
|
63
58
|
return new Zn(e);
|
|
64
59
|
}), this.register(function(e) {
|
|
65
|
-
return new
|
|
60
|
+
return new et(e);
|
|
61
|
+
}), this.register(function(e) {
|
|
62
|
+
return new qn(e);
|
|
66
63
|
}), this.register(function(e) {
|
|
67
64
|
return new nt(e);
|
|
68
65
|
}), this.register(function(e) {
|
|
69
|
-
return new
|
|
66
|
+
return new $n(e);
|
|
70
67
|
}), this.register(function(e) {
|
|
71
|
-
return new
|
|
68
|
+
return new st(e);
|
|
72
69
|
}), this.register(function(e) {
|
|
73
|
-
return new
|
|
70
|
+
return new tt(e);
|
|
74
71
|
}), this.register(function(e) {
|
|
75
|
-
return new
|
|
72
|
+
return new zn(e);
|
|
73
|
+
}), this.register(function(e) {
|
|
74
|
+
return new at(e);
|
|
75
|
+
}), this.register(function(e) {
|
|
76
|
+
return new ct(e);
|
|
76
77
|
});
|
|
77
78
|
}
|
|
78
79
|
/**
|
|
@@ -90,14 +91,14 @@ class jn extends en {
|
|
|
90
91
|
if (this.resourcePath !== "")
|
|
91
92
|
r = this.resourcePath;
|
|
92
93
|
else if (this.path !== "") {
|
|
93
|
-
const c =
|
|
94
|
-
r =
|
|
94
|
+
const c = Y.extractUrlBase(n);
|
|
95
|
+
r = Y.resolveURL(c, this.path);
|
|
95
96
|
} else
|
|
96
|
-
r =
|
|
97
|
+
r = Y.extractUrlBase(n);
|
|
97
98
|
this.manager.itemStart(n);
|
|
98
99
|
const a = function(c) {
|
|
99
100
|
t ? t(c) : console.error(c), s.manager.itemError(n), s.manager.itemEnd(n);
|
|
100
|
-
}, o = new
|
|
101
|
+
}, o = new Ie(this.manager);
|
|
101
102
|
o.setPath(this.path), o.setResponseType("arraybuffer"), o.setRequestHeader(this.requestHeader), o.setWithCredentials(this.withCredentials), o.load(n, function(c) {
|
|
102
103
|
try {
|
|
103
104
|
s.parse(c, r, function(u) {
|
|
@@ -172,9 +173,9 @@ class jn extends en {
|
|
|
172
173
|
if (typeof n == "string")
|
|
173
174
|
s = JSON.parse(n);
|
|
174
175
|
else if (n instanceof ArrayBuffer)
|
|
175
|
-
if (o.decode(new Uint8Array(n, 0, 4)) ===
|
|
176
|
+
if (o.decode(new Uint8Array(n, 0, 4)) === Ge) {
|
|
176
177
|
try {
|
|
177
|
-
r[R.KHR_BINARY_GLTF] = new
|
|
178
|
+
r[R.KHR_BINARY_GLTF] = new lt(n);
|
|
178
179
|
} catch (l) {
|
|
179
180
|
t && t(l);
|
|
180
181
|
return;
|
|
@@ -188,7 +189,7 @@ class jn extends en {
|
|
|
188
189
|
t && t(new Error("THREE.GLTFLoader: Unsupported asset. glTF versions >=2.0 are supported."));
|
|
189
190
|
return;
|
|
190
191
|
}
|
|
191
|
-
const c = new
|
|
192
|
+
const c = new _t(s, {
|
|
192
193
|
path: e || this.resourcePath || "",
|
|
193
194
|
crossOrigin: this.crossOrigin,
|
|
194
195
|
requestHeader: this.requestHeader,
|
|
@@ -206,16 +207,16 @@ class jn extends en {
|
|
|
206
207
|
const l = s.extensionsUsed[u], d = s.extensionsRequired || [];
|
|
207
208
|
switch (l) {
|
|
208
209
|
case R.KHR_MATERIALS_UNLIT:
|
|
209
|
-
r[l] = new
|
|
210
|
+
r[l] = new Xn();
|
|
210
211
|
break;
|
|
211
212
|
case R.KHR_DRACO_MESH_COMPRESSION:
|
|
212
|
-
r[l] = new
|
|
213
|
+
r[l] = new ut(s, this.dracoLoader);
|
|
213
214
|
break;
|
|
214
215
|
case R.KHR_TEXTURE_TRANSFORM:
|
|
215
|
-
r[l] = new
|
|
216
|
+
r[l] = new ft();
|
|
216
217
|
break;
|
|
217
218
|
case R.KHR_MESH_QUANTIZATION:
|
|
218
|
-
r[l] = new
|
|
219
|
+
r[l] = new dt();
|
|
219
220
|
break;
|
|
220
221
|
default:
|
|
221
222
|
d.indexOf(l) >= 0 && a[l] === void 0 && console.warn('THREE.GLTFLoader: Unknown extension "' + l + '".');
|
|
@@ -238,7 +239,7 @@ class jn extends en {
|
|
|
238
239
|
});
|
|
239
240
|
}
|
|
240
241
|
}
|
|
241
|
-
function
|
|
242
|
+
function Vn() {
|
|
242
243
|
let f = {};
|
|
243
244
|
return {
|
|
244
245
|
get: function(n) {
|
|
@@ -279,7 +280,7 @@ const R = {
|
|
|
279
280
|
EXT_MESHOPT_COMPRESSION: "EXT_meshopt_compression",
|
|
280
281
|
EXT_MESH_GPU_INSTANCING: "EXT_mesh_gpu_instancing"
|
|
281
282
|
};
|
|
282
|
-
class
|
|
283
|
+
class zn {
|
|
283
284
|
constructor(n) {
|
|
284
285
|
this.parser = n, this.name = R.KHR_LIGHTS_PUNCTUAL, this.cache = { refs: {}, uses: {} };
|
|
285
286
|
}
|
|
@@ -296,18 +297,18 @@ class Kn {
|
|
|
296
297
|
if (t) return t;
|
|
297
298
|
const s = e.json, o = ((s.extensions && s.extensions[this.name] || {}).lights || [])[n];
|
|
298
299
|
let c;
|
|
299
|
-
const u = new
|
|
300
|
+
const u = new j(16777215);
|
|
300
301
|
o.color !== void 0 && u.setRGB(o.color[0], o.color[1], o.color[2], P);
|
|
301
302
|
const l = o.range !== void 0 ? o.range : 0;
|
|
302
303
|
switch (o.type) {
|
|
303
304
|
case "directional":
|
|
304
|
-
c = new
|
|
305
|
+
c = new on(u), c.target.position.set(0, 0, -1), c.add(c.target);
|
|
305
306
|
break;
|
|
306
307
|
case "point":
|
|
307
|
-
c = new
|
|
308
|
+
c = new rn(u), c.distance = l;
|
|
308
309
|
break;
|
|
309
310
|
case "spot":
|
|
310
|
-
c = new
|
|
311
|
+
c = new sn(u), c.distance = l, o.spot = o.spot || {}, o.spot.innerConeAngle = o.spot.innerConeAngle !== void 0 ? o.spot.innerConeAngle : 0, o.spot.outerConeAngle = o.spot.outerConeAngle !== void 0 ? o.spot.outerConeAngle : Math.PI / 4, c.angle = o.spot.outerConeAngle, c.penumbra = 1 - o.spot.innerConeAngle / o.spot.outerConeAngle, c.target.position.set(0, 0, -1), c.add(c.target);
|
|
311
312
|
break;
|
|
312
313
|
default:
|
|
313
314
|
throw new Error("THREE.GLTFLoader: Unexpected light type: " + o.type);
|
|
@@ -325,28 +326,28 @@ class Kn {
|
|
|
325
326
|
});
|
|
326
327
|
}
|
|
327
328
|
}
|
|
328
|
-
class
|
|
329
|
+
class Xn {
|
|
329
330
|
constructor() {
|
|
330
331
|
this.name = R.KHR_MATERIALS_UNLIT;
|
|
331
332
|
}
|
|
332
333
|
getMaterialType() {
|
|
333
|
-
return
|
|
334
|
+
return W;
|
|
334
335
|
}
|
|
335
336
|
extendParams(n, e, i) {
|
|
336
337
|
const t = [];
|
|
337
|
-
n.color = new
|
|
338
|
+
n.color = new j(1, 1, 1), n.opacity = 1;
|
|
338
339
|
const s = e.pbrMetallicRoughness;
|
|
339
340
|
if (s) {
|
|
340
341
|
if (Array.isArray(s.baseColorFactor)) {
|
|
341
342
|
const r = s.baseColorFactor;
|
|
342
343
|
n.color.setRGB(r[0], r[1], r[2], P), n.opacity = r[3];
|
|
343
344
|
}
|
|
344
|
-
s.baseColorTexture !== void 0 && t.push(i.assignTexture(n, "map", s.baseColorTexture,
|
|
345
|
+
s.baseColorTexture !== void 0 && t.push(i.assignTexture(n, "map", s.baseColorTexture, $));
|
|
345
346
|
}
|
|
346
347
|
return Promise.all(t);
|
|
347
348
|
}
|
|
348
349
|
}
|
|
349
|
-
class
|
|
350
|
+
class qn {
|
|
350
351
|
constructor(n) {
|
|
351
352
|
this.parser = n, this.name = R.KHR_MATERIALS_EMISSIVE_STRENGTH;
|
|
352
353
|
}
|
|
@@ -358,7 +359,7 @@ class zn {
|
|
|
358
359
|
return s !== void 0 && (e.emissiveIntensity = s), Promise.resolve();
|
|
359
360
|
}
|
|
360
361
|
}
|
|
361
|
-
class
|
|
362
|
+
class Wn {
|
|
362
363
|
constructor(n) {
|
|
363
364
|
this.parser = n, this.name = R.KHR_MATERIALS_CLEARCOAT;
|
|
364
365
|
}
|
|
@@ -373,12 +374,12 @@ class Xn {
|
|
|
373
374
|
const s = [], r = t.extensions[this.name];
|
|
374
375
|
if (r.clearcoatFactor !== void 0 && (e.clearcoat = r.clearcoatFactor), r.clearcoatTexture !== void 0 && s.push(i.assignTexture(e, "clearcoatMap", r.clearcoatTexture)), r.clearcoatRoughnessFactor !== void 0 && (e.clearcoatRoughness = r.clearcoatRoughnessFactor), r.clearcoatRoughnessTexture !== void 0 && s.push(i.assignTexture(e, "clearcoatRoughnessMap", r.clearcoatRoughnessTexture)), r.clearcoatNormalTexture !== void 0 && (s.push(i.assignTexture(e, "clearcoatNormalMap", r.clearcoatNormalTexture)), r.clearcoatNormalTexture.scale !== void 0)) {
|
|
375
376
|
const a = r.clearcoatNormalTexture.scale;
|
|
376
|
-
e.clearcoatNormalScale = new
|
|
377
|
+
e.clearcoatNormalScale = new Ce(a, a);
|
|
377
378
|
}
|
|
378
379
|
return Promise.all(s);
|
|
379
380
|
}
|
|
380
381
|
}
|
|
381
|
-
class
|
|
382
|
+
class Yn {
|
|
382
383
|
constructor(n) {
|
|
383
384
|
this.parser = n, this.name = R.KHR_MATERIALS_DISPERSION;
|
|
384
385
|
}
|
|
@@ -394,7 +395,7 @@ class qn {
|
|
|
394
395
|
return e.dispersion = s.dispersion !== void 0 ? s.dispersion : 0, Promise.resolve();
|
|
395
396
|
}
|
|
396
397
|
}
|
|
397
|
-
class
|
|
398
|
+
class $n {
|
|
398
399
|
constructor(n) {
|
|
399
400
|
this.parser = n, this.name = R.KHR_MATERIALS_IRIDESCENCE;
|
|
400
401
|
}
|
|
@@ -410,7 +411,7 @@ class Wn {
|
|
|
410
411
|
return r.iridescenceFactor !== void 0 && (e.iridescence = r.iridescenceFactor), r.iridescenceTexture !== void 0 && s.push(i.assignTexture(e, "iridescenceMap", r.iridescenceTexture)), r.iridescenceIor !== void 0 && (e.iridescenceIOR = r.iridescenceIor), e.iridescenceThicknessRange === void 0 && (e.iridescenceThicknessRange = [100, 400]), r.iridescenceThicknessMinimum !== void 0 && (e.iridescenceThicknessRange[0] = r.iridescenceThicknessMinimum), r.iridescenceThicknessMaximum !== void 0 && (e.iridescenceThicknessRange[1] = r.iridescenceThicknessMaximum), r.iridescenceThicknessTexture !== void 0 && s.push(i.assignTexture(e, "iridescenceThicknessMap", r.iridescenceThicknessTexture)), Promise.all(s);
|
|
411
412
|
}
|
|
412
413
|
}
|
|
413
|
-
class
|
|
414
|
+
class Jn {
|
|
414
415
|
constructor(n) {
|
|
415
416
|
this.parser = n, this.name = R.KHR_MATERIALS_SHEEN;
|
|
416
417
|
}
|
|
@@ -423,16 +424,16 @@ class Yn {
|
|
|
423
424
|
if (!t.extensions || !t.extensions[this.name])
|
|
424
425
|
return Promise.resolve();
|
|
425
426
|
const s = [];
|
|
426
|
-
e.sheenColor = new
|
|
427
|
+
e.sheenColor = new j(0, 0, 0), e.sheenRoughness = 0, e.sheen = 1;
|
|
427
428
|
const r = t.extensions[this.name];
|
|
428
429
|
if (r.sheenColorFactor !== void 0) {
|
|
429
430
|
const a = r.sheenColorFactor;
|
|
430
431
|
e.sheenColor.setRGB(a[0], a[1], a[2], P);
|
|
431
432
|
}
|
|
432
|
-
return r.sheenRoughnessFactor !== void 0 && (e.sheenRoughness = r.sheenRoughnessFactor), r.sheenColorTexture !== void 0 && s.push(i.assignTexture(e, "sheenColorMap", r.sheenColorTexture,
|
|
433
|
+
return r.sheenRoughnessFactor !== void 0 && (e.sheenRoughness = r.sheenRoughnessFactor), r.sheenColorTexture !== void 0 && s.push(i.assignTexture(e, "sheenColorMap", r.sheenColorTexture, $)), r.sheenRoughnessTexture !== void 0 && s.push(i.assignTexture(e, "sheenRoughnessMap", r.sheenRoughnessTexture)), Promise.all(s);
|
|
433
434
|
}
|
|
434
435
|
}
|
|
435
|
-
class
|
|
436
|
+
class Qn {
|
|
436
437
|
constructor(n) {
|
|
437
438
|
this.parser = n, this.name = R.KHR_MATERIALS_TRANSMISSION;
|
|
438
439
|
}
|
|
@@ -448,7 +449,7 @@ class $n {
|
|
|
448
449
|
return r.transmissionFactor !== void 0 && (e.transmission = r.transmissionFactor), r.transmissionTexture !== void 0 && s.push(i.assignTexture(e, "transmissionMap", r.transmissionTexture)), Promise.all(s);
|
|
449
450
|
}
|
|
450
451
|
}
|
|
451
|
-
class
|
|
452
|
+
class Zn {
|
|
452
453
|
constructor(n) {
|
|
453
454
|
this.parser = n, this.name = R.KHR_MATERIALS_VOLUME;
|
|
454
455
|
}
|
|
@@ -463,10 +464,10 @@ class Jn {
|
|
|
463
464
|
const s = [], r = t.extensions[this.name];
|
|
464
465
|
e.thickness = r.thicknessFactor !== void 0 ? r.thicknessFactor : 0, r.thicknessTexture !== void 0 && s.push(i.assignTexture(e, "thicknessMap", r.thicknessTexture)), e.attenuationDistance = r.attenuationDistance || 1 / 0;
|
|
465
466
|
const a = r.attenuationColor || [1, 1, 1];
|
|
466
|
-
return e.attenuationColor = new
|
|
467
|
+
return e.attenuationColor = new j().setRGB(a[0], a[1], a[2], P), Promise.all(s);
|
|
467
468
|
}
|
|
468
469
|
}
|
|
469
|
-
class
|
|
470
|
+
class et {
|
|
470
471
|
constructor(n) {
|
|
471
472
|
this.parser = n, this.name = R.KHR_MATERIALS_IOR;
|
|
472
473
|
}
|
|
@@ -482,7 +483,7 @@ class Qn {
|
|
|
482
483
|
return e.ior = s.ior !== void 0 ? s.ior : 1.5, Promise.resolve();
|
|
483
484
|
}
|
|
484
485
|
}
|
|
485
|
-
class
|
|
486
|
+
class nt {
|
|
486
487
|
constructor(n) {
|
|
487
488
|
this.parser = n, this.name = R.KHR_MATERIALS_SPECULAR;
|
|
488
489
|
}
|
|
@@ -497,10 +498,10 @@ class Zn {
|
|
|
497
498
|
const s = [], r = t.extensions[this.name];
|
|
498
499
|
e.specularIntensity = r.specularFactor !== void 0 ? r.specularFactor : 1, r.specularTexture !== void 0 && s.push(i.assignTexture(e, "specularIntensityMap", r.specularTexture));
|
|
499
500
|
const a = r.specularColorFactor || [1, 1, 1];
|
|
500
|
-
return e.specularColor = new
|
|
501
|
+
return e.specularColor = new j().setRGB(a[0], a[1], a[2], P), r.specularColorTexture !== void 0 && s.push(i.assignTexture(e, "specularColorMap", r.specularColorTexture, $)), Promise.all(s);
|
|
501
502
|
}
|
|
502
503
|
}
|
|
503
|
-
class
|
|
504
|
+
class tt {
|
|
504
505
|
constructor(n) {
|
|
505
506
|
this.parser = n, this.name = R.EXT_MATERIALS_BUMP;
|
|
506
507
|
}
|
|
@@ -516,7 +517,7 @@ class et {
|
|
|
516
517
|
return e.bumpScale = r.bumpFactor !== void 0 ? r.bumpFactor : 1, r.bumpTexture !== void 0 && s.push(i.assignTexture(e, "bumpMap", r.bumpTexture)), Promise.all(s);
|
|
517
518
|
}
|
|
518
519
|
}
|
|
519
|
-
class
|
|
520
|
+
class st {
|
|
520
521
|
constructor(n) {
|
|
521
522
|
this.parser = n, this.name = R.KHR_MATERIALS_ANISOTROPY;
|
|
522
523
|
}
|
|
@@ -532,7 +533,7 @@ class nt {
|
|
|
532
533
|
return r.anisotropyStrength !== void 0 && (e.anisotropy = r.anisotropyStrength), r.anisotropyRotation !== void 0 && (e.anisotropyRotation = r.anisotropyRotation), r.anisotropyTexture !== void 0 && s.push(i.assignTexture(e, "anisotropyMap", r.anisotropyTexture)), Promise.all(s);
|
|
533
534
|
}
|
|
534
535
|
}
|
|
535
|
-
class
|
|
536
|
+
class rt {
|
|
536
537
|
constructor(n) {
|
|
537
538
|
this.parser = n, this.name = R.KHR_TEXTURE_BASISU;
|
|
538
539
|
}
|
|
@@ -549,7 +550,7 @@ class tt {
|
|
|
549
550
|
return e.loadTextureImage(n, s.source, r);
|
|
550
551
|
}
|
|
551
552
|
}
|
|
552
|
-
class
|
|
553
|
+
class it {
|
|
553
554
|
constructor(n) {
|
|
554
555
|
this.parser = n, this.name = R.EXT_TEXTURE_WEBP;
|
|
555
556
|
}
|
|
@@ -566,7 +567,7 @@ class st {
|
|
|
566
567
|
return i.loadTextureImage(n, r.source, o);
|
|
567
568
|
}
|
|
568
569
|
}
|
|
569
|
-
class
|
|
570
|
+
class ot {
|
|
570
571
|
constructor(n) {
|
|
571
572
|
this.parser = n, this.name = R.EXT_TEXTURE_AVIF;
|
|
572
573
|
}
|
|
@@ -583,7 +584,7 @@ class rt {
|
|
|
583
584
|
return i.loadTextureImage(n, r.source, o);
|
|
584
585
|
}
|
|
585
586
|
}
|
|
586
|
-
class
|
|
587
|
+
class at {
|
|
587
588
|
constructor(n) {
|
|
588
589
|
this.name = R.EXT_MESHOPT_COMPRESSION, this.parser = n;
|
|
589
590
|
}
|
|
@@ -609,7 +610,7 @@ class it {
|
|
|
609
610
|
return null;
|
|
610
611
|
}
|
|
611
612
|
}
|
|
612
|
-
class
|
|
613
|
+
class ct {
|
|
613
614
|
constructor(n) {
|
|
614
615
|
this.name = R.EXT_MESH_GPU_INSTANCING, this.parser = n;
|
|
615
616
|
}
|
|
@@ -627,44 +628,44 @@ class ot {
|
|
|
627
628
|
return a.length < 1 ? null : (a.push(this.parser.createNodeMesh(n)), Promise.all(a).then((c) => {
|
|
628
629
|
const u = c.pop(), l = u.isGroup ? u.children : [u], d = c[0].count, h = [];
|
|
629
630
|
for (const p of l) {
|
|
630
|
-
const x = new
|
|
631
|
+
const x = new Z(), m = new K(), g = new Oe(), E = new K(1, 1, 1), M = new an(p.geometry, p.material, d);
|
|
631
632
|
for (let T = 0; T < d; T++)
|
|
632
633
|
o.TRANSLATION && m.fromBufferAttribute(o.TRANSLATION, T), o.ROTATION && g.fromBufferAttribute(o.ROTATION, T), o.SCALE && E.fromBufferAttribute(o.SCALE, T), M.setMatrixAt(T, x.compose(m, g, E));
|
|
633
634
|
for (const T in o)
|
|
634
635
|
if (T === "_COLOR_0") {
|
|
635
|
-
const
|
|
636
|
-
M.instanceColor = new
|
|
636
|
+
const b = o[T];
|
|
637
|
+
M.instanceColor = new cn(b.array, b.itemSize, b.normalized);
|
|
637
638
|
} else T !== "TRANSLATION" && T !== "ROTATION" && T !== "SCALE" && p.geometry.setAttribute(T, o[T]);
|
|
638
|
-
|
|
639
|
+
ve.prototype.copy.call(M, p), this.parser.assignFinalMaterial(M), h.push(M);
|
|
639
640
|
}
|
|
640
641
|
return u.isGroup ? (u.clear(), u.add(...h), u) : h[0];
|
|
641
642
|
}));
|
|
642
643
|
}
|
|
643
644
|
}
|
|
644
|
-
const
|
|
645
|
-
class
|
|
645
|
+
const Ge = "glTF", q = 12, we = { JSON: 1313821514, BIN: 5130562 };
|
|
646
|
+
class lt {
|
|
646
647
|
constructor(n) {
|
|
647
648
|
this.name = R.KHR_BINARY_GLTF, this.content = null, this.body = null;
|
|
648
|
-
const e = new DataView(n, 0,
|
|
649
|
+
const e = new DataView(n, 0, q), i = new TextDecoder();
|
|
649
650
|
if (this.header = {
|
|
650
651
|
magic: i.decode(new Uint8Array(n.slice(0, 4))),
|
|
651
652
|
version: e.getUint32(4, !0),
|
|
652
653
|
length: e.getUint32(8, !0)
|
|
653
|
-
}, this.header.magic !==
|
|
654
|
+
}, this.header.magic !== Ge)
|
|
654
655
|
throw new Error("THREE.GLTFLoader: Unsupported glTF-Binary header.");
|
|
655
656
|
if (this.header.version < 2)
|
|
656
657
|
throw new Error("THREE.GLTFLoader: Legacy binary file detected.");
|
|
657
|
-
const t = this.header.length -
|
|
658
|
+
const t = this.header.length - q, s = new DataView(n, q);
|
|
658
659
|
let r = 0;
|
|
659
660
|
for (; r < t; ) {
|
|
660
661
|
const a = s.getUint32(r, !0);
|
|
661
662
|
r += 4;
|
|
662
663
|
const o = s.getUint32(r, !0);
|
|
663
|
-
if (r += 4, o ===
|
|
664
|
-
const c = new Uint8Array(n,
|
|
664
|
+
if (r += 4, o === we.JSON) {
|
|
665
|
+
const c = new Uint8Array(n, q + r, a);
|
|
665
666
|
this.content = i.decode(c);
|
|
666
|
-
} else if (o ===
|
|
667
|
-
const c =
|
|
667
|
+
} else if (o === we.BIN) {
|
|
668
|
+
const c = q + r;
|
|
668
669
|
this.body = n.slice(c, c + a);
|
|
669
670
|
}
|
|
670
671
|
r += a;
|
|
@@ -673,7 +674,7 @@ class at {
|
|
|
673
674
|
throw new Error("THREE.GLTFLoader: JSON content not found.");
|
|
674
675
|
}
|
|
675
676
|
}
|
|
676
|
-
class
|
|
677
|
+
class ut {
|
|
677
678
|
constructor(n, e) {
|
|
678
679
|
if (!e)
|
|
679
680
|
throw new Error("THREE.GLTFLoader: No DRACOLoader instance provided.");
|
|
@@ -682,13 +683,13 @@ class ct {
|
|
|
682
683
|
decodePrimitive(n, e) {
|
|
683
684
|
const i = this.json, t = this.dracoLoader, s = n.extensions[this.name].bufferView, r = n.extensions[this.name].attributes, a = {}, o = {}, c = {};
|
|
684
685
|
for (const u in r) {
|
|
685
|
-
const l =
|
|
686
|
+
const l = de[u] || u.toLowerCase();
|
|
686
687
|
a[l] = r[u];
|
|
687
688
|
}
|
|
688
689
|
for (const u in n.attributes) {
|
|
689
|
-
const l =
|
|
690
|
+
const l = de[u] || u.toLowerCase();
|
|
690
691
|
if (r[u] !== void 0) {
|
|
691
|
-
const d = i.accessors[n.attributes[u]], h =
|
|
692
|
+
const d = i.accessors[n.attributes[u]], h = z[d.componentType];
|
|
692
693
|
c[l] = h.name, o[l] = d.normalized === !0;
|
|
693
694
|
}
|
|
694
695
|
}
|
|
@@ -705,7 +706,7 @@ class ct {
|
|
|
705
706
|
});
|
|
706
707
|
}
|
|
707
708
|
}
|
|
708
|
-
class
|
|
709
|
+
class ft {
|
|
709
710
|
constructor() {
|
|
710
711
|
this.name = R.KHR_TEXTURE_TRANSFORM;
|
|
711
712
|
}
|
|
@@ -713,12 +714,12 @@ class lt {
|
|
|
713
714
|
return (e.texCoord === void 0 || e.texCoord === n.channel) && e.offset === void 0 && e.rotation === void 0 && e.scale === void 0 || (n = n.clone(), e.texCoord !== void 0 && (n.channel = e.texCoord), e.offset !== void 0 && n.offset.fromArray(e.offset), e.rotation !== void 0 && (n.rotation = e.rotation), e.scale !== void 0 && n.repeat.fromArray(e.scale), n.needsUpdate = !0), n;
|
|
714
715
|
}
|
|
715
716
|
}
|
|
716
|
-
class
|
|
717
|
+
class dt {
|
|
717
718
|
constructor() {
|
|
718
719
|
this.name = R.KHR_MESH_QUANTIZATION;
|
|
719
720
|
}
|
|
720
721
|
}
|
|
721
|
-
class
|
|
722
|
+
class je extends Fn {
|
|
722
723
|
constructor(n, e, i, t) {
|
|
723
724
|
super(n, e, i, t);
|
|
724
725
|
}
|
|
@@ -731,17 +732,17 @@ class Ge extends kn {
|
|
|
731
732
|
interpolate_(n, e, i, t) {
|
|
732
733
|
const s = this.resultBuffer, r = this.sampleValues, a = this.valueSize, o = a * 2, c = a * 3, u = t - e, l = (i - e) / u, d = l * l, h = d * l, p = n * c, x = p - c, m = -2 * h + 3 * d, g = h - d, E = 1 - m, M = g - d + l;
|
|
733
734
|
for (let T = 0; T !== a; T++) {
|
|
734
|
-
const
|
|
735
|
-
s[T] = E *
|
|
735
|
+
const b = r[x + T + a], I = r[x + T + o] * u, N = r[p + T + a], v = r[p + T] * u;
|
|
736
|
+
s[T] = E * b + M * I + m * N + g * v;
|
|
736
737
|
}
|
|
737
738
|
return s;
|
|
738
739
|
}
|
|
739
740
|
}
|
|
740
|
-
const
|
|
741
|
-
class
|
|
741
|
+
const ht = new Oe();
|
|
742
|
+
class pt extends je {
|
|
742
743
|
interpolate_(n, e, i, t) {
|
|
743
744
|
const s = super.interpolate_(n, e, i, t);
|
|
744
|
-
return
|
|
745
|
+
return ht.fromArray(s).normalize().toArray(s), s;
|
|
745
746
|
}
|
|
746
747
|
}
|
|
747
748
|
const C = {
|
|
@@ -752,25 +753,25 @@ const C = {
|
|
|
752
753
|
TRIANGLES: 4,
|
|
753
754
|
TRIANGLE_STRIP: 5,
|
|
754
755
|
TRIANGLE_FAN: 6
|
|
755
|
-
},
|
|
756
|
+
}, z = {
|
|
756
757
|
5120: Int8Array,
|
|
757
758
|
5121: Uint8Array,
|
|
758
759
|
5122: Int16Array,
|
|
759
760
|
5123: Uint16Array,
|
|
760
761
|
5125: Uint32Array,
|
|
761
762
|
5126: Float32Array
|
|
762
|
-
}, we = {
|
|
763
|
-
9728: ke,
|
|
764
|
-
9729: le,
|
|
765
|
-
9984: dn,
|
|
766
|
-
9985: fn,
|
|
767
|
-
9986: un,
|
|
768
|
-
9987: ve
|
|
769
763
|
}, ye = {
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
764
|
+
9728: Pe,
|
|
765
|
+
9729: ue,
|
|
766
|
+
9984: pn,
|
|
767
|
+
9985: hn,
|
|
768
|
+
9986: dn,
|
|
769
|
+
9987: ke
|
|
770
|
+
}, be = {
|
|
771
|
+
33071: gn,
|
|
772
|
+
33648: mn,
|
|
773
|
+
10497: fe
|
|
774
|
+
}, oe = {
|
|
774
775
|
SCALAR: 1,
|
|
775
776
|
VEC2: 2,
|
|
776
777
|
VEC3: 3,
|
|
@@ -778,7 +779,7 @@ const C = {
|
|
|
778
779
|
MAT2: 4,
|
|
779
780
|
MAT3: 9,
|
|
780
781
|
MAT4: 16
|
|
781
|
-
},
|
|
782
|
+
}, de = {
|
|
782
783
|
POSITION: "position",
|
|
783
784
|
NORMAL: "normal",
|
|
784
785
|
TANGENT: "tangent",
|
|
@@ -789,41 +790,41 @@ const C = {
|
|
|
789
790
|
COLOR_0: "color",
|
|
790
791
|
WEIGHTS_0: "skinWeight",
|
|
791
792
|
JOINTS_0: "skinIndex"
|
|
792
|
-
},
|
|
793
|
+
}, H = {
|
|
793
794
|
scale: "scale",
|
|
794
795
|
translation: "position",
|
|
795
796
|
rotation: "quaternion",
|
|
796
797
|
weights: "morphTargetInfluences"
|
|
797
|
-
},
|
|
798
|
+
}, mt = {
|
|
798
799
|
CUBICSPLINE: void 0,
|
|
799
800
|
// We use a custom interpolant (GLTFCubicSplineInterpolation) for CUBICSPLINE tracks. Each
|
|
800
801
|
// keyframe track will be initialized with a default interpolation type, then modified.
|
|
801
|
-
LINEAR:
|
|
802
|
-
STEP:
|
|
803
|
-
},
|
|
802
|
+
LINEAR: He,
|
|
803
|
+
STEP: vn
|
|
804
|
+
}, ae = {
|
|
804
805
|
OPAQUE: "OPAQUE",
|
|
805
806
|
MASK: "MASK",
|
|
806
807
|
BLEND: "BLEND"
|
|
807
808
|
};
|
|
808
|
-
function
|
|
809
|
-
return f.DefaultMaterial === void 0 && (f.DefaultMaterial = new
|
|
809
|
+
function gt(f) {
|
|
810
|
+
return f.DefaultMaterial === void 0 && (f.DefaultMaterial = new Fe({
|
|
810
811
|
color: 16777215,
|
|
811
812
|
emissive: 0,
|
|
812
813
|
metalness: 1,
|
|
813
814
|
roughness: 1,
|
|
814
815
|
transparent: !1,
|
|
815
816
|
depthTest: !0,
|
|
816
|
-
side:
|
|
817
|
+
side: Pn
|
|
817
818
|
})), f.DefaultMaterial;
|
|
818
819
|
}
|
|
819
|
-
function
|
|
820
|
+
function G(f, n, e) {
|
|
820
821
|
for (const i in e.extensions)
|
|
821
822
|
f[i] === void 0 && (n.userData.gltfExtensions = n.userData.gltfExtensions || {}, n.userData.gltfExtensions[i] = e.extensions[i]);
|
|
822
823
|
}
|
|
823
824
|
function k(f, n) {
|
|
824
825
|
n.extras !== void 0 && (typeof n.extras == "object" ? Object.assign(f.userData, n.extras) : console.warn("THREE.GLTFLoader: Ignoring primitive type .extras, " + n.extras));
|
|
825
826
|
}
|
|
826
|
-
function
|
|
827
|
+
function Tt(f, n, e) {
|
|
827
828
|
let i = !1, t = !1, s = !1;
|
|
828
829
|
for (let c = 0, u = n.length; c < u; c++) {
|
|
829
830
|
const l = n[c];
|
|
@@ -855,7 +856,7 @@ function mt(f, n, e) {
|
|
|
855
856
|
return i && (f.morphAttributes.position = u), t && (f.morphAttributes.normal = l), s && (f.morphAttributes.color = d), f.morphTargetsRelative = !0, f;
|
|
856
857
|
});
|
|
857
858
|
}
|
|
858
|
-
function
|
|
859
|
+
function xt(f, n) {
|
|
859
860
|
if (f.updateMorphTargets(), n.weights !== void 0)
|
|
860
861
|
for (let e = 0, i = n.weights.length; e < i; e++)
|
|
861
862
|
f.morphTargetInfluences[e] = n.weights[e];
|
|
@@ -869,22 +870,22 @@ function gt(f, n) {
|
|
|
869
870
|
console.warn("THREE.GLTFLoader: Invalid extras.targetNames length. Ignoring names.");
|
|
870
871
|
}
|
|
871
872
|
}
|
|
872
|
-
function
|
|
873
|
+
function Rt(f) {
|
|
873
874
|
let n;
|
|
874
875
|
const e = f.extensions && f.extensions[R.KHR_DRACO_MESH_COMPRESSION];
|
|
875
|
-
if (e ? n = "draco:" + e.bufferView + ":" + e.indices + ":" +
|
|
876
|
+
if (e ? n = "draco:" + e.bufferView + ":" + e.indices + ":" + ce(e.attributes) : n = f.indices + ":" + ce(f.attributes) + ":" + f.mode, f.targets !== void 0)
|
|
876
877
|
for (let i = 0, t = f.targets.length; i < t; i++)
|
|
877
|
-
n += ":" +
|
|
878
|
+
n += ":" + ce(f.targets[i]);
|
|
878
879
|
return n;
|
|
879
880
|
}
|
|
880
|
-
function
|
|
881
|
+
function ce(f) {
|
|
881
882
|
let n = "";
|
|
882
883
|
const e = Object.keys(f).sort();
|
|
883
884
|
for (let i = 0, t = e.length; i < t; i++)
|
|
884
885
|
n += e[i] + ":" + f[e[i]] + ";";
|
|
885
886
|
return n;
|
|
886
887
|
}
|
|
887
|
-
function
|
|
888
|
+
function he(f) {
|
|
888
889
|
switch (f) {
|
|
889
890
|
case Int8Array:
|
|
890
891
|
return 1 / 127;
|
|
@@ -898,13 +899,13 @@ function de(f) {
|
|
|
898
899
|
throw new Error("THREE.GLTFLoader: Unsupported normalized accessor component type.");
|
|
899
900
|
}
|
|
900
901
|
}
|
|
901
|
-
function
|
|
902
|
+
function Et(f) {
|
|
902
903
|
return f.search(/\.jpe?g($|\?)/i) > 0 || f.search(/^data\:image\/jpeg/) === 0 ? "image/jpeg" : f.search(/\.webp($|\?)/i) > 0 || f.search(/^data\:image\/webp/) === 0 ? "image/webp" : f.search(/\.ktx2($|\?)/i) > 0 || f.search(/^data\:image\/ktx2/) === 0 ? "image/ktx2" : "image/png";
|
|
903
904
|
}
|
|
904
|
-
const
|
|
905
|
-
class
|
|
905
|
+
const At = new Z();
|
|
906
|
+
class _t {
|
|
906
907
|
constructor(n = {}, e = {}) {
|
|
907
|
-
this.json = n, this.extensions = {}, this.plugins = {}, this.options = e, this.cache = new
|
|
908
|
+
this.json = n, this.extensions = {}, this.plugins = {}, this.options = e, this.cache = new Vn(), this.associations = /* @__PURE__ */ new Map(), this.primitiveCache = {}, this.nodeCache = {}, this.meshCache = { refs: {}, uses: {} }, this.cameraCache = { refs: {}, uses: {} }, this.lightCache = { refs: {}, uses: {} }, this.sourceCache = {}, this.textureCache = {}, this.nodeNamesUsed = {};
|
|
908
909
|
let i = !1, t = -1, s = !1, r = -1;
|
|
909
910
|
if (typeof navigator < "u") {
|
|
910
911
|
const a = navigator.userAgent;
|
|
@@ -912,7 +913,7 @@ class Et {
|
|
|
912
913
|
const o = a.match(/Version\/(\d+)/);
|
|
913
914
|
t = i && o ? parseInt(o[1], 10) : -1, s = a.indexOf("Firefox") > -1, r = s ? a.match(/Firefox\/([0-9]+)\./)[1] : -1;
|
|
914
915
|
}
|
|
915
|
-
typeof createImageBitmap > "u" || i && t < 17 || s && r < 98 ? this.textureLoader = new
|
|
916
|
+
typeof createImageBitmap > "u" || i && t < 17 || s && r < 98 ? this.textureLoader = new ln(this.options.manager) : this.textureLoader = new un(this.options.manager), this.textureLoader.setCrossOrigin(this.options.crossOrigin), this.textureLoader.setRequestHeader(this.options.requestHeader), this.fileLoader = new Ie(this.options.manager), this.fileLoader.setResponseType("arraybuffer"), this.options.crossOrigin === "use-credentials" && this.fileLoader.setWithCredentials(!0);
|
|
916
917
|
}
|
|
917
918
|
setExtensions(n) {
|
|
918
919
|
this.extensions = n;
|
|
@@ -942,7 +943,7 @@ class Et {
|
|
|
942
943
|
parser: i,
|
|
943
944
|
userData: {}
|
|
944
945
|
};
|
|
945
|
-
return
|
|
946
|
+
return G(s, a, t), k(a, t), Promise.all(i._invokeAll(function(o) {
|
|
946
947
|
return o.afterRoot && o.afterRoot(a);
|
|
947
948
|
})).then(function() {
|
|
948
949
|
for (const o of a.scenes)
|
|
@@ -1123,7 +1124,7 @@ class Et {
|
|
|
1123
1124
|
return Promise.resolve(this.extensions[R.KHR_BINARY_GLTF].body);
|
|
1124
1125
|
const t = this.options;
|
|
1125
1126
|
return new Promise(function(s, r) {
|
|
1126
|
-
i.load(
|
|
1127
|
+
i.load(Y.resolveURL(e.uri, t.path), s, void 0, function() {
|
|
1127
1128
|
r(new Error('THREE.GLTFLoader: Failed to load buffer "' + e.uri + '".'));
|
|
1128
1129
|
});
|
|
1129
1130
|
});
|
|
@@ -1152,25 +1153,25 @@ class Et {
|
|
|
1152
1153
|
loadAccessor(n) {
|
|
1153
1154
|
const e = this, i = this.json, t = this.json.accessors[n];
|
|
1154
1155
|
if (t.bufferView === void 0 && t.sparse === void 0) {
|
|
1155
|
-
const r =
|
|
1156
|
-
return Promise.resolve(new
|
|
1156
|
+
const r = oe[t.type], a = z[t.componentType], o = t.normalized === !0, c = new a(t.count * r);
|
|
1157
|
+
return Promise.resolve(new se(c, r, o));
|
|
1157
1158
|
}
|
|
1158
1159
|
const s = [];
|
|
1159
1160
|
return t.bufferView !== void 0 ? s.push(this.getDependency("bufferView", t.bufferView)) : s.push(null), t.sparse !== void 0 && (s.push(this.getDependency("bufferView", t.sparse.indices.bufferView)), s.push(this.getDependency("bufferView", t.sparse.values.bufferView))), Promise.all(s).then(function(r) {
|
|
1160
|
-
const a = r[0], o =
|
|
1161
|
+
const a = r[0], o = oe[t.type], c = z[t.componentType], u = c.BYTES_PER_ELEMENT, l = u * o, d = t.byteOffset || 0, h = t.bufferView !== void 0 ? i.bufferViews[t.bufferView].byteStride : void 0, p = t.normalized === !0;
|
|
1161
1162
|
let x, m;
|
|
1162
1163
|
if (h && h !== l) {
|
|
1163
1164
|
const g = Math.floor(d / h), E = "InterleavedBuffer:" + t.bufferView + ":" + t.componentType + ":" + g + ":" + t.count;
|
|
1164
1165
|
let M = e.cache.get(E);
|
|
1165
|
-
M || (x = new c(a, g * h, t.count * h / u), M = new
|
|
1166
|
+
M || (x = new c(a, g * h, t.count * h / u), M = new fn(x, h / u), e.cache.add(E, M)), m = new kn(M, o, d % h / u, p);
|
|
1166
1167
|
} else
|
|
1167
|
-
a === null ? x = new c(t.count * o) : x = new c(a, d, t.count * o), m = new
|
|
1168
|
+
a === null ? x = new c(t.count * o) : x = new c(a, d, t.count * o), m = new se(x, o, p);
|
|
1168
1169
|
if (t.sparse !== void 0) {
|
|
1169
|
-
const g =
|
|
1170
|
-
a !== null && (m = new
|
|
1171
|
-
for (let
|
|
1172
|
-
const
|
|
1173
|
-
if (m.setX(
|
|
1170
|
+
const g = oe.SCALAR, E = z[t.sparse.indices.componentType], M = t.sparse.indices.byteOffset || 0, T = t.sparse.values.byteOffset || 0, b = new E(r[1], M, t.sparse.count * g), I = new c(r[2], T, t.sparse.count * o);
|
|
1171
|
+
a !== null && (m = new se(m.array.slice(), m.itemSize, m.normalized)), m.normalized = !1;
|
|
1172
|
+
for (let N = 0, v = b.length; N < v; N++) {
|
|
1173
|
+
const _ = b[N];
|
|
1174
|
+
if (m.setX(_, I[N * o]), o >= 2 && m.setY(_, I[N * o + 1]), o >= 3 && m.setZ(_, I[N * o + 2]), o >= 4 && m.setW(_, I[N * o + 3]), o >= 5) throw new Error("THREE.GLTFLoader: Unsupported itemSize in sparse BufferAttribute.");
|
|
1174
1175
|
}
|
|
1175
1176
|
m.normalized = p;
|
|
1176
1177
|
}
|
|
@@ -1200,7 +1201,7 @@ class Et {
|
|
|
1200
1201
|
const c = this.loadImageSource(e, i).then(function(u) {
|
|
1201
1202
|
u.flipY = !1, u.name = r.name || a.name || "", u.name === "" && typeof a.uri == "string" && a.uri.startsWith("data:image/") === !1 && (u.name = a.uri);
|
|
1202
1203
|
const d = (s.samplers || {})[r.sampler] || {};
|
|
1203
|
-
return u.magFilter =
|
|
1204
|
+
return u.magFilter = ye[d.magFilter] || ue, u.minFilter = ye[d.minFilter] || ke, u.wrapS = be[d.wrapS] || fe, u.wrapT = be[d.wrapT] || fe, u.generateMipmaps = !u.isCompressedTexture && u.minFilter !== Pe && u.minFilter !== ue, t.associations.set(u, { textures: n }), u;
|
|
1204
1205
|
}).catch(function() {
|
|
1205
1206
|
return null;
|
|
1206
1207
|
});
|
|
@@ -1224,12 +1225,12 @@ class Et {
|
|
|
1224
1225
|
return new Promise(function(d, h) {
|
|
1225
1226
|
let p = d;
|
|
1226
1227
|
e.isImageBitmapLoader === !0 && (p = function(x) {
|
|
1227
|
-
const m = new
|
|
1228
|
+
const m = new xe(x);
|
|
1228
1229
|
m.needsUpdate = !0, d(m);
|
|
1229
|
-
}), e.load(
|
|
1230
|
+
}), e.load(Y.resolveURL(l, s.path), p, void 0, h);
|
|
1230
1231
|
});
|
|
1231
1232
|
}).then(function(l) {
|
|
1232
|
-
return c === !0 && a.revokeObjectURL(o), k(l, r), l.userData.mimeType = r.mimeType ||
|
|
1233
|
+
return c === !0 && a.revokeObjectURL(o), k(l, r), l.userData.mimeType = r.mimeType || Et(r.uri), l;
|
|
1233
1234
|
}).catch(function(l) {
|
|
1234
1235
|
throw console.error("THREE.GLTFLoader: Couldn't load texture", o), l;
|
|
1235
1236
|
});
|
|
@@ -1276,11 +1277,11 @@ class Et {
|
|
|
1276
1277
|
if (n.isPoints) {
|
|
1277
1278
|
const a = "PointsMaterial:" + i.uuid;
|
|
1278
1279
|
let o = this.cache.get(a);
|
|
1279
|
-
o || (o = new
|
|
1280
|
+
o || (o = new Tn(), re.prototype.copy.call(o, i), o.color.copy(i.color), o.map = i.map, o.sizeAttenuation = !1, this.cache.add(a, o)), i = o;
|
|
1280
1281
|
} else if (n.isLine) {
|
|
1281
1282
|
const a = "LineBasicMaterial:" + i.uuid;
|
|
1282
1283
|
let o = this.cache.get(a);
|
|
1283
|
-
o || (o = new
|
|
1284
|
+
o || (o = new xn(), re.prototype.copy.call(o, i), o.color.copy(i.color), o.map = i.map, this.cache.add(a, o)), i = o;
|
|
1284
1285
|
}
|
|
1285
1286
|
if (t || s || r) {
|
|
1286
1287
|
let a = "ClonedMaterial:" + i.uuid + ":";
|
|
@@ -1291,7 +1292,7 @@ class Et {
|
|
|
1291
1292
|
n.material = i;
|
|
1292
1293
|
}
|
|
1293
1294
|
getMaterialType() {
|
|
1294
|
-
return
|
|
1295
|
+
return Fe;
|
|
1295
1296
|
}
|
|
1296
1297
|
/**
|
|
1297
1298
|
* Specification: https://github.com/KhronosGroup/glTF/blob/master/specification/2.0/README.md#materials
|
|
@@ -1309,29 +1310,29 @@ class Et {
|
|
|
1309
1310
|
r = l.getMaterialType(), c.push(l.extendParams(a, s, e));
|
|
1310
1311
|
} else {
|
|
1311
1312
|
const l = s.pbrMetallicRoughness || {};
|
|
1312
|
-
if (a.color = new
|
|
1313
|
+
if (a.color = new j(1, 1, 1), a.opacity = 1, Array.isArray(l.baseColorFactor)) {
|
|
1313
1314
|
const d = l.baseColorFactor;
|
|
1314
1315
|
a.color.setRGB(d[0], d[1], d[2], P), a.opacity = d[3];
|
|
1315
1316
|
}
|
|
1316
|
-
l.baseColorTexture !== void 0 && c.push(e.assignTexture(a, "map", l.baseColorTexture,
|
|
1317
|
+
l.baseColorTexture !== void 0 && c.push(e.assignTexture(a, "map", l.baseColorTexture, $)), a.metalness = l.metallicFactor !== void 0 ? l.metallicFactor : 1, a.roughness = l.roughnessFactor !== void 0 ? l.roughnessFactor : 1, l.metallicRoughnessTexture !== void 0 && (c.push(e.assignTexture(a, "metalnessMap", l.metallicRoughnessTexture)), c.push(e.assignTexture(a, "roughnessMap", l.metallicRoughnessTexture))), r = this._invokeOne(function(d) {
|
|
1317
1318
|
return d.getMaterialType && d.getMaterialType(n);
|
|
1318
1319
|
}), c.push(Promise.all(this._invokeAll(function(d) {
|
|
1319
1320
|
return d.extendMaterialParams && d.extendMaterialParams(n, a);
|
|
1320
1321
|
})));
|
|
1321
1322
|
}
|
|
1322
|
-
s.doubleSided === !0 && (a.side =
|
|
1323
|
-
const u = s.alphaMode ||
|
|
1324
|
-
if (u ===
|
|
1323
|
+
s.doubleSided === !0 && (a.side = Rn);
|
|
1324
|
+
const u = s.alphaMode || ae.OPAQUE;
|
|
1325
|
+
if (u === ae.BLEND ? (a.transparent = !0, a.depthWrite = !1) : (a.transparent = !1, u === ae.MASK && (a.alphaTest = s.alphaCutoff !== void 0 ? s.alphaCutoff : 0.5)), s.normalTexture !== void 0 && r !== W && (c.push(e.assignTexture(a, "normalMap", s.normalTexture)), a.normalScale = new Ce(1, 1), s.normalTexture.scale !== void 0)) {
|
|
1325
1326
|
const l = s.normalTexture.scale;
|
|
1326
1327
|
a.normalScale.set(l, l);
|
|
1327
1328
|
}
|
|
1328
|
-
if (s.occlusionTexture !== void 0 && r !==
|
|
1329
|
+
if (s.occlusionTexture !== void 0 && r !== W && (c.push(e.assignTexture(a, "aoMap", s.occlusionTexture)), s.occlusionTexture.strength !== void 0 && (a.aoMapIntensity = s.occlusionTexture.strength)), s.emissiveFactor !== void 0 && r !== W) {
|
|
1329
1330
|
const l = s.emissiveFactor;
|
|
1330
|
-
a.emissive = new
|
|
1331
|
+
a.emissive = new j().setRGB(l[0], l[1], l[2], P);
|
|
1331
1332
|
}
|
|
1332
|
-
return s.emissiveTexture !== void 0 && r !==
|
|
1333
|
+
return s.emissiveTexture !== void 0 && r !== W && c.push(e.assignTexture(a, "emissiveMap", s.emissiveTexture, $)), Promise.all(c).then(function() {
|
|
1333
1334
|
const l = new r(a);
|
|
1334
|
-
return s.name && (l.name = s.name), k(l, s), e.associations.set(l, { materials: n }), s.extensions &&
|
|
1335
|
+
return s.name && (l.name = s.name), k(l, s), e.associations.set(l, { materials: n }), s.extensions && G(t, l, s), l;
|
|
1335
1336
|
});
|
|
1336
1337
|
}
|
|
1337
1338
|
/**
|
|
@@ -1342,7 +1343,7 @@ class Et {
|
|
|
1342
1343
|
* @return {string}
|
|
1343
1344
|
*/
|
|
1344
1345
|
createUniqueName(n) {
|
|
1345
|
-
const e =
|
|
1346
|
+
const e = En.sanitizeNodeName(n || "");
|
|
1346
1347
|
return e in this.nodeNamesUsed ? e + "_" + ++this.nodeNamesUsed[e] : (this.nodeNamesUsed[e] = 0, e);
|
|
1347
1348
|
}
|
|
1348
1349
|
/**
|
|
@@ -1358,17 +1359,17 @@ class Et {
|
|
|
1358
1359
|
const e = this, i = this.extensions, t = this.primitiveCache;
|
|
1359
1360
|
function s(a) {
|
|
1360
1361
|
return i[R.KHR_DRACO_MESH_COMPRESSION].decodePrimitive(a, e).then(function(o) {
|
|
1361
|
-
return
|
|
1362
|
+
return Se(o, a, e);
|
|
1362
1363
|
});
|
|
1363
1364
|
}
|
|
1364
1365
|
const r = [];
|
|
1365
1366
|
for (let a = 0, o = n.length; a < o; a++) {
|
|
1366
|
-
const c = n[a], u =
|
|
1367
|
+
const c = n[a], u = Rt(c), l = t[u];
|
|
1367
1368
|
if (l)
|
|
1368
1369
|
r.push(l.promise);
|
|
1369
1370
|
else {
|
|
1370
1371
|
let d;
|
|
1371
|
-
c.extensions && c.extensions[R.KHR_DRACO_MESH_COMPRESSION] ? d = s(c) : d =
|
|
1372
|
+
c.extensions && c.extensions[R.KHR_DRACO_MESH_COMPRESSION] ? d = s(c) : d = Se(new An(), c, e), t[u] = { primitive: c, promise: d }, r.push(d);
|
|
1372
1373
|
}
|
|
1373
1374
|
}
|
|
1374
1375
|
return Promise.all(r);
|
|
@@ -1383,7 +1384,7 @@ class Et {
|
|
|
1383
1384
|
loadMesh(n) {
|
|
1384
1385
|
const e = this, i = this.json, t = this.extensions, s = i.meshes[n], r = s.primitives, a = [];
|
|
1385
1386
|
for (let o = 0, c = r.length; o < c; o++) {
|
|
1386
|
-
const u = r[o].material === void 0 ?
|
|
1387
|
+
const u = r[o].material === void 0 ? gt(this.cache) : this.getDependency("material", r[o].material);
|
|
1387
1388
|
a.push(u);
|
|
1388
1389
|
}
|
|
1389
1390
|
return a.push(e.loadGeometries(r)), Promise.all(a).then(function(o) {
|
|
@@ -1393,18 +1394,18 @@ class Et {
|
|
|
1393
1394
|
let g;
|
|
1394
1395
|
const E = c[h];
|
|
1395
1396
|
if (m.mode === C.TRIANGLES || m.mode === C.TRIANGLE_STRIP || m.mode === C.TRIANGLE_FAN || m.mode === void 0)
|
|
1396
|
-
g = s.isSkinnedMesh === !0 ? new
|
|
1397
|
+
g = s.isSkinnedMesh === !0 ? new _n(x, E) : new De(x, E), g.isSkinnedMesh === !0 && g.normalizeSkinWeights(), m.mode === C.TRIANGLE_STRIP ? g.geometry = Me(g.geometry, Ne) : m.mode === C.TRIANGLE_FAN && (g.geometry = Me(g.geometry, le));
|
|
1397
1398
|
else if (m.mode === C.LINES)
|
|
1398
|
-
g = new
|
|
1399
|
+
g = new Ln(x, E);
|
|
1399
1400
|
else if (m.mode === C.LINE_STRIP)
|
|
1400
|
-
g = new
|
|
1401
|
+
g = new Mn(x, E);
|
|
1401
1402
|
else if (m.mode === C.LINE_LOOP)
|
|
1402
|
-
g = new
|
|
1403
|
+
g = new wn(x, E);
|
|
1403
1404
|
else if (m.mode === C.POINTS)
|
|
1404
|
-
g = new
|
|
1405
|
+
g = new yn(x, E);
|
|
1405
1406
|
else
|
|
1406
1407
|
throw new Error("THREE.GLTFLoader: Primitive mode unsupported: " + m.mode);
|
|
1407
|
-
Object.keys(g.geometry.morphAttributes).length > 0 &&
|
|
1408
|
+
Object.keys(g.geometry.morphAttributes).length > 0 && xt(g, s), g.name = e.createUniqueName(s.name || "mesh_" + n), k(g, s), m.extensions && G(t, g, m), e.assignFinalMaterial(g), l.push(g);
|
|
1408
1409
|
}
|
|
1409
1410
|
for (let h = 0, p = l.length; h < p; h++)
|
|
1410
1411
|
e.associations.set(l[h], {
|
|
@@ -1412,9 +1413,9 @@ class Et {
|
|
|
1412
1413
|
primitives: h
|
|
1413
1414
|
});
|
|
1414
1415
|
if (l.length === 1)
|
|
1415
|
-
return s.extensions &&
|
|
1416
|
-
const d = new
|
|
1417
|
-
s.extensions &&
|
|
1416
|
+
return s.extensions && G(t, l[0], s), l[0];
|
|
1417
|
+
const d = new ie();
|
|
1418
|
+
s.extensions && G(t, d, s), e.associations.set(d, { meshes: n });
|
|
1418
1419
|
for (let h = 0, p = l.length; h < p; h++)
|
|
1419
1420
|
d.add(l[h]);
|
|
1420
1421
|
return d;
|
|
@@ -1434,7 +1435,7 @@ class Et {
|
|
|
1434
1435
|
console.warn("THREE.GLTFLoader: Missing camera parameters.");
|
|
1435
1436
|
return;
|
|
1436
1437
|
}
|
|
1437
|
-
return i.type === "perspective" ? e = new
|
|
1438
|
+
return i.type === "perspective" ? e = new bn(Sn.radToDeg(t.yfov), t.aspectRatio || 1, t.znear || 1, t.zfar || 2e6) : i.type === "orthographic" && (e = new Nn(-t.xmag, t.xmag, t.ymag, -t.ymag, t.znear, t.zfar)), i.name && (e.name = this.createUniqueName(i.name)), k(e, i), Promise.resolve(e);
|
|
1438
1439
|
}
|
|
1439
1440
|
/**
|
|
1440
1441
|
* Specification: https://github.com/KhronosGroup/glTF/tree/master/specification/2.0#skins
|
|
@@ -1453,12 +1454,12 @@ class Et {
|
|
|
1453
1454
|
const l = r[c];
|
|
1454
1455
|
if (l) {
|
|
1455
1456
|
a.push(l);
|
|
1456
|
-
const d = new
|
|
1457
|
+
const d = new Z();
|
|
1457
1458
|
s !== null && d.fromArray(s.array, c * 16), o.push(d);
|
|
1458
1459
|
} else
|
|
1459
1460
|
console.warn('THREE.GLTFLoader: Joint "%s" could not be found.', e.joints[c]);
|
|
1460
1461
|
}
|
|
1461
|
-
return new
|
|
1462
|
+
return new In(a, o);
|
|
1462
1463
|
});
|
|
1463
1464
|
}
|
|
1464
1465
|
/**
|
|
@@ -1483,15 +1484,15 @@ class Et {
|
|
|
1483
1484
|
]).then(function(l) {
|
|
1484
1485
|
const d = l[0], h = l[1], p = l[2], x = l[3], m = l[4], g = [];
|
|
1485
1486
|
for (let E = 0, M = d.length; E < M; E++) {
|
|
1486
|
-
const T = d[E],
|
|
1487
|
+
const T = d[E], b = h[E], I = p[E], N = x[E], v = m[E];
|
|
1487
1488
|
if (T === void 0) continue;
|
|
1488
1489
|
T.updateMatrix && T.updateMatrix();
|
|
1489
|
-
const
|
|
1490
|
-
if (
|
|
1491
|
-
for (let F = 0; F <
|
|
1492
|
-
g.push(
|
|
1490
|
+
const _ = i._createAnimationTracks(T, b, I, N, v);
|
|
1491
|
+
if (_)
|
|
1492
|
+
for (let F = 0; F < _.length; F++)
|
|
1493
|
+
g.push(_[F]);
|
|
1493
1494
|
}
|
|
1494
|
-
return new
|
|
1495
|
+
return new Cn(s, void 0, g);
|
|
1495
1496
|
});
|
|
1496
1497
|
}
|
|
1497
1498
|
createNodeMesh(n) {
|
|
@@ -1524,7 +1525,7 @@ class Et {
|
|
|
1524
1525
|
]).then(function(c) {
|
|
1525
1526
|
const u = c[0], l = c[1], d = c[2];
|
|
1526
1527
|
d !== null && u.traverse(function(h) {
|
|
1527
|
-
h.isSkinnedMesh && h.bind(d,
|
|
1528
|
+
h.isSkinnedMesh && h.bind(d, At);
|
|
1528
1529
|
});
|
|
1529
1530
|
for (let h = 0, p = l.length; h < p; h++)
|
|
1530
1531
|
u.add(l[h]);
|
|
@@ -1548,11 +1549,11 @@ class Et {
|
|
|
1548
1549
|
a.push(c);
|
|
1549
1550
|
}), this.nodeCache[n] = Promise.all(a).then(function(c) {
|
|
1550
1551
|
let u;
|
|
1551
|
-
if (s.isBone === !0 ? u = new
|
|
1552
|
+
if (s.isBone === !0 ? u = new On() : c.length > 1 ? u = new ie() : c.length === 1 ? u = c[0] : u = new ve(), u !== c[0])
|
|
1552
1553
|
for (let l = 0, d = c.length; l < d; l++)
|
|
1553
1554
|
u.add(c[l]);
|
|
1554
|
-
if (s.name && (u.userData.name = s.name, u.name = r), k(u, s), s.extensions &&
|
|
1555
|
-
const l = new
|
|
1555
|
+
if (s.name && (u.userData.name = s.name, u.name = r), k(u, s), s.extensions && G(i, u, s), s.matrix !== void 0) {
|
|
1556
|
+
const l = new Z();
|
|
1556
1557
|
l.fromArray(s.matrix), u.applyMatrix4(l);
|
|
1557
1558
|
} else
|
|
1558
1559
|
s.translation !== void 0 && u.position.fromArray(s.translation), s.rotation !== void 0 && u.quaternion.fromArray(s.rotation), s.scale !== void 0 && u.scale.fromArray(s.scale);
|
|
@@ -1573,8 +1574,8 @@ class Et {
|
|
|
1573
1574
|
* @return {Promise<Group>}
|
|
1574
1575
|
*/
|
|
1575
1576
|
loadScene(n) {
|
|
1576
|
-
const e = this.extensions, i = this.json.scenes[n], t = this, s = new
|
|
1577
|
-
i.name && (s.name = t.createUniqueName(i.name)), k(s, i), i.extensions &&
|
|
1577
|
+
const e = this.extensions, i = this.json.scenes[n], t = this, s = new ie();
|
|
1578
|
+
i.name && (s.name = t.createUniqueName(i.name)), k(s, i), i.extensions && G(e, s, i);
|
|
1578
1579
|
const r = i.nodes || [], a = [];
|
|
1579
1580
|
for (let o = 0, c = r.length; o < c; o++)
|
|
1580
1581
|
a.push(t.getDependency("node", r[o]));
|
|
@@ -1584,7 +1585,7 @@ class Et {
|
|
|
1584
1585
|
const c = (u) => {
|
|
1585
1586
|
const l = /* @__PURE__ */ new Map();
|
|
1586
1587
|
for (const [d, h] of t.associations)
|
|
1587
|
-
(d instanceof
|
|
1588
|
+
(d instanceof re || d instanceof xe) && l.set(d, h);
|
|
1588
1589
|
return u.traverse((d) => {
|
|
1589
1590
|
const h = t.associations.get(d);
|
|
1590
1591
|
h != null && l.set(d, h);
|
|
@@ -1595,38 +1596,38 @@ class Et {
|
|
|
1595
1596
|
}
|
|
1596
1597
|
_createAnimationTracks(n, e, i, t, s) {
|
|
1597
1598
|
const r = [], a = n.name ? n.name : n.uuid, o = [];
|
|
1598
|
-
|
|
1599
|
+
H[s.path] === H.weights ? n.traverse(function(d) {
|
|
1599
1600
|
d.morphTargetInfluences && o.push(d.name ? d.name : d.uuid);
|
|
1600
1601
|
}) : o.push(a);
|
|
1601
1602
|
let c;
|
|
1602
|
-
switch (
|
|
1603
|
-
case
|
|
1604
|
-
c = Re;
|
|
1605
|
-
break;
|
|
1606
|
-
case D.rotation:
|
|
1603
|
+
switch (H[s.path]) {
|
|
1604
|
+
case H.weights:
|
|
1607
1605
|
c = Ee;
|
|
1608
1606
|
break;
|
|
1609
|
-
case
|
|
1610
|
-
|
|
1611
|
-
|
|
1607
|
+
case H.rotation:
|
|
1608
|
+
c = Ae;
|
|
1609
|
+
break;
|
|
1610
|
+
case H.translation:
|
|
1611
|
+
case H.scale:
|
|
1612
|
+
c = Re;
|
|
1612
1613
|
break;
|
|
1613
1614
|
default:
|
|
1614
1615
|
switch (i.itemSize) {
|
|
1615
1616
|
case 1:
|
|
1616
|
-
c =
|
|
1617
|
+
c = Ee;
|
|
1617
1618
|
break;
|
|
1618
1619
|
case 2:
|
|
1619
1620
|
case 3:
|
|
1620
1621
|
default:
|
|
1621
|
-
c =
|
|
1622
|
+
c = Re;
|
|
1622
1623
|
break;
|
|
1623
1624
|
}
|
|
1624
1625
|
break;
|
|
1625
1626
|
}
|
|
1626
|
-
const u = t.interpolation !== void 0 ?
|
|
1627
|
+
const u = t.interpolation !== void 0 ? mt[t.interpolation] : He, l = this._getArrayFromAccessor(i);
|
|
1627
1628
|
for (let d = 0, h = o.length; d < h; d++) {
|
|
1628
1629
|
const p = new c(
|
|
1629
|
-
o[d] + "." +
|
|
1630
|
+
o[d] + "." + H[s.path],
|
|
1630
1631
|
e.array,
|
|
1631
1632
|
l,
|
|
1632
1633
|
u
|
|
@@ -1638,7 +1639,7 @@ class Et {
|
|
|
1638
1639
|
_getArrayFromAccessor(n) {
|
|
1639
1640
|
let e = n.array;
|
|
1640
1641
|
if (n.normalized) {
|
|
1641
|
-
const i =
|
|
1642
|
+
const i = he(e.constructor), t = new Float32Array(e.length);
|
|
1642
1643
|
for (let s = 0, r = e.length; s < r; s++)
|
|
1643
1644
|
t[s] = e[s] * i;
|
|
1644
1645
|
e = t;
|
|
@@ -1647,21 +1648,21 @@ class Et {
|
|
|
1647
1648
|
}
|
|
1648
1649
|
_createCubicSplineTrackInterpolant(n) {
|
|
1649
1650
|
n.createInterpolant = function(i) {
|
|
1650
|
-
const t = this instanceof
|
|
1651
|
+
const t = this instanceof Ae ? pt : je;
|
|
1651
1652
|
return new t(this.times, this.values, this.getValueSize() / 3, i);
|
|
1652
1653
|
}, n.createInterpolant.isInterpolantFactoryMethodGLTFCubicSpline = !0;
|
|
1653
1654
|
}
|
|
1654
1655
|
}
|
|
1655
|
-
function
|
|
1656
|
-
const i = n.attributes, t = new
|
|
1656
|
+
function Lt(f, n, e) {
|
|
1657
|
+
const i = n.attributes, t = new Ue();
|
|
1657
1658
|
if (i.POSITION !== void 0) {
|
|
1658
1659
|
const a = e.json.accessors[i.POSITION], o = a.min, c = a.max;
|
|
1659
1660
|
if (o !== void 0 && c !== void 0) {
|
|
1660
1661
|
if (t.set(
|
|
1661
|
-
new
|
|
1662
|
-
new
|
|
1662
|
+
new K(o[0], o[1], o[2]),
|
|
1663
|
+
new K(c[0], c[1], c[2])
|
|
1663
1664
|
), a.normalized) {
|
|
1664
|
-
const u =
|
|
1665
|
+
const u = he(z[a.componentType]);
|
|
1665
1666
|
t.min.multiplyScalar(u), t.max.multiplyScalar(u);
|
|
1666
1667
|
}
|
|
1667
1668
|
} else {
|
|
@@ -1672,14 +1673,14 @@ function At(f, n, e) {
|
|
|
1672
1673
|
return;
|
|
1673
1674
|
const s = n.targets;
|
|
1674
1675
|
if (s !== void 0) {
|
|
1675
|
-
const a = new
|
|
1676
|
+
const a = new K(), o = new K();
|
|
1676
1677
|
for (let c = 0, u = s.length; c < u; c++) {
|
|
1677
1678
|
const l = s[c];
|
|
1678
1679
|
if (l.POSITION !== void 0) {
|
|
1679
1680
|
const d = e.json.accessors[l.POSITION], h = d.min, p = d.max;
|
|
1680
1681
|
if (h !== void 0 && p !== void 0) {
|
|
1681
1682
|
if (o.setX(Math.max(Math.abs(h[0]), Math.abs(p[0]))), o.setY(Math.max(Math.abs(h[1]), Math.abs(p[1]))), o.setZ(Math.max(Math.abs(h[2]), Math.abs(p[2]))), d.normalized) {
|
|
1682
|
-
const x =
|
|
1683
|
+
const x = he(z[d.componentType]);
|
|
1683
1684
|
o.multiplyScalar(x);
|
|
1684
1685
|
}
|
|
1685
1686
|
a.max(o);
|
|
@@ -1690,10 +1691,10 @@ function At(f, n, e) {
|
|
|
1690
1691
|
t.expandByVector(a);
|
|
1691
1692
|
}
|
|
1692
1693
|
f.boundingBox = t;
|
|
1693
|
-
const r = new
|
|
1694
|
+
const r = new Dn();
|
|
1694
1695
|
t.getCenter(r.center), r.radius = t.min.distanceTo(t.max) / 2, f.boundingSphere = r;
|
|
1695
1696
|
}
|
|
1696
|
-
function
|
|
1697
|
+
function Se(f, n, e) {
|
|
1697
1698
|
const i = n.attributes, t = [];
|
|
1698
1699
|
function s(r, a) {
|
|
1699
1700
|
return e.getDependency("accessor", r).then(function(o) {
|
|
@@ -1701,7 +1702,7 @@ function be(f, n, e) {
|
|
|
1701
1702
|
});
|
|
1702
1703
|
}
|
|
1703
1704
|
for (const r in i) {
|
|
1704
|
-
const a =
|
|
1705
|
+
const a = de[r] || r.toLowerCase();
|
|
1705
1706
|
a in f.attributes || t.push(s(i[r], a));
|
|
1706
1707
|
}
|
|
1707
1708
|
if (n.indices !== void 0 && !f.index) {
|
|
@@ -1710,12 +1711,12 @@ function be(f, n, e) {
|
|
|
1710
1711
|
});
|
|
1711
1712
|
t.push(r);
|
|
1712
1713
|
}
|
|
1713
|
-
return
|
|
1714
|
-
return n.targets !== void 0 ?
|
|
1714
|
+
return _e.workingColorSpace !== P && "COLOR_0" in i && console.warn(`THREE.GLTFLoader: Converting vertex colors from "srgb-linear" to "${_e.workingColorSpace}" not supported.`), k(f, n), Lt(f, n, e), Promise.all(t).then(function() {
|
|
1715
|
+
return n.targets !== void 0 ? Tt(f, n.targets, e) : f;
|
|
1715
1716
|
});
|
|
1716
1717
|
}
|
|
1717
|
-
function
|
|
1718
|
-
const f =
|
|
1718
|
+
function Mt() {
|
|
1719
|
+
const f = V(!1), n = V(""), e = Ve([]), i = V(null), t = new Gn(), s = new Un(), r = new jn(), a = new Kn();
|
|
1719
1720
|
return {
|
|
1720
1721
|
isLoading: f,
|
|
1721
1722
|
loadingProgress: n,
|
|
@@ -1741,24 +1742,24 @@ function _t() {
|
|
|
1741
1742
|
l.push(g);
|
|
1742
1743
|
let E = null;
|
|
1743
1744
|
const M = (T) => {
|
|
1744
|
-
const
|
|
1745
|
-
n.value = `正在加载 ${x}... ${Math.round(
|
|
1745
|
+
const b = T.lengthComputable ? T.loaded / T.total * 100 : 0;
|
|
1746
|
+
n.value = `正在加载 ${x}... ${Math.round(b)}%`;
|
|
1746
1747
|
};
|
|
1747
1748
|
switch (n.value = `正在加载 ${x}... 0%`, m) {
|
|
1748
1749
|
case "obj":
|
|
1749
1750
|
const T = x.replace(/\.obj$/i, ".mtl").toLowerCase();
|
|
1750
1751
|
if (u.has(T)) {
|
|
1751
|
-
const v = u.get(T),
|
|
1752
|
-
l.push(
|
|
1753
|
-
const F = await t.loadAsync(
|
|
1752
|
+
const v = u.get(T), _ = URL.createObjectURL(v);
|
|
1753
|
+
l.push(_);
|
|
1754
|
+
const F = await t.loadAsync(_);
|
|
1754
1755
|
F.preload(), s.setMaterials(F);
|
|
1755
1756
|
} else
|
|
1756
1757
|
s.setMaterials(null);
|
|
1757
1758
|
E = await s.loadAsync(g, M);
|
|
1758
1759
|
break;
|
|
1759
1760
|
case "stl":
|
|
1760
|
-
const
|
|
1761
|
-
E = new
|
|
1761
|
+
const b = await r.loadAsync(g, M), I = new Hn({ color: 11184810, specular: 1118481, shininess: 200 });
|
|
1762
|
+
E = new De(b, I);
|
|
1762
1763
|
break;
|
|
1763
1764
|
case "gltf":
|
|
1764
1765
|
case "glb":
|
|
@@ -1768,7 +1769,7 @@ function _t() {
|
|
|
1768
1769
|
console.warn(`不支持的文件类型: .${m}`), n.value = `不支持的文件类型: ${x}`;
|
|
1769
1770
|
continue;
|
|
1770
1771
|
}
|
|
1771
|
-
E && (E.userData.boundingBox = new
|
|
1772
|
+
E && (E.userData.boundingBox = new Ue().setFromObject(E), d.push(E));
|
|
1772
1773
|
}
|
|
1773
1774
|
e.value = d, n.value = "加载完成!";
|
|
1774
1775
|
} catch (p) {
|
|
@@ -1779,19 +1780,19 @@ function _t() {
|
|
|
1779
1780
|
}
|
|
1780
1781
|
};
|
|
1781
1782
|
}
|
|
1782
|
-
const
|
|
1783
|
+
const wt = { class: "obj-viewer-container" }, yt = { class: "buttonGroup-topLeft" }, bt = { class: "buttonGroup-left" }, St = { class: "buttonGroup-right" }, Nt = { class: "left-panel" }, It = { class: "panel-header" }, Ct = {
|
|
1783
1784
|
key: 0,
|
|
1784
1785
|
class: "clipping-content"
|
|
1785
|
-
},
|
|
1786
|
+
}, Ot = { class: "radio-group" }, vt = { class: "radio-label" }, kt = { class: "radio-label" }, Pt = { class: "radio-label" }, Ft = { class: "radio-label" }, Dt = {
|
|
1786
1787
|
key: 0,
|
|
1787
1788
|
class: "loading-overlay"
|
|
1788
|
-
},
|
|
1789
|
+
}, Ht = /* @__PURE__ */ ze({
|
|
1789
1790
|
__name: "threePreview",
|
|
1790
1791
|
props: {
|
|
1791
1792
|
fileBlobs: { default: () => [] }
|
|
1792
1793
|
},
|
|
1793
1794
|
setup(f) {
|
|
1794
|
-
const n = f, e =
|
|
1795
|
+
const n = f, e = V(null), i = V(!1), t = V(""), {
|
|
1795
1796
|
currentModels: s,
|
|
1796
1797
|
resetView: r,
|
|
1797
1798
|
initThreeJS: a,
|
|
@@ -1800,176 +1801,180 @@ const Lt = { class: "obj-viewer-container" }, Mt = { class: "buttonGroup-topLeft
|
|
|
1800
1801
|
cleanup: u,
|
|
1801
1802
|
setModels: l,
|
|
1802
1803
|
axesHelperVisible: d,
|
|
1803
|
-
toggleAxesVisibility: h
|
|
1804
|
-
|
|
1805
|
-
|
|
1806
|
-
|
|
1807
|
-
|
|
1808
|
-
|
|
1809
|
-
|
|
1810
|
-
|
|
1804
|
+
toggleAxesVisibility: h,
|
|
1805
|
+
zoomIn: p,
|
|
1806
|
+
zoomOut: x
|
|
1807
|
+
} = Qe(e), {
|
|
1808
|
+
isLoading: m,
|
|
1809
|
+
loadingProgress: g,
|
|
1810
|
+
loadedModels: E,
|
|
1811
|
+
error: M,
|
|
1812
|
+
loadModelsFromBlobs: T
|
|
1813
|
+
} = Mt(), { isAnimating: b, toggleAnimation: I, stopAnimation: N } = Ze(c, s), { isClipping: v, activeClippingAxis: _, toggleClipping: F, updateClippingPlanes: D } = en(
|
|
1811
1814
|
c,
|
|
1812
1815
|
s
|
|
1813
|
-
),
|
|
1816
|
+
), Be = () => {
|
|
1814
1817
|
h();
|
|
1815
1818
|
};
|
|
1816
|
-
|
|
1817
|
-
y && y.length > 0 &&
|
|
1819
|
+
ee(() => n.fileBlobs, (y) => {
|
|
1820
|
+
y && y.length > 0 && T(y).catch((A) => {
|
|
1818
1821
|
console.error("加载错误:", A);
|
|
1819
1822
|
});
|
|
1820
1823
|
}, {
|
|
1821
1824
|
immediate: !0,
|
|
1822
1825
|
deep: !0
|
|
1823
|
-
}),
|
|
1826
|
+
}), ee(E, (y) => {
|
|
1824
1827
|
y && y.length > 0 && l(y);
|
|
1825
|
-
}),
|
|
1826
|
-
y &&
|
|
1828
|
+
}), ee(M, (y) => {
|
|
1829
|
+
y && Le.error(`模型加载失败: ${y}`);
|
|
1827
1830
|
});
|
|
1828
|
-
const
|
|
1829
|
-
i.value = !0, t.value = y, y === "剖面视图" && !
|
|
1831
|
+
const pe = (y) => {
|
|
1832
|
+
i.value = !0, t.value = y, y === "剖面视图" && !v.value && F();
|
|
1830
1833
|
};
|
|
1831
|
-
return
|
|
1832
|
-
await
|
|
1834
|
+
return Xe(async () => {
|
|
1835
|
+
await qe();
|
|
1833
1836
|
try {
|
|
1834
1837
|
a(), window.addEventListener("resize", o);
|
|
1835
1838
|
} catch (y) {
|
|
1836
|
-
console.error("Three.js 初始化失败:", y),
|
|
1839
|
+
console.error("Three.js 初始化失败:", y), Le.error("渲染引擎初始化失败!");
|
|
1837
1840
|
}
|
|
1838
|
-
}),
|
|
1839
|
-
t.value = "", window.removeEventListener("resize", o),
|
|
1841
|
+
}), We(() => {
|
|
1842
|
+
t.value = "", window.removeEventListener("resize", o), b.value && N(), u();
|
|
1840
1843
|
}), (y, A) => {
|
|
1841
|
-
const
|
|
1842
|
-
return
|
|
1844
|
+
const Ke = Ye("el-scrollbar");
|
|
1845
|
+
return te(), ne("div", wt, [
|
|
1843
1846
|
L("div", {
|
|
1844
1847
|
ref_key: "threejsContainer",
|
|
1845
1848
|
ref: e,
|
|
1846
1849
|
class: "threejs-container"
|
|
1847
1850
|
}, null, 512),
|
|
1848
|
-
L("div",
|
|
1849
|
-
|
|
1851
|
+
L("div", yt, [
|
|
1852
|
+
U(B, {
|
|
1850
1853
|
name: "viewReset",
|
|
1851
1854
|
size: "24",
|
|
1852
|
-
onClick:
|
|
1855
|
+
onClick: w(r),
|
|
1853
1856
|
title: "重置"
|
|
1854
1857
|
}, null, 8, ["onClick"]),
|
|
1855
|
-
|
|
1858
|
+
U(B, {
|
|
1856
1859
|
name: "fangda",
|
|
1857
1860
|
size: "24",
|
|
1858
|
-
title: "放大"
|
|
1859
|
-
|
|
1860
|
-
|
|
1861
|
+
title: "放大",
|
|
1862
|
+
onClick: w(p)
|
|
1863
|
+
}, null, 8, ["onClick"]),
|
|
1864
|
+
U(B, {
|
|
1861
1865
|
name: "suoxiao",
|
|
1862
1866
|
size: "24",
|
|
1863
|
-
title: "缩小"
|
|
1864
|
-
|
|
1865
|
-
|
|
1867
|
+
title: "缩小",
|
|
1868
|
+
onClick: w(x)
|
|
1869
|
+
}, null, 8, ["onClick"]),
|
|
1870
|
+
U(B, {
|
|
1866
1871
|
name: "lookAround",
|
|
1867
1872
|
size: "24",
|
|
1868
|
-
onClick:
|
|
1869
|
-
title: b
|
|
1873
|
+
onClick: w(I),
|
|
1874
|
+
title: w(b) ? "停止动画" : "动画视图"
|
|
1870
1875
|
}, null, 8, ["onClick", "title"]),
|
|
1871
|
-
|
|
1876
|
+
U(B, {
|
|
1872
1877
|
name: "zuobiaoxi",
|
|
1873
1878
|
size: "24",
|
|
1874
|
-
active:
|
|
1875
|
-
onClick:
|
|
1879
|
+
active: w(d),
|
|
1880
|
+
onClick: Be,
|
|
1876
1881
|
title: "显隐坐标轴"
|
|
1877
1882
|
}, null, 8, ["active"])
|
|
1878
1883
|
]),
|
|
1879
|
-
L("div",
|
|
1880
|
-
|
|
1881
|
-
|
|
1884
|
+
L("div", bt, [
|
|
1885
|
+
ge(y.$slots, "button-left", { switchRightPanel: pe }, void 0, !0),
|
|
1886
|
+
U(B, {
|
|
1882
1887
|
name: "clipping",
|
|
1883
1888
|
size: "24",
|
|
1884
|
-
onClick: A[0] || (A[0] = (S) =>
|
|
1889
|
+
onClick: A[0] || (A[0] = (S) => pe("剖面视图")),
|
|
1885
1890
|
active: i.value && t.value === "剖面视图",
|
|
1886
1891
|
title: "剖面视图"
|
|
1887
1892
|
}, null, 8, ["active"])
|
|
1888
1893
|
]),
|
|
1889
|
-
L("div",
|
|
1890
|
-
|
|
1894
|
+
L("div", St, [
|
|
1895
|
+
ge(y.$slots, "button-right", {}, void 0, !0)
|
|
1891
1896
|
]),
|
|
1892
1897
|
A[15] || (A[15] = L("div", { class: "buttonGroup-bottom" }, null, -1)),
|
|
1893
|
-
|
|
1894
|
-
L("div",
|
|
1895
|
-
L("span", null,
|
|
1898
|
+
X(L("div", Nt, [
|
|
1899
|
+
L("div", It, [
|
|
1900
|
+
L("span", null, Te(t.value), 1),
|
|
1896
1901
|
L("span", {
|
|
1897
1902
|
class: "close",
|
|
1898
1903
|
onClick: A[1] || (A[1] = (S) => i.value = !1)
|
|
1899
1904
|
}, " X ")
|
|
1900
1905
|
]),
|
|
1901
|
-
|
|
1902
|
-
default:
|
|
1903
|
-
t.value === "剖面视图" ? (
|
|
1904
|
-
L("div",
|
|
1905
|
-
L("label",
|
|
1906
|
-
|
|
1906
|
+
U(Ke, { "max-height": "650px" }, {
|
|
1907
|
+
default: $e(() => [
|
|
1908
|
+
t.value === "剖面视图" ? (te(), ne("div", Ct, [
|
|
1909
|
+
L("div", Ot, [
|
|
1910
|
+
L("label", vt, [
|
|
1911
|
+
X(L("input", {
|
|
1907
1912
|
type: "radio",
|
|
1908
1913
|
name: "clipping-axis",
|
|
1909
1914
|
value: "none",
|
|
1910
|
-
"onUpdate:modelValue": A[2] || (A[2] = (S) =>
|
|
1915
|
+
"onUpdate:modelValue": A[2] || (A[2] = (S) => J(_) ? _.value = S : null),
|
|
1911
1916
|
onChange: A[3] || (A[3] = //@ts-ignore
|
|
1912
|
-
(...S) =>
|
|
1917
|
+
(...S) => w(D) && w(D)(...S))
|
|
1913
1918
|
}, null, 544), [
|
|
1914
|
-
[
|
|
1919
|
+
[Q, w(_)]
|
|
1915
1920
|
]),
|
|
1916
1921
|
A[10] || (A[10] = L("span", { class: "radio-text" }, "无切割", -1))
|
|
1917
1922
|
]),
|
|
1918
|
-
L("label",
|
|
1919
|
-
|
|
1923
|
+
L("label", kt, [
|
|
1924
|
+
X(L("input", {
|
|
1920
1925
|
type: "radio",
|
|
1921
1926
|
name: "clipping-axis",
|
|
1922
1927
|
value: "x",
|
|
1923
|
-
"onUpdate:modelValue": A[4] || (A[4] = (S) =>
|
|
1928
|
+
"onUpdate:modelValue": A[4] || (A[4] = (S) => J(_) ? _.value = S : null),
|
|
1924
1929
|
onChange: A[5] || (A[5] = //@ts-ignore
|
|
1925
|
-
(...S) =>
|
|
1930
|
+
(...S) => w(D) && w(D)(...S))
|
|
1926
1931
|
}, null, 544), [
|
|
1927
|
-
[
|
|
1932
|
+
[Q, w(_)]
|
|
1928
1933
|
]),
|
|
1929
1934
|
A[11] || (A[11] = L("span", { class: "radio-text" }, "X轴切割", -1))
|
|
1930
1935
|
]),
|
|
1931
|
-
L("label",
|
|
1932
|
-
|
|
1936
|
+
L("label", Pt, [
|
|
1937
|
+
X(L("input", {
|
|
1933
1938
|
type: "radio",
|
|
1934
1939
|
name: "clipping-axis",
|
|
1935
1940
|
value: "y",
|
|
1936
|
-
"onUpdate:modelValue": A[6] || (A[6] = (S) =>
|
|
1941
|
+
"onUpdate:modelValue": A[6] || (A[6] = (S) => J(_) ? _.value = S : null),
|
|
1937
1942
|
onChange: A[7] || (A[7] = //@ts-ignore
|
|
1938
|
-
(...S) =>
|
|
1943
|
+
(...S) => w(D) && w(D)(...S))
|
|
1939
1944
|
}, null, 544), [
|
|
1940
|
-
[
|
|
1945
|
+
[Q, w(_)]
|
|
1941
1946
|
]),
|
|
1942
1947
|
A[12] || (A[12] = L("span", { class: "radio-text" }, "Y轴切割", -1))
|
|
1943
1948
|
]),
|
|
1944
|
-
L("label",
|
|
1945
|
-
|
|
1949
|
+
L("label", Ft, [
|
|
1950
|
+
X(L("input", {
|
|
1946
1951
|
type: "radio",
|
|
1947
1952
|
name: "clipping-axis",
|
|
1948
1953
|
value: "z",
|
|
1949
|
-
"onUpdate:modelValue": A[8] || (A[8] = (S) =>
|
|
1954
|
+
"onUpdate:modelValue": A[8] || (A[8] = (S) => J(_) ? _.value = S : null),
|
|
1950
1955
|
onChange: A[9] || (A[9] = //@ts-ignore
|
|
1951
|
-
(...S) =>
|
|
1956
|
+
(...S) => w(D) && w(D)(...S))
|
|
1952
1957
|
}, null, 544), [
|
|
1953
|
-
[
|
|
1958
|
+
[Q, w(_)]
|
|
1954
1959
|
]),
|
|
1955
1960
|
A[13] || (A[13] = L("span", { class: "radio-text" }, "Z轴切割", -1))
|
|
1956
1961
|
])
|
|
1957
1962
|
])
|
|
1958
|
-
])) :
|
|
1963
|
+
])) : me("", !0)
|
|
1959
1964
|
]),
|
|
1960
1965
|
_: 1
|
|
1961
1966
|
})
|
|
1962
1967
|
], 512), [
|
|
1963
|
-
[
|
|
1968
|
+
[Je, i.value]
|
|
1964
1969
|
]),
|
|
1965
|
-
|
|
1970
|
+
w(m) ? (te(), ne("div", Dt, [
|
|
1966
1971
|
A[14] || (A[14] = L("div", { class: "loading-spinner" }, null, -1)),
|
|
1967
|
-
L("p", null,
|
|
1968
|
-
])) :
|
|
1972
|
+
L("p", null, Te(w(g)), 1)
|
|
1973
|
+
])) : me("", !0)
|
|
1969
1974
|
]);
|
|
1970
1975
|
};
|
|
1971
1976
|
}
|
|
1972
|
-
}),
|
|
1977
|
+
}), qt = /* @__PURE__ */ Bn(Ht, [["__scopeId", "data-v-98467d5e"]]);
|
|
1973
1978
|
export {
|
|
1974
|
-
|
|
1979
|
+
qt as default
|
|
1975
1980
|
};
|