X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=itk%2FclitkResampleImageWithOptionsFilter.txx;h=4c949cec33eff1ade7b4fe43cfac3f4bf313a1fe;hb=7ae042efea7b958dc573948b4e27981bafa9957e;hp=e009e38ccd1a292ffcfc116227d8a6950dbf539d;hpb=5f090df454afc7ec25cb1db1c1006294e2fd0c3f;p=clitk.git diff --git a/itk/clitkResampleImageWithOptionsFilter.txx b/itk/clitkResampleImageWithOptionsFilter.txx index e009e38..4c949ce 100644 --- a/itk/clitkResampleImageWithOptionsFilter.txx +++ b/itk/clitkResampleImageWithOptionsFilter.txx @@ -229,10 +229,9 @@ GenerateData() } // Compute origin based on image corner - typename FilterType::OriginPointType origin = input->GetOrigin(); for(unsigned int i=0; iGetSpacing()[i]; - origin[i] += 0.5 * m_OutputSpacing[i]; + m_OutputOrigin[i] -= 0.5 * input->GetSpacing()[i]; + m_OutputOrigin[i] += 0.5 * m_OutputSpacing[i]; } // Instance of the transform object to be passed to the resample