From: John Stone (johns_at_ks.uiuc.edu)
Date: Tue Feb 03 2009 - 09:02:27 CST

Vlad,
  Adding a new representation currently requires recompiling VMD.
The graphics code in VMD is very tightly coupled with the internal
data structures of the program, so this is something that's not presently
accessible by the plugin system. To write a new representation, one
creates a new routine called by the internals in DrawMolItem.C. You
can see how the existing ones work, some of them are reasonably easy
to follow. What sort of representation were you planning on implementing?

Cheers,
  John Stone
  vmd_at_ks.uiuc.edu

On Tue, Feb 03, 2009 at 03:22:24PM +0100, Vlad Cojocaru wrote:
> Dear John, Dear vmd users,
>
> I am wondering if somebody could give me an advice on how could I add a
> new, customized representation style to VMD. I mean code it and then add
> it to the Graphics-Representations menu in VMD. I assume recompilation
> of VMD is required for this.
>
> A good starting point would be for instance to modify the "New Cartoon"
> representation to apply it to other residues than proteins. First it
> would be helpful to know in which source files are the representations
> defined. Then, extract the code that produces the New Cartoon
> representation. Modify it to my own purposes. Could somebody indicate me
> where this code is located within the source code?
>
> Is there a way to load such a new representation style as an external
> module (e.g. tcl) without the need to recompile vmd ?
>
> Thanks for any ideas on this
>
> Greetings
> vlad
>
> --
> ----------------------------------------------------------------------------
> Dr. Vlad Cojocaru
>
> EML Research gGmbH
> Schloss-Wolfsbrunnenweg 33
> 69118 Heidelberg
>
> Tel: ++49-6221-533202
> Fax: ++49-6221-533298
>
> e-mail:Vlad.Cojocaru[at]eml-r.villa-bosch.de
>
> http://projects.villa-bosch.de/mcm/people/cojocaru/
>
> ----------------------------------------------------------------------------
> EML Research gGmbH
> Amtgericht Mannheim / HRB 337446
> Managing Partner: Dr. h.c. Klaus Tschira
> Scientific and Managing Director: Prof. Dr.-Ing. Andreas Reuter
> http://www.eml-r.org
> ----------------------------------------------------------------------------
>

-- 
NIH Resource for Macromolecular Modeling and Bioinformatics
Beckman Institute for Advanced Science and Technology
University of Illinois, 405 N. Mathews Ave, Urbana, IL 61801
Email: johns_at_ks.uiuc.edu                 Phone: 217-244-3349
  WWW: http://www.ks.uiuc.edu/~johns/      Fax: 217-244-6078