VTK  9.7.1
vtkRegularPolygonSource.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-License-Identifier: BSD-3-Clause
21 #ifndef vtkRegularPolygonSource_h
22 #define vtkRegularPolygonSource_h
23 
24 #include "vtkFiltersSourcesModule.h" // For export macro
25 #include "vtkPolyDataAlgorithm.h"
26 #include "vtkWrappingHints.h" // For VTK_MARSHALAUTO
27 
28 VTK_ABI_NAMESPACE_BEGIN
29 class VTKFILTERSSOURCES_EXPORT VTK_MARSHALAUTO vtkRegularPolygonSource : public vtkPolyDataAlgorithm
30 {
31 public:
33 
36  static vtkRegularPolygonSource* New();
38  void PrintSelf(ostream& os, vtkIndent indent) override;
40 
42 
46  vtkSetClampMacro(NumberOfSides, int, 3, VTK_INT_MAX);
47  vtkGetMacro(NumberOfSides, int);
49 
51 
55  vtkSetVector3Macro(Center, double);
56  vtkGetVectorMacro(Center, double, 3);
58 
60 
65  vtkSetVector3Macro(Normal, double);
66  vtkGetVectorMacro(Normal, double, 3);
68 
70 
73  vtkSetMacro(Radius, double);
74  vtkGetMacro(Radius, double);
76 
78 
81  vtkSetMacro(GeneratePolygon, vtkTypeBool);
82  vtkGetMacro(GeneratePolygon, vtkTypeBool);
83  vtkBooleanMacro(GeneratePolygon, vtkTypeBool);
85 
87 
90  vtkSetMacro(GeneratePolyline, vtkTypeBool);
91  vtkGetMacro(GeneratePolyline, vtkTypeBool);
92  vtkBooleanMacro(GeneratePolyline, vtkTypeBool);
94 
96 
101  vtkSetMacro(OutputPointsPrecision, int);
102  vtkGetMacro(OutputPointsPrecision, int);
104 
105 protected:
107  ~vtkRegularPolygonSource() override = default;
108 
110 
112  double Center[3];
113  double Normal[3];
114  double Radius;
118 
119 private:
121  void operator=(const vtkRegularPolygonSource&) = delete;
122 };
123 
124 VTK_ABI_NAMESPACE_END
125 #endif
Store vtkAlgorithm input/output information.
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
This is called by the superclass.
#define VTK_INT_MAX
Definition: vtkType.h:192
static vtkPolyDataAlgorithm * New()
int vtkTypeBool
Definition: vtkABI.h:64
Superclass for algorithms that produce only polydata as output.
a simple class to control print indentation
Definition: vtkIndent.h:28
create a regular, n-sided polygon and/or polyline
Store zero or more vtkInformation instances.
#define VTK_MARSHALAUTO
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.