VTK  9.1.0
vtkGraphWeightEuclideanDistanceFilter.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: Visualization Toolkit
4 Module: vtkGraphWeightEuclideanDistanceFilter.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=========================================================================*/
24#ifndef vtkGraphWeightEuclideanDistanceFilter_h
25#define vtkGraphWeightEuclideanDistanceFilter_h
26
27#include "vtkFiltersGeneralModule.h" // For export macro
29
30class vtkGraph;
31
32class VTKFILTERSGENERAL_EXPORT vtkGraphWeightEuclideanDistanceFilter : public vtkGraphWeightFilter
33{
34public:
37 void PrintSelf(ostream& os, vtkIndent indent) override;
38
39protected:
42
47 float ComputeWeight(vtkGraph* const graph, const vtkEdgeType& edge) const override;
48
52 bool CheckRequirements(vtkGraph* const graph) const override;
53
54private:
56 void operator=(const vtkGraphWeightEuclideanDistanceFilter&) = delete;
57};
58
59#endif
Weights the edges of a graph based on the Euclidean distance between the points.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
float ComputeWeight(vtkGraph *const graph, const vtkEdgeType &edge) const override
Compute the Euclidean distance between the Points defined for the vertices of a specified 'edge'.
~vtkGraphWeightEuclideanDistanceFilter() override=default
bool CheckRequirements(vtkGraph *const graph) const override
Ensure that 'graph' has Points defined.
static vtkGraphWeightEuclideanDistanceFilter * New()
Base class for filters that weight graph edges.
Base class for graph data types.
Definition: vtkGraph.h:339
a simple class to control print indentation
Definition: vtkIndent.h:113