VTK  9.3.20240424
vtkTreeDifferenceFilter.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2// SPDX-License-Identifier: BSD-3-Clause
3
20#ifndef vtkTreeDifferenceFilter_h
21#define vtkTreeDifferenceFilter_h
22
23#include "vtkGraphAlgorithm.h"
24#include "vtkInfovisCoreModule.h" // For export macro
25
26#include "vtkSmartPointer.h" // For ivars
27#include <vector> // For ivars
28
29VTK_ABI_NAMESPACE_BEGIN
30class vtkDoubleArray;
31class vtkTree;
32
33class VTKINFOVISCORE_EXPORT vtkTreeDifferenceFilter : public vtkGraphAlgorithm
34{
35public:
38 void PrintSelf(ostream& os, vtkIndent indent) override;
39
41
51 vtkSetStringMacro(IdArrayName);
52 vtkGetStringMacro(IdArrayName);
54
56
60 vtkSetStringMacro(ComparisonArrayName);
61 vtkGetStringMacro(ComparisonArrayName);
63
65
72 vtkSetStringMacro(OutputArrayName);
73 vtkGetStringMacro(OutputArrayName);
75
77
82 vtkSetMacro(ComparisonArrayIsVertexData, bool);
83 vtkGetMacro(ComparisonArrayIsVertexData, bool);
85
86protected:
89
91
92 int FillInputPortInformation(int port, vtkInformation* info) override;
93
99 bool GenerateMapping(vtkTree* tree1, vtkTree* tree2);
100
106
111
112 std::vector<vtkIdType> VertexMap;
113 std::vector<vtkIdType> EdgeMap;
114
115private:
117 void operator=(const vtkTreeDifferenceFilter&) = delete;
118};
119
120VTK_ABI_NAMESPACE_END
121#endif
dynamic, self-adjusting array of double
Superclass for algorithms that produce only graph as output.
a simple class to control print indentation
Definition vtkIndent.h:108
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
Hold a reference to a vtkObjectBase instance.
vtkSmartPointer< vtkDoubleArray > ComputeDifference(vtkTree *tree1, vtkTree *tree2)
Compute the differences between tree #1 and tree #2's copies of the comparison array.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
bool GenerateMapping(vtkTree *tree1, vtkTree *tree2)
Populate VertexMap and EdgeMap with meaningful values.
int FillInputPortInformation(int port, vtkInformation *info) override
Fill the input port information objects for this algorithm.
static vtkTreeDifferenceFilter * New()
std::vector< vtkIdType > EdgeMap
~vtkTreeDifferenceFilter() override
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
std::vector< vtkIdType > VertexMap
A rooted tree data structure.
Definition vtkTree.h:145