[Insight-developers] Re: [Insight-users] Problem with ConnectVTKITK

Mauricio Inforçati mauricio.inforcati at cenpra.gov.br
Thu, 19 Feb 2004 10:36:21 -0300


Hi, Brad.
I've  compiled ITK1.6 and I'd like to fix this little problem with
"itk::VTKImageImport", "itk::VTKImageExport" and "ConnectVTKITK". BUT, I
don't want to get all 1.6 branch from CVS since my system is too slow for
compiling ITK. My 1.6 is release version, i.e., It does not contain CVS
informations. So, finally, which files must I get from CVS? What have you
modified?
Thanks

  Maurício


----- Original Message ----- 
From: "Brad King" <brad.king at kitware.com>
To: "Charl P. Botha" <c.p.botha at ewi.tudelft.nl>
Cc: "Rodrigo Trujillo" <rodrigo.trujillo at cenpra.gov.br>; "ITK Users"
<insight-users at itk.org>; "ITK Developers" <insight-developers at itk.org>
Sent: Wednesday, February 18, 2004 7:58 PM
Subject: Re: [Insight-developers] Re: [Insight-users] Problem with
ConnectVTKITK


> Charl P. Botha wrote:
> > Rodrigo Trujillo wrote:
> >
> >> Traceback (most recent call last):
> >>   File "C:\Documents and
> >> Settings\ailton\Desktop\Testes\RecursiveGaussian.py", line 46, in ?
> >>     vtkitk.ConnectVTKToITKF3(vtkExporter, itkImporter.GetPointer())
> >> TypeError: Type error. Expected
> >> _p_itk__VTKImageImportTitk__ImageTfloat_3_t_vtkFloatingPointType_t
> >
> >
> > Durnit!  I can reproduce this error with the
> > CannyEdgeDetectionImageFilterConnectVTKITK.py example and recent ITK and
> > VTK CVS.  Swig is actually mangling the vtkFloatingType as part of its
> > text representation... the fact that the type is available during
> > building is not sufficient.
> >
> > My current thoughts are to make vtkSystemIncludes.h available to swig
> > during the .i -> .cxx parsing so that vtkFloatingPointType is correctly
> > interpreted as either float or double.  Any other ideas on this?
> >
> > As far as I can sniff, Swig should handle the typedef correctly and
> > mangle it as 'float' or 'double'.  *crosses fingers*
>
> I've committed changes to itk::VTKImageImport and itk::VTKImageExport
> that remove the second template argument altogether while still
> providing compatibility for both versions of VTK.  This issue is now
> completely hidden from the wrapping, and the ConnectVTKITK.h code gets
> much simpler again.
>
> This solves the problem, so I've placed the changes on both the ITK 1.6
> branch and the main tree.  The fix should be included when ITK 1.6.1 is
> released.
>
> -Brad
>
> _______________________________________________
> Insight-users mailing list
> Insight-users at itk.org
> http://www.itk.org/mailman/listinfo/insight-users
>