VTK  9.2.6
vtkCylinderSource.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkCylinderSource.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 =========================================================================*/
37 #ifndef vtkCylinderSource_h
38 #define vtkCylinderSource_h
39 
40 #include "vtkFiltersSourcesModule.h" // For export macro
41 #include "vtkPolyDataAlgorithm.h"
42 
43 #include "vtkCell.h" // Needed for VTK_CELL_SIZE
44 
45 class VTKFILTERSSOURCES_EXPORT vtkCylinderSource : public vtkPolyDataAlgorithm
46 {
47 public:
48  static vtkCylinderSource* New();
50  void PrintSelf(ostream& os, vtkIndent indent) override;
51 
53 
56  vtkSetClampMacro(Height, double, 0.0, VTK_DOUBLE_MAX);
57  vtkGetMacro(Height, double);
59 
61 
64  vtkSetClampMacro(Radius, double, 0.0, VTK_DOUBLE_MAX);
65  vtkGetMacro(Radius, double);
67 
69 
72  vtkSetVector3Macro(Center, double);
73  vtkGetVectorMacro(Center, double, 3);
75 
77 
80  vtkSetClampMacro(Resolution, int, 3, VTK_CELL_SIZE);
81  vtkGetMacro(Resolution, int);
83 
85 
88  vtkSetMacro(Capping, vtkTypeBool);
89  vtkGetMacro(Capping, vtkTypeBool);
90  vtkBooleanMacro(Capping, vtkTypeBool);
92 
94 
99  vtkSetMacro(OutputPointsPrecision, int);
100  vtkGetMacro(OutputPointsPrecision, int);
102 
103 protected:
104  vtkCylinderSource(int res = 6);
105  ~vtkCylinderSource() override = default;
106 
108  double Height;
109  double Radius;
110  double Center[3];
114 
115 private:
116  vtkCylinderSource(const vtkCylinderSource&) = delete;
117  void operator=(const vtkCylinderSource&) = delete;
118 };
119 
120 #endif
generate a polygonal cylinder centered at the origin
#define VTK_DOUBLE_MAX
Definition: vtkType.h:165
Store vtkAlgorithm input/output information.
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
This is called by the superclass.
#define VTK_CELL_SIZE
Definition: vtkCell.h:43
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:39
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.