Hello,
I am new to 3D Slicer, and currently, I am learning how to develop a new module in 3D Slicer to implement new features.
The basic idea of the module I am going to achieve is:
To enable users to specify and extract image data from a specific region by placing widgets like ROI boxes in the volume rendering view for subsequent statistical calculations. For example, first, the user places an ROI box in the 3D view of volume rendering and then clicks a button on the GUI panel implemented by this module to get the count of pixels in the region enclosed by the ROI box, which is somewhat similar to the segmentation operation.
I learned that the ‘segment editor’ module in 3D Slicer could be used to perform segmentation, but it is done by iterating all the medical image slices and drawing contour lines on three orthogonal planes. The user cannot directly extract the ROI in the 3D view of the volume rendering through widgets (in my case, I would like to extract the information such as pixel count in a box-shaped region by placing a box in the 3D view directly.)
Therefore, is it possible to implement this feature in 3D Slicer? Could you please elaborate on the feasibility of developing this feature? What do I need to learn to develop this module?
I appreciate any help and suggestions in advance!
The figure below is similar to the effect I’m going to achieve, FYI:
You can segment by iterating through slices but there are many other tools.
If you just need a rectangular region then you can draw an annotation or markups ROI and crop the volume using Crop volume module.
If you need free-form cutouts then I would recommend to try Scissors or Surface cut effects to specify region of interest and then add or remove the selected region using Volume clip effect. Install SegmentEditorExtraEffects extension, as it provides a number of additional effects.
Hello Dr.Lassoan,
Thank you for your kind and quick response!
Cool, I see that combine ‘Scissors’ and ‘Mask volume’ can help users to segment image data in the 3D view of volume rendering.
Although I know that both segmentation operations and volume calculations can be done by tools and modules that already exist in 3D Slicer (Scissors, Mask volume, Segmentation statistics).
My purpose is to integrate above functions into one plug-in. Therefore, the form of operation and the workflow will be different with the tools you mentioned.
Is it feasible to develop this module?
Now that these tools of 3D Slicer have implemented similar functions, does this mean that it will be more convenient to implement my own modules and workflows?
Could you please give more suggestions?
Thank you very much!
You need to set up a number of things in multiple modules, so if you want cutting in volume rendering conveniently available (because you need to process hundreds of cases or you are time-constrained or the software will be operated by clinicians) then it make sense to add a scripted module that sets up everything automatically on a single click. It should be fairly straightforward to do this, there are lots of examples in the script repository.
Hello lassoan,
Thank you so much for your previous guidance, I have learned how to create an extension from the tutorial you provided and the development process has been relatively smooth so far.
And you’ve mentioned:
You need to set up a number of things in multiple modules, so if you want cutting in volume rendering conveniently available (because you need to process hundreds of cases or you are time-constrained or the software will be operated by clinicians) then it make sense to add a scripted module that sets up everything automatically on a single click.
That’s exactly how my extension working(Sets up some useful functionalities of existing modules automatically on a single click.)
My question is: After I finish developing this extension, may I distribute and publish it to the Slicer Extensions Index so that users can download it from slicer directly?
It would be great if you could submit your extension to the extensions index so that users can install it by a few clicks. See details here: Extensions — 3D Slicer documentation