@realsee/dnalogel 2.25.0 → 2.26.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/dist/CruisePlugin/typing.d.ts +1 -1
- package/dist/GuideLinePlugin/typing.d.ts +1 -1
- package/dist/PanoCompassPlugin/typings.d.ts +1 -1
- package/dist/PanoMeasurePlugin/Model/point.d.ts +0 -4
- package/dist/PanoMeasurePlugin/Model/polyline.d.ts +1 -1
- package/dist/PipelinePlugin/Controller.d.ts +108 -0
- package/dist/PipelinePlugin/index.d.ts +6 -0
- package/dist/PipelinePlugin/typing/PluginData.d.ts +20 -0
- package/dist/PipelinePlugin/typing/ServerData.d.ts +28 -0
- package/dist/PipelinePlugin/typing/index.d.ts +79 -0
- package/dist/PipelinePlugin/utils/Objects/FlowPipe.d.ts +34 -0
- package/dist/PipelinePlugin/utils/Objects/Pipe.d.ts +49 -0
- package/dist/PipelinePlugin/utils/formatData.d.ts +12 -0
- package/dist/base/BasePluginWithData.d.ts +3 -15
- package/dist/floorplan/PanoFloorplanRadarPlugin/typing.d.ts +1 -1
- package/dist/floorplan/typings/index.d.ts +1 -1
- package/dist/index.cjs.js +100 -65
- package/dist/index.d.ts +1 -0
- package/dist/index.js +9180 -8600
- package/dist/index.umd.js +89 -54
- package/dist/shared-utils/three/Extras/Core/Interpolations.d.ts +11 -0
- package/dist/shared-utils/three/Extras/Curves/BezierCurve3.d.ts +13 -0
- package/docs/assets/search.js +1 -1
- package/docs/classes/CSS3DRender.html +33 -30
- package/docs/classes/CruisePluginController.html +28 -25
- package/docs/classes/GuideLineItem.GuideLineItem.html +22 -19
- package/docs/classes/GuideLineModeItem.GuideLineModeItem.html +37 -34
- package/docs/classes/Magnifier.html +22 -19
- package/docs/classes/ModelRoomLabelController.html +13 -10
- package/docs/classes/Object3DHelperController.html +27 -24
- package/docs/classes/PaintBrush.html +17 -14
- package/docs/classes/PanoMeasurePluginLine.html +29 -26
- package/docs/classes/PanoMeasurePluginModel.html +29 -26
- package/docs/classes/PanoMeasurePluginPoint.html +14 -48
- package/docs/classes/PanoMeasurePluginPolyline.html +43 -32
- package/docs/classes/PanoTagPluginController.html +49 -46
- package/docs/classes/Util.BetterTween.html +11 -8
- package/docs/classes/Util.Interval.html +14 -11
- package/docs/classes/Util.Magnifier.html +22 -19
- package/docs/classes/Util.PointDomHelper.html +13 -10
- package/docs/classes/Util.PointHelper.html +13 -10
- package/docs/classes/Util.PointSelectorHelper.html +18 -15
- package/docs/classes/Util.Rectangle.html +15 -12
- package/docs/enums/CameraMovementEffect.html +9 -6
- package/docs/enums/ContentType.html +22 -19
- package/docs/enums/DIRECTION.html +11 -8
- package/docs/enums/DISPLAY_STRATEGY_TYPE.html +11 -8
- package/docs/enums/DimensionType.html +9 -6
- package/docs/enums/FLOOR_PLAN_ATTACHED_TO.html +10 -7
- package/docs/enums/ITEM_LABEL_PLUGIN_DISPLAY_STRATEGY_TYPE.html +11 -8
- package/docs/enums/PaintBrushTypeEnum.html +10 -7
- package/docs/enums/PointType.html +9 -6
- package/docs/enums/Rotation.html +10 -7
- package/docs/functions/CSS3DRenderPlugin.html +6 -3
- package/docs/functions/CameraMovementPlugin.html +6 -3
- package/docs/functions/CruisePlugin.html +6 -3
- package/docs/functions/GuideLinePlugin.html +7 -4
- package/docs/functions/ItemLabelPlugin.html +6 -3
- package/docs/functions/MapviewFloorplanPlugin.html +6 -3
- package/docs/functions/ModelChassisCompassPlugin.html +6 -3
- package/docs/functions/ModelEntryDoorGuidePlugin.html +6 -3
- package/docs/functions/ModelFloorplanPlugin.html +6 -3
- package/docs/functions/ModelItemLabelPlugin.html +6 -3
- package/docs/functions/ModelRoomLabelPlugin.html +6 -3
- package/docs/functions/ModelTVVideoPlugin.html +6 -3
- package/docs/functions/ModelViewPlugin.html +6 -3
- package/docs/functions/Object3DHelperPlugin.html +6 -3
- package/docs/functions/PanoCompassPlugin.html +6 -3
- package/docs/functions/PanoCursorRaycasterPlugin.html +6 -3
- package/docs/functions/PanoDoorLabelPlugin.html +6 -3
- package/docs/functions/PanoFloorplanRadarPlugin.html +6 -3
- package/docs/functions/PanoMeasurePlugin.html +6 -3
- package/docs/functions/PanoRulerPlugin.html +6 -3
- package/docs/functions/PanoRulerProPlugin.html +6 -3
- package/docs/functions/PanoSpatialTagPlugin.html +6 -3
- package/docs/functions/PanoTagPlugin.html +6 -3
- package/docs/functions/PanoVideoPlugin.html +6 -3
- package/docs/functions/PipelinePlugin.html +280 -0
- package/docs/functions/TopviewFloorplanPlugin.html +6 -3
- package/docs/functions/Util.absoluteUrl.html +7 -4
- package/docs/functions/Util.getCoordsFromClient.html +7 -4
- package/docs/functions/Util.getCoordsFromElement.html +7 -4
- package/docs/functions/Util.getFrameTime.html +7 -4
- package/docs/functions/Util.getIntersectFromRelativePosition.html +7 -4
- package/docs/functions/Util.getRaycasterFromFivePointer.html +7 -4
- package/docs/functions/Util.isAbsoluteURL.html +7 -4
- package/docs/functions/Util.isModelLike.html +7 -4
- package/docs/functions/Util.isNil.html +7 -4
- package/docs/functions/Util.isPanoramaLike.html +7 -4
- package/docs/functions/Util.nextFrame.html +7 -4
- package/docs/functions/Util.notNil.html +7 -4
- package/docs/functions/Util.requestAnimationFrameInterval.html +7 -4
- package/docs/functions/Util.tweenProgress.html +7 -4
- package/docs/functions/Util.uuid.html +7 -4
- package/docs/functions/pluginFlag.html +7 -4
- package/docs/index.html +7 -4
- package/docs/interfaces/AddTagConfig.html +8 -5
- package/docs/interfaces/CSS3DRenderPluginEventMap.html +13 -10
- package/docs/interfaces/CSS3DRenderPluginState.html +10 -7
- package/docs/interfaces/CameraMovementPluginExportType.html +9 -6
- package/docs/interfaces/CruisePluginTypes.Config.html +10 -7
- package/docs/interfaces/CruisePluginTypes.CruiseKeyframe.html +14 -11
- package/docs/interfaces/CruisePluginTypes.EventMap.html +22 -19
- package/docs/interfaces/CruisePluginTypes.MoveAction.html +14 -11
- package/docs/interfaces/CruisePluginTypes.MoveWithKeyframesAction.html +16 -13
- package/docs/interfaces/CruisePluginTypes.MoveWithPanoIndexAction.html +16 -13
- package/docs/interfaces/CruisePluginTypes.PluginData.html +11 -8
- package/docs/interfaces/CruisePluginTypes.PluginServerData.html +10 -21
- package/docs/interfaces/CruisePluginTypes.PluginState.html +13 -10
- package/docs/interfaces/EventMap.html +17 -14
- package/docs/interfaces/FloorplanBounding.html +10 -7
- package/docs/interfaces/FloorplanData.html +12 -9
- package/docs/interfaces/FloorplanEntrance.html +13 -10
- package/docs/interfaces/FloorplanExtraObject.html +12 -9
- package/docs/interfaces/FloorplanExtraObject3D.html +10 -7
- package/docs/interfaces/FloorplanFloorData.html +11 -8
- package/docs/interfaces/FloorplanImagePosition.html +9 -6
- package/docs/interfaces/FloorplanObserver.html +11 -8
- package/docs/interfaces/FloorplanOutlineItem.html +11 -8
- package/docs/interfaces/FloorplanPosition.html +9 -6
- package/docs/interfaces/FloorplanRoomItem.html +15 -12
- package/docs/interfaces/FloorplanRoomLabelItem.html +9 -6
- package/docs/interfaces/FloorplanServerBounding.html +10 -7
- package/docs/interfaces/FloorplanServerComputedData.html +12 -9
- package/docs/interfaces/FloorplanServerData.html +9 -6
- package/docs/interfaces/FloorplanServerDoorItem.html +12 -9
- package/docs/interfaces/FloorplanServerDoorPosition.html +10 -7
- package/docs/interfaces/FloorplanServerEntrance.html +13 -10
- package/docs/interfaces/FloorplanServerFloorData.html +11 -8
- package/docs/interfaces/FloorplanServerImagePosition.html +9 -6
- package/docs/interfaces/FloorplanServerObserver.html +11 -8
- package/docs/interfaces/FloorplanServerOutlineItem.html +11 -8
- package/docs/interfaces/FloorplanServerPosition.html +9 -6
- package/docs/interfaces/FloorplanServerRoomItem.html +16 -13
- package/docs/interfaces/FloorplanServerRoomLabelItem.html +9 -6
- package/docs/interfaces/GuideLineModeItem.GuideLineTagContainer.html +10 -7
- package/docs/interfaces/GuideLinePluginType.CatmullRomCurve3.html +12 -9
- package/docs/interfaces/GuideLinePluginType.EventMap.html +15 -12
- package/docs/interfaces/GuideLinePluginType.GuideLineGeometryStyle.html +10 -7
- package/docs/interfaces/GuideLinePluginType.GuideLineItemContainer.html +8 -5
- package/docs/interfaces/GuideLinePluginType.GuideLineMaterialStyle.html +15 -12
- package/docs/interfaces/GuideLinePluginType.LineGeometriesConfig.html +10 -7
- package/docs/interfaces/GuideLinePluginType.ModelGuideLineStyle.html +20 -17
- package/docs/interfaces/GuideLinePluginType.ModelGuideLineTagData.html +9 -6
- package/docs/interfaces/GuideLinePluginType.PanoramaGuideLineStyle.html +20 -17
- package/docs/interfaces/GuideLinePluginType.PluginDataV2.html +7 -4
- package/docs/interfaces/GuideLinePluginType.PluginServerData.html +10 -21
- package/docs/interfaces/GuideLinePluginType.PluginState.html +10 -7
- package/docs/interfaces/GuideLinePluginType.Route.html +13 -10
- package/docs/interfaces/GuideLinePluginType.RouteConfig.html +11 -8
- package/docs/interfaces/HelperOffset.html +10 -7
- package/docs/interfaces/ImagePlaneGroup.html +8 -5
- package/docs/interfaces/ItemLabelPluginData.html +8 -5
- package/docs/interfaces/ItemLabelPluginExportReturnsType.html +13 -10
- package/docs/interfaces/ItemLabelPluginParametersType.html +11 -8
- package/docs/interfaces/MinMax.html +9 -6
- package/docs/interfaces/ModelChassisCompassPluginData.html +9 -6
- package/docs/interfaces/ModelChassisCompassPluginExportType.html +10 -7
- package/docs/interfaces/ModelChassisCompassPluginParameterType.html +9 -6
- package/docs/interfaces/ModelEntryDoorGuidePluginData.html +10 -7
- package/docs/interfaces/ModelEntryDoorGuidePluginExportType.html +10 -7
- package/docs/interfaces/ModelItemLabelPluginData.html +8 -5
- package/docs/interfaces/ModelItemLabelPluginExportReturnsType.html +13 -10
- package/docs/interfaces/ModelItemLabelPluginParametersType.html +9 -6
- package/docs/interfaces/ModelRoomLabelPluginData.html +8 -5
- package/docs/interfaces/ModelTVVideoPluginData.html +11 -8
- package/docs/interfaces/ModelTVVideoPluginExportType.html +10 -7
- package/docs/interfaces/ModelTVVideoPluginParameterType.html +8 -5
- package/docs/interfaces/ModelViewPluginExportType.html +13 -10
- package/docs/interfaces/Object3DHelperState.html +10 -7
- package/docs/interfaces/ObjectHelperControllers.html +11 -8
- package/docs/interfaces/PaintBrushAction.html +14 -11
- package/docs/interfaces/PaintBrushConfigs.html +14 -11
- package/docs/interfaces/PaintBrushState.html +12 -9
- package/docs/interfaces/PanoCursorRaycasterPluginExportType.html +12 -9
- package/docs/interfaces/PanoCursorRaycasterPluginParameterType.html +7 -4
- package/docs/interfaces/PanoMeasureParameterType.html +18 -15
- package/docs/interfaces/PanoMeasurePluginLineJson.html +10 -7
- package/docs/interfaces/PanoMeasurePluginOpenParameter.html +9 -6
- package/docs/interfaces/PanoMeasurePluginPointJson.html +9 -6
- package/docs/interfaces/PanoMeasurePluginPolylineJson.html +10 -7
- package/docs/interfaces/PanoRulerPluginExportType.html +12 -9
- package/docs/interfaces/PanoRulerPluginOptions.html +9 -6
- package/docs/interfaces/PanoRulerPluginParameterType.html +10 -7
- package/docs/interfaces/PanoRulerProPluginExportType.html +11 -8
- package/docs/interfaces/PanoRulerProPluginOptions.html +9 -6
- package/docs/interfaces/PanoRulerProPluginParameterType.html +9 -6
- package/docs/interfaces/PanoRulerProPluginState.html +10 -7
- package/docs/interfaces/PanoSpatialTagPluginContentEvent.html +7 -4
- package/docs/interfaces/PanoSpatialTagPluginContentReplacement.html +7 -4
- package/docs/interfaces/PanoSpatialTagPluginData.html +13 -10
- package/docs/interfaces/PanoSpatialTagPluginDataElement.html +12 -9
- package/docs/interfaces/PanoSpatialTagPluginExportType.html +15 -12
- package/docs/interfaces/PanoSpatialTagPluginOriginElement.html +12 -9
- package/docs/interfaces/PanoSpatialTagPluginParameterType.html +15 -12
- package/docs/interfaces/PanoSpatialTagPluginPointElement.html +13 -10
- package/docs/interfaces/PanoSpatialTagPluginTagElement.html +12 -9
- package/docs/interfaces/PanoVideoPluginType.LoadParams.html +8 -5
- package/docs/interfaces/PanoVideoPluginType.PanoVideoItem.html +10 -7
- package/docs/interfaces/PanoVideoPluginType.PluginData.html +8 -5
- package/docs/interfaces/PanoVideoPluginType.PluginEventMap.html +11 -8
- package/docs/interfaces/PanoVideoPluginType.PluginState.html +8 -5
- package/docs/interfaces/PanoVideoPluginType.VideoItem.html +10 -7
- package/docs/interfaces/PanoVideoPluginType.VideoMeshParams.html +12 -9
- package/docs/interfaces/Point.html +10 -7
- package/docs/interfaces/Room.html +11 -8
- package/docs/interfaces/RoomInfo.html +9 -6
- package/docs/interfaces/RoomLabel.html +16 -13
- package/docs/interfaces/RoomRules.html +7 -4
- package/docs/interfaces/Rooms.html +7 -4
- package/docs/interfaces/Scissor.html +11 -8
- package/docs/interfaces/State.html +10 -7
- package/docs/interfaces/TagCacheInterface.html +14 -11
- package/docs/interfaces/TagConfig.html +15 -12
- package/docs/interfaces/TagGLTFObjectGroup.html +8 -5
- package/docs/interfaces/TagIconUrl.html +14 -11
- package/docs/interfaces/TagObjectGroup.html +8 -5
- package/docs/interfaces/TagStyle.html +8 -5
- package/docs/interfaces/Tags.html +11 -8
- package/docs/interfaces/TemporaryState.html +8 -5
- package/docs/interfaces/Util.MagnifierParameter.html +13 -10
- package/docs/interfaces/Util.MouseGroupParameter.html +10 -7
- package/docs/interfaces/Util.PointIntersection.html +10 -7
- package/docs/modules/CruisePluginTypes.html +7 -4
- package/docs/modules/GuideLineItem.html +7 -4
- package/docs/modules/GuideLineModeItem.html +7 -4
- package/docs/modules/GuideLinePluginType.html +7 -4
- package/docs/modules/PanoVideoPluginType.html +7 -4
- package/docs/modules/Util.html +7 -4
- package/docs/modules.html +10 -4
- package/docs/types/ArrayPosition.html +7 -4
- package/docs/types/AudioAppearance.html +7 -4
- package/docs/types/AudioTagTypeConfigKey.html +7 -4
- package/docs/types/CSS3DRenderExportType.html +7 -4
- package/docs/types/CSS3DRenderPluginExportType.html +7 -4
- package/docs/types/CSS3DRenderPluginParameterType.html +7 -4
- package/docs/types/ClassFunctionParameters.html +7 -4
- package/docs/types/Color.html +7 -4
- package/docs/types/ContentTypeConfigKey.html +7 -4
- package/docs/types/ContentTypeConfigKeySplit.html +7 -4
- package/docs/types/ContentTypeMap.html +7 -4
- package/docs/types/Create3DDomContainerReturnType.html +7 -4
- package/docs/types/Create3DElementReturnType.html +7 -4
- package/docs/types/CruisePluginExportType.html +7 -4
- package/docs/types/CruisePluginTypes.CruiseData.html +7 -4
- package/docs/types/CruisePluginTypes.MoveEffect.html +7 -4
- package/docs/types/DeprecatedMediaPlaneProperty.html +7 -4
- package/docs/types/DeprecatedTagProperty.html +7 -4
- package/docs/types/Direction-1.html +7 -4
- package/docs/types/Direction4.html +7 -4
- package/docs/types/ElementRenderer.html +7 -4
- package/docs/types/FloorplanRuleLabels.html +7 -4
- package/docs/types/FloorplanServerRuleLabels.html +7 -4
- package/docs/types/GuideLinePluginExportType.html +7 -4
- package/docs/types/GuideLinePluginType.GuideLineItem.html +7 -4
- package/docs/types/GuideLinePluginType.GuideLineItemEventMap.html +7 -4
- package/docs/types/GuideLinePluginType.GuideLineModeItemMode.html +7 -4
- package/docs/types/GuideLinePluginType.GuideLineStyle.html +7 -4
- package/docs/types/GuideLinePluginType.ModelGuideLineTag.html +7 -4
- package/docs/types/GuideLinePluginType.PathItem.html +7 -4
- package/docs/types/GuideLinePluginType.PluginData.html +7 -4
- package/docs/types/HelperEventMap.html +7 -4
- package/docs/types/LoadTagConfig.html +7 -4
- package/docs/types/MapviewFloorplanPluginParameterType.html +7 -4
- package/docs/types/MapviewFloorplanPluginReturnType.html +7 -4
- package/docs/types/MediaData.html +7 -4
- package/docs/types/MediaStore.html +7 -4
- package/docs/types/ModelEntryDoorGuidePluginParameterType.html +7 -4
- package/docs/types/ModelFloorplanPluginParameterType.html +7 -4
- package/docs/types/ModelFloorplanPluginReturnType.html +7 -4
- package/docs/types/ModelRoomLabelPluginParameters.html +7 -4
- package/docs/types/ModelRoomLabelPluginReturnType.html +7 -4
- package/docs/types/MoveArgs.html +7 -4
- package/docs/types/MoveOpts.html +7 -4
- package/docs/types/Object3DHelperEventMap.html +7 -4
- package/docs/types/ObjectFit.html +7 -4
- package/docs/types/PaintBrushEventMap.html +7 -4
- package/docs/types/PanoCompassPluginData.html +7 -4
- package/docs/types/PanoCompassPluginExportType.html +7 -4
- package/docs/types/PanoCompassPluginParameterType.html +7 -4
- package/docs/types/PanoFloorplanRadarPluginParameterType.html +7 -4
- package/docs/types/PanoFloorplanRadarPluginReturnType.html +7 -4
- package/docs/types/PanoIndex.html +7 -4
- package/docs/types/PanoMeasurePluginEvent.html +7 -4
- package/docs/types/PanoMeasureReturnType.html +7 -4
- package/docs/types/PanoSpatialTagPluginId.html +7 -4
- package/docs/types/PanoTagPluginExportInterface.html +7 -4
- package/docs/types/PanoTagPluginParamsInterface.html +7 -4
- package/docs/types/PanoVideoPluginParameterType.html +7 -4
- package/docs/types/PanoVideoPluginReturnType.html +7 -4
- package/docs/types/PickTagContentTypeInContentTypeConfigKey.html +7 -4
- package/docs/types/PipelinePluginParameterType.html +271 -0
- package/docs/types/PipelinePluginReturnType.html +271 -0
- package/docs/types/PlaneTag.html +7 -4
- package/docs/types/Point2DTag.html +7 -4
- package/docs/types/Point3DTag.html +7 -4
- package/docs/types/PointTag.html +7 -4
- package/docs/types/PointTagInstance.html +7 -4
- package/docs/types/Position.html +7 -4
- package/docs/types/RotateArgs.html +7 -4
- package/docs/types/RotateOpts.html +7 -4
- package/docs/types/RuleLabelsKey.html +7 -4
- package/docs/types/RuleLabelsValue.html +7 -4
- package/docs/types/StickType.html +7 -4
- package/docs/types/Tag.html +7 -4
- package/docs/types/Tag2D.html +7 -4
- package/docs/types/Tag3D.html +7 -4
- package/docs/types/TagContentType.html +7 -4
- package/docs/types/TagDimensionType.html +7 -4
- package/docs/types/TagElement.html +7 -4
- package/docs/types/TagEvents.html +7 -4
- package/docs/types/TagGLTFObject.html +7 -4
- package/docs/types/TagHooks.html +7 -4
- package/docs/types/TagId.html +7 -4
- package/docs/types/TagInstance.html +7 -4
- package/docs/types/TagPointType.html +7 -4
- package/docs/types/TagRendererMap.html +7 -4
- package/docs/types/TopviewFloorplanPluginParameterType.html +7 -4
- package/docs/types/TopviewFloorplanPluginReturnType.html +7 -4
- package/docs/types/WorkCode.html +7 -4
- package/docs/variables/FLOOR_TYPE_MAP.html +7 -4
- package/docs/variables/PLUGIN.html +7 -4
- package/docs/variables/ROOM_FETILE_TYPE_MAP.html +7 -4
- package/docs/variables/ROOM_TYPE_MAP.html +7 -4
- package/docs/variables/itemLabelPluginServerParams.html +7 -4
- package/docs/variables/modelItemLabelPluginServerParams.html +7 -4
- package/docs/variables/modelRoomLabelPluginServerParams.html +7 -4
- package/libs/CruisePlugin/typing.d.ts +1 -1
- package/libs/GuideLinePlugin/typing.d.ts +1 -1
- package/libs/PanoCompassPlugin/typings.d.ts +1 -1
- package/libs/PanoMeasurePlugin/Components/Controller0.js +2 -4
- package/libs/PanoMeasurePlugin/Components/Controller1.js +52 -54
- package/libs/PanoMeasurePlugin/Controller/BaseController.js +2 -3
- package/libs/PanoMeasurePlugin/Controller/EditController.js +5 -7
- package/libs/PanoMeasurePlugin/Controller/MixedController.js +14 -16
- package/libs/PanoMeasurePlugin/Controller/ViewController.js +2 -3
- package/libs/PanoMeasurePlugin/Controller/WatchController.js +41 -43
- package/libs/PanoMeasurePlugin/Controller/index.js +26 -30
- package/libs/PanoMeasurePlugin/Model/area.js +2 -3
- package/libs/PanoMeasurePlugin/Model/index.js +2 -3
- package/libs/PanoMeasurePlugin/Model/line.js +20 -20
- package/libs/PanoMeasurePlugin/Model/point.d.ts +0 -4
- package/libs/PanoMeasurePlugin/Model/point.js +12 -20
- package/libs/PanoMeasurePlugin/Model/polyline.d.ts +1 -1
- package/libs/PanoMeasurePlugin/Model/polyline.js +59 -51
- package/libs/PanoMeasurePlugin/Modules/UIController/index.js +22 -24
- package/libs/PanoMeasurePlugin/Modules/rangePiece/index.js +2 -3
- package/libs/PanoMeasurePlugin/index.js +13 -15
- package/libs/PanoVideoPlugin/VideoMeshController.js +1 -2
- package/libs/PipelinePlugin/Controller.d.ts +108 -0
- package/libs/PipelinePlugin/Controller.js +344 -0
- package/libs/PipelinePlugin/index.d.ts +6 -0
- package/libs/PipelinePlugin/index.js +39 -0
- package/libs/PipelinePlugin/typing/PluginData/index.js +6 -0
- package/libs/PipelinePlugin/typing/PluginData.d.ts +20 -0
- package/libs/PipelinePlugin/typing/PluginData.js +1 -0
- package/libs/PipelinePlugin/typing/ServerData/index.js +6 -0
- package/libs/PipelinePlugin/typing/ServerData.d.ts +28 -0
- package/libs/PipelinePlugin/typing/ServerData.js +1 -0
- package/libs/PipelinePlugin/typing/index.d.ts +79 -0
- package/libs/PipelinePlugin/typing/index.js +6 -0
- package/libs/PipelinePlugin/utils/Objects/FlowPipe.d.ts +34 -0
- package/libs/PipelinePlugin/utils/Objects/FlowPipe.js +106 -0
- package/libs/PipelinePlugin/utils/Objects/HighlightPipe.d.ts +11 -0
- package/libs/PipelinePlugin/utils/Objects/HighlightPipe.js +52 -0
- package/libs/PipelinePlugin/utils/Objects/Pipe.d.ts +49 -0
- package/libs/PipelinePlugin/utils/Objects/Pipe.js +179 -0
- package/libs/PipelinePlugin/utils/formatData.d.ts +12 -0
- package/libs/PipelinePlugin/utils/formatData.js +46 -0
- package/libs/base/BasePlugin.js +1 -1
- package/libs/base/BasePluginWithData.d.ts +3 -15
- package/libs/floorplan/MapviewFloorplanPlugin/Controller.js +87 -88
- package/libs/floorplan/ModelFloorplanPlugin/Controller.js +75 -76
- package/libs/floorplan/PanoFloorplanRadarPlugin/typing.d.ts +1 -1
- package/libs/floorplan/typings/index.d.ts +1 -1
- package/libs/index.d.ts +1 -0
- package/libs/index.js +117 -110
- package/libs/shared-utils/logger.js +1 -1
- package/libs/shared-utils/three/Extras/Core/Interpolations.d.ts +11 -0
- package/libs/shared-utils/three/Extras/Core/Interpolations.js +28 -0
- package/libs/shared-utils/three/Extras/Core/Interpolations2.js +34 -0
- package/libs/shared-utils/three/Extras/Curves/BezierCurve3.d.ts +13 -0
- package/libs/shared-utils/three/Extras/Curves/BezierCurve3.js +30 -0
- package/package.json +1 -1
- package/dist/PanoMeasurePlugin/utils/findAssociatedLines.d.ts +0 -2
- package/dist/shared-utils/removeArrayItem.d.ts +0 -7
- package/libs/PanoMeasurePlugin/utils/findAssociatedLines.d.ts +0 -2
- package/libs/PanoMeasurePlugin/utils/findAssociatedLines.js +0 -13
- package/libs/shared-utils/removeArrayItem.d.ts +0 -7
- package/libs/shared-utils/removeArrayItem.js +0 -8
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
var v = Object.defineProperty;
|
|
2
|
+
var u = (o, e, t) => e in o ? v(o, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : o[e] = t;
|
|
3
|
+
var r = (o, e, t) => (u(o, typeof e != "symbol" ? e + "" : e, t), t);
|
|
4
|
+
import "hammerjs";
|
|
5
|
+
import "three";
|
|
6
|
+
import "@realsee/five";
|
|
7
|
+
import "../../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
|
|
8
|
+
import "../../../CSS3DRenderPlugin/utils/three/CSS3DRender.js";
|
|
9
|
+
import "../../../CSS3DRenderPlugin/utils/generateBehindFiveElement.js";
|
|
10
|
+
import { requestAnimationFrameInterval as c } from "../../../shared-utils/animationFrame/index.js";
|
|
11
|
+
import { ObjectPipe as h } from "./Pipe.js";
|
|
12
|
+
import "../../../CSS3DRenderPlugin/utils/three/CSS3DRenderer.js";
|
|
13
|
+
import "three/examples/jsm/renderers/CSS3DRenderer";
|
|
14
|
+
import "../../../CSS3DRenderPlugin/utils/getAllCSS3DObject.js";
|
|
15
|
+
import "../../../CSS3DRenderPlugin/utils/createResizeObserver.js";
|
|
16
|
+
import "../../../CSS3DRenderPlugin/utils/even.js";
|
|
17
|
+
import "../../../shared-utils/Subscribe.js";
|
|
18
|
+
import "../../../CSS3DRenderPlugin/utils/positionToVector3.js";
|
|
19
|
+
import "../../../CSS3DRenderPlugin/utils/three/CSS3DObject.js";
|
|
20
|
+
import "../../../CSS3DRenderPlugin/utils/three/OpacityMesh.js";
|
|
21
|
+
import "../../../shared-utils/three/centerPoint.js";
|
|
22
|
+
import "../../../CSS3DRenderPlugin/utils/three/CSS3DScene.js";
|
|
23
|
+
import "../../../CSS3DRenderPlugin/utils/three/CSS3DGroup.js";
|
|
24
|
+
import "../../../shared-utils/animationFrame/BetterTween.js";
|
|
25
|
+
import "../../../shared-utils/three/Extras/Curves/BezierCurve3.js";
|
|
26
|
+
import "../../../shared-utils/three/Extras/Core/Interpolations.js";
|
|
27
|
+
import "../../../shared-utils/three/Extras/Core/Interpolations2.js";
|
|
28
|
+
const d = (
|
|
29
|
+
/* glsl */
|
|
30
|
+
`
|
|
31
|
+
varying vec2 vUv;
|
|
32
|
+
uniform float uOffset;
|
|
33
|
+
uniform float vOffset;
|
|
34
|
+
uniform float opacity;
|
|
35
|
+
uniform mediump sampler2D envMap;
|
|
36
|
+
|
|
37
|
+
void main(){
|
|
38
|
+
// u > 0 时,不显示。即贴图不向前移动时,全部使用 u = 0 的值进行平铺
|
|
39
|
+
float u = min(vUv.x + uOffset, 0.0);
|
|
40
|
+
float v = vUv.y + vOffset;
|
|
41
|
+
vec2 uv = vec2(u, v);
|
|
42
|
+
gl_FragColor = texture2D(envMap, uv);
|
|
43
|
+
gl_FragColor.a = gl_FragColor.a * opacity;
|
|
44
|
+
}
|
|
45
|
+
`
|
|
46
|
+
);
|
|
47
|
+
class z extends h {
|
|
48
|
+
constructor(t) {
|
|
49
|
+
super(t, d);
|
|
50
|
+
/** 初始状态下,当前水管内的水流在整体管道上的位移
|
|
51
|
+
* @description 因为水管是不连续的,而要达到水流的连续效果,需要用过贴图的 uOffset 控制每根水管的初始状态
|
|
52
|
+
*/
|
|
53
|
+
r(this, "initialDisplacement", 0);
|
|
54
|
+
r(this, "oldTime", (/* @__PURE__ */ new Date()).getTime());
|
|
55
|
+
/** 横向流动速度:m / s */
|
|
56
|
+
r(this, "flowSpeed", 0.6);
|
|
57
|
+
/** 纵向旋转速度:deg / s */
|
|
58
|
+
r(this, "rotateSpeed", 0);
|
|
59
|
+
r(this, "flowAnimationDisposer", () => {
|
|
60
|
+
});
|
|
61
|
+
}
|
|
62
|
+
setInitialDisplacement(t, i = "backward") {
|
|
63
|
+
this.initialDisplacement = Math.abs(t) * (i === "forward" ? -1 : 1), this.moveFromOrigin(this.initialDisplacement);
|
|
64
|
+
}
|
|
65
|
+
/** 水流移动「基于初始位置」
|
|
66
|
+
* @description 因为贴图的运动与 u 的 uOffset 相反,比较反直觉,所以封装方法易于理解
|
|
67
|
+
* @param displacement 位移:米 * 方向(向前 -> 正, 向后 -> 负)
|
|
68
|
+
*/
|
|
69
|
+
moveFromOrigin(t) {
|
|
70
|
+
const i = t * this.uPreMeter;
|
|
71
|
+
return this.material.uniforms.uOffset.value = i, this.material.needsUpdate = !0, this.needsRender = !0, !0;
|
|
72
|
+
}
|
|
73
|
+
/** 水流移动「基于调整管道差值之后的位置」
|
|
74
|
+
*
|
|
75
|
+
* @param distance 位移:米 * 方向
|
|
76
|
+
*/
|
|
77
|
+
moveForwardFromInitialOffset(t) {
|
|
78
|
+
const i = t * -1, m = this.initialDisplacement + i;
|
|
79
|
+
this.moveFromOrigin(m);
|
|
80
|
+
}
|
|
81
|
+
flow() {
|
|
82
|
+
this.flowAnimationDisposer(), this.oldTime = (/* @__PURE__ */ new Date()).getTime();
|
|
83
|
+
let t = 0, i = 0;
|
|
84
|
+
const m = c(() => {
|
|
85
|
+
const n = (/* @__PURE__ */ new Date()).getTime(), s = n - this.oldTime, a = this.flowSpeed * (s / 1e3), l = this.rotateSpeed * (s / 1e3);
|
|
86
|
+
t = t + a, i = i + l;
|
|
87
|
+
const p = 1 / 360, f = i * p;
|
|
88
|
+
this.material.uniforms.vOffset.value = f, this.moveForwardFromInitialOffset(t), this.oldTime = n;
|
|
89
|
+
});
|
|
90
|
+
this.flowAnimationDisposer = function() {
|
|
91
|
+
m(), this.moveForwardFromInitialOffset(0);
|
|
92
|
+
};
|
|
93
|
+
}
|
|
94
|
+
stopFlow() {
|
|
95
|
+
this.flowAnimationDisposer();
|
|
96
|
+
}
|
|
97
|
+
setSpeed(t) {
|
|
98
|
+
typeof (t == null ? void 0 : t.flowSpeed) == "number" && (this.flowSpeed = t.flowSpeed), typeof (t == null ? void 0 : t.rotateSpeed) == "number" && (this.rotateSpeed = t.rotateSpeed);
|
|
99
|
+
}
|
|
100
|
+
disposeAnime() {
|
|
101
|
+
super.disposeAnime(), this.flowAnimationDisposer();
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
export {
|
|
105
|
+
z as ObjectFlowPipe
|
|
106
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { PipeParams as BasePipeParams, AnimeOptions } from './Pipe';
|
|
2
|
+
import { ObjectPipe } from './Pipe';
|
|
3
|
+
export type PipeParams = BasePipeParams;
|
|
4
|
+
export declare class ObjectHighlightPipe extends ObjectPipe {
|
|
5
|
+
imageCount: number;
|
|
6
|
+
private highlightAnime?;
|
|
7
|
+
constructor(params: PipeParams);
|
|
8
|
+
highlight(options?: AnimeOptions): void;
|
|
9
|
+
highlight1(options?: AnimeOptions): void;
|
|
10
|
+
disposeAnime(): void;
|
|
11
|
+
}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
var p = Object.defineProperty;
|
|
2
|
+
var n = (e, t, i) => t in e ? p(e, t, { enumerable: !0, configurable: !0, writable: !0, value: i }) : e[t] = i;
|
|
3
|
+
var h = (e, t, i) => (n(e, typeof t != "symbol" ? t + "" : t, i), i);
|
|
4
|
+
import "hammerjs";
|
|
5
|
+
import "three";
|
|
6
|
+
import "@realsee/five";
|
|
7
|
+
import "../../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
|
|
8
|
+
import "../../../CSS3DRenderPlugin/utils/three/CSS3DRender.js";
|
|
9
|
+
import "../../../CSS3DRenderPlugin/utils/generateBehindFiveElement.js";
|
|
10
|
+
import { tweenProgress as s } from "../../../shared-utils/animationFrame/BetterTween.js";
|
|
11
|
+
import { ObjectPipe as a } from "./Pipe.js";
|
|
12
|
+
import "../../../CSS3DRenderPlugin/utils/three/CSS3DRenderer.js";
|
|
13
|
+
import "three/examples/jsm/renderers/CSS3DRenderer";
|
|
14
|
+
import "../../../CSS3DRenderPlugin/utils/getAllCSS3DObject.js";
|
|
15
|
+
import "../../../CSS3DRenderPlugin/utils/createResizeObserver.js";
|
|
16
|
+
import "../../../CSS3DRenderPlugin/utils/even.js";
|
|
17
|
+
import "../../../shared-utils/Subscribe.js";
|
|
18
|
+
import "../../../CSS3DRenderPlugin/utils/positionToVector3.js";
|
|
19
|
+
import "../../../CSS3DRenderPlugin/utils/three/CSS3DObject.js";
|
|
20
|
+
import "../../../CSS3DRenderPlugin/utils/three/OpacityMesh.js";
|
|
21
|
+
import "../../../shared-utils/three/centerPoint.js";
|
|
22
|
+
import "../../../CSS3DRenderPlugin/utils/three/CSS3DScene.js";
|
|
23
|
+
import "../../../CSS3DRenderPlugin/utils/three/CSS3DGroup.js";
|
|
24
|
+
import "../../../shared-utils/animationFrame/index.js";
|
|
25
|
+
import "../../../shared-utils/three/Extras/Curves/BezierCurve3.js";
|
|
26
|
+
import "../../../shared-utils/three/Extras/Core/Interpolations.js";
|
|
27
|
+
import "../../../shared-utils/three/Extras/Core/Interpolations2.js";
|
|
28
|
+
class E extends a {
|
|
29
|
+
constructor(i) {
|
|
30
|
+
super(i);
|
|
31
|
+
h(this, "imageCount", 64);
|
|
32
|
+
h(this, "highlightAnime");
|
|
33
|
+
}
|
|
34
|
+
highlight(i) {
|
|
35
|
+
const r = (i == null ? void 0 : i.duration) || 500;
|
|
36
|
+
this.disposeAnime(), this.highlightAnime = s(r).onUpdate(({ progress: m }) => this.setOpacity(m)).yoyo(!0).repeat(1 / 0).play();
|
|
37
|
+
}
|
|
38
|
+
highlight1(i) {
|
|
39
|
+
const r = (i == null ? void 0 : i.duration) || 2500;
|
|
40
|
+
this.disposeAnime(), this.highlightAnime = s(r).onUpdate(({ progress: m }) => {
|
|
41
|
+
const o = -(Math.ceil(m * this.imageCount) - 1) / this.imageCount;
|
|
42
|
+
this.material.uniforms.vOffset.value !== o && (this.material.uniforms.vOffset.value = o, this.material.needsUpdate = !0, this.needsRender = !0);
|
|
43
|
+
}).repeat(1 / 0).play();
|
|
44
|
+
}
|
|
45
|
+
disposeAnime() {
|
|
46
|
+
var i;
|
|
47
|
+
super.disposeAnime(), (i = this.highlightAnime) == null || i.dispose(), this.highlightAnime = void 0;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
export {
|
|
51
|
+
E as ObjectHighlightPipe
|
|
52
|
+
};
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import * as THREE from 'three';
|
|
2
|
+
import { BetterTween } from '../../../shared-utils';
|
|
3
|
+
import { CustomBezierCurve3 } from '../../../shared-utils/three/Extras/Curves/BezierCurve3';
|
|
4
|
+
export interface PipeParams {
|
|
5
|
+
id?: string;
|
|
6
|
+
path: number[][];
|
|
7
|
+
texture: THREE.Texture;
|
|
8
|
+
geometryConfig?: {
|
|
9
|
+
radius?: number;
|
|
10
|
+
radialSegments?: number;
|
|
11
|
+
tubularSegments?: number;
|
|
12
|
+
};
|
|
13
|
+
}
|
|
14
|
+
export interface AnimeOptions {
|
|
15
|
+
duration?: number;
|
|
16
|
+
}
|
|
17
|
+
export declare class ObjectPipe extends THREE.Mesh<THREE.TubeBufferGeometry, THREE.ShaderMaterial> {
|
|
18
|
+
/** 根据控制点数量计算管道路径
|
|
19
|
+
*
|
|
20
|
+
* @description 两个控制点使用直线路径,多个控制点使用贝塞尔路径
|
|
21
|
+
*/
|
|
22
|
+
static calculatePath(points: THREE.Vector3[]): THREE.LineCurve3 | CustomBezierCurve3;
|
|
23
|
+
static formatGeometryUV<T extends THREE.BufferGeometry>(geometry: T, pathLength: number, uPreMeter: number): T;
|
|
24
|
+
/**
|
|
25
|
+
* 管道的 Texture 需要满足一定的要求,需要使用 formatTexture 先 format
|
|
26
|
+
*/
|
|
27
|
+
static formatTexture(texture: THREE.Texture): THREE.Texture;
|
|
28
|
+
geometryConfig: {
|
|
29
|
+
radius: number;
|
|
30
|
+
tubularSegments: number;
|
|
31
|
+
radialSegments: number;
|
|
32
|
+
};
|
|
33
|
+
customID: string;
|
|
34
|
+
path: THREE.LineCurve3 | CustomBezierCurve3;
|
|
35
|
+
pathLength: number;
|
|
36
|
+
pathPoints: number[][];
|
|
37
|
+
texture: THREE.Texture;
|
|
38
|
+
protected opacityAnime?: BetterTween<{
|
|
39
|
+
progress: number;
|
|
40
|
+
}>;
|
|
41
|
+
/** u / m: 每米水管对应到贴图上,应该对应的 u 的长度 */
|
|
42
|
+
protected uPreMeter: number;
|
|
43
|
+
constructor(params: PipeParams, fragmentShader?: string);
|
|
44
|
+
hide(options?: AnimeOptions): Promise<boolean>;
|
|
45
|
+
show(options?: AnimeOptions): Promise<boolean>;
|
|
46
|
+
setOpacity(value: number): boolean;
|
|
47
|
+
disposeAnime(): void;
|
|
48
|
+
dispose(): void;
|
|
49
|
+
}
|
|
@@ -0,0 +1,179 @@
|
|
|
1
|
+
var d = Object.defineProperty;
|
|
2
|
+
var v = Object.getOwnPropertySymbols;
|
|
3
|
+
var A = Object.prototype.hasOwnProperty, w = Object.prototype.propertyIsEnumerable;
|
|
4
|
+
var f = (a, e, t) => e in a ? d(a, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : a[e] = t, y = (a, e) => {
|
|
5
|
+
for (var t in e || (e = {}))
|
|
6
|
+
A.call(e, t) && f(a, t, e[t]);
|
|
7
|
+
if (v)
|
|
8
|
+
for (var t of v(e))
|
|
9
|
+
w.call(e, t) && f(a, t, e[t]);
|
|
10
|
+
return a;
|
|
11
|
+
};
|
|
12
|
+
var m = (a, e, t) => (f(a, typeof e != "symbol" ? e + "" : e, t), t);
|
|
13
|
+
var l = (a, e, t) => new Promise((i, s) => {
|
|
14
|
+
var o = (p) => {
|
|
15
|
+
try {
|
|
16
|
+
n(t.next(p));
|
|
17
|
+
} catch (c) {
|
|
18
|
+
s(c);
|
|
19
|
+
}
|
|
20
|
+
}, r = (p) => {
|
|
21
|
+
try {
|
|
22
|
+
n(t.throw(p));
|
|
23
|
+
} catch (c) {
|
|
24
|
+
s(c);
|
|
25
|
+
}
|
|
26
|
+
}, n = (p) => p.done ? i(p.value) : Promise.resolve(p.value).then(o, r);
|
|
27
|
+
n((t = t.apply(a, e)).next());
|
|
28
|
+
});
|
|
29
|
+
import * as u from "three";
|
|
30
|
+
import "hammerjs";
|
|
31
|
+
import "@realsee/five";
|
|
32
|
+
import "../../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
|
|
33
|
+
import "../../../CSS3DRenderPlugin/utils/three/CSS3DRender.js";
|
|
34
|
+
import "../../../CSS3DRenderPlugin/utils/generateBehindFiveElement.js";
|
|
35
|
+
import { BetterTween as g } from "../../../shared-utils/animationFrame/BetterTween.js";
|
|
36
|
+
import { CustomBezierCurve3 as x } from "../../../shared-utils/three/Extras/Curves/BezierCurve3.js";
|
|
37
|
+
import "../../../CSS3DRenderPlugin/utils/three/CSS3DRenderer.js";
|
|
38
|
+
import "three/examples/jsm/renderers/CSS3DRenderer";
|
|
39
|
+
import "../../../CSS3DRenderPlugin/utils/getAllCSS3DObject.js";
|
|
40
|
+
import "../../../CSS3DRenderPlugin/utils/createResizeObserver.js";
|
|
41
|
+
import "../../../CSS3DRenderPlugin/utils/even.js";
|
|
42
|
+
import "../../../shared-utils/Subscribe.js";
|
|
43
|
+
import "../../../CSS3DRenderPlugin/utils/positionToVector3.js";
|
|
44
|
+
import "../../../CSS3DRenderPlugin/utils/three/CSS3DObject.js";
|
|
45
|
+
import "../../../CSS3DRenderPlugin/utils/three/OpacityMesh.js";
|
|
46
|
+
import "../../../shared-utils/three/centerPoint.js";
|
|
47
|
+
import "../../../CSS3DRenderPlugin/utils/three/CSS3DScene.js";
|
|
48
|
+
import "../../../CSS3DRenderPlugin/utils/three/CSS3DGroup.js";
|
|
49
|
+
import "../../../shared-utils/animationFrame/index.js";
|
|
50
|
+
import "../../../shared-utils/three/Extras/Core/Interpolations.js";
|
|
51
|
+
import "../../../shared-utils/three/Extras/Core/Interpolations2.js";
|
|
52
|
+
const C = (
|
|
53
|
+
/* glsl */
|
|
54
|
+
`
|
|
55
|
+
varying vec2 vUv;
|
|
56
|
+
void main() {
|
|
57
|
+
vUv = uv;
|
|
58
|
+
gl_Position = projectionMatrix * modelViewMatrix * vec4(position, 1.0);
|
|
59
|
+
}
|
|
60
|
+
`
|
|
61
|
+
), O = (
|
|
62
|
+
/* glsl */
|
|
63
|
+
`
|
|
64
|
+
varying vec2 vUv;
|
|
65
|
+
uniform float uOffset;
|
|
66
|
+
uniform float vOffset;
|
|
67
|
+
uniform float opacity;
|
|
68
|
+
uniform mediump sampler2D envMap;
|
|
69
|
+
|
|
70
|
+
void main(){
|
|
71
|
+
float u = vUv.x + uOffset;
|
|
72
|
+
float v = vUv.y + vOffset;
|
|
73
|
+
vec2 uv = vec2(u, v);
|
|
74
|
+
gl_FragColor = texture2D(envMap, uv);
|
|
75
|
+
gl_FragColor.a = gl_FragColor.a * opacity;
|
|
76
|
+
}
|
|
77
|
+
`
|
|
78
|
+
);
|
|
79
|
+
class h extends u.Mesh {
|
|
80
|
+
constructor(t, i = O) {
|
|
81
|
+
super();
|
|
82
|
+
m(this, "geometryConfig", {
|
|
83
|
+
radius: 1.5 / 100,
|
|
84
|
+
tubularSegments: 20,
|
|
85
|
+
radialSegments: 8
|
|
86
|
+
});
|
|
87
|
+
m(this, "customID");
|
|
88
|
+
m(this, "path");
|
|
89
|
+
m(this, "pathLength", 0);
|
|
90
|
+
m(this, "pathPoints");
|
|
91
|
+
m(this, "texture");
|
|
92
|
+
m(this, "opacityAnime");
|
|
93
|
+
/** u / m: 每米水管对应到贴图上,应该对应的 u 的长度 */
|
|
94
|
+
m(this, "uPreMeter", 1);
|
|
95
|
+
t.geometryConfig && (this.geometryConfig = y(y({}, this.geometryConfig), t.geometryConfig)), this.customID = t.id || this.uuid, this.pathPoints = t.path, this.path = h.calculatePath(t.path.map((p) => new u.Vector3().fromArray(p))), this.pathLength = this.path.getLength(), this.texture = h.formatTexture(t.texture);
|
|
96
|
+
const { radius: s, tubularSegments: o, radialSegments: r } = this.geometryConfig, n = h.formatTexture(t.texture);
|
|
97
|
+
this.geometry = h.formatGeometryUV(
|
|
98
|
+
new u.TubeBufferGeometry(this.path, o, s, r),
|
|
99
|
+
this.pathLength,
|
|
100
|
+
this.uPreMeter
|
|
101
|
+
), this.material = new u.ShaderMaterial({
|
|
102
|
+
uniforms: {
|
|
103
|
+
opacity: { value: 1 },
|
|
104
|
+
uOffset: { value: 0 },
|
|
105
|
+
vOffset: { value: 0 },
|
|
106
|
+
envMap: {
|
|
107
|
+
value: n
|
|
108
|
+
}
|
|
109
|
+
},
|
|
110
|
+
transparent: !0,
|
|
111
|
+
vertexShader: C,
|
|
112
|
+
fragmentShader: i
|
|
113
|
+
});
|
|
114
|
+
}
|
|
115
|
+
/** 根据控制点数量计算管道路径
|
|
116
|
+
*
|
|
117
|
+
* @description 两个控制点使用直线路径,多个控制点使用贝塞尔路径
|
|
118
|
+
*/
|
|
119
|
+
static calculatePath(t) {
|
|
120
|
+
return t.length === 2 ? new u.LineCurve3(t[0], t[1]) : new x(t);
|
|
121
|
+
}
|
|
122
|
+
static formatGeometryUV(t, i, s) {
|
|
123
|
+
const o = t.getAttribute("uv");
|
|
124
|
+
for (let r = 0; r < o.count; r++) {
|
|
125
|
+
const n = o.getX(r) * i * s;
|
|
126
|
+
o.setX(r, n);
|
|
127
|
+
}
|
|
128
|
+
return t;
|
|
129
|
+
}
|
|
130
|
+
/**
|
|
131
|
+
* 管道的 Texture 需要满足一定的要求,需要使用 formatTexture 先 format
|
|
132
|
+
*/
|
|
133
|
+
static formatTexture(t) {
|
|
134
|
+
return t.wrapS = u.RepeatWrapping, t.wrapT = u.RepeatWrapping, t;
|
|
135
|
+
}
|
|
136
|
+
hide(t) {
|
|
137
|
+
return l(this, null, function* () {
|
|
138
|
+
var o;
|
|
139
|
+
(o = this.opacityAnime) == null || o.dispose();
|
|
140
|
+
const i = 0;
|
|
141
|
+
if (typeof (t == null ? void 0 : t.duration) != "number")
|
|
142
|
+
return this.setOpacity(i);
|
|
143
|
+
const s = this.material.uniforms.opacity.value;
|
|
144
|
+
return s === i ? !0 : new Promise((r) => {
|
|
145
|
+
this.opacityAnime = new g({ progress: s }).to({ progress: i }).onUpdate(({ progress: n }) => this.setOpacity(n)).onComplete(() => r(!0)).onDispose(() => {
|
|
146
|
+
this.setOpacity(i), r(!1);
|
|
147
|
+
}).play();
|
|
148
|
+
});
|
|
149
|
+
});
|
|
150
|
+
}
|
|
151
|
+
show(t) {
|
|
152
|
+
return l(this, null, function* () {
|
|
153
|
+
var o;
|
|
154
|
+
(o = this.opacityAnime) == null || o.dispose();
|
|
155
|
+
const i = 1;
|
|
156
|
+
if (typeof (t == null ? void 0 : t.duration) != "number")
|
|
157
|
+
return this.setOpacity(i);
|
|
158
|
+
const s = this.material.uniforms.opacity.value;
|
|
159
|
+
return new Promise((r) => {
|
|
160
|
+
this.opacityAnime = new g({ progress: s }).to({ progress: i }).onUpdate(({ progress: n }) => this.setOpacity(n)).onComplete(() => r(!0)).onDispose(() => {
|
|
161
|
+
this.setOpacity(i), r(!1);
|
|
162
|
+
}).play();
|
|
163
|
+
});
|
|
164
|
+
});
|
|
165
|
+
}
|
|
166
|
+
setOpacity(t) {
|
|
167
|
+
return this.material.uniforms.opacity.value = t, this.material.needsUpdate = !0, this.needsRender = !0, !0;
|
|
168
|
+
}
|
|
169
|
+
disposeAnime() {
|
|
170
|
+
var t;
|
|
171
|
+
(t = this.opacityAnime) == null || t.dispose(), this.opacityAnime = void 0;
|
|
172
|
+
}
|
|
173
|
+
dispose() {
|
|
174
|
+
this.disposeAnime(), this.geometry.dispose(), this.material.dispose();
|
|
175
|
+
}
|
|
176
|
+
}
|
|
177
|
+
export {
|
|
178
|
+
h as ObjectPipe
|
|
179
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { PluginData, ServerData, LoadOptions } from '../typing';
|
|
2
|
+
/** 从 PluginData 中找到符合「从 ID 为 startLibraryID 的设备到 ID 为 endLibraryID 的设备」的 pipe data */
|
|
3
|
+
export declare function getPipesFromLibrary(params: {
|
|
4
|
+
data: PluginData.RootObject;
|
|
5
|
+
target: {
|
|
6
|
+
startLibraryID: number;
|
|
7
|
+
endLibraryID: number;
|
|
8
|
+
}[];
|
|
9
|
+
}): PluginData.Pipe[];
|
|
10
|
+
/** 获取默认的管道贴图 */
|
|
11
|
+
export declare function getDefaultPipeUrl<T extends PluginData.Water>(water: T): string | undefined;
|
|
12
|
+
export declare function format(origin: ServerData.RootObject, options?: Partial<LoadOptions>): PluginData.RootObject;
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import { notNil as c } from "../../shared-utils/isNil.js";
|
|
2
|
+
function l(e) {
|
|
3
|
+
const t = /* @__PURE__ */ new Map();
|
|
4
|
+
return e.forEach((a) => a.pipes.forEach((s) => t.set(s.id, s))), Array.from(t.values());
|
|
5
|
+
}
|
|
6
|
+
function v(e) {
|
|
7
|
+
const t = e.target.map(({ startLibraryID: a, endLibraryID: s }) => {
|
|
8
|
+
const r = e.data.pipelines.find(
|
|
9
|
+
(n) => n.startLibraryID === a && n.endLibraryID === s
|
|
10
|
+
);
|
|
11
|
+
return r || console.warn(`Cannot find pipeline with startLibraryID ${a} and endLibraryID ${s}`), r;
|
|
12
|
+
}).filter(c);
|
|
13
|
+
return l(t);
|
|
14
|
+
}
|
|
15
|
+
function g(e) {
|
|
16
|
+
if (e.quality === 0)
|
|
17
|
+
return "//vrlab-static.ljcdn.com/release/web/aqueous-system-demo/19/1.png";
|
|
18
|
+
if (e.quality === 1)
|
|
19
|
+
return "//vrlab-static.ljcdn.com/release/web/aqueous-system-demo/19/2.png";
|
|
20
|
+
if (e.quality === 2)
|
|
21
|
+
return "//vrlab-static.ljcdn.com/release/web/aqueous-system-demo/19/3.png";
|
|
22
|
+
if (e.quality === 3)
|
|
23
|
+
return "//vrlab-static.ljcdn.com/release/web/aqueous-system-demo/19/4.png";
|
|
24
|
+
if (e.quality === 4)
|
|
25
|
+
return "//vrlab-static.ljcdn.com/release/web/aqueous-system-demo/19/5.png";
|
|
26
|
+
if (e.isHot)
|
|
27
|
+
return "//vrlab-static.ljcdn.com/release/web/aqueous-system-demo/19/6.png";
|
|
28
|
+
}
|
|
29
|
+
function w(e, t) {
|
|
30
|
+
const a = e.ConnectsDataset.map((r) => {
|
|
31
|
+
const n = r.data, d = r.start, o = r.end, u = { isHot: r.waterType === 5, quality: r.waterType }, m = n.map((f) => {
|
|
32
|
+
const i = e.LinesDataset.find((q) => q.id === f);
|
|
33
|
+
if (!i)
|
|
34
|
+
return null;
|
|
35
|
+
const p = i.data, y = t != null && t.getPipeRadius ? t.getPipeRadius(i) : 1.6 / 100, b = t != null && t.getPipeUrl ? t.getPipeUrl(u) : g(u);
|
|
36
|
+
return { id: i.id, radius: y, water: u, path: p, texture: b };
|
|
37
|
+
}).filter(c);
|
|
38
|
+
return { startLibraryID: d, endLibraryID: o, pipes: m };
|
|
39
|
+
});
|
|
40
|
+
return { pipes: l(a), pipelines: a };
|
|
41
|
+
}
|
|
42
|
+
export {
|
|
43
|
+
w as format,
|
|
44
|
+
g as getDefaultPipeUrl,
|
|
45
|
+
v as getPipesFromLibrary
|
|
46
|
+
};
|
package/libs/base/BasePlugin.js
CHANGED
|
@@ -7,20 +7,7 @@ interface EventMap<PluginState, PluginData> extends BasePlugin.EventMap<PluginSt
|
|
|
7
7
|
/** 数据加载完成 */
|
|
8
8
|
dataLoaded: (data: PluginData) => void;
|
|
9
9
|
}
|
|
10
|
-
|
|
11
|
-
* 插件的基础数据
|
|
12
|
-
*/
|
|
13
|
-
interface ServerData {
|
|
14
|
-
/**
|
|
15
|
-
* 数据版本
|
|
16
|
-
*/
|
|
17
|
-
version: number;
|
|
18
|
-
/**
|
|
19
|
-
* 数据
|
|
20
|
-
*/
|
|
21
|
-
data?: unknown;
|
|
22
|
-
}
|
|
23
|
-
declare abstract class Controller<PluginState extends State, PluginEventMap extends EventMap<PluginState, PluginData>, PluginServerData extends ServerData, PluginData> extends BasePlugin.Controller<PluginState, PluginEventMap> {
|
|
10
|
+
declare abstract class Controller<PluginState extends State, PluginEventMap extends EventMap<PluginState, PluginData>, PluginServerData, PluginData> extends BasePlugin.Controller<PluginState, PluginEventMap> {
|
|
24
11
|
protected abstract data?: PluginData;
|
|
25
12
|
/**
|
|
26
13
|
* 加载插件依赖数据
|
|
@@ -31,5 +18,6 @@ declare abstract class Controller<PluginState extends State, PluginEventMap exte
|
|
|
31
18
|
/** 把原始数据转化为插件数据 */
|
|
32
19
|
protected abstract formatData?(serverData: PluginServerData): Promise<PluginData>;
|
|
33
20
|
}
|
|
34
|
-
export type { State, EventMap,
|
|
21
|
+
export type { State, EventMap, Config };
|
|
22
|
+
export type { BaseOptions } from './BasePlugin';
|
|
35
23
|
export { Controller };
|