VTK
vtkPolyDataAlgorithm.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkPolyDataAlgorithm.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 =========================================================================*/
39 #ifndef __vtkPolyDataAlgorithm_h
40 #define __vtkPolyDataAlgorithm_h
41 
42 #include "vtkAlgorithm.h"
43 #include "vtkPolyData.h" // makes things a bit easier
44 
45 class vtkDataSet;
46 class vtkPolyData;
47 
49 {
50 public:
51  static vtkPolyDataAlgorithm *New();
53  void PrintSelf(ostream& os, vtkIndent indent);
54 
56 
57  vtkPolyData* GetOutput();
58  vtkPolyData* GetOutput(int);
59  virtual void SetOutput(vtkDataObject* d);
61 
63 
64  virtual int ProcessRequest(vtkInformation*,
68 
69  // this method is not recommended for use, but lots of old style filters
70  // use it
71  vtkDataObject* GetInput();
72  vtkDataObject *GetInput(int port);
73  vtkPolyData *GetPolyDataInput(int port);
74 
76 
83  void SetInput(vtkDataObject *);
84  void SetInput(int, vtkDataObject*);
86 
88 
92  void AddInput(vtkDataObject *);
93  void AddInput(int, vtkDataObject*);
95 
96 protected:
99 
100  // convenience method
101  virtual int RequestInformation(vtkInformation* request,
102  vtkInformationVector** inputVector,
103  vtkInformationVector* outputVector);
104 
106 
108  virtual int RequestData(vtkInformation* request,
109  vtkInformationVector** inputVector,
110  vtkInformationVector* outputVector);
112 
114 
116  virtual int RequestUpdateExtent(vtkInformation*,
120 
122 
123  virtual void ExecuteData(vtkDataObject *output);
124  virtual void Execute();
126 
127  // see algorithm for more info
128  virtual int FillOutputPortInformation(int port, vtkInformation* info);
129  virtual int FillInputPortInformation(int port, vtkInformation* info);
130 
131 private:
132  vtkPolyDataAlgorithm(const vtkPolyDataAlgorithm&); // Not implemented.
133  void operator=(const vtkPolyDataAlgorithm&); // Not implemented.
134 };
135 
136 #endif
Store vtkAlgorithm input/output information.
#define VTK_FILTERING_EXPORT
abstract class to specify dataset behavior
Definition: vtkDataSet.h:58
virtual int ProcessRequest(vtkInformation *request, vtkInformationVector **inInfo, vtkInformationVector *outInfo)
concrete dataset represents vertices, lines, polygons, and triangle strips
Definition: vtkPolyData.h:81
Superclass for all sources, filters, and sinks in VTK.
Definition: vtkAlgorithm.h:59
Superclass for algorithms that produce only polydata as output.
virtual int FillOutputPortInformation(int port, vtkInformation *info)
a simple class to control print indentation
Definition: vtkIndent.h:37
virtual int FillInputPortInformation(int port, vtkInformation *info)
Store zero or more vtkInformation instances.
static vtkAlgorithm * New()
helper class to get VTK data object types as string and instantiate them
void PrintSelf(ostream &os, vtkIndent indent)