Commit c9122d14 authored by Julien Michel's avatar Julien Michel

BUG: Ensure that the correct resampler is used for the output

parent 6582ff5e
......@@ -247,6 +247,10 @@ private:
m_GridResampler->SetOutputSize(recomputedSize);
otbAppLogINFO( << "Output image size : " << recomputedSize );
// Output Image
SetParameterOutputImage("out", m_GridResampler->GetOutput());
}
break;
......@@ -290,6 +294,8 @@ private:
otbAppLogINFO( << "Output image size : " << recomputedSize );
m_Resampler->SetTransform(transform);
// Output Image
SetParameterOutputImage("out", m_Resampler->GetOutput());
}
break;
......@@ -420,6 +426,9 @@ private:
recomputedSize[1] = static_cast<unsigned int>(vcl_floor(vcl_abs(size[1]/OutputSpacing[1])));
m_Resampler->SetOutputSize( recomputedSize );
otbAppLogINFO( << "Output image size : " << recomputedSize );
// Output Image
SetParameterOutputImage("out", m_Resampler->GetOutput());
}
break;
}
......@@ -427,10 +436,10 @@ private:
FloatVectorImageType::PixelType defaultValue;
itk::NumericTraits<FloatVectorImageType::PixelType>::SetLength(defaultValue, inputImage->GetNumberOfComponentsPerPixel());
m_Resampler->SetEdgePaddingValue(defaultValue);
m_GridResampler->SetEdgePaddingValue(defaultValue);
m_Resampler->UpdateOutputInformation();
// Output Image
SetParameterOutputImage("out", m_Resampler->GetOutput());
m_GridResampler->UpdateOutputInformation();
}
ResampleFilterType::Pointer m_Resampler;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment