VTK  9.7.1
vtkDataSetAlgorithm.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
22 #ifndef vtkDataSetAlgorithm_h
23 #define vtkDataSetAlgorithm_h
24 
25 #include "vtkAlgorithm.h"
26 #include "vtkCommonExecutionModelModule.h" // For export macro
27 #include "vtkWrappingHints.h" // For VTK_MARSHALAUTO
28 
29 VTK_ABI_NAMESPACE_BEGIN
30 class vtkDataSet;
31 class vtkImageData;
32 class vtkPolyData;
34 class vtkStructuredGrid;
36 class vtkRectilinearGrid;
37 
38 class VTKCOMMONEXECUTIONMODEL_EXPORT VTK_MARSHALAUTO vtkDataSetAlgorithm : public vtkAlgorithm
39 {
40 public:
41  static vtkDataSetAlgorithm* New();
43  void PrintSelf(ostream& os, vtkIndent indent) override;
44 
46 
49  vtkDataSet* GetOutput();
50  vtkDataSet* GetOutput(int);
52 
57  vtkDataObject* GetInput();
58 
62  vtkPolyData* GetPolyDataOutput();
63 
67  vtkStructuredPoints* GetStructuredPointsOutput();
68 
72  vtkImageData* GetImageDataOutput();
73 
77  vtkStructuredGrid* GetStructuredGridOutput();
78 
82  vtkUnstructuredGrid* GetUnstructuredGridOutput();
83 
87  vtkRectilinearGrid* GetRectilinearGridOutput();
88 
90 
95  void SetInputData(vtkDataObject*);
96  void SetInputData(int, vtkDataObject*);
97  void SetInputData(vtkDataSet*);
98  void SetInputData(int, vtkDataSet*);
100 
102 
107  void AddInputData(vtkDataObject*);
108  void AddInputData(vtkDataSet*);
109  void AddInputData(int, vtkDataSet*);
110  void AddInputData(int, vtkDataObject*);
112 
117  vtkInformationVector* outputVector) override;
118 
119 protected:
121  ~vtkDataSetAlgorithm() override = default;
122 
132  virtual int RequestDataObject(vtkInformation* request, vtkInformationVector** inputVector,
133  vtkInformationVector* outputVector);
134 
143  {
144  return 1;
145  }
146 
154  {
155  return 1;
156  }
157 
159  {
160  return 1;
161  }
162 
170  {
171  return 1;
172  }
173 
174  // see algorithm for more info
176  int FillInputPortInformation(int port, vtkInformation* info) override;
177 
178  vtkDataObject* GetInput(int port);
179 
180 private:
181  vtkDataSetAlgorithm(const vtkDataSetAlgorithm&) = delete;
182  void operator=(const vtkDataSetAlgorithm&) = delete;
183 };
184 
185 VTK_ABI_NAMESPACE_END
186 #endif
a dataset that is topologically regular with variable spacing in the three coordinate directions ...
virtual int RequestUpdateTime(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
Store vtkAlgorithm input/output information.
abstract class to specify dataset behavior
Definition: vtkDataSet.h:56
concrete dataset represents vertices, lines, polygons, and triangle strips
Definition: vtkPolyData.h:71
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
#define vtkDataSetAlgorithm
int vtkTypeBool
Definition: vtkABI.h:64
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: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
dataset represents arbitrary combinations of all possible cell types
virtual int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called within ProcessRequest when a request asks the algorithm to do its work.
virtual int FillInputPortInformation(int port, vtkInformation *info)
Fill the input port information objects for this algorithm.
virtual int RequestUpdateExtent(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called within ProcessRequest when each filter in the pipeline decides what portion of its inp...
A subclass of ImageData.
virtual int RequestInformation(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called within ProcessRequest when a request asks for Information.
topologically regular array of data
Store zero or more vtkInformation instances.
static vtkAlgorithm * New()
#define VTK_MARSHALAUTO
Superclass for algorithms that produce output of the same type as input.
general representation of visualization data
Definition: vtkDataObject.h:55