@realsee/dnalogel 3.51.0 → 3.52.1
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/CHANGELOG.md +15 -0
- package/dist/Object3DHelperPlugin/Controller.d.ts +9 -9
- package/dist/Object3DHelperPlugin/FiveControllerWrapper.d.ts +4 -2
- package/dist/PanoMeasurePlugin/Model/area.d.ts +1 -1
- package/dist/PanoMeasurePlugin/Model/polygon.d.ts +1 -1
- package/dist/PanoMeasurePlugin/typings/data.d.ts +1 -2
- package/dist/Sculpt/Editors/BoxMeshEditor.d.ts +5 -0
- package/dist/Sculpt/Editors/CircleMeshEditor.d.ts +5 -0
- package/dist/Sculpt/Editors/CylinderMeshEditor.d.ts +5 -0
- package/dist/Sculpt/Editors/PrismMeshEditor.d.ts +5 -0
- package/dist/Sculpt/Editors/RectangleMeshEditor.d.ts +5 -0
- package/dist/Sculpt/Meshes/Box.d.ts +6 -24
- package/dist/Sculpt/Meshes/Circle.d.ts +0 -4
- package/dist/Sculpt/Meshes/Cylinder.d.ts +0 -1
- package/dist/Sculpt/Meshes/Line.d.ts +9 -22
- package/dist/Sculpt/Meshes/Polygon.d.ts +1 -5
- package/dist/Sculpt/Meshes/PolygonWithEdge.d.ts +1 -1
- package/dist/Sculpt/Meshes/Prism.d.ts +29 -10
- package/dist/Sculpt/Meshes/Rectangle.d.ts +1 -5
- package/dist/Sculpt/Objects/Base/index.d.ts +3 -3
- package/dist/Sculpt/Objects/Box/index.d.ts +7 -2
- package/dist/Sculpt/Objects/Circle/index.d.ts +3 -0
- package/dist/Sculpt/Objects/Cylinder/index.d.ts +3 -0
- package/dist/Sculpt/Objects/Line/index.d.ts +3 -0
- package/dist/Sculpt/Objects/Point/index.d.ts +3 -0
- package/dist/Sculpt/Objects/Polygon/index.d.ts +3 -0
- package/dist/Sculpt/Objects/Polyline/index.d.ts +3 -0
- package/dist/Sculpt/Objects/Prism/index.d.ts +3 -0
- package/dist/Sculpt/Objects/Rectangle/index.d.ts +13 -2
- package/dist/Sculpt/index.d.ts +10 -19
- package/dist/Sculpt/typings/style.d.ts +6 -0
- package/dist/Sculpt/utils/export.d.ts +24 -18
- package/dist/Sculpt/utils/sortPositionsByCameraPosition.d.ts +5 -0
- package/dist/Sculpt/utils/three/ColoredMesh.d.ts +4 -0
- package/dist/index.cjs.js +88 -3009
- package/dist/index.d.ts +79 -1
- package/dist/index.js +35141 -54254
- package/dist/index.umd.js +81 -3002
- package/dist/shared-utils/Object3DHelper/Base/BaseController.d.ts +1 -0
- package/dist/shared-utils/Object3DHelper/Base/BaseHelper.d.ts +7 -3
- package/dist/shared-utils/Object3DHelper/Controller/ScaleController.d.ts +0 -1
- package/dist/shared-utils/Object3DHelper/Helper/BoundingBoxHelper.d.ts +3 -1
- package/dist/shared-utils/Object3DHelper/Helper/CSS3DScaleHelper.d.ts +2 -0
- package/dist/shared-utils/Object3DHelper/Helper/MoveHelper.d.ts +2 -1
- package/dist/shared-utils/Object3DHelper/Helper/RotateHelper.d.ts +2 -1
- package/dist/shared-utils/Object3DHelper/Helper/ScaleHelper.d.ts +4 -2
- package/dist/shared-utils/Object3DHelper/typings/index.d.ts +1 -1
- package/dist/shared-utils/Object3DHelper/utils/calculateScaleByCamera.d.ts +4 -1
- package/dist/shared-utils/five/FiveLine.d.ts +18 -14
- package/dist/shared-utils/index.d.ts +0 -1
- package/dist/shared-utils/math/planimetry.d.ts +1 -1
- package/dist/shared-utils/tag.d.ts +5 -7
- package/dist/shared-utils/three/boundingBox.d.ts +14 -20
- package/dist/shared-utils/three/core/LineGeometry.d.ts +13 -0
- package/dist/shared-utils/three/core/PrismGeometry.d.ts +14 -0
- package/dist/shared-utils/three/geometryUtil.d.ts +8 -0
- package/dist/shared-utils/three/getNormal.d.ts +5 -2
- package/libs/AreaMakerPlugin/Controller.js +47 -100
- package/libs/AreaMakerPlugin/index.js +12 -65
- package/libs/AreaMakerPlugin/utils/Item.js +102 -157
- package/libs/CSS3DRenderPlugin/Controller.js +45 -93
- package/libs/CSS3DRenderPlugin/index.js +15 -63
- package/libs/CSS3DRenderPlugin/utils/three/CSS3DObject.js +51 -106
- package/libs/CSS3DRenderPlugin/utils/three/CSS3DRender.js +79 -131
- package/libs/CruisePlugin/BaseController.js +90 -143
- package/libs/CruisePlugin/Move.js +39 -83
- package/libs/CruisePlugin/Work.js +52 -96
- package/libs/CruisePlugin/index.js +23 -67
- package/libs/CurrentPanoImagePlugin/Controller.js +88 -141
- package/libs/CurrentPanoImagePlugin/index.js +11 -64
- package/libs/GuideLinePlugin/Controller.js +13 -57
- package/libs/GuideLinePlugin/GuideLineItem.js +20 -64
- package/libs/GuideLinePlugin/GuideLineModeItem/index.js +3 -8
- package/libs/GuideLinePlugin/GuideLineModeItem.js +15 -59
- package/libs/GuideLinePlugin/index.js +23 -67
- package/libs/ModelMakerPlugin/Controller.js +125 -165
- package/libs/ModelMakerPlugin/index.js +23 -63
- package/libs/ModelMakerPlugin/item/baseItem.js +2 -3
- package/libs/ModelMakerPlugin/item/boxItem.js +2 -3
- package/libs/ModelMakerPlugin/item/polygonItem.js +6 -7
- package/libs/ModelMakerPlugin/item/prismItem.js +2 -3
- package/libs/ModelMakerPlugin/utils/getFiveDomEvent.js +2 -3
- package/libs/ModelTVVideoPlugin/Plugin.js +49 -97
- package/libs/ModelTVVideoPlugin/index.js +8 -56
- package/libs/Object3DHelperPlugin/Controller.d.ts +9 -9
- package/libs/Object3DHelperPlugin/Controller.js +105 -92
- package/libs/Object3DHelperPlugin/FiveControllerWrapper.d.ts +4 -2
- package/libs/Object3DHelperPlugin/FiveControllerWrapper.js +35 -30
- package/libs/Object3DHelperPlugin/index.js +15 -30
- package/libs/PanoCompassPlugin/Controller.js +46 -93
- package/libs/PanoCompassPlugin/index.js +17 -64
- package/libs/PanoCursorRaycasterPlugin/index.js +4 -3
- package/libs/PanoDoorLabelPlugin/BaseController.js +27 -80
- package/libs/PanoDoorLabelPlugin/Controller.js +80 -133
- package/libs/PanoDoorLabelPlugin/index.js +11 -64
- package/libs/PanoMeasurePlugin/Components/Controller0.js +79 -128
- package/libs/PanoMeasurePlugin/Components/Controller1.js +92 -141
- package/libs/PanoMeasurePlugin/Controller/BaseController.js +3 -2
- package/libs/PanoMeasurePlugin/Controller/EditController.js +73 -122
- package/libs/PanoMeasurePlugin/Controller/MixedController.js +3 -2
- package/libs/PanoMeasurePlugin/Controller/ViewController.js +3 -2
- package/libs/PanoMeasurePlugin/Controller/WatchController.js +72 -121
- package/libs/PanoMeasurePlugin/Controller/index.js +89 -135
- package/libs/PanoMeasurePlugin/Model/area.d.ts +1 -1
- package/libs/PanoMeasurePlugin/Model/area.js +25 -74
- package/libs/PanoMeasurePlugin/Model/index.js +3 -2
- package/libs/PanoMeasurePlugin/Model/line.js +1 -0
- package/libs/PanoMeasurePlugin/Model/polygon.d.ts +1 -1
- package/libs/PanoMeasurePlugin/Model/polygon.js +7 -7
- package/libs/PanoMeasurePlugin/Model/polyline.js +3 -2
- package/libs/PanoMeasurePlugin/Modules/Magnifier.js +1 -56
- package/libs/PanoMeasurePlugin/Modules/UIController/index.js +17 -66
- package/libs/PanoMeasurePlugin/index.js +18 -64
- package/libs/PanoMeasurePlugin/typings/data.d.ts +1 -2
- package/libs/PanoMeasurePlugin/utils/dom/areaDom.js +5 -59
- package/libs/PanoMeasurePlugin/utils/line.js +3 -2
- package/libs/PanoRulerProPlugin/Controller.js +34 -89
- package/libs/PanoRulerProPlugin/RulerItems.js +92 -147
- package/libs/PanoRulerProPlugin/index.js +10 -65
- package/libs/PanoSpatialTagPlugin/Plugin.js +130 -178
- package/libs/PanoSpatialTagPlugin/index.js +6 -54
- package/libs/PanoTagPlugin/Components/Common/TagPoint.js +61 -116
- package/libs/PanoTagPlugin/Components/Tag/MarketingTag.js +138 -193
- package/libs/PanoTagPlugin/Components/Tag/index.js +140 -194
- package/libs/PanoTagPlugin/Components/TagContainer.js +58 -112
- package/libs/PanoTagPlugin/Components/TagItem.js +137 -191
- package/libs/PanoTagPlugin/controller/Tag/BaseTag.js +109 -164
- package/libs/PanoTagPlugin/controller/Tag/ModelTag.js +22 -76
- package/libs/PanoTagPlugin/controller/Tag/PlaneTag.js +33 -87
- package/libs/PanoTagPlugin/controller/Tag/PointTag.js +39 -94
- package/libs/PanoTagPlugin/controller/TagRender.js +18 -62
- package/libs/PanoTagPlugin/controller/TagUtil.js +80 -124
- package/libs/PanoTagPlugin/controller/index.js +37 -81
- package/libs/PanoTagPlugin/index.js +28 -72
- package/libs/PanoTagPlugin/utils/model/mediaPlane.js +14 -14
- package/libs/PanoTagPlugin/utils/tag/calculateTagConfig.js +22 -77
- package/libs/PanoVideoPlugin/Controller.js +43 -96
- package/libs/PanoVideoPlugin/VideoMeshController.js +64 -119
- package/libs/PanoVideoPlugin/index.js +14 -67
- package/libs/PipelinePlugin/Controller.js +123 -176
- package/libs/PipelinePlugin/index.js +11 -64
- package/libs/PipelinePlugin/utils/Objects/FlowPipe.js +15 -70
- package/libs/PipelinePlugin/utils/Objects/HighlightPipe.js +3 -58
- package/libs/PipelinePlugin/utils/Objects/Pipe.js +42 -97
- package/libs/Sculpt/Editors/BoxMeshEditor.d.ts +5 -0
- package/libs/Sculpt/Editors/BoxMeshEditor.js +98 -0
- package/libs/Sculpt/Editors/CircleMeshEditor.d.ts +5 -0
- package/libs/Sculpt/Editors/CircleMeshEditor.js +9 -0
- package/libs/Sculpt/Editors/CylinderMeshEditor.d.ts +5 -0
- package/libs/Sculpt/Editors/CylinderMeshEditor.js +41 -0
- package/libs/Sculpt/Editors/PrismMeshEditor.d.ts +5 -0
- package/libs/Sculpt/Editors/PrismMeshEditor.js +43 -0
- package/libs/Sculpt/Editors/RectangleMeshEditor.d.ts +5 -0
- package/libs/Sculpt/Editors/RectangleMeshEditor.js +70 -0
- package/libs/Sculpt/Meshes/Box.d.ts +6 -24
- package/libs/Sculpt/Meshes/Box.js +22 -93
- package/libs/Sculpt/Meshes/Circle.d.ts +0 -4
- package/libs/Sculpt/Meshes/Circle.js +18 -27
- package/libs/Sculpt/Meshes/Cylinder.d.ts +0 -1
- package/libs/Sculpt/Meshes/Cylinder.js +17 -24
- package/libs/Sculpt/Meshes/Line.d.ts +9 -22
- package/libs/Sculpt/Meshes/Line.js +85 -104
- package/libs/Sculpt/Meshes/LineWithDots.js +10 -14
- package/libs/Sculpt/Meshes/Point.js +29 -34
- package/libs/Sculpt/Meshes/Polygon.d.ts +1 -5
- package/libs/Sculpt/Meshes/Polygon.js +40 -53
- package/libs/Sculpt/Meshes/PolygonWithEdge.d.ts +1 -1
- package/libs/Sculpt/Meshes/Prism.d.ts +29 -10
- package/libs/Sculpt/Meshes/Prism.js +108 -84
- package/libs/Sculpt/Meshes/Rectangle.d.ts +1 -5
- package/libs/Sculpt/Meshes/Rectangle.js +12 -22
- package/libs/Sculpt/Meshes/RectangleWithEdge.js +17 -20
- package/libs/Sculpt/Objects/Base/index.d.ts +3 -3
- package/libs/Sculpt/Objects/Base/index.js +20 -25
- package/libs/Sculpt/Objects/Box/index.d.ts +7 -2
- package/libs/Sculpt/Objects/Box/index.js +72 -60
- package/libs/Sculpt/Objects/Circle/index.d.ts +3 -0
- package/libs/Sculpt/Objects/Circle/index.js +41 -37
- package/libs/Sculpt/Objects/Cylinder/index.d.ts +3 -0
- package/libs/Sculpt/Objects/Cylinder/index.js +66 -62
- package/libs/Sculpt/Objects/Line/Editor.js +8 -10
- package/libs/Sculpt/Objects/Line/index.d.ts +3 -0
- package/libs/Sculpt/Objects/Line/index.js +45 -41
- package/libs/Sculpt/Objects/Point/index.d.ts +3 -0
- package/libs/Sculpt/Objects/Point/index.js +33 -29
- package/libs/Sculpt/Objects/Polygon/index.d.ts +3 -0
- package/libs/Sculpt/Objects/Polygon/index.js +67 -63
- package/libs/Sculpt/Objects/Polyline/index.d.ts +3 -0
- package/libs/Sculpt/Objects/Polyline/index.js +46 -42
- package/libs/Sculpt/Objects/Prism/index.d.ts +3 -0
- package/libs/Sculpt/Objects/Prism/index.js +58 -53
- package/libs/Sculpt/Objects/Rectangle/index.d.ts +13 -2
- package/libs/Sculpt/Objects/Rectangle/index.js +143 -81
- package/libs/Sculpt/index.d.ts +10 -19
- package/libs/Sculpt/index.js +105 -107
- package/libs/Sculpt/typings/style.d.ts +6 -0
- package/libs/Sculpt/utils/export.d.ts +24 -18
- package/libs/Sculpt/utils/export.js +52 -19
- package/libs/Sculpt/utils/sortPositionsByCameraPosition.d.ts +5 -0
- package/libs/Sculpt/utils/sortPositionsByCameraPosition.js +9 -0
- package/libs/Sculpt/utils/three/ColoredMesh.d.ts +4 -0
- package/libs/Sculpt/utils/three/ColoredMesh.js +40 -37
- package/libs/base/BasePlugin.js +10 -15
- package/libs/floorplan/MapviewFloorplanPlugin/Controller.js +96 -147
- package/libs/floorplan/MapviewFloorplanPlugin/index.js +12 -63
- package/libs/floorplan/ModelFloorplanPlugin/Controller.js +53 -105
- package/libs/floorplan/ModelFloorplanPlugin/index.js +11 -63
- package/libs/floorplan/PanoFloorplanRadarPlugin/Controller.js +65 -118
- package/libs/floorplan/PanoFloorplanRadarPlugin/index.js +11 -64
- package/libs/floorplan/TopviewFloorplanPlugin/Controller.js +54 -106
- package/libs/floorplan/TopviewFloorplanPlugin/index.js +11 -63
- package/libs/floorplan/index.js +0 -5
- package/libs/index.d.ts +79 -1
- package/libs/index.js +229 -215
- package/libs/shared-utils/Object3DHelper/Base/BaseController.d.ts +1 -0
- package/libs/shared-utils/Object3DHelper/Base/BaseController.js +112 -122
- package/libs/shared-utils/Object3DHelper/Base/BaseHelper.d.ts +7 -3
- package/libs/shared-utils/Object3DHelper/Base/BaseHelper.js +60 -39
- package/libs/shared-utils/Object3DHelper/Controller/RotateController.js +47 -47
- package/libs/shared-utils/Object3DHelper/Controller/ScaleController.d.ts +0 -1
- package/libs/shared-utils/Object3DHelper/Controller/ScaleController.js +28 -28
- package/libs/shared-utils/Object3DHelper/Helper/BoundingBoxHelper.d.ts +3 -1
- package/libs/shared-utils/Object3DHelper/Helper/BoundingBoxHelper.js +25 -18
- package/libs/shared-utils/Object3DHelper/Helper/CSS3DScaleHelper.d.ts +2 -0
- package/libs/shared-utils/Object3DHelper/Helper/CSS3DScaleHelper.js +18 -14
- package/libs/shared-utils/Object3DHelper/Helper/MoveHelper.d.ts +2 -1
- package/libs/shared-utils/Object3DHelper/Helper/MoveHelper.js +1 -0
- package/libs/shared-utils/Object3DHelper/Helper/RotateHelper.d.ts +2 -1
- package/libs/shared-utils/Object3DHelper/Helper/RotateHelper.js +2 -1
- package/libs/shared-utils/Object3DHelper/Helper/ScaleHelper.d.ts +4 -2
- package/libs/shared-utils/Object3DHelper/Helper/ScaleHelper.js +40 -28
- package/libs/shared-utils/Object3DHelper/typings/index.d.ts +1 -1
- package/libs/shared-utils/Object3DHelper/utils/calculateScaleByCamera.d.ts +4 -1
- package/libs/shared-utils/Object3DHelper/utils/calculateScaleByCamera.js +4 -4
- package/libs/shared-utils/five/FiveDomEvents.js +88 -88
- package/libs/shared-utils/five/FiveLine.d.ts +18 -14
- package/libs/shared-utils/five/FiveLine.js +31 -13
- package/libs/shared-utils/five/index.js +2 -7
- package/libs/shared-utils/five/lookObject.js +27 -32
- package/libs/shared-utils/index.d.ts +0 -1
- package/libs/shared-utils/index.js +31 -33
- package/libs/shared-utils/logger.js +1 -1
- package/libs/shared-utils/math/planimetry.d.ts +1 -1
- package/libs/shared-utils/tag.d.ts +5 -7
- package/libs/shared-utils/tag.js +1 -1
- package/libs/shared-utils/three/boundingBox.d.ts +14 -20
- package/libs/shared-utils/three/core/LineGeometry.d.ts +13 -0
- package/libs/shared-utils/three/core/LineGeometry.js +26 -0
- package/libs/shared-utils/three/core/PrismGeometry.d.ts +14 -0
- package/libs/shared-utils/three/core/PrismGeometry.js +42 -0
- package/libs/shared-utils/three/earcut3D.js +5 -5
- package/libs/shared-utils/three/geometryUtil.d.ts +8 -0
- package/libs/shared-utils/three/geometryUtil.js +3 -1
- package/libs/shared-utils/three/getNormal.d.ts +5 -2
- package/libs/shared-utils/three/getNormal.js +6 -5
- package/libs/shared-utils/three/index.js +0 -5
- package/package.json +1 -1
- package/dist/Sculpt/Objects/Box/Editor.d.ts +0 -5
- package/dist/Sculpt/Objects/Circle/Editor.d.ts +0 -5
- package/dist/Sculpt/Objects/Cylinder/Editor.d.ts +0 -5
- package/dist/Sculpt/Objects/Prism/Editor.d.ts +0 -5
- package/dist/Sculpt/Objects/Rectangle/Editor.d.ts +0 -5
- package/dist/Sculpt/utils/getBetterNormal.d.ts +0 -2
- package/libs/Sculpt/Objects/Box/Editor.d.ts +0 -5
- package/libs/Sculpt/Objects/Box/Editor.js +0 -44
- package/libs/Sculpt/Objects/Circle/Editor.d.ts +0 -5
- package/libs/Sculpt/Objects/Circle/Editor.js +0 -9
- package/libs/Sculpt/Objects/Cylinder/Editor.d.ts +0 -5
- package/libs/Sculpt/Objects/Cylinder/Editor.js +0 -41
- package/libs/Sculpt/Objects/Prism/Editor.d.ts +0 -5
- package/libs/Sculpt/Objects/Prism/Editor.js +0 -44
- package/libs/Sculpt/Objects/Rectangle/Editor.d.ts +0 -5
- package/libs/Sculpt/Objects/Rectangle/Editor.js +0 -9
- package/libs/Sculpt/utils/getBetterNormal.d.ts +0 -2
- package/libs/Sculpt/utils/getBetterNormal.js +0 -8
- package/libs/vendor/three/build/three.module.js +0 -19336
- package/libs/vendor/three/examples/jsm/lines/LineGeometry.js +0 -28
- package/libs/vendor/three/examples/jsm/lines/LineSegmentsGeometry.js +0 -69
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
var x = Object.defineProperty;
|
|
2
2
|
var I = Object.getOwnPropertySymbols;
|
|
3
3
|
var D = Object.prototype.hasOwnProperty, E = Object.prototype.propertyIsEnumerable;
|
|
4
|
-
var c = (n, s, t) => s in n ? x(n, s, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[s] = t,
|
|
4
|
+
var c = (n, s, t) => s in n ? x(n, s, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[s] = t, m = (n, s) => {
|
|
5
5
|
for (var t in s || (s = {}))
|
|
6
6
|
D.call(s, t) && c(n, t, s[t]);
|
|
7
7
|
if (I)
|
|
@@ -9,11 +9,11 @@ var c = (n, s, t) => s in n ? x(n, s, { enumerable: !0, configurable: !0, writab
|
|
|
9
9
|
E.call(s, t) && c(n, t, s[t]);
|
|
10
10
|
return n;
|
|
11
11
|
};
|
|
12
|
-
var
|
|
13
|
-
import
|
|
12
|
+
var r = (n, s, t) => (c(n, typeof s != "symbol" ? s + "" : s, t), t);
|
|
13
|
+
import h from "./EditController.js";
|
|
14
14
|
import k from "./ViewController.js";
|
|
15
15
|
import T from "./WatchController.js";
|
|
16
|
-
import
|
|
16
|
+
import a from "./MixedController.js";
|
|
17
17
|
import { omit as G } from "../../shared-utils/filter.js";
|
|
18
18
|
import { Group as S } from "three";
|
|
19
19
|
import { Model as L } from "../Model/index.js";
|
|
@@ -27,20 +27,16 @@ import { Magnifier as V } from "../../shared-utils/three/Magnifier.js";
|
|
|
27
27
|
import "../../shared-utils/three/PointSelector/index.js";
|
|
28
28
|
import "three/examples/jsm/renderers/CSS3DRenderer";
|
|
29
29
|
import "@realsee/five/line";
|
|
30
|
-
import "../../vendor/three/examples/jsm/lines/LineGeometry.js";
|
|
31
30
|
import "../../shared-utils/three/core/Sphere.js";
|
|
32
31
|
import "animejs";
|
|
33
|
-
import { isTouchDevice as K } from "../../shared-utils/isTouchDevice.js";
|
|
34
32
|
import "../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
|
|
35
|
-
import "../../
|
|
36
|
-
import "../../Sculpt/utils/Modules/Global.js";
|
|
37
|
-
import "../../vendor/hotkeys-js/dist/hotkeys.esm.js";
|
|
38
|
-
import "../../Sculpt/utils/three/rayOnLine.js";
|
|
33
|
+
import { isTouchDevice as K } from "../../shared-utils/isTouchDevice.js";
|
|
39
34
|
import { Controller as H } from "../../base/BasePlugin.js";
|
|
40
35
|
import "../Model/line.js";
|
|
41
36
|
import "../../shared-utils/uuid.js";
|
|
42
37
|
import "../utils/line.js";
|
|
43
38
|
import "../../shared-utils/five/FiveLine.js";
|
|
39
|
+
import "../../shared-utils/isNil.js";
|
|
44
40
|
import "../utils/constants.js";
|
|
45
41
|
import "@realsee/five";
|
|
46
42
|
import "../utils/dom/distanceItem.js";
|
|
@@ -63,7 +59,6 @@ import "../utils/isIntersecting.js";
|
|
|
63
59
|
import "../utils/dom/areaDom.js";
|
|
64
60
|
import "../../shared-utils/three/geometryUtil.js";
|
|
65
61
|
import "hammerjs";
|
|
66
|
-
import "../../shared-utils/isNil.js";
|
|
67
62
|
import "../Modules/DeleteDom/index.js";
|
|
68
63
|
import "../Modules/DeleteDom/_Assets/delete.svg.js";
|
|
69
64
|
import "../Modules/DeleteDom/_Assets/delete_bg.png.js";
|
|
@@ -81,79 +76,37 @@ import "../../shared-utils/three/temp.js";
|
|
|
81
76
|
import "../../shared-utils/three/core/Raycaster.js";
|
|
82
77
|
import "../../shared-utils/dom/resizeObserver.js";
|
|
83
78
|
import "../../shared-utils/five/fiveEveryReadyListener.js";
|
|
84
|
-
import "../../vendor/three/examples/jsm/lines/LineSegmentsGeometry.js";
|
|
85
|
-
import "../../vendor/three/build/three.module.js";
|
|
86
|
-
import "../../Sculpt/typings/style.js";
|
|
87
|
-
import "../../Sculpt/utils/three/ColoredMesh.js";
|
|
88
|
-
import "../../Sculpt/utils/Modules/Cursor.js";
|
|
89
|
-
import "../../Object3DHelperPlugin/Controller.js";
|
|
90
|
-
import "../../shared-utils/Object3DHelper/Helper/MoveHelper.js";
|
|
91
|
-
import "../../shared-utils/Object3DHelper/Base/BaseHelper.js";
|
|
92
|
-
import "../../shared-utils/Object3DHelper/utils/setObjectQuaternion.js";
|
|
93
|
-
import "../../shared-utils/three/boundingBox.js";
|
|
94
|
-
import "../../shared-utils/Object3DHelper/Helper/Objects/ArrowGroup.js";
|
|
95
|
-
import "../../shared-utils/Object3DHelper/utils/direction.js";
|
|
96
|
-
import "../../shared-utils/Object3DHelper/Constants/color.js";
|
|
97
|
-
import "../../shared-utils/Object3DHelper/utils/calculateScaleByCamera.js";
|
|
98
|
-
import "../../CSS3DRenderPlugin/utils/three/CSS3DRender.js";
|
|
99
|
-
import "../../CSS3DRenderPlugin/utils/three/CSS3DRenderer.js";
|
|
100
|
-
import "../../CSS3DRenderPlugin/utils/three/THREEJS_CSS3DRenderer.js";
|
|
101
|
-
import "../../CSS3DRenderPlugin/utils/createResizeObserver.js";
|
|
102
|
-
import "../../CSS3DRenderPlugin/utils/even.js";
|
|
103
|
-
import "../../CSS3DRenderPlugin/utils/three/CSS3DObject.js";
|
|
104
|
-
import "../../CSS3DRenderPlugin/utils/three/OpacityMesh.js";
|
|
105
|
-
import "../../shared-utils/three/getObjectVisible.js";
|
|
106
79
|
import "../../shared-utils/three/PointSelector/utils/PointSelectorHelper.js";
|
|
107
80
|
import "../../shared-utils/three/PointSelector/utils/PointHelper.js";
|
|
108
81
|
import "../../shared-utils/three/Assets/index.js";
|
|
82
|
+
import "../../CSS3DRenderPlugin/utils/three/CSS3DObject.js";
|
|
83
|
+
import "../../CSS3DRenderPlugin/utils/even.js";
|
|
84
|
+
import "../../CSS3DRenderPlugin/utils/three/OpacityMesh.js";
|
|
85
|
+
import "../../shared-utils/three/getObjectVisible.js";
|
|
109
86
|
import "../../shared-utils/three/PointSelector/utils/html.js";
|
|
110
87
|
import "../../shared-utils/five/initialCSS3DRender.js";
|
|
88
|
+
import "../../CSS3DRenderPlugin/utils/three/CSS3DRenderer.js";
|
|
89
|
+
import "../../CSS3DRenderPlugin/utils/three/THREEJS_CSS3DRenderer.js";
|
|
90
|
+
import "../../CSS3DRenderPlugin/utils/createResizeObserver.js";
|
|
111
91
|
import "../../shared-utils/three/PointSelector/utils/PointHelper2.js";
|
|
112
92
|
import "../../Sculpt/Meshes/Line.js";
|
|
93
|
+
import "../../Sculpt/typings/style.js";
|
|
113
94
|
import "../../Sculpt/utils/removeAllTag.js";
|
|
114
95
|
import "../../Sculpt/utils/Meshes/getLengthHTML.js";
|
|
115
96
|
import "../../shared-utils/three/applyObjectMatrixWorld.js";
|
|
116
97
|
import "../../shared-utils/util.js";
|
|
98
|
+
import "../../shared-utils/three/core/LineGeometry.js";
|
|
117
99
|
import "../../CSS3DRenderPlugin/utils/three/CSS3DSprite.js";
|
|
118
100
|
import "../../shared-utils/five/getPosition.js";
|
|
119
101
|
import "../../shared-utils/five/getRaycasterByNdcPosition.js";
|
|
120
102
|
import "../../shared-utils/three/PointSelector/utils/contents.js";
|
|
121
|
-
import "../../shared-utils/url/absoluteUrl.js";
|
|
122
|
-
import "../../CSS3DRenderPlugin/utils/three/CSS3DScene.js";
|
|
123
|
-
import "../../CSS3DRenderPlugin/utils/getAllCSS3DObject.js";
|
|
124
|
-
import "../../CSS3DRenderPlugin/utils/three/CSS3DGroup.js";
|
|
125
|
-
import "../../shared-utils/Object3DHelper/Helper/RotateHelper.js";
|
|
126
|
-
import "../../shared-utils/Object3DHelper/Helper/HTML/tipsDom.js";
|
|
127
|
-
import "../../shared-utils/Object3DHelper/Helper/HTML/utils/createElement.js";
|
|
128
|
-
import "../../shared-utils/Object3DHelper/Helper/CSS3DScaleHelper.js";
|
|
129
|
-
import "../../shared-utils/Object3DHelper/Helper/HTML/rectangleScaleDom.js";
|
|
130
|
-
import "../../shared-utils/Object3DHelper/Helper/BoundingBoxHelper.js";
|
|
131
|
-
import "../../shared-utils/Object3DHelper/Controller/MoveController.js";
|
|
132
|
-
import "../../shared-utils/Object3DHelper/Base/BaseController.js";
|
|
133
|
-
import "../../shared-utils/threex/domevents/index.js";
|
|
134
|
-
import "../../shared-utils/Object3DHelper/utils/getMouseRaycaster.js";
|
|
135
|
-
import "../../shared-utils/Object3DHelper/utils/calculateThreeMouse.js";
|
|
136
|
-
import "../../Object3DHelperPlugin/FiveControllerWrapper.js";
|
|
137
|
-
import "../../shared-utils/Object3DHelper/index.js";
|
|
138
|
-
import "../../shared-utils/Object3DHelper/Controller/RotateController.js";
|
|
139
|
-
import "../../shared-utils/math/rad2Deg.js";
|
|
140
|
-
import "../../shared-utils/math/deg2Rad.js";
|
|
141
|
-
import "../../shared-utils/Object3DHelper/Controller/CSS3DScaleController.js";
|
|
142
|
-
import "../../shared-utils/Object3DHelper/Controller/RectangleScaleController.js";
|
|
143
|
-
import "../../shared-utils/Object3DHelper/utils/vectorIsEqual.js";
|
|
144
|
-
import "../../CSS3DRenderPlugin/utils/generateBehindFiveElement.js";
|
|
145
|
-
import "../../shared-utils/Object3DHelper/Controller/BoundingBoxController.js";
|
|
146
|
-
import "../../shared-utils/Object3DHelper/Helper/ScaleHelper.js";
|
|
147
|
-
import "../../shared-utils/Object3DHelper/Controller/ScaleController.js";
|
|
148
|
-
import "../../shared-utils/five/fiveModelLoad.js";
|
|
149
|
-
import "../../shared-utils/five/FiveDomEvents.js";
|
|
150
|
-
import "../../shared-utils/five/calculateThreeMouse.js";
|
|
151
103
|
import "../utils/findClosestPoint.js";
|
|
152
104
|
import "../utils/ndc2Screen.js";
|
|
153
105
|
import "../../shared-utils/getPointFromHammerEvent.js";
|
|
154
106
|
import "../Modules/rangePiece/index.js";
|
|
155
107
|
import "../../shared-utils/animationFrame/index.js";
|
|
156
108
|
import "../../shared-utils/noop.js";
|
|
109
|
+
import "../../shared-utils/five/calculateThreeMouse.js";
|
|
157
110
|
import "../../shared-utils/tap.js";
|
|
158
111
|
import "../Modules/UIController/HTML.js";
|
|
159
112
|
import "../Modules/UIController/mobileHTML.js";
|
|
@@ -173,85 +126,86 @@ import "../../vendor/svelte/transition/index.js";
|
|
|
173
126
|
import "../../vendor/svelte/easing/index.js";
|
|
174
127
|
import "../../vendor/object-assign-deep/objectAssignDeep.js";
|
|
175
128
|
import "../Components/Tip.js";
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
129
|
+
import "../../shared-utils/url/absoluteUrl.js";
|
|
130
|
+
class Ye extends H {
|
|
131
|
+
constructor(t, e) {
|
|
132
|
+
var l, u, d, f, g, y, C, M, w, P, b, v;
|
|
179
133
|
super(t);
|
|
180
|
-
|
|
181
|
-
|
|
134
|
+
r(this, "state", { enabled: !0 });
|
|
135
|
+
r(this, "hasOpen", !1);
|
|
182
136
|
/** @deprecated use hooks instead */
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
137
|
+
r(this, "hook");
|
|
138
|
+
r(this, "magnifier");
|
|
139
|
+
r(this, "controller", null);
|
|
186
140
|
/** 允许的测量类型 */
|
|
187
|
-
|
|
141
|
+
r(this, "allowMeasureType");
|
|
188
142
|
/** 当前的测量类型 */
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
143
|
+
r(this, "currentMeasureType");
|
|
144
|
+
r(this, "model");
|
|
145
|
+
r(this, "group");
|
|
146
|
+
r(this, "config");
|
|
147
|
+
r(this, "isMobile");
|
|
148
|
+
r(this, "useUIController");
|
|
149
|
+
r(this, "params");
|
|
150
|
+
r(this, "useGuideController");
|
|
151
|
+
r(this, "container", document.createElement("div"));
|
|
152
|
+
r(this, "shortcutKeyController");
|
|
199
153
|
/** 关闭插件功能
|
|
200
154
|
* @description 清除标尺线条
|
|
201
155
|
* @description 还原点位展示和默认鼠标 UI
|
|
202
156
|
*/
|
|
203
|
-
|
|
204
|
-
var t,
|
|
205
|
-
this.hasOpen = !1, this.state.enabled = !1, this.container.style.visibility = "hidden", this.container.style.opacity = "0", (t = this.controller) == null || t.dispose(), (
|
|
157
|
+
r(this, "disable", () => {
|
|
158
|
+
var t, e, i, o;
|
|
159
|
+
this.hasOpen = !1, this.state.enabled = !1, this.container.style.visibility = "hidden", this.container.style.opacity = "0", (t = this.controller) == null || t.dispose(), (e = this.useUIController) == null || e.hide(), (i = this.useGuideController) == null || i.hide(), (o = this.shortcutKeyController) == null || o.dispose(), this.controller = null, this.five.helperVisible = !0, this.five.scene.remove(this.group), this.five.needsRender = !0, this.hook.emit("disable", !0);
|
|
206
160
|
});
|
|
207
|
-
|
|
161
|
+
r(this, "getCurrentMode", () => this.controller instanceof h ? "Edit" : this.controller instanceof T ? "Watch" : this.controller instanceof a ? "Mixed" : this.controller instanceof k ? "View" : null);
|
|
208
162
|
/** 变更场景
|
|
209
163
|
* @description 如果从编辑场景改变到观看场景,不会自动保存,默认丢弃所有改动
|
|
210
164
|
*/
|
|
211
|
-
|
|
165
|
+
r(this, "changeMode", (t) => {
|
|
212
166
|
var o;
|
|
213
167
|
if (!this.hasOpen || this.getCurrentMode() === t)
|
|
214
168
|
return;
|
|
215
169
|
(o = this.controller) == null || o.dispose();
|
|
216
|
-
const
|
|
170
|
+
const e = {
|
|
217
171
|
View: k,
|
|
218
172
|
Watch: T,
|
|
219
|
-
Edit:
|
|
220
|
-
Mixed:
|
|
173
|
+
Edit: h,
|
|
174
|
+
Mixed: a
|
|
221
175
|
};
|
|
222
|
-
if (!
|
|
176
|
+
if (!e[t])
|
|
223
177
|
throw new Error("不存在的 Mode");
|
|
224
|
-
const
|
|
225
|
-
this.controller = new
|
|
178
|
+
const i = this.createControllerParams();
|
|
179
|
+
this.controller = new e[t](i), this.hook.emit("modeChange", t);
|
|
226
180
|
});
|
|
227
181
|
/**
|
|
228
182
|
* @description: 切换测量的类型
|
|
229
183
|
*/
|
|
230
|
-
|
|
184
|
+
r(this, "changeMeasureType", (t) => {
|
|
231
185
|
this.currentMeasureType = t, this.hook.emit("measureTypeChange", t);
|
|
232
186
|
});
|
|
233
|
-
this.five = t, this.hook = this.hooks, this.params =
|
|
187
|
+
this.five = t, this.hook = this.hooks, this.params = e, this.config = G(e, ["openParams", "magnifierParams"]), this.model = new L(this.config), this.isMobile = (u = (l = e == null ? void 0 : e.openParams) == null ? void 0 : l.isMobile) != null ? u : !1, this.magnifier = new V(
|
|
234
188
|
t,
|
|
235
|
-
(y = (g =
|
|
236
|
-
), this.allowMeasureType = Array.from(new Set((M = (C =
|
|
237
|
-
const
|
|
189
|
+
(y = (g = e.magnifierParams) != null ? g : (f = (d = e.pointSelectorConfig) == null ? void 0 : d.helper) == null ? void 0 : f.magnifierParams) != null ? y : { width: 190, height: 190, scale: 2 }
|
|
190
|
+
), this.allowMeasureType = Array.from(new Set((M = (C = e.editParams) == null ? void 0 : C.allowMeasureType) != null ? M : ["line"])), this.currentMeasureType = (w = this.allowMeasureType[0]) != null ? w : "line", this.group = new S(), this.group.name = "plugin-measure-group", this.container.classList.add("five-plugin-measure-container"), this.container.style.position = "absolute", this.container.style.left = "0", this.container.style.top = "0", this.container.style.visibility = "hidden", this.container.style.width = "100%", this.container.style.height = "100%", this.container.style.opacity = "0", this.container.style.zIndex = "1";
|
|
191
|
+
const i = (b = (P = e.editParams) == null ? void 0 : P.pointSelectorMode) != null ? b : K ? "fixed" : "cursor", o = (v = this.params.openParams) != null ? v : {};
|
|
238
192
|
if (this.params.useUIController !== !1) {
|
|
239
|
-
const
|
|
193
|
+
const p = m({
|
|
240
194
|
container: this.container,
|
|
241
195
|
openParams: o,
|
|
242
|
-
i18n:
|
|
243
|
-
pointSelectorMode:
|
|
196
|
+
i18n: e.i18n,
|
|
197
|
+
pointSelectorMode: i,
|
|
244
198
|
useNewUI: this.allowMeasureType.length > 1
|
|
245
199
|
}, U(this.params.useUIController));
|
|
246
|
-
this.useUIController = new W(this,
|
|
200
|
+
this.useUIController = new W(this, p);
|
|
247
201
|
}
|
|
248
202
|
if (this.params.useGuideController !== !1) {
|
|
249
|
-
const
|
|
203
|
+
const p = m({
|
|
250
204
|
container: this.container,
|
|
251
|
-
pointSelectorMode:
|
|
252
|
-
i18n:
|
|
205
|
+
pointSelectorMode: i,
|
|
206
|
+
i18n: e.i18n
|
|
253
207
|
}, U(this.params.useGuideController));
|
|
254
|
-
this.useGuideController = new A(this,
|
|
208
|
+
this.useGuideController = new A(this, p);
|
|
255
209
|
}
|
|
256
210
|
}
|
|
257
211
|
appendTo(t) {
|
|
@@ -261,8 +215,8 @@ class Rr extends H {
|
|
|
261
215
|
this.model.clear();
|
|
262
216
|
}
|
|
263
217
|
dispose() {
|
|
264
|
-
var t,
|
|
265
|
-
this.disable(), this.clear(), (t = this.useUIController) == null || t.dispose(), (
|
|
218
|
+
var t, e;
|
|
219
|
+
this.disable(), this.clear(), (t = this.useUIController) == null || t.dispose(), (e = this.magnifier) == null || e.dispose(), this.five.needsRender = !0;
|
|
266
220
|
}
|
|
267
221
|
/** 加载数据
|
|
268
222
|
* @description 数据加载时会覆盖当前已保存的数据
|
|
@@ -276,18 +230,18 @@ class Rr extends H {
|
|
|
276
230
|
* @description 会隐藏当前 VR 内的点位展示
|
|
277
231
|
*/
|
|
278
232
|
enable(t) {
|
|
279
|
-
var
|
|
280
|
-
this.hasOpen || (this.state.enabled = !0, this.hasOpen = !0, this.group.matrix.copy(this.workUtil.transform), this.group.matrix.decompose(this.group.position, this.group.quaternion, this.group.scale), this.group.updateMatrixWorld(), this.five.scene.add(this.group), this.container.style.visibility = "visible", this.container.style.opacity = "1", t != null && t.mode ? this.changeMode(t.mode) : this.isMobile ? this.changeMode("Mixed") : this.changeMode("Watch"), (
|
|
233
|
+
var e, i;
|
|
234
|
+
this.hasOpen || (this.state.enabled = !0, this.hasOpen = !0, this.group.matrix.copy(this.workUtil.transform), this.group.matrix.decompose(this.group.position, this.group.quaternion, this.group.scale), this.group.updateMatrixWorld(), this.five.scene.add(this.group), this.container.style.visibility = "visible", this.container.style.opacity = "1", t != null && t.mode ? this.changeMode(t.mode) : this.isMobile ? this.changeMode("Mixed") : this.changeMode("Watch"), (e = this.useUIController) == null || e.show(), (i = this.useGuideController) == null || i.show(), this.shortcutKeyController = new B(this, this.five), this.hook.emit("enable", !0));
|
|
281
235
|
}
|
|
282
236
|
/** 进入编辑模式 */
|
|
283
237
|
edit(t) {
|
|
284
238
|
t && this.changeMeasureType(t);
|
|
285
|
-
const
|
|
286
|
-
this.changeMode(
|
|
239
|
+
const e = this.isMobile ? "Mixed" : "Edit";
|
|
240
|
+
this.changeMode(e);
|
|
287
241
|
}
|
|
288
242
|
/** 撤销编辑 */
|
|
289
243
|
revoke() {
|
|
290
|
-
this.controller instanceof
|
|
244
|
+
this.controller instanceof h && this.controller.revoke();
|
|
291
245
|
}
|
|
292
246
|
removePolyline(t) {
|
|
293
247
|
this.model.removePolyline(t);
|
|
@@ -296,8 +250,8 @@ class Rr extends H {
|
|
|
296
250
|
this.model.removeArea(t);
|
|
297
251
|
}
|
|
298
252
|
removePolylineByID(t) {
|
|
299
|
-
const
|
|
300
|
-
|
|
253
|
+
const e = this.model.getPolylineByID(t);
|
|
254
|
+
e && this.model.removePolyline(e);
|
|
301
255
|
}
|
|
302
256
|
getPolylineByID(t) {
|
|
303
257
|
return this.model.getPolylineByID(t);
|
|
@@ -310,8 +264,8 @@ class Rr extends H {
|
|
|
310
264
|
highlightLine(t) {
|
|
311
265
|
if (this.getCurrentMode() !== "Watch")
|
|
312
266
|
return !1;
|
|
313
|
-
const
|
|
314
|
-
return
|
|
267
|
+
const e = this.model.getLineByID(t);
|
|
268
|
+
return e ? (this.controller.highlightLine(e), !0) : !1;
|
|
315
269
|
}
|
|
316
270
|
clearHighlightLines() {
|
|
317
271
|
return this.getCurrentMode() !== "Watch" ? !1 : (this.controller.clearHighlightLines(), !0);
|
|
@@ -321,20 +275,20 @@ class Rr extends H {
|
|
|
321
275
|
*/
|
|
322
276
|
save(t) {
|
|
323
277
|
var o;
|
|
324
|
-
if (!(this.controller instanceof
|
|
278
|
+
if (!(this.controller instanceof h) && !(this.controller instanceof a))
|
|
325
279
|
return this;
|
|
326
|
-
const
|
|
327
|
-
return this.controller instanceof
|
|
328
|
-
|
|
329
|
-
}), this.changeMode(
|
|
280
|
+
const e = (o = t == null ? void 0 : t.mode) != null ? o : "View", i = this.controller.model.areas;
|
|
281
|
+
return this.controller instanceof h ? this.controller.complete() : i.forEach((l) => {
|
|
282
|
+
l.showArea(), this.model.addArea(l);
|
|
283
|
+
}), this.changeMode(e), this;
|
|
330
284
|
}
|
|
331
285
|
/** Mixed 模式才有用,添加起点 */
|
|
332
286
|
addStartPoint() {
|
|
333
|
-
this.controller instanceof
|
|
287
|
+
this.controller instanceof a && this.hook.emit("willChangeState", "watching", "editing");
|
|
334
288
|
}
|
|
335
289
|
/** Mixed 模式才有用,添加终点 */
|
|
336
290
|
addEndPoint() {
|
|
337
|
-
this.controller instanceof
|
|
291
|
+
this.controller instanceof a && this.hook.emit("willChangeState", "editing", "watching");
|
|
338
292
|
}
|
|
339
293
|
/** 导出数据 */
|
|
340
294
|
toJson() {
|
|
@@ -348,20 +302,20 @@ class Rr extends H {
|
|
|
348
302
|
changeIsMobile(t) {
|
|
349
303
|
}
|
|
350
304
|
changeConfigs(t) {
|
|
351
|
-
var
|
|
352
|
-
Object.assign(this.config, t), (
|
|
305
|
+
var e, i;
|
|
306
|
+
Object.assign(this.config, t), (e = this.controller) == null || e.updateDistanceUI(), (i = this.controller) == null || i.updateAreaUI();
|
|
353
307
|
}
|
|
354
308
|
/** 设置线段的文本 */
|
|
355
|
-
setCustomText(t,
|
|
309
|
+
setCustomText(t, e) {
|
|
356
310
|
var o;
|
|
357
|
-
const
|
|
358
|
-
if (!
|
|
311
|
+
const i = this.model.getLineByID(t);
|
|
312
|
+
if (!i)
|
|
359
313
|
throw new Error("不存在的线段");
|
|
360
|
-
|
|
314
|
+
i.setText(e), (o = this.controller) == null || o.updateDistanceUI();
|
|
361
315
|
}
|
|
362
316
|
createControllerParams() {
|
|
363
|
-
var
|
|
364
|
-
const t = (
|
|
317
|
+
var i, o;
|
|
318
|
+
const t = (i = this.params.openParams) != null ? i : {}, e = (o = this.params.editParams) != null ? o : {};
|
|
365
319
|
return t.isMobile = this.isMobile, {
|
|
366
320
|
five: this.five,
|
|
367
321
|
hook: this.hook,
|
|
@@ -372,15 +326,15 @@ class Rr extends H {
|
|
|
372
326
|
container: this.container,
|
|
373
327
|
workUtil: this.workUtil,
|
|
374
328
|
openParams: t,
|
|
375
|
-
editParams:
|
|
329
|
+
editParams: e,
|
|
376
330
|
pointSelectorConfig: this.params.pointSelectorConfig,
|
|
377
331
|
magnifierParams: this.params.magnifierParams,
|
|
378
332
|
getMeasureType: () => this.currentMeasureType,
|
|
379
|
-
mouseGroup: O(
|
|
333
|
+
mouseGroup: O(m({}, t.crossHairParameter)),
|
|
380
334
|
userDistanceItemCreator: this.params.userDistanceItemCreator
|
|
381
335
|
};
|
|
382
336
|
}
|
|
383
337
|
}
|
|
384
338
|
export {
|
|
385
|
-
|
|
339
|
+
Ye as default
|
|
386
340
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as THREE from 'three';
|
|
2
2
|
import { Subscribe, type Five, type SubscribeEventMap } from '@realsee/five';
|
|
3
|
-
import PolygonMesh from './polygon';
|
|
3
|
+
import { PolygonMesh } from './polygon';
|
|
4
4
|
import { Polyline } from './polyline';
|
|
5
5
|
import type { Model } from '.';
|
|
6
6
|
import { AreaItem } from '../utils/dom/areaDom';
|
|
@@ -1,17 +1,18 @@
|
|
|
1
1
|
var l = Object.defineProperty;
|
|
2
|
-
var d = (
|
|
3
|
-
var i = (
|
|
4
|
-
import * as
|
|
2
|
+
var d = (o, t, e) => t in o ? l(o, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : o[t] = e;
|
|
3
|
+
var i = (o, t, e) => (d(o, typeof t != "symbol" ? t + "" : t, e), e);
|
|
4
|
+
import * as m from "three";
|
|
5
5
|
import { uuid as f } from "../../shared-utils/uuid.js";
|
|
6
6
|
import { Subscribe as c } from "@realsee/five";
|
|
7
7
|
import u from "./line.js";
|
|
8
|
-
import v from "./polygon.js";
|
|
8
|
+
import { PolygonMesh as v } from "./polygon.js";
|
|
9
9
|
import { Polyline as y } from "./polyline.js";
|
|
10
10
|
import n from "./point.js";
|
|
11
11
|
import { AreaItem as C } from "../utils/dom/areaDom.js";
|
|
12
12
|
import "../utils/line.js";
|
|
13
13
|
import "../../shared-utils/five/FiveLine.js";
|
|
14
14
|
import "@realsee/five/line";
|
|
15
|
+
import "../../shared-utils/isNil.js";
|
|
15
16
|
import "../utils/constants.js";
|
|
16
17
|
import "../utils/dom/distanceItem.js";
|
|
17
18
|
import "../utils/dom/base.js";
|
|
@@ -49,79 +50,29 @@ import "three/examples/jsm/renderers/CSS3DRenderer";
|
|
|
49
50
|
import "../../CSS3DRenderPlugin/utils/even.js";
|
|
50
51
|
import "../../CSS3DRenderPlugin/utils/three/OpacityMesh.js";
|
|
51
52
|
import "../../shared-utils/three/getObjectVisible.js";
|
|
52
|
-
import "../../vendor/three/examples/jsm/lines/LineGeometry.js";
|
|
53
|
-
import "../../vendor/three/examples/jsm/lines/LineSegmentsGeometry.js";
|
|
54
|
-
import "../../vendor/three/build/three.module.js";
|
|
55
53
|
import "../../shared-utils/three/core/Sphere.js";
|
|
56
54
|
import "animejs";
|
|
57
|
-
import "../../shared-utils/isNil.js";
|
|
58
55
|
import "../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
|
|
59
|
-
import "../../
|
|
60
|
-
import "../../
|
|
61
|
-
import "../../Sculpt/utils/three/ColoredMesh.js";
|
|
62
|
-
import "../../Sculpt/utils/Modules/Global.js";
|
|
63
|
-
import "../../Sculpt/utils/Modules/Cursor.js";
|
|
64
|
-
import "../../Object3DHelperPlugin/Controller.js";
|
|
65
|
-
import "../../base/BasePlugin.js";
|
|
66
|
-
import "../../shared-utils/url/absoluteUrl.js";
|
|
67
|
-
import "../../vendor/hotkeys-js/dist/hotkeys.esm.js";
|
|
68
|
-
import "../../Sculpt/utils/three/rayOnLine.js";
|
|
69
|
-
import "../../shared-utils/Object3DHelper/Helper/MoveHelper.js";
|
|
70
|
-
import "../../shared-utils/Object3DHelper/Base/BaseHelper.js";
|
|
71
|
-
import "../../shared-utils/Object3DHelper/utils/setObjectQuaternion.js";
|
|
72
|
-
import "../../shared-utils/three/boundingBox.js";
|
|
73
|
-
import "../../shared-utils/Object3DHelper/Helper/Objects/ArrowGroup.js";
|
|
74
|
-
import "../../shared-utils/Object3DHelper/utils/direction.js";
|
|
75
|
-
import "../../shared-utils/Object3DHelper/Constants/color.js";
|
|
76
|
-
import "../../shared-utils/Object3DHelper/utils/calculateScaleByCamera.js";
|
|
77
|
-
import "../../CSS3DRenderPlugin/utils/three/CSS3DRender.js";
|
|
56
|
+
import "../../shared-utils/three/PointSelector/utils/html.js";
|
|
57
|
+
import "../../shared-utils/five/initialCSS3DRender.js";
|
|
78
58
|
import "../../CSS3DRenderPlugin/utils/three/CSS3DRenderer.js";
|
|
79
59
|
import "../../CSS3DRenderPlugin/utils/three/THREEJS_CSS3DRenderer.js";
|
|
80
60
|
import "../../CSS3DRenderPlugin/utils/createResizeObserver.js";
|
|
81
|
-
import "../../CSS3DRenderPlugin/utils/three/CSS3DScene.js";
|
|
82
|
-
import "../../CSS3DRenderPlugin/utils/getAllCSS3DObject.js";
|
|
83
|
-
import "../../shared-utils/util.js";
|
|
84
|
-
import "../../CSS3DRenderPlugin/utils/three/CSS3DGroup.js";
|
|
85
|
-
import "../../shared-utils/three/PointSelector/utils/html.js";
|
|
86
|
-
import "../../shared-utils/five/initialCSS3DRender.js";
|
|
87
61
|
import "../../shared-utils/three/PointSelector/utils/PointHelper2.js";
|
|
88
62
|
import "../../Sculpt/Meshes/Line.js";
|
|
63
|
+
import "../../Sculpt/typings/style.js";
|
|
89
64
|
import "../../Sculpt/utils/removeAllTag.js";
|
|
90
65
|
import "../../Sculpt/utils/Meshes/getLengthHTML.js";
|
|
91
66
|
import "../../shared-utils/three/applyObjectMatrixWorld.js";
|
|
67
|
+
import "../../shared-utils/util.js";
|
|
68
|
+
import "../../shared-utils/three/core/LineGeometry.js";
|
|
92
69
|
import "../../CSS3DRenderPlugin/utils/three/CSS3DSprite.js";
|
|
93
|
-
import "../../shared-utils/Object3DHelper/Helper/RotateHelper.js";
|
|
94
|
-
import "../../shared-utils/Object3DHelper/Helper/HTML/tipsDom.js";
|
|
95
|
-
import "../../shared-utils/Object3DHelper/Helper/HTML/utils/createElement.js";
|
|
96
|
-
import "../../shared-utils/Object3DHelper/Helper/CSS3DScaleHelper.js";
|
|
97
|
-
import "../../shared-utils/Object3DHelper/Helper/HTML/rectangleScaleDom.js";
|
|
98
|
-
import "../../shared-utils/Object3DHelper/Helper/BoundingBoxHelper.js";
|
|
99
|
-
import "../../shared-utils/Object3DHelper/Controller/MoveController.js";
|
|
100
|
-
import "../../shared-utils/Object3DHelper/Base/BaseController.js";
|
|
101
|
-
import "../../shared-utils/threex/domevents/index.js";
|
|
102
|
-
import "../../shared-utils/Object3DHelper/utils/getMouseRaycaster.js";
|
|
103
|
-
import "../../shared-utils/Object3DHelper/utils/calculateThreeMouse.js";
|
|
104
|
-
import "../../Object3DHelperPlugin/FiveControllerWrapper.js";
|
|
105
|
-
import "../../shared-utils/Object3DHelper/index.js";
|
|
106
|
-
import "../../shared-utils/Object3DHelper/Controller/RotateController.js";
|
|
107
|
-
import "../../shared-utils/math/rad2Deg.js";
|
|
108
|
-
import "../../shared-utils/math/deg2Rad.js";
|
|
109
|
-
import "../../shared-utils/Object3DHelper/Controller/CSS3DScaleController.js";
|
|
110
|
-
import "../../shared-utils/Object3DHelper/Controller/RectangleScaleController.js";
|
|
111
|
-
import "../../shared-utils/Object3DHelper/utils/vectorIsEqual.js";
|
|
112
|
-
import "../../CSS3DRenderPlugin/utils/generateBehindFiveElement.js";
|
|
113
|
-
import "../../shared-utils/Object3DHelper/Controller/BoundingBoxController.js";
|
|
114
|
-
import "../../shared-utils/Object3DHelper/Helper/ScaleHelper.js";
|
|
115
|
-
import "../../shared-utils/Object3DHelper/Controller/ScaleController.js";
|
|
116
|
-
import "../../shared-utils/five/fiveModelLoad.js";
|
|
117
|
-
import "../../shared-utils/five/FiveDomEvents.js";
|
|
118
|
-
import "../../shared-utils/five/calculateThreeMouse.js";
|
|
119
70
|
import "../../shared-utils/isTouchDevice.js";
|
|
120
71
|
import "../../shared-utils/five/getPosition.js";
|
|
121
72
|
import "../../shared-utils/five/getRaycasterByNdcPosition.js";
|
|
122
73
|
import "../../shared-utils/three/PointSelector/utils/contents.js";
|
|
123
|
-
class
|
|
124
|
-
constructor(t,
|
|
74
|
+
class Lt {
|
|
75
|
+
constructor(t, e) {
|
|
125
76
|
i(this, "id", f());
|
|
126
77
|
i(this, "selected", !1);
|
|
127
78
|
i(this, "text");
|
|
@@ -149,14 +100,14 @@ class Si {
|
|
|
149
100
|
i(this, "updateDom", () => {
|
|
150
101
|
this.five && (this.polyline.lines.forEach((t) => t.distanceItem.update(this.five)), this.areaItem.updateDomPosition(this.five));
|
|
151
102
|
});
|
|
152
|
-
var
|
|
153
|
-
t && (this.points = t), this.model =
|
|
103
|
+
var p;
|
|
104
|
+
t && (this.points = t), this.model = e.model, this.polygon = new v(t), this.polyline = new y({ model: e.model }), this.areaItem = new C({
|
|
154
105
|
area: this,
|
|
155
|
-
clickCallback: (
|
|
156
|
-
const a =
|
|
106
|
+
clickCallback: (r, s) => {
|
|
107
|
+
const a = r.clientX + "px", h = r.clientY + "px";
|
|
157
108
|
this.hook.emit("selected", this, { left: a, top: h });
|
|
158
109
|
}
|
|
159
|
-
}), this.domContainer =
|
|
110
|
+
}), this.domContainer = e.domContainer || null, this.meshContainer = e.meshContainer || null, this.five = e.five || null, this.areaItem.appendTo(this.domContainer), (p = this.five) == null || p.on("cameraUpdate", this.updateDom);
|
|
160
111
|
}
|
|
161
112
|
/**
|
|
162
113
|
* @description: 多边形的端点是否闭合
|
|
@@ -166,14 +117,14 @@ class Si {
|
|
|
166
117
|
return this.points.length >= 4 && ((t = this.points.at(0)) == null ? void 0 : t.equals(this.points.at(-1)));
|
|
167
118
|
}
|
|
168
119
|
addPoints(t) {
|
|
169
|
-
var
|
|
120
|
+
var r;
|
|
170
121
|
this.points = this.points.concat(t);
|
|
171
|
-
const
|
|
172
|
-
if (
|
|
173
|
-
const
|
|
174
|
-
this.polyline.addLine(
|
|
122
|
+
const e = this.points.at(-2), p = this.points.at(-1);
|
|
123
|
+
if (e && p) {
|
|
124
|
+
const s = new u(new n(e), new n(p), this.polyline.model);
|
|
125
|
+
this.polyline.addLine(s), this.meshContainer.add(s.mesh), this.five && (s.distanceItem.setCanSelect(!1), s.distanceItem.appendTo(this.domContainer), s.distanceItem.update(this.five));
|
|
175
126
|
}
|
|
176
|
-
(
|
|
127
|
+
(r = this.meshContainer) != null && r.children.includes(this.polygon) || this.meshContainer.add(this.polygon), this.polygon.updatePoints(this.points), this.areaItem.updateArea(this.five), this.points.length === 3 ? this.planeHelper = new m.Plane().setFromCoplanarPoints(this.points[0], this.points[1], this.points[2]) : this.points.length < 3 && (this.planeHelper = null);
|
|
177
128
|
}
|
|
178
129
|
/**
|
|
179
130
|
* @description: 移除最后一个添加的点
|
|
@@ -199,7 +150,7 @@ class Si {
|
|
|
199
150
|
* @description: 获取一个点投影在当前平面上的点
|
|
200
151
|
*/
|
|
201
152
|
projectPoint(t) {
|
|
202
|
-
return t && (this.planeHelper ? this.planeHelper.projectPoint(t, new
|
|
153
|
+
return t && (this.planeHelper ? this.planeHelper.projectPoint(t, new m.Vector3()) : t);
|
|
203
154
|
}
|
|
204
155
|
remove() {
|
|
205
156
|
this.polygon.removeFromParent(), this.areaItem.remove(), this.polyline.lines.forEach((t) => t.remove());
|
|
@@ -219,5 +170,5 @@ class Si {
|
|
|
219
170
|
}
|
|
220
171
|
}
|
|
221
172
|
export {
|
|
222
|
-
|
|
173
|
+
Lt as default
|
|
223
174
|
};
|
|
@@ -8,6 +8,7 @@ import "../../shared-utils/uuid.js";
|
|
|
8
8
|
import "../utils/line.js";
|
|
9
9
|
import "../../shared-utils/five/FiveLine.js";
|
|
10
10
|
import "@realsee/five/line";
|
|
11
|
+
import "../../shared-utils/isNil.js";
|
|
11
12
|
import "../utils/constants.js";
|
|
12
13
|
import "three";
|
|
13
14
|
import "@realsee/five";
|
|
@@ -16,7 +17,7 @@ import "../utils/dom/base.js";
|
|
|
16
17
|
import "../utils/isNDCPointInScreen.js";
|
|
17
18
|
import "../../shared-utils/three/centerPoint.js";
|
|
18
19
|
import "./point.js";
|
|
19
|
-
class
|
|
20
|
+
class B {
|
|
20
21
|
constructor(e) {
|
|
21
22
|
r(this, "config");
|
|
22
23
|
r(this, "polylines", []);
|
|
@@ -97,5 +98,5 @@ class x {
|
|
|
97
98
|
}
|
|
98
99
|
}
|
|
99
100
|
export {
|
|
100
|
-
|
|
101
|
+
B as Model
|
|
101
102
|
};
|
|
@@ -7,6 +7,7 @@ import { Subscribe as c } from "@realsee/five";
|
|
|
7
7
|
import { DistanceItem as d } from "../utils/dom/distanceItem.js";
|
|
8
8
|
import "../../shared-utils/five/FiveLine.js";
|
|
9
9
|
import "@realsee/five/line";
|
|
10
|
+
import "../../shared-utils/isNil.js";
|
|
10
11
|
import "../utils/constants.js";
|
|
11
12
|
import "three";
|
|
12
13
|
import "../utils/dom/base.js";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as THREE from 'three';
|
|
2
2
|
import { IObject3D } from '../../shared-utils/three/IObject3D';
|
|
3
3
|
export declare const blankGeometry: THREE.BufferGeometry;
|
|
4
|
-
export
|
|
4
|
+
export declare class PolygonMesh extends IObject3D {
|
|
5
5
|
readonly isPolygonMesh = true;
|
|
6
6
|
geometry: THREE.BufferGeometry;
|
|
7
7
|
isBlank: boolean;
|