00001 
00002 
00003 
00004 
00005 
00006 
00007 
00008 
00009 
00010 
00011 
00012 
00013 
00014 
00015 
00016 
00017 
00018 
00019 
00020 
00021 
00022 
00023 
00024 
00025 
00026 
00027 
00028 
00029 
00030 
00031 
00032 
00033 
00034 
00035 
00036 
00037 
00038 
00039 
00056 #ifndef __vtkPolyLine_h
00057 #define __vtkPolyLine_h
00058 
00059 #include "vtkCell.h"
00060 #include "vtkPoints.h"
00061 #include "vtkCellArray.h"
00062 #include "vtkLine.h"
00063 
00064 class VTK_COMMON_EXPORT vtkPolyLine : public vtkCell
00065 {
00066 public:
00067   static vtkPolyLine *New();
00068   vtkTypeMacro(vtkPolyLine,vtkCell);
00069 
00075   int GenerateSlidingNormals(vtkPoints *, vtkCellArray *, vtkDataArray *);
00076 
00078 
00079   vtkCell *MakeObject();
00080   int GetCellType() {return VTK_POLY_LINE;};
00081   int GetCellDimension() {return 1;};
00082   int GetNumberOfEdges() {return 0;};
00083   int GetNumberOfFaces() {return 0;};
00084   vtkCell *GetEdge(int vtkNotUsed(edgeId)) {return 0;};
00085   vtkCell *GetFace(int vtkNotUsed(faceId)) {return 0;};
00086   int CellBoundary(int subId, float pcoords[3], vtkIdList *pts);
00087   void Contour(float value, vtkDataArray *cellScalars, 
00088                vtkPointLocator *locator, vtkCellArray *verts, 
00089                vtkCellArray *lines, vtkCellArray *polys, 
00090                vtkPointData *inPd, vtkPointData *outPd,
00091                vtkCellData *inCd, vtkIdType cellId, vtkCellData *outCd);
00092   void Clip(float value, vtkDataArray *cellScalars, 
00093             vtkPointLocator *locator, vtkCellArray *lines,
00094             vtkPointData *inPd, vtkPointData *outPd,
00095             vtkCellData *inCd, vtkIdType cellId, vtkCellData *outCd,
00096             int insideOut);
00097   int EvaluatePosition(float x[3], float* closestPoint,
00098                        int& subId, float pcoords[3],
00099                        float& dist2, float *weights);
00100   void EvaluateLocation(int& subId, float pcoords[3], float x[3],
00101                         float *weights);
00102   int IntersectWithLine(float p1[3], float p2[3], float tol, float& t,
00103                         float x[3], float pcoords[3], int& subId);
00104   int Triangulate(int index, vtkIdList *ptIds, vtkPoints *pts);
00105   void Derivatives(int subId, float pcoords[3], float *values, 
00106                    int dim, float *derivs);
00108 
00110   int GetParametricCenter(float pcoords[3]);
00111 
00112   
00113 protected:
00114   vtkPolyLine();
00115   ~vtkPolyLine();
00116 
00117   vtkLine *Line;
00118 
00119 private:
00120   vtkPolyLine(const vtkPolyLine&);  
00121   void operator=(const vtkPolyLine&);  
00122 };
00123 
00124 #endif
00125 
00126