VTK  9.3.20240418
vtkStrahlerMetric.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-FileCopyrightText: Copyright 2008 Sandia Corporation
3 // SPDX-License-Identifier: LicenseRef-BSD-3-Clause-Sandia-USGov
27 #ifndef vtkStrahlerMetric_h
28 #define vtkStrahlerMetric_h
29 
30 #include "vtkFiltersStatisticsModule.h" // For export macro
31 #include "vtkTreeAlgorithm.h"
32 
33 VTK_ABI_NAMESPACE_BEGIN
34 class vtkFloatArray;
35 
36 class VTKFILTERSSTATISTICS_EXPORT vtkStrahlerMetric : public vtkTreeAlgorithm
37 {
38 public:
41  void PrintSelf(ostream& os, vtkIndent indent) override;
42 
44 
49  vtkSetStringMacro(MetricArrayName);
51 
53 
58  vtkSetMacro(Normalize, vtkTypeBool);
59  vtkGetMacro(Normalize, vtkTypeBool);
60  vtkBooleanMacro(Normalize, vtkTypeBool);
62 
64 
67  vtkGetMacro(MaxStrahler, float);
69 
70 protected:
72  ~vtkStrahlerMetric() override;
73 
75 
77  float MaxStrahler;
79 
80  float CalculateStrahler(vtkIdType root, vtkFloatArray* metric, vtkTree* tree);
81 
82 private:
83  vtkStrahlerMetric(const vtkStrahlerMetric&) = delete;
84  void operator=(const vtkStrahlerMetric&) = delete;
85 };
86 
87 VTK_ABI_NAMESPACE_END
88 #endif
dynamic, self-adjusting array of float
a simple class to control print indentation
Definition: vtkIndent.h:108
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
compute Strahler metric for a tree
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
~vtkStrahlerMetric() override
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
float CalculateStrahler(vtkIdType root, vtkFloatArray *metric, vtkTree *tree)
static vtkStrahlerMetric * New()
Superclass for algorithms that produce only Tree as output.
A rooted tree data structure.
Definition: vtkTree.h:145
int vtkTypeBool
Definition: vtkABI.h:64
int vtkIdType
Definition: vtkType.h:315