13 #ifndef itkLocalIntensityFilter_h
14 #define itkLocalIntensityFilter_h
16 #include "itkImageToImageFilter.h"
17 #include "itkNumericTraits.h"
19 #include "itkSimpleDataObjectDecorator.h"
24 template<
typename TInputImage >
26 public ImageToImageFilter< TInputImage, TInputImage >
31 typedef ImageToImageFilter< TInputImage, TInputImage >
Superclass;
45 typedef typename TInputImage::SizeType
SizeType;
49 typedef Image<unsigned short, TInputImage::ImageDimension>
MaskImageType;
53 TInputImage::ImageDimension);
56 typedef typename NumericTraits< PixelType >::RealType
RealType;
68 return this->GetLocalPeakOutput()->Get();
77 return this->GetGlobalPeakOutput()->Get();
86 return this->GetLocalMaximumOutput()->Get();
92 void SetMask(
typename MaskImageType::Pointer mask)
97 itkSetMacro(Range,
double);
98 itkGetMacro(Range,
double);
99 itkGetConstMacro(Range,
double);
104 using Superclass::MakeOutput;
107 #ifdef ITK_USE_CONCEPT_CHECKING
109 itkConceptMacro(InputHasNumericTraitsCheck,
110 (Concept::HasNumericTraits< PixelType >));
117 void PrintSelf(std::ostream & os, Indent indent)
const ITK_OVERRIDE;
125 void BeforeThreadedGenerateData() ITK_OVERRIDE;
129 void AfterThreadedGenerateData() ITK_OVERRIDE;
133 outputRegionForThread,
134 ThreadIdType threadId) ITK_OVERRIDE;
137 void GenerateInputRequestedRegion() ITK_OVERRIDE;
140 void EnlargeOutputRequestedRegion(DataObject *data) ITK_OVERRIDE;
145 Array<
RealType > m_ThreadLocalMaximum;
146 Array<
RealType > m_ThreadLocalPeakValue;
147 Array<
RealType > m_ThreadGlobalPeakValue;
153 #ifndef ITK_MANUAL_INSTANTIATION
154 #include "itkLocalIntensityFilter.hxx"
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