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
33#ifndef vtkConeSource_h
34#define vtkConeSource_h
35
36#include "vtkFiltersSourcesModule.h" // For export macro
38
39#include "vtkCell.h" // Needed for VTK_CELL_SIZE
40
41VTK_ABI_NAMESPACE_BEGIN
42class VTKFILTERSSOURCES_EXPORT vtkConeSource : public vtkPolyDataAlgorithm
43{
44public:
46 void PrintSelf(ostream& os, vtkIndent indent) override;
47
53 static vtkConeSource* New();
54
56
60 vtkSetClampMacro(Height, double, 0.0, VTK_DOUBLE_MAX);
61 vtkGetMacro(Height, double);
63
65
68 vtkSetClampMacro(Radius, double, 0.0, VTK_DOUBLE_MAX);
69 vtkGetMacro(Radius, double);
71
73
76 vtkSetClampMacro(Resolution, int, 0, VTK_CELL_SIZE);
77 vtkGetMacro(Resolution, int);
79
81
86 vtkSetVector3Macro(Center, double);
87 vtkGetVectorMacro(Center, double, 3);
89
91
96 vtkSetVector3Macro(Direction, double);
97 vtkGetVectorMacro(Direction, double, 3);
99
101
108 void SetAngle(double angle);
109 double GetAngle();
111
113
116 vtkSetMacro(Capping, vtkTypeBool);
117 vtkGetMacro(Capping, vtkTypeBool);
118 vtkBooleanMacro(Capping, vtkTypeBool);
120
122
127 vtkSetMacro(OutputPointsPrecision, int);
128 vtkGetMacro(OutputPointsPrecision, int);
130
131protected:
132 vtkConeSource(int res = 6);
133 ~vtkConeSource() override = default;
134
137
138 double Height;
139 double Radius;
142 double Center[3];
143 double Direction[3];
145
146private:
147 vtkConeSource(const vtkConeSource&) = delete;
148 void operator=(const vtkConeSource&) = delete;
149};
150
151VTK_ABI_NAMESPACE_END
152#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:38
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:40
#define VTK_DOUBLE_MAX
Definition vtkType.h:154