VTK  9.2.6
vtkImageAlgorithm.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkImageAlgorithm.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
31 #ifndef vtkImageAlgorithm_h
32 #define vtkImageAlgorithm_h
33 
34 #include "vtkAlgorithm.h"
35 #include "vtkCommonExecutionModelModule.h" // For export macro
36 
37 class vtkDataSet;
38 class vtkImageData;
39 
40 class VTKCOMMONEXECUTIONMODEL_EXPORT vtkImageAlgorithm : public vtkAlgorithm
41 {
42 public:
44  void PrintSelf(ostream& os, vtkIndent indent) override;
45 
47 
50  vtkImageData* GetOutput();
51  vtkImageData* GetOutput(int);
52  virtual void SetOutput(vtkDataObject* d);
54 
62 
64 
69  void SetInputData(vtkDataObject*);
70  void SetInputData(int, vtkDataObject*);
72 
74 
79  vtkDataObject* GetInput(int port);
80  vtkDataObject* GetInput() { return this->GetInput(0); }
81  vtkImageData* GetImageDataInput(int port);
83 
85 
90  virtual void AddInputData(vtkDataObject*);
91  virtual void AddInputData(int, vtkDataObject*);
93 
94 protected:
96  ~vtkImageAlgorithm() override;
97 
102  virtual int RequestInformation(vtkInformation* request, vtkInformationVector** inputVector,
103  vtkInformationVector* outputVector);
104 
110  virtual int RequestUpdateExtent(vtkInformation*, vtkInformationVector**, vtkInformationVector*);
111 
119  virtual void CopyInputArrayAttributesToOutput(vtkInformation* request,
120  vtkInformationVector** inputVector, vtkInformationVector* outputVector);
121 
129  virtual int RequestData(vtkInformation* request, vtkInformationVector** inputVector,
130  vtkInformationVector* outputVector);
131 
136  virtual void ExecuteDataWithInformation(vtkDataObject* output, vtkInformation* outInfo);
137 
139 
143  virtual void ExecuteData(vtkDataObject* output);
144  virtual void Execute();
146 
148 
152  virtual void AllocateOutputData(vtkImageData* out, vtkInformation* outInfo, int* uExtent);
153  virtual vtkImageData* AllocateOutputData(vtkDataObject* out, vtkInformation* outInfo);
155 
160  virtual void CopyAttributeData(
161  vtkImageData* in, vtkImageData* out, vtkInformationVector** inputVector);
162 
164 
170  int FillInputPortInformation(int port, vtkInformation* info) override;
172 
173 private:
174  vtkImageAlgorithm(const vtkImageAlgorithm&) = delete;
175  void operator=(const vtkImageAlgorithm&) = delete;
176 };
177 
178 #endif
Store vtkAlgorithm input/output information.
abstract class to specify dataset behavior
Definition: vtkDataSet.h:62
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:69
virtual vtkTypeBool ProcessRequest(vtkInformation *request, vtkInformationVector **inInfo, vtkInformationVector *outInfo)
Upstream/Downstream requests form the generalized interface through which executives invoke a algorit...
Superclass for all sources, filters, and sinks in VTK.
Definition: vtkAlgorithm.h:62
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:39
topologically and geometrically regular array of data
Definition: vtkImageData.h:53
virtual int FillInputPortInformation(int port, vtkInformation *info)
Fill the input port information objects for this algorithm.
Generic algorithm superclass for image algs.
Store zero or more vtkInformation instances.
general representation of visualization data
Definition: vtkDataObject.h:65