ITK  4.4.0
Insight Segmentation and Registration Toolkit
itkScalarImageToTextureFeaturesFilter.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright Insight Software Consortium
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0.txt
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  *=========================================================================*/
18 #ifndef __itkScalarImageToTextureFeaturesFilter_h
19 #define __itkScalarImageToTextureFeaturesFilter_h
20 
21 #include "itkDataObjectDecorator.h"
22 
25 
26 namespace itk
27 {
28 namespace Statistics
29 {
104 template< class TImageType,
105  class THistogramFrequencyContainer = DenseFrequencyContainer2 >
107 {
108 public:
114 
117 
119  itkNewMacro(Self);
120 
121  typedef THistogramFrequencyContainer FrequencyContainerType;
122  typedef TImageType ImageType;
123  typedef typename ImageType::Pointer ImagePointer;
124 
125  typedef typename ImageType::PixelType PixelType;
126  typedef typename ImageType::OffsetType OffsetType;
130 
133 
136 
137  typedef short TextureFeatureName;
139 
144 
147 
151 
152  const FeatureValueVectorDataObjectType * GetFeatureMeansOutput() const;
153 
154  const FeatureValueVectorDataObjectType * GetFeatureStandardDeviationsOutput() const;
155 
158  using Superclass::SetInput;
159  void SetInput(const ImageType *);
160 
161  const ImageType * GetInput() const;
162 
164  itkGetConstReferenceObjectMacro(FeatureMeans, FeatureValueVector);
165  itkGetConstReferenceObjectMacro(FeatureStandardDeviations, FeatureValueVector);
167 
169  itkSetConstObjectMacro(RequestedFeatures, FeatureNameVector);
170  itkGetConstObjectMacro(RequestedFeatures, FeatureNameVector);
172 
175  itkSetConstObjectMacro(Offsets, OffsetVector);
176  itkGetConstObjectMacro(Offsets, OffsetVector);
178 
181  void SetNumberOfBinsPerAxis(unsigned int);
182 
185  void SetPixelValueMinMax(PixelType min, PixelType max);
187 
190  void SetMaskImage(const ImageType *);
191 
192  const ImageType * GetMaskImage() const;
193 
196  void SetInsidePixelValue(PixelType InsidePixelValue);
197 
198  itkGetConstMacro(FastCalculations, bool);
199  itkSetMacro(FastCalculations, bool);
200  itkBooleanMacro(FastCalculations);
201 
202 protected:
205  void PrintSelf(std::ostream & os, Indent indent) const;
206 
207  void FastCompute();
208 
209  void FullCompute();
210 
212  virtual void GenerateData();
213 
216  using Superclass::MakeOutput;
218 
219 private:
221 
223 
229 };
230 } // end of namespace Statistics
231 } // end of namespace itk
232 
233 #ifndef ITK_MANUAL_INSTANTIATION
234 #include "itkScalarImageToTextureFeaturesFilter.hxx"
235 #endif
236 
237 #endif
238