[vtkusers] recommended cell locator for IntersectWithLine tests?
David Doria
daviddoria+vtk at gmail.com
Wed Dec 16 19:21:56 EST 2009
On Wed, Dec 16, 2009 at 4:45 PM, Dean Inglis <dean.inglis at camris.ca> wrote:
> Hi all,
>
> I am revisiting some old code I wrote to do stereology measurements
> (mean intercept length). I am rotating a set of evenly spaced parallel
> test lines (in the x-y plane) and during each rotation I need to find all
> the intersection points
> of the lines with a set of perpendicular planes defined by a vtkPolyData
> ( imagine the planes as being the walls of a maze ). I was using vtkOBBTree
> with the following settings:
> this->OBBTree->CacheCellBoundsOff();
> this->OBBTree->AutomaticOff();
> this->OBBTree->SetMaxLevel( 100 );
> this->OBBTree->SetNumberOfCellsPerNode( 1 );
>
> but there are some cases wherein not all the interesection points are found.
> The number of "walls" in the "maze" are in the hundreds but less than a
> thousand.
> The walls do not necessarily form closed polygons. Can anyone recommend
> a more robust locator and if so with some suggested settings?
>
> thanks,
> Dean
I highly recommend the vtkModifiedBSPTree. It sped up my intersections
over the OBBTree about 40x. I didn't ever play with those kind of
settings so I can't recommend any, I just used the defaults and it
seemed to work fine for my application.
Thanks,
David
More information about the vtkusers
mailing list