00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00052 #ifndef __vtkContourFilter_h
00053 #define __vtkContourFilter_h
00054
00055 #include "vtkPolyDataAlgorithm.h"
00056
00057 #include "vtkContourValues.h"
00058
00059 class vtkIncrementalPointLocator;
00060 class vtkScalarTree;
00061 class vtkSynchronizedTemplates2D;
00062 class vtkSynchronizedTemplates3D;
00063 class vtkGridSynchronizedTemplates3D;
00064 class vtkRectilinearSynchronizedTemplates;
00065
00066 class VTK_GRAPHICS_EXPORT vtkContourFilter : public vtkPolyDataAlgorithm
00067 {
00068 public:
00069 vtkTypeMacro(vtkContourFilter,vtkPolyDataAlgorithm);
00070 void PrintSelf(ostream& os, vtkIndent indent);
00071
00074 static vtkContourFilter *New();
00075
00077
00078 void SetValue(int i, double value);
00079 double GetValue(int i);
00080 double *GetValues();
00081 void GetValues(double *contourValues);
00082 void SetNumberOfContours(int number);
00083 int GetNumberOfContours();
00084 void GenerateValues(int numContours, double range[2]);
00085 void GenerateValues(int numContours, double rangeStart, double rangeEnd);
00087
00089 unsigned long GetMTime();
00090
00092
00096 vtkSetMacro(ComputeNormals,int);
00097 vtkGetMacro(ComputeNormals,int);
00098 vtkBooleanMacro(ComputeNormals,int);
00100
00102
00108 vtkSetMacro(ComputeGradients,int);
00109 vtkGetMacro(ComputeGradients,int);
00110 vtkBooleanMacro(ComputeGradients,int);
00112
00114
00115 vtkSetMacro(ComputeScalars,int);
00116 vtkGetMacro(ComputeScalars,int);
00117 vtkBooleanMacro(ComputeScalars,int);
00119
00121
00122 vtkSetMacro(UseScalarTree,int);
00123 vtkGetMacro(UseScalarTree,int);
00124 vtkBooleanMacro(UseScalarTree,int);
00126
00128
00129 virtual void SetScalarTree(vtkScalarTree*);
00130 vtkGetObjectMacro(ScalarTree,vtkScalarTree);
00132
00134
00136 void SetLocator(vtkIncrementalPointLocator *locator);
00137 vtkGetObjectMacro(Locator,vtkIncrementalPointLocator);
00139
00142 void CreateDefaultLocator();
00143
00145
00148 void SetArrayComponent( int );
00149 int GetArrayComponent();
00151
00153
00154 virtual int ProcessRequest(vtkInformation*,
00155 vtkInformationVector**,
00156 vtkInformationVector*);
00158
00159 protected:
00160 vtkContourFilter();
00161 ~vtkContourFilter();
00162
00163 virtual void ReportReferences(vtkGarbageCollector*);
00164
00165 virtual int RequestData(vtkInformation* request,
00166 vtkInformationVector** inputVector,
00167 vtkInformationVector* outputVector);
00168 virtual int RequestUpdateExtent(vtkInformation*,
00169 vtkInformationVector**,
00170 vtkInformationVector*);
00171 virtual int FillInputPortInformation(int port, vtkInformation *info);
00172
00173 vtkContourValues *ContourValues;
00174 int ComputeNormals;
00175 int ComputeGradients;
00176 int ComputeScalars;
00177 vtkIncrementalPointLocator *Locator;
00178 int UseScalarTree;
00179 vtkScalarTree *ScalarTree;
00180
00181 vtkSynchronizedTemplates2D *SynchronizedTemplates2D;
00182 vtkSynchronizedTemplates3D *SynchronizedTemplates3D;
00183 vtkGridSynchronizedTemplates3D *GridSynchronizedTemplates;
00184 vtkRectilinearSynchronizedTemplates *RectilinearSynchronizedTemplates;
00185
00186 private:
00187 vtkContourFilter(const vtkContourFilter&);
00188 void operator=(const vtkContourFilter&);
00189 };
00190
00193 inline void vtkContourFilter::SetValue(int i, double value)
00194 {this->ContourValues->SetValue(i,value);}
00195
00197
00198 inline double vtkContourFilter::GetValue(int i)
00199 {return this->ContourValues->GetValue(i);}
00201
00203
00205 inline double *vtkContourFilter::GetValues()
00206 {return this->ContourValues->GetValues();}
00208
00212 inline void vtkContourFilter::GetValues(double *contourValues)
00213 {this->ContourValues->GetValues(contourValues);}
00214
00218 inline void vtkContourFilter::SetNumberOfContours(int number)
00219 {this->ContourValues->SetNumberOfContours(number);}
00220
00222
00223 inline int vtkContourFilter::GetNumberOfContours()
00224 {return this->ContourValues->GetNumberOfContours();}
00226
00228
00230 inline void vtkContourFilter::GenerateValues(int numContours, double range[2])
00231 {this->ContourValues->GenerateValues(numContours, range);}
00233
00235
00237 inline void vtkContourFilter::GenerateValues(int numContours, double
00238 rangeStart, double rangeEnd)
00239 {this->ContourValues->GenerateValues(numContours, rangeStart, rangeEnd);}
00241
00242
00243 #endif
00244
00245