VTK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
vtkProbeFilter.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkProbeFilter.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 =========================================================================*/
43 #ifndef __vtkProbeFilter_h
44 #define __vtkProbeFilter_h
45 
46 #include "vtkFiltersCoreModule.h" // For export macro
47 #include "vtkDataSetAlgorithm.h"
48 #include "vtkDataSetAttributes.h" // needed for vtkDataSetAttributes::FieldList
49 
50 class vtkIdTypeArray;
51 class vtkCharArray;
52 class vtkMaskPoints;
53 
54 class VTKFILTERSCORE_EXPORT vtkProbeFilter : public vtkDataSetAlgorithm
55 {
56 public:
57  static vtkProbeFilter *New();
59  void PrintSelf(ostream& os, vtkIndent indent);
60 
62 
64  void SetSourceData(vtkDataObject *source);
65  vtkDataObject *GetSource();
67 
70  void SetSourceConnection(vtkAlgorithmOutput* algOutput);
71 
73 
81  vtkSetMacro(SpatialMatch, int);
82  vtkGetMacro(SpatialMatch, int);
83  vtkBooleanMacro(SpatialMatch, int);
85 
87 
89  vtkGetObjectMacro(ValidPoints, vtkIdTypeArray);
91 
93 
96  vtkSetStringMacro(ValidPointMaskArrayName)
97  vtkGetStringMacro(ValidPointMaskArrayName)
99 
101 
102  vtkSetMacro(PassCellArrays, int);
103  vtkGetMacro(PassCellArrays, int);
104  //
105  vtkSetMacro(PassPointArrays, int);
106  vtkGetMacro(PassPointArrays, int);
108 
109 //BTX
110 protected:
111  vtkProbeFilter();
112  ~vtkProbeFilter();
113 
114  int PassCellArrays;
115  int PassPointArrays;
116 
117  int SpatialMatch;
118 
119  virtual int RequestData(vtkInformation *, vtkInformationVector **,
120  vtkInformationVector *);
121  virtual int RequestInformation(vtkInformation *, vtkInformationVector **,
122  vtkInformationVector *);
123  virtual int RequestUpdateExtent(vtkInformation *, vtkInformationVector **,
124  vtkInformationVector *);
125 
127  void Probe(vtkDataSet *input, vtkDataSet *source, vtkDataSet *output);
128 
131  void BuildFieldList(vtkDataSet* source);
132 
135  virtual void InitializeForProbing(vtkDataSet *input, vtkDataSet *output);
136 
138 
141  void ProbeEmptyPoints(vtkDataSet *input, int srcIdx, vtkDataSet *source,
142  vtkDataSet *output);
144 
145  char* ValidPointMaskArrayName;
146  vtkIdTypeArray *ValidPoints;
147  vtkCharArray* MaskPoints;
148  int NumberOfValidPoints;
149 
150  // Agreed, this is sort of a hack to allow subclasses to override the default
151  // behavior of this filter to call NullPoint() for every point that is
152  // not-a-hit when probing. This makes it possible for subclasses to initialize
153  // the arrays with different defaults.
154  bool UseNullPoint;
155 
156  vtkDataSetAttributes::FieldList* CellList;
157  vtkDataSetAttributes::FieldList* PointList;
158 private:
159  vtkProbeFilter(const vtkProbeFilter&); // Not implemented.
160  void operator=(const vtkProbeFilter&); // Not implemented.
161 
162  class vtkVectorOfArrays;
163  vtkVectorOfArrays* CellArrays;
164 //ETX
165 };
166 
167 #endif
sample data values at specified point locations
Proxy object to connect input/output ports.
selectively filter points
Definition: vtkMaskPoints.h:42
boost::graph_traits< vtkGraph * >::vertex_descriptor source(boost::graph_traits< vtkGraph * >::edge_descriptor e, vtkGraph *)
void PrintSelf(ostream &os, vtkIndent indent)
Superclass for algorithms that produce output of the same type as input.
general representation of visualization data
Definition: vtkDataObject.h:64
static vtkDataSetAlgorithm * New()