[Insight-users] WrapITK: ImageReader and SmartPointer

Gaëtan Lehmann gaetan.lehmann at jouy.inra.fr
Wed Jun 24 12:33:47 EDT 2009


Le 24 juin 09 à 17:56, Marcel Luethi a écrit :

> Hi all,
>
> I noticed that in WrapITK (included with ITK 3.8.1) the itkImageReader
> does not behave the same for all the wrapped types.
>
> Instantiating a ImageReader for an image of type unsigned short will
> return a smart pointer, whereas for the signed short image the output
> will be the plain image pointer:
>
>> In [4]: itk.ImageFileReader.ISS3.New().GetOutput()
>> Out[4]: <C itk::Image<(short int,3u)> instance at
>> _f08ecc0400000000_p_itk__ImageTshort_int_3u_t>
>
>> In [5]: itk.ImageFileReader.IUS3.New().GetOutput()
>> Out[5]: <C itk::SmartPointer<(itk::Image<(unsigned short,3u)>)>
>> instance at
>> _d0c04f0200000000_p_itk__SmartPointerTitk__ImageTunsigned_short_3u_t_t
>> >
>
> Is this a bug in WrapITK or is this the intended behavior? It seems  
> that
> it does not cause any troubles as long as one is sticking to the
> standard filters. However, for my own extensions this behavior causes
> some problems.
>
> Thank you for your help and best regards,
>
> Marcel
>
> ps. I am working on Linux (Fedora Core 9, 64bit) and Python 2.5


Hi Marcel,

It looks like a bug in WrapITK.
Can you file a bug report in ITK bug tracker, so we won't forget about  
it?

Thanks,

Gaëtan

-- 
Gaëtan Lehmann
Biologie du Développement et de la Reproduction
INRA de Jouy-en-Josas (France)
tel: +33 1 34 65 29 66    fax: 01 34 65 29 09
http://voxel.jouy.inra.fr  http://www.itk.org
http://www.mandriva.org  http://www.bepo.fr

-------------- next part --------------
A non-text attachment was scrubbed...
Name: PGP.sig
Type: application/pgp-signature
Size: 203 bytes
Desc: Ceci est une signature ?lectronique PGP
URL: <http://www.itk.org/pipermail/insight-users/attachments/20090624/0f0ec5a8/attachment.pgp>


More information about the Insight-users mailing list