VTK  9.2.5
vtkCollapseVerticesByArray.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: Visualization Toolkit
4 Module: vtkCollapseVerticesByArray.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=========================================================================*/
33#ifndef vtkCollapseVerticesByArray_h
34#define vtkCollapseVerticesByArray_h
35
36#include "vtkGraphAlgorithm.h"
37#include "vtkInfovisCoreModule.h" // For export macro
38
39class vtkCollapseVerticesByArrayInternal;
40
41class VTKINFOVISCORE_EXPORT vtkCollapseVerticesByArray : public vtkGraphAlgorithm
42{
43public:
46
47 void PrintSelf(ostream& os, vtkIndent indent) override;
48
50
53 vtkGetMacro(AllowSelfLoops, bool);
54 vtkSetMacro(AllowSelfLoops, bool);
55 vtkBooleanMacro(AllowSelfLoops, bool);
57
62 void AddAggregateEdgeArray(const char* arrName);
63
68
70
73 vtkGetStringMacro(VertexArray);
74 vtkSetStringMacro(VertexArray);
76
78
81 vtkGetMacro(CountEdgesCollapsed, bool);
82 vtkSetMacro(CountEdgesCollapsed, bool);
83 vtkBooleanMacro(CountEdgesCollapsed, bool);
85
87
91 vtkGetStringMacro(EdgesCollapsedArray);
92 vtkSetStringMacro(EdgesCollapsedArray);
94
96
99 vtkGetMacro(CountVerticesCollapsed, bool);
100 vtkSetMacro(CountVerticesCollapsed, bool);
101 vtkBooleanMacro(CountVerticesCollapsed, bool);
103
105
109 vtkGetStringMacro(VerticesCollapsedArray);
110 vtkSetStringMacro(VerticesCollapsedArray);
112
113protected:
116
121 vtkInformationVector* outputVector) override;
122
126 int FillOutputPortInformation(int port, vtkInformation* info) override;
127
132
137
138private:
141 void operator=(const vtkCollapseVerticesByArray&) = delete;
143
144protected:
147
150
153
154 vtkCollapseVerticesByArrayInternal* Internal;
155};
156
157#endif // vtkCollapseVerticesByArray_h__
Collapse the graph given a vertex array.
int FillOutputPortInformation(int port, vtkInformation *info) override
Pipeline function.
int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector) override
Pipeline function.
void FindEdge(vtkGraph *outGraph, vtkIdType source, vtkIdType target, vtkIdType &edgeId)
Helper function.
static vtkCollapseVerticesByArray * New()
vtkCollapseVerticesByArrayInternal * Internal
void AddAggregateEdgeArray(const char *arrName)
Add arrays on which aggregation of data is allowed.
vtkGraph * Create(vtkGraph *inGraph)
Create output graph given all the parameters.
~vtkCollapseVerticesByArray() override
void ClearAggregateEdgeArray()
Clear the list of arrays on which aggregation was set to allow.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
Superclass for algorithms that produce only graph as output.
Base class for graph data types.
Definition: vtkGraph.h:296
a simple class to control print indentation
Definition: vtkIndent.h:40
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
boost::graph_traits< vtkGraph * >::vertex_descriptor source(boost::graph_traits< vtkGraph * >::edge_descriptor e, vtkGraph *)
boost::graph_traits< vtkGraph * >::vertex_descriptor target(boost::graph_traits< vtkGraph * >::edge_descriptor e, vtkGraph *)
int vtkIdType
Definition: vtkType.h:332