Skip to content
Snippets Groups Projects
Commit 907cb3a1 authored by Otmane Lahlou's avatar Otmane Lahlou
Browse files

ENH : replace ImageAdapter with ImageAdaptor

parent 4e0bb52c
No related branches found
No related tags found
No related merge requests found
...@@ -30,7 +30,7 @@ ...@@ -30,7 +30,7 @@
#include "otbDescriptorsListSampleGenerator.h" #include "otbDescriptorsListSampleGenerator.h"
#include "otbImageFileReader.h" #include "otbImageFileReader.h"
#include "otbVectorDataFileReader.h" #include "otbVectorDataFileReader.h"
#include "otbImageFunctionAdapter.h" #include "otbImageFunctionAdaptor.h"
const unsigned int Dimension = 2; const unsigned int Dimension = 2;
typedef int LabelType; typedef int LabelType;
...@@ -41,8 +41,8 @@ typedef double CoordRepType; ...@@ -41,8 +41,8 @@ typedef double CoordRepType;
typedef otb::Image<PixelType, Dimension> ImageType; typedef otb::Image<PixelType, Dimension> ImageType;
typedef otb::VectorData<> VectorDataType; typedef otb::VectorData<> VectorDataType;
typedef otb::RadiometricMomentsImageFunction<ImageType, CoordRepType> FunctionType; typedef otb::RadiometricMomentsImageFunction<ImageType, CoordRepType> FunctionType;
typedef otb::ImageFunctionAdapter typedef otb::ImageFunctionAdaptor
<ImageType,FunctionType> AdapatedFunctionType; <FunctionType> AdapatedFunctionType;
//typedef FunctionType::OutputType SampleType; //typedef FunctionType::OutputType SampleType;
typedef itk::VariableLengthVector<CoordRepType> SampleType; typedef itk::VariableLengthVector<CoordRepType> SampleType;
...@@ -134,7 +134,7 @@ int otbDescriptorsListSampleGenerator(int argc, char* argv[]) ...@@ -134,7 +134,7 @@ int otbDescriptorsListSampleGenerator(int argc, char* argv[])
AdapatedFunctionType::Pointer descriptorsFunction = AdapatedFunctionType::New(); AdapatedFunctionType::Pointer descriptorsFunction = AdapatedFunctionType::New();
descriptorsFunction->SetInputImage(imageReader->GetOutput()); descriptorsFunction->SetInputImage(imageReader->GetOutput());
descriptorsFunction->GetImageFunction()->SetNeighborhoodRadius(5); descriptorsFunction->GetInternalImageFunction()->SetNeighborhoodRadius(5);
DescriptorsListSampleGeneratorType::Pointer descriptorsGenerator = DescriptorsListSampleGeneratorType::New(); DescriptorsListSampleGeneratorType::Pointer descriptorsGenerator = DescriptorsListSampleGeneratorType::New();
descriptorsGenerator->SetInputImage(imageReader->GetOutput()); descriptorsGenerator->SetInputImage(imageReader->GetOutput());
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment