cornerstone3D icon indicating copy to clipboard operation
cornerstone3D copied to clipboard

cant get segmentation state for BrushTool

Open dima9911 opened this issue 1 year ago • 1 comments

Describe the Bug

Hello. i cant get segmentation state for BrushTool with circlular strategy on stack viewports Снимок экрана 2024-02-14 в 17 32 31

i draw any seg, then i want to save tool state as json. after reload page i want add this json for redraw my segmentation

Steps to Reproduce

  1. add BrushTool and draw
  2. cornerstoneTools.segmentation.state.getSegmentations()[0]

The current behavior

here is result of 2 step

{
    "segmentationId": "SEGMENTATION_derived:259c4ae7-2948-4274-aef5-e415cca689ab",
    "cachedStats": {},
    "segmentLabels": {},
    "label": null,
    "segmentsLocked": {},
    "type": "LABELMAP",
    "activeSegmentIndex": 1,
    "representationData": {
        "LABELMAP": {
            "imageIdReferenceMap": {}
        }
    }
}

The expected behavior

i expected state with coord look like as annotation for redraw after page reload. but i cant get any coords, doc and examples do not help

OS

mac os

Node version

16

Browser

chrome

dima9911 avatar Feb 14 '24 12:02 dima9911

there is no coordinates for the brush, labelmap segmentation is actually pixelData itself, you can look at the values in the cornerstone.cache

sedghi avatar Mar 20 '24 18:03 sedghi