Main Page | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members | Related Pages

vtkQuad.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    $RCSfile: vtkQuad.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 =========================================================================*/
00030 #ifndef __vtkQuad_h
00031 #define __vtkQuad_h
00032 
00033 #include "vtkCell.h"
00034 
00035 class vtkLine;
00036 class vtkTriangle;
00037 
00038 class VTK_FILTERING_EXPORT vtkQuad : public vtkCell
00039 {
00040 public:
00041   static vtkQuad *New();
00042   vtkTypeRevisionMacro(vtkQuad,vtkCell);
00043   void PrintSelf(ostream& os, vtkIndent indent);
00044 
00046 
00047   int GetCellType() {return VTK_QUAD;};
00048   int GetCellDimension() {return 2;};
00049   int GetNumberOfEdges() {return 4;};
00050   int GetNumberOfFaces() {return 0;};
00051   vtkCell *GetEdge(int edgeId);
00052   vtkCell *GetFace(int) {return 0;};
00053   int CellBoundary(int subId, double pcoords[3], vtkIdList *pts);
00054   void Contour(double value, vtkDataArray *cellScalars, 
00055                vtkPointLocator *locator, vtkCellArray *verts, 
00056                vtkCellArray *lines, vtkCellArray *polys,
00057                vtkPointData *inPd, vtkPointData *outPd,
00058                vtkCellData *inCd, vtkIdType cellId, vtkCellData *outCd);
00059   int EvaluatePosition(double x[3], double* closestPoint,
00060                        int& subId, double pcoords[3],
00061                        double& dist2, double *weights);
00062   void EvaluateLocation(int& subId, double pcoords[3], double x[3],
00063                         double *weights);
00064   int IntersectWithLine(double p1[3], double p2[3], double tol, double& t,
00065                         double x[3], double pcoords[3], int& subId);
00066   int Triangulate(int index, vtkIdList *ptIds, vtkPoints *pts);
00067   void Derivatives(int subId, double pcoords[3], double *values, 
00068                    int dim, double *derivs);
00069   virtual double *GetParametricCoords();
00071 
00073   int GetParametricCenter(double pcoords[3]);
00074 
00076 
00078   void Clip(double value, vtkDataArray *cellScalars, 
00079             vtkPointLocator *locator, vtkCellArray *polys,
00080             vtkPointData *inPd, vtkPointData *outPd,
00081             vtkCellData *inCd, vtkIdType cellId, vtkCellData *outCd,
00082             int insideOut);
00084 
00086 
00087   static void InterpolationFunctions(double pcoords[3], double sf[4]);
00088   static void InterpolationDerivs(double pcoords[3], double derivs[8]);
00090 
00091 protected:
00092   vtkQuad();
00093   ~vtkQuad();
00094 
00095   vtkLine     *Line;
00096   vtkTriangle *Triangle;
00097 
00098 private:
00099   vtkQuad(const vtkQuad&);  // Not implemented.
00100   void operator=(const vtkQuad&);  // Not implemented.
00101 };
00102 //----------------------------------------------------------------------------
00103 inline int vtkQuad::GetParametricCenter(double pcoords[3])
00104 {
00105   pcoords[0] = pcoords[1] = 0.5;
00106   pcoords[2] = 0.0;
00107   return 0;
00108 }
00109 
00110 
00111 #endif
00112 
00113 

Generated on Mon Jan 21 23:07:20 2008 for VTK by  doxygen 1.4.3-20050530