[Vv] clitkResampleImage
Benoît Presles
benoit.presles at u-bourgogne.fr
Tue Jul 25 16:19:21 CEST 2017
Hello Thomas,
Thanks for your reply. In the meantime, I am going to use
clitkAffineTransform transform.
If clitkResampleImage is not maintained anymore, you should delete it.
Best regards,
Ben
Le 25/07/2017 à 14:53, Thomas BAUDIER a écrit :
> Hi Benoit,
>
> I have no idea, I'll talk to Simon and David after holidays.
>
> Just one thing. Usually, we use to use clitkAffineTransform even to
> resample.
> In your case, you can do clitkAffineTransform -i result.nii -l
> SUVImg.nii -o resampleCLITK.nii
> and the output origin is the same than SUVImg.nii image.
>
> Best
> Thomas
>
> On 2017-07-24 18:38, Benoît Presles wrote:
>> Dear vv users,
>>
>> When I use clitkResampleImage to resample the image result.nii like
>> the image SUVImg.nii (clitkResampleImage -i result.nii -l SUVImg.nii
>> -o resampleCLITK.nii), the origin of the resampleCLITK image is not
>> the same as the SUVImg image
>> (https://cloud.u-bourgogne.fr/index.php/s/LMzrtE1HvegjIaY).
>> I did not expect this behaviour especially with the "like option".
>>
>> It is because line 231 in clitkResampleImageWithOptionsFilter.txx, you
>> modify the output origin:
>> // Compute origin based on image corner
>> for(unsigned int i=0; i<OutputImageType::ImageDimension; i++) {
>> m_OutputOrigin[i] -= 0.5 * input->GetSpacing()[i];
>> m_OutputOrigin[i] += 0.5 * m_OutputSpacing[i];
>> }
>>
>> Is there any reason?
>>
>>
>> Thanks for your help,
>> Cheers,
>> Ben
>>
>> _______________________________________________
>> vv mailing list
>> vv at creatis.insa-lyon.fr
>> http://www.creatis.insa-lyon.fr/mailman/listinfo/vv
> _______________________________________________
> vv mailing list
> vv at creatis.insa-lyon.fr
> http://www.creatis.insa-lyon.fr/mailman/listinfo/vv
More information about the vv
mailing list