Reading data set from a file

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Reading data set from a file

Kirthi  Krishnamraju

 
Hi,

I am new to VTK. I am having problem in reading a dataset from a file and use it in the program.sample of my dataset is as follows
-10.304059 -45.374859 -78.576840
-12.567382 -47.687463 -79.794049

there r some 20,000 of such values.
I am using VC++ 6.0 n vtk4.2.

I am not understanding if i shud retrieve the data from the file just the way we do in vc++ or use the vtkPolyDataReader.

Can any1 pls help me. If there is any site tht has examples of programs tht use the files for reading and writing data, I would be happy if u gimme the link.

Regards,
Kirthi




_______________________________________________
This is the private VTK discussion list.
Please keep messages on-topic. Check the FAQ at: http://www.vtk.org/Wiki/VTK_FAQ
Follow this link to subscribe/unsubscribe:
http://www.vtk.org/mailman/listinfo/vtkusers
Reply | Threaded
Open this post in threaded view
|

Re: Reading data set from a file

Kevin H. Hobbs
On Wed, 2006-02-01 at 18:43 +0000, Kirthi Krishnamraju wrote:

>  
> Hi,
>
> I am new to VTK. I am having problem in reading a dataset from a file
> and use it in the program.sample of my dataset is as follows
> -10.304059 -45.374859 -78.576840
> -12.567382 -47.687463 -79.794049
>
> there r some 20,000 of such values.
> I am using VC++ 6.0 n vtk4.2.
>
> I am not understanding if i shud retrieve the data from the file just
> the way we do in vc++ or use the vtkPolyDataReader.
>
> Can any1 pls help me. If there is any site tht has examples of
> programs tht use the files for reading and writing data, I would be
> happy if u gimme the link.
>
> Regards,
> Kirthi
Are these data in a text file? I think there's a vtk example that does
this, but I did it myself too.  I read points in and triangulated them.
You can throw out that section of code. I also used C malloc because
that's what I know.  The #include "utility.c" is a hack because I'm also
no CMake expert.



_______________________________________________
This is the private VTK discussion list.
Please keep messages on-topic. Check the FAQ at: http://www.vtk.org/Wiki/VTK_FAQ
Follow this link to subscribe/unsubscribe:
http://www.vtk.org/mailman/listinfo/vtkusers

CMakeLists.txt (586 bytes) Download Attachment
utility.c (2K) Download Attachment
utility.h (2K) Download Attachment
vtk_mesh.cxx (3K) Download Attachment
signature.asc (196 bytes) Download Attachment