Common/vtkOrderedTriangulator.h Source File

Main Page Class Hierarchy Alphabetical List Compound List File List Compound Members File Members Related Pages

# Common/vtkOrderedTriangulator.h

Go to the documentation of this file.

    00001 /*=========================================================================
    00002
    00003   Program:   Visualization Toolkit
    00004   Module:    $RCSfile: vtkOrderedTriangulator.h,v $
    00005   Language:  C++
    00006
    00007   Copyright (c) 1993-2002 Ken Martin, Will Schroeder, Bill Lorensen
    00008   All rights reserved.
    00009   See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
    00010
    00011      This software is distributed WITHOUT ANY WARRANTY; without even
    00012      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
    00013      PURPOSE.  See the above copyright notice for more information.
    00014
    00015 =========================================================================*/
    00080 #ifndef __vtkOrderedTriangulator_h
    00081 #define __vtkOrderedTriangulator_h
    00082
    00083 #include "vtkObject.h"
    00084
    00085 class vtkUnstructuredGrid;
    00086 class vtkOTMesh;
    00087 class vtkCellArray;
    00088 class vtkMemoryPool;
    00089 class vtkIdList;
    00090 class vtkPoints;
    00091
    00092 class VTK_COMMON_EXPORT vtkOrderedTriangulator : public vtkObject
    00093 {
    00094 public:
    00095   vtkTypeRevisionMacro(vtkOrderedTriangulator,vtkObject);
    00096   void PrintSelf(ostream& os, vtkIndent indent);
    00097
    00099   static vtkOrderedTriangulator *New();
    00100
    00102
    00104   void InitTriangulation(float xmin, float xmax, float ymin, float ymax,
    00105                          float zmin, float zmax, int numPts);
    00106   void InitTriangulation(float bounds[6], int numPts);
    00108
    00110
    00123   vtkIdType InsertPoint(vtkIdType id, float x[3], float p[3], int type);
    00124   vtkIdType InsertPoint(vtkIdType id, vtkIdType sortid, float x[3], float p[3],
    00125                         int type);
    00126   vtkIdType InsertPoint(vtkIdType id, vtkIdType sortid,  vtkIdType sortid2,
    00127                         float x[3], float p[3], int type);
    00129
    00132   void Triangulate();
    00133
    00139   void UpdatePointType(vtkIdType internalId, int type);
    00140
    00142
    00146   vtkSetMacro(PreSorted,int);
    00147   vtkGetMacro(PreSorted,int);
    00148   vtkBooleanMacro(PreSorted,int);
    00150
    00152
    00154   vtkSetMacro(UseTwoSortIds,int);
    00155   vtkGetMacro(UseTwoSortIds,int);
    00156   vtkBooleanMacro(UseTwoSortIds,int);
    00158
    00168   vtkIdType GetTetras(int classification, vtkUnstructuredGrid *ugrid);
    00169
    00177   vtkIdType AddTetras(int classification, vtkUnstructuredGrid *ugrid);
    00178
    00184   vtkIdType AddTetras(int classification, vtkCellArray *connectivity);
    00185
    00189   vtkIdType AddTetras(int classification, vtkIdList *ptIds, vtkPoints *pts);
    00190
    00193   vtkIdType AddTriangles(vtkCellArray *connectivity);
    00194
    00198   vtkIdType AddTriangles(vtkIdType id, vtkCellArray *connectivity);
    00199
    00200 protected:
    00201   vtkOrderedTriangulator();
    00202   ~vtkOrderedTriangulator();
    00203
    00204 private:
    00205   vtkOTMesh  *Mesh;
    00206   int NumberOfPoints; //number of points inserted
    00207   int MaximumNumberOfPoints; //maximum possible number of points to be inserted
    00208   int PreSorted;
    00209   int UseTwoSortIds;
    00210   vtkMemoryPool* Pool;
    00211   double Quanta;
    00212
    00213 private:
    00214   vtkOrderedTriangulator(const vtkOrderedTriangulator&);  // Not implemented.
    00215   void operator=(const vtkOrderedTriangulator&);  // Not implemented.
    00216 };
    00217
    00218 #endif
    00219
    00220