VTK
|
00001 /*========================================================================= 00002 00003 Program: Visualization Toolkit 00004 Module: $RCSfile: vtkGeometryFilter.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 =========================================================================*/ 00049 #ifndef __vtkGeometryFilter_h 00050 #define __vtkGeometryFilter_h 00051 00052 #include "vtkPolyDataAlgorithm.h" 00053 00054 class vtkPointLocator; 00055 00056 class VTK_GRAPHICS_EXPORT vtkGeometryFilter : public vtkPolyDataAlgorithm 00057 { 00058 public: 00059 static vtkGeometryFilter *New(); 00060 vtkTypeRevisionMacro(vtkGeometryFilter,vtkPolyDataAlgorithm); 00061 void PrintSelf(ostream& os, vtkIndent indent); 00062 00064 00065 vtkSetMacro(PointClipping,int); 00066 vtkGetMacro(PointClipping,int); 00067 vtkBooleanMacro(PointClipping,int); 00069 00071 00072 vtkSetMacro(CellClipping,int); 00073 vtkGetMacro(CellClipping,int); 00074 vtkBooleanMacro(CellClipping,int); 00076 00078 00079 vtkSetMacro(ExtentClipping,int); 00080 vtkGetMacro(ExtentClipping,int); 00081 vtkBooleanMacro(ExtentClipping,int); 00083 00085 00086 vtkSetClampMacro(PointMinimum,vtkIdType,0,VTK_LARGE_ID); 00087 vtkGetMacro(PointMinimum,vtkIdType); 00089 00091 00092 vtkSetClampMacro(PointMaximum,vtkIdType,0,VTK_LARGE_ID); 00093 vtkGetMacro(PointMaximum,vtkIdType); 00095 00097 00098 vtkSetClampMacro(CellMinimum,vtkIdType,0,VTK_LARGE_ID); 00099 vtkGetMacro(CellMinimum,vtkIdType); 00101 00103 00104 vtkSetClampMacro(CellMaximum,vtkIdType,0,VTK_LARGE_ID); 00105 vtkGetMacro(CellMaximum,vtkIdType); 00107 00109 00111 void SetExtent(double xMin, double xMax, double yMin, double yMax, 00112 double zMin, double zMax); 00114 00116 00118 void SetExtent(double extent[6]); 00119 double *GetExtent() { return this->Extent;}; 00121 00123 00126 vtkSetMacro(Merging,int); 00127 vtkGetMacro(Merging,int); 00128 vtkBooleanMacro(Merging,int); 00130 00132 00134 void SetLocator(vtkPointLocator *locator); 00135 vtkGetObjectMacro(Locator,vtkPointLocator); 00137 00139 void CreateDefaultLocator(); 00140 00142 unsigned long GetMTime(); 00143 00144 protected: 00145 vtkGeometryFilter(); 00146 ~vtkGeometryFilter(); 00147 00148 virtual int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *); 00149 virtual int FillInputPortInformation(int port, vtkInformation *info); 00150 00151 //special cases for performance 00152 void PolyDataExecute(vtkDataSet *, vtkPolyData *, vtkInformation *); 00153 void UnstructuredGridExecute(vtkDataSet *, vtkPolyData *, vtkInformation *); 00154 void StructuredGridExecute(vtkDataSet *, vtkPolyData *, vtkInformation *); 00155 int RequestUpdateExtent(vtkInformation *, vtkInformationVector **, vtkInformationVector *); 00156 00157 vtkIdType PointMaximum; 00158 vtkIdType PointMinimum; 00159 vtkIdType CellMinimum; 00160 vtkIdType CellMaximum; 00161 double Extent[6]; 00162 int PointClipping; 00163 int CellClipping; 00164 int ExtentClipping; 00165 00166 int Merging; 00167 vtkPointLocator *Locator; 00168 private: 00169 vtkGeometryFilter(const vtkGeometryFilter&); // Not implemented. 00170 void operator=(const vtkGeometryFilter&); // Not implemented. 00171 }; 00172 00173 #endif 00174 00175