[vtkusers] plot height field figure
David Doria
daviddoria at gmail.com
Fri Apr 20 18:25:12 EDT 2012
On Fri, Apr 20, 2012 at 5:48 PM, zhixiu li <zhixiuli at gmail.com> wrote:
> Dear All,
> I have a dataset like this (in data.txt)
> 1 0 0
> 2 0 0
> 1 2 3
> 1 2 3
> ...
> the 1st column is x and the second col is y. the last column is the
> attribute of this point. I want to make a 3 D plot for each points(Z will
> the attribute value).
> How do I read this data file to VTK? Thank you very much!
>
> tianbu
>
Using a reader like this:
http://www.vtk.org/Wiki/VTK/Examples/Cxx/IO/SimplePointsReader
Will assume that the 3 values are XYZ coordinates. You can then color the
points by their Z value using this:
http://www.vtk.org/Wiki/VTK/Examples/Cxx/Meshes/ElevationFilter
David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20120420/4edaebad/attachment.htm>
More information about the vtkusers
mailing list