28 #ifndef vtkThreadedImageAlgorithm_h
29 #define vtkThreadedImageAlgorithm_h
31 #include "vtkCommonExecutionModelModule.h"
32 #include "vtkImageAlgorithm.h"
35 class vtkMultiThreader;
41 void PrintSelf(ostream& os, vtkIndent indent) VTK_OVERRIDE;
50 vtkInformationVector **inputVector,
51 vtkInformationVector *outputVector,
52 vtkImageData ***inData,
53 vtkImageData **outData,
54 int extent[6],
int threadId);
57 virtual void ThreadedExecute(vtkImageData *inData,
58 vtkImageData *outData,
59 int extent[6],
int threadId);
65 vtkGetMacro(EnableSMP,
bool);
66 vtkSetMacro(EnableSMP,
bool);
74 static bool GetGlobalDefaultEnableSMP();
82 vtkSetVector3Macro(MinimumPieceSize,
int);
83 vtkGetVector3Macro(MinimumPieceSize,
int);
93 vtkSetMacro(DesiredBytesPerPiece, vtkIdType);
94 vtkGetMacro(DesiredBytesPerPiece, vtkIdType);
105 vtkSetClampMacro(SplitMode,
int, 0, 2);
106 void SetSplitModeToSlab() { this->SetSplitMode(SLAB); }
107 void SetSplitModeToBeam() { this->SetSplitMode(BEAM); }
108 void SetSplitModeToBlock() { this->SetSplitMode(BLOCK); }
109 vtkGetMacro(SplitMode,
int);
117 vtkSetClampMacro( NumberOfThreads,
int, 1, VTK_MAX_THREADS );
118 vtkGetMacro( NumberOfThreads,
int );
131 vtkMultiThreader *Threader;
135 static
bool GlobalDefaultEnableSMP;
147 int MinimumPieceSize[3];
148 vtkIdType DesiredBytesPerPiece;
155 vtkInformationVector** inputVector,
156 vtkInformationVector* outputVector) VTK_OVERRIDE;
165 vtkInformationVector **inputVector,
166 vtkInformationVector *outputVector,
167 vtkImageData ***inData,
168 vtkImageData **outData,
169 vtkIdType begin, vtkIdType end,
170 vtkIdType pieces,
int extent[6]);
179 vtkInformationVector *outputVector,
180 vtkImageData ***inDataObjects=0,
181 vtkImageData **outDataObjects=0);
187 friend class vtkThreadedImageAlgorithmFunctor;
Generic algorithm superclass for image algs.
Definition: vtkImageAlgorithm.h:38
Generic filter that has one input..
Definition: vtkThreadedImageAlgorithm.h:38
virtual void PrepareImageData(vtkInformationVector **inputVector, vtkInformationVector *outputVector, vtkImageData ***inDataObjects=0, vtkImageData **outDataObjects=0)
virtual void SMPRequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector, vtkImageData ***inData, vtkImageData **outData, vtkIdType begin, vtkIdType end, vtkIdType pieces, int extent[6])
virtual int SplitExtent(int splitExt[6], int startExt[6], int num, int total)
virtual void ThreadedRequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector, vtkImageData ***inData, vtkImageData **outData, int extent[6], int threadId)
int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector) VTK_OVERRIDE
void PrintSelf(ostream &os, vtkIndent indent) VTK_OVERRIDE
static void SetGlobalDefaultEnableSMP(bool enable)