VTK
vtkBridgeCell.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkBridgeCell.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
27 #ifndef vtkBridgeCell_h
28 #define vtkBridgeCell_h
29 
30 #include "vtkBridgeExport.h" //for module export macro
31 #include "vtkGenericAdaptorCell.h"
32 
33 class vtkCell;
34 class vtkBridgeDataSet;
36 
38 {
39 public:
40  static vtkBridgeCell *New();
42  void PrintSelf(ostream& os, vtkIndent indent);
43 
46  virtual vtkIdType GetId();
47 
49  virtual int IsInDataSet();
50 
54  virtual int GetType();
55 
58  virtual int GetDimension();
59 
61  virtual int GetGeometryOrder();
62 
66 
70 
75 
77  virtual int IsPrimary();
78 
81  virtual int GetNumberOfPoints();
82 
91  virtual int GetNumberOfBoundaries(int dim=-1);
92 
101  virtual int GetNumberOfDOFNodes();
102 
105 
108 
110 
114  virtual void GetBoundaryIterator(vtkGenericCellIterator *boundaries,
115  int dim=-1);
117 
119 
124  virtual int CountNeighbors(vtkGenericAdaptorCell *boundary);
125  void CountEdgeNeighbors( int* sharing );
127 
129 
135  virtual void GetNeighbors(vtkGenericAdaptorCell *boundary,
136  vtkGenericCellIterator *neighbors);
138 
140 
144  virtual int FindClosestBoundary(int subId,
145  double pcoords[3],
146  vtkGenericCellIterator* &boundary);
148 
150 
158  virtual int EvaluatePosition(double x[3],
159  double *closestPoint,
160  int &subId,
161  double pcoords[3],
162  double &dist2);
164 
166 
170  virtual void EvaluateLocation(int subId,
171  double pcoords[3],
172  double x[3]);
174 
176 
182  virtual void InterpolateTuple(vtkGenericAttribute *a, double pcoords[3],
183  double *val);
185 
187 
193  virtual void InterpolateTuple(vtkGenericAttributeCollection *c, double pcoords[3],
194  double *val);
195 #if 0
196 
197 
198 
218  virtual void Contour(vtkContourValues *values,
220  vtkGenericAttributeCollection *attributes,
221  vtkPointLocator *locator,
222  vtkCellArray *verts,
223  vtkCellArray *lines,
224  vtkCellArray *polys,
225  vtkPointData *outPd,
226  vtkCellData *outCd);
227 #endif
228 #if 0
229 
230 
231 
257  virtual void Clip(double value,
259  vtkGenericAttributeCollection *attributes,
261  int insideOut,
262  vtkPointLocator *locator,
263  vtkCellArray *connectivity,
264  vtkPointData *outPd,
265  vtkCellData *outCd);
266 #endif
267 
268 
269 
275  virtual int IntersectWithLine(double p1[3],
276  double p2[3],
277  double tol,
278  double &t,
279  double x[3],
280  double pcoords[3],
281  int &subId);
283 
285 
294  virtual void Derivatives(int subId,
295  double pcoords[3],
296  vtkGenericAttribute *attribute,
297  double *derivs);
299 
302  virtual void GetBounds(double bounds[6]);
303 
307  virtual double *GetBounds();
308 
311  virtual double GetLength2();
312 
317  virtual int GetParametricCenter(double pcoords[3]);
318 
324  virtual double GetParametricDistance(double pcoords[3]);
325 
327 
335  virtual double *GetParametricCoords();
336 #if 0
337 
338 
339 
348  virtual void Tessellate(vtkGenericAttributeCollection *attributes,
349  vtkPoints *points, vtkCellArray* cellArray,
350  vtkPointData *pd, vtkCellData* cd);
351 #endif
352  // For the internals of the tesselation algorithm (the hash table in particular)
353  virtual int IsFaceOnBoundary(vtkIdType faceId);
354  virtual int IsOnBoundary();
356 
358 
360  virtual void GetPointIds(vtkIdType *id);
361 #if 0
362  virtual void TriangulateFace(vtkGenericAttributeCollection *attributes,
364  int index,
365  vtkPoints *pts, vtkCellArray *cellArray,
366  vtkPointData *pd,
367  vtkCellData *cd );
368 #endif
369 
370 
375  int *GetFaceArray(int faceId);
376 
381  int GetNumberOfVerticesOnFace(int faceId);
382 
387  int *GetEdgeArray(int edgeId);
388 
390 
394  vtkIdType cellid);
396 
398 
401  vtkIdType id);
403 
406  void DeepCopy(vtkBridgeCell *other);
407 
408 protected:
410  virtual ~vtkBridgeCell();
411 
415 
417  void InterpolationFunctions(double pcoords[3], double *weights);
418 
419  friend class vtkBridgeDataSet;
420  friend class vtkBridgeAttribute;
421  friend class vtkBridgeCellIterator;
426 
429  vtkIdType Id; // what does it mean for boundary cells?
432 
433  double *Weights; // interpolation functions
435 
436 private:
437  vtkBridgeCell(const vtkBridgeCell&); // Not implemented.
438  void operator=(const vtkBridgeCell&); // Not implemented.
439 };
440 
441 #endif
vtkPoints
represent and manipulate 3D points
Definition: vtkPoints.h:39
vtkGenericPointIterator
iterator used to traverse points
Definition: vtkGenericPointIterator.h:42
VTKTESTINGGENERICBRIDGE_EXPORT
#define VTKTESTINGGENERICBRIDGE_EXPORT
Definition: vtkTestingGenericBridgeModule.h:15
vtkBridgeCell::GetParametricCenter
virtual int GetParametricCenter(double pcoords[3])
vtkBridgeCell::GetParametricDistance
virtual double GetParametricDistance(double pcoords[3])
vtkBridgeCell::GetNeighbors
virtual void GetNeighbors(vtkGenericAdaptorCell *boundary, vtkGenericCellIterator *neighbors)
vtkBridgeCell::GetLength2
virtual double GetLength2()
vtkgl::weights
const GLbyte * weights
Definition: vtkgl.h:12766
vtkBridgeCell::InterpolationFunctions
void InterpolationFunctions(double pcoords[3], double *weights)
vtkBridgeCell::GetNumberOfBoundaries
virtual int GetNumberOfBoundaries(int dim=-1)
vtkBridgeCell::Derivatives
virtual void Derivatives(int subId, double pcoords[3], vtkGenericAttribute *attribute, double *derivs)
vtkGenericAdaptorCell::Tessellate
virtual void Tessellate(vtkGenericAttributeCollection *attributes, vtkGenericCellTessellator *tess, vtkPoints *points, vtkIncrementalPointLocator *locator, vtkCellArray *cellArray, vtkPointData *internalPd, vtkPointData *pd, vtkCellData *cd, vtkUnsignedCharArray *types)
vtkPointData
represent and manipulate point attribute data
Definition: vtkPointData.h:37
vtkGenericAdaptorCell.h
vtkBridgeCell::EvaluateLocation
virtual void EvaluateLocation(int subId, double pcoords[3], double x[3])
vtkIdType
int vtkIdType
Definition: vtkType.h:275
vtkBridgeCell::GetParametricCoords
virtual double * GetParametricCoords()
vtkPointLocator
quickly locate points in 3-space
Definition: vtkPointLocator.h:53
vtkBridgeCell::CountNeighbors
virtual int CountNeighbors(vtkGenericAdaptorCell *boundary)
vtkTypeMacro
#define vtkTypeMacro(thisClass, superclass)
Definition: vtkSetGet.h:642
vtkBridgeCell::Init
void Init(vtkBridgeDataSet *ds, vtkIdType cellid)
vtkBridgeCell::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent)
vtkBridgeCell::GetNumberOfDOFNodes
virtual int GetNumberOfDOFNodes()
vtkGenericAdaptorCell
defines cell interface
Definition: vtkGenericAdaptorCell.h:95
vtkgl::x
GLint GLint GLint GLint GLint x
Definition: vtkgl.h:11318
vtkBridgePointIteratorOnCell
Implementation of vtkGenericPointIterator.
Definition: vtkBridgePointIteratorOnCell.h:37
vtkBridgeCell::GetBounds
virtual double * GetBounds()
vtkGenericCellIterator
iterator used to traverse cells
Definition: vtkGenericCellIterator.h:44
vtkBridgeCell::BoolIsInDataSet
int BoolIsInDataSet
Definition: vtkBridgeCell.h:430
vtkBridgeCell::GetNumberOfVerticesOnFace
int GetNumberOfVerticesOnFace(int faceId)
vtkBridgeCell::GetNumberOfPoints
virtual int GetNumberOfPoints()
vtkBridgeCell::GetBounds
virtual void GetBounds(double bounds[6])
vtkgl::points
GLsizei const GLfloat * points
Definition: vtkgl.h:14786
vtkBridgeCell::GetDimension
virtual int GetDimension()
vtkGenericAdaptorCell::Contour
virtual void Contour(vtkContourValues *values, vtkImplicitFunction *f, vtkGenericAttributeCollection *attributes, vtkGenericCellTessellator *tess, vtkIncrementalPointLocator *locator, vtkCellArray *verts, vtkCellArray *lines, vtkCellArray *polys, vtkPointData *outPd, vtkCellData *outCd, vtkPointData *internalPd, vtkPointData *secondaryPd, vtkCellData *secondaryCd)
vtkgl::val
GLuint GLfloat * val
Definition: vtkgl.h:13789
vtkImplicitFunction
abstract interface for implicit functions
Definition: vtkImplicitFunction.h:58
vtkBridgeCell::~vtkBridgeCell
virtual ~vtkBridgeCell()
vtkBridgeCellIteratorOnCellBoundaries
Iterate over boundary cells of a cell.
Definition: vtkBridgeCellIteratorOnCellBoundaries.h:37
vtkBridgeCell::AllocateWeights
void AllocateWeights()
vtkGenericCellTessellator
helper class to perform cell tessellation
Definition: vtkGenericCellTessellator.h:58
vtkBridgeCell::vtkBridgeCell
vtkBridgeCell()
vtkBridgeCell::WeightsCapacity
int WeightsCapacity
Definition: vtkBridgeCell.h:434
vtkgl::value
GLsizei const GLfloat * value
Definition: vtkgl.h:12021
vtkBridgeCell::GetBoundaryIterator
virtual void GetBoundaryIterator(vtkGenericCellIterator *boundaries, int dim=-1)
vtkBridgeCell::InterpolateTuple
virtual void InterpolateTuple(vtkGenericAttributeCollection *c, double pcoords[3], double *val)
vtkgl::c
const GLubyte * c
Definition: vtkgl.h:15720
vtkBridgeCell::Weights
double * Weights
Definition: vtkBridgeCell.h:433
vtkgl::values
GLboolean GLenum GLenum GLvoid * values
Definition: vtkgl.h:11354
vtkBridgeCell::InterpolateTuple
virtual void InterpolateTuple(vtkGenericAttribute *a, double pcoords[3], double *val)
vtkBridgeExport.h
vtkCell
abstract class to specify cell behavior
Definition: vtkCell.h:62
vtkGenericAdaptorCell::Clip
virtual void Clip(double value, vtkImplicitFunction *f, vtkGenericAttributeCollection *attributes, vtkGenericCellTessellator *tess, int insideOut, vtkIncrementalPointLocator *locator, vtkCellArray *connectivity, vtkPointData *outPd, vtkCellData *outCd, vtkPointData *internalPd, vtkPointData *secondaryPd, vtkCellData *secondaryCd)
vtkContourValues
helper object to manage setting and generating contour values
Definition: vtkContourValues.h:35
vtkCellData
represent and manipulate cell attribute data
Definition: vtkCellData.h:38
vtkBridgeCell::CountEdgeNeighbors
void CountEdgeNeighbors(int *sharing)
vtkBridgeCell::IsFaceOnBoundary
virtual int IsFaceOnBoundary(vtkIdType faceId)
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:39
vtkCellArray
object to represent cell connectivity
Definition: vtkCellArray.h:50
vtkBridgeCell::DataSet
vtkBridgeDataSet * DataSet
Definition: vtkBridgeCell.h:428
vtkBridgeCell::IsPrimary
virtual int IsPrimary()
vtkgl::f
GLclampf f
Definition: vtkgl.h:14181
vtkBridgeCell
Implementation of vtkGenericAdaptorCell.
Definition: vtkBridgeCell.h:38
vtkgl::a
GLboolean GLboolean GLboolean GLboolean a
Definition: vtkgl.h:12312
vtkBridgeCell::GetPointIterator
virtual void GetPointIterator(vtkGenericPointIterator *it)
vtkBridgeCell::IsInDataSet
virtual int IsInDataSet()
vtkBridgeCell::GetEdgeArray
int * GetEdgeArray(int edgeId)
vtkBridgeCell::GetFaceArray
int * GetFaceArray(int faceId)
vtkBridgeAttribute
Implementation of vtkGenericAttribute.
Definition: vtkBridgeAttribute.h:38
vtkBridgeCell::InitWithCell
void InitWithCell(vtkCell *c, vtkIdType id)
vtkBridgeCell::DeepCopy
void DeepCopy(vtkBridgeCell *other)
vtkBridgeCell::IntersectWithLine
virtual int IntersectWithLine(double p1[3], double p2[3], double tol, double &t, double x[3], double pcoords[3], int &subId)
vtkgl::index
GLuint index
Definition: vtkgl.h:11983
vtkBridgeCell::GetId
virtual vtkIdType GetId()
vtkgl::t
GLdouble GLdouble t
Definition: vtkgl.h:11602
vtkBridgeCell::Cell
vtkCell * Cell
Definition: vtkBridgeCell.h:427
vtkBridgeCellIteratorOne
Iterate over one cell only of a dataset.
Definition: vtkBridgeCellIteratorOne.h:37
vtkBridgeDataSet
Implementation of vtkGenericDataSet.
Definition: vtkBridgeDataSet.h:34
vtkBridgeCellIterator
Implementation of vtkGenericCellIterator. It is just an example that show how to implement the Generi...
Definition: vtkBridgeCellIterator.h:46
vtkBridgeCell::EvaluatePosition
virtual int EvaluatePosition(double x[3], double *closestPoint, int &subId, double pcoords[3], double &dist2)
vtkBridgeCell::IsOnBoundary
virtual int IsOnBoundary()
vtkGenericAttributeCollection
a collection of attributes
Definition: vtkGenericAttributeCollection.h:36
vtkGenericAttribute
abstract class defined API for attribute data
Definition: vtkGenericAttribute.h:50
vtkBridgeCell::NewCellIterator
virtual vtkGenericCellIterator * NewCellIterator()
vtkBridgeCell::IsGeometryLinear
int IsGeometryLinear()
vtkBridgeCellIteratorOnDataSet
Iterate over cells of a dataset.
Definition: vtkBridgeCellIteratorOnDataSet.h:35
vtkBridgeCell::InternalIterator
vtkBridgeCellIterator * InternalIterator
Definition: vtkBridgeCell.h:431
vtkBridgeCell::GetPointIds
virtual void GetPointIds(vtkIdType *id)
vtkBridgeCell::FindClosestBoundary
virtual int FindClosestBoundary(int subId, double pcoords[3], vtkGenericCellIterator *&boundary)
vtkBridgeCell::GetAttributeOrder
virtual int GetAttributeOrder(vtkGenericAttribute *a)
vtkBridgeCell::GetType
virtual int GetType()
vtkBridgeCell::IsAttributeLinear
int IsAttributeLinear(vtkGenericAttribute *a)
vtkBridgeCell::Id
vtkIdType Id
Definition: vtkBridgeCell.h:429
vtkBridgeCell::New
static vtkBridgeCell * New()
vtkBridgeCell::GetGeometryOrder
virtual int GetGeometryOrder()
vtkGenericAdaptorCell::TriangulateFace
virtual void TriangulateFace(vtkGenericAttributeCollection *attributes, vtkGenericCellTessellator *tess, int index, vtkPoints *points, vtkIncrementalPointLocator *locator, vtkCellArray *cellArray, vtkPointData *internalPd, vtkPointData *pd, vtkCellData *cd)