VMTK
Loading...
Searching...
No Matches
vtkvmtkCenterlineSplittingAndGroupingFilter.h
Go to the documentation of this file.
1/*=========================================================================
2
3Program: VMTK
4
5 Copyright (c) Luca Antiga, David Steinman. All rights reserved.
6 See LICENSE file for details.
7
8 Portions of this code are covered under the VTK copyright.
9 See VTKCopyright.txt or http://www.kitware.com/VTKCopyright.htm
10 for details.
11
12 This software is distributed WITHOUT ANY WARRANTY; without even
13 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
14 PURPOSE. See the above copyright notices for more information.
15
16=========================================================================*/
34
35#ifndef __vtkvmtkCenterlineSplittingAndGroupingFilter_h
36#define __vtkvmtkCenterlineSplittingAndGroupingFilter_h
37
38#include "vtkPolyDataAlgorithm.h"
39//#include "vtkvmtkComputationalGeometryWin32Header.h"
40#include "vtkvmtkWin32Header.h"
41
42class VTK_VMTK_COMPUTATIONAL_GEOMETRY_EXPORT vtkvmtkCenterlineSplittingAndGroupingFilter : public vtkPolyDataAlgorithm
43{
44 public:
45 vtkTypeMacro(vtkvmtkCenterlineSplittingAndGroupingFilter,vtkPolyDataAlgorithm);
46 void PrintSelf(std::ostream& os, vtkIndent indent) override;
47
49
54 vtkSetStringMacro(RadiusArrayName);
55 vtkGetStringMacro(RadiusArrayName);
57
59
64 vtkSetStringMacro(GroupIdsArrayName);
65 vtkGetStringMacro(GroupIdsArrayName);
67
69
74 vtkSetStringMacro(CenterlineIdsArrayName);
75 vtkGetStringMacro(CenterlineIdsArrayName);
77
79
85 vtkSetStringMacro(BlankingArrayName);
86 vtkGetStringMacro(BlankingArrayName);
88
90
95 vtkSetStringMacro(TractIdsArrayName);
96 vtkGetStringMacro(TractIdsArrayName);
98
100
106 vtkSetMacro(GroupingMode,int);
107 vtkGetMacro(GroupingMode,int);
109
115
121
128
129//BTX
133 enum {
137 };
138//ETX
139
140 protected:
143
144 virtual int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override;
145
146 virtual void ComputeCenterlineSplitting(vtkPolyData* input, vtkIdType cellId) = 0;
147
148 virtual void GroupTracts(vtkPolyData* input, vtkPolyData* centerlineTracts);
149
150 void CoincidentExtremePointGroupTracts(vtkPolyData* input, vtkPolyData* centerlineTracts, bool first = true);
151 void PointInTubeGroupTracts(vtkPolyData* input, vtkPolyData* centerlineTracts);
152
153 virtual void MergeTracts(vtkPolyData* centerlineTracts);
154
155 void SplitCenterline(vtkPolyData* input, vtkIdType cellId, int numberOfSplittingPoints, const vtkIdType* subIds, const double* pcoords, const int* tractBlanking, vtkPolyData* splitCenterline);
156
157 void MakeGroupIdsAdjacent(vtkPolyData* centerlineTracts);
158 void MakeTractIdsAdjacent(vtkPolyData* centerlineTracts);
159
165
167 vtkIdType* SubIds;
168 double* PCoords;
171
172 private:
174 void operator=(const vtkvmtkCenterlineSplittingAndGroupingFilter&); // Not implemented.
175};
176
177#endif
Multipurpose filter used to bundle and blank split tracts in all "branch extractor" like methods.
void SplitCenterline(vtkPolyData *input, vtkIdType cellId, int numberOfSplittingPoints, const vtkIdType *subIds, const double *pcoords, const int *tractBlanking, vtkPolyData *splitCenterline)
void CoincidentExtremePointGroupTracts(vtkPolyData *input, vtkPolyData *centerlineTracts, bool first=true)
void PointInTubeGroupTracts(vtkPolyData *input, vtkPolyData *centerlineTracts)
void PrintSelf(std::ostream &os, vtkIndent indent) override
virtual void ComputeCenterlineSplitting(vtkPolyData *input, vtkIdType cellId)=0
virtual void GroupTracts(vtkPolyData *input, vtkPolyData *centerlineTracts)