This blog entry follows up from previous post Segmenting bone structures with Bounding Box and Eraser Mask by showing another way of using the combination of Region Growing, Bounding Box and Eraser Mask tools.

Initial Guess

We have the following image, that we opened by pressing the Open Image button (or running command RMOpenImage). We want to segment the left scapula of the patient.

Image

In the Image Analysis tab (button Image Analysis or command RMImageAnalysis, Set Threshold subsection) we set a threshold that includes the region we want to segment. In the Segmentation tab (button Segmentation or command RMSegmentation) we press Pick Seed Point (Region Growing Segmentation subsection), select a slice and a point that belongs to the target structure. We press Surface from Region Growing to get a broad surface that contains the smaller region we want. This will guide us to get to our goal combined with the Bounding Box Mask.

Pick Seed Point over thresholded region

Region Growing initial surface

Rough Region Extraction

We go to the Manual Segmentation subsection in the Segmentation tab and press Mask from Threshold button. The threshold mask will be converted into a manually editable mask. In the same subsection, we press Create button under the field Bounding Box. A box will appear that clips the mask, automatically removing anything that is outside.

Bounding Box

We move the bounding box with the gumball. The gumball is a set of arrows and handles that let us transform the box, translate, scale and rotate it (preferably in this order). To see the gumball, we must check the option Gumball that is located in the bottom Rhino interface, between options SmartTrack and Record History.
We then transform the box with the help of the initial surface in order to precisely place the left scapula inside. We can uncheck Show under a particular slice in the Image Analysis tab (Select Region of Interest subsection) if we want to hide a particular coordinate slice to have better visibility.

Note that at this point it may be problematic to properly select the bounding box without selecting the image itself and the initial bone surface. It is recommended to show the layer manager (at right of the Rhino interface, type command Layer to display it) and lock the image layer (called Images) and surfaces layer (usually called Surface or Region Growing), by clicling over the lock symbol next to every layer. The bounding box itself belongs to a layer named Bounding Box and can also be locked, changed visibility and color. It is important to, once the editing of the bounding box is finished, unlock the Images layer if it was ever locked.

Layer manager

Once we are done with transforming the bounding box so that it almost only contains the structure of interest, we first delete the initial surface guess that we got using Region Growing (or alternatively rename its layer and change its visibility), then press Surface from Region Growing button (Segmentation tab, Region Growing Segmentation subsection) after checking On Mask and Close Surface checkboxes. It is crucial to have checked On Mask because otherwise the seed point will grow to the whole image again instead of the smaller mask we have defined with the bounding box. Close Surface will give us a closed surface mesh.

If we think we can improve this result, we can reiterate: delete the surface (use SelMesh command to quickly select and delete all visible unlocked scene meshes) or rename and hide its layer, edit the mask and push Surface from Region Growing, until we have the optimal result.

Region Growing after Bounding Box editing

Polish and Separate Meshes

There are certain details of our extracted region that are small and not oriented with respect to the orthogonal axis of the scene, hence cannot be removed by using the bounding box. In our case we have a small part of rib that is attached to the scapula and that we want to remove. For that, we use the Eraser button, located in Segmentation tab, Manual Segmentation subsection.

We press Eraser and a window containing painting tools is launched. With it we can paint area in the image that will be erased from the manual mask when hitting the Apply button. With the window running we scroll through the image in the Image Analysis, paint over a few separated slices and then hit Fill Between Slices to interpolate in between, and eventually press Apply to remove the highlighted mask from the manual mask.

Eraser Mask

We use the eraser to remove the part of the mask corresponding to rib bone.

Scapula after using Eraser Mask

We can user Eraser as many times as necessary to continue polishing the surface. We press Surface from Region Growing button with On Mask and Close Surface checked (minding that we do not have a previous surface already in the layer Region Growing, and that this layer is visible), and extract our final surface, closed and ready for 3D printing.

The initial broad surface with the overlapping left scapula

The isolated left scapula surface