@cornerstonejs/tools 1.52.0 → 1.54.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/drawingSvg/drawPath.d.ts +11 -0
- package/dist/cjs/drawingSvg/drawPath.js +55 -0
- package/dist/cjs/drawingSvg/drawPath.js.map +1 -0
- package/dist/cjs/drawingSvg/drawPolyline.d.ts +1 -1
- package/dist/cjs/drawingSvg/drawPolyline.js +2 -10
- package/dist/cjs/drawingSvg/drawPolyline.js.map +1 -1
- package/dist/cjs/drawingSvg/index.d.ts +2 -1
- package/dist/cjs/drawingSvg/index.js +3 -1
- package/dist/cjs/drawingSvg/index.js.map +1 -1
- package/dist/cjs/enums/WorkerTypes.d.ts +8 -0
- package/dist/cjs/enums/WorkerTypes.js +12 -0
- package/dist/cjs/enums/WorkerTypes.js.map +1 -0
- package/dist/cjs/enums/index.d.ts +2 -1
- package/dist/cjs/enums/index.js +3 -1
- package/dist/cjs/enums/index.js.map +1 -1
- package/dist/cjs/eventDispatchers/shared/getActiveToolForMouseEvent.js.map +1 -1
- package/dist/cjs/eventListeners/annotations/contourSegmentation/contourSegmentationCompleted.d.ts +1 -1
- package/dist/cjs/eventListeners/annotations/contourSegmentation/contourSegmentationCompleted.js +171 -89
- package/dist/cjs/eventListeners/annotations/contourSegmentation/contourSegmentationCompleted.js.map +1 -1
- package/dist/cjs/eventListeners/segmentation/imageChangeEventListener.js +4 -3
- package/dist/cjs/eventListeners/segmentation/imageChangeEventListener.js.map +1 -1
- package/dist/cjs/eventListeners/segmentation/labelmap/onLabelmapSegmentationDataModified.js +58 -47
- package/dist/cjs/eventListeners/segmentation/labelmap/onLabelmapSegmentationDataModified.js.map +1 -1
- package/dist/cjs/stateManagement/annotation/FrameOfReferenceSpecificAnnotationManager.d.ts +1 -0
- package/dist/cjs/stateManagement/annotation/FrameOfReferenceSpecificAnnotationManager.js +5 -0
- package/dist/cjs/stateManagement/annotation/FrameOfReferenceSpecificAnnotationManager.js.map +1 -1
- package/dist/cjs/stateManagement/annotation/annotationState.d.ts +7 -1
- package/dist/cjs/stateManagement/annotation/annotationState.js +54 -1
- package/dist/cjs/stateManagement/annotation/annotationState.js.map +1 -1
- package/dist/cjs/stateManagement/annotation/helpers/state.d.ts +2 -1
- package/dist/cjs/stateManagement/annotation/helpers/state.js +14 -3
- package/dist/cjs/stateManagement/annotation/helpers/state.js.map +1 -1
- package/dist/cjs/stateManagement/index.d.ts +6 -1
- package/dist/cjs/stateManagement/index.js +6 -1
- package/dist/cjs/stateManagement/index.js.map +1 -1
- package/dist/cjs/stateManagement/segmentation/SegmentationStateManager.js +4 -1
- package/dist/cjs/stateManagement/segmentation/SegmentationStateManager.js.map +1 -1
- package/dist/cjs/stateManagement/segmentation/addRepresentationData.d.ts +12 -0
- package/dist/cjs/stateManagement/segmentation/addRepresentationData.js +35 -0
- package/dist/cjs/stateManagement/segmentation/addRepresentationData.js.map +1 -0
- package/dist/cjs/stateManagement/segmentation/addSegmentationRepresentation.js +32 -14
- package/dist/cjs/stateManagement/segmentation/addSegmentationRepresentation.js.map +1 -1
- package/dist/cjs/stateManagement/segmentation/config/segmentationVisibility.js +3 -52
- package/dist/cjs/stateManagement/segmentation/config/segmentationVisibility.js.map +1 -1
- package/dist/cjs/stateManagement/segmentation/convertStackToVolumeSegmentation.d.ts +9 -2
- package/dist/cjs/stateManagement/segmentation/convertStackToVolumeSegmentation.js +44 -27
- package/dist/cjs/stateManagement/segmentation/convertStackToVolumeSegmentation.js.map +1 -1
- package/dist/cjs/stateManagement/segmentation/convertVolumeToStackSegmentation.d.ts +13 -0
- package/dist/cjs/stateManagement/segmentation/convertVolumeToStackSegmentation.js +52 -26
- package/dist/cjs/stateManagement/segmentation/convertVolumeToStackSegmentation.js.map +1 -1
- package/dist/cjs/stateManagement/segmentation/helpers/validateSegmentationInput.js +6 -9
- package/dist/cjs/stateManagement/segmentation/helpers/validateSegmentationInput.js.map +1 -1
- package/dist/cjs/stateManagement/segmentation/index.d.ts +3 -1
- package/dist/cjs/stateManagement/segmentation/index.js +5 -1
- package/dist/cjs/stateManagement/segmentation/index.js.map +1 -1
- package/dist/cjs/stateManagement/segmentation/polySeg/Contour/computeAndAddContourRepresentation.d.ts +2 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Contour/computeAndAddContourRepresentation.js +8 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Contour/computeAndAddContourRepresentation.js.map +1 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Labelmap/computeAndAddLabelmapRepresentation.d.ts +2 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Labelmap/computeAndAddLabelmapRepresentation.js +11 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Labelmap/computeAndAddLabelmapRepresentation.js.map +1 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Labelmap/convertContourToLabelmap.d.ts +7 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Labelmap/convertContourToLabelmap.js +162 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Labelmap/convertContourToLabelmap.js.map +1 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Labelmap/convertSurfaceToLabelmap.d.ts +6 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Labelmap/convertSurfaceToLabelmap.js +71 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Labelmap/convertSurfaceToLabelmap.js.map +1 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Labelmap/labelmapComputationStrategies.d.ts +6 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Labelmap/labelmapComputationStrategies.js +120 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Labelmap/labelmapComputationStrategies.js.map +1 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Surface/computeAndAddSurfaceRepresentation.d.ts +4 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Surface/computeAndAddSurfaceRepresentation.js +12 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Surface/computeAndAddSurfaceRepresentation.js.map +1 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Surface/convertContourToSurface.d.ts +3 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Surface/convertContourToSurface.js +52 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Surface/convertContourToSurface.js.map +1 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Surface/convertLabelmapToSurface.d.ts +3 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Surface/convertLabelmapToSurface.js +60 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Surface/convertLabelmapToSurface.js.map +1 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Surface/createAndCacheSurfacesFromRaw.d.ts +5 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Surface/createAndCacheSurfacesFromRaw.js +56 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Surface/createAndCacheSurfacesFromRaw.js.map +1 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Surface/surfaceComputationStrategies.d.ts +12 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Surface/surfaceComputationStrategies.js +94 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Surface/surfaceComputationStrategies.js.map +1 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Surface/updateSurfaceData.d.ts +1 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Surface/updateSurfaceData.js +74 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/Surface/updateSurfaceData.js.map +1 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/canComputeRequestedRepresentation.d.ts +2 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/canComputeRequestedRepresentation.js +83 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/canComputeRequestedRepresentation.js.map +1 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/computeAndAddRepresentation.d.ts +3 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/computeAndAddRepresentation.js +64 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/computeAndAddRepresentation.js.map +1 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/index.d.ts +5 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/index.js +12 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/index.js.map +1 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/registerPolySegWorker.d.ts +1 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/registerPolySegWorker.js +27 -0
- package/dist/cjs/stateManagement/segmentation/polySeg/registerPolySegWorker.js.map +1 -0
- package/dist/cjs/stateManagement/segmentation/segmentIndex.js +4 -0
- package/dist/cjs/stateManagement/segmentation/segmentIndex.js.map +1 -1
- package/dist/cjs/stateManagement/segmentation/segmentationState.d.ts +6 -1
- package/dist/cjs/stateManagement/segmentation/segmentationState.js +30 -1
- package/dist/cjs/stateManagement/segmentation/segmentationState.js.map +1 -1
- package/dist/cjs/store/ToolGroupManager/ToolGroup.d.ts +3 -1
- package/dist/cjs/store/ToolGroupManager/ToolGroup.js +3 -2
- package/dist/cjs/store/ToolGroupManager/ToolGroup.js.map +1 -1
- package/dist/cjs/tools/ScaleOverlayTool.js +2 -1
- package/dist/cjs/tools/ScaleOverlayTool.js.map +1 -1
- package/dist/cjs/tools/SegmentationIntersectionTool.js +1 -1
- package/dist/cjs/tools/SegmentationIntersectionTool.js.map +1 -1
- package/dist/cjs/tools/annotation/LivewireContourSegmentationTool.js +1 -1
- package/dist/cjs/tools/annotation/LivewireContourSegmentationTool.js.map +1 -1
- package/dist/cjs/tools/annotation/LivewireContourTool.d.ts +4 -3
- package/dist/cjs/tools/annotation/LivewireContourTool.js +26 -26
- package/dist/cjs/tools/annotation/LivewireContourTool.js.map +1 -1
- package/dist/cjs/tools/annotation/PlanarFreehandContourSegmentationTool.d.ts +1 -2
- package/dist/cjs/tools/annotation/PlanarFreehandContourSegmentationTool.js +0 -11
- package/dist/cjs/tools/annotation/PlanarFreehandContourSegmentationTool.js.map +1 -1
- package/dist/cjs/tools/annotation/PlanarFreehandROITool.js +2 -2
- package/dist/cjs/tools/annotation/PlanarFreehandROITool.js.map +1 -1
- package/dist/cjs/tools/annotation/ProbeTool.js +3 -0
- package/dist/cjs/tools/annotation/ProbeTool.js.map +1 -1
- package/dist/cjs/tools/annotation/SplineROITool.d.ts +6 -3
- package/dist/cjs/tools/annotation/SplineROITool.js +37 -18
- package/dist/cjs/tools/annotation/SplineROITool.js.map +1 -1
- package/dist/cjs/tools/annotation/planarFreehandROITool/closedContourEditLoop.js +12 -7
- package/dist/cjs/tools/annotation/planarFreehandROITool/closedContourEditLoop.js.map +1 -1
- package/dist/cjs/tools/annotation/planarFreehandROITool/drawLoop.js +25 -19
- package/dist/cjs/tools/annotation/planarFreehandROITool/drawLoop.js.map +1 -1
- package/dist/cjs/tools/annotation/planarFreehandROITool/openContourEditLoop.js +16 -10
- package/dist/cjs/tools/annotation/planarFreehandROITool/openContourEditLoop.js.map +1 -1
- package/dist/cjs/tools/annotation/planarFreehandROITool/openContourEndEditLoop.js +1 -1
- package/dist/cjs/tools/annotation/planarFreehandROITool/openContourEndEditLoop.js.map +1 -1
- package/dist/cjs/tools/annotation/planarFreehandROITool/renderMethods.js +19 -7
- package/dist/cjs/tools/annotation/planarFreehandROITool/renderMethods.js.map +1 -1
- package/dist/cjs/tools/annotation/splines/LinearSpline.js +1 -1
- package/dist/cjs/tools/annotation/splines/LinearSpline.js.map +1 -1
- package/dist/cjs/tools/annotation/splines/Spline.d.ts +2 -0
- package/dist/cjs/tools/annotation/splines/Spline.js +7 -3
- package/dist/cjs/tools/annotation/splines/Spline.js.map +1 -1
- package/dist/cjs/tools/base/AnnotationTool.js +1 -1
- package/dist/cjs/tools/base/AnnotationTool.js.map +1 -1
- package/dist/cjs/tools/base/BaseTool.js.map +1 -1
- package/dist/cjs/tools/base/ContourBaseTool.d.ts +1 -0
- package/dist/cjs/tools/base/ContourBaseTool.js +18 -1
- package/dist/cjs/tools/base/ContourBaseTool.js.map +1 -1
- package/dist/cjs/tools/base/ContourSegmentationBaseTool.d.ts +1 -2
- package/dist/cjs/tools/base/ContourSegmentationBaseTool.js +28 -24
- package/dist/cjs/tools/base/ContourSegmentationBaseTool.js.map +1 -1
- package/dist/cjs/tools/displayTools/Contour/contourConfig.js +1 -0
- package/dist/cjs/tools/displayTools/Contour/contourConfig.js.map +1 -1
- package/dist/cjs/tools/displayTools/Contour/contourDisplay.js +9 -6
- package/dist/cjs/tools/displayTools/Contour/contourDisplay.js.map +1 -1
- package/dist/cjs/tools/displayTools/Contour/removeContourFromElement.js.map +1 -1
- package/dist/cjs/tools/displayTools/Contour/{addContourSetsToElement.d.ts → vtkContour/addContourSetsToElement.d.ts} +1 -1
- package/dist/cjs/tools/displayTools/Contour/vtkContour/addContourSetsToElement.js.map +1 -0
- package/dist/cjs/tools/displayTools/Contour/vtkContour/addOrUpdateVTKContourSets.d.ts +3 -0
- package/dist/cjs/tools/displayTools/Contour/vtkContour/addOrUpdateVTKContourSets.js +14 -0
- package/dist/cjs/tools/displayTools/Contour/vtkContour/addOrUpdateVTKContourSets.js.map +1 -0
- package/dist/cjs/tools/displayTools/Contour/vtkContour/contourConfigCache.js.map +1 -0
- package/dist/cjs/tools/displayTools/Contour/vtkContour/updateVTKContourSets.d.ts +3 -0
- package/dist/cjs/tools/displayTools/Contour/{updateContourSets.js → vtkContour/updateVTKContourSets.js} +4 -4
- package/dist/cjs/tools/displayTools/Contour/vtkContour/updateVTKContourSets.js.map +1 -0
- package/dist/cjs/tools/displayTools/Contour/{utils.d.ts → vtkContour/utils.d.ts} +2 -2
- package/dist/cjs/tools/displayTools/Contour/vtkContour/utils.js.map +1 -0
- package/dist/cjs/tools/displayTools/Labelmap/addLabelmapToElement.js +1 -1
- package/dist/cjs/tools/displayTools/Labelmap/addLabelmapToElement.js.map +1 -1
- package/dist/cjs/tools/displayTools/Labelmap/index.d.ts +2 -1
- package/dist/cjs/tools/displayTools/Labelmap/index.js +4 -1
- package/dist/cjs/tools/displayTools/Labelmap/index.js.map +1 -1
- package/dist/cjs/tools/displayTools/Labelmap/labelmapDisplay.js +20 -2
- package/dist/cjs/tools/displayTools/Labelmap/labelmapDisplay.js.map +1 -1
- package/dist/cjs/tools/displayTools/Labelmap/validateLabelmap.d.ts +4 -0
- package/dist/cjs/tools/displayTools/Labelmap/validateLabelmap.js +38 -0
- package/dist/cjs/tools/displayTools/Labelmap/validateLabelmap.js.map +1 -0
- package/dist/cjs/tools/displayTools/Surface/addOrUpdateSurfaceToElement.d.ts +3 -0
- package/dist/cjs/tools/displayTools/Surface/addOrUpdateSurfaceToElement.js +112 -0
- package/dist/cjs/tools/displayTools/Surface/addOrUpdateSurfaceToElement.js.map +1 -0
- package/dist/cjs/tools/displayTools/Surface/surfaceConfig.d.ts +3 -0
- package/dist/cjs/tools/displayTools/Surface/surfaceConfig.js +11 -0
- package/dist/cjs/tools/displayTools/Surface/surfaceConfig.js.map +1 -0
- package/dist/cjs/tools/displayTools/Surface/surfaceDisplay.d.ts +7 -0
- package/dist/cjs/tools/displayTools/Surface/surfaceDisplay.js +173 -27
- package/dist/cjs/tools/displayTools/Surface/surfaceDisplay.js.map +1 -1
- package/dist/cjs/tools/displayTools/registerDisplayToolsWorker.d.ts +1 -0
- package/dist/cjs/tools/displayTools/registerDisplayToolsWorker.js +27 -0
- package/dist/cjs/tools/displayTools/registerDisplayToolsWorker.js.map +1 -0
- package/dist/cjs/tools/segmentation/BrushTool.js +1 -1
- package/dist/cjs/tools/segmentation/BrushTool.js.map +1 -1
- package/dist/cjs/tools/segmentation/CircleScissorsTool.js +1 -1
- package/dist/cjs/tools/segmentation/CircleScissorsTool.js.map +1 -1
- package/dist/cjs/tools/segmentation/PaintFillTool.js +1 -1
- package/dist/cjs/tools/segmentation/PaintFillTool.js.map +1 -1
- package/dist/cjs/tools/segmentation/RectangleScissorsTool.js +1 -1
- package/dist/cjs/tools/segmentation/RectangleScissorsTool.js.map +1 -1
- package/dist/cjs/tools/segmentation/SegmentSelectTool.d.ts +6 -2
- package/dist/cjs/tools/segmentation/SegmentSelectTool.js +45 -35
- package/dist/cjs/tools/segmentation/SegmentSelectTool.js.map +1 -1
- package/dist/cjs/tools/segmentation/SphereScissorsTool.js +1 -1
- package/dist/cjs/tools/segmentation/SphereScissorsTool.js.map +1 -1
- package/dist/cjs/tools/segmentation/strategies/BrushStrategy.js +7 -5
- package/dist/cjs/tools/segmentation/strategies/BrushStrategy.js.map +1 -1
- package/dist/cjs/tools/segmentation/strategies/compositions/regionFill.js +1 -1
- package/dist/cjs/tools/segmentation/strategies/compositions/regionFill.js.map +1 -1
- package/dist/cjs/tools/segmentation/strategies/fillSphere.js +14 -5
- package/dist/cjs/tools/segmentation/strategies/fillSphere.js.map +1 -1
- package/dist/cjs/tools/segmentation/strategies/utils/getStrategyData.js +21 -9
- package/dist/cjs/tools/segmentation/strategies/utils/getStrategyData.js.map +1 -1
- package/dist/cjs/tools/segmentation/strategies/utils/stackVolumeCheck.d.ts +5 -5
- package/dist/cjs/tools/segmentation/strategies/utils/stackVolumeCheck.js +15 -8
- package/dist/cjs/tools/segmentation/strategies/utils/stackVolumeCheck.js.map +1 -1
- package/dist/cjs/types/AnnotationTypes.d.ts +2 -0
- package/dist/cjs/types/ContourAnnotation.d.ts +6 -0
- package/dist/cjs/types/ContourAnnotation.js +7 -0
- package/dist/cjs/types/ContourAnnotation.js.map +1 -1
- package/dist/cjs/types/ContourSegmentationAnnotation.d.ts +0 -1
- package/dist/cjs/types/ContourTypes.d.ts +1 -0
- package/dist/cjs/types/EventTypes.d.ts +4 -1
- package/dist/cjs/types/ISpline.d.ts +1 -0
- package/dist/cjs/types/LabelmapTypes.d.ts +5 -1
- package/dist/cjs/types/PolySeg.d.ts +6 -0
- package/dist/cjs/types/PolySeg.js +3 -0
- package/dist/cjs/types/PolySeg.js.map +1 -0
- package/dist/cjs/types/SegmentationStateTypes.d.ts +12 -2
- package/dist/cjs/types/SplineProps.d.ts +1 -0
- package/dist/cjs/types/SurfaceTypes.d.ts +1 -1
- package/dist/cjs/types/index.d.ts +2 -1
- package/dist/cjs/utilities/boundingBox/getBoundingBoxAroundShape.js +6 -6
- package/dist/cjs/utilities/boundingBox/getBoundingBoxAroundShape.js.map +1 -1
- package/dist/cjs/utilities/contourSegmentation/addContourSegmentationAnnotation.d.ts +2 -0
- package/dist/cjs/utilities/contourSegmentation/addContourSegmentationAnnotation.js +20 -0
- package/dist/cjs/utilities/contourSegmentation/addContourSegmentationAnnotation.js.map +1 -0
- package/dist/cjs/utilities/contourSegmentation/areSameSegment.js +0 -2
- package/dist/cjs/utilities/contourSegmentation/areSameSegment.js.map +1 -1
- package/dist/cjs/utilities/contourSegmentation/index.d.ts +2 -0
- package/dist/cjs/utilities/contourSegmentation/index.js +5 -1
- package/dist/cjs/utilities/contourSegmentation/index.js.map +1 -1
- package/dist/cjs/utilities/contourSegmentation/removeContourSegmentationAnnotation.d.ts +2 -0
- package/dist/cjs/utilities/contourSegmentation/removeContourSegmentationAnnotation.js +19 -0
- package/dist/cjs/utilities/contourSegmentation/removeContourSegmentationAnnotation.js.map +1 -0
- package/dist/cjs/utilities/contours/detectContourHoles.js.map +1 -1
- package/dist/cjs/utilities/contours/generateContourSetsFromLabelmap.js +2 -2
- package/dist/cjs/utilities/contours/generateContourSetsFromLabelmap.js.map +1 -1
- package/dist/cjs/utilities/contours/getContourHolesDataCanvas.d.ts +3 -0
- package/dist/cjs/utilities/contours/getContourHolesDataCanvas.js +21 -0
- package/dist/cjs/utilities/contours/getContourHolesDataCanvas.js.map +1 -0
- package/dist/cjs/utilities/contours/getContourHolesDataWorld.d.ts +3 -0
- package/dist/cjs/utilities/contours/getContourHolesDataWorld.js +10 -0
- package/dist/cjs/utilities/contours/getContourHolesDataWorld.js.map +1 -0
- package/dist/cjs/utilities/contours/getDeduplicatedVTKPolyDataPoints.d.ts +11 -0
- package/dist/cjs/utilities/contours/getDeduplicatedVTKPolyDataPoints.js +50 -0
- package/dist/cjs/utilities/contours/getDeduplicatedVTKPolyDataPoints.js.map +1 -0
- package/dist/cjs/utilities/contours/index.d.ts +5 -2
- package/dist/cjs/utilities/contours/index.js +9 -3
- package/dist/cjs/utilities/contours/index.js.map +1 -1
- package/dist/cjs/utilities/contours/updateContourPolyline.d.ts +10 -0
- package/dist/cjs/utilities/contours/updateContourPolyline.js +64 -0
- package/dist/cjs/utilities/contours/updateContourPolyline.js.map +1 -0
- package/dist/cjs/utilities/index.d.ts +3 -1
- package/dist/cjs/utilities/index.js +5 -1
- package/dist/cjs/utilities/index.js.map +1 -1
- package/dist/cjs/utilities/math/polyline/containsPoint.js.map +1 -1
- package/dist/cjs/utilities/math/polyline/containsPoints.d.ts +2 -0
- package/dist/cjs/utilities/math/polyline/containsPoints.js +16 -0
- package/dist/cjs/utilities/math/polyline/containsPoints.js.map +1 -0
- package/dist/cjs/utilities/math/polyline/getWindingDirection.d.ts +2 -0
- package/dist/cjs/utilities/math/polyline/getWindingDirection.js +12 -0
- package/dist/cjs/utilities/math/polyline/getWindingDirection.js.map +1 -0
- package/dist/cjs/utilities/math/polyline/index.d.ts +4 -1
- package/dist/cjs/utilities/math/polyline/index.js +7 -1
- package/dist/cjs/utilities/math/polyline/index.js.map +1 -1
- package/dist/cjs/utilities/math/polyline/isPointInsidePolyline3D.d.ts +2 -0
- package/dist/cjs/utilities/math/polyline/isPointInsidePolyline3D.js +34 -0
- package/dist/cjs/utilities/math/polyline/isPointInsidePolyline3D.js.map +1 -0
- package/dist/cjs/utilities/math/polyline/planarFreehandROIInternalTypes.d.ts +1 -0
- package/dist/cjs/utilities/segmentation/contourAndFindLargestBidirectional.js +0 -1
- package/dist/cjs/utilities/segmentation/contourAndFindLargestBidirectional.js.map +1 -1
- package/dist/cjs/utilities/segmentation/getHoveredContourSegmentationAnnotation.d.ts +1 -0
- package/dist/cjs/utilities/segmentation/getHoveredContourSegmentationAnnotation.js +18 -0
- package/dist/cjs/utilities/segmentation/getHoveredContourSegmentationAnnotation.js.map +1 -0
- package/dist/cjs/utilities/segmentation/getSegmentAtLabelmapBorder.d.ts +7 -0
- package/dist/cjs/utilities/segmentation/getSegmentAtLabelmapBorder.js +77 -0
- package/dist/cjs/utilities/segmentation/getSegmentAtLabelmapBorder.js.map +1 -0
- package/dist/cjs/utilities/segmentation/getSegmentAtWorldPoint.d.ts +11 -0
- package/dist/cjs/utilities/segmentation/getSegmentAtWorldPoint.js +82 -0
- package/dist/cjs/utilities/segmentation/getSegmentAtWorldPoint.js.map +1 -0
- package/dist/cjs/utilities/segmentation/getUniqueSegmentIndices.d.ts +2 -0
- package/dist/cjs/utilities/segmentation/getUniqueSegmentIndices.js +59 -0
- package/dist/cjs/utilities/segmentation/getUniqueSegmentIndices.js.map +1 -0
- package/dist/cjs/utilities/segmentation/index.d.ts +5 -1
- package/dist/cjs/utilities/segmentation/index.js +9 -1
- package/dist/cjs/utilities/segmentation/index.js.map +1 -1
- package/dist/cjs/utilities/triggerAnnotationRenderForToolGroupIds.d.ts +2 -0
- package/dist/cjs/utilities/triggerAnnotationRenderForToolGroupIds.js +32 -0
- package/dist/cjs/utilities/triggerAnnotationRenderForToolGroupIds.js.map +1 -0
- package/dist/cjs/workers/clippingPlaneWorker.d.ts +1 -0
- package/dist/cjs/workers/clippingPlaneWorker.js +63 -0
- package/dist/cjs/workers/clippingPlaneWorker.js.map +1 -0
- package/dist/cjs/workers/polySegConverters.d.ts +1 -0
- package/dist/cjs/workers/polySegConverters.js +267 -0
- package/dist/cjs/workers/polySegConverters.js.map +1 -0
- package/dist/esm/drawingSvg/drawPath.js +49 -0
- package/dist/esm/drawingSvg/drawPath.js.map +1 -0
- package/dist/esm/drawingSvg/drawPolyline.js +2 -10
- package/dist/esm/drawingSvg/drawPolyline.js.map +1 -1
- package/dist/esm/drawingSvg/index.js +2 -1
- package/dist/esm/drawingSvg/index.js.map +1 -1
- package/dist/esm/enums/WorkerTypes.js +10 -0
- package/dist/esm/enums/WorkerTypes.js.map +1 -0
- package/dist/esm/enums/index.js +2 -1
- package/dist/esm/enums/index.js.map +1 -1
- package/dist/esm/eventDispatchers/shared/getActiveToolForMouseEvent.js.map +1 -1
- package/dist/esm/eventListeners/annotations/contourSegmentation/contourSegmentationCompleted.js +112 -43
- package/dist/esm/eventListeners/annotations/contourSegmentation/contourSegmentationCompleted.js.map +1 -1
- package/dist/esm/eventListeners/segmentation/imageChangeEventListener.js +3 -3
- package/dist/esm/eventListeners/segmentation/imageChangeEventListener.js.map +1 -1
- package/dist/esm/eventListeners/segmentation/labelmap/onLabelmapSegmentationDataModified.js +59 -45
- package/dist/esm/eventListeners/segmentation/labelmap/onLabelmapSegmentationDataModified.js.map +1 -1
- package/dist/esm/stateManagement/annotation/FrameOfReferenceSpecificAnnotationManager.js +5 -0
- package/dist/esm/stateManagement/annotation/FrameOfReferenceSpecificAnnotationManager.js.map +1 -1
- package/dist/esm/stateManagement/annotation/annotationState.js +46 -1
- package/dist/esm/stateManagement/annotation/annotationState.js.map +1 -1
- package/dist/esm/stateManagement/annotation/helpers/state.js +12 -2
- package/dist/esm/stateManagement/annotation/helpers/state.js.map +1 -1
- package/dist/esm/stateManagement/index.js +2 -2
- package/dist/esm/stateManagement/index.js.map +1 -1
- package/dist/esm/stateManagement/segmentation/SegmentationStateManager.js +4 -1
- package/dist/esm/stateManagement/segmentation/SegmentationStateManager.js.map +1 -1
- package/dist/esm/stateManagement/segmentation/addRepresentationData.js +30 -0
- package/dist/esm/stateManagement/segmentation/addRepresentationData.js.map +1 -0
- package/dist/esm/stateManagement/segmentation/addSegmentationRepresentation.js +32 -15
- package/dist/esm/stateManagement/segmentation/addSegmentationRepresentation.js.map +1 -1
- package/dist/esm/stateManagement/segmentation/config/segmentationVisibility.js +1 -46
- package/dist/esm/stateManagement/segmentation/config/segmentationVisibility.js.map +1 -1
- package/dist/esm/stateManagement/segmentation/convertStackToVolumeSegmentation.js +42 -27
- package/dist/esm/stateManagement/segmentation/convertStackToVolumeSegmentation.js.map +1 -1
- package/dist/esm/stateManagement/segmentation/convertVolumeToStackSegmentation.js +49 -25
- package/dist/esm/stateManagement/segmentation/convertVolumeToStackSegmentation.js.map +1 -1
- package/dist/esm/stateManagement/segmentation/helpers/validateSegmentationInput.js +6 -6
- package/dist/esm/stateManagement/segmentation/helpers/validateSegmentationInput.js.map +1 -1
- package/dist/esm/stateManagement/segmentation/index.js +3 -1
- package/dist/esm/stateManagement/segmentation/index.js.map +1 -1
- package/dist/esm/stateManagement/segmentation/polySeg/Contour/computeAndAddContourRepresentation.js +4 -0
- package/dist/esm/stateManagement/segmentation/polySeg/Contour/computeAndAddContourRepresentation.js.map +1 -0
- package/dist/esm/stateManagement/segmentation/polySeg/Labelmap/computeAndAddLabelmapRepresentation.js +7 -0
- package/dist/esm/stateManagement/segmentation/polySeg/Labelmap/computeAndAddLabelmapRepresentation.js.map +1 -0
- package/dist/esm/stateManagement/segmentation/polySeg/Labelmap/convertContourToLabelmap.js +142 -0
- package/dist/esm/stateManagement/segmentation/polySeg/Labelmap/convertContourToLabelmap.js.map +1 -0
- package/dist/esm/stateManagement/segmentation/polySeg/Labelmap/convertSurfaceToLabelmap.js +53 -0
- package/dist/esm/stateManagement/segmentation/polySeg/Labelmap/convertSurfaceToLabelmap.js.map +1 -0
- package/dist/esm/stateManagement/segmentation/polySeg/Labelmap/labelmapComputationStrategies.js +108 -0
- package/dist/esm/stateManagement/segmentation/polySeg/Labelmap/labelmapComputationStrategies.js.map +1 -0
- package/dist/esm/stateManagement/segmentation/polySeg/Surface/computeAndAddSurfaceRepresentation.js +8 -0
- package/dist/esm/stateManagement/segmentation/polySeg/Surface/computeAndAddSurfaceRepresentation.js.map +1 -0
- package/dist/esm/stateManagement/segmentation/polySeg/Surface/convertContourToSurface.js +37 -0
- package/dist/esm/stateManagement/segmentation/polySeg/Surface/convertContourToSurface.js.map +1 -0
- package/dist/esm/stateManagement/segmentation/polySeg/Surface/convertLabelmapToSurface.js +45 -0
- package/dist/esm/stateManagement/segmentation/polySeg/Surface/convertLabelmapToSurface.js.map +1 -0
- package/dist/esm/stateManagement/segmentation/polySeg/Surface/createAndCacheSurfacesFromRaw.js +41 -0
- package/dist/esm/stateManagement/segmentation/polySeg/Surface/createAndCacheSurfacesFromRaw.js.map +1 -0
- package/dist/esm/stateManagement/segmentation/polySeg/Surface/surfaceComputationStrategies.js +78 -0
- package/dist/esm/stateManagement/segmentation/polySeg/Surface/surfaceComputationStrategies.js.map +1 -0
- package/dist/esm/stateManagement/segmentation/polySeg/Surface/updateSurfaceData.js +59 -0
- package/dist/esm/stateManagement/segmentation/polySeg/Surface/updateSurfaceData.js.map +1 -0
- package/dist/esm/stateManagement/segmentation/polySeg/canComputeRequestedRepresentation.js +68 -0
- package/dist/esm/stateManagement/segmentation/polySeg/canComputeRequestedRepresentation.js.map +1 -0
- package/dist/esm/stateManagement/segmentation/polySeg/computeAndAddRepresentation.js +47 -0
- package/dist/esm/stateManagement/segmentation/polySeg/computeAndAddRepresentation.js.map +1 -0
- package/dist/esm/stateManagement/segmentation/polySeg/index.js +6 -0
- package/dist/esm/stateManagement/segmentation/polySeg/index.js.map +1 -0
- package/dist/esm/stateManagement/segmentation/polySeg/registerPolySegWorker.js +23 -0
- package/dist/esm/stateManagement/segmentation/polySeg/registerPolySegWorker.js.map +1 -0
- package/dist/esm/stateManagement/segmentation/segmentIndex.js +4 -0
- package/dist/esm/stateManagement/segmentation/segmentIndex.js.map +1 -1
- package/dist/esm/stateManagement/segmentation/segmentationState.js +28 -1
- package/dist/esm/stateManagement/segmentation/segmentationState.js.map +1 -1
- package/dist/esm/store/ToolGroupManager/ToolGroup.js +3 -2
- package/dist/esm/store/ToolGroupManager/ToolGroup.js.map +1 -1
- package/dist/esm/tools/ScaleOverlayTool.js +2 -1
- package/dist/esm/tools/ScaleOverlayTool.js.map +1 -1
- package/dist/esm/tools/SegmentationIntersectionTool.js +1 -1
- package/dist/esm/tools/SegmentationIntersectionTool.js.map +1 -1
- package/dist/esm/tools/annotation/LivewireContourSegmentationTool.js +1 -1
- package/dist/esm/tools/annotation/LivewireContourSegmentationTool.js.map +1 -1
- package/dist/esm/tools/annotation/LivewireContourTool.js +28 -28
- package/dist/esm/tools/annotation/LivewireContourTool.js.map +1 -1
- package/dist/esm/tools/annotation/PlanarFreehandContourSegmentationTool.js +0 -11
- package/dist/esm/tools/annotation/PlanarFreehandContourSegmentationTool.js.map +1 -1
- package/dist/esm/tools/annotation/PlanarFreehandROITool.js +3 -3
- package/dist/esm/tools/annotation/PlanarFreehandROITool.js.map +1 -1
- package/dist/esm/tools/annotation/ProbeTool.js +3 -0
- package/dist/esm/tools/annotation/ProbeTool.js.map +1 -1
- package/dist/esm/tools/annotation/SplineROITool.js +37 -19
- package/dist/esm/tools/annotation/SplineROITool.js.map +1 -1
- package/dist/esm/tools/annotation/planarFreehandROITool/closedContourEditLoop.js +12 -7
- package/dist/esm/tools/annotation/planarFreehandROITool/closedContourEditLoop.js.map +1 -1
- package/dist/esm/tools/annotation/planarFreehandROITool/drawLoop.js +26 -20
- package/dist/esm/tools/annotation/planarFreehandROITool/drawLoop.js.map +1 -1
- package/dist/esm/tools/annotation/planarFreehandROITool/openContourEditLoop.js +16 -10
- package/dist/esm/tools/annotation/planarFreehandROITool/openContourEditLoop.js.map +1 -1
- package/dist/esm/tools/annotation/planarFreehandROITool/openContourEndEditLoop.js +1 -1
- package/dist/esm/tools/annotation/planarFreehandROITool/openContourEndEditLoop.js.map +1 -1
- package/dist/esm/tools/annotation/planarFreehandROITool/renderMethods.js +20 -8
- package/dist/esm/tools/annotation/planarFreehandROITool/renderMethods.js.map +1 -1
- package/dist/esm/tools/annotation/splines/LinearSpline.js +1 -1
- package/dist/esm/tools/annotation/splines/LinearSpline.js.map +1 -1
- package/dist/esm/tools/annotation/splines/Spline.js +5 -1
- package/dist/esm/tools/annotation/splines/Spline.js.map +1 -1
- package/dist/esm/tools/base/AnnotationTool.js +1 -1
- package/dist/esm/tools/base/AnnotationTool.js.map +1 -1
- package/dist/esm/tools/base/BaseTool.js +1 -1
- package/dist/esm/tools/base/BaseTool.js.map +1 -1
- package/dist/esm/tools/base/ContourBaseTool.js +20 -3
- package/dist/esm/tools/base/ContourBaseTool.js.map +1 -1
- package/dist/esm/tools/base/ContourSegmentationBaseTool.js +28 -24
- package/dist/esm/tools/base/ContourSegmentationBaseTool.js.map +1 -1
- package/dist/esm/tools/displayTools/Contour/contourConfig.js +1 -0
- package/dist/esm/tools/displayTools/Contour/contourConfig.js.map +1 -1
- package/dist/esm/tools/displayTools/Contour/contourDisplay.js +10 -7
- package/dist/esm/tools/displayTools/Contour/contourDisplay.js.map +1 -1
- package/dist/esm/tools/displayTools/Contour/removeContourFromElement.js.map +1 -1
- package/dist/esm/tools/displayTools/Contour/vtkContour/addContourSetsToElement.js.map +1 -0
- package/dist/esm/tools/displayTools/Contour/{addOrUpdateContourSets.js → vtkContour/addOrUpdateVTKContourSets.js} +4 -4
- package/dist/esm/tools/displayTools/Contour/vtkContour/addOrUpdateVTKContourSets.js.map +1 -0
- package/dist/esm/tools/displayTools/Contour/vtkContour/contourConfigCache.js.map +1 -0
- package/dist/esm/tools/displayTools/Contour/{updateContourSets.js → vtkContour/updateVTKContourSets.js} +2 -2
- package/dist/esm/tools/displayTools/Contour/vtkContour/updateVTKContourSets.js.map +1 -0
- package/dist/esm/tools/displayTools/Contour/vtkContour/utils.js.map +1 -0
- package/dist/esm/tools/displayTools/Labelmap/addLabelmapToElement.js +1 -1
- package/dist/esm/tools/displayTools/Labelmap/addLabelmapToElement.js.map +1 -1
- package/dist/esm/tools/displayTools/Labelmap/index.js +2 -1
- package/dist/esm/tools/displayTools/Labelmap/index.js.map +1 -1
- package/dist/esm/tools/displayTools/Labelmap/labelmapDisplay.js +20 -2
- package/dist/esm/tools/displayTools/Labelmap/labelmapDisplay.js.map +1 -1
- package/dist/esm/tools/displayTools/Labelmap/validateLabelmap.js +33 -0
- package/dist/esm/tools/displayTools/Labelmap/validateLabelmap.js.map +1 -0
- package/dist/esm/tools/displayTools/Surface/addOrUpdateSurfaceToElement.js +106 -0
- package/dist/esm/tools/displayTools/Surface/addOrUpdateSurfaceToElement.js.map +1 -0
- package/dist/esm/tools/displayTools/Surface/surfaceConfig.js +9 -0
- package/dist/esm/tools/displayTools/Surface/surfaceConfig.js.map +1 -0
- package/dist/esm/tools/displayTools/Surface/surfaceDisplay.js +162 -28
- package/dist/esm/tools/displayTools/Surface/surfaceDisplay.js.map +1 -1
- package/dist/esm/tools/displayTools/registerDisplayToolsWorker.js +23 -0
- package/dist/esm/tools/displayTools/registerDisplayToolsWorker.js.map +1 -0
- package/dist/esm/tools/segmentation/BrushTool.js +1 -1
- package/dist/esm/tools/segmentation/BrushTool.js.map +1 -1
- package/dist/esm/tools/segmentation/CircleScissorsTool.js +1 -1
- package/dist/esm/tools/segmentation/CircleScissorsTool.js.map +1 -1
- package/dist/esm/tools/segmentation/PaintFillTool.js +1 -1
- package/dist/esm/tools/segmentation/PaintFillTool.js.map +1 -1
- package/dist/esm/tools/segmentation/RectangleScissorsTool.js +1 -1
- package/dist/esm/tools/segmentation/RectangleScissorsTool.js.map +1 -1
- package/dist/esm/tools/segmentation/SegmentSelectTool.js +47 -37
- package/dist/esm/tools/segmentation/SegmentSelectTool.js.map +1 -1
- package/dist/esm/tools/segmentation/SphereScissorsTool.js +1 -1
- package/dist/esm/tools/segmentation/SphereScissorsTool.js.map +1 -1
- package/dist/esm/tools/segmentation/strategies/BrushStrategy.js +7 -5
- package/dist/esm/tools/segmentation/strategies/BrushStrategy.js.map +1 -1
- package/dist/esm/tools/segmentation/strategies/compositions/regionFill.js +1 -1
- package/dist/esm/tools/segmentation/strategies/compositions/regionFill.js.map +1 -1
- package/dist/esm/tools/segmentation/strategies/fillSphere.js +14 -5
- package/dist/esm/tools/segmentation/strategies/fillSphere.js.map +1 -1
- package/dist/esm/tools/segmentation/strategies/utils/getStrategyData.js +21 -9
- package/dist/esm/tools/segmentation/strategies/utils/getStrategyData.js.map +1 -1
- package/dist/esm/tools/segmentation/strategies/utils/stackVolumeCheck.js +15 -7
- package/dist/esm/tools/segmentation/strategies/utils/stackVolumeCheck.js.map +1 -1
- package/dist/esm/types/ContourAnnotation.js +6 -1
- package/dist/esm/types/ContourAnnotation.js.map +1 -1
- package/dist/esm/types/PolySeg.js +2 -0
- package/dist/esm/types/PolySeg.js.map +1 -0
- package/dist/esm/utilities/boundingBox/getBoundingBoxAroundShape.js +3 -2
- package/dist/esm/utilities/boundingBox/getBoundingBoxAroundShape.js.map +1 -1
- package/dist/esm/utilities/contourSegmentation/addContourSegmentationAnnotation.js +16 -0
- package/dist/esm/utilities/contourSegmentation/addContourSegmentationAnnotation.js.map +1 -0
- package/dist/esm/utilities/contourSegmentation/areSameSegment.js +0 -2
- package/dist/esm/utilities/contourSegmentation/areSameSegment.js.map +1 -1
- package/dist/esm/utilities/contourSegmentation/index.js +2 -0
- package/dist/esm/utilities/contourSegmentation/index.js.map +1 -1
- package/dist/esm/utilities/contourSegmentation/removeContourSegmentationAnnotation.js +15 -0
- package/dist/esm/utilities/contourSegmentation/removeContourSegmentationAnnotation.js.map +1 -0
- package/dist/esm/utilities/contours/detectContourHoles.js.map +1 -1
- package/dist/esm/utilities/contours/generateContourSetsFromLabelmap.js +2 -2
- package/dist/esm/utilities/contours/generateContourSetsFromLabelmap.js.map +1 -1
- package/dist/esm/utilities/contours/getContourHolesDataCanvas.js +15 -0
- package/dist/esm/utilities/contours/getContourHolesDataCanvas.js.map +1 -0
- package/dist/esm/utilities/contours/getContourHolesDataWorld.js +6 -0
- package/dist/esm/utilities/contours/getContourHolesDataWorld.js.map +1 -0
- package/dist/esm/utilities/contours/getDeduplicatedVTKPolyDataPoints.js +46 -0
- package/dist/esm/utilities/contours/getDeduplicatedVTKPolyDataPoints.js.map +1 -0
- package/dist/esm/utilities/contours/index.js +5 -2
- package/dist/esm/utilities/contours/index.js.map +1 -1
- package/dist/esm/utilities/contours/updateContourPolyline.js +38 -0
- package/dist/esm/utilities/contours/updateContourPolyline.js.map +1 -0
- package/dist/esm/utilities/index.js +3 -1
- package/dist/esm/utilities/index.js.map +1 -1
- package/dist/esm/utilities/math/polyline/containsPoint.js.map +1 -1
- package/dist/esm/utilities/math/polyline/containsPoints.js +10 -0
- package/dist/esm/utilities/math/polyline/containsPoints.js.map +1 -0
- package/dist/esm/utilities/math/polyline/getWindingDirection.js +6 -0
- package/dist/esm/utilities/math/polyline/getWindingDirection.js.map +1 -0
- package/dist/esm/utilities/math/polyline/index.js +4 -1
- package/dist/esm/utilities/math/polyline/index.js.map +1 -1
- package/dist/esm/utilities/math/polyline/isPointInsidePolyline3D.js +27 -0
- package/dist/esm/utilities/math/polyline/isPointInsidePolyline3D.js.map +1 -0
- package/dist/esm/utilities/segmentation/contourAndFindLargestBidirectional.js +0 -1
- package/dist/esm/utilities/segmentation/contourAndFindLargestBidirectional.js.map +1 -1
- package/dist/esm/utilities/segmentation/getHoveredContourSegmentationAnnotation.js +14 -0
- package/dist/esm/utilities/segmentation/getHoveredContourSegmentationAnnotation.js.map +1 -0
- package/dist/esm/utilities/segmentation/getSegmentAtLabelmapBorder.js +73 -0
- package/dist/esm/utilities/segmentation/getSegmentAtLabelmapBorder.js.map +1 -0
- package/dist/esm/utilities/segmentation/getSegmentAtWorldPoint.js +75 -0
- package/dist/esm/utilities/segmentation/getSegmentAtWorldPoint.js.map +1 -0
- package/dist/esm/utilities/segmentation/getUniqueSegmentIndices.js +55 -0
- package/dist/esm/utilities/segmentation/getUniqueSegmentIndices.js.map +1 -0
- package/dist/esm/utilities/segmentation/index.js +5 -1
- package/dist/esm/utilities/segmentation/index.js.map +1 -1
- package/dist/esm/utilities/triggerAnnotationRenderForToolGroupIds.js +25 -0
- package/dist/esm/utilities/triggerAnnotationRenderForToolGroupIds.js.map +1 -0
- package/dist/esm/workers/clippingPlaneWorker.js +58 -0
- package/dist/esm/workers/clippingPlaneWorker.js.map +1 -0
- package/dist/esm/workers/polySegConverters.js +241 -0
- package/dist/esm/workers/polySegConverters.js.map +1 -0
- package/dist/types/drawingSvg/drawPath.d.ts +12 -0
- package/dist/types/drawingSvg/drawPath.d.ts.map +1 -0
- package/dist/types/drawingSvg/drawPolyline.d.ts +1 -1
- package/dist/types/drawingSvg/drawPolyline.d.ts.map +1 -1
- package/dist/types/drawingSvg/index.d.ts +2 -1
- package/dist/types/drawingSvg/index.d.ts.map +1 -1
- package/dist/types/enums/WorkerTypes.d.ts +9 -0
- package/dist/types/enums/WorkerTypes.d.ts.map +1 -0
- package/dist/types/enums/index.d.ts +2 -1
- package/dist/types/eventListeners/annotations/contourSegmentation/contourSegmentationCompleted.d.ts +1 -1
- package/dist/types/eventListeners/annotations/contourSegmentation/contourSegmentationCompleted.d.ts.map +1 -1
- package/dist/types/eventListeners/segmentation/imageChangeEventListener.d.ts.map +1 -1
- package/dist/types/eventListeners/segmentation/labelmap/onLabelmapSegmentationDataModified.d.ts.map +1 -1
- package/dist/types/stateManagement/annotation/FrameOfReferenceSpecificAnnotationManager.d.ts +1 -0
- package/dist/types/stateManagement/annotation/FrameOfReferenceSpecificAnnotationManager.d.ts.map +1 -1
- package/dist/types/stateManagement/annotation/annotationState.d.ts +7 -1
- package/dist/types/stateManagement/annotation/annotationState.d.ts.map +1 -1
- package/dist/types/stateManagement/annotation/helpers/state.d.ts +2 -1
- package/dist/types/stateManagement/annotation/helpers/state.d.ts.map +1 -1
- package/dist/types/stateManagement/index.d.ts +6 -1
- package/dist/types/stateManagement/segmentation/SegmentationStateManager.d.ts.map +1 -1
- package/dist/types/stateManagement/segmentation/addRepresentationData.d.ts +13 -0
- package/dist/types/stateManagement/segmentation/addRepresentationData.d.ts.map +1 -0
- package/dist/types/stateManagement/segmentation/addSegmentationRepresentation.d.ts.map +1 -1
- package/dist/types/stateManagement/segmentation/config/segmentationVisibility.d.ts.map +1 -1
- package/dist/types/stateManagement/segmentation/convertStackToVolumeSegmentation.d.ts +9 -2
- package/dist/types/stateManagement/segmentation/convertStackToVolumeSegmentation.d.ts.map +1 -1
- package/dist/types/stateManagement/segmentation/convertVolumeToStackSegmentation.d.ts +13 -0
- package/dist/types/stateManagement/segmentation/convertVolumeToStackSegmentation.d.ts.map +1 -1
- package/dist/types/stateManagement/segmentation/helpers/validateSegmentationInput.d.ts.map +1 -1
- package/dist/types/stateManagement/segmentation/index.d.ts +3 -1
- package/dist/types/stateManagement/segmentation/index.d.ts.map +1 -1
- package/dist/types/stateManagement/segmentation/polySeg/Contour/computeAndAddContourRepresentation.d.ts +3 -0
- package/dist/types/stateManagement/segmentation/polySeg/Contour/computeAndAddContourRepresentation.d.ts.map +1 -0
- package/dist/types/stateManagement/segmentation/polySeg/Labelmap/computeAndAddLabelmapRepresentation.d.ts +3 -0
- package/dist/types/stateManagement/segmentation/polySeg/Labelmap/computeAndAddLabelmapRepresentation.d.ts.map +1 -0
- package/dist/types/stateManagement/segmentation/polySeg/Labelmap/convertContourToLabelmap.d.ts +8 -0
- package/dist/types/stateManagement/segmentation/polySeg/Labelmap/convertContourToLabelmap.d.ts.map +1 -0
- package/dist/types/stateManagement/segmentation/polySeg/Labelmap/convertSurfaceToLabelmap.d.ts +7 -0
- package/dist/types/stateManagement/segmentation/polySeg/Labelmap/convertSurfaceToLabelmap.d.ts.map +1 -0
- package/dist/types/stateManagement/segmentation/polySeg/Labelmap/labelmapComputationStrategies.d.ts +7 -0
- package/dist/types/stateManagement/segmentation/polySeg/Labelmap/labelmapComputationStrategies.d.ts.map +1 -0
- package/dist/types/stateManagement/segmentation/polySeg/Surface/computeAndAddSurfaceRepresentation.d.ts +5 -0
- package/dist/types/stateManagement/segmentation/polySeg/Surface/computeAndAddSurfaceRepresentation.d.ts.map +1 -0
- package/dist/types/stateManagement/segmentation/polySeg/Surface/convertContourToSurface.d.ts +4 -0
- package/dist/types/stateManagement/segmentation/polySeg/Surface/convertContourToSurface.d.ts.map +1 -0
- package/dist/types/stateManagement/segmentation/polySeg/Surface/convertLabelmapToSurface.d.ts +4 -0
- package/dist/types/stateManagement/segmentation/polySeg/Surface/convertLabelmapToSurface.d.ts.map +1 -0
- package/dist/types/stateManagement/segmentation/polySeg/Surface/createAndCacheSurfacesFromRaw.d.ts +6 -0
- package/dist/types/stateManagement/segmentation/polySeg/Surface/createAndCacheSurfacesFromRaw.d.ts.map +1 -0
- package/dist/types/stateManagement/segmentation/polySeg/Surface/surfaceComputationStrategies.d.ts +13 -0
- package/dist/types/stateManagement/segmentation/polySeg/Surface/surfaceComputationStrategies.d.ts.map +1 -0
- package/dist/types/stateManagement/segmentation/polySeg/Surface/updateSurfaceData.d.ts +2 -0
- package/dist/types/stateManagement/segmentation/polySeg/Surface/updateSurfaceData.d.ts.map +1 -0
- package/dist/types/stateManagement/segmentation/polySeg/canComputeRequestedRepresentation.d.ts +3 -0
- package/dist/types/stateManagement/segmentation/polySeg/canComputeRequestedRepresentation.d.ts.map +1 -0
- package/dist/types/stateManagement/segmentation/polySeg/computeAndAddRepresentation.d.ts +4 -0
- package/dist/types/stateManagement/segmentation/polySeg/computeAndAddRepresentation.d.ts.map +1 -0
- package/dist/types/stateManagement/segmentation/polySeg/index.d.ts +6 -0
- package/dist/types/stateManagement/segmentation/polySeg/index.d.ts.map +1 -0
- package/dist/types/stateManagement/segmentation/polySeg/registerPolySegWorker.d.ts +2 -0
- package/dist/types/stateManagement/segmentation/polySeg/registerPolySegWorker.d.ts.map +1 -0
- package/dist/types/stateManagement/segmentation/segmentIndex.d.ts.map +1 -1
- package/dist/types/stateManagement/segmentation/segmentationState.d.ts +6 -1
- package/dist/types/stateManagement/segmentation/segmentationState.d.ts.map +1 -1
- package/dist/types/store/ToolGroupManager/ToolGroup.d.ts +3 -1
- package/dist/types/store/ToolGroupManager/ToolGroup.d.ts.map +1 -1
- package/dist/types/tools/ScaleOverlayTool.d.ts.map +1 -1
- package/dist/types/tools/annotation/LivewireContourTool.d.ts +4 -3
- package/dist/types/tools/annotation/LivewireContourTool.d.ts.map +1 -1
- package/dist/types/tools/annotation/PlanarFreehandContourSegmentationTool.d.ts +1 -2
- package/dist/types/tools/annotation/PlanarFreehandContourSegmentationTool.d.ts.map +1 -1
- package/dist/types/tools/annotation/PlanarFreehandROITool.d.ts.map +1 -1
- package/dist/types/tools/annotation/ProbeTool.d.ts.map +1 -1
- package/dist/types/tools/annotation/SplineROITool.d.ts +6 -3
- package/dist/types/tools/annotation/SplineROITool.d.ts.map +1 -1
- package/dist/types/tools/annotation/planarFreehandROITool/closedContourEditLoop.d.ts.map +1 -1
- package/dist/types/tools/annotation/planarFreehandROITool/drawLoop.d.ts.map +1 -1
- package/dist/types/tools/annotation/planarFreehandROITool/openContourEditLoop.d.ts.map +1 -1
- package/dist/types/tools/annotation/planarFreehandROITool/renderMethods.d.ts.map +1 -1
- package/dist/types/tools/annotation/splines/Spline.d.ts +2 -0
- package/dist/types/tools/annotation/splines/Spline.d.ts.map +1 -1
- package/dist/types/tools/base/AnnotationTool.d.ts.map +1 -1
- package/dist/types/tools/base/BaseTool.d.ts.map +1 -1
- package/dist/types/tools/base/ContourBaseTool.d.ts +1 -0
- package/dist/types/tools/base/ContourBaseTool.d.ts.map +1 -1
- package/dist/types/tools/base/ContourSegmentationBaseTool.d.ts +1 -2
- package/dist/types/tools/base/ContourSegmentationBaseTool.d.ts.map +1 -1
- package/dist/types/tools/displayTools/Contour/contourConfig.d.ts.map +1 -1
- package/dist/types/tools/displayTools/Contour/contourDisplay.d.ts.map +1 -1
- package/dist/types/tools/displayTools/Contour/removeContourFromElement.d.ts.map +1 -1
- package/dist/types/tools/displayTools/Contour/{addContourSetsToElement.d.ts → vtkContour/addContourSetsToElement.d.ts} +1 -1
- package/dist/types/tools/displayTools/Contour/vtkContour/addContourSetsToElement.d.ts.map +1 -0
- package/dist/types/tools/displayTools/Contour/vtkContour/addOrUpdateVTKContourSets.d.ts +4 -0
- package/dist/types/tools/displayTools/Contour/vtkContour/addOrUpdateVTKContourSets.d.ts.map +1 -0
- package/dist/types/tools/displayTools/Contour/vtkContour/contourConfigCache.d.ts.map +1 -0
- package/dist/types/tools/displayTools/Contour/vtkContour/updateVTKContourSets.d.ts +4 -0
- package/dist/types/tools/displayTools/Contour/vtkContour/updateVTKContourSets.d.ts.map +1 -0
- package/dist/types/tools/displayTools/Contour/{utils.d.ts → vtkContour/utils.d.ts} +2 -2
- package/dist/types/tools/displayTools/Contour/vtkContour/utils.d.ts.map +1 -0
- package/dist/types/tools/displayTools/Labelmap/index.d.ts +2 -1
- package/dist/types/tools/displayTools/Labelmap/index.d.ts.map +1 -1
- package/dist/types/tools/displayTools/Labelmap/labelmapDisplay.d.ts.map +1 -1
- package/dist/types/tools/displayTools/Labelmap/validateLabelmap.d.ts +5 -0
- package/dist/types/tools/displayTools/Labelmap/validateLabelmap.d.ts.map +1 -0
- package/dist/types/tools/displayTools/Surface/addOrUpdateSurfaceToElement.d.ts +4 -0
- package/dist/types/tools/displayTools/Surface/addOrUpdateSurfaceToElement.d.ts.map +1 -0
- package/dist/types/tools/displayTools/Surface/surfaceConfig.d.ts +4 -0
- package/dist/types/tools/displayTools/Surface/surfaceConfig.d.ts.map +1 -0
- package/dist/types/tools/displayTools/Surface/surfaceDisplay.d.ts +7 -0
- package/dist/types/tools/displayTools/Surface/surfaceDisplay.d.ts.map +1 -1
- package/dist/types/tools/displayTools/registerDisplayToolsWorker.d.ts +2 -0
- package/dist/types/tools/displayTools/registerDisplayToolsWorker.d.ts.map +1 -0
- package/dist/types/tools/segmentation/CircleScissorsTool.d.ts.map +1 -1
- package/dist/types/tools/segmentation/RectangleScissorsTool.d.ts.map +1 -1
- package/dist/types/tools/segmentation/SegmentSelectTool.d.ts +6 -2
- package/dist/types/tools/segmentation/SegmentSelectTool.d.ts.map +1 -1
- package/dist/types/tools/segmentation/SphereScissorsTool.d.ts.map +1 -1
- package/dist/types/tools/segmentation/strategies/BrushStrategy.d.ts.map +1 -1
- package/dist/types/tools/segmentation/strategies/fillSphere.d.ts.map +1 -1
- package/dist/types/tools/segmentation/strategies/utils/getStrategyData.d.ts.map +1 -1
- package/dist/types/tools/segmentation/strategies/utils/stackVolumeCheck.d.ts +5 -5
- package/dist/types/tools/segmentation/strategies/utils/stackVolumeCheck.d.ts.map +1 -1
- package/dist/types/types/AnnotationTypes.d.ts +2 -0
- package/dist/types/types/AnnotationTypes.d.ts.map +1 -1
- package/dist/types/types/ContourAnnotation.d.ts +6 -0
- package/dist/types/types/ContourAnnotation.d.ts.map +1 -1
- package/dist/types/types/ContourSegmentationAnnotation.d.ts +0 -1
- package/dist/types/types/ContourSegmentationAnnotation.d.ts.map +1 -1
- package/dist/types/types/ContourTypes.d.ts +1 -0
- package/dist/types/types/ContourTypes.d.ts.map +1 -1
- package/dist/types/types/EventTypes.d.ts +4 -1
- package/dist/types/types/EventTypes.d.ts.map +1 -1
- package/dist/types/types/ISpline.d.ts +1 -0
- package/dist/types/types/ISpline.d.ts.map +1 -1
- package/dist/types/types/LabelmapTypes.d.ts +5 -1
- package/dist/types/types/LabelmapTypes.d.ts.map +1 -1
- package/dist/types/types/PolySeg.d.ts +7 -0
- package/dist/types/types/PolySeg.d.ts.map +1 -0
- package/dist/types/types/SegmentationStateTypes.d.ts +12 -2
- package/dist/types/types/SegmentationStateTypes.d.ts.map +1 -1
- package/dist/types/types/SplineProps.d.ts +1 -0
- package/dist/types/types/SplineProps.d.ts.map +1 -1
- package/dist/types/types/SurfaceTypes.d.ts +1 -1
- package/dist/types/types/SurfaceTypes.d.ts.map +1 -1
- package/dist/types/types/index.d.ts +2 -1
- package/dist/types/types/index.d.ts.map +1 -1
- package/dist/types/utilities/boundingBox/getBoundingBoxAroundShape.d.ts.map +1 -1
- package/dist/types/utilities/contourSegmentation/addContourSegmentationAnnotation.d.ts +3 -0
- package/dist/types/utilities/contourSegmentation/addContourSegmentationAnnotation.d.ts.map +1 -0
- package/dist/types/utilities/contourSegmentation/areSameSegment.d.ts.map +1 -1
- package/dist/types/utilities/contourSegmentation/index.d.ts +2 -0
- package/dist/types/utilities/contourSegmentation/index.d.ts.map +1 -1
- package/dist/types/utilities/contourSegmentation/removeContourSegmentationAnnotation.d.ts +3 -0
- package/dist/types/utilities/contourSegmentation/removeContourSegmentationAnnotation.d.ts.map +1 -0
- package/dist/types/utilities/contours/detectContourHoles.d.ts.map +1 -1
- package/dist/types/utilities/contours/getContourHolesDataCanvas.d.ts +4 -0
- package/dist/types/utilities/contours/getContourHolesDataCanvas.d.ts.map +1 -0
- package/dist/types/utilities/contours/getContourHolesDataWorld.d.ts +4 -0
- package/dist/types/utilities/contours/getContourHolesDataWorld.d.ts.map +1 -0
- package/dist/types/utilities/contours/getDeduplicatedVTKPolyDataPoints.d.ts +12 -0
- package/dist/types/utilities/contours/getDeduplicatedVTKPolyDataPoints.d.ts.map +1 -0
- package/dist/types/utilities/contours/index.d.ts +5 -2
- package/dist/types/utilities/contours/index.d.ts.map +1 -1
- package/dist/types/utilities/contours/updateContourPolyline.d.ts +11 -0
- package/dist/types/utilities/contours/updateContourPolyline.d.ts.map +1 -0
- package/dist/types/utilities/index.d.ts +3 -1
- package/dist/types/utilities/index.d.ts.map +1 -1
- package/dist/types/utilities/math/polyline/containsPoint.d.ts.map +1 -1
- package/dist/types/utilities/math/polyline/containsPoints.d.ts +3 -0
- package/dist/types/utilities/math/polyline/containsPoints.d.ts.map +1 -0
- package/dist/types/utilities/math/polyline/getWindingDirection.d.ts +3 -0
- package/dist/types/utilities/math/polyline/getWindingDirection.d.ts.map +1 -0
- package/dist/types/utilities/math/polyline/index.d.ts +4 -1
- package/dist/types/utilities/math/polyline/index.d.ts.map +1 -1
- package/dist/types/utilities/math/polyline/isPointInsidePolyline3D.d.ts +3 -0
- package/dist/types/utilities/math/polyline/isPointInsidePolyline3D.d.ts.map +1 -0
- package/dist/types/utilities/math/polyline/planarFreehandROIInternalTypes.d.ts +1 -0
- package/dist/types/utilities/math/polyline/planarFreehandROIInternalTypes.d.ts.map +1 -1
- package/dist/types/utilities/segmentation/contourAndFindLargestBidirectional.d.ts.map +1 -1
- package/dist/types/utilities/segmentation/getHoveredContourSegmentationAnnotation.d.ts +2 -0
- package/dist/types/utilities/segmentation/getHoveredContourSegmentationAnnotation.d.ts.map +1 -0
- package/dist/types/utilities/segmentation/getSegmentAtLabelmapBorder.d.ts +8 -0
- package/dist/types/utilities/segmentation/getSegmentAtLabelmapBorder.d.ts.map +1 -0
- package/dist/types/utilities/segmentation/getSegmentAtWorldPoint.d.ts +12 -0
- package/dist/types/utilities/segmentation/getSegmentAtWorldPoint.d.ts.map +1 -0
- package/dist/types/utilities/segmentation/getUniqueSegmentIndices.d.ts +3 -0
- package/dist/types/utilities/segmentation/getUniqueSegmentIndices.d.ts.map +1 -0
- package/dist/types/utilities/segmentation/index.d.ts +5 -1
- package/dist/types/utilities/segmentation/index.d.ts.map +1 -1
- package/dist/types/utilities/triggerAnnotationRenderForToolGroupIds.d.ts +3 -0
- package/dist/types/utilities/triggerAnnotationRenderForToolGroupIds.d.ts.map +1 -0
- package/dist/types/workers/clippingPlaneWorker.d.ts +2 -0
- package/dist/types/workers/clippingPlaneWorker.d.ts.map +1 -0
- package/dist/types/workers/polySegConverters.d.ts +2 -0
- package/dist/types/workers/polySegConverters.d.ts.map +1 -0
- package/dist/umd/17dd54813d5acc10bf8f.wasm +0 -0
- package/dist/umd/444.index.js +3 -0
- package/dist/umd/444.index.js.LICENSE.txt +5 -0
- package/dist/umd/444.index.js.map +1 -0
- package/dist/umd/78.index.js +3 -0
- package/dist/umd/78.index.js.LICENSE.txt +5 -0
- package/dist/umd/78.index.js.map +1 -0
- package/dist/umd/985.index.js +2 -0
- package/dist/umd/985.index.js.map +1 -0
- package/dist/umd/index.js +1 -1
- package/dist/umd/index.js.map +1 -1
- package/package.json +5 -3
- package/src/drawingSvg/drawPath.ts +96 -0
- package/src/drawingSvg/drawPolyline.ts +12 -16
- package/src/drawingSvg/index.ts +2 -0
- package/src/enums/WorkerTypes.ts +16 -0
- package/src/enums/index.js +2 -0
- package/src/eventDispatchers/shared/getActiveToolForMouseEvent.ts +1 -1
- package/src/eventListeners/annotations/contourSegmentation/contourSegmentationCompleted.ts +204 -75
- package/src/eventListeners/segmentation/imageChangeEventListener.ts +3 -4
- package/src/eventListeners/segmentation/labelmap/onLabelmapSegmentationDataModified.ts +97 -69
- package/src/stateManagement/annotation/FrameOfReferenceSpecificAnnotationManager.ts +11 -0
- package/src/stateManagement/annotation/annotationState.ts +107 -0
- package/src/stateManagement/annotation/helpers/state.ts +29 -1
- package/src/stateManagement/index.js +10 -0
- package/src/stateManagement/segmentation/SegmentationStateManager.ts +4 -1
- package/src/stateManagement/segmentation/addRepresentationData.ts +71 -0
- package/src/stateManagement/segmentation/addSegmentationRepresentation.ts +39 -16
- package/src/stateManagement/segmentation/config/segmentationVisibility.ts +1 -59
- package/src/stateManagement/segmentation/convertStackToVolumeSegmentation.ts +74 -37
- package/src/stateManagement/segmentation/convertVolumeToStackSegmentation.ts +102 -38
- package/src/stateManagement/segmentation/helpers/validateSegmentationInput.ts +13 -8
- package/src/stateManagement/segmentation/index.ts +9 -2
- package/src/stateManagement/segmentation/polySeg/Contour/computeAndAddContourRepresentation.ts +17 -0
- package/src/stateManagement/segmentation/polySeg/Labelmap/computeAndAddLabelmapRepresentation.ts +25 -0
- package/src/stateManagement/segmentation/polySeg/Labelmap/convertContourToLabelmap.ts +273 -0
- package/src/stateManagement/segmentation/polySeg/Labelmap/convertSurfaceToLabelmap.ts +89 -0
- package/src/stateManagement/segmentation/polySeg/Labelmap/labelmapComputationStrategies.ts +193 -0
- package/src/stateManagement/segmentation/polySeg/Surface/computeAndAddSurfaceRepresentation.ts +26 -0
- package/src/stateManagement/segmentation/polySeg/Surface/convertContourToSurface.ts +62 -0
- package/src/stateManagement/segmentation/polySeg/Surface/convertLabelmapToSurface.ts +81 -0
- package/src/stateManagement/segmentation/polySeg/Surface/createAndCacheSurfacesFromRaw.ts +81 -0
- package/src/stateManagement/segmentation/polySeg/Surface/surfaceComputationStrategies.ts +167 -0
- package/src/stateManagement/segmentation/polySeg/Surface/updateSurfaceData.ts +95 -0
- package/src/stateManagement/segmentation/polySeg/canComputeRequestedRepresentation.ts +123 -0
- package/src/stateManagement/segmentation/polySeg/computeAndAddRepresentation.ts +97 -0
- package/src/stateManagement/segmentation/polySeg/index.ts +12 -0
- package/src/stateManagement/segmentation/polySeg/registerPolySegWorker.ts +34 -0
- package/src/stateManagement/segmentation/segmentIndex.ts +5 -0
- package/src/stateManagement/segmentation/segmentationState.ts +62 -0
- package/src/store/ToolGroupManager/ToolGroup.ts +9 -2
- package/src/tools/ScaleOverlayTool.ts +4 -1
- package/src/tools/SegmentationIntersectionTool.ts +1 -1
- package/src/tools/annotation/LivewireContourSegmentationTool.ts +1 -1
- package/src/tools/annotation/LivewireContourTool.ts +65 -38
- package/src/tools/annotation/PlanarFreehandContourSegmentationTool.ts +1 -22
- package/src/tools/annotation/PlanarFreehandROITool.ts +8 -5
- package/src/tools/annotation/ProbeTool.ts +4 -0
- package/src/tools/annotation/SplineROITool.ts +76 -29
- package/src/tools/annotation/planarFreehandROITool/closedContourEditLoop.ts +20 -11
- package/src/tools/annotation/planarFreehandROITool/drawLoop.ts +42 -23
- package/src/tools/annotation/planarFreehandROITool/openContourEditLoop.ts +28 -13
- package/src/tools/annotation/planarFreehandROITool/openContourEndEditLoop.ts +1 -1
- package/src/tools/annotation/planarFreehandROITool/renderMethods.ts +28 -10
- package/src/tools/annotation/splines/LinearSpline.ts +1 -1
- package/src/tools/annotation/splines/Spline.ts +13 -1
- package/src/tools/base/AnnotationTool.ts +2 -1
- package/src/tools/base/BaseTool.ts +1 -6
- package/src/tools/base/ContourBaseTool.ts +46 -4
- package/src/tools/base/ContourSegmentationBaseTool.ts +51 -42
- package/src/tools/displayTools/Contour/contourConfig.ts +1 -0
- package/src/tools/displayTools/Contour/contourDisplay.ts +82 -9
- package/src/tools/displayTools/Contour/removeContourFromElement.ts +2 -0
- package/src/tools/displayTools/Contour/{addContourSetsToElement.ts → vtkContour/addContourSetsToElement.ts} +1 -1
- package/src/tools/displayTools/Contour/{addOrUpdateContourSets.ts → vtkContour/addOrUpdateVTKContourSets.ts} +4 -4
- package/src/tools/displayTools/Contour/{updateContourSets.ts → vtkContour/updateVTKContourSets.ts} +2 -2
- package/src/tools/displayTools/Contour/{utils.ts → vtkContour/utils.ts} +1 -1
- package/src/tools/displayTools/Labelmap/addLabelmapToElement.ts +1 -1
- package/src/tools/displayTools/Labelmap/index.ts +10 -1
- package/src/tools/displayTools/Labelmap/labelmapDisplay.ts +39 -4
- package/src/tools/displayTools/Labelmap/validateLabelmap.ts +71 -0
- package/src/tools/displayTools/Surface/addOrUpdateSurfaceToElement.ts +172 -0
- package/src/tools/displayTools/Surface/surfaceConfig.ts +12 -0
- package/src/tools/displayTools/Surface/surfaceDisplay.ts +275 -35
- package/src/tools/displayTools/registerDisplayToolsWorker.ts +34 -0
- package/src/tools/segmentation/BrushTool.ts +1 -1
- package/src/tools/segmentation/CircleScissorsTool.ts +3 -1
- package/src/tools/segmentation/PaintFillTool.ts +1 -1
- package/src/tools/segmentation/RectangleScissorsTool.ts +3 -1
- package/src/tools/segmentation/SegmentSelectTool.ts +70 -75
- package/src/tools/segmentation/SphereScissorsTool.ts +3 -1
- package/src/tools/segmentation/strategies/BrushStrategy.ts +12 -9
- package/src/tools/segmentation/strategies/compositions/regionFill.ts +1 -1
- package/src/tools/segmentation/strategies/fillSphere.ts +13 -5
- package/src/tools/segmentation/strategies/utils/getStrategyData.ts +30 -15
- package/src/tools/segmentation/strategies/utils/stackVolumeCheck.ts +24 -17
- package/src/types/AnnotationTypes.ts +14 -0
- package/src/types/ContourAnnotation.ts +13 -0
- package/src/types/ContourSegmentationAnnotation.ts +0 -1
- package/src/types/ContourTypes.ts +3 -0
- package/src/types/EventTypes.ts +9 -0
- package/src/types/ISpline.ts +3 -0
- package/src/types/LabelmapTypes.ts +7 -1
- package/src/types/PolySeg.ts +7 -0
- package/src/types/SegmentationStateTypes.ts +20 -4
- package/src/types/SplineProps.ts +10 -0
- package/src/types/SurfaceTypes.ts +1 -1
- package/src/types/index.ts +3 -0
- package/src/utilities/boundingBox/getBoundingBoxAroundShape.ts +4 -2
- package/src/utilities/contourSegmentation/addContourSegmentationAnnotation.ts +29 -0
- package/src/utilities/contourSegmentation/areSameSegment.ts +0 -2
- package/src/utilities/contourSegmentation/index.ts +2 -0
- package/src/utilities/contourSegmentation/removeContourSegmentationAnnotation.ts +30 -0
- package/src/utilities/contours/detectContourHoles.ts +2 -0
- package/src/utilities/contours/generateContourSetsFromLabelmap.ts +2 -2
- package/src/utilities/contours/getContourHolesDataCanvas.ts +33 -0
- package/src/utilities/contours/getContourHolesDataWorld.ts +19 -0
- package/src/utilities/contours/getDeduplicatedVTKPolyDataPoints.ts +66 -0
- package/src/utilities/contours/index.ts +8 -2
- package/src/utilities/contours/updateContourPolyline.ts +74 -0
- package/src/utilities/index.ts +4 -0
- package/src/utilities/math/polyline/containsPoint.ts +4 -2
- package/src/utilities/math/polyline/containsPoints.ts +22 -0
- package/src/utilities/math/polyline/getWindingDirection.ts +14 -0
- package/src/utilities/math/polyline/index.ts +6 -0
- package/src/utilities/math/polyline/isPointInsidePolyline3D.ts +56 -0
- package/src/utilities/math/polyline/planarFreehandROIInternalTypes.ts +1 -0
- package/src/utilities/segmentation/contourAndFindLargestBidirectional.ts +0 -1
- package/src/utilities/segmentation/getHoveredContourSegmentationAnnotation.ts +25 -0
- package/src/utilities/segmentation/getSegmentAtLabelmapBorder.ts +179 -0
- package/src/utilities/segmentation/getSegmentAtWorldPoint.ts +173 -0
- package/src/utilities/segmentation/getUniqueSegmentIndices.ts +76 -0
- package/src/utilities/segmentation/index.ts +8 -0
- package/src/utilities/triggerAnnotationRenderForToolGroupIds.ts +38 -0
- package/src/workers/clippingPlaneWorker.js +87 -0
- package/src/workers/polySegConverters.js +467 -0
- package/dist/cjs/tools/displayTools/Contour/addContourSetsToElement.js.map +0 -1
- package/dist/cjs/tools/displayTools/Contour/addOrUpdateContourSets.d.ts +0 -3
- package/dist/cjs/tools/displayTools/Contour/addOrUpdateContourSets.js +0 -14
- package/dist/cjs/tools/displayTools/Contour/addOrUpdateContourSets.js.map +0 -1
- package/dist/cjs/tools/displayTools/Contour/contourConfigCache.js.map +0 -1
- package/dist/cjs/tools/displayTools/Contour/updateContourSets.d.ts +0 -3
- package/dist/cjs/tools/displayTools/Contour/updateContourSets.js.map +0 -1
- package/dist/cjs/tools/displayTools/Contour/utils.js.map +0 -1
- package/dist/cjs/tools/displayTools/Labelmap/validateRepresentationData.d.ts +0 -3
- package/dist/cjs/tools/displayTools/Labelmap/validateRepresentationData.js +0 -20
- package/dist/cjs/tools/displayTools/Labelmap/validateRepresentationData.js.map +0 -1
- package/dist/cjs/tools/displayTools/Surface/addSurfaceToElement.d.ts +0 -2
- package/dist/cjs/tools/displayTools/Surface/addSurfaceToElement.js +0 -84
- package/dist/cjs/tools/displayTools/Surface/addSurfaceToElement.js.map +0 -1
- package/dist/cjs/utilities/contours/mergePoints.d.ts +0 -8
- package/dist/cjs/utilities/contours/mergePoints.js +0 -77
- package/dist/cjs/utilities/contours/mergePoints.js.map +0 -1
- package/dist/esm/tools/displayTools/Contour/addContourSetsToElement.js.map +0 -1
- package/dist/esm/tools/displayTools/Contour/addOrUpdateContourSets.js.map +0 -1
- package/dist/esm/tools/displayTools/Contour/contourConfigCache.js.map +0 -1
- package/dist/esm/tools/displayTools/Contour/updateContourSets.js.map +0 -1
- package/dist/esm/tools/displayTools/Contour/utils.js.map +0 -1
- package/dist/esm/tools/displayTools/Labelmap/validateRepresentationData.js +0 -18
- package/dist/esm/tools/displayTools/Labelmap/validateRepresentationData.js.map +0 -1
- package/dist/esm/tools/displayTools/Surface/addSurfaceToElement.js +0 -79
- package/dist/esm/tools/displayTools/Surface/addSurfaceToElement.js.map +0 -1
- package/dist/esm/utilities/contours/mergePoints.js +0 -73
- package/dist/esm/utilities/contours/mergePoints.js.map +0 -1
- package/dist/types/tools/displayTools/Contour/addContourSetsToElement.d.ts.map +0 -1
- package/dist/types/tools/displayTools/Contour/addOrUpdateContourSets.d.ts +0 -4
- package/dist/types/tools/displayTools/Contour/addOrUpdateContourSets.d.ts.map +0 -1
- package/dist/types/tools/displayTools/Contour/contourConfigCache.d.ts.map +0 -1
- package/dist/types/tools/displayTools/Contour/updateContourSets.d.ts +0 -4
- package/dist/types/tools/displayTools/Contour/updateContourSets.d.ts.map +0 -1
- package/dist/types/tools/displayTools/Contour/utils.d.ts.map +0 -1
- package/dist/types/tools/displayTools/Labelmap/validateRepresentationData.d.ts +0 -4
- package/dist/types/tools/displayTools/Labelmap/validateRepresentationData.d.ts.map +0 -1
- package/dist/types/tools/displayTools/Surface/addSurfaceToElement.d.ts +0 -3
- package/dist/types/tools/displayTools/Surface/addSurfaceToElement.d.ts.map +0 -1
- package/dist/types/utilities/contours/mergePoints.d.ts +0 -9
- package/dist/types/utilities/contours/mergePoints.d.ts.map +0 -1
- package/src/tools/displayTools/Labelmap/validateRepresentationData.ts +0 -36
- package/src/tools/displayTools/Surface/addSurfaceToElement.ts +0 -115
- package/src/utilities/contours/mergePoints.ts +0 -108
- /package/dist/cjs/tools/displayTools/Contour/{addContourSetsToElement.js → vtkContour/addContourSetsToElement.js} +0 -0
- /package/dist/cjs/tools/displayTools/Contour/{contourConfigCache.d.ts → vtkContour/contourConfigCache.d.ts} +0 -0
- /package/dist/cjs/tools/displayTools/Contour/{contourConfigCache.js → vtkContour/contourConfigCache.js} +0 -0
- /package/dist/cjs/tools/displayTools/Contour/{utils.js → vtkContour/utils.js} +0 -0
- /package/dist/esm/tools/displayTools/Contour/{addContourSetsToElement.js → vtkContour/addContourSetsToElement.js} +0 -0
- /package/dist/esm/tools/displayTools/Contour/{contourConfigCache.js → vtkContour/contourConfigCache.js} +0 -0
- /package/dist/esm/tools/displayTools/Contour/{utils.js → vtkContour/utils.js} +0 -0
- /package/dist/types/tools/displayTools/Contour/{contourConfigCache.d.ts → vtkContour/contourConfigCache.d.ts} +0 -0
- /package/src/tools/displayTools/Contour/{contourConfigCache.ts → vtkContour/contourConfigCache.ts} +0 -0
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.validate = exports.validatePublic = void 0;
|
|
4
|
+
const core_1 = require("@cornerstonejs/core");
|
|
5
|
+
function validateRepresentationData(segmentationRepresentationData) {
|
|
6
|
+
if ('volumeId' in segmentationRepresentationData) {
|
|
7
|
+
segmentationRepresentationData =
|
|
8
|
+
segmentationRepresentationData;
|
|
9
|
+
const cachedVolume = core_1.cache.getVolume(segmentationRepresentationData.volumeId);
|
|
10
|
+
if (!cachedVolume) {
|
|
11
|
+
throw new Error(`volumeId of ${segmentationRepresentationData.volumeId} not found in cache, you should load and cache volume before adding segmentation`);
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
else if ('imageIdReferenceMap' in segmentationRepresentationData) {
|
|
15
|
+
segmentationRepresentationData =
|
|
16
|
+
segmentationRepresentationData;
|
|
17
|
+
if (!segmentationRepresentationData.imageIdReferenceMap) {
|
|
18
|
+
throw new Error('The segmentationInput.representationData.imageIdReferenceMap is undefined, please provide a valid representationData.imageIdReferenceMap');
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
else {
|
|
22
|
+
throw new Error('The segmentationInput.representationData is undefined, please provide a valid representationData');
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
function validatePublic(segmentationInput) {
|
|
26
|
+
if (!segmentationInput.representation.data) {
|
|
27
|
+
throw new Error('The segmentationInput.representationData.data is undefined, please provide a valid representationData.data');
|
|
28
|
+
}
|
|
29
|
+
const representationData = segmentationInput.representation
|
|
30
|
+
.data;
|
|
31
|
+
validateRepresentationData(representationData);
|
|
32
|
+
}
|
|
33
|
+
exports.validatePublic = validatePublic;
|
|
34
|
+
function validate(segmentationRepresentationData) {
|
|
35
|
+
validateRepresentationData(segmentationRepresentationData);
|
|
36
|
+
}
|
|
37
|
+
exports.validate = validate;
|
|
38
|
+
//# sourceMappingURL=validateLabelmap.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"validateLabelmap.js","sourceRoot":"","sources":["../../../../../src/tools/displayTools/Labelmap/validateLabelmap.ts"],"names":[],"mappings":";;;AAAA,8CAA4C;AAQ5C,SAAS,0BAA0B,CACjC,8BAAwD;IAExD,IAAI,UAAU,IAAI,8BAA8B,EAAE;QAChD,8BAA8B;YAC5B,8BAAgE,CAAC;QAEnE,MAAM,YAAY,GAAG,YAAK,CAAC,SAAS,CAClC,8BAA8B,CAAC,QAAQ,CACxC,CAAC;QAEF,IAAI,CAAC,YAAY,EAAE;YACjB,MAAM,IAAI,KAAK,CACb,eAAe,8BAA8B,CAAC,QAAQ,kFAAkF,CACzI,CAAC;SACH;KACF;SAAM,IAAI,qBAAqB,IAAI,8BAA8B,EAAE;QAClE,8BAA8B;YAC5B,8BAA+D,CAAC;QAElE,IAAI,CAAC,8BAA8B,CAAC,mBAAmB,EAAE;YACvD,MAAM,IAAI,KAAK,CACb,0IAA0I,CAC3I,CAAC;SACH;KACF;SAAM;QACL,MAAM,IAAI,KAAK,CACb,kGAAkG,CACnG,CAAC;KACH;AACH,CAAC;AAQD,SAAgB,cAAc,CAC5B,iBAA0C;IAE1C,IAAI,CAAC,iBAAiB,CAAC,cAAc,CAAC,IAAI,EAAE;QAC1C,MAAM,IAAI,KAAK,CACb,4GAA4G,CAC7G,CAAC;KACH;IAED,MAAM,kBAAkB,GAAG,iBAAiB,CAAC,cAAc;SACxD,IAAgC,CAAC;IAEpC,0BAA0B,CAAC,kBAAkB,CAAC,CAAC;AACjD,CAAC;AAbD,wCAaC;AAOD,SAAgB,QAAQ,CACtB,8BAAwD;IAExD,0BAA0B,CAAC,8BAA8B,CAAC,CAAC;AAC7D,CAAC;AAJD,4BAIC"}
|
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const core_1 = require("@cornerstonejs/core");
|
|
7
|
+
const Mapper_1 = __importDefault(require("@kitware/vtk.js/Rendering/Core/Mapper"));
|
|
8
|
+
const Actor_1 = __importDefault(require("@kitware/vtk.js/Rendering/Core/Actor"));
|
|
9
|
+
const ClipClosedSurface_1 = __importDefault(require("@kitware/vtk.js/Filters/General/ClipClosedSurface"));
|
|
10
|
+
const PolyData_1 = __importDefault(require("@kitware/vtk.js/Common/DataModel/PolyData"));
|
|
11
|
+
const CellArray_1 = __importDefault(require("@kitware/vtk.js/Common/Core/CellArray"));
|
|
12
|
+
const surfaceDisplay_1 = require("./surfaceDisplay");
|
|
13
|
+
function addOrUpdateSurfaceToElement(element, surface, segmentationRepresentationUID) {
|
|
14
|
+
var _a, _b;
|
|
15
|
+
const actorUID = (0, surfaceDisplay_1.getSurfaceActorUID)(segmentationRepresentationUID, surface.id);
|
|
16
|
+
const enabledElement = (0, core_1.getEnabledElement)(element);
|
|
17
|
+
const { viewport } = enabledElement;
|
|
18
|
+
const surfaceActor = (_a = viewport.getActor(actorUID)) === null || _a === void 0 ? void 0 : _a.actor;
|
|
19
|
+
if (surfaceActor) {
|
|
20
|
+
const surfaceMapper = surfaceActor.getMapper();
|
|
21
|
+
const currentPolyData = surfaceMapper.getInputData();
|
|
22
|
+
const newPoints = surface.getPoints();
|
|
23
|
+
const newPolys = surface.getPolys();
|
|
24
|
+
const currentPoints = currentPolyData.getPoints().getData();
|
|
25
|
+
const currentPolys = currentPolyData.getPolys().getData();
|
|
26
|
+
if (newPoints.length === currentPoints.length &&
|
|
27
|
+
newPolys.length === currentPolys.length) {
|
|
28
|
+
return;
|
|
29
|
+
}
|
|
30
|
+
const polyData = PolyData_1.default.newInstance();
|
|
31
|
+
polyData.getPoints().setData(newPoints, 3);
|
|
32
|
+
const triangles = CellArray_1.default.newInstance({
|
|
33
|
+
values: Float32Array.from(newPolys),
|
|
34
|
+
});
|
|
35
|
+
polyData.setPolys(triangles);
|
|
36
|
+
surfaceMapper.setInputData(polyData);
|
|
37
|
+
surfaceMapper.modified();
|
|
38
|
+
setTimeout(() => {
|
|
39
|
+
viewport.getRenderer().resetCameraClippingRange();
|
|
40
|
+
}, 0);
|
|
41
|
+
return;
|
|
42
|
+
}
|
|
43
|
+
const points = surface.getPoints();
|
|
44
|
+
const polys = surface.getPolys();
|
|
45
|
+
const color = surface.getColor();
|
|
46
|
+
const surfacePolyData = PolyData_1.default.newInstance();
|
|
47
|
+
surfacePolyData.getPoints().setData(points, 3);
|
|
48
|
+
const triangles = CellArray_1.default.newInstance({
|
|
49
|
+
values: Float32Array.from(polys),
|
|
50
|
+
});
|
|
51
|
+
surfacePolyData.setPolys(triangles);
|
|
52
|
+
const mapper = Mapper_1.default.newInstance({});
|
|
53
|
+
let clippingFilter;
|
|
54
|
+
if (!(viewport instanceof core_1.VolumeViewport3D)) {
|
|
55
|
+
clippingFilter = ClipClosedSurface_1.default.newInstance({
|
|
56
|
+
clippingPlanes: [],
|
|
57
|
+
activePlaneId: 2,
|
|
58
|
+
passPointData: false,
|
|
59
|
+
});
|
|
60
|
+
clippingFilter.setInputData(surfacePolyData);
|
|
61
|
+
clippingFilter.setGenerateOutline(true);
|
|
62
|
+
clippingFilter.setGenerateFaces(false);
|
|
63
|
+
clippingFilter.update();
|
|
64
|
+
const filteredData = clippingFilter.getOutputData();
|
|
65
|
+
mapper.setInputData(filteredData);
|
|
66
|
+
const evt = {
|
|
67
|
+
detail: {
|
|
68
|
+
actorEntry: {
|
|
69
|
+
actor: {
|
|
70
|
+
getMapper: () => mapper,
|
|
71
|
+
},
|
|
72
|
+
clippingFilter,
|
|
73
|
+
uid: actorUID,
|
|
74
|
+
},
|
|
75
|
+
vtkPlanes: (_b = viewport.getClippingPlanesForActor) === null || _b === void 0 ? void 0 : _b.call(viewport),
|
|
76
|
+
viewport,
|
|
77
|
+
},
|
|
78
|
+
};
|
|
79
|
+
updateSurfacePlanes(evt);
|
|
80
|
+
element.addEventListener(core_1.Enums.Events.CLIPPING_PLANES_UPDATED, updateSurfacePlanes);
|
|
81
|
+
}
|
|
82
|
+
else {
|
|
83
|
+
mapper.setInputData(surfacePolyData);
|
|
84
|
+
}
|
|
85
|
+
const actor = Actor_1.default.newInstance();
|
|
86
|
+
actor.setMapper(mapper);
|
|
87
|
+
actor.getProperty().setColor(color[0] / 255, color[1] / 255, color[2] / 255);
|
|
88
|
+
actor.getProperty().setLineWidth(2);
|
|
89
|
+
viewport.addActor({
|
|
90
|
+
actor,
|
|
91
|
+
uid: actorUID,
|
|
92
|
+
clippingFilter,
|
|
93
|
+
});
|
|
94
|
+
viewport.resetCamera();
|
|
95
|
+
setTimeout(() => {
|
|
96
|
+
viewport.getRenderer().resetCameraClippingRange();
|
|
97
|
+
}, 0);
|
|
98
|
+
}
|
|
99
|
+
function updateSurfacePlanes(evt) {
|
|
100
|
+
const { actorEntry, vtkPlanes, viewport } = evt.detail;
|
|
101
|
+
if (!(actorEntry === null || actorEntry === void 0 ? void 0 : actorEntry.clippingFilter)) {
|
|
102
|
+
return;
|
|
103
|
+
}
|
|
104
|
+
const sliceIndex = viewport.getSliceIndex();
|
|
105
|
+
const mapper = actorEntry.actor.getMapper();
|
|
106
|
+
const { viewPlaneNormal } = viewport.getCamera();
|
|
107
|
+
const cacheId = (0, surfaceDisplay_1.generateCacheId)(viewport, viewPlaneNormal, sliceIndex);
|
|
108
|
+
const polyData = (0, surfaceDisplay_1.getOrCreatePolyData)(actorEntry, cacheId, vtkPlanes);
|
|
109
|
+
mapper.setInputData(polyData);
|
|
110
|
+
}
|
|
111
|
+
exports.default = addOrUpdateSurfaceToElement;
|
|
112
|
+
//# sourceMappingURL=addOrUpdateSurfaceToElement.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"addOrUpdateSurfaceToElement.js","sourceRoot":"","sources":["../../../../../src/tools/displayTools/Surface/addOrUpdateSurfaceToElement.ts"],"names":[],"mappings":";;;;;AAAA,8CAI6B;AAE7B,m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,EAAE,GAAG,GAAG,CAAC,MAAM,CAAC;IACvD,IAAI,CAAC,CAAA,UAAU,aAAV,UAAU,uBAAV,UAAU,CAAE,cAAc,CAAA,EAAE;QAC/B,OAAO;KACR;IACD,MAAM,UAAU,GAAG,QAAQ,CAAC,aAAa,EAAE,CAAC;IAC5C,MAAM,MAAM,GAAG,UAAU,CAAC,KAAK,CAAC,SAAS,EAAE,CAAC;IAC5C,MAAM,EAAE,eAAe,EAAE,GAAG,QAAQ,CAAC,SAAS,EAAE,CAAC;IACjD,MAAM,OAAO,GAAG,IAAA,gCAAe,EAAC,QAAQ,EAAE,eAAe,EAAE,UAAU,CAAC,CAAC;IACvE,MAAM,QAAQ,GAAG,IAAA,oCAAmB,EAAC,UAAU,EAAE,OAAO,EAAE,SAAS,CAAC,CAAC;IACrE,MAAM,CAAC,YAAY,CAAC,QAAQ,CAAC,CAAC;AAChC,CAAC;AAED,kBAAe,2BAA2B,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const defaultSurfaceConfig = {
|
|
4
|
+
renderFill: true,
|
|
5
|
+
fillAlpha: 1,
|
|
6
|
+
};
|
|
7
|
+
function getDefaultSurfaceConfig() {
|
|
8
|
+
return defaultSurfaceConfig;
|
|
9
|
+
}
|
|
10
|
+
exports.default = getDefaultSurfaceConfig;
|
|
11
|
+
//# sourceMappingURL=surfaceConfig.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"surfaceConfig.js","sourceRoot":"","sources":["../../../../../src/tools/displayTools/Surface/surfaceConfig.ts"],"names":[],"mappings":";;AAEA,MAAM,oBAAoB,GAA2B;IACnD,UAAU,EAAE,IAAI;IAChB,SAAS,EAAE,CAAC;CACb,CAAC;AAEF,SAAS,uBAAuB;IAC9B,OAAO,oBAAoB,CAAC;AAC9B,CAAC;AAED,kBAAe,uBAAuB,CAAC"}
|
|
@@ -1,9 +1,16 @@
|
|
|
1
1
|
import { Types } from '@cornerstonejs/core';
|
|
2
2
|
import { SegmentationRepresentationConfig, ToolGroupSpecificRepresentation } from '../../../types/SegmentationStateTypes';
|
|
3
|
+
declare const polyDataCache: Map<any, any>;
|
|
3
4
|
declare function removeSegmentationRepresentation(toolGroupId: string, segmentationRepresentationUID: string, renderImmediate?: boolean): void;
|
|
4
5
|
declare function render(viewport: Types.IVolumeViewport, representation: ToolGroupSpecificRepresentation, toolGroupConfig: SegmentationRepresentationConfig): Promise<void>;
|
|
6
|
+
export declare function getSurfaceActorUID(segmentationRepresentationUID: string, surfaceId: string): string;
|
|
7
|
+
export declare function generateCacheId(viewport: any, viewPlaneNormal: any, sliceIndex: any): string;
|
|
8
|
+
export declare function getOrCreatePolyData(actorEntry: any, cacheId: any, vtkPlanes: any): any;
|
|
9
|
+
export declare function updatePolyDataCache(actorUID: any, cacheId: any, polyDataResult: any): void;
|
|
10
|
+
export declare function getSortedPlanesInfo(viewport: any): any;
|
|
5
11
|
declare const _default: {
|
|
6
12
|
render: typeof render;
|
|
7
13
|
removeSegmentationRepresentation: typeof removeSegmentationRepresentation;
|
|
8
14
|
};
|
|
9
15
|
export default _default;
|
|
16
|
+
export { render, removeSegmentationRepresentation, polyDataCache };
|
|
@@ -35,12 +35,29 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
35
35
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
36
36
|
};
|
|
37
37
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
38
|
+
exports.polyDataCache = exports.removeSegmentationRepresentation = exports.render = exports.getSortedPlanesInfo = exports.updatePolyDataCache = exports.getOrCreatePolyData = exports.generateCacheId = exports.getSurfaceActorUID = void 0;
|
|
39
|
+
const PolyData_1 = __importDefault(require("@kitware/vtk.js/Common/DataModel/PolyData"));
|
|
40
|
+
const CellArray_1 = __importDefault(require("@kitware/vtk.js/Common/Core/CellArray"));
|
|
38
41
|
const core_1 = require("@cornerstonejs/core");
|
|
39
42
|
const SegmentationState = __importStar(require("../../../stateManagement/segmentation/segmentationState"));
|
|
40
43
|
const SegmentationRepresentations_1 = __importDefault(require("../../../enums/SegmentationRepresentations"));
|
|
41
44
|
const ToolGroupManager_1 = require("../../../store/ToolGroupManager");
|
|
45
|
+
const registerDisplayToolsWorker_1 = require("../registerDisplayToolsWorker");
|
|
42
46
|
const removeSurfaceFromElement_1 = __importDefault(require("./removeSurfaceFromElement"));
|
|
43
|
-
const
|
|
47
|
+
const addOrUpdateSurfaceToElement_1 = __importDefault(require("./addOrUpdateSurfaceToElement"));
|
|
48
|
+
const segmentation_1 = require("../../../stateManagement/segmentation");
|
|
49
|
+
const utilities_1 = require("../../../utilities");
|
|
50
|
+
const enums_1 = require("../../../enums");
|
|
51
|
+
const workerManager = (0, core_1.getWebWorkerManager)();
|
|
52
|
+
const polyDataCache = new Map();
|
|
53
|
+
exports.polyDataCache = polyDataCache;
|
|
54
|
+
const currentViewportNormal = new Map();
|
|
55
|
+
const triggerWorkerProgress = (eventTarget, progress) => {
|
|
56
|
+
(0, core_1.triggerEvent)(eventTarget, core_1.Enums.Events.WEB_WORKER_PROGRESS, {
|
|
57
|
+
progress,
|
|
58
|
+
type: enums_1.WorkerTypes.DISPLAY_TOOL_CLIP_SURFACE,
|
|
59
|
+
});
|
|
60
|
+
};
|
|
44
61
|
function removeSegmentationRepresentation(toolGroupId, segmentationRepresentationUID, renderImmediate = false) {
|
|
45
62
|
_removeSurfaceFromToolGroupViewports(toolGroupId, segmentationRepresentationUID);
|
|
46
63
|
SegmentationState.removeSegmentationRepresentation(toolGroupId, segmentationRepresentationUID);
|
|
@@ -52,43 +69,55 @@ function removeSegmentationRepresentation(toolGroupId, segmentationRepresentatio
|
|
|
52
69
|
});
|
|
53
70
|
}
|
|
54
71
|
}
|
|
72
|
+
exports.removeSegmentationRepresentation = removeSegmentationRepresentation;
|
|
55
73
|
function render(viewport, representation, toolGroupConfig) {
|
|
56
74
|
return __awaiter(this, void 0, void 0, function* () {
|
|
57
75
|
const { colorLUTIndex, active, segmentationId, segmentationRepresentationUID, segmentsHidden, } = representation;
|
|
58
76
|
const segmentation = SegmentationState.getSegmentation(segmentationId);
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
if (!geometryId) {
|
|
62
|
-
console.warn(`No Surfaces found for segmentationId ${segmentationId}. Skipping render.`);
|
|
77
|
+
if (!segmentation) {
|
|
78
|
+
return;
|
|
63
79
|
}
|
|
64
|
-
|
|
65
|
-
if (!
|
|
66
|
-
|
|
80
|
+
let SurfaceData = segmentation.representationData[SegmentationRepresentations_1.default.Surface];
|
|
81
|
+
if (!SurfaceData &&
|
|
82
|
+
segmentation_1.polySeg.canComputeRequestedRepresentation(segmentationRepresentationUID)) {
|
|
83
|
+
SurfaceData = yield segmentation_1.polySeg.computeAndAddSurfaceRepresentation(segmentationId, {
|
|
84
|
+
segmentationRepresentationUID,
|
|
85
|
+
});
|
|
86
|
+
if (!SurfaceData) {
|
|
87
|
+
throw new Error(`No Surface data found for segmentationId ${segmentationId}.`);
|
|
88
|
+
}
|
|
67
89
|
}
|
|
68
|
-
|
|
69
|
-
|
|
90
|
+
const { geometryIds } = SurfaceData;
|
|
91
|
+
if (!(geometryIds === null || geometryIds === void 0 ? void 0 : geometryIds.size)) {
|
|
92
|
+
console.warn(`No Surfaces found for segmentationId ${segmentationId}. Skipping render.`);
|
|
70
93
|
}
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
94
|
+
const colorLUT = SegmentationState.getColorLUT(colorLUTIndex);
|
|
95
|
+
const surfaces = [];
|
|
96
|
+
geometryIds.forEach((geometryId, segmentIndex) => {
|
|
97
|
+
const geometry = core_1.cache.getGeometry(geometryId);
|
|
98
|
+
if (!geometry) {
|
|
99
|
+
throw new Error(`No Surfaces found for geometryId ${geometryId}`);
|
|
100
|
+
}
|
|
101
|
+
if (geometry.type !== core_1.Enums.GeometryType.SURFACE) {
|
|
102
|
+
throw new Error(`Geometry type ${geometry.type} not supported for rendering.`);
|
|
103
|
+
}
|
|
104
|
+
if (!geometry.data) {
|
|
105
|
+
console.warn(`No Surfaces found for geometryId ${geometryId}. Skipping render.`);
|
|
106
|
+
return;
|
|
107
|
+
}
|
|
108
|
+
const surface = geometry.data;
|
|
109
|
+
const color = colorLUT[segmentIndex];
|
|
110
|
+
surface.setColor(color.slice(0, 3));
|
|
111
|
+
(0, addOrUpdateSurfaceToElement_1.default)(viewport.element, surface, segmentationRepresentationUID);
|
|
112
|
+
surfaces.push(surface);
|
|
113
|
+
});
|
|
114
|
+
if (viewport instanceof core_1.VolumeViewport) {
|
|
115
|
+
generateAndCacheClippedSurfaces(surfaces, viewport, segmentationRepresentationUID);
|
|
74
116
|
}
|
|
75
|
-
const surface = geometry.data;
|
|
76
|
-
const surfaceUID = `${segmentationRepresentationUID}_${surface.id}}`;
|
|
77
|
-
_renderSurface(viewport, surface, surfaceUID);
|
|
78
|
-
viewport.resetCamera();
|
|
79
117
|
viewport.render();
|
|
80
118
|
});
|
|
81
119
|
}
|
|
82
|
-
|
|
83
|
-
const actorUID = surfaceUID;
|
|
84
|
-
const actorEntry = viewport.getActor(actorUID);
|
|
85
|
-
if (!actorEntry) {
|
|
86
|
-
(0, addSurfaceToElement_1.default)(viewport.element, surface, actorUID);
|
|
87
|
-
}
|
|
88
|
-
else {
|
|
89
|
-
throw new Error('Not implemented yet. (Update surface)');
|
|
90
|
-
}
|
|
91
|
-
}
|
|
120
|
+
exports.render = render;
|
|
92
121
|
function _removeSurfaceFromToolGroupViewports(toolGroupId, segmentationRepresentationUID) {
|
|
93
122
|
const toolGroup = (0, ToolGroupManager_1.getToolGroup)(toolGroupId);
|
|
94
123
|
if (toolGroup === undefined) {
|
|
@@ -101,6 +130,123 @@ function _removeSurfaceFromToolGroupViewports(toolGroupId, segmentationRepresent
|
|
|
101
130
|
(0, removeSurfaceFromElement_1.default)(enabledElement.viewport.element, segmentationRepresentationUID);
|
|
102
131
|
}
|
|
103
132
|
}
|
|
133
|
+
function generateAndCacheClippedSurfaces(surfaces, viewport, segmentationRepresentationUID) {
|
|
134
|
+
var _a;
|
|
135
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
136
|
+
(0, registerDisplayToolsWorker_1.registerDisplayToolsWorker)();
|
|
137
|
+
const planesInfo = (_a = viewport.getSlicesClippingPlanes) === null || _a === void 0 ? void 0 : _a.call(viewport);
|
|
138
|
+
const currentSliceIndex = viewport.getSliceIndex();
|
|
139
|
+
planesInfo.sort((a, b) => {
|
|
140
|
+
const diffA = Math.abs(a.sliceIndex - currentSliceIndex);
|
|
141
|
+
const diffB = Math.abs(b.sliceIndex - currentSliceIndex);
|
|
142
|
+
return diffA - diffB;
|
|
143
|
+
});
|
|
144
|
+
const pointsAndPolys = surfaces.map((surface) => {
|
|
145
|
+
const id = surface.id;
|
|
146
|
+
const points = surface.getPoints();
|
|
147
|
+
const polys = surface.getPolys();
|
|
148
|
+
return { id, points, polys };
|
|
149
|
+
});
|
|
150
|
+
const camera = viewport.getCamera();
|
|
151
|
+
function cameraModifiedCallback(evt) {
|
|
152
|
+
const { camera } = evt.detail;
|
|
153
|
+
const { viewPlaneNormal } = camera;
|
|
154
|
+
const surface1 = surfaces[0];
|
|
155
|
+
if (core_1.utilities.isEqual(viewPlaneNormal, currentViewportNormal.get(surface1.id))) {
|
|
156
|
+
return;
|
|
157
|
+
}
|
|
158
|
+
currentViewportNormal.set(surface1.id, viewPlaneNormal);
|
|
159
|
+
workerManager.terminate('displayTools');
|
|
160
|
+
setTimeout(() => {
|
|
161
|
+
generateAndCacheClippedSurfaces(surfaces, viewport, segmentationRepresentationUID);
|
|
162
|
+
}, 0);
|
|
163
|
+
viewport.render();
|
|
164
|
+
}
|
|
165
|
+
viewport.element.removeEventListener(core_1.Enums.Events.CAMERA_MODIFIED, cameraModifiedCallback);
|
|
166
|
+
viewport.element.addEventListener(core_1.Enums.Events.CAMERA_MODIFIED, cameraModifiedCallback);
|
|
167
|
+
triggerWorkerProgress(core_1.eventTarget, 0);
|
|
168
|
+
yield workerManager
|
|
169
|
+
.executeTask('displayTools', 'clipSurfaceWithPlanes', {
|
|
170
|
+
planesInfo,
|
|
171
|
+
pointsAndPolys,
|
|
172
|
+
}, {
|
|
173
|
+
callbacks: [
|
|
174
|
+
({ progress }) => {
|
|
175
|
+
triggerWorkerProgress(core_1.eventTarget, progress);
|
|
176
|
+
},
|
|
177
|
+
({ sliceIndex, polyDataResults }) => {
|
|
178
|
+
polyDataResults.forEach((polyDataResult, surfaceId) => {
|
|
179
|
+
const actorUID = `${segmentationRepresentationUID}_${surfaceId}`;
|
|
180
|
+
const cacheId = generateCacheId(viewport, camera.viewPlaneNormal, sliceIndex);
|
|
181
|
+
updatePolyDataCache(actorUID, cacheId, polyDataResult);
|
|
182
|
+
});
|
|
183
|
+
},
|
|
184
|
+
],
|
|
185
|
+
})
|
|
186
|
+
.catch((error) => {
|
|
187
|
+
console.error(error);
|
|
188
|
+
});
|
|
189
|
+
triggerWorkerProgress(core_1.eventTarget, 100);
|
|
190
|
+
});
|
|
191
|
+
}
|
|
192
|
+
function getSurfaceActorUID(segmentationRepresentationUID, surfaceId) {
|
|
193
|
+
return `${segmentationRepresentationUID}_${surfaceId}`;
|
|
194
|
+
}
|
|
195
|
+
exports.getSurfaceActorUID = getSurfaceActorUID;
|
|
196
|
+
function generateCacheId(viewport, viewPlaneNormal, sliceIndex) {
|
|
197
|
+
return `${viewport.id}-${(0, utilities_1.pointToString)(viewPlaneNormal)}-${sliceIndex}`;
|
|
198
|
+
}
|
|
199
|
+
exports.generateCacheId = generateCacheId;
|
|
200
|
+
function getOrCreatePolyData(actorEntry, cacheId, vtkPlanes) {
|
|
201
|
+
let actorCache = polyDataCache.get(actorEntry.uid);
|
|
202
|
+
if (!actorCache) {
|
|
203
|
+
actorCache = new Map();
|
|
204
|
+
polyDataCache.set(actorEntry.uid, actorCache);
|
|
205
|
+
}
|
|
206
|
+
let polyData = actorCache.get(cacheId);
|
|
207
|
+
if (!polyData) {
|
|
208
|
+
const clippingFilter = actorEntry.clippingFilter;
|
|
209
|
+
clippingFilter.setClippingPlanes(vtkPlanes);
|
|
210
|
+
try {
|
|
211
|
+
clippingFilter.update();
|
|
212
|
+
polyData = clippingFilter.getOutputData();
|
|
213
|
+
actorCache.set(cacheId, polyData);
|
|
214
|
+
}
|
|
215
|
+
catch (e) {
|
|
216
|
+
console.error('Error clipping surface', e);
|
|
217
|
+
}
|
|
218
|
+
}
|
|
219
|
+
return polyData;
|
|
220
|
+
}
|
|
221
|
+
exports.getOrCreatePolyData = getOrCreatePolyData;
|
|
222
|
+
function updatePolyDataCache(actorUID, cacheId, polyDataResult) {
|
|
223
|
+
const { points, lines } = polyDataResult;
|
|
224
|
+
const polyData = PolyData_1.default.newInstance();
|
|
225
|
+
polyData.getPoints().setData(points, 3);
|
|
226
|
+
const linesArray = CellArray_1.default.newInstance({
|
|
227
|
+
values: Int16Array.from(lines),
|
|
228
|
+
});
|
|
229
|
+
polyData.setLines(linesArray);
|
|
230
|
+
let actorCache = polyDataCache.get(actorUID);
|
|
231
|
+
if (!actorCache) {
|
|
232
|
+
actorCache = new Map();
|
|
233
|
+
polyDataCache.set(actorUID, actorCache);
|
|
234
|
+
}
|
|
235
|
+
actorCache.set(cacheId, polyData);
|
|
236
|
+
}
|
|
237
|
+
exports.updatePolyDataCache = updatePolyDataCache;
|
|
238
|
+
function getSortedPlanesInfo(viewport) {
|
|
239
|
+
var _a;
|
|
240
|
+
const planesInfo = (_a = viewport.getSlicesClippingPlanes) === null || _a === void 0 ? void 0 : _a.call(viewport);
|
|
241
|
+
const currentSliceIndex = viewport.getSliceIndex();
|
|
242
|
+
planesInfo.sort((a, b) => {
|
|
243
|
+
const diffA = Math.abs(a.sliceIndex - currentSliceIndex);
|
|
244
|
+
const diffB = Math.abs(b.sliceIndex - currentSliceIndex);
|
|
245
|
+
return diffA - diffB;
|
|
246
|
+
});
|
|
247
|
+
return planesInfo;
|
|
248
|
+
}
|
|
249
|
+
exports.getSortedPlanesInfo = getSortedPlanesInfo;
|
|
104
250
|
exports.default = {
|
|
105
251
|
render,
|
|
106
252
|
removeSegmentationRepresentation,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"surfaceDisplay.js","sourceRoot":"","sources":["../../../../../src/tools/displayTools/Surface/surfaceDisplay.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"surfaceDisplay.js","sourceRoot":"","sources":["../../../../../src/tools/displayTools/Surface/surfaceDisplay.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,yFAAoE;AACpE,sFAAiE;AACjE,8CAU6B;AAE7B,2GAA6F;AAC7F,6GAAyE;AACzE,sEAA+D;AAK/D,8EAA2E;AAE3E,0FAAkE;AAClE,gGAAwE;AACxE,wEAAgE;AAChE,kDAAmD;AACnD,0CAA6C;AAC7C,MAAM,aAAa,GAAG,IAAA,0BAAmB,GAAE,CAAC;AAE5C,MAAM,aAAa,GAAG,IAAI,GAAG,EAAE,CAAC;AA4WmB,sCAAa;AA3WhE,MAAM,qBAAqB,GAAG,IAAI,GAAG,EAAE,CAAC;AAExC,MAAM,qBAAqB,GAAG,CAAC,WAAW,EAAE,QAAQ,EAAE,EAAE;IACtD,IAAA,mBAAY,EAAC,WAAW,EAAE,YAAK,CAAC,MAAM,CAAC,mBAAmB,EAAE;QAC1D,QAAQ;QACR,IAAI,EAAE,mBAAW,CAAC,yBAAyB;KAC5C,CAAC,CAAC;AACL,CAAC,CAAC;AAYF,SAAS,gCAAgC,CACvC,WAAmB,EACnB,6BAAqC,EACrC,eAAe,GAAG,KAAK;IAEvB,oCAAoC,CAClC,WAAW,EACX,6BAA6B,CAC9B,CAAC;IACF,iBAAiB,CAAC,gCAAgC,CAChD,WAAW,EACX,6BAA6B,CAC9B,CAAC;IAEF,IAAI,eAAe,EAAE;QACnB,MAAM,aAAa,GAAG,IAAA,+BAAY,EAAC,WAAW,CAAC,CAAC,gBAAgB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AAa,EAAE,CAAC;IAGnD,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE;QACvB,MAAM,KAAK,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,UAAU,GAAG,iBAAiB,CAAC,CAAC;QACzD,MAAM,KAAK,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,UAAU,GAAG,iBAAiB,CAAC,CAAC;QACzD,OAAO,KAAK,GAAG,KAAK,CAAC;IACvB,CAAC,CAAC,CAAC;IACH,OAAO,UAAU,CAAC;AACpB,CAAC;AAXD,kDAWC;AAED,kBAAe;IACb,MAAM;IACN,gCAAgC;CACjC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function registerDisplayToolsWorker(): void;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.registerDisplayToolsWorker = void 0;
|
|
4
|
+
const core_1 = require("@cornerstonejs/core");
|
|
5
|
+
let registered = false;
|
|
6
|
+
function registerDisplayToolsWorker() {
|
|
7
|
+
if (registered) {
|
|
8
|
+
return;
|
|
9
|
+
}
|
|
10
|
+
registered = true;
|
|
11
|
+
const workerFn = () => {
|
|
12
|
+
return new Worker(new URL('../../workers/clippingPlaneWorker', import.meta.url), {
|
|
13
|
+
name: 'displayTools',
|
|
14
|
+
});
|
|
15
|
+
};
|
|
16
|
+
const workerManager = (0, core_1.getWebWorkerManager)();
|
|
17
|
+
const options = {
|
|
18
|
+
maxWorkerInstances: 1,
|
|
19
|
+
autoTerminateOnIdle: {
|
|
20
|
+
enabled: true,
|
|
21
|
+
idleTimeThreshold: 2000,
|
|
22
|
+
},
|
|
23
|
+
};
|
|
24
|
+
workerManager.registerWorker('displayTools', workerFn, options);
|
|
25
|
+
}
|
|
26
|
+
exports.registerDisplayToolsWorker = registerDisplayToolsWorker;
|
|
27
|
+
//# sourceMappingURL=registerDisplayToolsWorker.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"registerDisplayToolsWorker.js","sourceRoot":"","sources":["../../../../src/tools/displayTools/registerDisplayToolsWorker.ts"],"names":[],"mappings":";;;AAAA,8CAA0D;AAE1D,IAAI,UAAU,GAAG,KAAK,CAAC;AAEvB,SAAgB,0BAA0B;IACxC,IAAI,UAAU,EAAE;QACd,OAAO;KACR;IAED,UAAU,GAAG,IAAI,CAAC;IAElB,MAAM,QAAQ,GAAG,GAAG,EAAE;QAEpB,OAAO,IAAI,MAAM,CAEf,IAAI,GAAG,CAAC,mCAAmC,EAAE,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,EAC7D;YACE,IAAI,EAAE,cAAc;SACrB,CACF,CAAC;IACJ,CAAC,CAAC;IAEF,MAAM,aAAa,GAAG,IAAA,0BAAmB,GAAE,CAAC;IAE5C,MAAM,OAAO,GAAG;QACd,kBAAkB,EAAE,CAAC;QACrB,mBAAmB,EAAE;YACnB,OAAO,EAAE,IAAI;YACb,iBAAiB,EAAE,IAAI;SACxB;KACF,CAAC;IAEF,aAAa,CAAC,cAAc,CAAC,cAAc,EAAE,QAAQ,EAAE,OAAO,CAAC,CAAC;AAClE,CAAC;AA7BD,gEA6BC"}
|
|
@@ -208,7 +208,7 @@ class BrushTool extends base_1.BaseTool {
|
|
|
208
208
|
const segmentsLocked = segmentation_1.segmentLocking.getLockedSegments(segmentationId);
|
|
209
209
|
const { representationData } = segmentation_1.state.getSegmentation(segmentationId);
|
|
210
210
|
const labelmapData = representationData[enums_1.SegmentationRepresentations.Labelmap];
|
|
211
|
-
if ((0, stackVolumeCheck_1.isVolumeSegmentation)(labelmapData)) {
|
|
211
|
+
if ((0, stackVolumeCheck_1.isVolumeSegmentation)(labelmapData, viewport)) {
|
|
212
212
|
const { volumeId } = representationData[type];
|
|
213
213
|
const actors = viewport.getActors();
|
|
214
214
|
const firstVolumeActorUID = actors[0].uid;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BrushTool.js","sourceRoot":"","sources":["../../../../src/tools/segmentation/BrushTool.ts"],"names":[],"mappings":";;;;;AAAA,8CAA8E;AAC9E,yCAAuC;AASvC,kCAAmC;AACnC,wDAGiC;AACjC,0DAA6D;AAC7D,wDAGiC;AACjC,0DAA6D;AAC7D,uCAKqB;AACrB,iDAA+D;AAC/D,+DAGqC;AAErC,kIAA2G;AAC3G,qEAM4C;AAK5C,0EAA2E;AAqB3E,MAAM,SAAU,SAAQ,eAAQ;IA4B9B,YACE,YAA6B,EAAE,EAC/B,mBAA8B;QAC5B,yBAAyB,EAAE,CAAC,OAAO,EAAE,OAAO,CAAC;QAC7C,aAAa,EAAE;YACb,UAAU,EAAE;gBACV,kBAAkB,EAAE,6BAAgB;gBACpC,mBAAmB,EAAE,+BAAiB;gBACtC,kBAAkB,EAAE,6BAAgB;gBACpC,mBAAmB,EAAE,+BAAiB;gBACtC,uBAAuB,EAAE,kCAAqB;gBAC9C,uBAAuB,EAAE,kCAAqB;aAC/C;YACD,6BAA6B,EAAE;gBAC7B,SAAS,EAAE;oBACT,SAAS,EAAE,CAAC,CAAC,GAAG,EAAE,CAAC,EAAE,CAAC;iBACvB;aACF;YACD,eAAe,EAAE,oBAAoB;YACrC,cAAc,EAAE,oBAAoB;YACpC,SAAS,EAAE,EAAE;YACb,OAAO,EAAE;gBAEP,OAAO,EAAE,KAAK;gBACd,aAAa,EAAE,EAAE;gBAEjB,aAAa,EAAE,GAAG;gBAElB,mBAAmB,EAAE,CAAC;gBAEtB,gBAAgB,EAAE,CAAC;gBAEnB,UAAU,EAAE,GAAG;aAChB;YAED,YAAY,EAAE,CAAC;YACf,OAAO,EAAE;gBACP,CAAC,yBAAiB,CAAC,aAAa,CAAC,EAAE;oBACjC,MAAM,EAAE,yBAAiB,CAAC,aAAa;oBACvC,QAAQ,EAAE;wBACR;4BACE,GAAG,EAAE,OAAO;yBACb;qBACF;iBACF;gBACD,CAAC,yBAAiB,CAAC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AC;QACtB,IAAA,uBAAa,EACX,gBAAgB,EAChB,aAAa,EACb,SAAS,EACT,MAAsB,EACtB,MAAM,EACN;YACE,KAAK;SACN,CACF,CAAC;QAEF,MAAM,EAAE,YAAY,EAAE,GAAG,IAAI,CAAC,aAAa,CAAC;QAC5C,IAAI,YAAY,IAAI,CAAC,EAAE;YACrB,MAAM,UAAU,GAAG,GAAG,CAAC;YACvB,IAAA,uBAAa,EACX,gBAAgB,EAChB,aAAa,EACb,UAAU,EACV,MAAsB,EACtB,CAAC,EACD;gBACE,KAAK;aACN,CACF,CAAC;SACH;IACH,CAAC;CACF;AAED,SAAS,CAAC,QAAQ,GAAG,OAAO,CAAC;AAC7B,kBAAe,SAAS,CAAC"}
|
|
1
|
+
{"version":3,"file":"BrushTool.js","sourceRoot":"","sources":["../../../../src/tools/segmentation/BrushTool.ts"],"names":[],"mappings":";;;;;AAAA,8CAA8E;AAC9E,yCAAuC;AASvC,kCAAmC;AACnC,wDAGiC;AACjC,0DAA6D;AAC7D,wDAGiC;AACjC,0DAA6D;AAC7D,uCAKqB;AACrB,iDAA+D;AAC/D,+DAGqC;AAErC,kIAA2G;AAC3G,qEAM4C;AAK5C,0EAA2E;AAqB3E,MAAM,SAAU,SAAQ,eAAQ;IA4B9B,YACE,YAA6B,EAAE,EAC/B,mBAA8B;QAC5B,yBAAyB,EAAE,CAAC,OAAO,EAAE,OAAO,CAAC;QAC7C,aAAa,EAAE;YACb,UAAU,EAAE;gBACV,kBAAkB,EAAE,6BAAgB;gBACpC,mBAAmB,EAAE,+BAAiB;gBACtC,kBAAkB,EAAE,6BAAgB;gBACpC,mBAAmB,EAAE,+BAAiB;gBACtC,uBAAuB,EAAE,kCAAqB;gBAC9C,uBAAuB,EAAE,kCAAqB;aAC/C;YACD,6BAA6B,EAAE;gBAC7B,SAAS,EAAE;oBACT,SAAS,EAAE,CAAC,CAAC,GAAG,EAAE,CAAC,EAAE,CAAC;iBACvB;aACF;YACD,eAAe,EAAE,oBAAoB;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M,CAAC,CAAC,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,GAAG,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;QAE1E,MAAM,KAAK,GAAG,OAAO,CAAA,MAAA,YAAY,CAAC,YAAY,0CAAE,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,KAAI,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,GAAG,CAAC;QAG5E,IAAI,CAAC,QAAQ,CAAC,kBAAkB,EAAE,EAAE;YAClC,OAAO,CAAC,IAAI,CAAC,qCAAqC,CAAC,CAAC;YACpD,OAAO;SACR;QAED,MAAM,SAAS,GAAG,GAAG,CAAC;QACtB,IAAA,uBAAa,EACX,gBAAgB,EAChB,aAAa,EACb,SAAS,EACT,MAAsB,EACtB,MAAM,EACN;YACE,KAAK;SACN,CACF,CAAC;QAEF,MAAM,EAAE,YAAY,EAAE,GAAG,IAAI,CAAC,aAAa,CAAC;QAC5C,IAAI,YAAY,IAAI,CAAC,EAAE;YACrB,MAAM,UAAU,GAAG,GAAG,CAAC;YACvB,IAAA,uBAAa,EACX,gBAAgB,EAChB,aAAa,EACb,UAAU,EACV,MAAsB,EACtB,CAAC,EACD;gBACE,KAAK;aACN,CACF,CAAC;SACH;IACH,CAAC;CACF;AAED,SAAS,CAAC,QAAQ,GAAG,OAAO,CAAC;AAC7B,kBAAe,SAAS,CAAC"}
|
|
@@ -89,7 +89,7 @@ class CircleScissorsTool extends base_1.BaseTool {
|
|
|
89
89
|
hasMoved: false,
|
|
90
90
|
segmentationRepresentationUID,
|
|
91
91
|
};
|
|
92
|
-
if ((0, stackVolumeCheck_1.isVolumeSegmentation)(labelmapData)) {
|
|
92
|
+
if ((0, stackVolumeCheck_1.isVolumeSegmentation)(labelmapData, viewport)) {
|
|
93
93
|
const { volumeId } = labelmapData;
|
|
94
94
|
const segmentation = core_1.cache.getVolume(volumeId);
|
|
95
95
|
this.editData = Object.assign(Object.assign({}, this.editData), { volumeId, referencedVolumeId: segmentation.referencedVolumeId });
|