From: Olaf Lenz (lenzo_at_mpip-mainz.mpg.de)
Date: Mon Nov 02 2009 - 07:29:24 CST

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hello!

On

http://www.ks.uiuc.edu/Research/vmd/plugins/doxygen/molfileplugins.html#molfileplugins

I notice that VMD provides a way to access the Tcl interpreter from a
molfile reader plugin via the command VMDPLUGIN_register_tcl. The docs
state, that the function is there to allow plugins to export additional
Tcl functions. Unfortunately, I can't find a single plugin that actually
uses this functionality, so I'm not sure whether I can actually do what
I think of.

Is it possible to exchange data between the molfile reader functions
(like open_file_read) and whatever function I would like to register
from Tcl? In principle, I would think that it should be possible to use
global variables, however, this is of course not very elegant.

I would like to allow a molfile reader plugin to inject additional data
into the Tcl data space, so that the reader format can store additional
user data, that is made available to the user in VMD via Tcl.

An even simpler solution would be if I had a way to access the Tcl
interpreter from inside the molfile reader plugin functions. Is there a
(legal) way to do that?

Of course, I could easily misuse the above register function to get a
pointer to the Tcl interpreter, store it in a global variable and then
use it from inside the plugin function, but I guess that this would have
severe consequences, would it?

Olaf

- --
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
A: Top-posting.
Q: What is the most annoying thing in e-mail?
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.4-svn0 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iD8DBQFK7t60tQ3riQ3oo/oRApVnAJ9SZCgIgv05IFvFhl74zQGmDXTKegCaA4y4
yRKLeM4Wypdy0+it11Q+v4M=
=t+Jw
-----END PGP SIGNATURE-----