[vtkusers] Extract contours's features in 2D images

frederic.salvador at epfl.ch frederic.salvador at epfl.ch
Mon Feb 8 05:04:25 EST 2010


Dear all,

I want to detect contours from 2D binary images.
More specifically, once the contours are detected, I would like to get  
their perimeters, areas, and parents->children relationships.

I tried some itk filters which extract contours pretty well, such as  
"itkSimpleContourImageFilter". But the features of the detected  
contours (perimeters, areas,...) cant be extracted from these filters.

So I moved to the "itkContourExtractor2DImageFilter", that I implement  
this way:

typedef itk::ContourExtractor2DImageFilter <Image2D> ExtractorType;
ExtractorType::Pointer Extractor = ExtractorType::New();
Extractor->SetInput(reader->GetOutput());
Extractor->SetContourValue(255.0);
Extractor->Update();

But this filter didnt detect any contours...

Someone could help with this?
Thanks a lot in advance for this.

Fred



More information about the vtkusers mailing list