[vtkusers] conversion from vtkImageData to vtkDataObject

Martine Lefevre martine_lef at yahoo.fr
Mon Jan 26 09:43:16 EST 2009


Thanks Sercani nd Francoi for your quiik relpy.
 
Including the header file "vtkImageData.h" resolve the problem.

 
This relationship is actually inheritance: vtkImageData is a subclass of vtkDataSet. The only way for the compiler to know this relationship is to include the header file of the subclass, that is: #include "vtkImageData.h"

Thanks a lot
Martine
 
 


--- En date de : Lun 26.1.09, Sercani <sercanimailgroups at gmail.com> a écrit :

De: Sercani <sercanimailgroups at gmail.com>
Objet: RE: [vtkusers] conversion from vtkImageData to vtkDataObject
À: martine_lef at yahoo.fr, vtkusers at vtk.org
Date: Lundi 26 Janvier 2009, 14h19








Hi Martine;
Actually vtkImageData inherits from vtkDataSet and it inherits from vtkDataObject, so you may use vtkImageData as a vtkDataObject object. I am using vtkImageData as an input for vtkPolyDataAlgoritm and i get no error…There must be some other stuff that causes error…
Best Regards,
Sercani…
 

From: vtkusers-bounces at vtk.org [mailto:vtkusers-bounces at vtk.org] On Behalf Of Martine Lefevre
Sent: Monday, January 26, 2009 4:08 PM
To: vtkusers at vtk.org
Subject: [vtkusers] conversion from vtkImageData to vtkDataObject
 




Hi,
I'd like to compute the curvature of an 3D object and I got the following error:
error C2664: 'void vtkPolyDataAlgorithm::SetInput(vtkDataObject *)' : cannot convert parameter 1 from 'vtkImageData *' to 'vtkDataObject *'.
So my question is how I can convert form vtkImageData to vtkDataObject.
Thanks 
Martine
 


      
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20090126/56bc76ab/attachment.htm>


More information about the vtkusers mailing list