[Insight-users] BinaryErodeImageFilter

Sylvain Jaume sylvain.jaume at kitware.com
Wed Jul 12 12:38:52 EDT 2006


Hi Dan,

Did you try a larger structuring element?

Sylvain

Dan Rico wrote:
> Hi,
>  
> while testing the output of the "itkBinaryErodeImageFilter" on a 3D 
> binary images I found out that the output is identical to the input.
> Does anyone have experienced similar problems with the erosion filter?
>  
> The tests have been performed on version 2.4.1.
>  
> Sample code:
>  
> typedef unsigned char CharPixelType;
> typedef itk::Image <CharPixelType, 3> Input3DImageType;
> typedef itk::BinaryBallStructuringElement<CharPixelType, 3> 
> StructuringElementType3D;
> typedef itk::BinaryErodeImageFilter<Input3DImageType,
>          Input3DImageType,
>          StructuringElementType3D> ErodeFilterTypeInt2Int3D;
> ....
>  
> inputBinaryVolume = readerBinary->GetOutput();
>  
>  unsigned char TubeRadiusSE = 2;
>  StructuringElementType3D structuringElement;
>  structuringElement.SetRadius(TubeRadiusSE);
>  structuringElement.CreateStructuringElement();
>  
>  ErodeFilterTypeInt2Int3D::Pointer binaryErode = 
> ErodeFilterTypeInt2Int3D::New();
>  binaryErode->SetKernel(structuringElement);
>  binaryErode->SetInput(inputBinaryVolume);
>  binaryErode->SetErodeValue(1);
>  binaryErode->Update();  
>  
> Thanks,
> Dan
>  
>  
>
> ------------------------------------------------------------------------
> Yahoo! Music Unlimited - Access over 1 million songs. Try it free. 
> <http://pa.yahoo.com/*http://us.rd.yahoo.com/evt=36035/*http://music.yahoo.com/unlimited/%20> 
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Insight-users mailing list
> Insight-users at itk.org
> http://www.itk.org/mailman/listinfo/insight-users
>   


More information about the Insight-users mailing list