VMTK
vtkvmtkCenterlineGeometry.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3 Program: VMTK
4 Module: $RCSfile: vtkvmtkCenterlineGeometry.h,v $
5 Language: C++
6 
7  Copyright (c) Luca Antiga, David Steinman. All rights reserved.
8  See LICENSE file for details.
9 
10  Portions of this code are covered under the VTK copyright.
11  See VTKCopyright.txt or http://www.kitware.com/VTKCopyright.htm
12  for details.
13 
14  This software is distributed WITHOUT ANY WARRANTY; without even
15  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
16  PURPOSE. See the above copyright notices for more information.
17 
18 =========================================================================*/
32 #ifndef __vtkvmtkCenterlineGeometry_h
33 #define __vtkvmtkCenterlineGeometry_h
34 
35 #include "vtkPolyDataAlgorithm.h"
36 //#include "vtkvmtkComputationalGeometryWin32Header.h"
37 #include "vtkvmtkWin32Header.h"
38 
39 class vtkDoubleArray;
40 
41 class VTK_VMTK_COMPUTATIONAL_GEOMETRY_EXPORT vtkvmtkCenterlineGeometry : public vtkPolyDataAlgorithm
42 {
43  public:
44  vtkTypeMacro(vtkvmtkCenterlineGeometry,vtkPolyDataAlgorithm);
45  void PrintSelf(ostream& os, vtkIndent indent) VTK_OVERRIDE;
46 
47  static vtkvmtkCenterlineGeometry* New();
48 
49  vtkSetStringMacro(LengthArrayName);
50  vtkGetStringMacro(LengthArrayName);
51 
52  vtkSetStringMacro(CurvatureArrayName);
53  vtkGetStringMacro(CurvatureArrayName);
54 
55  vtkSetStringMacro(TorsionArrayName);
56  vtkGetStringMacro(TorsionArrayName);
57 
58  vtkSetStringMacro(TortuosityArrayName);
59  vtkGetStringMacro(TortuosityArrayName);
60 
61  vtkSetStringMacro(FrenetTangentArrayName);
62  vtkGetStringMacro(FrenetTangentArrayName);
63 
64  vtkSetStringMacro(FrenetNormalArrayName);
65  vtkGetStringMacro(FrenetNormalArrayName);
66 
67  vtkSetStringMacro(FrenetBinormalArrayName);
68  vtkGetStringMacro(FrenetBinormalArrayName);
69 
70  vtkSetMacro(SmoothingFactor,double);
71  vtkGetMacro(SmoothingFactor,double);
72 
73  vtkSetMacro(NumberOfSmoothingIterations,int);
74  vtkGetMacro(NumberOfSmoothingIterations,int);
75 
76  vtkSetMacro(LineSmoothing,int);
77  vtkGetMacro(LineSmoothing,int);
78  vtkBooleanMacro(LineSmoothing,int);
79 
80  vtkSetMacro(OutputSmoothedLines,int);
81  vtkGetMacro(OutputSmoothedLines,int);
82  vtkBooleanMacro(OutputSmoothedLines,int);
83 
84  static double ComputeLineCurvature(vtkPoints* linePoints, vtkDoubleArray* curvatureArray);
85  static double ComputeLineTorsion(vtkPoints* linePoints, vtkDoubleArray* torsionArray);
86  static void ComputeLineFrenetReferenceSystem(vtkPoints* linePoints, vtkDoubleArray* lineTangentArray, vtkDoubleArray* lineNormalArray, vtkDoubleArray* lineBinormalArray);
87 
88  protected:
91 
92  virtual int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) VTK_OVERRIDE;
93 
101 
106 
107  private:
108  vtkvmtkCenterlineGeometry(const vtkvmtkCenterlineGeometry&); // Not implemented.
109  void operator=(const vtkvmtkCenterlineGeometry&); // Not implemented.
110 };
111 
112 #endif
Compute length, curvature, torsion, tortuosity, and frenet frames for individual centerlines.