VTK  9.2.6
vtkConeSource.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkConeSource.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 =========================================================================*/
45 #ifndef vtkConeSource_h
46 #define vtkConeSource_h
47 
48 #include "vtkFiltersSourcesModule.h" // For export macro
49 #include "vtkPolyDataAlgorithm.h"
50 
51 #include "vtkCell.h" // Needed for VTK_CELL_SIZE
52 
53 class VTKFILTERSSOURCES_EXPORT vtkConeSource : public vtkPolyDataAlgorithm
54 {
55 public:
57  void PrintSelf(ostream& os, vtkIndent indent) override;
58 
64  static vtkConeSource* New();
65 
67 
71  vtkSetClampMacro(Height, double, 0.0, VTK_DOUBLE_MAX);
72  vtkGetMacro(Height, double);
74 
76 
79  vtkSetClampMacro(Radius, double, 0.0, VTK_DOUBLE_MAX);
80  vtkGetMacro(Radius, double);
82 
84 
87  vtkSetClampMacro(Resolution, int, 0, VTK_CELL_SIZE);
88  vtkGetMacro(Resolution, int);
90 
92 
97  vtkSetVector3Macro(Center, double);
98  vtkGetVectorMacro(Center, double, 3);
100 
102 
107  vtkSetVector3Macro(Direction, double);
108  vtkGetVectorMacro(Direction, double, 3);
110 
112 
119  void SetAngle(double angle);
120  double GetAngle();
122 
124 
127  vtkSetMacro(Capping, vtkTypeBool);
128  vtkGetMacro(Capping, vtkTypeBool);
129  vtkBooleanMacro(Capping, vtkTypeBool);
131 
133 
138  vtkSetMacro(OutputPointsPrecision, int);
139  vtkGetMacro(OutputPointsPrecision, int);
141 
142 protected:
143  vtkConeSource(int res = 6);
144  ~vtkConeSource() override = default;
145 
148 
149  double Height;
150  double Radius;
153  double Center[3];
154  double Direction[3];
156 
157 private:
158  vtkConeSource(const vtkConeSource&) = delete;
159  void operator=(const vtkConeSource&) = delete;
160 };
161 
162 #endif
generate polygonal cone
Definition: vtkConeSource.h:54
vtkTypeBool Capping
~vtkConeSource() override=default
int RequestInformation(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
vtkConeSource(int res=6)
void SetAngle(double angle)
Set the angle of the cone.
double GetAngle()
Set the angle of the cone.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
int OutputPointsPrecision
static vtkConeSource * New()
Construct with default resolution 6, height 1.0, radius 0.5, and capping on.
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
a simple class to control print indentation
Definition: vtkIndent.h:49
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
Superclass for algorithms that produce only polydata as output.
int vtkTypeBool
Definition: vtkABI.h:69
#define VTK_CELL_SIZE
Definition: vtkCell.h:52
#define VTK_DOUBLE_MAX
Definition: vtkType.h:165