Extract a set of contours from binarylabelMaps

In fact I want to develop a new method which reconstruct a 3D surface Model from a set of contours using implicit models. For the entry I have Brain MRI images stored in DICOM format. When using segment editor to segment the set of images using a contour method. I have BinaryLabelMap as master representation even I need only contours. I know that in SlicerRT there are conversions rules to convert directly the set of contours to a closed surface but in Slicer3D it is not possible. My question is are there a filters that I can use to extract contours from binarylabelMaps as a set of 3D points? I guess I cant’use slicerRT to manipulate IRM images and extract a planar contours?

I am novice in 3D slicer, so thank you so much for any help in advance

It is certainly possible: install SlicerRT extension, loaf your structure set, and choose to create closed surface representation. If you have a y questions about how to do this, you can post to https://discourse.slicer.org.

If you want to do the inverse (create planar contours from closed surface) then it is a simpler operation: you can use vtkContourTriangulator. This filter has some robustness issues for complex surfaces (https://gitlab.kitware.com/vtk/vtk/issues/17627) but works well for reasonably complex ones.

Thank you so much for the response. You mean that I must install SlicerRt and develop the entire application using slicerRT even i I have IRM images. Or is there a way to inegrate SlicerRt extension in Slicer3D so I can use the conversions rules offered by SlicerRt.

It would help a lot if you could tell what the clinical application is and what you would like to achieve overall. For example, would you like to segment structures on MR images and export them to DICOM RT structure set to be used for radiation therapy treatment planning?

I just want to add a new module to Slicer3D. So i will implement the method described in this paper: > Contour-Based Surface Reconstruction using MPU Implicit Models.

As montioned above, I have a set of Brain IRM images from which a want to get a 3D surface of ROI. I have used a segment editor to extract ventricules for exemple but the respresentation is always stored as labelMap (vtlorientedImageData) , but I need only the set of contours from which i would reconstruct the surface. So in Slicer3D , i dont find a coneversion rule to convert labelmap to planar contours. My question is there any possibility to extract only contours from labelMap (segmented volume) or to exploit in my applications directly the contours. If not, can I developp the montioned method in SlicerRT, but I have IRM images.

From the abstract of the MPU paper: “This paper presents a technique for creating a smooth, closed surface from a set of 2D contours”. This is exactly the same that SlicerRT can do.

If you don’t import segmentation but create it from scratch (in Segment Editor) then you don’t even need any contour to surface conversion but only volume to surface conversion, which is a much simpler operation (and performed automatically when you visualize the segmentation in 3D). You can save this closed surface by “Export to files” feature (you can also export the segmentation to model by right-clicking on it in Data module and then use File/Save to write to file in STL, VTK, VTP, obj, or ply format).

What do you do with the segmentation in closed surface format? Create surgical guide, 3D print, import to treatment planning system, visualize in AR/VR/Unity,…? Optimal choice of processing and export methods depend on the final clinical goal.

Thank yo very much for you help, you highlighted the ambiguities.

1 Like