2 * airwaysTreeTypeDefinition.h
4 * Created on: May 19, 2014
8 #ifndef AIRWAYSTREETYPEDEFINITION_H_
9 #define AIRWAYSTREETYPEDEFINITION_H_
17 #include <boost/graph/adjacency_list.hpp>
20 #include "itkConnectedComponentImageFilter.h"
21 #include "itkConstNeighborhoodIterator.h"
22 #include "itkImageDuplicator.h"
23 #include "itkSphereSpatialFunction.h"
24 #include "itkConnectedThresholdImageFilter.h"
25 #include "itkSubtractImageFilter.h"
26 #include "itkCastImageFilter.h"
28 #include "../MathLib/vec3.h"
29 #include "airwaysNode.h"
30 #include "airwaysEdge.h"
34 typedef std::pair<Vec3, double> pair_posVox_rad;
35 typedef std::vector<pair_posVox_rad> vec_pair_posVox_rad;
43 * Pair of a pair of nodes and a score
45 //typedef std::pair<pair_node_node,double> Pair_PairNodes_Score;
47 //----------------------------------------------------------------------------
52 * @typedef Defines a graph using the Boost DiGraph library
54 typedef boost::adjacency_list<boost::vecS, boost::vecS, boost::directedS,
55 pair_posVox_rad> DiGraph;
57 //--------------------------------------------------------------------------
59 * @typedef Defines boost::vertex_descriptor of DiGraph
61 typedef boost::graph_traits<DiGraph>::vertex_descriptor DiGraph_VertexDescriptor;
62 //--------------------------------------------------------------------------
63 ///DiGraph edge_descriptor
64 typedef boost::graph_traits<DiGraph>::edge_descriptor DiGraph_EdgeDescriptor;
65 //--------------------------------------------------------------------------
67 typedef std::pair<DiGraph_EdgeDescriptor, bool> DiGraph_EdgePair;
68 //--------------------------------------------------------------------------
69 ///DiGraph Vertex IndexMap
70 typedef boost::property_map<DiGraph, boost::vertex_index_t>::type DiGraph_VertexIndexMap;
71 //--------------------------------------------------------------------------
72 ///DiGraph VertexIterator
73 typedef boost::graph_traits<DiGraph>::vertex_iterator DiGraph_VertexIterator;
74 //--------------------------------------------------------------------------
75 ///DiGraph Vertex iterator pair
76 typedef std::pair<DiGraph_VertexIterator, DiGraph_VertexIterator> DiGraph_VertexIteratorPair;
77 //--------------------------------------------------------------------------
78 ///DiGraph Edge iterator
79 typedef boost::graph_traits<DiGraph>::edge_iterator DiGraph_EdgeIterator;
80 //--------------------------------------------------------------------------
81 ///DiGraph In Edge iterator
82 typedef boost::graph_traits<DiGraph>::in_edge_iterator DiGraph_InEdgeIterator;
83 //--------------------------------------------------------------------------
84 ///DiGraph Out Edge iterator
85 typedef boost::graph_traits<DiGraph>::out_edge_iterator DiGraph_OutEdgeIterator;
86 //--------------------------------------------------------------------------
87 ///DiGraph Adjacency iterator
88 typedef boost::graph_traits<DiGraph>::adjacency_iterator DiGraph_AdjacencyIterator;
89 //--------------------------------------------------------------------------
90 ///DiGraph Vertex descriptor vector
91 typedef std::vector<DiGraph_VertexDescriptor> DiGraph_VertexVector;
92 //--------------------------------------------------------------------------
93 ///DiGraph Vertex descriptor queue
94 typedef std::queue<DiGraph_VertexDescriptor> DiGraph_VertexQueue;
95 //--------------------------------------------------------------------------
96 ///DiGraph Edge descriptor vector
97 typedef std::vector<DiGraph_EdgeDescriptor> DiGraph_EdgeVector;
98 //----------------------------------------------------------------------------
99 const unsigned int Dim = 3;
100 typedef double TPixel;
101 typedef unsigned char TPixel2;
102 typedef itk::Image<TPixel, Dim> TInputImage;
103 typedef itk::Image<TPixel2, Dim> TInputImage2;
104 typedef itk::Image<unsigned short, Dim> TInputImage3;
105 //----------------------------------------------------------------------------
106 typedef itk::ImageDuplicator<TInputImage> DuplicatorType;
107 //--------------------------------------------------------------------------
108 typedef itk::ConstNeighborhoodIterator<TInputImage> ConstNeighborhoodIterator;
109 typedef itk::ImageRegionIterator<TInputImage> RegionIterator;
110 //----------------------------------------------------------------------------
111 typedef itk::SphereSpatialFunction<> SphereType;
112 //----------------------------------------------------------------------------
113 typedef itk::ConnectedThresholdImageFilter<TInputImage, TInputImage> ConnectedFilterType;
114 //----------------------------------------------------------------------------
115 typedef itk::SubtractImageFilter<TInputImage, TInputImage> SubtractImageFilterType;
116 //----------------------------------------------------------------------------
117 typedef itk::CastImageFilter<TInputImage, TInputImage2> CastFilterType;
118 typedef itk::ConnectedComponentImageFilter<TInputImage2, TInputImage3> ConnectedComponentImageFilterType;
119 //----------------------------------------------------------------------------
121 //----------------------------------------------------------------------------
122 typedef std::vector<Edge*> EdgeVector;
123 //----------------------------------------------------------------------------
124 typedef std::queue<Vec3> Vec3Queue;
125 typedef std::vector<Vec3> Vec3List;
128 * End of typedef declaration
132 #endif /* AIRWAYSTREETYPEDEFINITION_H_ */