Main Page | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members | Related Pages

vtkMarchingSquares.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    $RCSfile: vtkMarchingSquares.h,v $
00005 
00006   Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
00007   All rights reserved.
00008   See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
00009 
00010      This software is distributed WITHOUT ANY WARRANTY; without even
00011      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
00012      PURPOSE.  See the above copyright notice for more information.
00013 
00014 =========================================================================*/
00041 #ifndef __vtkMarchingSquares_h
00042 #define __vtkMarchingSquares_h
00043 
00044 #include "vtkPolyDataAlgorithm.h"
00045 
00046 #include "vtkContourValues.h" // Passes calls to vtkContourValues
00047 
00048 class vtkImageData;
00049 class vtkPointLocator;
00050 
00051 class VTK_GRAPHICS_EXPORT vtkMarchingSquares : public vtkPolyDataAlgorithm
00052 {
00053 public:
00054   static vtkMarchingSquares *New();
00055   vtkTypeRevisionMacro(vtkMarchingSquares,vtkPolyDataAlgorithm);
00056   void PrintSelf(ostream& os, vtkIndent indent);
00057 
00059 
00063   vtkSetVectorMacro(ImageRange,int,6);
00064   vtkGetVectorMacro(ImageRange,int,6);
00065   void SetImageRange(int imin, int imax, int jmin, int jmax, 
00066                      int kmin, int kmax);
00068 
00070 
00071   void SetValue(int i, double value);
00072   double GetValue(int i);
00073   double *GetValues();
00074   void GetValues(double *contourValues);
00075   void SetNumberOfContours(int number);
00076   int GetNumberOfContours();
00077   void GenerateValues(int numContours, double range[2]);
00078   void GenerateValues(int numContours, double rangeStart, double rangeEnd);
00080 
00082   unsigned long int GetMTime();
00083 
00084   void SetLocator(vtkPointLocator *locator);
00085   vtkGetObjectMacro(Locator,vtkPointLocator);
00086 
00089   void CreateDefaultLocator();
00090 
00091 protected:
00092   vtkMarchingSquares();
00093   ~vtkMarchingSquares();
00094 
00095   virtual int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *);
00096   virtual int FillInputPortInformation(int port, vtkInformation *info);
00097 
00098   vtkContourValues *ContourValues;
00099   int ImageRange[6];
00100   vtkPointLocator *Locator;
00101 
00102 private:
00103   vtkMarchingSquares(const vtkMarchingSquares&);  // Not implemented.
00104   void operator=(const vtkMarchingSquares&);  // Not implemented.
00105 };
00106 
00109 inline void vtkMarchingSquares::SetValue(int i, double value)
00110 {this->ContourValues->SetValue(i,value);}
00111 
00113 
00114 inline double vtkMarchingSquares::GetValue(int i)
00115 {return this->ContourValues->GetValue(i);}
00117 
00119 
00121 inline double *vtkMarchingSquares::GetValues()
00122 {return this->ContourValues->GetValues();}
00124 
00128 inline void vtkMarchingSquares::GetValues(double *contourValues)
00129 {this->ContourValues->GetValues(contourValues);}
00130 
00134 inline void vtkMarchingSquares::SetNumberOfContours(int number)
00135 {this->ContourValues->SetNumberOfContours(number);}
00136 
00138 
00139 inline int vtkMarchingSquares::GetNumberOfContours()
00140 {return this->ContourValues->GetNumberOfContours();}
00142 
00144 
00146 inline void vtkMarchingSquares::GenerateValues(int numContours, double range[2])
00147 {this->ContourValues->GenerateValues(numContours, range);}
00149 
00151 
00153 inline void vtkMarchingSquares::GenerateValues(int numContours, double
00154                                              rangeStart, double rangeEnd)
00155 {this->ContourValues->GenerateValues(numContours, rangeStart, rangeEnd);}
00157 
00158 #endif

Generated on Mon Jan 21 23:07:25 2008 for VTK by  doxygen 1.4.3-20050530