[Insight-users] resampler

Stefan Klein stefan at isi.uu.nl
Thu May 4 03:27:47 EDT 2006


Hi Luis,

Thanks for the changes!

>As a general practice it doesn't seem right to overpopulate the
>Resample filter all the transforms available in ITK. We probably
>can add a "Trait" to the transform for defining when they are
>"Linear", and  allowing the ResampleImageFilter to decide what

I agree with this. Adding a method "bool IsLinear(void) {return 
true/false;}" to every transform would do the trick, right?

Regards,
Stefan.


At 16:56 02/05/06, Luis Ibanez wrote:
>Hi Marius,
>
>Thanks for pointing this out.
>
>Actually the if/else-if style is discouraged in the coding style of ITK,
>so I replaced with full "if" statements and each one with its respective
>return.
>
>Note that there are other transforms that will qualify as "linear" and
>are not included here yet.  In particular the Scale transform and the
>VersorTransform. They are less commonly used...though.
>
>As a general practice it doesn't seem right to overpopulate the
>Resample filter all the transforms available in ITK. We probably
>can add a "Trait" to the transform for defining when they are
>"Linear", and  allowing the ResampleImageFilter to decide what
>method to use for the invocation of the transform.
>
>
>
>   Regards,
>
>
>      Luis
>
>
>------------------
>Marius Staring wrote:
>>hi Luis,
>>you might want to change the
>>if (dynamic_cast<const TranslationTransformType *>(m_Transform.GetPointer()))
>>to
>>else if (dynamic_cast<const TranslationTransformType 
>>*>(m_Transform.GetPointer()))
>>
>>for the sake of consistency.
>>And then you can get rid of all the return's.
>>Regards,
>>Marius
>>
>>Luis Ibanez wrote:
>>
>>>
>>>Hi Stefan,
>>>
>>>The TranslationTransform has now been added to the code of the
>>>ResampleImageFilter, in order to make it use the fast cycle of
>>>point coordinates mapping.
>>>
>>>You may want to update your CVS checkout of ITK:
>>>http://www.itk.org/cgi-bin/viewcvs.cgi/Code/BasicFilters/itkResampleImageFilter.txx?root=Insight&sortby=date&r2=1.53&r1=1.52 
>>>
>>>
>>>Please let us know if you find any problems,
>>>
>>>
>>>    Thanks
>>>
>>>
>>>       Luis
>>>
>>>
>>>
>>>=====================
>>>Stefan Klein wrote:
>>>
>>>>
>>>>Hi,
>>>>
>>>>The itkResampleImageFilter takes smart advantage of linear 
>>>>transforms.  >From line 187-206 in the .txx file it seems that the 
>>>>TranslationTransform is not considered a linear transform. Is this done 
>>>>on purpose, or is it a mistake?
>>>>
>>>>Best regards,
>>>>Stefan.
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>------------------------------------------------------------------------
>>>>
>>>>_______________________________________________
>>>>Insight-users mailing list
>>>>Insight-users at itk.org
>>>>http://www.itk.org/mailman/listinfo/insight-users
>>>
>>>
>>>
>>>_______________________________________________
>>>Insight-users mailing list
>>>Insight-users at itk.org
>>>http://www.itk.org/mailman/listinfo/insight-users
>
>
>_______________________________________________
>Insight-users mailing list
>Insight-users at itk.org
>http://www.itk.org/mailman/listinfo/insight-users

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://public.kitware.com/pipermail/insight-users/attachments/20060504/526b5b79/attachment.html


More information about the Insight-users mailing list