Go to the documentation of this file.
29 #ifndef vtkImageStencilIterator_h
30 #define vtkImageStencilIterator_h
46 this->BasePointer = 0;
48 this->SpanEndPointer = 0;
69 this->BasePointer =
static_cast<DType *
>(
71 this->UpdatePointer();
86 image,
extent, stencil, algorithm, threadId);
87 this->BasePointer =
static_cast<DType *
>(
89 this->UpdatePointer();
102 this->UpdatePointer();
119 return this->Pointer;
127 return this->SpanEndPointer;
138 this->Pointer = this->BasePointer + this->Id*this->Increment;
139 this->SpanEndPointer = this->BasePointer + this->SpanEnd*this->Increment;
152 #ifndef vtkImageStencilIterator_cxx
154 #pragma warning (push)
157 #pragma warning (disable: 4910) // extern and dllexport incompatible
163 #pragma warning (pop)
iterate over point data in an image.
bool IsAtEnd()
Test if the iterator has completed iterating over the entire extent.
Superclass for all sources, filters, and sinks in VTK.
static void * GetVoidPointer(vtkImageData *image, vtkIdType i=0, int *pixelIncrement=0)
Get a void pointer and pixel increment for the given point Id.
bool IsAtEnd()
Test if the iterator has completed iterating over the entire extent.
void NextSpan()
Move the iterator to the beginning of the next span.
void Initialize(vtkImageData *image, vtkImageStencilData *stencil=0, const int extent[6]=0, vtkAlgorithm *algorithm=0, int threadId=0)
Initialize an iterator.
DType * BeginSpan()
Return a pointer to the beginning of the current span.
void NextSpan()
Move the iterator to the beginning of the next span.
#define vtkExternTemplateMacro(decl)
A macro to declare extern templates for all numerical types.
topologically and geometrically regular array of data
vtkImageStencilIterator()
Default constructor, its use must be followed by Initialize().
efficient description of an image stencil
DType * EndSpan()
Return a pointer to the end of the current span.
vtkImageStencilIterator(vtkImageData *image, vtkImageStencilData *stencil=0, const int extent[6]=0, vtkAlgorithm *algorithm=0, int threadId=0)
Create an iterator for the given image, with several options.
void UpdatePointer()
Update the pointer (called automatically when a new span begins).
void Initialize(vtkImageData *image, const int extent[6]=0, vtkImageStencilData *stencil=0, vtkAlgorithm *algorithm=0, int threadId=0)
Initialize an iterator.