[vtkusers] vtkImageIterator - feature request?

Mathieu Malaterre mathieu.malaterre at kitware.com
Mon Mar 1 15:10:46 EST 2004


Dean Inglis wrote:
> I'm almost certain, but please correct me if I'm wrong,
> that there is no way to reset a vtkImageIterator after
> it has been used: e.g., 

correct


> Can such a feature be implemented?

Yes. You need to keep track of the initial this->Pointer (so NextSpan 
should not work directly on it).
But I usually use this class on the stack:

for( ... )
{
   vtkImageIterator<T> inIt(inData, outExt);
   vtkImageIterator<T> outIt(outData, outExt);
   ...
}


HTH
Mathieu





More information about the vtkusers mailing list