[vtkusers] RE: How to Read a VTK file format?

Steven Chen itkvtk at yahoo.com
Thu Jan 1 19:33:54 EST 2004


HI, All
 
I met a problem in reading a VTK file format from a file.
 
I use Windows XP + VS7
 
The code is as follows:
 

#include "vtkPolyDataReader.h"

int main(){


vtkPolyDataReader *reader = vtkPolyDataReader::New();

reader->setFileName("C:\image.vtk");

return 0;

}


There is always an error message saying" SetFileName is not a member of vtkPolyDataReader. 

I try to change setFileName to FileName, but the following error messages occurs:

 error C2248: 'vtkDataReader::FileName' : cannot access protected member declared in class 'vtkDataReader'

 

So please help!

 

thanks alot

Steven Chen




 


---------------------------------
Do you Yahoo!?
Find out what made the Top Yahoo! Searches of 2003
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20040101/0211bcff/attachment.htm>


More information about the vtkusers mailing list