[vtkusers] Trying to use vtkChartXY with Tcl

Mario Rodriguez biomates at telefonica.net
Tue Dec 15 18:24:02 EST 2015



El 15/12/15 a las 21:51, David Gobbi escribió:
> Hi Mario,
>

Thanks for your kind and quick response.

> Tcl syntax a mixture of lisp and shell script.  The code will look 
> like this:
>
>   set line [chart AddPlot 0]
>   $line SetInputData table 0 2

Now I see where I was wrong. I forgot the dollar symbol.

After writing:

[view GetRenderWindow] SetMultiSamples 0
[view GetRenderWindow] Render

where view was created by

vtkContextView view

I successfully get the expected plot.

The problem now is how to close the window with a mouse click. Any hints?

>
> Are you really sure that you want to use Tcl?

Yes, it is mandatory. We have the system Lisp -> Tcl -> Vtk for drawing 
3D scenes from Computer Algebra System Maxima:

http://riotorto.users.sourceforge.net/vtk/

Tcl is a dependency to be satisfied by Maxima, which is also used for 
other purposes.

I am trying to know how far we can go with Vtk for plotting 2D scenes, 
in order to extend the Maxima-Vtk interface.


> Many of the VTK classes
> and methods that you can use with Python cannot be used from Tcl, so
> it might not even be possible to convert that example into working Tcl
> code.  You're welcome to try, though.
>
>  - David
>

Thanks again for your help.

--
Mario
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtkusers/attachments/20151216/9a0a7504/attachment.html>


More information about the vtkusers mailing list