OTB  9.0.0
Orfeo Toolbox
otbCloudDetectionFunctor.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 otbCloudDetectionFunctor_h
22 #define otbCloudDetectionFunctor_h
23 
25 
26 namespace otb
27 {
34 namespace Functor
35 {
36 template <class TInput, class TOutputValue>
38 {
39 public:
41 
43  {
44  m_MinThreshold = 0.0;
45  m_MaxThreshold = 1.0;
46  }
47 
49  {
50  }
51  inline TOutputValue operator()(const TInput& inPix)
52  {
54  {
55  return 1;
56  }
57  else
58  {
59  return 0;
60  }
61  }
62 
63  void SetReferencePixel(TInput ref)
64  {
66  }
67  void SetVariance(double variance)
68  {
70  }
71  void SetMinThreshold(double threshold)
72  {
73  m_MinThreshold = threshold;
74  }
75  void SetMaxThreshold(double threshold)
76  {
77  m_MaxThreshold = threshold;
78  }
79  double GetMinThreshold()
80  {
81  return m_MinThreshold;
82  }
83  double GetMaxThreshold()
84  {
85  return m_MaxThreshold;
86  }
87  double GetVariance()
88  {
90  }
92  {
94  }
95 
96 protected:
100 };
101 
102 } // end namespace functor
103 } // end namespace otb
104 
105 #endif
otb::Functor::CloudDetectionFunctor::operator()
TOutputValue operator()(const TInput &inPix)
Definition: otbCloudDetectionFunctor.h:51
otb::Functor::CloudEstimatorFunctor::GetReferencePixel
TInput GetReferencePixel() const
Definition: otbCloudEstimatorFunctor.h:100
otb::Functor::CloudDetectionFunctor::m_CloudEstimatorFunctor
CloudEstimatorFunctorType m_CloudEstimatorFunctor
Definition: otbCloudDetectionFunctor.h:97
otb::Functor::CloudDetectionFunctor::CloudEstimatorFunctorType
CloudEstimatorFunctor< TInput, TOutputValue > CloudEstimatorFunctorType
Definition: otbCloudDetectionFunctor.h:40
otb::Functor::CloudDetectionFunctor::SetVariance
void SetVariance(double variance)
Definition: otbCloudDetectionFunctor.h:67
otb::Functor::CloudDetectionFunctor::CloudDetectionFunctor
CloudDetectionFunctor()
Definition: otbCloudDetectionFunctor.h:42
otb::Functor::CloudDetectionFunctor::GetMaxThreshold
double GetMaxThreshold()
Definition: otbCloudDetectionFunctor.h:83
otb::Functor::CloudDetectionFunctor::m_MaxThreshold
double m_MaxThreshold
Definition: otbCloudDetectionFunctor.h:99
otb::Functor::CloudDetectionFunctor::SetMaxThreshold
void SetMaxThreshold(double threshold)
Definition: otbCloudDetectionFunctor.h:75
otb
The "otb" namespace contains all Orfeo Toolbox (OTB) classes.
Definition: otbJoinContainer.h:32
otb::Functor::CloudDetectionFunctor::GetMinThreshold
double GetMinThreshold()
Definition: otbCloudDetectionFunctor.h:79
otb::Functor::CloudDetectionFunctor::GetVariance
double GetVariance()
Definition: otbCloudDetectionFunctor.h:87
otb::Functor::CloudEstimatorFunctor
Functor to help with the cloud detection.
Definition: otbCloudEstimatorFunctor.h:41
otb::Functor::CloudDetectionFunctor::SetReferencePixel
void SetReferencePixel(TInput ref)
Definition: otbCloudDetectionFunctor.h:63
otb::Functor::CloudDetectionFunctor::~CloudDetectionFunctor
virtual ~CloudDetectionFunctor()
Definition: otbCloudDetectionFunctor.h:48
otb::Functor::CloudDetectionFunctor::m_MinThreshold
double m_MinThreshold
Definition: otbCloudDetectionFunctor.h:98
otb::Functor::CloudDetectionFunctor
Definition: otbCloudDetectionFunctor.h:37
otb::Functor::CloudDetectionFunctor::SetMinThreshold
void SetMinThreshold(double threshold)
Definition: otbCloudDetectionFunctor.h:71
otb::Functor::CloudEstimatorFunctor::SetReferencePixel
void SetReferencePixel(TInput ref)
Definition: otbCloudEstimatorFunctor.h:81
otb::Functor::CloudEstimatorFunctor::SetVariance
void SetVariance(double variance)
Definition: otbCloudEstimatorFunctor.h:94
otb::Functor::CloudEstimatorFunctor::GetVariance
double GetVariance() const
Definition: otbCloudEstimatorFunctor.h:104
otb::Functor::CloudDetectionFunctor::GetReferencePixel
TInput GetReferencePixel()
Definition: otbCloudDetectionFunctor.h:91
otbCloudEstimatorFunctor.h