VTK  9.3.1
vtkImageEllipsoidSource.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
15 #ifndef vtkImageEllipsoidSource_h
16 #define vtkImageEllipsoidSource_h
17 
18 #include "vtkImageAlgorithm.h"
19 #include "vtkImagingSourcesModule.h" // For export macro
20 
21 VTK_ABI_NAMESPACE_BEGIN
22 class VTKIMAGINGSOURCES_EXPORT vtkImageEllipsoidSource : public vtkImageAlgorithm
23 {
24 public:
25  static vtkImageEllipsoidSource* New();
27  void PrintSelf(ostream& os, vtkIndent indent) override;
28 
30 
33  void SetWholeExtent(int extent[6]);
34  void SetWholeExtent(int minX, int maxX, int minY, int maxY, int minZ, int maxZ);
35  void GetWholeExtent(int extent[6]);
36  int* GetWholeExtent() VTK_SIZEHINT(6) { return this->WholeExtent; }
38 
40 
43  vtkSetVector3Macro(Center, double);
44  vtkGetVector3Macro(Center, double);
46 
48 
51  vtkSetVector3Macro(Radius, double);
52  vtkGetVector3Macro(Radius, double);
54 
56 
59  vtkSetMacro(InValue, double);
60  vtkGetMacro(InValue, double);
62 
64 
67  vtkSetMacro(OutValue, double);
68  vtkGetMacro(OutValue, double);
70 
72 
75  vtkSetMacro(OutputScalarType, int);
76  vtkGetMacro(OutputScalarType, int);
77  void SetOutputScalarTypeToFloat() { this->SetOutputScalarType(VTK_FLOAT); }
78  void SetOutputScalarTypeToDouble() { this->SetOutputScalarType(VTK_DOUBLE); }
79  void SetOutputScalarTypeToLong() { this->SetOutputScalarType(VTK_LONG); }
80  void SetOutputScalarTypeToUnsignedLong() { this->SetOutputScalarType(VTK_UNSIGNED_LONG); }
81  void SetOutputScalarTypeToInt() { this->SetOutputScalarType(VTK_INT); }
82  void SetOutputScalarTypeToUnsignedInt() { this->SetOutputScalarType(VTK_UNSIGNED_INT); }
83  void SetOutputScalarTypeToShort() { this->SetOutputScalarType(VTK_SHORT); }
84  void SetOutputScalarTypeToUnsignedShort() { this->SetOutputScalarType(VTK_UNSIGNED_SHORT); }
85  void SetOutputScalarTypeToChar() { this->SetOutputScalarType(VTK_CHAR); }
86  void SetOutputScalarTypeToUnsignedChar() { this->SetOutputScalarType(VTK_UNSIGNED_CHAR); }
88 
89 protected:
91  ~vtkImageEllipsoidSource() override;
92 
93  int WholeExtent[6];
94  double Center[3];
95  double Radius[3];
96  double InValue;
97  double OutValue;
99 
101 
103 
104 private:
106  void operator=(const vtkImageEllipsoidSource&) = delete;
107 };
108 
109 VTK_ABI_NAMESPACE_END
110 #endif
#define VTK_UNSIGNED_INT
Definition: vtkType.h:39
Store vtkAlgorithm input/output information.
void SetOutputScalarTypeToLong()
Set what type of scalar data this source should generate.
int * GetWholeExtent()
Set/Get the extent of the whole output image.
#define VTK_UNSIGNED_SHORT
Definition: vtkType.h:37
Create a binary image of an ellipsoid.
void SetOutputScalarTypeToInt()
Set what type of scalar data this source should generate.
void SetOutputScalarTypeToUnsignedLong()
Set what type of scalar data this source should generate.
void SetOutputScalarTypeToFloat()
Set what type of scalar data this source should generate.
void SetOutputScalarTypeToUnsignedChar()
Set what type of scalar data this source should generate.
#define VTK_DOUBLE
Definition: vtkType.h:43
#define VTK_FLOAT
Definition: vtkType.h:42
a simple class to control print indentation
Definition: vtkIndent.h:28
void SetOutputScalarTypeToChar()
Set what type of scalar data this source should generate.
void SetOutputScalarTypeToDouble()
Set what type of scalar data this source should generate.
virtual int RequestInformation(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
Subclasses can reimplement this method to collect information from their inputs and set information f...
#define VTK_SHORT
Definition: vtkType.h:36
#define VTK_CHAR
Definition: vtkType.h:33
#define VTK_LONG
Definition: vtkType.h:40
#define VTK_SIZEHINT(...)
void SetOutputScalarTypeToUnsignedShort()
Set what type of scalar data this source should generate.
void SetOutputScalarTypeToUnsignedInt()
Set what type of scalar data this source should generate.
#define VTK_UNSIGNED_CHAR
Definition: vtkType.h:35
Generic algorithm superclass for image algs.
Store zero or more vtkInformation instances.
static vtkAlgorithm * New()
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
#define VTK_UNSIGNED_LONG
Definition: vtkType.h:41
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
This is called in response to a REQUEST_DATA request from the executive.
#define VTK_INT
Definition: vtkType.h:38
void SetOutputScalarTypeToShort()
Set what type of scalar data this source should generate.