Main Page Class Hierarchy Alphabetical List Compound List File List Compound Members File Members Related Pages
Patented/vtkSynchronizedTemplates3D.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00059 #ifndef __vtkSynchronizedTemplates3D_h
00060 #define __vtkSynchronizedTemplates3D_h
00061
00062 #include "vtkPolyDataSource.h"
00063 #include "vtkContourValues.h"
00064
00065 class vtkImageData;
00066 class vtkKitwareContourFilter;
00067 class vtkMultiThreader;
00068
00069 class VTK_PATENTED_EXPORT vtkSynchronizedTemplates3D : public vtkPolyDataSource
00070 {
00071 public:
00072 static vtkSynchronizedTemplates3D *New();
00073
00074 vtkTypeRevisionMacro(vtkSynchronizedTemplates3D,vtkPolyDataSource);
00075 void PrintSelf(ostream& os, vtkIndent indent);
00076
00078
00079 void SetInput(vtkImageData *input);
00080 vtkImageData *GetInput();
00082
00084 unsigned long int GetMTime();
00085
00087
00091 vtkSetMacro(ComputeNormals,int);
00092 vtkGetMacro(ComputeNormals,int);
00093 vtkBooleanMacro(ComputeNormals,int);
00095
00097
00103 vtkSetMacro(ComputeGradients,int);
00104 vtkGetMacro(ComputeGradients,int);
00105 vtkBooleanMacro(ComputeGradients,int);
00107
00109
00110 vtkSetMacro(ComputeScalars,int);
00111 vtkGetMacro(ComputeScalars,int);
00112 vtkBooleanMacro(ComputeScalars,int);
00114
00117 void SetValue(int i, float value) {this->ContourValues->SetValue(i,value);}
00118
00120 float GetValue(int i) {return this->ContourValues->GetValue(i);}
00121
00124 float *GetValues() {return this->ContourValues->GetValues();}
00125
00127
00130 void GetValues(float *contourValues) {
00131 this->ContourValues->GetValues(contourValues);}
00133
00135
00138 void SetNumberOfContours(int number) {
00139 this->ContourValues->SetNumberOfContours(number);}
00141
00143
00144 int GetNumberOfContours() {
00145 return this->ContourValues->GetNumberOfContours();}
00147
00149
00151 void GenerateValues(int numContours, float range[2]) {
00152 this->ContourValues->GenerateValues(numContours, range);}
00154
00156
00158 void GenerateValues(int numContours, float rangeStart, float rangeEnd)
00159 {this->ContourValues->GenerateValues(numContours, rangeStart, rangeEnd);}
00161
00163
00164 int *GetExecuteExtent() {return this->ExecuteExtent;}
00165 void ThreadedExecute(vtkImageData *data, int *exExt, int threadId);
00167
00169
00170 vtkSetClampMacro( NumberOfThreads, int, 1, VTK_MAX_THREADS );
00171 vtkGetMacro( NumberOfThreads, int );
00173
00175
00178 void SetInputMemoryLimit(unsigned long limit);
00179 unsigned long GetInputMemoryLimit();
00181
00182 protected:
00183 vtkSynchronizedTemplates3D();
00184 ~vtkSynchronizedTemplates3D();
00185
00187
00190 vtkGetStringMacro(InputScalarsSelection);
00191 void SelectInputScalars(const char *fieldName)
00192 {this->SetInputScalarsSelection(fieldName);}
00194
00195
00196 int ComputeNormals;
00197 int ComputeGradients;
00198 int ComputeScalars;
00199 vtkContourValues *ContourValues;
00200
00201 void Execute();
00202 void ExecuteInformation();
00203
00204 void ComputeInputUpdateExtents(vtkDataObject *output);
00205
00206 int ExecuteExtent[6];
00207
00208 int NumberOfThreads;
00209 vtkMultiThreader *Threader;
00210
00211 vtkPolyData *Threads[VTK_MAX_THREADS];
00212
00213 char *InputScalarsSelection;
00214 vtkSetStringMacro(InputScalarsSelection);
00215
00216 private:
00217
00218 friend class VTK_PATENTED_EXPORT vtkKitwareContourFilter;
00219
00220
00221 private:
00222 vtkSynchronizedTemplates3D(const vtkSynchronizedTemplates3D&);
00223 void operator=(const vtkSynchronizedTemplates3D&);
00224 };
00225
00226
00227
00228
00229
00230
00231
00232
00233
00234
00235 extern int VTK_SYNCHONIZED_TEMPLATES_3D_TABLE_1[];
00236 extern int VTK_SYNCHONIZED_TEMPLATES_3D_TABLE_2[];
00237
00238
00239
00240 #endif
00241