VTK
vtkTessellatorFilter.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3 Program: Visualization Toolkit
4 Module: vtkTessellatorFilter.h
5 Language: C++
6 
7 Copyright 2003 Sandia Corporation.
8 Under the terms of Contract DE-AC04-94AL85000, there is a non-exclusive
9 license for use of this work by or on behalf of the
10 U.S. Government. Redistribution and use in source and binary forms, with
11 or without modification, are permitted provided that this Notice and any
12 statement of authorship are reproduced on all copies.
13 
14 =========================================================================*/
15 #ifndef vtkTessellatorFilter_h
16 #define vtkTessellatorFilter_h
17 
61 #include "vtkFiltersGeneralModule.h" // For export macro
63 
64 class vtkDataArray;
65 class vtkDataSet;
67 class vtkPointLocator;
68 class vtkPoints;
72 
74 {
75 public:
77  void PrintSelf( ostream& os, vtkIndent indent );
78 
79  static vtkTessellatorFilter* New();
80 
81  virtual void SetTessellator( vtkStreamingTessellator* );
82  vtkGetObjectMacro(Tessellator, vtkStreamingTessellator);
83 
84  virtual void SetSubdivider( vtkDataSetEdgeSubdivisionCriterion* );
85  vtkGetObjectMacro(Subdivider, vtkDataSetEdgeSubdivisionCriterion);
86 
87  virtual unsigned long GetMTime();
88 
90 
95  vtkSetClampMacro(OutputDimension,int,1,3);
96  vtkGetMacro(OutputDimension,int);
97  //BTX
98  int GetOutputDimension() const;
99  //ETX
101 
103 
106  virtual void SetMaximumNumberOfSubdivisions( int num_subdiv_in );
107  int GetMaximumNumberOfSubdivisions();
108  virtual void SetChordError( double ce );
109  double GetChordError();
111 
113 
114  virtual void ResetFieldCriteria();
115  virtual void SetFieldCriterion( int field, double chord );
117 
119 
123  vtkGetMacro(MergePoints,int);
124  vtkSetMacro(MergePoints,int);
125  vtkBooleanMacro(MergePoints,int);
127 
128 protected:
131 
133 
137  void SetupOutput( vtkDataSet* input, vtkUnstructuredGrid* output );
138 
140  void MergeOutputPoints( vtkUnstructuredGrid* input, vtkUnstructuredGrid* output );
141 
144  void Teardown();
145 
147 
148  virtual int RequestData(vtkInformation* request,
149  vtkInformationVector** inputVector,
150  vtkInformationVector* outputVector);
152 
153  //BTX
159 
161 
168 
169  static void AddAPoint( const double*,
171  void*,
172  const void* );
173  static void AddALine( const double*,
174  const double*,
176  void*,
177  const void* );
178  static void AddATriangle( const double*,
179  const double*,
180  const double*,
182  void*,
183  const void* );
184  static void AddATetrahedron( const double*,
185  const double*,
186  const double*,
187  const double*,
189  void*,
190  const void* );
191  void OutputPoint( const double* );
192  void OutputLine( const double*, const double* );
193  void OutputTriangle( const double*, const double*, const double* );
194  void OutputTetrahedron( const double*,
195  const double*,
196  const double*,
197  const double* );
198  //ETX
199 
200 private:
201  vtkTessellatorFilter( const vtkTessellatorFilter& ); // Not implemented.
202  void operator = ( const vtkTessellatorFilter& ); // Not implemented.
203 };
204 
205 //BTX
207 {
208  return this->OutputDimension;
209 }
210 //ETX
211 
212 #endif // vtkTessellatorFilter_h
vtkPointLocator * Locator
a subclass of vtkEdgeSubdivisionCriterion for vtkDataSet objects.
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
vtkUnstructuredGrid * OutputMesh
An algorithm that refines an initial simplicial tessellation using edge subdivision.
quickly locate points in 3-space
Store vtkAlgorithm input/output information.
abstract class to specify dataset behavior
Definition: vtkDataSet.h:61
static vtkUnstructuredGridAlgorithm * New()
virtual int FillInputPortInformation(int port, vtkInformation *info)
vtkDataSetEdgeSubdivisionCriterion * Subdivider
approximate nonlinear FEM elements with simplices
virtual unsigned long GetMTime()
a simple class to control print indentation
Definition: vtkIndent.h:38
dataset represents arbitrary combinations of all possible cell types
abstract superclass for arrays of numeric data
Definition: vtkDataArray.h:54
void PrintSelf(ostream &os, vtkIndent indent)
#define VTKFILTERSGENERAL_EXPORT
Superclass for algorithms that produce only unstructured grid as output.
how to decide whether a linear approximation to nonlinear geometry or field should be subdivided ...
vtkDataArray ** OutputAttributes
Store zero or more vtkInformation instances.
vtkStreamingTessellator * Tessellator
virtual int GetOutputDimension()
represent and manipulate 3D points
Definition: vtkPoints.h:38