From: dsarrut Date: Wed, 15 Dec 2010 08:54:02 +0000 (+0000) Subject: add enlarge capability X-Git-Tag: v1.2.0~283 X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=commitdiff_plain;h=04b38827ad4a4c82553f01cfe62adc4abb19400a;p=clitk.git add enlarge capability --- diff --git a/tools/clitkCropImage.ggo b/tools/clitkCropImage.ggo index 01a19b3..4931b5b 100755 --- a/tools/clitkCropImage.ggo +++ b/tools/clitkCropImage.ggo @@ -25,6 +25,8 @@ option "BG" - "Background value in input." double default="0" no section "Crop like another image" option "like" - "Crop like this image (must have the same spacing" string no +option "BGLike" - "Background value in output (if like larger)" double default="0" no + diff --git a/tools/clitkCropImageGenericFilter.txx b/tools/clitkCropImageGenericFilter.txx index 89aeabc..8d2a239 100755 --- a/tools/clitkCropImageGenericFilter.txx +++ b/tools/clitkCropImageGenericFilter.txx @@ -25,7 +25,7 @@ clitk::CropImageGenericFilter::CropImageGenericFilter(): { // Default values cmdline_parser_clitkCropImage_init(&mArgsInfo); - //InitializeImageType<2>(); + InitializeImageType<2>(); InitializeImageType<3>(); InitializeImageType<4>(); } @@ -106,6 +106,7 @@ void clitk::CropImageGenericFilter::UpdateWithInputImageType() typename FilterType::Pointer filter = FilterType::New(); filter->SetInput(input); filter->SetCropLikeFilename(mArgsInfo.like_arg); + filter->SetBackgroundValue(mArgsInfo.BGLike_arg); filter->Update(); output = filter->GetOutput(); }