Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Jialin Wang
otb
Commits
c9122d14
Commit
c9122d14
authored
Jun 06, 2016
by
Julien Michel
Browse files
BUG: Ensure that the correct resampler is used for the output
parent
6582ff5e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Modules/Applications/AppProjection/app/otbRigidTransformResample.cxx
View file @
c9122d14
...
...
@@ -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
;
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment