13 #ifndef itkLocalIntensityFilter_h
14 #define itkLocalIntensityFilter_h
16 #include <itkImageToImageFilter.h>
17 #include <itkNumericTraits.h>
19 #include <itkSimpleDataObjectDecorator.h>
34 template<
typename TInputImage >
36 public ImageToImageFilter< TInputImage, TInputImage >
41 typedef ImageToImageFilter< TInputImage, TInputImage >
Superclass;
55 typedef typename TInputImage::SizeType
SizeType;
59 typedef Image<unsigned short, TInputImage::ImageDimension>
MaskImageType;
63 TInputImage::ImageDimension);
66 typedef typename NumericTraits< PixelType >::RealType
RealType;
78 return this->GetLocalPeakOutput()->Get();
87 return this->GetGlobalPeakOutput()->Get();
96 return this->GetLocalMaximumOutput()->Get();
102 void SetMask(
typename MaskImageType::Pointer mask)
107 itkSetMacro(Range,
double);
108 itkGetMacro(Range,
double);
109 itkGetConstMacro(Range,
double);
114 using Superclass::MakeOutput;
117 #ifdef ITK_USE_CONCEPT_CHECKING
119 itkConceptMacro(InputHasNumericTraitsCheck,
120 (Concept::HasNumericTraits< PixelType >));
127 void PrintSelf(std::ostream & os, Indent indent)
const ITK_OVERRIDE;
135 void BeforeThreadedGenerateData() ITK_OVERRIDE;
139 void AfterThreadedGenerateData() ITK_OVERRIDE;
143 outputRegionForThread,
144 ThreadIdType threadId) ITK_OVERRIDE;
147 void GenerateInputRequestedRegion() ITK_OVERRIDE;
150 void EnlargeOutputRequestedRegion(DataObject *data) ITK_OVERRIDE;
155 Array<
RealType > m_ThreadLocalMaximum;
156 Array<
RealType > m_ThreadLocalPeakValue;
157 Array<
RealType > m_ThreadGlobalPeakValue;
163 #ifndef ITK_MANUAL_INSTANTIATION
164 #include <itkLocalIntensityFilter.tpp>
Computes local and global intensity peak features within a spherical neighbourhood.
RealType GetLocalMaximum() const
TInputImage::SizeType SizeType
TInputImage::RegionType RegionType
DataObject::Pointer DataObjectPointer
RealType GetGlobalPeak() const
TInputImage::PixelType PixelType
TInputImage::Pointer InputImagePointer
ImageToImageFilter< TInputImage, TInputImage > Superclass
SmartPointer< const Self > ConstPointer
const RealObjectType * GetLocalMaximumOutput() const
const RealObjectType * GetGlobalPeakOutput() const
RealObjectType * GetGlobalPeakOutput()
Image< unsigned short, TInputImage::ImageDimension > MaskImageType
void SetMask(typename MaskImageType::Pointer mask)
DataObjectPointer MakeOutput(DataObjectPointerArraySizeType idx) ITK_OVERRIDE
itkStaticConstMacro(ImageDimension, unsigned int, TInputImage::ImageDimension)
NumericTraits< PixelType >::RealType RealType
RealType GetLocalPeak() const
~LocalIntensityFilter() ITK_OVERRIDE
LocalIntensityFilter Self
SmartPointer< Self > Pointer
TInputImage::IndexType IndexType
void PrintSelf(std::ostream &os, Indent indent) const ITK_OVERRIDE
SimpleDataObjectDecorator< RealType > RealObjectType
void AllocateOutputs() ITK_OVERRIDE
SimpleDataObjectDecorator< PixelType > PixelObjectType
RealObjectType * GetLocalMaximumOutput()
const RealObjectType * GetLocalPeakOutput() const
RealObjectType * GetLocalPeakOutput()
ProcessObject::DataObjectPointerArraySizeType DataObjectPointerArraySizeType