VTK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
vtkCompositeDataPipeline.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkCompositeDataPipeline.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 =========================================================================*/
49 #ifndef __vtkCompositeDataPipeline_h
50 #define __vtkCompositeDataPipeline_h
51 
52 #include "vtkCommonExecutionModelModule.h" // For export macro
54 
63 
66 {
67 public:
68  static vtkCompositeDataPipeline* New();
70  void PrintSelf(ostream& os, vtkIndent indent);
71 
74  vtkDataObject* GetCompositeOutputData(int port);
75 
77 
79  vtkDataObject* GetCompositeInputData(
80  int port, int index, vtkInformationVector **inInfoVec);
82 
85  static vtkInformationIntegerKey* LOAD_REQUESTED_BLOCKS();
86 
92  static vtkInformationObjectBaseKey* COMPOSITE_DATA_META_DATA();
93 
102  static vtkInformationIntegerVectorKey* UPDATE_COMPOSITE_INDICES();
103 
109  static vtkInformationIntegerVectorKey* COMPOSITE_INDICES();
110 
111 
112 protected:
115 
116  virtual int ForwardUpstream(vtkInformation* request);
117  virtual int ForwardUpstream(int i, int j, vtkInformation* request);
118 
119  // Copy information for the given request.
120  virtual void CopyDefaultInformation(vtkInformation* request, int direction,
121  vtkInformationVector** inInfoVec,
122  vtkInformationVector* outInfoVec);
123 
124  virtual void CopyFromDataToInformation(
125  vtkDataObject* dobj, vtkInformation* inInfo);
126  virtual void PushInformation(vtkInformation*);
127  virtual void PopInformation (vtkInformation*);
128 
129  virtual int ExecuteDataObject(vtkInformation* request,
130  vtkInformationVector** inInfo,
131  vtkInformationVector* outInfo);
132 
133  virtual int ExecuteData(vtkInformation* request,
134  vtkInformationVector** inInfoVec,
135  vtkInformationVector* outInfoVec);
136 
137  virtual void ExecuteDataStart(vtkInformation* request,
138  vtkInformationVector** inInfoVec,
139  vtkInformationVector* outInfoVec);
140 
141  // Override this check to account for update extent.
142  virtual int NeedToExecuteData(int outputPort,
143  vtkInformationVector** inInfoVec,
144  vtkInformationVector* outInfoVec);
145 
146  // Check whether the data object in the pipeline information for an
147  // output port exists and has a valid type.
148  virtual int CheckCompositeData(vtkInformation *request,
149  int port,
150  vtkInformationVector** inInfoVec,
151  vtkInformationVector* outInfoVec);
152 
153  // True when the pipeline is iterating over the current (simple) filter
154  // to produce composite output. In this case, ExecuteDataStart() should
155  // NOT Initialize() the composite output.
157 
158  virtual void ExecuteSimpleAlgorithm(vtkInformation* request,
159  vtkInformationVector** inInfoVec,
160  vtkInformationVector* outInfoVec,
161  int compositePort);
162 
163  virtual void ExecuteEach(vtkCompositeDataIterator* iter,
164  vtkInformationVector** inInfoVec,
165  vtkInformationVector* outInfoVec,
166  int compositePort,
167  int connection,
168  vtkInformation* request,
169  vtkCompositeDataSet* compositeOutput);
170 
171  vtkDataObject* ExecuteSimpleAlgorithmForBlock(
172  vtkInformationVector** inInfoVec,
173  vtkInformationVector* outInfoVec,
174  vtkInformation* inInfo,
175  vtkInformation* outInfo,
176  vtkInformation* request,
177  vtkDataObject* dobj);
178 
179  bool ShouldIterateOverInput(vtkInformationVector** inInfoVec,
180  int& compositePort);
181 
182  virtual int InputTypeIsValid(int port, int index,
183  vtkInformationVector **inInfoVec);
184 
186 
192 
193 
194  virtual void ResetPipelineInformation(int port, vtkInformation*);
195 
197 
204  vtkCompositeDataSet* CreateOutputCompositeDataSet(
205  vtkCompositeDataSet* input, int compositePort);
207 
208  // Override this to handle UPDATE_COMPOSITE_INDICES().
209  virtual void MarkOutputsGenerated(vtkInformation* request,
210  vtkInformationVector** inInfoVec,
211  vtkInformationVector* outInfoVec);
212 
213  int NeedToExecuteBasedOnCompositeIndices(vtkInformation* outInfo);
214 
215  // Because we sometimes have to swap between "simple" data types and composite
216  // data types, we sometimes want to skip resetting the pipeline information.
217  static vtkInformationIntegerKey* SUPPRESS_RESET_PI();
218 
219 private:
220  vtkCompositeDataPipeline(const vtkCompositeDataPipeline&); // Not implemented.
221  void operator=(const vtkCompositeDataPipeline&); // Not implemented.
222 };
223 
224 #endif
#define VTKCOMMONEXECUTIONMODEL_EXPORT
virtual void ExecuteDataStart(vtkInformation *request, vtkInformationVector **inInfoVec, vtkInformationVector *outInfoVec)
static vtkStreamingDemandDrivenPipeline * New()
virtual void MarkOutputsGenerated(vtkInformation *request, vtkInformationVector **inInfoVec, vtkInformationVector *outInfoVec)
GLuint index
Definition: vtkgl.h:11983
Store vtkAlgorithm input/output information.
GLenum GLenum GLenum input
Definition: vtkgl.h:15941
Key for vtkDataObject values.
virtual int ExecuteData(vtkInformation *request, vtkInformationVector **inInfo, vtkInformationVector *outInfo)
virtual void ResetPipelineInformation(int port, vtkInformation *)
Key for string values in vtkInformation.
superclass for composite data iterators
abstract superclass for composite (multi-block or AMR) datasets
a simple class to control print indentation
Definition: vtkIndent.h:38
Key for integer values in vtkInformation.
virtual int ExecuteDataObject(vtkInformation *request, vtkInformationVector **inInfo, vtkInformationVector *outInfo)
Key for vtkObjectBase values.
int InputTypeIsValid(vtkInformationVector **)
Executive supporting composite datasets.
void PrintSelf(ostream &os, vtkIndent indent)
Key for double values in vtkInformation.
virtual void CopyDefaultInformation(vtkInformation *request, int direction, vtkInformationVector **inInfoVec, vtkInformationVector *outInfoVec)
virtual int NeedToExecuteData(int outputPort, vtkInformationVector **inInfoVec, vtkInformationVector *outInfoVec)
Store zero or more vtkInformation instances.
Executive supporting partial updates.
general representation of visualization data
Definition: vtkDataObject.h:64
virtual int ForwardUpstream(vtkInformation *request)