From: Lars Bruno Hansen (lhansen_at_fysik.dtu.dk)
Date: Thu Oct 30 2003 - 08:21:43 CST

dear VMD users,

I have a question about running VMD and VTK (Visual Tool Kit) together,
using VMD's python interpreter. VTK can be called directly from python.

I have a set of localized orbitals, and have a representation of these
as spheres, which I can visualize in VMD, possible together with the
molecule itself.
I would then like to pick an orbital in VMD and have this orbital
shown as a 3D plot in VTK. The VTK graphics runs in a Tk window.

The VTK window opens fine from within the VMD python interpreter,
you can rotate the view in the VTK window and you still have the
the VMD python window active, also the VMD Main menu works fine,
however VMD's openGl window is not redrawn.
Trying to close the VTK window and delete the VTK objects from
the python session does not help, also the VMD command 'reset view',
does not restore control to VMD's openGL window.

I do not know if one in general can have these two graphics loop
running together in the same process, or if you will have to
start VMD and VTK as independent processes and then communicate
via a pipe or similar?

Any help on this is greatly appreciated.

I am running vmd 1.8.1 openGL version on linux redhat 9.0.

with best regards
Lars

-- 
Lars Bruno Hansen,
CAMP, Dept. of Physics, Building 307, DTU, DK-2800 Lyngby, Denmark
Phone: +45 45 25 32 16  Fax: +45 45 93 23 99
E-mail: lhansen_at_fysik.dtu.dk