@shopware-ag/dive 1.19.1-beta.8 → 2.0.1-beta.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.
- package/build/chunks/FileTypes-BjZ0rrIV.cjs +1 -0
- package/build/chunks/FileTypes-qgYnI0Jg.mjs +30 -0
- package/build/chunks/ModuleRegistry-NyNtjHb2.cjs +1 -0
- package/build/chunks/ModuleRegistry-RSub8W0G.mjs +13 -0
- package/build/chunks/PerspectiveCamera-BByyG5R4.cjs +1 -0
- package/build/chunks/PerspectiveCamera-sm4_81KJ.mjs +34 -0
- package/build/chunks/SelectTool-BRKko7uz.cjs +1 -0
- package/build/chunks/SelectTool-mTRiZYaC.mjs +712 -0
- package/build/chunks/SystemInfo-DPAQG-S5.mjs +139 -0
- package/build/chunks/SystemInfo-oX-NNneO.cjs +1 -0
- package/build/chunks/VisibilityLayerMask-BI7jPKdx.cjs +1 -0
- package/build/chunks/VisibilityLayerMask-CXgt1fJc.mjs +8 -0
- package/build/chunks/findInterface-BEdL2iUQ.cjs +1 -0
- package/build/chunks/findInterface-OrXgmwxj.mjs +18 -0
- package/build/chunks/index-C_uFFwT2.mjs +5 -0
- package/build/chunks/index-DAwIH9xh.cjs +1 -0
- package/build/chunks/package-BFpY3sIj.cjs +1 -0
- package/build/chunks/package-BvoZkrge.mjs +39 -0
- package/build/chunks/parse-error-2f5qpXP5.cjs +6 -0
- package/build/chunks/parse-error-DRBVHL9E.mjs +614 -0
- package/build/dive.cjs +30 -0
- package/build/dive.d.ts +2 -0
- package/build/dive.mjs +1757 -0
- package/build/src/{primitive → components}/floor/Floor.d.ts +1 -1
- package/build/src/{gizmo → components/gizmo}/Gizmo.d.ts +4 -4
- package/build/src/{gizmo → components/gizmo}/handles/AxisHandle.d.ts +4 -4
- package/build/src/{gizmo → components/gizmo}/handles/RadialHandle.d.ts +4 -4
- package/build/src/{gizmo → components/gizmo}/handles/ScaleHandle.d.ts +4 -4
- package/build/src/{gizmo → components/gizmo}/plane/GizmoPlane.d.ts +1 -1
- package/build/src/{gizmo → components/gizmo}/rotate/RotateGizmo.d.ts +4 -4
- package/build/src/{gizmo → components/gizmo}/scale/ScaleGizmo.d.ts +5 -5
- package/build/src/{gizmo → components/gizmo}/translate/TranslateGizmo.d.ts +4 -4
- package/build/src/{group → components/group}/Group.d.ts +8 -3
- package/build/src/components/index.d.ts +9 -0
- package/build/src/{light → components/light}/AmbientLight.d.ts +1 -1
- package/build/src/{light → components/light}/PointLight.d.ts +4 -4
- package/build/src/{light → components/light}/SceneLight.d.ts +1 -1
- package/build/src/components/light/index.d.ts +3 -0
- package/build/src/{model → components/model}/Model.d.ts +2 -2
- package/build/src/{node → components/node}/Node.d.ts +4 -4
- package/build/src/{primitive → components/primitive}/Primitive.d.ts +2 -2
- package/build/src/{engine/scene → components}/root/Root.d.ts +6 -2
- package/build/src/constants/index.d.ts +3 -0
- package/build/src/core/Dive.d.ts +57 -0
- package/build/src/core/index.d.ts +1 -0
- package/build/src/engine/Engine.d.ts +19 -19
- package/build/src/engine/camera/PerspectiveCamera.d.ts +6 -3
- package/build/src/engine/clock/Clock.d.ts +19 -0
- package/build/src/engine/renderer/Renderer.d.ts +29 -57
- package/build/src/engine/resize/ResizeManager.d.ts +11 -0
- package/build/src/engine/scene/Scene.d.ts +6 -15
- package/build/src/engine/scene/xrroot/XRRoot.d.ts +5 -5
- package/build/src/engine/scene/xrroot/xrlightroot/XRLightRoot.d.ts +3 -3
- package/build/src/{helper → helpers}/findSceneRecursive/findSceneRecursive.d.ts +1 -1
- package/build/src/helpers/index.d.ts +8 -0
- package/build/src/{helper → helpers}/isFileTypeSupported/isFileTypeSupported.d.ts +1 -1
- package/build/src/index.d.ts +8 -2
- package/build/src/{interface → interfaces}/Draggable.d.ts +1 -1
- package/build/src/interfaces/index.d.ts +6 -0
- package/build/src/modules/ModuleRegistry.d.ts +19 -0
- package/build/src/modules/animation/AnimationSystem.cjs +1 -0
- package/build/src/modules/animation/AnimationSystem.d.ts +36 -0
- package/build/src/modules/animation/AnimationSystem.mjs +95 -0
- package/build/src/modules/animation/animator/Animator.d.ts +26 -0
- package/build/src/modules/animation/types/AnimatorParameters.d.ts +7 -0
- package/build/src/modules/ar/ARSystem.cjs +1 -2
- package/build/src/modules/ar/ARSystem.d.ts +1 -2
- package/build/src/modules/ar/ARSystem.mjs +2 -3
- package/build/src/modules/ar/arquicklook/ARQuickLook.d.ts +1 -1
- package/build/src/modules/ar/sceneviewer/SceneViewer.d.ts +1 -1
- package/build/src/modules/ar/webxr/WebXR.d.ts +3 -4
- package/build/src/modules/ar/webxr/controller/WebXRController.d.ts +3 -3
- package/build/src/modules/ar/webxr/origin/WebXROrigin.d.ts +2 -2
- package/build/src/modules/ar/webxr/raycaster/WebXRRaycaster.d.ts +4 -4
- package/build/src/modules/ar/webxr/raycaster/ar/WebXRRaycasterAR.d.ts +3 -3
- package/build/src/modules/ar/webxr/raycaster/three/WebXRRaycasterTHREE.d.ts +4 -4
- package/build/src/modules/ar/webxr/touchscreencontrols/WebXRTouchscreenControls.d.ts +1 -1
- package/build/src/modules/asset/converter/AssetConverter.cjs +0 -1
- package/build/src/modules/asset/converter/AssetConverter.d.ts +4 -5
- package/build/src/modules/asset/converter/AssetConverter.mjs +0 -1
- package/build/src/modules/asset/exporter/AssetExporter.cjs +24 -25
- package/build/src/modules/asset/exporter/AssetExporter.d.ts +15 -3
- package/build/src/modules/asset/exporter/AssetExporter.mjs +3 -5
- package/build/src/modules/asset/loader/AssetLoader.cjs +2 -3
- package/build/src/modules/asset/loader/AssetLoader.d.ts +1 -3
- package/build/src/modules/asset/loader/AssetLoader.mjs +96 -101
- package/build/src/modules/axiscamera/AxisCamera.d.ts +21 -0
- package/build/src/modules/controller/orbit/OrbitController.d.ts +30 -0
- package/build/src/modules/mediacreator/MediaCreator.cjs +1 -2
- package/build/src/modules/mediacreator/MediaCreator.d.ts +5 -6
- package/build/src/modules/mediacreator/MediaCreator.mjs +13 -11
- package/build/src/modules/state/ActionRegistry.d.ts +26 -0
- package/build/src/modules/state/State.cjs +27 -0
- package/build/src/modules/state/State.d.ts +58 -0
- package/build/src/modules/state/State.mjs +4271 -0
- package/build/src/modules/state/actions/action.d.ts +36 -0
- package/build/src/modules/state/actions/ar/index.d.ts +1 -0
- package/build/src/modules/state/actions/ar/launchar.d.ts +15 -0
- package/build/src/modules/state/actions/camera/computeencompassingview.d.ts +12 -0
- package/build/src/modules/state/actions/camera/getcameratransform.d.ts +12 -0
- package/build/src/modules/state/actions/camera/index.d.ts +6 -0
- package/build/src/modules/state/actions/camera/lockcamera.d.ts +8 -0
- package/build/src/modules/state/actions/camera/movecamera.d.ts +29 -0
- package/build/src/modules/state/actions/camera/setcameralayer.d.ts +12 -0
- package/build/src/modules/state/actions/camera/setcameratransform.d.ts +15 -0
- package/build/src/modules/state/actions/camera/zoomcamera.d.ts +14 -0
- package/build/src/modules/state/actions/index.d.ts +7 -0
- package/build/src/modules/state/actions/media/generatemedia.d.ts +25 -0
- package/build/src/modules/state/actions/media/index.d.ts +1 -0
- package/build/src/modules/state/actions/object/addobject.d.ts +8 -0
- package/build/src/modules/state/actions/object/deleteobject.d.ts +12 -0
- package/build/src/modules/state/actions/object/deselectobject.d.ts +12 -0
- package/build/src/modules/state/actions/object/dropit.d.ts +12 -0
- package/build/src/modules/state/actions/object/getallobjects.d.ts +8 -0
- package/build/src/modules/state/actions/object/getobjects.d.ts +12 -0
- package/build/src/modules/state/actions/object/index.d.ts +11 -0
- package/build/src/modules/state/actions/object/modelloaded.d.ts +12 -0
- package/build/src/modules/state/actions/object/placeonfloor.d.ts +12 -0
- package/build/src/modules/state/actions/object/selectobject.d.ts +12 -0
- package/build/src/modules/state/actions/object/setparent.d.ts +22 -0
- package/build/src/modules/state/actions/object/updateobject.d.ts +12 -0
- package/build/src/modules/state/actions/renderer/index.d.ts +1 -0
- package/build/src/modules/state/actions/renderer/startrender.d.ts +8 -0
- package/build/src/modules/state/actions/scene/exportscene.d.ts +13 -0
- package/build/src/modules/state/actions/scene/getallscenedata.d.ts +9 -0
- package/build/src/modules/state/actions/scene/index.d.ts +4 -0
- package/build/src/modules/state/actions/scene/setbackground.d.ts +12 -0
- package/build/src/modules/state/actions/scene/updatescene.d.ts +20 -0
- package/build/src/modules/state/actions/toolbox/index.d.ts +4 -0
- package/build/src/modules/state/actions/toolbox/setgizmomode.d.ts +12 -0
- package/build/src/modules/state/actions/toolbox/setgizmoscalelinked.d.ts +8 -0
- package/build/src/modules/state/actions/toolbox/setgizmovisible.d.ts +8 -0
- package/build/src/modules/state/actions/toolbox/usetool.d.ts +13 -0
- package/build/src/modules/state/types/ActionTypes.d.ts +18 -0
- package/build/src/{com → modules/state}/types/COMBaseEntity.d.ts +1 -1
- package/build/src/modules/state/types/COMEntity.d.ts +6 -0
- package/build/src/{com → modules/state}/types/COMGeometry.d.ts +1 -1
- package/build/src/{com → modules/state}/types/COMGroup.d.ts +3 -1
- package/build/src/{com → modules/state}/types/COMLight.d.ts +3 -1
- package/build/src/{com → modules/state}/types/COMModel.d.ts +4 -2
- package/build/src/modules/state/types/COMPov.d.ts +9 -0
- package/build/src/modules/state/types/COMPrimitive.d.ts +13 -0
- package/build/src/modules/state/types/index.d.ts +11 -0
- package/build/src/modules/systeminfo/SystemInfo.cjs +1 -2
- package/build/src/modules/systeminfo/SystemInfo.d.ts +6 -9
- package/build/src/modules/systeminfo/SystemInfo.mjs +3 -113
- package/build/src/{toolbox → modules/toolbox}/BaseTool.d.ts +6 -6
- package/build/src/modules/toolbox/Toolbox.cjs +1 -0
- package/build/src/{toolbox → modules/toolbox}/Toolbox.d.ts +10 -6
- package/build/src/modules/toolbox/Toolbox.mjs +99 -0
- package/build/src/{toolbox → modules/toolbox}/select/SelectTool.d.ts +5 -5
- package/build/src/{toolbox → modules/toolbox}/transform/TransformTool.d.ts +6 -6
- package/build/src/types/SceneData.d.ts +1 -1
- package/build/src/types/SceneObjects.d.ts +6 -6
- package/build/src/types/SceneType.d.ts +1 -1
- package/build/src/types/UUID.d.ts +1 -0
- package/build/src/types/file/index.d.ts +1 -1
- package/build/src/types/index.d.ts +6 -6
- package/package.json +67 -26
- package/build/chunks/PerspectiveCamera-ACx6umAu.mjs +0 -38
- package/build/chunks/PerspectiveCamera-ACx6umAu.mjs.map +0 -1
- package/build/chunks/PerspectiveCamera-BXPNOM71.cjs +0 -2
- package/build/chunks/PerspectiveCamera-BXPNOM71.cjs.map +0 -1
- package/build/chunks/fflate.module-DHdJvhNh.cjs +0 -7
- package/build/chunks/fflate.module-DHdJvhNh.cjs.map +0 -1
- package/build/chunks/fflate.module-DkZg07PZ.mjs +0 -603
- package/build/chunks/fflate.module-DkZg07PZ.mjs.map +0 -1
- package/build/chunks/file-type-error-D6aWGgyc.mjs +0 -15
- package/build/chunks/file-type-error-D6aWGgyc.mjs.map +0 -1
- package/build/chunks/file-type-error-DtvBgs64.cjs +0 -2
- package/build/chunks/file-type-error-DtvBgs64.cjs.map +0 -1
- package/build/chunks/index-C7Wx_9uY.mjs +0 -34
- package/build/chunks/index-C7Wx_9uY.mjs.map +0 -1
- package/build/chunks/index-MNP0K5dt.cjs +0 -2
- package/build/chunks/index-MNP0K5dt.cjs.map +0 -1
- package/build/chunks/network-error-C2ZDC8qS.cjs +0 -2
- package/build/chunks/network-error-C2ZDC8qS.cjs.map +0 -1
- package/build/chunks/network-error-DgecatEk.mjs +0 -27
- package/build/chunks/network-error-DgecatEk.mjs.map +0 -1
- package/build/index.cjs +0 -57
- package/build/index.cjs.map +0 -1
- package/build/index.d.ts +0 -6
- package/build/index.mjs +0 -6809
- package/build/index.mjs.map +0 -1
- package/build/src/animation/AnimationSystem.d.ts +0 -16
- package/build/src/axiscamera/AxisCamera.d.ts +0 -18
- package/build/src/com/Communication.d.ts +0 -74
- package/build/src/com/actions/camera/computeencompassingview.d.ts +0 -9
- package/build/src/com/actions/camera/getcameratransform.d.ts +0 -9
- package/build/src/com/actions/camera/movecamera.d.ts +0 -15
- package/build/src/com/actions/camera/resetcamera.d.ts +0 -7
- package/build/src/com/actions/camera/setcameralayer.d.ts +0 -7
- package/build/src/com/actions/camera/setcameratransform.d.ts +0 -9
- package/build/src/com/actions/camera/zoomcamera.d.ts +0 -8
- package/build/src/com/actions/index.d.ts +0 -60
- package/build/src/com/actions/media/generatemedia.d.ts +0 -14
- package/build/src/com/actions/object/addobject.d.ts +0 -6
- package/build/src/com/actions/object/deleteobject.d.ts +0 -8
- package/build/src/com/actions/object/deselectobject.d.ts +0 -8
- package/build/src/com/actions/object/getallobjects.d.ts +0 -6
- package/build/src/com/actions/object/getobjects.d.ts +0 -8
- package/build/src/com/actions/object/model/dropit.d.ts +0 -7
- package/build/src/com/actions/object/model/modelloaded.d.ts +0 -7
- package/build/src/com/actions/object/model/placeonfloor.d.ts +0 -7
- package/build/src/com/actions/object/selectobject.d.ts +0 -8
- package/build/src/com/actions/object/setparent.d.ts +0 -13
- package/build/src/com/actions/object/updateobject.d.ts +0 -8
- package/build/src/com/actions/renderer/startrender.d.ts +0 -5
- package/build/src/com/actions/scene/exportscene.d.ts +0 -8
- package/build/src/com/actions/scene/getallscenedata.d.ts +0 -6
- package/build/src/com/actions/scene/launchar.d.ts +0 -9
- package/build/src/com/actions/scene/setbackground.d.ts +0 -7
- package/build/src/com/actions/scene/updatescene.d.ts +0 -11
- package/build/src/com/actions/toolbox/select/setgizmomode.d.ts +0 -7
- package/build/src/com/actions/toolbox/transform/setgizmoscalelinked.d.ts +0 -5
- package/build/src/com/actions/toolbox/transform/setgizmovisible.d.ts +0 -5
- package/build/src/com/actions/toolbox/usetool.d.ts +0 -8
- package/build/src/com/types/COMEntity.d.ts +0 -6
- package/build/src/com/types/COMPov.d.ts +0 -7
- package/build/src/com/types/COMPrimitive.d.ts +0 -11
- package/build/src/com/types/index.d.ts +0 -11
- package/build/src/controls/OrbitControls.d.ts +0 -38
- package/build/src/dive.d.ts +0 -49
- package/build/src/error/index.d.ts +0 -4
- package/build/src/helper/index.d.ts +0 -7
- package/build/src/modules/_system/ModuleImporter.d.ts +0 -21
- package/build/src/modules/_system/ModuleRegistry.d.ts +0 -72
- package/build/src/modules/ar/ARSystem.cjs.map +0 -1
- package/build/src/modules/ar/ARSystem.mjs.map +0 -1
- package/build/src/modules/asset/converter/AssetConverter.cjs.map +0 -1
- package/build/src/modules/asset/converter/AssetConverter.mjs.map +0 -1
- package/build/src/modules/asset/exporter/AssetExporter.cjs.map +0 -1
- package/build/src/modules/asset/exporter/AssetExporter.mjs.map +0 -1
- package/build/src/modules/asset/loader/AssetLoader.cjs.map +0 -1
- package/build/src/modules/asset/loader/AssetLoader.mjs.map +0 -1
- package/build/src/modules/index.cjs +0 -2
- package/build/src/modules/index.cjs.map +0 -1
- package/build/src/modules/index.d.ts +0 -10
- package/build/src/modules/index.mjs +0 -109
- package/build/src/modules/index.mjs.map +0 -1
- package/build/src/modules/mediacreator/MediaCreator.cjs.map +0 -1
- package/build/src/modules/mediacreator/MediaCreator.mjs.map +0 -1
- package/build/src/modules/systeminfo/SystemInfo.cjs.map +0 -1
- package/build/src/modules/systeminfo/SystemInfo.mjs.map +0 -1
- /package/build/src/{grid → components/grid}/Grid.d.ts +0 -0
- /package/build/src/{constant → constants}/AxisHelperColors.d.ts +0 -0
- /package/build/src/{constant → constants}/GridColors.d.ts +0 -0
- /package/build/src/{constant → constants}/VisibilityLayerMask.d.ts +0 -0
- /package/build/src/{helper → helpers}/applyMixins/applyMixins.d.ts +0 -0
- /package/build/src/{helper → helpers}/findInterface/findInterface.d.ts +0 -0
- /package/build/src/{helper → helpers}/getFileTypeFromUri/getFileTypeFromUri.d.ts +0 -0
- /package/build/src/{helper → helpers}/getObjectDelta/getObjectDelta.d.ts +0 -0
- /package/build/src/{helper/isInterface → helpers/implementsInterface}/implementsInterface.d.ts +0 -0
- /package/build/src/{math → helpers/math}/ceil/ceilExp.d.ts +0 -0
- /package/build/src/{math → helpers/math}/degToRad/degToRad.d.ts +0 -0
- /package/build/src/{math → helpers/math}/floor/floorExp.d.ts +0 -0
- /package/build/src/{math → helpers/math}/helper/shift.d.ts +0 -0
- /package/build/src/{math → helpers/math}/index.d.ts +0 -0
- /package/build/src/{math → helpers/math}/radToDeg/radToDeg.d.ts +0 -0
- /package/build/src/{math → helpers/math}/round/roundExp.d.ts +0 -0
- /package/build/src/{math → helpers/math}/signedAngleTo/signedAngleTo.d.ts +0 -0
- /package/build/src/{math → helpers/math}/toFixed/toFixedExp.d.ts +0 -0
- /package/build/src/{math → helpers/math}/truncate/truncateExp.d.ts +0 -0
- /package/build/src/{interface → interfaces}/Hoverable.d.ts +0 -0
- /package/build/src/{interface → interfaces}/Movable.d.ts +0 -0
- /package/build/src/{interface → interfaces}/Rotatable.d.ts +0 -0
- /package/build/src/{interface → interfaces}/Scalable.d.ts +0 -0
- /package/build/src/{interface → interfaces}/Selectable.d.ts +0 -0
- /package/build/src/{events → modules/events}/EventExecutor.d.ts +0 -0
- /package/build/src/{com → modules/state}/types/COMEntityType.d.ts +0 -0
- /package/build/src/{com → modules/state}/types/COMGeometryType.d.ts +0 -0
- /package/build/src/{com → modules/state}/types/COMMaterial.d.ts +0 -0
|
@@ -2,10 +2,9 @@ var ve = Object.defineProperty;
|
|
|
2
2
|
var Ge = (d, t, e) => t in d ? ve(d, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : d[t] = e;
|
|
3
3
|
var J = (d, t, e) => Ge(d, typeof t != "symbol" ? t + "" : t, e);
|
|
4
4
|
import { TrianglesDrawMode as Be, TriangleFanDrawMode as ne, TriangleStripDrawMode as Se, Loader as we, LoaderUtils as V, FileLoader as W, MeshPhysicalMaterial as C, Vector2 as z, Color as G, LinearSRGBColorSpace as O, SRGBColorSpace as P, SpotLight as Ue, PointLight as je, DirectionalLight as Ke, Matrix4 as q, Vector3 as B, Quaternion as _e, InstancedMesh as Ve, InstancedBufferAttribute as Xe, Object3D as ie, TextureLoader as ye, ImageBitmapLoader as We, BufferAttribute as v, InterleavedBuffer as ze, InterleavedBufferAttribute as qe, LinearMipmapLinearFilter as Le, NearestMipmapLinearFilter as Ye, LinearMipmapNearestFilter as Qe, NearestMipmapNearestFilter as Je, LinearFilter as Me, NearestFilter as Ze, RepeatWrapping as Y, MirroredRepeatWrapping as be, ClampToEdgeWrapping as Ne, PointsMaterial as $e, Material as Z, LineBasicMaterial as et, MeshStandardMaterial as Ie, DoubleSide as tt, MeshBasicMaterial as K, PropertyBinding as nt, BufferGeometry as Ce, SkinnedMesh as st, Mesh as Oe, LineSegments as rt, Line as it, LineLoop as ot, Points as at, Group as X, PerspectiveCamera as ct, MathUtils as ut, OrthographicCamera as lt, Skeleton as ft, AnimationClip as dt, Bone as ht, InterpolateDiscrete as pt, InterpolateLinear as Fe, Texture as ce, VectorKeyframeTrack as ue, NumberKeyframeTrack as le, QuaternionKeyframeTrack as fe, ColorManagement as de, FrontSide as mt, Interpolant as gt, Box3 as At, Sphere as Tt, NoColorSpace as k } from "three";
|
|
5
|
-
import { u as xt,
|
|
6
|
-
import {
|
|
7
|
-
|
|
8
|
-
function Ae(d, t) {
|
|
5
|
+
import { u as xt, a as he, F as pe, P as me } from "../../../../chunks/parse-error-DRBVHL9E.mjs";
|
|
6
|
+
import { g as Rt, i as Et, S as St } from "../../../../chunks/FileTypes-qgYnI0Jg.mjs";
|
|
7
|
+
function ge(d, t) {
|
|
9
8
|
if (t === Be)
|
|
10
9
|
return console.warn("THREE.BufferGeometryUtils.toTrianglesDrawMode(): Geometry already defined as triangles."), d;
|
|
11
10
|
if (t === ne || t === Se) {
|
|
@@ -32,40 +31,40 @@ function Ae(d, t) {
|
|
|
32
31
|
} else
|
|
33
32
|
return console.error("THREE.BufferGeometryUtils.toTrianglesDrawMode(): Unknown draw mode:", t), d;
|
|
34
33
|
}
|
|
35
|
-
class
|
|
34
|
+
class wt extends we {
|
|
36
35
|
constructor(t) {
|
|
37
36
|
super(t), this.dracoLoader = null, this.ktx2Loader = null, this.meshoptDecoder = null, this.pluginCallbacks = [], this.register(function(e) {
|
|
38
|
-
return new
|
|
39
|
-
}), this.register(function(e) {
|
|
40
|
-
return new Pt(e);
|
|
41
|
-
}), this.register(function(e) {
|
|
42
|
-
return new kt(e);
|
|
37
|
+
return new bt(e);
|
|
43
38
|
}), this.register(function(e) {
|
|
44
39
|
return new Ht(e);
|
|
45
40
|
}), this.register(function(e) {
|
|
46
|
-
return new
|
|
41
|
+
return new vt(e);
|
|
47
42
|
}), this.register(function(e) {
|
|
48
|
-
return new
|
|
43
|
+
return new Gt(e);
|
|
49
44
|
}), this.register(function(e) {
|
|
50
45
|
return new It(e);
|
|
51
46
|
}), this.register(function(e) {
|
|
52
47
|
return new Ct(e);
|
|
53
|
-
}), this.register(function(e) {
|
|
54
|
-
return new yt(e);
|
|
55
48
|
}), this.register(function(e) {
|
|
56
49
|
return new Ot(e);
|
|
50
|
+
}), this.register(function(e) {
|
|
51
|
+
return new Ft(e);
|
|
57
52
|
}), this.register(function(e) {
|
|
58
53
|
return new Mt(e);
|
|
59
54
|
}), this.register(function(e) {
|
|
60
55
|
return new Dt(e);
|
|
61
56
|
}), this.register(function(e) {
|
|
62
|
-
return new
|
|
57
|
+
return new Nt(e);
|
|
63
58
|
}), this.register(function(e) {
|
|
64
|
-
return new
|
|
59
|
+
return new kt(e);
|
|
65
60
|
}), this.register(function(e) {
|
|
66
|
-
return new
|
|
61
|
+
return new Pt(e);
|
|
67
62
|
}), this.register(function(e) {
|
|
68
|
-
return new
|
|
63
|
+
return new yt(e);
|
|
64
|
+
}), this.register(function(e) {
|
|
65
|
+
return new Bt(e);
|
|
66
|
+
}), this.register(function(e) {
|
|
67
|
+
return new Ut(e);
|
|
69
68
|
});
|
|
70
69
|
}
|
|
71
70
|
load(t, e, i, n) {
|
|
@@ -120,7 +119,7 @@ class Et extends we {
|
|
|
120
119
|
else if (t instanceof ArrayBuffer)
|
|
121
120
|
if (o.decode(new Uint8Array(t, 0, 4)) === De) {
|
|
122
121
|
try {
|
|
123
|
-
s[w.KHR_BINARY_GLTF] = new
|
|
122
|
+
s[w.KHR_BINARY_GLTF] = new jt(t);
|
|
124
123
|
} catch (u) {
|
|
125
124
|
n && n(u);
|
|
126
125
|
return;
|
|
@@ -134,7 +133,7 @@ class Et extends we {
|
|
|
134
133
|
n && n(new Error("THREE.GLTFLoader: Unsupported asset. glTF versions >=2.0 are supported."));
|
|
135
134
|
return;
|
|
136
135
|
}
|
|
137
|
-
const c = new
|
|
136
|
+
const c = new tn(r, {
|
|
138
137
|
path: e || this.resourcePath || "",
|
|
139
138
|
crossOrigin: this.crossOrigin,
|
|
140
139
|
requestHeader: this.requestHeader,
|
|
@@ -152,16 +151,16 @@ class Et extends we {
|
|
|
152
151
|
const u = r.extensionsUsed[l], p = r.extensionsRequired || [];
|
|
153
152
|
switch (u) {
|
|
154
153
|
case w.KHR_MATERIALS_UNLIT:
|
|
155
|
-
s[u] = new
|
|
154
|
+
s[u] = new Lt();
|
|
156
155
|
break;
|
|
157
156
|
case w.KHR_DRACO_MESH_COMPRESSION:
|
|
158
|
-
s[u] = new
|
|
157
|
+
s[u] = new Kt(r, this.dracoLoader);
|
|
159
158
|
break;
|
|
160
159
|
case w.KHR_TEXTURE_TRANSFORM:
|
|
161
|
-
s[u] = new
|
|
160
|
+
s[u] = new Vt();
|
|
162
161
|
break;
|
|
163
162
|
case w.KHR_MESH_QUANTIZATION:
|
|
164
|
-
s[u] = new
|
|
163
|
+
s[u] = new Xt();
|
|
165
164
|
break;
|
|
166
165
|
default:
|
|
167
166
|
p.indexOf(u) >= 0 && a[u] === void 0 && console.warn('THREE.GLTFLoader: Unknown extension "' + u + '".');
|
|
@@ -176,7 +175,7 @@ class Et extends we {
|
|
|
176
175
|
});
|
|
177
176
|
}
|
|
178
177
|
}
|
|
179
|
-
function
|
|
178
|
+
function _t() {
|
|
180
179
|
let d = {};
|
|
181
180
|
return {
|
|
182
181
|
get: function(t) {
|
|
@@ -216,7 +215,7 @@ const w = {
|
|
|
216
215
|
EXT_MESHOPT_COMPRESSION: "EXT_meshopt_compression",
|
|
217
216
|
EXT_MESH_GPU_INSTANCING: "EXT_mesh_gpu_instancing"
|
|
218
217
|
};
|
|
219
|
-
class
|
|
218
|
+
class yt {
|
|
220
219
|
constructor(t) {
|
|
221
220
|
this.parser = t, this.name = w.KHR_LIGHTS_PUNCTUAL, this.cache = { refs: {}, uses: {} };
|
|
222
221
|
}
|
|
@@ -262,7 +261,7 @@ class wt {
|
|
|
262
261
|
});
|
|
263
262
|
}
|
|
264
263
|
}
|
|
265
|
-
class
|
|
264
|
+
class Lt {
|
|
266
265
|
constructor() {
|
|
267
266
|
this.name = w.KHR_MATERIALS_UNLIT;
|
|
268
267
|
}
|
|
@@ -283,7 +282,7 @@ class _t {
|
|
|
283
282
|
return Promise.all(n);
|
|
284
283
|
}
|
|
285
284
|
}
|
|
286
|
-
class
|
|
285
|
+
class Mt {
|
|
287
286
|
constructor(t) {
|
|
288
287
|
this.parser = t, this.name = w.KHR_MATERIALS_EMISSIVE_STRENGTH;
|
|
289
288
|
}
|
|
@@ -295,7 +294,7 @@ class yt {
|
|
|
295
294
|
return r !== void 0 && (e.emissiveIntensity = r), Promise.resolve();
|
|
296
295
|
}
|
|
297
296
|
}
|
|
298
|
-
class
|
|
297
|
+
class bt {
|
|
299
298
|
constructor(t) {
|
|
300
299
|
this.parser = t, this.name = w.KHR_MATERIALS_CLEARCOAT;
|
|
301
300
|
}
|
|
@@ -315,7 +314,7 @@ class Lt {
|
|
|
315
314
|
return Promise.all(r);
|
|
316
315
|
}
|
|
317
316
|
}
|
|
318
|
-
class
|
|
317
|
+
class Nt {
|
|
319
318
|
constructor(t) {
|
|
320
319
|
this.parser = t, this.name = w.KHR_MATERIALS_IRIDESCENCE;
|
|
321
320
|
}
|
|
@@ -331,7 +330,7 @@ class Mt {
|
|
|
331
330
|
return s.iridescenceFactor !== void 0 && (e.iridescence = s.iridescenceFactor), s.iridescenceTexture !== void 0 && r.push(i.assignTexture(e, "iridescenceMap", s.iridescenceTexture)), s.iridescenceIor !== void 0 && (e.iridescenceIOR = s.iridescenceIor), e.iridescenceThicknessRange === void 0 && (e.iridescenceThicknessRange = [100, 400]), s.iridescenceThicknessMinimum !== void 0 && (e.iridescenceThicknessRange[0] = s.iridescenceThicknessMinimum), s.iridescenceThicknessMaximum !== void 0 && (e.iridescenceThicknessRange[1] = s.iridescenceThicknessMaximum), s.iridescenceThicknessTexture !== void 0 && r.push(i.assignTexture(e, "iridescenceThicknessMap", s.iridescenceThicknessTexture)), Promise.all(r);
|
|
332
331
|
}
|
|
333
332
|
}
|
|
334
|
-
class
|
|
333
|
+
class It {
|
|
335
334
|
constructor(t) {
|
|
336
335
|
this.parser = t, this.name = w.KHR_MATERIALS_SHEEN;
|
|
337
336
|
}
|
|
@@ -353,7 +352,7 @@ class bt {
|
|
|
353
352
|
return s.sheenRoughnessFactor !== void 0 && (e.sheenRoughness = s.sheenRoughnessFactor), s.sheenColorTexture !== void 0 && r.push(i.assignTexture(e, "sheenColorMap", s.sheenColorTexture, P)), s.sheenRoughnessTexture !== void 0 && r.push(i.assignTexture(e, "sheenRoughnessMap", s.sheenRoughnessTexture)), Promise.all(r);
|
|
354
353
|
}
|
|
355
354
|
}
|
|
356
|
-
class
|
|
355
|
+
class Ct {
|
|
357
356
|
constructor(t) {
|
|
358
357
|
this.parser = t, this.name = w.KHR_MATERIALS_TRANSMISSION;
|
|
359
358
|
}
|
|
@@ -369,7 +368,7 @@ class Nt {
|
|
|
369
368
|
return s.transmissionFactor !== void 0 && (e.transmission = s.transmissionFactor), s.transmissionTexture !== void 0 && r.push(i.assignTexture(e, "transmissionMap", s.transmissionTexture)), Promise.all(r);
|
|
370
369
|
}
|
|
371
370
|
}
|
|
372
|
-
class
|
|
371
|
+
class Ot {
|
|
373
372
|
constructor(t) {
|
|
374
373
|
this.parser = t, this.name = w.KHR_MATERIALS_VOLUME;
|
|
375
374
|
}
|
|
@@ -387,7 +386,7 @@ class It {
|
|
|
387
386
|
return e.attenuationColor = new G().setRGB(a[0], a[1], a[2], O), Promise.all(r);
|
|
388
387
|
}
|
|
389
388
|
}
|
|
390
|
-
class
|
|
389
|
+
class Ft {
|
|
391
390
|
constructor(t) {
|
|
392
391
|
this.parser = t, this.name = w.KHR_MATERIALS_IOR;
|
|
393
392
|
}
|
|
@@ -403,7 +402,7 @@ class Ct {
|
|
|
403
402
|
return e.ior = r.ior !== void 0 ? r.ior : 1.5, Promise.resolve();
|
|
404
403
|
}
|
|
405
404
|
}
|
|
406
|
-
class
|
|
405
|
+
class Dt {
|
|
407
406
|
constructor(t) {
|
|
408
407
|
this.parser = t, this.name = w.KHR_MATERIALS_SPECULAR;
|
|
409
408
|
}
|
|
@@ -421,7 +420,7 @@ class Ot {
|
|
|
421
420
|
return e.specularColor = new G().setRGB(a[0], a[1], a[2], O), s.specularColorTexture !== void 0 && r.push(i.assignTexture(e, "specularColorMap", s.specularColorTexture, P)), Promise.all(r);
|
|
422
421
|
}
|
|
423
422
|
}
|
|
424
|
-
class
|
|
423
|
+
class Pt {
|
|
425
424
|
constructor(t) {
|
|
426
425
|
this.parser = t, this.name = w.EXT_MATERIALS_BUMP;
|
|
427
426
|
}
|
|
@@ -437,7 +436,7 @@ class Ft {
|
|
|
437
436
|
return e.bumpScale = s.bumpFactor !== void 0 ? s.bumpFactor : 1, s.bumpTexture !== void 0 && r.push(i.assignTexture(e, "bumpMap", s.bumpTexture)), Promise.all(r);
|
|
438
437
|
}
|
|
439
438
|
}
|
|
440
|
-
class
|
|
439
|
+
class kt {
|
|
441
440
|
constructor(t) {
|
|
442
441
|
this.parser = t, this.name = w.KHR_MATERIALS_ANISOTROPY;
|
|
443
442
|
}
|
|
@@ -453,7 +452,7 @@ class Dt {
|
|
|
453
452
|
return s.anisotropyStrength !== void 0 && (e.anisotropy = s.anisotropyStrength), s.anisotropyRotation !== void 0 && (e.anisotropyRotation = s.anisotropyRotation), s.anisotropyTexture !== void 0 && r.push(i.assignTexture(e, "anisotropyMap", s.anisotropyTexture)), Promise.all(r);
|
|
454
453
|
}
|
|
455
454
|
}
|
|
456
|
-
class
|
|
455
|
+
class Ht {
|
|
457
456
|
constructor(t) {
|
|
458
457
|
this.parser = t, this.name = w.KHR_TEXTURE_BASISU;
|
|
459
458
|
}
|
|
@@ -470,7 +469,7 @@ class Pt {
|
|
|
470
469
|
return e.loadTextureImage(t, r.source, s);
|
|
471
470
|
}
|
|
472
471
|
}
|
|
473
|
-
class
|
|
472
|
+
class vt {
|
|
474
473
|
constructor(t) {
|
|
475
474
|
this.parser = t, this.name = w.EXT_TEXTURE_WEBP, this.isSupported = null;
|
|
476
475
|
}
|
|
@@ -500,7 +499,7 @@ class kt {
|
|
|
500
499
|
})), this.isSupported;
|
|
501
500
|
}
|
|
502
501
|
}
|
|
503
|
-
class
|
|
502
|
+
class Gt {
|
|
504
503
|
constructor(t) {
|
|
505
504
|
this.parser = t, this.name = w.EXT_TEXTURE_AVIF, this.isSupported = null;
|
|
506
505
|
}
|
|
@@ -530,7 +529,7 @@ class Ht {
|
|
|
530
529
|
})), this.isSupported;
|
|
531
530
|
}
|
|
532
531
|
}
|
|
533
|
-
class
|
|
532
|
+
class Bt {
|
|
534
533
|
constructor(t) {
|
|
535
534
|
this.name = w.EXT_MESHOPT_COMPRESSION, this.parser = t;
|
|
536
535
|
}
|
|
@@ -556,7 +555,7 @@ class vt {
|
|
|
556
555
|
return null;
|
|
557
556
|
}
|
|
558
557
|
}
|
|
559
|
-
class
|
|
558
|
+
class Ut {
|
|
560
559
|
constructor(t) {
|
|
561
560
|
this.name = w.EXT_MESH_GPU_INSTANCING, this.parser = t;
|
|
562
561
|
}
|
|
@@ -588,8 +587,8 @@ class Gt {
|
|
|
588
587
|
}));
|
|
589
588
|
}
|
|
590
589
|
}
|
|
591
|
-
const De = "glTF", j = 12,
|
|
592
|
-
class
|
|
590
|
+
const De = "glTF", j = 12, Ae = { JSON: 1313821514, BIN: 5130562 };
|
|
591
|
+
class jt {
|
|
593
592
|
constructor(t) {
|
|
594
593
|
this.name = w.KHR_BINARY_GLTF, this.content = null, this.body = null;
|
|
595
594
|
const e = new DataView(t, 0, j), i = new TextDecoder();
|
|
@@ -607,10 +606,10 @@ class Bt {
|
|
|
607
606
|
const a = r.getUint32(s, !0);
|
|
608
607
|
s += 4;
|
|
609
608
|
const o = r.getUint32(s, !0);
|
|
610
|
-
if (s += 4, o ===
|
|
609
|
+
if (s += 4, o === Ae.JSON) {
|
|
611
610
|
const c = new Uint8Array(t, j + s, a);
|
|
612
611
|
this.content = i.decode(c);
|
|
613
|
-
} else if (o ===
|
|
612
|
+
} else if (o === Ae.BIN) {
|
|
614
613
|
const c = j + s;
|
|
615
614
|
this.body = t.slice(c, c + a);
|
|
616
615
|
}
|
|
@@ -620,7 +619,7 @@ class Bt {
|
|
|
620
619
|
throw new Error("THREE.GLTFLoader: JSON content not found.");
|
|
621
620
|
}
|
|
622
621
|
}
|
|
623
|
-
class
|
|
622
|
+
class Kt {
|
|
624
623
|
constructor(t, e) {
|
|
625
624
|
if (!e)
|
|
626
625
|
throw new Error("THREE.GLTFLoader: No DRACOLoader instance provided.");
|
|
@@ -652,7 +651,7 @@ class Ut {
|
|
|
652
651
|
});
|
|
653
652
|
}
|
|
654
653
|
}
|
|
655
|
-
class
|
|
654
|
+
class Vt {
|
|
656
655
|
constructor() {
|
|
657
656
|
this.name = w.KHR_TEXTURE_TRANSFORM;
|
|
658
657
|
}
|
|
@@ -660,7 +659,7 @@ class jt {
|
|
|
660
659
|
return (e.texCoord === void 0 || e.texCoord === t.channel) && e.offset === void 0 && e.rotation === void 0 && e.scale === void 0 || (t = t.clone(), e.texCoord !== void 0 && (t.channel = e.texCoord), e.offset !== void 0 && t.offset.fromArray(e.offset), e.rotation !== void 0 && (t.rotation = e.rotation), e.scale !== void 0 && t.repeat.fromArray(e.scale), t.needsUpdate = !0), t;
|
|
661
660
|
}
|
|
662
661
|
}
|
|
663
|
-
class
|
|
662
|
+
class Xt {
|
|
664
663
|
constructor() {
|
|
665
664
|
this.name = w.KHR_MESH_QUANTIZATION;
|
|
666
665
|
}
|
|
@@ -684,11 +683,11 @@ class Pe extends gt {
|
|
|
684
683
|
return r;
|
|
685
684
|
}
|
|
686
685
|
}
|
|
687
|
-
const
|
|
688
|
-
class
|
|
686
|
+
const Wt = new _e();
|
|
687
|
+
class zt extends Pe {
|
|
689
688
|
interpolate_(t, e, i, n) {
|
|
690
689
|
const r = super.interpolate_(t, e, i, n);
|
|
691
|
-
return
|
|
690
|
+
return Wt.fromArray(r).normalize().toArray(r), r;
|
|
692
691
|
}
|
|
693
692
|
}
|
|
694
693
|
const I = {
|
|
@@ -706,14 +705,14 @@ const I = {
|
|
|
706
705
|
5123: Uint16Array,
|
|
707
706
|
5125: Uint32Array,
|
|
708
707
|
5126: Float32Array
|
|
709
|
-
},
|
|
708
|
+
}, Te = {
|
|
710
709
|
9728: Ze,
|
|
711
710
|
9729: Me,
|
|
712
711
|
9984: Je,
|
|
713
712
|
9985: Qe,
|
|
714
713
|
9986: Ye,
|
|
715
714
|
9987: Le
|
|
716
|
-
},
|
|
715
|
+
}, xe = {
|
|
717
716
|
33071: Ne,
|
|
718
717
|
33648: be,
|
|
719
718
|
10497: Y
|
|
@@ -741,7 +740,7 @@ const I = {
|
|
|
741
740
|
translation: "position",
|
|
742
741
|
rotation: "quaternion",
|
|
743
742
|
weights: "morphTargetInfluences"
|
|
744
|
-
},
|
|
743
|
+
}, qt = {
|
|
745
744
|
CUBICSPLINE: void 0,
|
|
746
745
|
// We use a custom interpolant (GLTFCubicSplineInterpolation) for CUBICSPLINE tracks. Each
|
|
747
746
|
// keyframe track will be initialized with a default interpolation type, then modified.
|
|
@@ -752,7 +751,7 @@ const I = {
|
|
|
752
751
|
MASK: "MASK",
|
|
753
752
|
BLEND: "BLEND"
|
|
754
753
|
};
|
|
755
|
-
function
|
|
754
|
+
function Yt(d) {
|
|
756
755
|
return d.DefaultMaterial === void 0 && (d.DefaultMaterial = new Ie({
|
|
757
756
|
color: 16777215,
|
|
758
757
|
emissive: 0,
|
|
@@ -770,7 +769,7 @@ function H(d, t, e) {
|
|
|
770
769
|
function D(d, t) {
|
|
771
770
|
t.extras !== void 0 && (typeof t.extras == "object" ? Object.assign(d.userData, t.extras) : console.warn("THREE.GLTFLoader: Ignoring primitive type .extras, " + t.extras));
|
|
772
771
|
}
|
|
773
|
-
function
|
|
772
|
+
function Qt(d, t, e) {
|
|
774
773
|
let i = !1, n = !1, r = !1;
|
|
775
774
|
for (let c = 0, l = t.length; c < l; c++) {
|
|
776
775
|
const u = t[c];
|
|
@@ -802,7 +801,7 @@ function qt(d, t, e) {
|
|
|
802
801
|
return i && (d.morphAttributes.position = l), n && (d.morphAttributes.normal = u), r && (d.morphAttributes.color = p), d.morphTargetsRelative = !0, d;
|
|
803
802
|
});
|
|
804
803
|
}
|
|
805
|
-
function
|
|
804
|
+
function Jt(d, t) {
|
|
806
805
|
if (d.updateMorphTargets(), t.weights !== void 0)
|
|
807
806
|
for (let e = 0, i = t.weights.length; e < i; e++)
|
|
808
807
|
d.morphTargetInfluences[e] = t.weights[e];
|
|
@@ -816,7 +815,7 @@ function Yt(d, t) {
|
|
|
816
815
|
console.warn("THREE.GLTFLoader: Invalid extras.targetNames length. Ignoring names.");
|
|
817
816
|
}
|
|
818
817
|
}
|
|
819
|
-
function
|
|
818
|
+
function Zt(d) {
|
|
820
819
|
let t;
|
|
821
820
|
const e = d.extensions && d.extensions[w.KHR_DRACO_MESH_COMPRESSION];
|
|
822
821
|
if (e ? t = "draco:" + e.bufferView + ":" + e.indices + ":" + te(e.attributes) : t = d.indices + ":" + te(d.attributes) + ":" + d.mode, d.targets !== void 0)
|
|
@@ -845,13 +844,13 @@ function re(d) {
|
|
|
845
844
|
throw new Error("THREE.GLTFLoader: Unsupported normalized accessor component type.");
|
|
846
845
|
}
|
|
847
846
|
}
|
|
848
|
-
function
|
|
847
|
+
function $t(d) {
|
|
849
848
|
return d.search(/\.jpe?g($|\?)/i) > 0 || d.search(/^data\:image\/jpeg/) === 0 ? "image/jpeg" : d.search(/\.webp($|\?)/i) > 0 || d.search(/^data\:image\/webp/) === 0 ? "image/webp" : "image/png";
|
|
850
849
|
}
|
|
851
|
-
const
|
|
852
|
-
class
|
|
850
|
+
const en = new q();
|
|
851
|
+
class tn {
|
|
853
852
|
constructor(t = {}, e = {}) {
|
|
854
|
-
this.json = t, this.extensions = {}, this.plugins = {}, this.options = e, this.cache = new
|
|
853
|
+
this.json = t, this.extensions = {}, this.plugins = {}, this.options = e, this.cache = new _t(), 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 = {};
|
|
855
854
|
let i = !1, n = !1, r = -1;
|
|
856
855
|
typeof navigator < "u" && (i = /^((?!chrome|android).)*safari/i.test(navigator.userAgent) === !0, n = navigator.userAgent.indexOf("Firefox") > -1, r = n ? navigator.userAgent.match(/Firefox\/([0-9]+)\./)[1] : -1), typeof createImageBitmap > "u" || i || n && r < 98 ? this.textureLoader = new ye(this.options.manager) : this.textureLoader = new We(this.options.manager), this.textureLoader.setCrossOrigin(this.options.crossOrigin), this.textureLoader.setRequestHeader(this.options.requestHeader), this.fileLoader = new W(this.options.manager), this.fileLoader.setResponseType("arraybuffer"), this.options.crossOrigin === "use-credentials" && this.fileLoader.setWithCredentials(!0);
|
|
857
856
|
}
|
|
@@ -1114,7 +1113,7 @@ class $t {
|
|
|
1114
1113
|
const c = this.loadImageSource(e, i).then(function(l) {
|
|
1115
1114
|
l.flipY = !1, l.name = s.name || a.name || "", l.name === "" && typeof a.uri == "string" && a.uri.startsWith("data:image/") === !1 && (l.name = a.uri);
|
|
1116
1115
|
const p = (r.samplers || {})[s.sampler] || {};
|
|
1117
|
-
return l.magFilter =
|
|
1116
|
+
return l.magFilter = Te[p.magFilter] || Me, l.minFilter = Te[p.minFilter] || Le, l.wrapS = xe[p.wrapS] || Y, l.wrapT = xe[p.wrapT] || Y, n.associations.set(l, { textures: t }), l;
|
|
1118
1117
|
}).catch(function() {
|
|
1119
1118
|
return null;
|
|
1120
1119
|
});
|
|
@@ -1143,7 +1142,7 @@ class $t {
|
|
|
1143
1142
|
}), e.load(V.resolveURL(u, r.path), x, void 0, A);
|
|
1144
1143
|
});
|
|
1145
1144
|
}).then(function(u) {
|
|
1146
|
-
return c === !0 && a.revokeObjectURL(o), u.userData.mimeType = s.mimeType ||
|
|
1145
|
+
return c === !0 && a.revokeObjectURL(o), u.userData.mimeType = s.mimeType || $t(s.uri), u;
|
|
1147
1146
|
}).catch(function(u) {
|
|
1148
1147
|
throw console.error("THREE.GLTFLoader: Couldn't load texture", o), u;
|
|
1149
1148
|
});
|
|
@@ -1258,17 +1257,17 @@ class $t {
|
|
|
1258
1257
|
const e = this, i = this.extensions, n = this.primitiveCache;
|
|
1259
1258
|
function r(a) {
|
|
1260
1259
|
return i[w.KHR_DRACO_MESH_COMPRESSION].decodePrimitive(a, e).then(function(o) {
|
|
1261
|
-
return
|
|
1260
|
+
return Re(o, a, e);
|
|
1262
1261
|
});
|
|
1263
1262
|
}
|
|
1264
1263
|
const s = [];
|
|
1265
1264
|
for (let a = 0, o = t.length; a < o; a++) {
|
|
1266
|
-
const c = t[a], l =
|
|
1265
|
+
const c = t[a], l = Zt(c), u = n[l];
|
|
1267
1266
|
if (u)
|
|
1268
1267
|
s.push(u.promise);
|
|
1269
1268
|
else {
|
|
1270
1269
|
let p;
|
|
1271
|
-
c.extensions && c.extensions[w.KHR_DRACO_MESH_COMPRESSION] ? p = r(c) : p =
|
|
1270
|
+
c.extensions && c.extensions[w.KHR_DRACO_MESH_COMPRESSION] ? p = r(c) : p = Re(new Ce(), c, e), n[l] = { primitive: c, promise: p }, s.push(p);
|
|
1272
1271
|
}
|
|
1273
1272
|
}
|
|
1274
1273
|
return Promise.all(s);
|
|
@@ -1281,7 +1280,7 @@ class $t {
|
|
|
1281
1280
|
loadMesh(t) {
|
|
1282
1281
|
const e = this, i = this.json, n = this.extensions, r = i.meshes[t], s = r.primitives, a = [];
|
|
1283
1282
|
for (let o = 0, c = s.length; o < c; o++) {
|
|
1284
|
-
const l = s[o].material === void 0 ?
|
|
1283
|
+
const l = s[o].material === void 0 ? Yt(this.cache) : this.getDependency("material", s[o].material);
|
|
1285
1284
|
a.push(l);
|
|
1286
1285
|
}
|
|
1287
1286
|
return a.push(e.loadGeometries(s)), Promise.all(a).then(function(o) {
|
|
@@ -1291,7 +1290,7 @@ class $t {
|
|
|
1291
1290
|
let R;
|
|
1292
1291
|
const y = c[A];
|
|
1293
1292
|
if (T.mode === I.TRIANGLES || T.mode === I.TRIANGLE_STRIP || T.mode === I.TRIANGLE_FAN || T.mode === void 0)
|
|
1294
|
-
R = r.isSkinnedMesh === !0 ? new st(_, y) : new Oe(_, y), R.isSkinnedMesh === !0 && R.normalizeSkinWeights(), T.mode === I.TRIANGLE_STRIP ? R.geometry =
|
|
1293
|
+
R = r.isSkinnedMesh === !0 ? new st(_, y) : new Oe(_, y), R.isSkinnedMesh === !0 && R.normalizeSkinWeights(), T.mode === I.TRIANGLE_STRIP ? R.geometry = ge(R.geometry, Se) : T.mode === I.TRIANGLE_FAN && (R.geometry = ge(R.geometry, ne));
|
|
1295
1294
|
else if (T.mode === I.LINES)
|
|
1296
1295
|
R = new rt(_, y);
|
|
1297
1296
|
else if (T.mode === I.LINE_STRIP)
|
|
@@ -1302,7 +1301,7 @@ class $t {
|
|
|
1302
1301
|
R = new at(_, y);
|
|
1303
1302
|
else
|
|
1304
1303
|
throw new Error("THREE.GLTFLoader: Primitive mode unsupported: " + T.mode);
|
|
1305
|
-
Object.keys(R.geometry.morphAttributes).length > 0 &&
|
|
1304
|
+
Object.keys(R.geometry.morphAttributes).length > 0 && Jt(R, r), R.name = e.createUniqueName(r.name || "mesh_" + t), D(R, r), T.extensions && H(n, R, T), e.assignFinalMaterial(R), u.push(R);
|
|
1306
1305
|
}
|
|
1307
1306
|
for (let A = 0, x = u.length; A < x; A++)
|
|
1308
1307
|
e.associations.set(u[A], {
|
|
@@ -1414,7 +1413,7 @@ class $t {
|
|
|
1414
1413
|
]).then(function(c) {
|
|
1415
1414
|
const l = c[0], u = c[1], p = c[2];
|
|
1416
1415
|
p !== null && l.traverse(function(A) {
|
|
1417
|
-
A.isSkinnedMesh && A.bind(p,
|
|
1416
|
+
A.isSkinnedMesh && A.bind(p, en);
|
|
1418
1417
|
});
|
|
1419
1418
|
for (let A = 0, x = u.length; A < x; A++)
|
|
1420
1419
|
l.add(u[A]);
|
|
@@ -1505,7 +1504,7 @@ class $t {
|
|
|
1505
1504
|
}
|
|
1506
1505
|
break;
|
|
1507
1506
|
}
|
|
1508
|
-
const l = n.interpolation !== void 0 ?
|
|
1507
|
+
const l = n.interpolation !== void 0 ? qt[n.interpolation] : Fe, u = this._getArrayFromAccessor(i);
|
|
1509
1508
|
for (let p = 0, A = o.length; p < A; p++) {
|
|
1510
1509
|
const x = new c(
|
|
1511
1510
|
o[p] + "." + F[r.path],
|
|
@@ -1529,12 +1528,12 @@ class $t {
|
|
|
1529
1528
|
}
|
|
1530
1529
|
_createCubicSplineTrackInterpolant(t) {
|
|
1531
1530
|
t.createInterpolant = function(i) {
|
|
1532
|
-
const n = this instanceof fe ?
|
|
1531
|
+
const n = this instanceof fe ? zt : Pe;
|
|
1533
1532
|
return new n(this.times, this.values, this.getValueSize() / 3, i);
|
|
1534
1533
|
}, t.createInterpolant.isInterpolantFactoryMethodGLTFCubicSpline = !0;
|
|
1535
1534
|
}
|
|
1536
1535
|
}
|
|
1537
|
-
function
|
|
1536
|
+
function nn(d, t, e) {
|
|
1538
1537
|
const i = t.attributes, n = new At();
|
|
1539
1538
|
if (i.POSITION !== void 0) {
|
|
1540
1539
|
const a = e.json.accessors[i.POSITION], o = a.min, c = a.max;
|
|
@@ -1575,7 +1574,7 @@ function en(d, t, e) {
|
|
|
1575
1574
|
const s = new Tt();
|
|
1576
1575
|
n.getCenter(s.center), s.radius = n.min.distanceTo(n.max) / 2, d.boundingSphere = s;
|
|
1577
1576
|
}
|
|
1578
|
-
function
|
|
1577
|
+
function Re(d, t, e) {
|
|
1579
1578
|
const i = t.attributes, n = [];
|
|
1580
1579
|
function r(s, a) {
|
|
1581
1580
|
return e.getDependency("accessor", s).then(function(o) {
|
|
@@ -1592,11 +1591,11 @@ function Ee(d, t, e) {
|
|
|
1592
1591
|
});
|
|
1593
1592
|
n.push(s);
|
|
1594
1593
|
}
|
|
1595
|
-
return de.workingColorSpace !== O && "COLOR_0" in i && console.warn(`THREE.GLTFLoader: Converting vertex colors from "srgb-linear" to "${de.workingColorSpace}" not supported.`), D(d, t),
|
|
1596
|
-
return t.targets !== void 0 ?
|
|
1594
|
+
return de.workingColorSpace !== O && "COLOR_0" in i && console.warn(`THREE.GLTFLoader: Converting vertex colors from "srgb-linear" to "${de.workingColorSpace}" not supported.`), D(d, t), nn(d, t, e), Promise.all(n).then(function() {
|
|
1595
|
+
return t.targets !== void 0 ? Qt(d, t.targets, e) : d;
|
|
1597
1596
|
});
|
|
1598
1597
|
}
|
|
1599
|
-
class
|
|
1598
|
+
class sn {
|
|
1600
1599
|
parse(t) {
|
|
1601
1600
|
const e = {}, i = t.split(`
|
|
1602
1601
|
`);
|
|
@@ -1623,7 +1622,7 @@ class tn {
|
|
|
1623
1622
|
return e;
|
|
1624
1623
|
}
|
|
1625
1624
|
}
|
|
1626
|
-
class
|
|
1625
|
+
class rn extends we {
|
|
1627
1626
|
constructor(t) {
|
|
1628
1627
|
super(t);
|
|
1629
1628
|
}
|
|
@@ -1638,7 +1637,7 @@ class nn extends we {
|
|
|
1638
1637
|
}, i, n);
|
|
1639
1638
|
}
|
|
1640
1639
|
parse(t) {
|
|
1641
|
-
const e = new
|
|
1640
|
+
const e = new sn();
|
|
1642
1641
|
function i(f) {
|
|
1643
1642
|
const h = {};
|
|
1644
1643
|
new W().setResponseType("arraybuffer");
|
|
@@ -1865,37 +1864,34 @@ class nn extends we {
|
|
|
1865
1864
|
return N(l, M), M;
|
|
1866
1865
|
}
|
|
1867
1866
|
}
|
|
1868
|
-
|
|
1869
|
-
|
|
1870
|
-
|
|
1871
|
-
|
|
1872
|
-
}
|
|
1873
|
-
function rn(d) {
|
|
1874
|
-
return d.toLowerCase() in { glb: !0, gltf: !0, usdz: !0 };
|
|
1867
|
+
class Ee extends Error {
|
|
1868
|
+
constructor(t, e, i) {
|
|
1869
|
+
super(e), this.url = t, this.cause = i, this.name = "NetworkError";
|
|
1870
|
+
}
|
|
1875
1871
|
}
|
|
1876
|
-
class
|
|
1872
|
+
class ln {
|
|
1877
1873
|
constructor() {
|
|
1878
1874
|
J(this, "_gltfLoader");
|
|
1879
1875
|
J(this, "_usdzLoader");
|
|
1880
|
-
this._gltfLoader = new
|
|
1876
|
+
this._gltfLoader = new wt(), this._usdzLoader = new rn();
|
|
1881
1877
|
}
|
|
1882
1878
|
async _loadFile(t) {
|
|
1883
1879
|
const e = await fetch(t);
|
|
1884
1880
|
if (!e.ok)
|
|
1885
|
-
throw new
|
|
1881
|
+
throw new Ee(t, `Failed to fetch file from ${t}`);
|
|
1886
1882
|
try {
|
|
1887
1883
|
return await e.arrayBuffer();
|
|
1888
1884
|
} catch {
|
|
1889
|
-
throw new
|
|
1885
|
+
throw new Ee(t, `Failed to fetch file from ${t}`);
|
|
1890
1886
|
}
|
|
1891
1887
|
}
|
|
1892
1888
|
async load(t) {
|
|
1893
|
-
const e =
|
|
1889
|
+
const e = Rt(t);
|
|
1894
1890
|
if (e.length === 0)
|
|
1895
|
-
throw new
|
|
1896
|
-
if (!
|
|
1897
|
-
throw new
|
|
1898
|
-
`Unsupported file type: ${e}. Supported types: ${
|
|
1891
|
+
throw new pe("No file extension found in URI", "");
|
|
1892
|
+
if (!Et(e))
|
|
1893
|
+
throw new pe(
|
|
1894
|
+
`Unsupported file type: ${e}. Supported types: ${St.join(", ")}`,
|
|
1899
1895
|
e
|
|
1900
1896
|
);
|
|
1901
1897
|
const i = await this._loadFile(t);
|
|
@@ -1911,14 +1907,13 @@ class fn {
|
|
|
1911
1907
|
return await this._usdzLoader.parse(i);
|
|
1912
1908
|
}
|
|
1913
1909
|
} catch (n) {
|
|
1914
|
-
throw n instanceof Error ? new
|
|
1910
|
+
throw n instanceof Error ? new me(
|
|
1915
1911
|
`Failed to parse ${e} file: ${n.message}`,
|
|
1916
1912
|
n
|
|
1917
|
-
) : new
|
|
1913
|
+
) : new me(`Failed to parse ${e} file`);
|
|
1918
1914
|
}
|
|
1919
1915
|
}
|
|
1920
1916
|
}
|
|
1921
1917
|
export {
|
|
1922
|
-
|
|
1918
|
+
ln as AssetLoader
|
|
1923
1919
|
};
|
|
1924
|
-
//# sourceMappingURL=AssetLoader.mjs.map
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { Matrix4, OrthographicCamera } from 'three';
|
|
2
|
+
import { DIVERenderPipeline } from '../../engine/renderer/Renderer.ts';
|
|
3
|
+
import { DIVETicker } from '../../engine/clock/Clock.ts';
|
|
4
|
+
import { DIVEScene } from '../../engine/scene/Scene.ts';
|
|
5
|
+
import { DIVEPerspectiveCamera } from '../../engine/camera/PerspectiveCamera.ts';
|
|
6
|
+
/**
|
|
7
|
+
* Shows the scene axes in the bottom left corner of the screen.
|
|
8
|
+
*
|
|
9
|
+
* @module
|
|
10
|
+
*/
|
|
11
|
+
export declare class DIVEAxisCamera extends OrthographicCamera implements DIVETicker {
|
|
12
|
+
private axesHelper;
|
|
13
|
+
private _renderer;
|
|
14
|
+
private _scene;
|
|
15
|
+
private _camera;
|
|
16
|
+
private _restoreViewport;
|
|
17
|
+
constructor(renderer: DIVERenderPipeline, scene: DIVEScene, camera: DIVEPerspectiveCamera);
|
|
18
|
+
tick(): void;
|
|
19
|
+
Dispose(): void;
|
|
20
|
+
SetFromCameraMatrix(matrix: Matrix4): void;
|
|
21
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { OrbitControls } from 'three/examples/jsm/controls/OrbitControls.js';
|
|
2
|
+
import { DIVEPerspectiveCamera } from '../../../engine/camera/PerspectiveCamera.ts';
|
|
3
|
+
import { Box3, Vector3Like } from 'three';
|
|
4
|
+
import { DIVETicker } from '../../../engine/clock/Clock.ts';
|
|
5
|
+
export type OrbitControllerSettings = {
|
|
6
|
+
/** Whether to enable damping for smooth camera movement */
|
|
7
|
+
enableDamping: boolean;
|
|
8
|
+
/** Damping factor for camera movement */
|
|
9
|
+
dampingFactor: number;
|
|
10
|
+
};
|
|
11
|
+
export declare const OrbitControllerDefaultSettings: Required<OrbitControllerSettings>;
|
|
12
|
+
/**
|
|
13
|
+
* Orbit Controls. Basic functionality to orbit around a given target point in the scene.
|
|
14
|
+
*
|
|
15
|
+
* @module
|
|
16
|
+
*/
|
|
17
|
+
export declare class OrbitController extends OrbitControls implements DIVETicker {
|
|
18
|
+
domElement: HTMLCanvasElement;
|
|
19
|
+
static readonly DEFAULT_ZOOM_FACTOR = 1;
|
|
20
|
+
uuid: string;
|
|
21
|
+
object: DIVEPerspectiveCamera;
|
|
22
|
+
constructor(camera: DIVEPerspectiveCamera, domElement: HTMLCanvasElement, settings?: Partial<OrbitControllerSettings>);
|
|
23
|
+
tick(): void;
|
|
24
|
+
computeEncompassingView(bb: Box3): {
|
|
25
|
+
position: Vector3Like;
|
|
26
|
+
target: Vector3Like;
|
|
27
|
+
};
|
|
28
|
+
zoomIn(by?: number): void;
|
|
29
|
+
zoomOut(by?: number): void;
|
|
30
|
+
}
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
"use strict";var _=Object.defineProperty;var d=(t,e,r)=>e in t?_(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r;var n=(t,e,r)=>d(t,typeof e!="symbol"?e+"":e,r);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("../../../chunks/PerspectiveCamera-
|
|
2
|
-
//# sourceMappingURL=MediaCreator.cjs.map
|
|
1
|
+
"use strict";var _=Object.defineProperty;var d=(t,e,r)=>e in t?_(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r;var n=(t,e,r)=>d(t,typeof e!="symbol"?e+"":e,r);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("../../../chunks/PerspectiveCamera-BByyG5R4.cjs");class h{constructor(e,r,o){n(this,"_renderer");n(this,"_scene");n(this,"_controller");this._renderer=e,this._scene=r,this._controller=o}GenerateMedia(e,r,o,s){const c=this._controller.object.position.clone(),l=this._controller.object.quaternion.clone();this._renderer.onResize(o,s),this._controller.object.onResize(o,s),this._controller.object.position.copy(e),this._controller.target.copy(r),this._controller.update();const a=this.DrawCanvas().toDataURL();return this._controller.object.position.copy(c),this._controller.object.quaternion.copy(l),a}DrawCanvas(e){const r=this._renderer.webglrenderer.domElement;e&&(this._renderer.webglrenderer.domElement=e),this._controller.object.layers.mask=i.DIVEPerspectiveCamera.LIVE_VIEW_LAYER_MASK,this._renderer.webglrenderer.render(this._scene,this._controller.object),this._controller.object.layers.mask=i.DIVEPerspectiveCamera.EDITOR_VIEW_LAYER_MASK;const o=this._renderer.webglrenderer.domElement;return e&&(this._renderer.webglrenderer.domElement=r),o}}exports.MediaCreator=h;
|