[vtkusers] Re: is VTK good for 3D charting?

Goodwin Lawlor goodwin.lawlor at ucd.ie
Fri Oct 27 11:59:02 EDT 2006


ahgu wrote:
> is VTK good for 3D charting? Does it have functions that support 3D
> plotting?
> Where can I find examples with visual c++?
> thanks
> Andrew

Hi Andrew,

If you're talking about animating 2d charts have a look at these tcl 
examples:
/Hybrid/Testing/Tcl/xyPlot.tcl
/Hybrid/Testing/Tcl/xyPlot2.tcl
/Hybrid/Testing/Tcl/xyPlot3.tcl
/Hybrid/Testing/Tcl/xyPlot4.tcl

And this C++ example:
/Widgets/Testing/Cxx/TestSplineWidget.cxx


Basically, vtkXYPlotActor is the class you want...

If you're talking about plotting your 3D data in 3D space have a look at 
vtkGlyph3D for a 3D scatter plot, and vtkPolyLine or vtkCardinalSpline 
for a line plot.

The also an example of plotting financial data here: 
/Examples/Modelling/Cxx/finance.cxx

hth



hth

Goodwin





More information about the vtkusers mailing list