[Insight-users] Extract 3D contour from mask image

Sergio Vera sergio.vera at alma3d.com
Mon Oct 11 03:19:42 EDT 2010


Hi,
depending on the 3-D shape the contour will be thick, sometimes several
voxels wide. Some shapes generate such thick contours, this is related to
the 3d-neiggborhood of a given voxel. I guess you are evaluating the contour
with a 2-D view? Keep in mind that the following and previous slices will
affect the contour detected at a specific slice... at least that happened to
me. When a shape is smooth and homogeneous, the contour is thin, but when it
has cavities  or bumps, the contour grows.

HTH


On Fri, Oct 8, 2010 at 11:41 PM, Sara Rolfe <smrolfe at u.washington.edu>wrote:

> Thanks Sergio, I have the BinaryContourImageFilter working.  I also got the
> SimpleContourExtractorImageFilter to work by increasing the radius. I have
> one more related question.  I used:
>
> contour->SetFullyConnected(false); // true makes thicker contours
>
>
> to get a thinner contour, but it still appears very thick.  Is there any
> way to get closer to a 1-pixel wide contour from a 3D binary image?
>
> Thanks,
>
> Sara
>
>
> On Oct 8, 2010, at 12:19 AM, Sergio Vera wrote:
>
> Hi Sara
>
> As far as I know, SimpleContourExtractorImageFilter works OK in 3d images.
> We have performed some simple test in the past days and it worked. However,
> we finally use BinaryContourImageFilter as it seems to be faster:
>
> typedef itk::BinaryContourImageFilter <ITKImgLabelType,
> ITKImgLabelType> Contourizer;
> Contourizer::Pointer contour = Contourizer::New();
> contour->SetInput(img);
> contour->SetFullyConnected(false); // true makes thicker contours
> contour->SetBackgroundValue(0);
> contour->SetForegroundValue(255); // the value of your binary mask
> contour->Update()
>
> Regards
>
> On Fri, Oct 8, 2010 at 2:30 AM, Sara Rolfe <smrolfe at u.washington.edu>wrote:
>
>> Hello,
>>
>> I'm attempting to extract the 3d contour from a binary mask image.  I've
>> done this successfully before using the
>> SimpleContourExtractorImageFilter, but in was in 2D.  Is there a problem
>> using this filter in 3D?  Or parameters that need to be changed?  Also, if
>> there are any examples that might help please point me to them.
>>
>> Thanks,
>> Sara
>>
>> _____________________________________
>> Powered by www.kitware.com
>>
>> Visit other Kitware open-source projects at
>> http://www.kitware.com/opensource/opensource.html
>>
>> Kitware offers ITK Training Courses, for more information visit:
>> http://www.kitware.com/products/protraining.html
>>
>> Please keep messages on-topic and check the ITK FAQ at:
>> http://www.itk.org/Wiki/ITK_FAQ
>>
>> Follow this link to subscribe/unsubscribe:
>> http://www.itk.org/mailman/listinfo/insight-users
>>
>>
>
>
> --
> Sergio Vera
>
>  Alma IT Systems
>  C/ Vilana, 4B, 4º 1ª
>  08022 Barcelona
>  T. (+34) 932 380 592
>  www.alma3d.com
>
>
>


-- 
Sergio Vera

 Alma IT Systems
 C/ Vilana, 4B, 4º 1ª
 08022 Barcelona
 T. (+34) 932 380 592
 www.alma3d.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/pipermail/insight-users/attachments/20101011/28fb6eb5/attachment.htm>


More information about the Insight-users mailing list