Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023 #ifndef VTKVIEWER_GEOMETRYFILTER_H
00024 #define VTKVIEWER_GEOMETRYFILTER_H
00025
00026 #include "VTKViewer.h"
00027
00028 #include <vtkGeometryFilter.h>
00029
00030 #include <vector>
00031
00032 #ifdef WIN32
00033 #pragma warning ( disable:4251 )
00034 #endif
00035
00036 class vtkUnstructuredGrid;
00037
00040 class VTKVIEWER_EXPORT VTKViewer_GeometryFilter : public vtkGeometryFilter
00041 {
00042 public:
00045 static VTKViewer_GeometryFilter *New();
00046
00050 vtkTypeRevisionMacro(VTKViewer_GeometryFilter, vtkGeometryFilter);
00055 void SetInside(int theShowInside);
00060 int GetInside();
00065 void SetWireframeMode(int theIsWireframeMode);
00070 int GetWireframeMode();
00075 void SetStoreMapping(int theStoreMapping);
00080 int GetStoreMapping();
00085 virtual vtkIdType GetNodeObjId(int theVtkID) { return theVtkID;}
00090 virtual vtkIdType GetElemObjId(int theVtkID);
00091
00092 virtual void SetQuadraticArcMode(bool theFlag);
00093 virtual bool GetQuadraticArcMode() const;
00094
00095 virtual void SetQuadraticArcAngle(vtkFloatingPointType theMaxAngle);
00096 virtual vtkFloatingPointType GetQuadraticArcAngle() const;
00097
00098
00099 protected:
00103 VTKViewer_GeometryFilter();
00107 ~VTKViewer_GeometryFilter();
00108
00109 virtual int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *);
00110
00111
00112
00116 int UnstructuredGridExecute (vtkDataSet *, vtkPolyData *, vtkInformation *);
00117
00118
00119 void BuildArcedPolygon(vtkIdType cellId, vtkUnstructuredGrid* input, vtkPolyData *output, bool triangulate = false);
00120
00121 private:
00122 typedef std::vector<vtkIdType> TVectorId;
00123
00124 private:
00125 TVectorId myVTK2ObjIds;
00126 int myShowInside;
00127 int myStoreMapping;
00128 int myIsWireframeMode;
00129
00130 vtkFloatingPointType myMaxArcAngle;
00131 bool myIsBuildArc;
00132 };
00133
00134 #ifdef WIN32
00135 #pragma warning ( default:4251 )
00136 #endif
00137
00138 #endif