[vtkusers] vtkRenderWindow and Python GUI
David Gobbi
dgobbi at imaging.robarts.ca
Sun May 11 12:49:45 EDT 2003
Hi Guillaume,
Use the vtkTkRenderWidget, it provides the necessary connection
between VTK and Tkinter:
from vtk.tk import vtkTkRenderWidget
Also see VTK/Wrapping/Python/vtk/tk/vtkTkRenderWidget.py
for more details.
VTK/Python also supplies widgets for Qt and wxWindows.
Cheers,
David
--
David Gobbi, MSc dgobbi at imaging.robarts.ca
Advanced Imaging Research Group
Robarts Research Institute, University of Western Ontario
On Sun, 11 May 2003, Guillaume WINDELS wrote:
> Hello,
>
> My problem with vtkRenderWindow is that it opens automatically a new window whereas I would like to visualize a vtk file (whom I know the complete path) in a GUI (written in python).
>
> The RenderWindow where the vtk file is supposed to be displayed is defined like this :
>
> self.renwin_frame = Tkinter.Frame (master_f)
> self.renwin_frame.pack (side='left', fill='both', expand=1)
> self.renwin = RenderWindow.RenderWindow (self.renwin_frame)
> self.renwin.set_background ((0., 0., 0.))
>
> I was thus wondering what was the best way to bypass this problem ?
>
> Thanks in advance
>
> Guillaume
>
>
>
More information about the vtkusers
mailing list