41 #ifndef __vtkConvertSelection_h
42 #define __vtkConvertSelection_h
44 #include "vtkFiltersExtractionModule.h"
45 #include "vtkSelectionAlgorithm.h"
47 class vtkCompositeDataSet;
51 class vtkSelectionNode;
61 void PrintSelf(ostream& os, vtkIndent indent);
65 void SetDataObjectConnection(vtkAlgorithmOutput* in);
72 vtkSetMacro(InputFieldType,
int);
73 vtkGetMacro(InputFieldType,
int);
79 vtkSetMacro(OutputType,
int);
80 vtkGetMacro(OutputType,
int);
85 virtual void SetArrayName(
const char*);
86 virtual const char* GetArrayName();
91 virtual void SetArrayNames(vtkStringArray*);
92 vtkGetObjectMacro(ArrayNames, vtkStringArray);
97 void AddArrayName(
const char*);
98 void ClearArrayNames();
104 vtkSetMacro(MatchAnyValues,
bool);
105 vtkGetMacro(MatchAnyValues,
bool);
106 vtkBooleanMacro(MatchAnyValues,
bool);
119 static vtkSelection* ToIndexSelection(
121 vtkDataObject* data);
122 static vtkSelection* ToGlobalIdSelection(
124 vtkDataObject* data);
125 static vtkSelection* ToPedigreeIdSelection(
127 vtkDataObject* data);
128 static vtkSelection* ToValueSelection(
131 const char* arrayName);
132 static vtkSelection* ToValueSelection(
135 vtkStringArray* arrayNames);
142 static void GetSelectedItems(
146 vtkIdTypeArray* indices);
152 static void GetSelectedVertices(
155 vtkIdTypeArray* indices);
156 static void GetSelectedEdges(
159 vtkIdTypeArray* indices);
160 static void GetSelectedPoints(
163 vtkIdTypeArray* indices);
164 static void GetSelectedCells(
167 vtkIdTypeArray* indices);
168 static void GetSelectedRows(
171 vtkIdTypeArray* indices);
177 static vtkSelection* ToSelectionType(
181 vtkStringArray* arrayNames = 0,
182 int inputFieldType = -1);
189 virtual int RequestData(
191 vtkInformationVector **,
192 vtkInformationVector *);
197 vtkSelection* output);
199 int ConvertCompositeDataSet(
201 vtkCompositeDataSet* data,
202 vtkSelection* output);
204 int ConvertToIndexSelection(
205 vtkSelectionNode* input,
207 vtkSelectionNode* output);
209 int SelectTableFromTable(
212 vtkIdTypeArray* indices);
214 int ConvertToBlockSelection(
215 vtkSelection* input, vtkCompositeDataSet* data, vtkSelection* output);
217 virtual int FillInputPortInformation(
218 int port, vtkInformation* info);
vtkExtractSelection * SelectionExtractor
vtkStringArray * ArrayNames
Convert a selection from one type to another.