OTB  9.0.0
Orfeo Toolbox
otbKeyPointDensityImageFilter.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2005-2022 Centre National d'Etudes Spatiales (CNES)
3  *
4  * This file is part of Orfeo Toolbox
5  *
6  * https://www.orfeo-toolbox.org/
7  *
8  * Licensed under the Apache License, Version 2.0 (the "License");
9  * you may not use this file except in compliance with the License.
10  * You may obtain a copy of the License at
11  *
12  * http://www.apache.org/licenses/LICENSE-2.0
13  *
14  * Unless required by applicable law or agreed to in writing, software
15  * distributed under the License is distributed on an "AS IS" BASIS,
16  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17  * See the License for the specific language governing permissions and
18  * limitations under the License.
19  */
20 
21 #ifndef otbKeyPointDensityImageFilter_h
22 #define otbKeyPointDensityImageFilter_h
23 
24 #include "itkImageToImageFilter.h"
26 #include "itkNumericTraits.h"
27 
28 namespace otb
29 {
30 
48 template <class TInputImage, class TOutputImage, class TDetector>
49 class ITK_EXPORT KeyPointDensityImageFilter : public itk::ImageToImageFilter<TInputImage, TOutputImage>
50 {
51 
52 public:
55  typedef itk::ImageToImageFilter<TInputImage, TOutputImage> Superclass;
56  typedef itk::SmartPointer<Self> Pointer;
57  typedef itk::SmartPointer<const Self> ConstPointer;
58 
60  itkNewMacro(Self);
61 
63  itkTypeMacro(KeyPointDensityImageFilter, itk::ImageToImageFilter);
64 
66  typedef TInputImage InputImageType;
67  typedef typename InputImageType::Pointer InputImagePointerType;
68 
70  typedef TOutputImage OutputImageType;
71  typedef typename OutputImageType::Pointer OutputImagePointerType;
72 
74  typedef TDetector DetectorType;
75  typedef typename DetectorType::OutputPointSetType PointSetType;
76  typedef typename DetectorType::Pointer DetectorPointerType;
77 
81 
84  itkSetMacro(NeighborhoodRadius, unsigned int);
85  itkGetConstReferenceMacro(NeighborhoodRadius, unsigned int);
87 
89  virtual void SetDetector(DetectorType* detector);
90  virtual DetectorType* GetDetector();
92 
93 protected:
98 
102  ~KeyPointDensityImageFilter() override;
103 
107  void PrintSelf(std::ostream& os, itk::Indent indent) const override;
108 
112  // virtual void ThreadedGenerateData(const OutputImageRegionType& outputRegionForThread, itk::ThreadIdType threadId );
113  void GenerateData() override;
115 
116 private:
117  KeyPointDensityImageFilter(const Self&) = delete;
118  void operator=(const Self&) = delete;
119 
122  unsigned int m_NeighborhoodRadius;
123 };
124 }
125 #ifndef OTB_MANUAL_INSTANTIATION
127 #endif
128 
129 #endif
otb::KeyPointDensityImageFilter::m_PointSetToDensityImageFilter
PointSetToDensityImagePointerType m_PointSetToDensityImageFilter
Definition: otbKeyPointDensityImageFilter.h:121
otb::KeyPointDensityImageFilter::Pointer
itk::SmartPointer< Self > Pointer
Definition: otbKeyPointDensityImageFilter.h:56
otb::KeyPointDensityImageFilter::PointSetToDensityImagePointerType
PointSetToDensityImageType::Pointer PointSetToDensityImagePointerType
Definition: otbKeyPointDensityImageFilter.h:80
otb::KeyPointDensityImageFilter::InputImageType
TInputImage InputImageType
Definition: otbKeyPointDensityImageFilter.h:63
otb::PointSetToDensityImageFilter
Draw the density of a point set on an image.
Definition: otbPointSetToDensityImageFilter.h:40
otb::PointSetToDensityImageFilter::Pointer
itk::SmartPointer< Self > Pointer
Definition: otbPointSetToDensityImageFilter.h:47
otb::KeyPointDensityImageFilter::DetectorPointerType
DetectorType::Pointer DetectorPointerType
Definition: otbKeyPointDensityImageFilter.h:76
otb::KeyPointDensityImageFilter::OutputImageType
TOutputImage OutputImageType
Definition: otbKeyPointDensityImageFilter.h:70
otbKeyPointDensityImageFilter.hxx
otb
The "otb" namespace contains all Orfeo Toolbox (OTB) classes.
Definition: otbJoinContainer.h:32
otb::KeyPointDensityImageFilter::m_Detector
DetectorPointerType m_Detector
Definition: otbKeyPointDensityImageFilter.h:120
otb::KeyPointDensityImageFilter::OutputImagePointerType
OutputImageType::Pointer OutputImagePointerType
Definition: otbKeyPointDensityImageFilter.h:71
otb::KeyPointDensityImageFilter::ConstPointer
itk::SmartPointer< const Self > ConstPointer
Definition: otbKeyPointDensityImageFilter.h:57
otb::KeyPointDensityImageFilter
This class computes the density of the characteristic points detected in the image.
Definition: otbKeyPointDensityImageFilter.h:49
otb::KeyPointDensityImageFilter::Self
KeyPointDensityImageFilter Self
Definition: otbKeyPointDensityImageFilter.h:54
otb::KeyPointDensityImageFilter::m_NeighborhoodRadius
unsigned int m_NeighborhoodRadius
Definition: otbKeyPointDensityImageFilter.h:122
otbPointSetToDensityImageFilter.h
otb::KeyPointDensityImageFilter::PointSetToDensityImageType
otb::PointSetToDensityImageFilter< PointSetType, OutputImageType > PointSetToDensityImageType
Definition: otbKeyPointDensityImageFilter.h:79
otb::KeyPointDensityImageFilter::PointSetType
DetectorType::OutputPointSetType PointSetType
Definition: otbKeyPointDensityImageFilter.h:75
otb::KeyPointDensityImageFilter::DetectorType
TDetector DetectorType
Definition: otbKeyPointDensityImageFilter.h:74
otb::KeyPointDensityImageFilter::InputImagePointerType
InputImageType::Pointer InputImagePointerType
Definition: otbKeyPointDensityImageFilter.h:67
otb::KeyPointDensityImageFilter::Superclass
itk::ImageToImageFilter< TInputImage, TOutputImage > Superclass
Definition: otbKeyPointDensityImageFilter.h:55