[vtk-developers] vtkRectilinearGrid speed-up in FindPoint + ComputeStructuredCoordinates

Bryn Lloyd lloyd at itis.ethz.ch
Sat Apr 28 20:07:08 EDT 2012


Hi

I've been trying to make our stream-line visualization faster. As a 
result I found that the vtkRectilinearGrid is using linear algorithms to 
locate both cells and points.
A binary search would be more optimal (logarithmic) for medium to large 
sized grids.

I implemented a new version of vtkRectilinearGrid::FindPoint and 
vtkRectilinearGrid::ComputeStructuredCoordinates, which use a binary search.
The speed up for a grid of dimensions around 100*100*200 is close to a 
factor of 10 (this is a small-medium sized grid for our application).
Clearly, it would be great if these changes could enter the next release 
of VTK, since they will make interpolation (used in stream-lines) and 
other algorithms quite a bit faster for rectilinear grids.

How can I contribute these changes such that they have a chance to enter 
in the next release.
I have written tests, which make sure the result is still the same as 
with old implementation and am prepared to put some effort into 
explaining/documenting/testing the changes as needed.

Thanks & regards
Bryn




More information about the vtk-developers mailing list