KWStyle - itkBloxBoundaryProfileItem.txx
 
Matrix View
Description

1 DEF #ifndef __itkBloxBoundaryProfile_txx
2 HRD,DEF #define __itkBloxBoundaryProfile_txx
3
4 #include "itkBloxBoundaryProfileItem.h"
5
6 namespace itk
7 {
8 HRD template <unsigned int VImageDimension>
9 BloxBoundaryProfileItem<VImageDimension>
10 ::BloxBoundaryProfileItem()
11 HRD {
12   m_LowerIntensity = 0;
13   m_UpperIntensity = 0;
14   m_Mean = 0;
15   m_ProfileLength = 0;
16   m_MeanNormalized = 0;
17   m_StandardDeviation = 0;
18   m_StandardDeviationNormalized = 0;
19   m_BoundaryPoint = 0;
20   m_Gradient = 0;
21   m_Gradient2.Fill(0);
22 }
23
24 template <unsigned int VImageDimension>
25 BloxBoundaryProfileItem<VImageDimension>
26 ::~BloxBoundaryProfileItem()
27 {
28
29 }
30
31 template <unsigned int VImageDimension>
32 void
33 BloxBoundaryProfileItem<VImageDimension>
34 ::SetBoundaryPoint(BPItemType * point) 
35 {
36   m_BoundaryPoint = point;
37 }
38
39 template <unsigned int VImageDimension>
40 void
41 BloxBoundaryProfileItem<VImageDimension>
42 ::SetLowerIntensity(double lowerIntensity)
43 {
44   m_LowerIntensity = lowerIntensity;
45 }
46
47 template <unsigned int VImageDimension>
48 double
49 BloxBoundaryProfileItem<VImageDimension>
50 ::GetLowerIntensity(void)
51 {
52   return m_LowerIntensity;
53 }
54
55 template <unsigned int VImageDimension>
56 void
57 BloxBoundaryProfileItem<VImageDimension>
58 ::SetUpperIntensity(double upperIntensity)
59 {
60   m_UpperIntensity = upperIntensity;
61 }
62
63 template <unsigned int VImageDimension>
64 double
65 BloxBoundaryProfileItem<VImageDimension>
66 ::GetUpperIntensity(void)
67 {
68   return(m_UpperIntensity);
69 }
70
71 template <unsigned int VImageDimension>
72 void
73 BloxBoundaryProfileItem<VImageDimension>
74 ::SetMean(double mean)
75 {
76   m_Mean = mean;
77 }
78
79 template <unsigned int VImageDimension>
80 double
81 BloxBoundaryProfileItem<VImageDimension>
82 ::GetMean(void)
83 {
84   return(m_Mean);
85 }
86
87 template <unsigned int VImageDimension>
88 void 
89 BloxBoundaryProfileItem<VImageDimension>
90 ::SetProfileLength(unsigned int profileLength)
91 {
92   m_ProfileLength = profileLength;
93 }
94
95 template <unsigned int VImageDimension>
96 unsigned int
97 BloxBoundaryProfileItem<VImageDimension>
98 ::GetProfileLength(void)
99 {
100   return(m_ProfileLength);
101 }
102
103 template <unsigned int VImageDimension>
104 void
105 BloxBoundaryProfileItem<VImageDimension>
106 ::SetMeanNormalized(void)
107 {
108   m_MeanNormalized = m_Mean - m_ProfileLength/2;
109 }
110
111 template <unsigned int VImageDimension>
112 double
113 BloxBoundaryProfileItem<VImageDimension>
114 ::GetMeanNormalized(void)
115 {
116   return(m_MeanNormalized);
117 }
118
119 template <unsigned int VImageDimension>
120 void
121 BloxBoundaryProfileItem<VImageDimension>
122 ::SetStandardDeviation(double standardDeviation)
123 {
124   m_StandardDeviation = standardDeviation;
125 }
126
127 template <unsigned int VImageDimension>
128 double
129 BloxBoundaryProfileItem<VImageDimension>
130 ::GetStandardDeviation(void)
131 {
132   return(m_StandardDeviation);
133 }
134
135 template <unsigned int VImageDimension>
136 void
137 BloxBoundaryProfileItem<VImageDimension>
138 ::SetStandardDeviationNormalized(void)
139 {
140   m_StandardDeviationNormalized = m_StandardDeviation / m_ProfileLength;
141 }
142
143 template <unsigned int VImageDimension>
144 double
145 BloxBoundaryProfileItem<VImageDimension>
146 ::GetStandardDeviationNormalized(void)
147 {
148   return(m_StandardDeviationNormalized);
149 }
150
151 template <unsigned int VImageDimension>
152 void
153 BloxBoundaryProfileItem<VImageDimension>
154 LEN ::SetOptimalBoundaryLocation(VectorType spatialFunctionOriginVector, VectorType orientation)
155 {
156   VectorType optimalBoundaryLocation;
157   optimalBoundaryLocation = m_MeanNormalized * orientation;
158 LEN   optimalBoundaryLocation = spatialFunctionOriginVector + optimalBoundaryLocation;
159   for(unsigned int i = 0; i < VImageDimension; i++)
160     m_OptimalBoundaryLocation[i] = optimalBoundaryLocation[i];
161 }
162
163 template <unsigned int VImageDimension>
164 typename BloxBoundaryProfileItem<VImageDimension>::PositionType
165 BloxBoundaryProfileItem<VImageDimension>
166 ::GetOptimalBoundaryLocation(void)
167 {
168   return(m_OptimalBoundaryLocation);
169 }
170
171 template <unsigned int VImageDimension>
172 void
173 BloxBoundaryProfileItem<VImageDimension>
174 ::SetGradient(GradientType * gradient)
175 {
176   m_Gradient = gradient;
177 }
178
179 template <unsigned int VImageDimension>
180 typename BloxBoundaryProfileItem<VImageDimension>::GradientType *
181 BloxBoundaryProfileItem<VImageDimension>
182 ::GetGradient()
183 {
184   return(m_Gradient);
185 }
186
187 // end namespace itk
188
189 #endif
190
191 EOF

Generated by KWStyle 1.0b on Tuesday January,17 at 02:14:00PM
© Kitware Inc.