VTK  9.3.0
vtkConeSource.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
24#ifndef vtkConeSource_h
25#define vtkConeSource_h
26
27#include "vtkFiltersSourcesModule.h" // For export macro
29
30#include "vtkCell.h" // Needed for VTK_CELL_SIZE
31
32VTK_ABI_NAMESPACE_BEGIN
33class VTKFILTERSSOURCES_EXPORT vtkConeSource : public vtkPolyDataAlgorithm
34{
35public:
37 void PrintSelf(ostream& os, vtkIndent indent) override;
38
44 static vtkConeSource* New();
45
47
51 vtkSetClampMacro(Height, double, 0.0, VTK_DOUBLE_MAX);
52 vtkGetMacro(Height, double);
54
56
59 vtkSetClampMacro(Radius, double, 0.0, VTK_DOUBLE_MAX);
60 vtkGetMacro(Radius, double);
62
64
67 vtkSetClampMacro(Resolution, int, 0, VTK_CELL_SIZE);
68 vtkGetMacro(Resolution, int);
70
72
77 vtkSetVector3Macro(Center, double);
78 vtkGetVectorMacro(Center, double, 3);
80
82
87 vtkSetVector3Macro(Direction, double);
88 vtkGetVectorMacro(Direction, double, 3);
90
92
99 void SetAngle(double angle);
100 double GetAngle();
102
104
107 vtkSetMacro(Capping, vtkTypeBool);
108 vtkGetMacro(Capping, vtkTypeBool);
109 vtkBooleanMacro(Capping, vtkTypeBool);
111
113
118 vtkSetMacro(OutputPointsPrecision, int);
119 vtkGetMacro(OutputPointsPrecision, int);
121
122protected:
123 vtkConeSource(int res = 6);
124 ~vtkConeSource() override = default;
125
128
129 double Height;
130 double Radius;
133 double Center[3];
134 double Direction[3];
136
137private:
138 vtkConeSource(const vtkConeSource&) = delete;
139 void operator=(const vtkConeSource&) = delete;
140};
141
142VTK_ABI_NAMESPACE_END
143#endif
generate polygonal cone
vtkTypeBool Capping
static vtkConeSource * New()
Construct with default resolution 6, height 1.0, radius 0.5, and capping on.
~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 RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
a simple class to control print indentation
Definition vtkIndent.h:29
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:64
#define VTK_CELL_SIZE
Definition vtkCell.h:31
#define VTK_DOUBLE_MAX
Definition vtkType.h:154