VTK  9.6.1
vtkCubeSource.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
17
18#ifndef vtkCubeSource_h
19#define vtkCubeSource_h
20
21#include "vtkFiltersSourcesModule.h" // For export macro
23#include "vtkWrappingHints.h" // For VTK_MARSHALAUTO
24
25VTK_ABI_NAMESPACE_BEGIN
26class VTKFILTERSSOURCES_EXPORT VTK_MARSHALAUTO vtkCubeSource : public vtkPolyDataAlgorithm
27{
28public:
29 static vtkCubeSource* New();
31 void PrintSelf(ostream& os, vtkIndent indent) override;
32
34
37 vtkSetClampMacro(XLength, double, 0.0, VTK_DOUBLE_MAX);
38 vtkGetMacro(XLength, double);
40
42
45 vtkSetClampMacro(YLength, double, 0.0, VTK_DOUBLE_MAX);
46 vtkGetMacro(YLength, double);
48
50
53 vtkSetClampMacro(ZLength, double, 0.0, VTK_DOUBLE_MAX);
54 vtkGetMacro(ZLength, double);
56
58
61 vtkSetVector3Macro(Center, double);
62 vtkGetVectorMacro(Center, double, 3);
64
66
69 void SetBounds(double xMin, double xMax, double yMin, double yMax, double zMin, double zMax);
70 void SetBounds(const double bounds[6]);
71 void GetBounds(double bounds[6]);
73
75
80 vtkSetMacro(OutputPointsPrecision, int);
81 vtkGetMacro(OutputPointsPrecision, int);
83
84protected:
85 vtkCubeSource(double xL = 1.0, double yL = 1.0, double zL = 1.0);
86 ~vtkCubeSource() override = default;
87
89 double XLength;
90 double YLength;
91 double ZLength;
92 double Center[3];
94
95private:
96 vtkCubeSource(const vtkCubeSource&) = delete;
97 void operator=(const vtkCubeSource&) = delete;
98};
99
100VTK_ABI_NAMESPACE_END
101#endif
~vtkCubeSource() override=default
void GetBounds(double bounds[6])
Convenience methods allows creation of cube by specifying bounding box.
static vtkCubeSource * New()
int OutputPointsPrecision
vtkCubeSource(double xL=1.0, double yL=1.0, double zL=1.0)
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
void SetBounds(const double bounds[6])
Convenience methods allows creation of cube by specifying bounding box.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
double Center[3]
void SetBounds(double xMin, double xMax, double yMin, double yMax, double zMin, double zMax)
Convenience methods allows creation of cube by specifying bounding box.
a simple class to control print indentation
Definition vtkIndent.h:29
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
#define VTK_DOUBLE_MAX
Definition vtkType.h:207
#define VTK_MARSHALAUTO