@realsee/dnalogel 0.1.7-alpha.8 → 2.0.0-alpha.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -89
- package/dist/dnalogel.cjs.js +2 -0
- package/dist/dnalogel.es.js +37145 -0
- package/dist/dnalogel.umd.js +2 -0
- package/dist/style.css +1 -0
- package/{plugins → libs}/CSS3DRenderPlugin/index.d.ts +1 -1
- package/libs/CSS3DRenderPlugin/index.js +181 -0
- package/{plugins → libs}/CSS3DRenderPlugin/utils/createResizeObserver.d.ts +0 -0
- package/libs/CSS3DRenderPlugin/utils/createResizeObserver.js +18 -0
- package/{plugins → libs}/CameraMovementPlugin/index.d.ts +0 -0
- package/libs/CameraMovementPlugin/index.js +159 -0
- package/{plugins → libs}/CameraMovementPlugin/typing.d.ts +0 -0
- package/libs/CameraMovementPlugin/typing.js +17 -0
- package/{plugins → libs}/ModelChassisCompassPlugin/index.d.ts +0 -0
- package/libs/ModelChassisCompassPlugin/index.js +75 -0
- package/{plugins → libs}/ModelEntryDoorGuidePlugin/index.d.ts +2 -2
- package/libs/ModelEntryDoorGuidePlugin/index.js +136 -0
- package/libs/ModelRoomLabelPlugin/Assets/roomLabelBg.d.ts +1 -0
- package/libs/ModelRoomLabelPlugin/Assets/roomLabelBg.js +1 -0
- package/{plugins → libs}/ModelRoomLabelPlugin/Controller.d.ts +3 -2
- package/libs/ModelRoomLabelPlugin/Controller.js +100 -0
- package/libs/ModelRoomLabelPlugin/RoomLabelItem.svelte +63 -0
- package/libs/ModelRoomLabelPlugin/RoomLabelItem.svelte.map +1 -0
- package/libs/ModelRoomLabelPlugin/RoomLabelItems.svelte +80 -0
- package/libs/ModelRoomLabelPlugin/RoomLabelItems.svelte.map +1 -0
- package/{plugins → libs}/ModelRoomLabelPlugin/index.d.ts +4 -4
- package/libs/ModelRoomLabelPlugin/index.js +9 -0
- package/{plugins → libs}/ModelRoomLabelPlugin/typings.d.ts +2 -2
- package/libs/ModelRoomLabelPlugin/typings.js +1 -0
- package/{plugins → libs}/ModelRoomLabelPlugin/utils/parseData.d.ts +0 -0
- package/libs/ModelRoomLabelPlugin/utils/parseData.js +14 -0
- package/{plugins → libs}/ModelViewPlugin/index.d.ts +0 -0
- package/libs/ModelViewPlugin/index.js +160 -0
- package/{plugins → libs}/PanoCursorRaycasterPlugin/index.d.ts +2 -3
- package/libs/PanoCursorRaycasterPlugin/index.js +74 -0
- package/libs/floorplan/Assets/camera.d.ts +1 -0
- package/libs/floorplan/Assets/camera.js +1 -0
- package/{plugins → libs}/floorplan/Assets/floorplanExtraObject.d.ts +0 -0
- package/libs/floorplan/Assets/floorplanExtraObject.js +1 -0
- package/libs/floorplan/Components/BaseImage.svelte +25 -0
- package/libs/floorplan/Components/BaseImage.svelte.map +1 -0
- package/libs/floorplan/Components/Normalmage.svelte +11 -0
- package/libs/floorplan/Components/Normalmage.svelte.map +1 -0
- package/libs/floorplan/Components/RoomHighlight/Room.svelte +21 -0
- package/libs/floorplan/Components/RoomHighlight/Room.svelte.map +1 -0
- package/libs/floorplan/Components/RoomHighlight/RoomHighlight.svelte +60 -0
- package/libs/floorplan/Components/RoomHighlight/RoomHighlight.svelte.map +1 -0
- package/libs/floorplan/Components/RoomMaterials/RoomMaterial.svelte +35 -0
- package/libs/floorplan/Components/RoomMaterials/RoomMaterial.svelte.map +1 -0
- package/libs/floorplan/Components/RoomMaterials/RoomMaterial_0.svelte +7 -0
- package/libs/floorplan/Components/RoomMaterials/RoomMaterial_0.svelte.map +1 -0
- package/libs/floorplan/Components/RoomMaterials/RoomMaterial_1.svelte +16 -0
- package/libs/floorplan/Components/RoomMaterials/RoomMaterial_1.svelte.map +1 -0
- package/libs/floorplan/Components/RoomMaterials/RoomMaterial_2.svelte +17 -0
- package/libs/floorplan/Components/RoomMaterials/RoomMaterial_2.svelte.map +1 -0
- package/libs/floorplan/Components/SvgImage.svelte +25 -0
- package/libs/floorplan/Components/SvgImage.svelte.map +1 -0
- package/libs/floorplan/ModelFloorplanPlugin/Assets/compass.d.ts +1 -0
- package/libs/floorplan/ModelFloorplanPlugin/Assets/compass.js +1 -0
- package/libs/floorplan/ModelFloorplanPlugin/Components/Camera.svelte +46 -0
- package/libs/floorplan/ModelFloorplanPlugin/Components/Camera.svelte.map +1 -0
- package/libs/floorplan/ModelFloorplanPlugin/Components/Compass.svelte +48 -0
- package/libs/floorplan/ModelFloorplanPlugin/Components/Compass.svelte.map +1 -0
- package/libs/floorplan/ModelFloorplanPlugin/Components/CurrentFloor/CurrentFloor.svelte +37 -0
- package/libs/floorplan/ModelFloorplanPlugin/Components/CurrentFloor/CurrentFloor.svelte.map +1 -0
- package/libs/floorplan/ModelFloorplanPlugin/Components/Main.svelte +50 -0
- package/libs/floorplan/ModelFloorplanPlugin/Components/Main.svelte.map +1 -0
- package/libs/floorplan/ModelFloorplanPlugin/Components/RoomLabels/RoomLabel.svelte +41 -0
- package/libs/floorplan/ModelFloorplanPlugin/Components/RoomLabels/RoomLabel.svelte.map +1 -0
- package/libs/floorplan/ModelFloorplanPlugin/Components/RoomLabels/RoomLabels.svelte +25 -0
- package/libs/floorplan/ModelFloorplanPlugin/Components/RoomLabels/RoomLabels.svelte.map +1 -0
- package/libs/floorplan/ModelFloorplanPlugin/Components/RuleLabels/RuleItem.svelte +148 -0
- package/libs/floorplan/ModelFloorplanPlugin/Components/RuleLabels/RuleItem.svelte.map +1 -0
- package/libs/floorplan/ModelFloorplanPlugin/Components/RuleLabels/RuleLabels.svelte +15 -0
- package/libs/floorplan/ModelFloorplanPlugin/Components/RuleLabels/RuleLabels.svelte.map +1 -0
- package/{plugins → libs}/floorplan/ModelFloorplanPlugin/Controller.d.ts +11 -12
- package/libs/floorplan/ModelFloorplanPlugin/Controller.js +357 -0
- package/{plugins → libs}/floorplan/ModelFloorplanPlugin/index.d.ts +1 -1
- package/libs/floorplan/ModelFloorplanPlugin/index.js +5 -0
- package/{plugins → libs}/floorplan/ModelFloorplanPlugin/typings/events.type.d.ts +0 -0
- package/libs/floorplan/ModelFloorplanPlugin/typings/events.type.js +1 -0
- package/{plugins → libs}/floorplan/ModelFloorplanPlugin/utils/constant.d.ts +0 -0
- package/libs/floorplan/ModelFloorplanPlugin/utils/constant.js +16 -0
- package/{plugins → libs}/floorplan/ModelFloorplanPlugin/utils/correctFiveState.d.ts +0 -0
- package/libs/floorplan/ModelFloorplanPlugin/utils/correctFiveState.js +46 -0
- package/libs/floorplan/PanoFloorplanRadarPlugin/Components/Camera.svelte +84 -0
- package/libs/floorplan/PanoFloorplanRadarPlugin/Components/Camera.svelte.map +1 -0
- package/libs/floorplan/PanoFloorplanRadarPlugin/Components/CurrentFloor/CurrentFloor.svelte +18 -0
- package/libs/floorplan/PanoFloorplanRadarPlugin/Components/CurrentFloor/CurrentFloor.svelte.map +1 -0
- package/libs/floorplan/PanoFloorplanRadarPlugin/Components/CurrentFloor/ExtraObjects.svelte +40 -0
- package/libs/floorplan/PanoFloorplanRadarPlugin/Components/CurrentFloor/ExtraObjects.svelte.map +1 -0
- package/libs/floorplan/PanoFloorplanRadarPlugin/Components/Main.svelte +61 -0
- package/libs/floorplan/PanoFloorplanRadarPlugin/Components/Main.svelte.map +1 -0
- package/{plugins → libs}/floorplan/PanoFloorplanRadarPlugin/Controller.d.ts +5 -10
- package/libs/floorplan/PanoFloorplanRadarPlugin/Controller.js +88 -0
- package/{plugins → libs}/floorplan/PanoFloorplanRadarPlugin/index.d.ts +0 -0
- package/libs/floorplan/PanoFloorplanRadarPlugin/index.js +5 -0
- package/{plugins → libs}/floorplan/TopviewFloorplanPlugin/Controller.d.ts +13 -12
- package/libs/floorplan/TopviewFloorplanPlugin/Controller.js +189 -0
- package/{plugins → libs}/floorplan/TopviewFloorplanPlugin/index.d.ts +0 -0
- package/libs/floorplan/TopviewFloorplanPlugin/index.js +5 -0
- package/{plugins → libs}/floorplan/TopviewFloorplanPlugin/style.d.ts +0 -0
- package/libs/floorplan/TopviewFloorplanPlugin/style.js +8 -0
- package/{plugins → libs}/floorplan/typings/floorplanData.d.ts +6 -2
- package/libs/floorplan/typings/floorplanData.js +6 -0
- package/{plugins → libs}/floorplan/typings/floorplanServerData.d.ts +1 -1
- package/libs/floorplan/typings/floorplanServerData.js +101 -0
- package/{plugins/floorplan/ModelFloorplanPlugin → libs/floorplan}/typings/utility.d.ts +0 -0
- package/libs/floorplan/typings/utility.js +1 -0
- package/{plugins → libs}/floorplan/utils/formatData.d.ts +3 -3
- package/libs/floorplan/utils/formatData.js +94 -0
- package/{plugins → libs}/floorplan/utils/formatPosition.d.ts +3 -4
- package/libs/floorplan/utils/formatPosition.js +50 -0
- package/libs/index.d.ts +17 -0
- package/libs/index.js +10 -0
- package/{shared-utils → libs/shared-utils}/Preloader.d.ts +0 -0
- package/libs/shared-utils/Preloader.js +38 -0
- package/{shared-utils → libs/shared-utils}/Subscribe.d.ts +3 -3
- package/libs/shared-utils/Subscribe.js +101 -0
- package/{shared-utils → libs/shared-utils}/animationFrame/BetterTween.d.ts +0 -0
- package/libs/shared-utils/animationFrame/BetterTween.js +30 -0
- package/{shared-utils → libs/shared-utils}/animationFrame/calculateProgress.d.ts +0 -0
- package/libs/shared-utils/animationFrame/calculateProgress.js +23 -0
- package/{shared-utils → libs/shared-utils}/animationFrame/formatRad.d.ts +0 -0
- package/libs/shared-utils/animationFrame/formatRad.js +20 -0
- package/{shared-utils → libs/shared-utils}/animationFrame/index.d.ts +0 -0
- package/libs/shared-utils/animationFrame/index.js +48 -0
- package/{shared-utils → libs/shared-utils}/animationFrame/tween.d.ts +0 -0
- package/libs/shared-utils/animationFrame/tween.js +44 -0
- package/{shared-utils → libs/shared-utils}/changeModelCanvasOpacity.d.ts +0 -0
- package/libs/shared-utils/changeModelCanvasOpacity.js +15 -0
- package/{shared-utils → libs/shared-utils}/createCanvasTextTexture.d.ts +0 -0
- package/libs/shared-utils/createCanvasTextTexture.js +19 -0
- package/{shared-utils → libs/shared-utils}/createLine/index.d.ts +1 -1
- package/libs/shared-utils/createLine/index.js +8 -0
- package/{shared-utils → libs/shared-utils}/debounce.d.ts +1 -1
- package/libs/shared-utils/debounce.js +14 -0
- package/{shared-utils → libs/shared-utils}/equal.d.ts +0 -0
- package/libs/shared-utils/equal.js +84 -0
- package/{shared-utils → libs/shared-utils}/filter.d.ts +0 -0
- package/libs/shared-utils/filter.js +53 -0
- package/{shared-utils → libs/shared-utils}/five/changeMode.d.ts +0 -0
- package/libs/shared-utils/five/changeMode.js +15 -0
- package/{shared-utils → libs/shared-utils}/five/useFivePlugin.d.ts +0 -0
- package/libs/shared-utils/five/useFivePlugin.js +8 -0
- package/{shared-utils → libs/shared-utils}/formatRad.d.ts +0 -0
- package/libs/shared-utils/formatRad.js +10 -0
- package/{shared-utils → libs/shared-utils}/getPxmm.d.ts +0 -0
- package/libs/shared-utils/getPxmm.js +20 -0
- package/{shared-utils → libs/shared-utils}/getRandomColor.d.ts +0 -0
- package/libs/shared-utils/getRandomColor.js +10 -0
- package/{shared-utils → libs/shared-utils}/isNil.d.ts +0 -0
- package/libs/shared-utils/isNil.js +14 -0
- package/{shared-utils → libs/shared-utils}/isTruelyObject.d.ts +0 -0
- package/libs/shared-utils/isTruelyObject.js +20 -0
- package/{shared-utils → libs/shared-utils}/math/evenNumber.d.ts +0 -0
- package/libs/shared-utils/math/evenNumber.js +4 -0
- package/{shared-utils → libs/shared-utils}/math/planimetry.d.ts +4 -4
- package/libs/shared-utils/math/planimetry.js +288 -0
- package/{shared-utils → libs/shared-utils}/math/rad2Deg.d.ts +0 -0
- package/libs/shared-utils/math/rad2Deg.js +3 -0
- package/{shared-utils → libs/shared-utils}/nearlyEqual.d.ts +0 -0
- package/libs/shared-utils/nearlyEqual.js +9 -0
- package/{shared-utils → libs/shared-utils}/nextFrame.d.ts +0 -0
- package/libs/shared-utils/nextFrame.js +6 -0
- package/{shared-utils → libs/shared-utils}/noop.d.ts +0 -0
- package/libs/shared-utils/noop.js +7 -0
- package/{shared-utils → libs/shared-utils}/object3d2LocalMatrix.d.ts +0 -0
- package/libs/shared-utils/object3d2LocalMatrix.js +29 -0
- package/{shared-utils → libs/shared-utils}/px2rem.d.ts +0 -0
- package/libs/shared-utils/px2rem.js +4 -0
- package/{shared-utils → libs/shared-utils}/removeArrayItem.d.ts +1 -1
- package/libs/shared-utils/removeArrayItem.js +12 -0
- package/{shared-utils → libs/shared-utils}/tap.d.ts +0 -0
- package/{shared-utils → libs/shared-utils}/tap.js +4 -13
- package/{shared-utils → libs/shared-utils}/three/centerPoint.d.ts +0 -0
- package/libs/shared-utils/three/centerPoint.js +4 -0
- package/{shared-utils → libs/shared-utils}/three/getExtraModelLoader.d.ts +0 -0
- package/libs/shared-utils/three/getExtraModelLoader.js +18 -0
- package/{shared-utils → libs/shared-utils}/three/getNormal.d.ts +0 -0
- package/libs/shared-utils/three/getNormal.js +6 -0
- package/{shared-utils → libs/shared-utils}/three/getTextureLoader.d.ts +0 -0
- package/libs/shared-utils/three/getTextureLoader.js +17 -0
- package/{shared-utils → libs/shared-utils}/three/loadFbxObj.d.ts +0 -0
- package/libs/shared-utils/three/loadFbxObj.js +13 -0
- package/{shared-utils → libs/shared-utils}/three/loadTexture.d.ts +0 -0
- package/libs/shared-utils/three/loadTexture.js +10 -0
- package/{shared-utils → libs/shared-utils}/three/transformPositionToVector3.d.ts +0 -0
- package/libs/shared-utils/three/transformPositionToVector3.js +3 -0
- package/{shared-utils → libs/shared-utils}/three/transfromToMeshBasicMaterial.d.ts +0 -0
- package/libs/shared-utils/three/transfromToMeshBasicMaterial.js +14 -0
- package/{shared-utils → libs/shared-utils}/throttle.d.ts +1 -1
- package/libs/shared-utils/throttle.js +18 -0
- package/{shared-utils → libs/shared-utils}/to.d.ts +0 -0
- package/libs/shared-utils/to.js +18 -0
- package/{shared-utils → libs/shared-utils}/useDebounce.d.ts +0 -0
- package/libs/shared-utils/useDebounce.js +22 -0
- package/{shared-utils → libs/shared-utils}/useThrottle.d.ts +0 -0
- package/libs/shared-utils/useThrottle.js +25 -0
- package/libs/{gltf-viewer → shared-utils}/uuid.d.ts +0 -0
- package/libs/shared-utils/uuid.js +11 -0
- package/{shared-utils → libs/shared-utils}/vectorTocoordinates.d.ts +0 -0
- package/libs/shared-utils/vectorTocoordinates.js +9 -0
- package/{typings → libs/typings}/math.type.d.ts +0 -0
- package/libs/typings/math.type.js +1 -0
- package/{typings → libs/typings}/utils.type.d.ts +0 -0
- package/libs/typings/utils.type.js +1 -0
- package/package.json +45 -17
- package/TERMS.txt +0 -56
- package/components/ARVideoFigure/ARVideoFigureMesh.d.ts +0 -44
- package/components/ARVideoFigure/ARVideoFigureMesh.js +0 -371
- package/components/ARVideoFigure/ARVideoFigureScene.d.ts +0 -11
- package/components/ARVideoFigure/ARVideoFigureScene.js +0 -85
- package/components/ARVideoFigure/ImgBgTransparent.d.ts +0 -16
- package/components/ARVideoFigure/ImgBgTransparent.js +0 -65
- package/components/ARVideoFigure/ImgBgTransparentMesh.d.ts +0 -30
- package/components/ARVideoFigure/ImgBgTransparentMesh.js +0 -183
- package/components/ARVideoFigure/fragmentShader.d.ts +0 -5
- package/components/ARVideoFigure/fragmentShader.js +0 -18
- package/components/ARVideoFigure/index.d.ts +0 -15
- package/components/ARVideoFigure/index.js +0 -80
- package/components/ARVideoFigure/vertexShader.d.ts +0 -1
- package/components/ARVideoFigure/vertexShader.js +0 -10
- package/components/GLTFView/index.d.ts +0 -110
- package/components/GLTFView/index.js +0 -187
- package/components/GlassFilters/index.d.ts +0 -32
- package/components/GlassFilters/index.js +0 -78
- package/components/ModelView/ModelViewController.d.ts +0 -18
- package/components/ModelView/ModelViewController.js +0 -157
- package/components/ModelView/index.d.ts +0 -10
- package/components/ModelView/index.js +0 -24
- package/components/PaintBrush/index.d.ts +0 -16
- package/components/PaintBrush/index.js +0 -47
- package/components/PanoTag/index.d.ts +0 -4
- package/components/PanoTag/index.js +0 -13
- package/custom.d.js +0 -3
- package/data/1aGKl9JmrlXMXx8d.d.ts +0 -104
- package/data/1aGKl9JmrlXMXx8d.js +0 -537
- package/data/54djM0oR6ky3Ey8e.d.ts +0 -55
- package/data/54djM0oR6ky3Ey8e.js +0 -350
- package/data/6gyq3v1verxD7JO1.d.ts +0 -104
- package/data/6gyq3v1verxD7JO1.js +0 -462
- package/data/8054djM0oR6ky3Ey8e.d.ts +0 -55
- package/data/8054djM0oR6ky3Ey8e.js +0 -350
- package/data/81zxMaeVKLQU93OZMG.d.ts +0 -49
- package/data/81zxMaeVKLQU93OZMG.js +0 -633
- package/data/KpokNd82rwjhackhQTBEoYKHg8zGbPXe.d.ts +0 -84
- package/data/KpokNd82rwjhackhQTBEoYKHg8zGbPXe.js +0 -600
- package/data/PrXel3aqGbp34JQn.d.ts +0 -389
- package/data/PrXel3aqGbp34JQn.js +0 -4787
- package/data/XJ6NMLWnkAY3Rdx8.d.ts +0 -843
- package/data/XJ6NMLWnkAY3Rdx8.js +0 -7989
- package/data/YdoNP9K4rwQDwjJr.d.ts +0 -83
- package/data/YdoNP9K4rwQDwjJr.js +0 -1453
- package/data/ZLvK29zj4L29Jowd.d.ts +0 -55
- package/data/ZLvK29zj4L29Jowd.js +0 -372
- package/data/_vLykj3NWrllMrG06.d.ts +0 -95
- package/data/_vLykj3NWrllMrG06.js +0 -1
- package/data/auto3d-njL5J99VwCmnjtQElOmXQr.d.ts +0 -86
- package/data/auto3d-njL5J99VwCmnjtQElOmXQr.js +0 -711
- package/data/extrude-walls/ZLvK29zj4L29Jowd.d.ts +0 -5
- package/data/extrude-walls/ZLvK29zj4L29Jowd.js +0 -14
- package/data/extrude-walls/lo024DEgzanMj5BE.d.ts +0 -5
- package/data/extrude-walls/lo024DEgzanMj5BE.js +0 -14
- package/data/jd6oMOzPxnQ3BvxY_B7yw51J9rXlhYhjhGTOgRVqu6WeEqjNX.d.ts +0 -85
- package/data/jd6oMOzPxnQ3BvxY_B7yw51J9rXlhYhjhGTOgRVqu6WeEqjNX.js +0 -511
- package/data/lo024DEgzanMj5BE.d.ts +0 -55
- package/data/lo024DEgzanMj5BE.js +0 -966
- package/data/oPzy3ApbjjpD8YdR.d.ts +0 -83
- package/data/oPzy3ApbjjpD8YdR.js +0 -283
- package/data/qjAxMG4XbPn96wKG.d.ts +0 -104
- package/data/qjAxMG4XbPn96wKG.js +0 -637
- package/data/rXel3aPQRRBD4JQn.d.ts +0 -86
- package/data/rXel3aPQRRBD4JQn.js +0 -622
- package/data/vLykj3NWrllMrG06.d.ts +0 -91
- package/data/vLykj3NWrllMrG06.js +0 -2993
- package/data/wz0QV9KA4ugyo9ME.d.ts +0 -39
- package/data/wz0QV9KA4ugyo9ME.js +0 -136
- package/data/zxMawr9raSg8LYjG.d.ts +0 -53
- package/data/zxMawr9raSg8LYjG.js +0 -590
- package/examples/FiveStateController/index.js +0 -134
- package/examples/VRHouse/Mobile.js +0 -36
- package/examples/VRHouse/PC.js +0 -36
- package/examples/VRHouse/index.js +0 -36
- package/index.d.ts +0 -15
- package/index.js +0 -45
- package/libs/gltf-viewer/Subscribe.d.ts +0 -76
- package/libs/gltf-viewer/Subscribe.js +0 -231
- package/libs/gltf-viewer/coordsMoveByOffset.d.ts +0 -13
- package/libs/gltf-viewer/coordsMoveByOffset.js +0 -22
- package/libs/gltf-viewer/coordsToDirection.d.ts +0 -5
- package/libs/gltf-viewer/coordsToDirection.js +0 -41
- package/libs/gltf-viewer/formatRad.d.ts +0 -1
- package/libs/gltf-viewer/formatRad.js +0 -13
- package/libs/gltf-viewer/getFrameTime.d.ts +0 -1
- package/libs/gltf-viewer/getFrameTime.js +0 -28
- package/libs/gltf-viewer/index.d.ts +0 -78
- package/libs/gltf-viewer/index.js +0 -763
- package/libs/gltf-viewer/mouseWheel.d.ts +0 -2
- package/libs/gltf-viewer/mouseWheel.js +0 -59
- package/libs/gltf-viewer/requestAnimationFrame.d.ts +0 -1
- package/libs/gltf-viewer/requestAnimationFrame.js +0 -18
- package/libs/gltf-viewer/requestAnimationFrameInterval.d.ts +0 -1
- package/libs/gltf-viewer/requestAnimationFrameInterval.js +0 -31
- package/libs/gltf-viewer/uuid.js +0 -28
- package/plugins/AutoPreloadPlugin/index.d.ts +0 -23
- package/plugins/AutoPreloadPlugin/index.js +0 -111
- package/plugins/CSS3DRenderPlugin/components/Marker/index.d.ts +0 -12
- package/plugins/CSS3DRenderPlugin/components/Marker/index.js +0 -121
- package/plugins/CSS3DRenderPlugin/index.js +0 -303
- package/plugins/CSS3DRenderPlugin/utils/createResizeObserver.js +0 -34
- package/plugins/CameraMovementPlugin/index.js +0 -362
- package/plugins/CameraMovementPlugin/typing.js +0 -37
- package/plugins/ModelChassisCompassPlugin/index.js +0 -158
- package/plugins/ModelEntryDoorGuidePlugin/index.js +0 -252
- package/plugins/ModelExtrudeWallsPlugin/index.d.ts +0 -16
- package/plugins/ModelExtrudeWallsPlugin/index.js +0 -252
- package/plugins/ModelRoomLabelPlugin/Controller.js +0 -154
- package/plugins/ModelRoomLabelPlugin/RoomLabelItem.d.ts +0 -8
- package/plugins/ModelRoomLabelPlugin/RoomLabelItem.js +0 -66
- package/plugins/ModelRoomLabelPlugin/RoomLabelItems.d.ts +0 -7
- package/plugins/ModelRoomLabelPlugin/RoomLabelItems.js +0 -159
- package/plugins/ModelRoomLabelPlugin/index.js +0 -23
- package/plugins/ModelRoomLabelPlugin/typings.js +0 -7
- package/plugins/ModelRoomLabelPlugin/utils/parseData.js +0 -35
- package/plugins/ModelTVVideoPlugin/index.d.ts +0 -21
- package/plugins/ModelTVVideoPlugin/index.js +0 -397
- package/plugins/ModelViewPlugin/index.js +0 -223
- package/plugins/PanoCursorRaycasterPlugin/PanoCursorRaycasterPluginUsage.d.ts +0 -48
- package/plugins/PanoCursorRaycasterPlugin/components/MovePointTowardsCamera.d.ts +0 -9
- package/plugins/PanoCursorRaycasterPlugin/components/MovePointTowardsCamera.js +0 -117
- package/plugins/PanoCursorRaycasterPlugin/components/PointAxesHelper.d.ts +0 -11
- package/plugins/PanoCursorRaycasterPlugin/components/PointAxesHelper.js +0 -39
- package/plugins/PanoCursorRaycasterPlugin/index.js +0 -126
- package/plugins/PanoCursorRaycasterPlugin/utils/addLineToFive.d.ts +0 -5
- package/plugins/PanoCursorRaycasterPlugin/utils/addLineToFive.js +0 -27
- package/plugins/PanoCursorRaycasterPlugin/utils/createLine.d.ts +0 -3
- package/plugins/PanoCursorRaycasterPlugin/utils/createLine.js +0 -48
- package/plugins/PanoDoorLabelPlugin/index.d.ts +0 -4
- package/plugins/PanoDoorLabelPlugin/index.js +0 -14
- package/plugins/PanoIRobotPlugin/index.d.ts +0 -10
- package/plugins/PanoIRobotPlugin/index.js +0 -18
- package/plugins/PanoMaskSelectorPlugin/compare.d.ts +0 -1
- package/plugins/PanoMaskSelectorPlugin/compare.js +0 -17
- package/plugins/PanoMaskSelectorPlugin/createBox.d.ts +0 -7
- package/plugins/PanoMaskSelectorPlugin/createBox.js +0 -82
- package/plugins/PanoMaskSelectorPlugin/createTextures.d.ts +0 -3
- package/plugins/PanoMaskSelectorPlugin/createTextures.js +0 -45
- package/plugins/PanoMaskSelectorPlugin/fragmentShader.d.ts +0 -1
- package/plugins/PanoMaskSelectorPlugin/fragmentShader.js +0 -10
- package/plugins/PanoMaskSelectorPlugin/index.d.ts +0 -49
- package/plugins/PanoMaskSelectorPlugin/index.js +0 -350
- package/plugins/PanoMaskSelectorPlugin/vertexShader.d.ts +0 -1
- package/plugins/PanoMaskSelectorPlugin/vertexShader.js +0 -10
- package/plugins/PanoMeasurePlugin/Controller/BaseController.d.ts +0 -36
- package/plugins/PanoMeasurePlugin/Controller/BaseController.js +0 -103
- package/plugins/PanoMeasurePlugin/Controller/EditController.d.ts +0 -52
- package/plugins/PanoMeasurePlugin/Controller/EditController.js +0 -341
- package/plugins/PanoMeasurePlugin/Controller/ShortcutKeyController.d.ts +0 -12
- package/plugins/PanoMeasurePlugin/Controller/ShortcutKeyController.js +0 -69
- package/plugins/PanoMeasurePlugin/Controller/WatchController.d.ts +0 -25
- package/plugins/PanoMeasurePlugin/Controller/WatchController.js +0 -371
- package/plugins/PanoMeasurePlugin/Controller/index.d.ts +0 -61
- package/plugins/PanoMeasurePlugin/Controller/index.js +0 -230
- package/plugins/PanoMeasurePlugin/Model/index.d.ts +0 -38
- package/plugins/PanoMeasurePlugin/Model/index.js +0 -235
- package/plugins/PanoMeasurePlugin/Model/line.d.ts +0 -30
- package/plugins/PanoMeasurePlugin/Model/line.js +0 -121
- package/plugins/PanoMeasurePlugin/Model/point.d.ts +0 -16
- package/plugins/PanoMeasurePlugin/Model/point.js +0 -68
- package/plugins/PanoMeasurePlugin/Model/polyline.d.ts +0 -16
- package/plugins/PanoMeasurePlugin/Model/polyline.js +0 -109
- package/plugins/PanoMeasurePlugin/Modules/DeleteDom/_Assets/delete.svg.d.ts +0 -2
- package/plugins/PanoMeasurePlugin/Modules/DeleteDom/_Assets/delete.svg.js +0 -11
- package/plugins/PanoMeasurePlugin/Modules/DeleteDom/_Assets/delete_bg.png.d.ts +0 -2
- package/plugins/PanoMeasurePlugin/Modules/DeleteDom/_Assets/delete_bg.png.js +0 -11
- package/plugins/PanoMeasurePlugin/Modules/DeleteDom/_Assets/delete_hover_bg.png.d.ts +0 -2
- package/plugins/PanoMeasurePlugin/Modules/DeleteDom/_Assets/delete_hover_bg.png.js +0 -11
- package/plugins/PanoMeasurePlugin/Modules/DeleteDom/index.d.ts +0 -22
- package/plugins/PanoMeasurePlugin/Modules/DeleteDom/index.js +0 -182
- package/plugins/PanoMeasurePlugin/Modules/FiveHelper.d.ts +0 -11
- package/plugins/PanoMeasurePlugin/Modules/FiveHelper.js +0 -66
- package/plugins/PanoMeasurePlugin/Modules/GuideController.d.ts +0 -18
- package/plugins/PanoMeasurePlugin/Modules/GuideController.js +0 -107
- package/plugins/PanoMeasurePlugin/Modules/Magnifier.d.ts +0 -24
- package/plugins/PanoMeasurePlugin/Modules/Magnifier.js +0 -139
- package/plugins/PanoMeasurePlugin/Modules/UIController/HTML.d.ts +0 -6
- package/plugins/PanoMeasurePlugin/Modules/UIController/HTML.js +0 -26
- package/plugins/PanoMeasurePlugin/Modules/UIController/MainBtnController.d.ts +0 -18
- package/plugins/PanoMeasurePlugin/Modules/UIController/MainBtnController.js +0 -169
- package/plugins/PanoMeasurePlugin/Modules/UIController/Revoke/index.d.ts +0 -12
- package/plugins/PanoMeasurePlugin/Modules/UIController/Revoke/index.js +0 -59
- package/plugins/PanoMeasurePlugin/Modules/UIController/index.d.ts +0 -16
- package/plugins/PanoMeasurePlugin/Modules/UIController/index.js +0 -123
- package/plugins/PanoMeasurePlugin/Modules/UIController/style.d.ts +0 -17
- package/plugins/PanoMeasurePlugin/Modules/UIController/style.js +0 -103
- package/plugins/PanoMeasurePlugin/index.d.ts +0 -7
- package/plugins/PanoMeasurePlugin/index.js +0 -20
- package/plugins/PanoMeasurePlugin/typings/data.d.ts +0 -28
- package/plugins/PanoMeasurePlugin/typings/data.js +0 -7
- package/plugins/PanoMeasurePlugin/typings/event.type.d.ts +0 -28
- package/plugins/PanoMeasurePlugin/typings/event.type.js +0 -7
- package/plugins/PanoMeasurePlugin/typings/utils.type.d.ts +0 -1
- package/plugins/PanoMeasurePlugin/typings/utils.type.js +0 -7
- package/plugins/PanoMeasurePlugin/utils/clearGroup.d.ts +0 -2
- package/plugins/PanoMeasurePlugin/utils/clearGroup.js +0 -16
- package/plugins/PanoMeasurePlugin/utils/constants.d.ts +0 -4
- package/plugins/PanoMeasurePlugin/utils/constants.js +0 -47
- package/plugins/PanoMeasurePlugin/utils/distanceDom.d.ts +0 -28
- package/plugins/PanoMeasurePlugin/utils/distanceDom.js +0 -147
- package/plugins/PanoMeasurePlugin/utils/findAssociatedLines.d.ts +0 -2
- package/plugins/PanoMeasurePlugin/utils/findAssociatedLines.js +0 -37
- package/plugins/PanoMeasurePlugin/utils/findClosestPoint.d.ts +0 -10
- package/plugins/PanoMeasurePlugin/utils/findClosestPoint.js +0 -49
- package/plugins/PanoMeasurePlugin/utils/getIntersectionFromEvent.d.ts +0 -4
- package/plugins/PanoMeasurePlugin/utils/getIntersectionFromEvent.js +0 -20
- package/plugins/PanoMeasurePlugin/utils/getPointFromHammerEvent.d.ts +0 -10
- package/plugins/PanoMeasurePlugin/utils/getPointFromHammerEvent.js +0 -33
- package/plugins/PanoMeasurePlugin/utils/ironbox.d.ts +0 -1
- package/plugins/PanoMeasurePlugin/utils/ironbox.js +0 -14
- package/plugins/PanoMeasurePlugin/utils/isNDCPointInScreen.d.ts +0 -2
- package/plugins/PanoMeasurePlugin/utils/isNDCPointInScreen.js +0 -16
- package/plugins/PanoMeasurePlugin/utils/line.d.ts +0 -17
- package/plugins/PanoMeasurePlugin/utils/line.js +0 -61
- package/plugins/PanoMeasurePlugin/utils/math.d.ts +0 -17
- package/plugins/PanoMeasurePlugin/utils/math.js +0 -57
- package/plugins/PanoMeasurePlugin/utils/mouseGroup.d.ts +0 -2
- package/plugins/PanoMeasurePlugin/utils/mouseGroup.js +0 -42
- package/plugins/PanoMeasurePlugin/utils/ndc2Screen.d.ts +0 -5
- package/plugins/PanoMeasurePlugin/utils/ndc2Screen.js +0 -16
- package/plugins/PanoRulerPlugin/data/roomInfo.d.ts +0 -3
- package/plugins/PanoRulerPlugin/data/roomInfo.js +0 -51
- package/plugins/PanoRulerPlugin/data/roomRules.d.ts +0 -3
- package/plugins/PanoRulerPlugin/data/roomRules.js +0 -235
- package/plugins/PanoRulerPlugin/index.d.ts +0 -31
- package/plugins/PanoRulerPlugin/index.js +0 -642
- package/plugins/PanoRulerPlugin/typings.d.ts +0 -21
- package/plugins/PanoRulerPlugin/typings.js +0 -7
- package/plugins/PanoTVVideoPlugin/index.d.ts +0 -26
- package/plugins/PanoTVVideoPlugin/index.js +0 -433
- package/plugins/TreasurePlugin/Controller.d.ts +0 -73
- package/plugins/TreasurePlugin/Controller.js +0 -250
- package/plugins/TreasurePlugin/TreasureFaceAnime.d.ts +0 -25
- package/plugins/TreasurePlugin/TreasureFaceAnime.js +0 -143
- package/plugins/TreasurePlugin/TreasureObject.d.ts +0 -53
- package/plugins/TreasurePlugin/TreasureObject.js +0 -406
- package/plugins/TreasurePlugin/TreasureOpenAnime.d.ts +0 -25
- package/plugins/TreasurePlugin/TreasureOpenAnime.js +0 -127
- package/plugins/TreasurePlugin/constants.d.ts +0 -33
- package/plugins/TreasurePlugin/constants.js +0 -67
- package/plugins/TreasurePlugin/index.d.ts +0 -11
- package/plugins/TreasurePlugin/index.js +0 -26
- package/plugins/TreasurePlugin/typings.d.ts +0 -2
- package/plugins/TreasurePlugin/typings.js +0 -7
- package/plugins/floorplan/Assets/floorplanExtraObject.js +0 -10
- package/plugins/floorplan/ModelFloorplanPlugin/Controller.js +0 -637
- package/plugins/floorplan/ModelFloorplanPlugin/components/Camera.d.ts +0 -13
- package/plugins/floorplan/ModelFloorplanPlugin/components/Camera.js +0 -78
- package/plugins/floorplan/ModelFloorplanPlugin/components/Compass.d.ts +0 -5
- package/plugins/floorplan/ModelFloorplanPlugin/components/Compass.js +0 -84
- package/plugins/floorplan/ModelFloorplanPlugin/components/NowFloor/RoomHighlight.d.ts +0 -10
- package/plugins/floorplan/ModelFloorplanPlugin/components/NowFloor/RoomHighlight.js +0 -129
- package/plugins/floorplan/ModelFloorplanPlugin/components/NowFloor/RoomLabels.d.ts +0 -13
- package/plugins/floorplan/ModelFloorplanPlugin/components/NowFloor/RoomLabels.js +0 -118
- package/plugins/floorplan/ModelFloorplanPlugin/components/NowFloor/RoomMaterial.d.ts +0 -11
- package/plugins/floorplan/ModelFloorplanPlugin/components/NowFloor/RoomMaterial.js +0 -174
- package/plugins/floorplan/ModelFloorplanPlugin/components/NowFloor/RuleLabels.d.ts +0 -8
- package/plugins/floorplan/ModelFloorplanPlugin/components/NowFloor/RuleLabels.js +0 -178
- package/plugins/floorplan/ModelFloorplanPlugin/components/NowFloor/index.d.ts +0 -15
- package/plugins/floorplan/ModelFloorplanPlugin/components/NowFloor/index.js +0 -74
- package/plugins/floorplan/ModelFloorplanPlugin/components/index.d.ts +0 -23
- package/plugins/floorplan/ModelFloorplanPlugin/components/index.js +0 -88
- package/plugins/floorplan/ModelFloorplanPlugin/controller.style.d.ts +0 -1
- package/plugins/floorplan/ModelFloorplanPlugin/controller.style.js +0 -16
- package/plugins/floorplan/ModelFloorplanPlugin/index.js +0 -20
- package/plugins/floorplan/ModelFloorplanPlugin/typings/events.type.js +0 -7
- package/plugins/floorplan/ModelFloorplanPlugin/typings/utility.js +0 -7
- package/plugins/floorplan/ModelFloorplanPlugin/utils/constant.js +0 -33
- package/plugins/floorplan/ModelFloorplanPlugin/utils/correctFiveState.js +0 -154
- package/plugins/floorplan/PanoFloorplanRadarPlugin/Content/Camera.d.ts +0 -13
- package/plugins/floorplan/PanoFloorplanRadarPlugin/Content/Camera.js +0 -114
- package/plugins/floorplan/PanoFloorplanRadarPlugin/Content/Camera.style.d.ts +0 -3
- package/plugins/floorplan/PanoFloorplanRadarPlugin/Content/Camera.style.js +0 -39
- package/plugins/floorplan/PanoFloorplanRadarPlugin/Content/NowFloor/ExtraObjects.d.ts +0 -5
- package/plugins/floorplan/PanoFloorplanRadarPlugin/Content/NowFloor/ExtraObjects.js +0 -66
- package/plugins/floorplan/PanoFloorplanRadarPlugin/Content/NowFloor/RoomHighlight.d.ts +0 -9
- package/plugins/floorplan/PanoFloorplanRadarPlugin/Content/NowFloor/RoomHighlight.js +0 -126
- package/plugins/floorplan/PanoFloorplanRadarPlugin/Content/NowFloor/index.d.ts +0 -11
- package/plugins/floorplan/PanoFloorplanRadarPlugin/Content/NowFloor/index.js +0 -58
- package/plugins/floorplan/PanoFloorplanRadarPlugin/Content/index.d.ts +0 -17
- package/plugins/floorplan/PanoFloorplanRadarPlugin/Content/index.js +0 -85
- package/plugins/floorplan/PanoFloorplanRadarPlugin/Content/index.style.d.ts +0 -2
- package/plugins/floorplan/PanoFloorplanRadarPlugin/Content/index.style.js +0 -15
- package/plugins/floorplan/PanoFloorplanRadarPlugin/Controller.js +0 -211
- package/plugins/floorplan/PanoFloorplanRadarPlugin/index.js +0 -20
- package/plugins/floorplan/TopviewFloorplanPlugin/Controller.js +0 -272
- package/plugins/floorplan/TopviewFloorplanPlugin/index.js +0 -18
- package/plugins/floorplan/TopviewFloorplanPlugin/style.js +0 -16
- package/plugins/floorplan/components/FloorplanImage.d.ts +0 -7
- package/plugins/floorplan/components/FloorplanImage.js +0 -90
- package/plugins/floorplan/index.d.ts +0 -4
- package/plugins/floorplan/index.js +0 -13
- package/plugins/floorplan/typings/floorplanData.js +0 -7
- package/plugins/floorplan/typings/floorplanServerData.js +0 -382
- package/plugins/floorplan/utils/formatData.js +0 -218
- package/plugins/floorplan/utils/formatPosition.js +0 -89
- package/shared-utils/Preloader.js +0 -57
- package/shared-utils/Subscribe.js +0 -230
- package/shared-utils/animationFrame/BetterTween.js +0 -103
- package/shared-utils/animationFrame/calculateProgress.js +0 -40
- package/shared-utils/animationFrame/formatRad.js +0 -36
- package/shared-utils/animationFrame/index.js +0 -81
- package/shared-utils/animationFrame/tween.js +0 -92
- package/shared-utils/changeModelCanvasOpacity.js +0 -38
- package/shared-utils/createCanvasTextTexture.js +0 -31
- package/shared-utils/createFiveContainer.d.ts +0 -10
- package/shared-utils/createFiveContainer.js +0 -171
- package/shared-utils/createLine/index.js +0 -43
- package/shared-utils/debounce.js +0 -30
- package/shared-utils/equal.js +0 -107
- package/shared-utils/filter.js +0 -127
- package/shared-utils/five/changeMode.js +0 -82
- package/shared-utils/five/useFivePlugin.js +0 -17
- package/shared-utils/formatRad.js +0 -18
- package/shared-utils/getPxmm.js +0 -51
- package/shared-utils/getRandomColor.js +0 -23
- package/shared-utils/isNil.js +0 -26
- package/shared-utils/isTruelyObject.js +0 -31
- package/shared-utils/math/evenNumber.js +0 -15
- package/shared-utils/math/planimetry.js +0 -352
- package/shared-utils/math/rad2Deg.js +0 -12
- package/shared-utils/nearlyEqual.js +0 -19
- package/shared-utils/nextFrame.js +0 -15
- package/shared-utils/noop.js +0 -19
- package/shared-utils/object3d2LocalMatrix.js +0 -79
- package/shared-utils/px2rem.js +0 -22
- package/shared-utils/removeArrayItem.js +0 -22
- package/shared-utils/three/centerPoint.js +0 -14
- package/shared-utils/three/getExtraModelLoader.js +0 -45
- package/shared-utils/three/getNormal.js +0 -17
- package/shared-utils/three/getTextureLoader.js +0 -50
- package/shared-utils/three/loadFbxObj.js +0 -54
- package/shared-utils/three/loadTexture.js +0 -65
- package/shared-utils/three/transformPositionToVector3.js +0 -20
- package/shared-utils/three/transfromToMeshBasicMaterial.js +0 -33
- package/shared-utils/throttle.js +0 -29
- package/shared-utils/to.js +0 -67
- package/shared-utils/useDebounce.js +0 -49
- package/shared-utils/useThrottle.js +0 -47
- package/shared-utils/uuid.d.ts +0 -4
- package/shared-utils/uuid.js +0 -28
- package/shared-utils/vectorTocoordinates.js +0 -18
- package/typedoc/components.d.ts +0 -6
- package/typedoc/components.js +0 -7
- package/typedoc/libs.d.ts +0 -1
- package/typedoc/libs.js +0 -7
- package/typedoc/plugins.d.ts +0 -19
- package/typedoc/plugins.js +0 -165
- package/typedoc/shared-utils.d.ts +0 -3
- package/typedoc/shared-utils.js +0 -7
- package/typedoc/typings.d.ts +0 -3
- package/typedoc/typings.js +0 -7
- package/typings/math.type.js +0 -7
- package/typings/utils.type.js +0 -7
|
@@ -1,303 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
require("core-js/modules/es.array.iterator.js");
|
|
4
|
-
|
|
5
|
-
require("core-js/modules/es.object.to-string.js");
|
|
6
|
-
|
|
7
|
-
require("core-js/modules/es.string.iterator.js");
|
|
8
|
-
|
|
9
|
-
require("core-js/modules/es.weak-map.js");
|
|
10
|
-
|
|
11
|
-
require("core-js/modules/web.dom-collections.iterator.js");
|
|
12
|
-
|
|
13
|
-
require("core-js/modules/es.object.define-property.js");
|
|
14
|
-
|
|
15
|
-
require("core-js/modules/es.object.get-own-property-descriptor.js");
|
|
16
|
-
|
|
17
|
-
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
18
|
-
|
|
19
|
-
var _typeof = require("@babel/runtime/helpers/typeof");
|
|
20
|
-
|
|
21
|
-
Object.defineProperty(exports, "__esModule", {
|
|
22
|
-
value: true
|
|
23
|
-
});
|
|
24
|
-
exports["default"] = exports.CSS3DRenderPlugin = void 0;
|
|
25
|
-
|
|
26
|
-
require("core-js/modules/es.array.map.js");
|
|
27
|
-
|
|
28
|
-
require("core-js/modules/es.array.for-each.js");
|
|
29
|
-
|
|
30
|
-
require("core-js/modules/es.array.find-index.js");
|
|
31
|
-
|
|
32
|
-
require("core-js/modules/es.array.splice.js");
|
|
33
|
-
|
|
34
|
-
require("core-js/modules/es.string.sub.js");
|
|
35
|
-
|
|
36
|
-
require("core-js/modules/es.function.name.js");
|
|
37
|
-
|
|
38
|
-
require("core-js/modules/web.dom-collections.for-each.js");
|
|
39
|
-
|
|
40
|
-
var THREE = _interopRequireWildcard(require("three"));
|
|
41
|
-
|
|
42
|
-
var _CSS3DRenderer = require("three/examples/jsm/renderers/CSS3DRenderer");
|
|
43
|
-
|
|
44
|
-
var _evenNumber = _interopRequireDefault(require("../../shared-utils/math/evenNumber"));
|
|
45
|
-
|
|
46
|
-
var _centerPoint = _interopRequireDefault(require("../../shared-utils/three/centerPoint"));
|
|
47
|
-
|
|
48
|
-
var _transformPositionToVector = _interopRequireDefault(require("../../shared-utils/three/transformPositionToVector3"));
|
|
49
|
-
|
|
50
|
-
var _createResizeObserver = _interopRequireDefault(require("./utils/createResizeObserver"));
|
|
51
|
-
|
|
52
|
-
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
53
|
-
|
|
54
|
-
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
55
|
-
|
|
56
|
-
/**
|
|
57
|
-
* **CSS3DRenderPlugin** 提供矩形区域(三维空间四个坐标点),你可以在此矩形区域中渲染 DOM 内容。
|
|
58
|
-
* 实现原理参考[CSS3DRenderer](https://threejs.org/docs/index.html?q=CSS3D#examples/en/renderers/CSS3DRenderer)。
|
|
59
|
-
*
|
|
60
|
-
* @returns
|
|
61
|
-
*/
|
|
62
|
-
var CSS3DRenderPlugin = function CSS3DRenderPlugin(five) {
|
|
63
|
-
var state = {
|
|
64
|
-
disposeCallbacks: []
|
|
65
|
-
};
|
|
66
|
-
|
|
67
|
-
var create3DDomContainer = function create3DDomContainer() {
|
|
68
|
-
var _five$model, _five$model2, _config$autoRender;
|
|
69
|
-
|
|
70
|
-
for (var _len = arguments.length, params = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
71
|
-
params[_key] = arguments[_key];
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
var points = params[0].map(function (point) {
|
|
75
|
-
return point instanceof THREE.Vector3 ? point : (0, _transformPositionToVector["default"])(point);
|
|
76
|
-
});
|
|
77
|
-
var config = params[1];
|
|
78
|
-
if ((points === null || points === void 0 ? void 0 : points.length) < 4) return console.error('points must be equal or greater than than 4');
|
|
79
|
-
if (!(five !== null && five !== void 0 && (_five$model = five.model) !== null && _five$model !== void 0 && _five$model.loaded)) return console.error('five.model.loaded is: ', five === null || five === void 0 ? void 0 : (_five$model2 = five.model) === null || _five$model2 === void 0 ? void 0 : _five$model2.loaded);
|
|
80
|
-
var fiveElement = five.getElement();
|
|
81
|
-
if (!fiveElement) return console.error('five.getElement() is ' + fiveElement);
|
|
82
|
-
var disposers = [];
|
|
83
|
-
var ratio = (config === null || config === void 0 ? void 0 : config.ratio) || 0.00216;
|
|
84
|
-
if (ratio <= 0.00215) console.warn('if you need click css3DElement on safari, ratio must be greater than 0.00215');
|
|
85
|
-
var dpr = (config === null || config === void 0 ? void 0 : config.dpr) || 1;
|
|
86
|
-
var mode = (config === null || config === void 0 ? void 0 : config.mode) || 'front';
|
|
87
|
-
var autoRender = (_config$autoRender = config === null || config === void 0 ? void 0 : config.autoRender) !== null && _config$autoRender !== void 0 ? _config$autoRender : true;
|
|
88
|
-
var behindFiveContainer = (config === null || config === void 0 ? void 0 : config.behindFiveContainer) || fiveElement.parentElement || document.body;
|
|
89
|
-
var container = (config === null || config === void 0 ? void 0 : config.container) || document.createElement('div');
|
|
90
|
-
container.classList.add('__Dnalogel-plugin--CSS3DRenderPlugin'); // 获取css3DObject, 如果mode为behind的话,一起获取mesh
|
|
91
|
-
|
|
92
|
-
var _createObject = createObject(points, {
|
|
93
|
-
ratio: ratio,
|
|
94
|
-
dpr: dpr,
|
|
95
|
-
container: container,
|
|
96
|
-
mode: mode
|
|
97
|
-
}),
|
|
98
|
-
css3DObject = _createObject.css3DObject,
|
|
99
|
-
mesh = _createObject.mesh; // ======= INIT START =======
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
var resizeObserver;
|
|
103
|
-
var frontModeUnInited = mode === 'front' && !state.frontMode;
|
|
104
|
-
var behindModeUnInited = mode === 'behind' && !state.behindMode;
|
|
105
|
-
var inited = !(frontModeUnInited || behindModeUnInited);
|
|
106
|
-
var stopRenderFlag = false;
|
|
107
|
-
var requestAnimationFrameId = null;
|
|
108
|
-
|
|
109
|
-
if (behindModeUnInited) {
|
|
110
|
-
state.behindMode = {
|
|
111
|
-
scene: new THREE.Scene(),
|
|
112
|
-
css3DRenderer: new _CSS3DRenderer.CSS3DRenderer()
|
|
113
|
-
};
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
if (frontModeUnInited) {
|
|
117
|
-
state.frontMode = {
|
|
118
|
-
scene: new THREE.Scene(),
|
|
119
|
-
css3DRenderer: new _CSS3DRenderer.CSS3DRenderer()
|
|
120
|
-
};
|
|
121
|
-
}
|
|
122
|
-
|
|
123
|
-
var _ref = mode === 'behind' ? state.behindMode : state.frontMode,
|
|
124
|
-
scene = _ref.scene,
|
|
125
|
-
css3DRenderer = _ref.css3DRenderer;
|
|
126
|
-
|
|
127
|
-
var render = function () {
|
|
128
|
-
if (!inited) {
|
|
129
|
-
var css3DRendererSetSize = function css3DRendererSetSize() {
|
|
130
|
-
// 这里evenNumber策略是遇到奇数会加1,不知道为啥会触发滚动条显示,导致fiveElement变小,fiveElement变小又触发了这里的resize,宽高变小,滚动条消失,然后又触发resize。。。无限循环
|
|
131
|
-
// 为了规避上面这种情况,evenNumber设置了一个参数,遇到奇数可选择减一
|
|
132
|
-
var rendererWidth = (0, _evenNumber["default"])(fiveElement.clientWidth, {
|
|
133
|
-
smaller: true
|
|
134
|
-
});
|
|
135
|
-
var rendererHeight = (0, _evenNumber["default"])(fiveElement.clientHeight, {
|
|
136
|
-
smaller: true
|
|
137
|
-
});
|
|
138
|
-
css3DRenderer.setSize(rendererWidth, rendererHeight);
|
|
139
|
-
};
|
|
140
|
-
|
|
141
|
-
css3DRendererSetSize();
|
|
142
|
-
resizeObserver = (0, _createResizeObserver["default"])(css3DRendererSetSize, fiveElement);
|
|
143
|
-
css3DRenderer.domElement.style.position = 'absolute';
|
|
144
|
-
css3DRenderer.domElement.style.top = '0';
|
|
145
|
-
css3DRenderer.domElement.style.userSelect = 'none';
|
|
146
|
-
css3DRenderer.domElement.style.pointerEvents = 'none';
|
|
147
|
-
|
|
148
|
-
var renderEveryFrame = function renderEveryFrame() {
|
|
149
|
-
if (stopRenderFlag) return;
|
|
150
|
-
requestAnimationFrameId = requestAnimationFrame(renderEveryFrame);
|
|
151
|
-
css3DRenderer.render(scene, five.camera);
|
|
152
|
-
};
|
|
153
|
-
|
|
154
|
-
return function () {
|
|
155
|
-
var _resizeObserver, _resizeObserver$obser;
|
|
156
|
-
|
|
157
|
-
scene.add(css3DObject);
|
|
158
|
-
(_resizeObserver = resizeObserver) === null || _resizeObserver === void 0 ? void 0 : (_resizeObserver$obser = _resizeObserver.observe) === null || _resizeObserver$obser === void 0 ? void 0 : _resizeObserver$obser.call(_resizeObserver);
|
|
159
|
-
renderEveryFrame();
|
|
160
|
-
|
|
161
|
-
if (mode === 'behind' && mesh) {
|
|
162
|
-
five.scene.add(mesh);
|
|
163
|
-
disposers.push(function () {
|
|
164
|
-
return mesh && five.scene.remove(mesh);
|
|
165
|
-
});
|
|
166
|
-
}
|
|
167
|
-
};
|
|
168
|
-
} else {
|
|
169
|
-
return function () {
|
|
170
|
-
scene.add(css3DObject);
|
|
171
|
-
};
|
|
172
|
-
}
|
|
173
|
-
}();
|
|
174
|
-
|
|
175
|
-
if (frontModeUnInited) {
|
|
176
|
-
var wrapper = fiveElement.parentElement || document.body;
|
|
177
|
-
wrapper.appendChild(css3DRenderer.domElement);
|
|
178
|
-
}
|
|
179
|
-
|
|
180
|
-
if (behindModeUnInited) {
|
|
181
|
-
var _wrapper = behindFiveContainer;
|
|
182
|
-
|
|
183
|
-
_wrapper.appendChild(css3DRenderer.domElement);
|
|
184
|
-
} // ======= INIT END =======
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
var dispose = function dispose() {
|
|
188
|
-
stopRenderFlag = true;
|
|
189
|
-
disposers.forEach(function (d) {
|
|
190
|
-
return d === null || d === void 0 ? void 0 : d();
|
|
191
|
-
});
|
|
192
|
-
scene.remove(css3DObject);
|
|
193
|
-
if (typeof requestAnimationFrameId === 'number') cancelAnimationFrame(requestAnimationFrameId);
|
|
194
|
-
|
|
195
|
-
if (scene.children.length === 0) {
|
|
196
|
-
css3DRenderer.domElement.remove();
|
|
197
|
-
if (mode === 'front') state.frontMode = undefined;
|
|
198
|
-
if (mode === 'behind') state.behindMode = undefined;
|
|
199
|
-
|
|
200
|
-
if (!state.behindMode && !state.frontMode) {
|
|
201
|
-
var _resizeObserver2, _resizeObserver2$unob;
|
|
202
|
-
|
|
203
|
-
(_resizeObserver2 = resizeObserver) === null || _resizeObserver2 === void 0 ? void 0 : (_resizeObserver2$unob = _resizeObserver2.unobserve) === null || _resizeObserver2$unob === void 0 ? void 0 : _resizeObserver2$unob.call(_resizeObserver2);
|
|
204
|
-
}
|
|
205
|
-
}
|
|
206
|
-
|
|
207
|
-
return true;
|
|
208
|
-
};
|
|
209
|
-
|
|
210
|
-
var idx = state.disposeCallbacks.findIndex(function (item) {
|
|
211
|
-
return item === dispose;
|
|
212
|
-
});
|
|
213
|
-
|
|
214
|
-
if (idx !== -1) {
|
|
215
|
-
state.disposeCallbacks.splice(idx, 1);
|
|
216
|
-
} else {
|
|
217
|
-
state.disposeCallbacks.push(dispose);
|
|
218
|
-
}
|
|
219
|
-
|
|
220
|
-
if (autoRender) render();
|
|
221
|
-
return {
|
|
222
|
-
container: container,
|
|
223
|
-
dispose: dispose,
|
|
224
|
-
css3DObject: css3DObject,
|
|
225
|
-
render: autoRender ? undefined : render
|
|
226
|
-
};
|
|
227
|
-
};
|
|
228
|
-
|
|
229
|
-
var createObject = function createObject(points, config) {
|
|
230
|
-
var ratio = config.ratio,
|
|
231
|
-
dpr = config.dpr,
|
|
232
|
-
element = config.container,
|
|
233
|
-
mode = config.mode;
|
|
234
|
-
var planeWidth = points[0].distanceTo(points[1]);
|
|
235
|
-
var planeHeight = points[1].distanceTo(points[2]);
|
|
236
|
-
var domWidthPx = (0, _evenNumber["default"])(planeWidth / ratio * dpr);
|
|
237
|
-
var domHeightPx = (0, _evenNumber["default"])(planeHeight / ratio * dpr);
|
|
238
|
-
var css3DObject = new _CSS3DRenderer.CSS3DObject(element);
|
|
239
|
-
css3DObject.scale.set(ratio, ratio, ratio);
|
|
240
|
-
element.style.width = domWidthPx + 'px';
|
|
241
|
-
element.style.height = domHeightPx + 'px';
|
|
242
|
-
element.style.pointerEvents = 'none';
|
|
243
|
-
var centerPosition = (0, _centerPoint["default"])(points[0], points[2]);
|
|
244
|
-
var vector01 = points[1].clone().sub(points[0]); // 点0 -> 点1 的向量
|
|
245
|
-
|
|
246
|
-
var vector12 = points[2].clone().sub(points[1]); // 点1 -> 点2 的向量
|
|
247
|
-
// 旋转
|
|
248
|
-
|
|
249
|
-
var rotateXAngle = new THREE.Vector3(0, 1, 0).angleTo(new THREE.Vector3(0, vector12.y, vector12.z));
|
|
250
|
-
var rotateYAngle = new THREE.Vector3(1, 0, 0).angleTo(new THREE.Vector3(vector01.x, 0, vector01.z));
|
|
251
|
-
var rotateZAngle = vector01.angleTo(new THREE.Vector3(vector01.x, 0, vector01.z));
|
|
252
|
-
/**
|
|
253
|
-
* [0,1,0] => [0,0,1] 为rolate Worldx正方向
|
|
254
|
-
* [0,0,1] => [0,1,0] 为rolate Worldy正方向
|
|
255
|
-
* [0,1,1] => [-1,0,0] 为rolate Worldz正方向
|
|
256
|
-
*/
|
|
257
|
-
|
|
258
|
-
var rolateX = (vector12.z > 0 ? 1 : -1) * rotateXAngle;
|
|
259
|
-
var rolateY = (vector01.z < 0 ? 1 : -1) * rotateYAngle;
|
|
260
|
-
var rolateZ = (vector01.x > 0 && vector01.y < 0 || vector01.x < 0 && vector01.y > 0 ? -1 : 1) * rotateZAngle;
|
|
261
|
-
css3DObject.rotateOnWorldAxis(new THREE.Vector3(1, 0, 0), rolateX); // x
|
|
262
|
-
|
|
263
|
-
css3DObject.rotateOnWorldAxis(new THREE.Vector3(0, 1, 0), rolateY); // y
|
|
264
|
-
|
|
265
|
-
css3DObject.rotateOnWorldAxis(new THREE.Vector3(0, 0, 1), rolateZ); // z
|
|
266
|
-
|
|
267
|
-
css3DObject.position.set(centerPosition.x, centerPosition.y, centerPosition.z);
|
|
268
|
-
var mesh;
|
|
269
|
-
|
|
270
|
-
if (mode === 'behind') {
|
|
271
|
-
var material = new THREE.MeshBasicMaterial({
|
|
272
|
-
opacity: 0,
|
|
273
|
-
transparent: false,
|
|
274
|
-
side: THREE.DoubleSide
|
|
275
|
-
});
|
|
276
|
-
var geometry = new THREE.PlaneGeometry(domWidthPx, domHeightPx);
|
|
277
|
-
mesh = new THREE.Mesh(geometry, material);
|
|
278
|
-
mesh.name = 'CSS3DRenderPlugin-mesh';
|
|
279
|
-
mesh.position.copy(css3DObject.position);
|
|
280
|
-
mesh.rotation.copy(css3DObject.rotation);
|
|
281
|
-
mesh.scale.copy(css3DObject.scale);
|
|
282
|
-
}
|
|
283
|
-
|
|
284
|
-
return {
|
|
285
|
-
css3DObject: css3DObject,
|
|
286
|
-
mesh: mesh
|
|
287
|
-
};
|
|
288
|
-
};
|
|
289
|
-
|
|
290
|
-
return {
|
|
291
|
-
create3DDomContainer: create3DDomContainer,
|
|
292
|
-
disposeAll: function disposeAll() {
|
|
293
|
-
state.disposeCallbacks.forEach(function (d) {
|
|
294
|
-
return d === null || d === void 0 ? void 0 : d();
|
|
295
|
-
});
|
|
296
|
-
state.disposeCallbacks = [];
|
|
297
|
-
}
|
|
298
|
-
};
|
|
299
|
-
};
|
|
300
|
-
|
|
301
|
-
exports.CSS3DRenderPlugin = CSS3DRenderPlugin;
|
|
302
|
-
var _default = CSS3DRenderPlugin;
|
|
303
|
-
exports["default"] = _default;
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
require("core-js/modules/es.object.define-property.js");
|
|
4
|
-
|
|
5
|
-
Object.defineProperty(exports, "__esModule", {
|
|
6
|
-
value: true
|
|
7
|
-
});
|
|
8
|
-
exports["default"] = createResizeObserver;
|
|
9
|
-
|
|
10
|
-
/**
|
|
11
|
-
* @description: 究极简陋的 ResizeObserver polyfill
|
|
12
|
-
*/
|
|
13
|
-
function createResizeObserver(func, element) {
|
|
14
|
-
if (!element || typeof ResizeObserver === 'undefined') {
|
|
15
|
-
return {
|
|
16
|
-
observe: function observe() {
|
|
17
|
-
return window.addEventListener('resize', func);
|
|
18
|
-
},
|
|
19
|
-
unobserve: function unobserve() {
|
|
20
|
-
return window.removeEventListener('resize', func);
|
|
21
|
-
}
|
|
22
|
-
};
|
|
23
|
-
} else {
|
|
24
|
-
var observer = new ResizeObserver(func);
|
|
25
|
-
return {
|
|
26
|
-
observe: function observe() {
|
|
27
|
-
return observer.observe(element);
|
|
28
|
-
},
|
|
29
|
-
unobserve: function unobserve() {
|
|
30
|
-
return observer.unobserve(element);
|
|
31
|
-
}
|
|
32
|
-
};
|
|
33
|
-
}
|
|
34
|
-
}
|
|
@@ -1,362 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
require("core-js/modules/es.array.iterator.js");
|
|
4
|
-
|
|
5
|
-
require("core-js/modules/es.string.iterator.js");
|
|
6
|
-
|
|
7
|
-
require("core-js/modules/es.weak-map.js");
|
|
8
|
-
|
|
9
|
-
require("core-js/modules/web.dom-collections.iterator.js");
|
|
10
|
-
|
|
11
|
-
require("core-js/modules/es.object.define-property.js");
|
|
12
|
-
|
|
13
|
-
require("core-js/modules/es.object.get-own-property-descriptor.js");
|
|
14
|
-
|
|
15
|
-
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
16
|
-
|
|
17
|
-
var _typeof = require("@babel/runtime/helpers/typeof");
|
|
18
|
-
|
|
19
|
-
Object.defineProperty(exports, "__esModule", {
|
|
20
|
-
value: true
|
|
21
|
-
});
|
|
22
|
-
exports["default"] = exports.CameraMovementPlugin = void 0;
|
|
23
|
-
|
|
24
|
-
var _regenerator = _interopRequireDefault(require("@babel/runtime/regenerator"));
|
|
25
|
-
|
|
26
|
-
require("core-js/modules/es.object.to-string.js");
|
|
27
|
-
|
|
28
|
-
require("core-js/modules/es.promise.js");
|
|
29
|
-
|
|
30
|
-
require("core-js/modules/es.object.assign.js");
|
|
31
|
-
|
|
32
|
-
require("core-js/modules/es.string.repeat.js");
|
|
33
|
-
|
|
34
|
-
require("core-js/modules/web.timers.js");
|
|
35
|
-
|
|
36
|
-
var _asyncToGenerator2 = _interopRequireDefault(require("@babel/runtime/helpers/asyncToGenerator"));
|
|
37
|
-
|
|
38
|
-
var _five = require("@realsee/five");
|
|
39
|
-
|
|
40
|
-
var TWEEN = _interopRequireWildcard(require("@tweenjs/tween.js"));
|
|
41
|
-
|
|
42
|
-
var _tween2 = require("../../shared-utils/animationFrame/tween");
|
|
43
|
-
|
|
44
|
-
var _typing = require("./typing");
|
|
45
|
-
|
|
46
|
-
var _formatRad = require("../../shared-utils/animationFrame/formatRad");
|
|
47
|
-
|
|
48
|
-
var _calculateProgress = require("../../shared-utils/animationFrame/calculateProgress");
|
|
49
|
-
|
|
50
|
-
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
51
|
-
|
|
52
|
-
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
53
|
-
|
|
54
|
-
var getLongitudeParams = function getLongitudeParams(from, to, rotation) {
|
|
55
|
-
var PI = Math.PI;
|
|
56
|
-
var PI_2 = PI * 2;
|
|
57
|
-
from = (0, _formatRad.formatLongitude)(from);
|
|
58
|
-
to = (0, _formatRad.formatLongitude)(to); // 逆时针旋转,初始值必须是较大的值
|
|
59
|
-
|
|
60
|
-
if (rotation === _typing.Rotation.Anticlockwise && from < to) from += PI_2; // 顺时针旋转,结束值必须是较大值
|
|
61
|
-
|
|
62
|
-
if (rotation === _typing.Rotation.Clockwise && to < from) to += PI_2; // Loop 旋转,找锐角旋转
|
|
63
|
-
// 如果 to 比 from 大 180°,逆时针转
|
|
64
|
-
// 如果 from 比 to 大 180°,顺时针转
|
|
65
|
-
|
|
66
|
-
if (rotation === _typing.Rotation.Loop && to - from > PI) return getLongitudeParams(from, to, _typing.Rotation.Anticlockwise);
|
|
67
|
-
if (rotation === _typing.Rotation.Loop && from - to > PI) return getLongitudeParams(from, to, _typing.Rotation.Clockwise);
|
|
68
|
-
return {
|
|
69
|
-
from: from,
|
|
70
|
-
to: to
|
|
71
|
-
};
|
|
72
|
-
};
|
|
73
|
-
/**
|
|
74
|
-
* **运镜插件** 模拟类似于电影运镜效果。
|
|
75
|
-
*/
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
var CameraMovementPlugin = function CameraMovementPlugin(five) {
|
|
79
|
-
var state = {};
|
|
80
|
-
|
|
81
|
-
var move = /*#__PURE__*/function () {
|
|
82
|
-
var _ref = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee(args, duration) {
|
|
83
|
-
var opts,
|
|
84
|
-
_args = arguments;
|
|
85
|
-
return _regenerator["default"].wrap(function _callee$(_context) {
|
|
86
|
-
while (1) {
|
|
87
|
-
switch (_context.prev = _context.next) {
|
|
88
|
-
case 0:
|
|
89
|
-
opts = _args.length > 2 && _args[2] !== undefined ? _args[2] : {
|
|
90
|
-
preload: true
|
|
91
|
-
};
|
|
92
|
-
|
|
93
|
-
if (state.interruptCallback) {
|
|
94
|
-
state.interruptCallback(false);
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
if (!opts.asyncStartCallback) {
|
|
98
|
-
_context.next = 5;
|
|
99
|
-
break;
|
|
100
|
-
}
|
|
101
|
-
|
|
102
|
-
_context.next = 5;
|
|
103
|
-
return opts.asyncStartCallback();
|
|
104
|
-
|
|
105
|
-
case 5:
|
|
106
|
-
if (!(args.mode && args.mode !== five.currentMode)) {
|
|
107
|
-
_context.next = 8;
|
|
108
|
-
break;
|
|
109
|
-
}
|
|
110
|
-
|
|
111
|
-
_context.next = 8;
|
|
112
|
-
return five.changeMode(args.mode);
|
|
113
|
-
|
|
114
|
-
case 8:
|
|
115
|
-
if (!(opts.preload && args.panoIndex !== undefined && args.panoIndex !== five.panoIndex)) {
|
|
116
|
-
_context.next = 11;
|
|
117
|
-
break;
|
|
118
|
-
}
|
|
119
|
-
|
|
120
|
-
_context.next = 11;
|
|
121
|
-
return five.preloadPano(args.panoIndex);
|
|
122
|
-
|
|
123
|
-
case 11:
|
|
124
|
-
if (!opts.asyncEndCallback) {
|
|
125
|
-
_context.next = 14;
|
|
126
|
-
break;
|
|
127
|
-
}
|
|
128
|
-
|
|
129
|
-
_context.next = 14;
|
|
130
|
-
return opts.asyncEndCallback();
|
|
131
|
-
|
|
132
|
-
case 14:
|
|
133
|
-
if (!(args.panoIndex === undefined && args.fov === undefined && args.latitude === undefined && args.longitude === undefined)) {
|
|
134
|
-
_context.next = 16;
|
|
135
|
-
break;
|
|
136
|
-
}
|
|
137
|
-
|
|
138
|
-
return _context.abrupt("return", true);
|
|
139
|
-
|
|
140
|
-
case 16:
|
|
141
|
-
_context.next = 18;
|
|
142
|
-
return new Promise(function (resolve, reject) {
|
|
143
|
-
var panoIndex = args.panoIndex !== undefined ? args.panoIndex : five.panoIndex;
|
|
144
|
-
|
|
145
|
-
if (panoIndex !== undefined) {
|
|
146
|
-
five.moveToPano(panoIndex, Object.assign({
|
|
147
|
-
duration: duration,
|
|
148
|
-
// 移动耗时
|
|
149
|
-
moveEndCallback: function moveEndCallback() {
|
|
150
|
-
return resolve(true);
|
|
151
|
-
},
|
|
152
|
-
// 移动结束
|
|
153
|
-
moveCancelCallback: function moveCancelCallback() {
|
|
154
|
-
return reject(false);
|
|
155
|
-
} // 移动开始
|
|
156
|
-
|
|
157
|
-
}, args));
|
|
158
|
-
} else {
|
|
159
|
-
reject(false);
|
|
160
|
-
}
|
|
161
|
-
});
|
|
162
|
-
|
|
163
|
-
case 18:
|
|
164
|
-
return _context.abrupt("return", _context.sent);
|
|
165
|
-
|
|
166
|
-
case 19:
|
|
167
|
-
case "end":
|
|
168
|
-
return _context.stop();
|
|
169
|
-
}
|
|
170
|
-
}
|
|
171
|
-
}, _callee);
|
|
172
|
-
}));
|
|
173
|
-
|
|
174
|
-
return function move(_x, _x2) {
|
|
175
|
-
return _ref.apply(this, arguments);
|
|
176
|
-
};
|
|
177
|
-
}();
|
|
178
|
-
|
|
179
|
-
var getAnimeParams = function getAnimeParams(args) {
|
|
180
|
-
var currentFiveState = five.state; // latitude
|
|
181
|
-
|
|
182
|
-
var fromLatitude = (0, _formatRad.formatLatitude)(currentFiveState.latitude);
|
|
183
|
-
var toLatitude = (0, _formatRad.formatLatitude)(args.latitude); // longitude
|
|
184
|
-
|
|
185
|
-
var _getLongitudeParams = getLongitudeParams(currentFiveState.longitude, args.longitude, args.rotation || _typing.Rotation.Loop),
|
|
186
|
-
fromLongitude = _getLongitudeParams.from,
|
|
187
|
-
toLongitude = _getLongitudeParams.to; // fov
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
var fromFov = currentFiveState.fov;
|
|
191
|
-
var toFov = args.fov;
|
|
192
|
-
return {
|
|
193
|
-
from: {
|
|
194
|
-
latitude: fromLatitude,
|
|
195
|
-
longitude: fromLongitude,
|
|
196
|
-
fov: fromFov
|
|
197
|
-
},
|
|
198
|
-
to: {
|
|
199
|
-
latitude: toLatitude,
|
|
200
|
-
longitude: toLongitude,
|
|
201
|
-
fov: toFov
|
|
202
|
-
}
|
|
203
|
-
};
|
|
204
|
-
};
|
|
205
|
-
|
|
206
|
-
var rotate = /*#__PURE__*/function () {
|
|
207
|
-
var _ref2 = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee2(args, duration) {
|
|
208
|
-
var opts,
|
|
209
|
-
_getAnimeParams,
|
|
210
|
-
from,
|
|
211
|
-
to,
|
|
212
|
-
_args2 = arguments;
|
|
213
|
-
|
|
214
|
-
return _regenerator["default"].wrap(function _callee2$(_context2) {
|
|
215
|
-
while (1) {
|
|
216
|
-
switch (_context2.prev = _context2.next) {
|
|
217
|
-
case 0:
|
|
218
|
-
opts = _args2.length > 2 && _args2[2] !== undefined ? _args2[2] : {};
|
|
219
|
-
|
|
220
|
-
if (state.interruptCallback) {
|
|
221
|
-
state.interruptCallback(false);
|
|
222
|
-
}
|
|
223
|
-
|
|
224
|
-
if (!opts.asyncStartCallback) {
|
|
225
|
-
_context2.next = 5;
|
|
226
|
-
break;
|
|
227
|
-
}
|
|
228
|
-
|
|
229
|
-
_context2.next = 5;
|
|
230
|
-
return opts.asyncStartCallback();
|
|
231
|
-
|
|
232
|
-
case 5:
|
|
233
|
-
if (!(five.currentMode !== _five.Five.Mode.Panorama)) {
|
|
234
|
-
_context2.next = 8;
|
|
235
|
-
break;
|
|
236
|
-
}
|
|
237
|
-
|
|
238
|
-
_context2.next = 8;
|
|
239
|
-
return five.changeMode(_five.Five.Mode.Panorama);
|
|
240
|
-
|
|
241
|
-
case 8:
|
|
242
|
-
if (!(args.panoIndex !== undefined && args.panoIndex !== five.panoIndex)) {
|
|
243
|
-
_context2.next = 14;
|
|
244
|
-
break;
|
|
245
|
-
}
|
|
246
|
-
|
|
247
|
-
if (!opts.preload) {
|
|
248
|
-
_context2.next = 12;
|
|
249
|
-
break;
|
|
250
|
-
}
|
|
251
|
-
|
|
252
|
-
_context2.next = 12;
|
|
253
|
-
return five.preloadPano(args.panoIndex);
|
|
254
|
-
|
|
255
|
-
case 12:
|
|
256
|
-
_context2.next = 14;
|
|
257
|
-
return new Promise(function (resolve, reject) {
|
|
258
|
-
if (!args.panoIndex) {
|
|
259
|
-
resolve(true);
|
|
260
|
-
return;
|
|
261
|
-
}
|
|
262
|
-
|
|
263
|
-
five.moveToPano(args.panoIndex, {
|
|
264
|
-
moveEndCallback: function moveEndCallback() {
|
|
265
|
-
return resolve(true);
|
|
266
|
-
},
|
|
267
|
-
// 移动结束
|
|
268
|
-
moveCancelCallback: function moveCancelCallback() {
|
|
269
|
-
return reject(false);
|
|
270
|
-
} // 移动开始
|
|
271
|
-
|
|
272
|
-
});
|
|
273
|
-
});
|
|
274
|
-
|
|
275
|
-
case 14:
|
|
276
|
-
if (!opts.asyncEndCallback) {
|
|
277
|
-
_context2.next = 17;
|
|
278
|
-
break;
|
|
279
|
-
}
|
|
280
|
-
|
|
281
|
-
_context2.next = 17;
|
|
282
|
-
return opts.asyncEndCallback();
|
|
283
|
-
|
|
284
|
-
case 17:
|
|
285
|
-
_getAnimeParams = getAnimeParams(args), from = _getAnimeParams.from, to = _getAnimeParams.to;
|
|
286
|
-
_context2.next = 20;
|
|
287
|
-
return new Promise(function (resolve) {
|
|
288
|
-
var onUpdate = function onUpdate(_ref3) {
|
|
289
|
-
var progress = _ref3.progress;
|
|
290
|
-
var state = {};
|
|
291
|
-
state.longitude = (0, _calculateProgress.progressNumber)(from.longitude, to.longitude, progress);
|
|
292
|
-
state.latitude = (0, _calculateProgress.progressNumber)(from.latitude, to.latitude, progress);
|
|
293
|
-
state.fov = (0, _calculateProgress.progressNumber)(from.fov, to.fov, progress);
|
|
294
|
-
five.setState(state, true);
|
|
295
|
-
};
|
|
296
|
-
|
|
297
|
-
var onComplete = function onComplete() {
|
|
298
|
-
resolve(true);
|
|
299
|
-
};
|
|
300
|
-
|
|
301
|
-
var onDestroy = function onDestroy() {
|
|
302
|
-
resolve(false);
|
|
303
|
-
};
|
|
304
|
-
|
|
305
|
-
var animeDuration = args.rotateSpeed ? Math.ceil(Math.abs(to.longitude - from.longitude) / args.rotateSpeed * 1000) : duration;
|
|
306
|
-
var tween = (0, _tween2.tweenProgress)(animeDuration, TWEEN.Easing.Linear.None).onUpdate(onUpdate).onComplete(onComplete).onDestroy(onDestroy);
|
|
307
|
-
|
|
308
|
-
if (args.rotation === _typing.Rotation.Loop) {
|
|
309
|
-
tween.repeat(Infinity).yoyo(true);
|
|
310
|
-
}
|
|
311
|
-
/**
|
|
312
|
-
* 中断回调:可能会被其他动画中断。
|
|
313
|
-
*/
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
/**
|
|
317
|
-
* 中断回调:可能会被其他动画中断。
|
|
318
|
-
*/
|
|
319
|
-
state.interruptCallback = function () {
|
|
320
|
-
var flag = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : true;
|
|
321
|
-
tween.destroy();
|
|
322
|
-
state.interruptCallback = undefined;
|
|
323
|
-
|
|
324
|
-
if (state.timeoutId) {
|
|
325
|
-
clearTimeout(state.timeoutId);
|
|
326
|
-
state.timeoutId = undefined;
|
|
327
|
-
}
|
|
328
|
-
|
|
329
|
-
resolve(flag);
|
|
330
|
-
};
|
|
331
|
-
|
|
332
|
-
state.timeoutId = setTimeout(function () {
|
|
333
|
-
// 总时间到了之后强制结束,同时也是 Loop 模式的结束方式
|
|
334
|
-
if (state.interruptCallback) state.interruptCallback(true);
|
|
335
|
-
}, duration);
|
|
336
|
-
});
|
|
337
|
-
|
|
338
|
-
case 20:
|
|
339
|
-
return _context2.abrupt("return", _context2.sent);
|
|
340
|
-
|
|
341
|
-
case 21:
|
|
342
|
-
case "end":
|
|
343
|
-
return _context2.stop();
|
|
344
|
-
}
|
|
345
|
-
}
|
|
346
|
-
}, _callee2);
|
|
347
|
-
}));
|
|
348
|
-
|
|
349
|
-
return function rotate(_x3, _x4) {
|
|
350
|
-
return _ref2.apply(this, arguments);
|
|
351
|
-
};
|
|
352
|
-
}();
|
|
353
|
-
|
|
354
|
-
return {
|
|
355
|
-
move: move,
|
|
356
|
-
rotate: rotate
|
|
357
|
-
};
|
|
358
|
-
};
|
|
359
|
-
|
|
360
|
-
exports.CameraMovementPlugin = CameraMovementPlugin;
|
|
361
|
-
var _default = CameraMovementPlugin;
|
|
362
|
-
exports["default"] = _default;
|