VTK  9.0.20210121
vtkDataSetAlgorithm.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkDataSetAlgorithm.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 =========================================================================*/
34 #ifndef vtkDataSetAlgorithm_h
35 #define vtkDataSetAlgorithm_h
36 
37 #include "vtkAlgorithm.h"
38 #include "vtkCommonExecutionModelModule.h" // For export macro
39 
40 class vtkDataSet;
41 class vtkImageData;
42 class vtkPolyData;
44 class vtkStructuredGrid;
46 class vtkRectilinearGrid;
47 
48 class VTKCOMMONEXECUTIONMODEL_EXPORT vtkDataSetAlgorithm : public vtkAlgorithm
49 {
50 public:
51  static vtkDataSetAlgorithm* New();
53  void PrintSelf(ostream& os, vtkIndent indent) override;
54 
56 
59  vtkDataSet* GetOutput();
60  vtkDataSet* GetOutput(int);
62 
67  vtkDataObject* GetInput();
68 
72  vtkPolyData* GetPolyDataOutput();
73 
77  vtkStructuredPoints* GetStructuredPointsOutput();
78 
82  vtkImageData* GetImageDataOutput();
83 
87  vtkStructuredGrid* GetStructuredGridOutput();
88 
92  vtkUnstructuredGrid* GetUnstructuredGridOutput();
93 
97  vtkRectilinearGrid* GetRectilinearGridOutput();
98 
100 
105  void SetInputData(vtkDataObject*);
106  void SetInputData(int, vtkDataObject*);
107  void SetInputData(vtkDataSet*);
108  void SetInputData(int, vtkDataSet*);
110 
112 
117  void AddInputData(vtkDataObject*);
118  void AddInputData(vtkDataSet*);
119  void AddInputData(int, vtkDataSet*);
120  void AddInputData(int, vtkDataObject*);
122 
127  vtkInformationVector* outputVector) override;
128 
129 protected:
131  ~vtkDataSetAlgorithm() override = default;
132 
141  {
142  return 1;
143  }
144 
146 
153  {
154  return 1;
155  }
157 
167  virtual int RequestDataObject(vtkInformation* request, vtkInformationVector** inputVector,
168  vtkInformationVector* outputVector);
169 
177  {
178  return 1;
179  }
180 
181  // see algorithm for more info
183  int FillInputPortInformation(int port, vtkInformation* info) override;
184 
185  vtkDataObject* GetInput(int port);
186 
187 private:
188  vtkDataSetAlgorithm(const vtkDataSetAlgorithm&) = delete;
189  void operator=(const vtkDataSetAlgorithm&) = delete;
190 };
191 
192 #endif
vtkStructuredPoints
A subclass of ImageData.
Definition: vtkStructuredPoints.h:35
vtkAlgorithm
Superclass for all sources, filters, and sinks in VTK.
Definition: vtkAlgorithm.h:63
vtkAlgorithm::FillInputPortInformation
virtual int FillInputPortInformation(int port, vtkInformation *info)
Fill the input port information objects for this algorithm.
vtkRectilinearGrid
a dataset that is topologically regular with variable spacing in the three coordinate directions
Definition: vtkRectilinearGrid.h:51
vtkInformationVector
Store zero or more vtkInformation instances.
Definition: vtkInformationVector.h:35
vtkStructuredGrid
topologically regular array of data
Definition: vtkStructuredGrid.h:57
vtkDataSetAlgorithm::RequestData
virtual int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called within ProcessRequest when a request asks the algorithm to do its work.
Definition: vtkDataSetAlgorithm.h:176
vtkAlgorithm.h
vtkDataSetAlgorithm
Superclass for algorithms that produce output of the same type as input.
Definition: vtkDataSetAlgorithm.h:48
vtkX3D::port
Definition: vtkX3D.h:453
vtkImageData
topologically and geometrically regular array of data
Definition: vtkImageData.h:47
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:33
vtkDataSet
abstract class to specify dataset behavior
Definition: vtkDataSet.h:56
vtkInformation
Store vtkAlgorithm input/output information.
Definition: vtkInformation.h:73
vtkX3D::info
Definition: vtkX3D.h:382
vtkAlgorithm::New
static vtkAlgorithm * New()
vtkPolyData
concrete dataset represents vertices, lines, polygons, and triangle strips
Definition: vtkPolyData.h:85
vtkAlgorithm::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkDataSetAlgorithm::RequestUpdateExtent
virtual int RequestUpdateExtent(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called within ProcessRequest when each filter in the pipeline decides what portion of its inp...
Definition: vtkDataSetAlgorithm.h:152
vtkUnstructuredGrid
dataset represents arbitrary combinations of all possible cell types
Definition: vtkUnstructuredGrid.h:93
vtkDataObject
general representation of visualization data
Definition: vtkDataObject.h:59
vtkAlgorithm::ProcessRequest
virtual vtkTypeBool ProcessRequest(vtkInformation *request, vtkInformationVector **inInfo, vtkInformationVector *outInfo)
Upstream/Downstream requests form the generalized interface through which executives invoke a algorit...
vtkAlgorithm::FillOutputPortInformation
virtual int FillOutputPortInformation(int port, vtkInformation *info)
Fill the output port information objects for this algorithm.
vtkTypeBool
int vtkTypeBool
Definition: vtkABI.h:69
vtkDataSetAlgorithm::RequestInformation
virtual int RequestInformation(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called within ProcessRequest when a request asks for Information.
Definition: vtkDataSetAlgorithm.h:140