VTK
vtkLinearExtrusionFilter.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkLinearExtrusionFilter.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 =========================================================================*/
51 #ifndef vtkLinearExtrusionFilter_h
52 #define vtkLinearExtrusionFilter_h
53 
54 #include "vtkFiltersModelingModule.h" // For export macro
55 #include "vtkPolyDataAlgorithm.h"
56 
57 class vtkDataArray;
58 
59 #define VTK_VECTOR_EXTRUSION 1
60 #define VTK_NORMAL_EXTRUSION 2
61 #define VTK_POINT_EXTRUSION 3
62 
63 class VTKFILTERSMODELING_EXPORT vtkLinearExtrusionFilter : public vtkPolyDataAlgorithm
64 {
65 public:
67  void PrintSelf(ostream& os, vtkIndent indent) override;
68 
73  static vtkLinearExtrusionFilter *New();
74 
76 
79  vtkSetClampMacro(ExtrusionType,int,VTK_VECTOR_EXTRUSION,VTK_POINT_EXTRUSION);
80  vtkGetMacro(ExtrusionType,int);
82  {this->SetExtrusionType(VTK_VECTOR_EXTRUSION);};
84  {this->SetExtrusionType(VTK_NORMAL_EXTRUSION);};
86  {this->SetExtrusionType(VTK_POINT_EXTRUSION);};
88 
90 
93  vtkSetMacro(Capping,vtkTypeBool);
94  vtkGetMacro(Capping,vtkTypeBool);
95  vtkBooleanMacro(Capping,vtkTypeBool);
97 
99 
102  vtkSetMacro(ScaleFactor,double);
103  vtkGetMacro(ScaleFactor,double);
105 
107 
111  vtkSetVector3Macro(Vector,double);
112  vtkGetVectorMacro(Vector,double,3);
114 
116 
120  vtkSetVector3Macro(ExtrusionPoint,double);
121  vtkGetVectorMacro(ExtrusionPoint,double,3);
123 
124 protected:
127 
131  double ScaleFactor;
132  double Vector[3];
133  double ExtrusionPoint[3];
134 
135  void (vtkLinearExtrusionFilter::*ExtrudePoint)(double x[3], vtkIdType id,
136  vtkDataArray *normals);
137  void ViaNormal(double x[3], vtkIdType id, vtkDataArray *normals);
138  void ViaVector(double x[3], vtkIdType id, vtkDataArray *normals=nullptr);
139  void ViaPoint(double x[3], vtkIdType id, vtkDataArray *normals=nullptr);
140 
141 private:
143  void operator=(const vtkLinearExtrusionFilter&) = delete;
144 };
145 
146 #endif
#define VTK_POINT_EXTRUSION
Store vtkAlgorithm input/output information.
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
This is called by the superclass.
int vtkIdType
Definition: vtkType.h:347
#define VTK_VECTOR_EXTRUSION
#define VTK_NORMAL_EXTRUSION
static vtkPolyDataAlgorithm * New()
int vtkTypeBool
Definition: vtkABI.h:69
Superclass for algorithms that produce only polydata as output.
a simple class to control print indentation
Definition: vtkIndent.h:33
abstract superclass for arrays of numeric data
Definition: vtkDataArray.h:48
void SetExtrusionTypeToVectorExtrusion()
Set/Get the type of extrusion.
void SetExtrusionTypeToPointExtrusion()
Set/Get the type of extrusion.
void SetExtrusionTypeToNormalExtrusion()
Set/Get the type of extrusion.
sweep polygonal data creating a "skirt" from free edges and lines, and lines from vertices
Store zero or more vtkInformation instances.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.