00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00035 #ifndef __vtkNonLinearCell_h
00036 #define __vtkNonLinearCell_h
00037
00038 #include "vtkCell.h"
00039
00040 #include "vtkPointLocator.h"
00041 #include "vtkPoints.h"
00042
00043 class vtkPolyData;
00044 class vtkDataSet;
00045 class vtkUnstructuredGrid;
00046
00047 class VTK_FILTERING_EXPORT vtkNonLinearCell : public vtkCell
00048 {
00049 public:
00050 vtkTypeRevisionMacro(vtkNonLinearCell,vtkCell);
00051 void PrintSelf(ostream& os, vtkIndent indent);
00052
00054
00056 vtkSetClampMacro(Error,double,0.001,1.0);
00057 vtkGetMacro(Error,double);
00059
00063 virtual int IsLinear() {return 0;}
00064
00066
00076 virtual void Tessellate(vtkIdType cellId,
00077 vtkDataSet *input, vtkPolyData *output,
00078 vtkPointLocator *locator=NULL);
00080
00082
00092 virtual void Tessellate(vtkIdType cellId,
00093 vtkDataSet *input, vtkUnstructuredGrid *output,
00094 vtkPointLocator *locator=NULL);
00096
00097
00098 protected:
00099 vtkNonLinearCell();
00100 ~vtkNonLinearCell() {}
00101
00102 double Error;
00103
00104
00105 vtkIdType InsertPoint(vtkPointLocator *locator, vtkPoints *pts, double *x)
00106 {
00107 if ( locator != NULL )
00108 {
00109 vtkIdType p;
00110 locator->InsertUniquePoint(x,p);
00111 return p;
00112 }
00113 else
00114 {
00115 return pts->InsertNextPoint(x);
00116 }
00117 }
00118
00119 private:
00120 vtkNonLinearCell(const vtkNonLinearCell&);
00121 void operator=(const vtkNonLinearCell&);
00122 };
00123
00124 #endif
00125
00126