How to edit an STL file using Segment Editor

I want to do some modifications on my stl file. when I open it from file as a data the “Segment Editor” is NOT active. How may I do that?

See step-by-step instructions in Segmentations module documentation (see the tip at the end of the section on how to create a master volume if you don’t have one).

1 Like

Great! It works now. Thanks a lot.

1 Like

I load the stl file and after specifying the geometry I tried to modify the stl file using Draw tube effect. when I click on Draw tube effect a message shows up that says:“change master representation to binary labelmap”. if say YES,the files quality changes like


attached screenshot. what would be the solution for this?
The barbed fitting beforehand is added to the stl file in solidworks.(FYI)
Many thanks

This is looks good. The resolution you choose determines what details are preserved. If it is not feasible to use a resolution that preserves all the details you need (e.g., because your segmentation is large and your computer could not handle a very fine resolution labelmap of that size) then you can combine image-derived meshes with CAD parts by Boolean mesh operations, using Combine Models module (in Sandbox extension).

Thanks for quick reply. This quality does not work for my case because the tube should be fitted to the fitting barbed that you see in the screen shot and this one will end up with a leakage.
How may I change the resolution?
Does the image spacing change the mentioned quality? for my case the image spacing is 1mm along each axes. What happened if I change it e.g to 0.1mm?

Spacing of the binary labelmap representation of the segmentation directly determines “quality”, i.e., size of the smallest details that can be preserved. Typical spacing is between few tenths of a millimeter to a few millimeters - consistent with spacing of the input images. However, if you need fitting between mechanical parts then you would need to work with 1-2 magnitudes smaller spacing along each axis, which would mean that you would have 3-6 magnitudes more voxels in the labelmap. Working with such large labelmaps (tens of GBs in size) is often not practically feasible, so if you need to combine pieces from image-driven segmentations with CAD parts, I would recommend to export the segmentation to models and then combine them with CAD-designed meshes using Combine models module.

When I load data (.stl model) into Slicer there are three options(segmentation-model-volume). If I choose model and load it, is there any way to modify the model? e.g cutting a part of it?
Thanks

Look at the Dynamic Modeler module, which provides tools for manipulation of surface models, including cutting.

1 Like

Thank you Mike. it works for cutting. Is there any option to fill holes ,…etc there?

The Surface Toolbox module has a variety of processing options oriented towards cleaning up and optimizing model meshes. One of the options there is “Fill Holes”, which might accomplish what you want (I don’t have experience with using that tool, so I’m not sure how it goes about filling holes).

Depending on what manipulations you want to do, you might have an easier time loading your stl as a segmentation and editing it using the Segment Editor tools. Then you can convert back to a surface representation after editing.

1 Like

Hello,
How can I use painting option with stl file?segment editor is inactive when open a stl file

Right click on the stl object in the Data module and choose “convert model to Segmentation node”

1 Like

Perfect! Thank you so much Muratmaga