[vtkusers] vtkOBBTree problem

tp500 at doc.ic.ac.uk tp500 at doc.ic.ac.uk
Mon Mar 17 12:11:52 EST 2003


Hi vtk-users,
I have some large Polydata surfaces and I want to find the closest points. I 
have been using Cell and Point locators in the past but they are not fast 
enough.
I have been trying to write a program testing out the OBBTrees but it 
continuesly crashes after the line obb_tree->FindClosestPoint(...). Has anyone 
encountered this problem before? Any solutions? I seem to be doing everything 
write. Since it inherits from the vtkCellLocator class it should all work the 
same way...but it doesn't.
My code:
  obb_tree->SetDataSet(target_reader->GetOutput());
  obb_tree->SetNumberOfCellsPerBucket(25);
  obb_tree->BuildLocator();
  target_reader->GetOutput()->GetPoint(entry_counter, xyz);
-->obb_tree->FindClosestPoint(xyz, closestPoint, cell, cellId, subId, dist2);
------ CRASHES HERE------

Does the OBBTree class work much faster for point location than the 
CellLocators?
Thanks for all the help.
Theodoros



More information about the vtkusers mailing list