From de3a323154deea6b609bc7cceb46e338ad79ba2e Mon Sep 17 00:00:00 2001 From: remi cresson <remi.cresson@teledetection.fr> Date: Thu, 3 Aug 2017 08:39:15 +0000 Subject: [PATCH] REFAC: remove binary functor image filter from include. Use external remote module TimeSeriesUtils --- include/otbBinaryFunctorImageFilter.h | 84 --------------------------- otb-module.cmake | 7 ++- 2 files changed, 4 insertions(+), 87 deletions(-) delete mode 100644 include/otbBinaryFunctorImageFilter.h diff --git a/include/otbBinaryFunctorImageFilter.h b/include/otbBinaryFunctorImageFilter.h deleted file mode 100644 index 6f0bf16..0000000 --- a/include/otbBinaryFunctorImageFilter.h +++ /dev/null @@ -1,84 +0,0 @@ -/*========================================================================= - - Program: ORFEO Toolbox - Language: C++ - Date: $Date$ - Version: $Revision$ - - - Copyright (c) Centre National d'Etudes Spatiales. All rights reserved. - See OTBCopyright.txt for details. - - - This software is distributed WITHOUT ANY WARRANTY; without even - the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR - PURPOSE. See the above copyright notices for more information. - -=========================================================================*/ -#ifndef otbBinaryFunctorImageFilter_h -#define otbBinaryFunctorImageFilter_h - -#include "itkBinaryFunctorImageFilter.h" - -namespace otb -{ -/** - * \class BinaryFunctorImageFilter - * \brief Implements pixel-wise generic operation on two images. - * - * Add the capability to change the number of channel when operation on - * VectorImage compared to the itk::BinaryFunctorImageFilter - * - * The number of channel is provided by the functor: TFunction::OutputSize. If - * this number is lower or equal to zero, the behavior of the itk::BinaryFunctorImageFilter - * remains unchanged. - * - * \sa itk::BinaryFunctorImageFilter - * - * \ingroup OTBCommon - */ -template <class TInputImage1, class TInputImage2, class TOutputImage, class TFunction> -class ITK_EXPORT BinaryFunctorImageFilter : public itk::BinaryFunctorImageFilter<TInputImage1, TInputImage2, TOutputImage, TFunction> -{ -public: - /** Standard class typedefs. */ - typedef BinaryFunctorImageFilter Self; - typedef itk::BinaryFunctorImageFilter<TInputImage1, TInputImage2, TOutputImage, TFunction> Superclass; - typedef itk::SmartPointer<Self> Pointer; - typedef itk::SmartPointer<const Self> ConstPointer; - - /** Method for creation through the object factory. */ - itkNewMacro(Self); - - /** Run-time type information (and related methods). */ - itkTypeMacro(BinaryFunctorImageFilter, itk::BinaryFunctorImageFilter); - -protected: - BinaryFunctorImageFilter() {}; - ~BinaryFunctorImageFilter() ITK_OVERRIDE {} - - /** BinaryFunctorImageFilter can produce an image which has a different number of bands - * than its input image. As such, BinaryFunctorImageFilter - * needs to provide an implementation for - * GenerateOutputInformation() in order to inform the pipeline - * execution model. The original documentation of this method is - * below. - * - * \sa ProcessObject::GenerateOutputInformaton() */ - void GenerateOutputInformation() ITK_OVERRIDE - { - Superclass::GenerateOutputInformation(); - typename Superclass::OutputImagePointer outputPtr = this->GetOutput(); - outputPtr->SetNumberOfComponentsPerPixel( // propagate vector length info - this->GetFunctor().GetOutputSize()); - } - -private: - BinaryFunctorImageFilter(const Self &); //purposely not implemented - void operator =(const Self&); //purposely not implemented - -}; - -} // end namespace otb - -#endif diff --git a/otb-module.cmake b/otb-module.cmake index 0748597..31d9f2e 100644 --- a/otb-module.cmake +++ b/otb-module.cmake @@ -2,10 +2,11 @@ set(DOCUMENTATION "Clear Cuts Detection") otb_module(ClearCutsDetection DEPENDS - Mosaic - OTBIndices - OTBStatistics + Mosaic + OTBIndices + OTBStatistics OTBIOXML + TimeSeriesUtils TEST_DEPENDS OTBTestKernel -- GitLab