[vtkusers] Re: 3D reconstitution and contour Filtring

Michael Knopke Michael.Knopke at gmx.de
Wed Feb 7 12:12:51 EST 2007


Hi Mohamed,

well the link did not work it sent me to general GE website.

I used vtkImageShrinker3D before and had good results with it,
but I didn't like the filtering of little detail it always does. (I tried
all options not to filter). No I use vtkImageResample to reduce the volume
and then I will manually filter (user can choose) with median filter.


Here is how I do SSD:

  volume16 as input (localSource)

  // vtkImageResample
  image_Resample->SetInputConnection(localSource);
  image_Resample->SetAxisMagnificationFactor(0,.5);
  image_Resample->SetAxisMagnificationFactor(1,.5);
  image_Resample->SetAxisMagnificationFactor(2,.5);
  image_Resample->ReleaseDataFlagOff();

  // vtkImageMedian3D
  median3D->SetInputConnection(image_Resample->GetOutputPort());
  median3D->ReleaseDataFlagOff();
  //optional: median3D->SetKernelSize(X,Y,Z)
  // i usually use only 2D filtering since 3D filtering takes very long
  // just increase X and Y and leave Z = 1



  // the marching cubes      
  iso_Extractor->SetInputConnection(median3D->GetOutputPort());
  iso_Extractor->SetValue(0, StartValue);
  iso_Extractor->ComputeGradientsOn();
  iso_Extractor->ComputeNormalsOn();
  iso_Extractor->ReleaseDataFlagOff();

    // the mapper for the iso_extractor
  iso_Mapper->SetInput(iso_Extractor->GetOutput());
  iso_Mapper->ScalarVisibilityOff();
  iso_Mapper->ReleaseDataFlagOff();


  // the actor for the iso_extractor
  iso_Actor->SetMapper(iso_Mapper);
  iso_Actor->SetPosition(0,0,0);

Regards

Michael

-- 
"Feel free" - 5 GB Mailbox, 50 FreeSMS/Monat ...
Jetzt GMX ProMail testen: http://www.gmx.net/de/go/promail?ac=OM.GX.GX003K11711T4781a



More information about the vtkusers mailing list