[vtkusers] vtkIterativeClosestPointTransform

Gregory Bleiker gregory.bleiker at phonak.ch
Mon Feb 4 12:44:47 EST 2002


Hi everybody
I'm still trying to use

vtkIterativeClosestPointTransform

I am using the C++ version of the 4.0 release canditate. The results are somewhat unclear to me; especially one thing: is the transformation preserving size or not? To me it seems as if it is scaling the data that should be fit (the source) to achieve a better fit. The original ICP does not do this, I think. Can I turn it off?
Can I in any way influence the way the algorithm selects landmarks? Does it do a uniform sample (I'm using imported stls) or take the corner points of the triangles?

Any help appreciated

Gregi Bleiker


PS. The code fragment, for anyone who feels inclined... :)

  icp->SetSource (data);
  icp->SetTarget (data2);
  icp->SetCheckMeanDistance(true);
  icp->SetMaximumMeanDistance(0.001);
  icp->SetMaximumNumberOfIterations(3000);
  icp->SetMaximumNumberOfLandmarks(800);
  icp->StartByMatchingCentroidsOff();  
  icp->Update();
  //icp->SetMaximumNumberOfIterations (1);     
  int i= icp->GetNumberOfIterations();
  vtkPolyDataMapper *shellMapper = vtkPolyDataMapper::New();  
  shellMapper->SetInput( shell->GetOutput());
    
  vtkDataSetMapper *shell2Mapper = vtkDataSetMapper::New();  
  shell2Mapper->SetInput( shell2->GetOutput() );

  vtkActor *shellActor = vtkActor::New();
  shellActor->SetMapper( shellMapper );
  shellActor->SetUserTransform(icp); // btw data is mapped to shell




More information about the vtkusers mailing list