Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions packages/tools/examples/labelmapMIP/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,20 @@ addButtonToToolbar({
},
});

addButtonToToolbar({
title: 'Delete Labelmap Representation',
onClick: () => {
const representations =
segmentation.state.getSegmentationRepresentations(viewportId2);

if (representations && representations.length > 0) {
segmentation.removeSegmentationRepresentation(
viewportId2,
segmentationId as any
);
}
},
});
/**
* Runs the demo
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -196,6 +196,7 @@ export async function addVolumesAsIndependentComponents({
const { element, id } = viewport;
viewport.removeActors([uid]);

//Here throw error when removed segmentation representation on MIP viewport
const actor = await createVolumeActor(
{
volumeId: uid,
Expand Down
Loading