NifTK  16.4.1 - 0798f20
CMIC's Translational Medical Imaging Platform
itkBinariseVesselResponseFilter.h
Go to the documentation of this file.
1 /*=============================================================================
2 
3  NifTK: A software platform for medical image computing.
4 
5  Copyright (c) University College London (UCL). All rights reserved.
6 
7  This software is distributed WITHOUT ANY WARRANTY; without even
8  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
9  PURPOSE.
10 
11  See LICENSE.txt in the top level directory for details.
12 
13 =============================================================================*/
14 
15 #ifndef ITKBINARISEVESSELRESPONSEFILTER_H
16 #define ITKBINARISEVESSELRESPONSEFILTER_H
17 
18 #include <itkImageToImageFilter.h>
19 #include <itkMacro.h>
20 #include <itkRelabelComponentImageFilter.h>
21 #include <itkConnectedThresholdImageFilter.h>
22 #include <itkNormalizeImageFilter.h>
23 #include <itkBinaryThresholdImageFilter.h>
24 
25 namespace itk {
29 template < class TInputImage, class TOutputImage >
30 class ITK_EXPORT BinariseVesselResponseFilter :
31  public ImageToImageFilter< TInputImage, TOutputImage >
32 {
33 public:
36  typedef ImageToImageFilter<TInputImage,TOutputImage> Superclass;
37  typedef SmartPointer<Self> Pointer;
38  typedef SmartPointer<const Self> ConstPointer;
39 
41  itkNewMacro(Self);
42 
44  itkTypeMacro(BinariseVesselResponseFilter, ImageToImageFilter);
45 
46  itkStaticConstMacro(ImageDimension, unsigned int, TInputImage::ImageDimension);
47 
49  typedef typename Superclass::InputImageType InputImageType;
50  typedef typename Superclass::OutputImageType OutputImageType;
51  typedef typename Superclass::InputImagePointer InputImagePointer;
52  typedef typename Superclass::OutputImagePointer OutputImagePointer;
53  typedef typename Superclass::InputImageConstPointer InputImageConstPointer;
56 
57  itkGetConstMacro(LowThreshold, InputPixelType);
58  itkGetConstMacro(UpThreshold, InputPixelType);
59  itkGetConstMacro(Percentage, float);
60  itkSetMacro(LowThreshold, InputPixelType);
61  itkSetMacro(UpThreshold, InputPixelType);
62  itkSetMacro(Percentage, float);
63 
64 protected:
67  void PrintSelf(std::ostream&os, Indent indent) const;
68 
70  virtual void GenerateData();
71 
72  typedef double InternalPixelType;
74  typedef itk::NormalizeImageFilter< InputImageType,
75  InternalImageType >NormalizerType;
76  typedef itk::BinaryThresholdImageFilter< InternalImageType, OutputImageType > ThresholdFilter;
77  typedef itk::BinaryThresholdImageFilter <OutputImageType,
79  typedef itk::ConnectedComponentImageFilter <OutputImageType, OutputImageType >
81  typedef itk::RelabelComponentImageFilter<OutputImageType, OutputImageType > RelabelFilterType;
82 
83 private:
84  BinariseVesselResponseFilter(const Self&); //purposely not implemented
85  void operator=(const Self&); //purposely not implemented
86 
87  InputPixelType m_LowThreshold;
88  InputPixelType m_UpThreshold;
89  float m_Percentage;
90 };
91 
92 } //end namespace
93 
94 #ifndef ITK_MANUAL_INSTANTIATION
95 #include "itkBinariseVesselResponseFilter.txx"
96 #endif
97 
98 #endif // ITKBINARISEVESSELRESPONSEFILTER_H
itk::BinaryThresholdImageFilter< OutputImageType, OutputImageType > BinaryLabelThresholdImageFilterType
Definition: itkBinariseVesselResponseFilter.h:78
itk::ConnectedComponentImageFilter< OutputImageType, OutputImageType > ConnectedComponentImageFilterType
Definition: itkBinariseVesselResponseFilter.h:80
Binarises the vesselness response and keeps the largest objects.
Definition: itkBinariseVesselResponseFilter.h:30
Superclass::InputImagePointer InputImagePointer
Definition: itkBinariseVesselResponseFilter.h:51
SmartPointer< const Self > ConstPointer
Definition: itkBinariseVesselResponseFilter.h:38
Superclass::OutputImageType OutputImageType
Definition: itkBinariseVesselResponseFilter.h:50
BinariseVesselResponseFilter Self
Definition: itkBinariseVesselResponseFilter.h:35
ImageToImageFilter< TInputImage, TOutputImage > Superclass
Definition: itkBinariseVesselResponseFilter.h:36
Definition: niftkITKAffineResampleImage.cxx:74
Superclass::InputImageType InputImageType
Definition: itkBinariseVesselResponseFilter.h:49
itk::RelabelComponentImageFilter< OutputImageType, OutputImageType > RelabelFilterType
Definition: itkBinariseVesselResponseFilter.h:81
~BinariseVesselResponseFilter()
Definition: itkBinariseVesselResponseFilter.h:66
float PixelType
Definition: niftkBreastDCEandADC.cxx:88
Superclass::OutputImagePointer OutputImagePointer
Definition: itkBinariseVesselResponseFilter.h:52
InputImageType::PixelType InputPixelType
Definition: itkBinariseVesselResponseFilter.h:54
Superclass::InputImageConstPointer InputImageConstPointer
Definition: itkBinariseVesselResponseFilter.h:53
OutputImageType::PixelType OutputPixelType
Definition: itkBinariseVesselResponseFilter.h:55
Image< InternalPixelType, ImageDimension > InternalImageType
Definition: itkBinariseVesselResponseFilter.h:73
Simultaneous itk::Image and itk::Array (and hence vnl_vector) class.
double InternalPixelType
Definition: itkBinariseVesselResponseFilter.h:72
itk::NormalizeImageFilter< InputImageType, InternalImageType > NormalizerType
Definition: itkBinariseVesselResponseFilter.h:75
itk::BinaryThresholdImageFilter< InternalImageType, OutputImageType > ThresholdFilter
Definition: itkBinariseVesselResponseFilter.h:76
SmartPointer< Self > Pointer
Definition: itkBinariseVesselResponseFilter.h:37