VTK  9.7.1
vtkImageAlgorithm.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
19 #ifndef vtkImageAlgorithm_h
20 #define vtkImageAlgorithm_h
21 
22 #include "vtkAlgorithm.h"
23 #include "vtkCommonExecutionModelModule.h" // For export macro
24 #include "vtkWrappingHints.h" // For VTK_MARSHALAUTO
25 
26 VTK_ABI_NAMESPACE_BEGIN
27 class vtkDataSet;
28 class vtkImageData;
29 
30 class VTKCOMMONEXECUTIONMODEL_EXPORT VTK_MARSHALAUTO vtkImageAlgorithm : public vtkAlgorithm
31 {
32 public:
34  void PrintSelf(ostream& os, vtkIndent indent) override;
35 
37 
41  vtkImageData* GetOutput();
43  vtkImageData* GetOutput(int);
45  virtual void SetOutput(vtkDataObject* d);
47 
53  vtkTypeBool ProcessRequest(
54  vtkInformation*, vtkInformationVector**, vtkInformationVector*) override;
55 
57 
62  void SetInputData(vtkDataObject*);
63  void SetInputData(int, vtkDataObject*);
65 
67 
72  vtkDataObject* GetInput(int port);
73  vtkDataObject* GetInput() { return this->GetInput(0); }
74  vtkImageData* GetImageDataInput(int port);
76 
78 
83  virtual void AddInputData(vtkDataObject*);
84  virtual void AddInputData(int, vtkDataObject*);
86 
87 protected:
89  ~vtkImageAlgorithm() override;
90 
95  virtual int RequestInformation(vtkInformation* request, vtkInformationVector** inputVector,
96  vtkInformationVector* outputVector);
97 
103  virtual int RequestUpdateExtent(vtkInformation*, vtkInformationVector**, vtkInformationVector*);
104 
105  virtual int RequestUpdateTime(vtkInformation*, vtkInformationVector**, vtkInformationVector*);
106 
114  virtual void CopyInputArrayAttributesToOutput(vtkInformation* request,
115  vtkInformationVector** inputVector, vtkInformationVector* outputVector);
116 
124  virtual int RequestData(vtkInformation* request, vtkInformationVector** inputVector,
125  vtkInformationVector* outputVector);
126 
131  virtual void ExecuteDataWithInformation(vtkDataObject* output, vtkInformation* outInfo);
132 
134 
138  virtual void ExecuteData(vtkDataObject* output);
139  virtual void Execute();
141 
143 
147  virtual void AllocateOutputData(
148  vtkImageData* out, vtkInformation* outInfo, VTK_FUTURE_CONST int uExtent[6]);
149  virtual vtkImageData* AllocateOutputData(vtkDataObject* out, vtkInformation* outInfo);
151 
156  virtual void CopyAttributeData(
157  vtkImageData* in, vtkImageData* out, vtkInformationVector** inputVector);
158 
160 
166  int FillInputPortInformation(int port, vtkInformation* info) override;
168 
169 private:
170  vtkImageAlgorithm(const vtkImageAlgorithm&) = delete;
171  void operator=(const vtkImageAlgorithm&) = delete;
172 };
173 
174 VTK_ABI_NAMESPACE_END
175 #endif
Store vtkAlgorithm input/output information.
abstract class to specify dataset behavior
Definition: vtkDataSet.h:56
vtkDataObject * GetInput()
Get a data object for one of the input port connections.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
int vtkTypeBool
Definition: vtkABI.h:64
Superclass for all sources, filters, and sinks in VTK.
Definition: vtkAlgorithm.h:53
virtual int FillOutputPortInformation(int port, vtkInformation *info)
Fill the output port information objects for this algorithm.
a simple class to control print indentation
Definition: vtkIndent.h:28
topologically and geometrically regular array of data
Definition: vtkImageData.h:45
virtual int FillInputPortInformation(int port, vtkInformation *info)
Fill the input port information objects for this algorithm.
#define vtkImageAlgorithm
#define VTK_MARSHALEXCLUDE(reason)
Generic algorithm superclass for image algs.
Store zero or more vtkInformation instances.
#define VTK_MARSHALAUTO
general representation of visualization data
Definition: vtkDataObject.h:55
#define VTK_MARSHAL_EXCLUDE_REASON_IS_INTERNAL