VTK  9.3.1
vtkKdTreeSelector.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-FileCopyrightText: Copyright (c) Sandia Corporation
3 // SPDX-License-Identifier: BSD-3-Clause
16 #ifndef vtkKdTreeSelector_h
17 #define vtkKdTreeSelector_h
18 
19 #include "vtkFiltersSelectionModule.h" // For export macro
20 #include "vtkSelectionAlgorithm.h"
21 
22 VTK_ABI_NAMESPACE_BEGIN
23 class vtkKdTree;
24 
25 class VTKFILTERSSELECTION_EXPORT vtkKdTreeSelector : public vtkSelectionAlgorithm
26 {
27 public:
28  static vtkKdTreeSelector* New();
30  void PrintSelf(ostream& os, vtkIndent indent) override;
31 
33 
38  void SetKdTree(vtkKdTree* tree);
39  vtkGetObjectMacro(KdTree, vtkKdTree);
41 
43 
48  vtkSetVector6Macro(SelectionBounds, double);
49  vtkGetVector6Macro(SelectionBounds, double);
51 
53 
59  vtkSetStringMacro(SelectionFieldName);
60  vtkGetStringMacro(SelectionFieldName);
62 
64 
72  vtkSetMacro(SelectionAttribute, int);
73  vtkGetMacro(SelectionAttribute, int);
75 
77 
83  vtkSetMacro(SingleSelection, bool);
84  vtkGetMacro(SingleSelection, bool);
85  vtkBooleanMacro(SingleSelection, bool);
87 
89 
95  vtkSetMacro(SingleSelectionThreshold, double);
96  vtkGetMacro(SingleSelectionThreshold, double);
98 
99  vtkMTimeType GetMTime() override;
100 
101 protected:
103  ~vtkKdTreeSelector() override;
104 
106  double SelectionBounds[6];
112 
113  int FillInputPortInformation(int port, vtkInformation* info) override;
114 
116 
117 private:
118  vtkKdTreeSelector(const vtkKdTreeSelector&) = delete;
119  void operator=(const vtkKdTreeSelector&) = delete;
120 };
121 
122 VTK_ABI_NAMESPACE_END
123 #endif
int FillInputPortInformation(int port, vtkInformation *info) override
Fill the input port information objects for this algorithm.
Store vtkAlgorithm input/output information.
vtkTypeUInt32 vtkMTimeType
Definition: vtkType.h:270
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
static vtkSelectionAlgorithm * New()
a simple class to control print indentation
Definition: vtkIndent.h:28
Selects point ids using a kd-tree.
virtual vtkMTimeType GetMTime()
Return this object's modified time.
Superclass for algorithms that produce only Selection as output.
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
This is called by the superclass.
a Kd-tree spatial decomposition of a set of points
Definition: vtkKdTree.h:67
Store zero or more vtkInformation instances.