Add:

cmd.set("surface_mode",1)
cmd.set("mesh_mode",1)

> -----Original Message-----
> From: petr benes [mailto:xbe...@centrum.cz]
> Sent: Friday, March 06, 2009 7:21 PM
> To: pymol-users@lists.sourceforge.net
> Subject: [PyMOL] model refuses to display surface and mesh
> 
> Dear pyMol users,
>  I am trying to load a simple model using python into pymol using the
> following script. All works perfectly until i click for this new model to
> display its surface or mesh. The other thing is that in older versions
> 0.99rc the surface and mesh were correctly displayed, however this works
> no longer with 1.1 version
> Does anyone know how to fix the issue? Thanks. Petr Benes
> 
> from chempy.models import Indexed
> from chempy import Bond, Atom
> from whrandom import random
> from pymol import cmd
> 
> model = Indexed()
> 
> # create some atoms
> 
> for a in range(1,11):
>    at = Atom()
>    at.name = "X%02d"%a
>    at.coord = [random()*5,random()*5,random()*5]
>    at.vdw = 2.0
>    model.atom.append(at)
> 
> # now create some bonds
> 
> for a in range(1,10):
>    bd = Bond()
>    bd.index = [a-1,a] # zero-based indices!
>    model.bond.append(bd)
> 
> # now load and label
> 
> cmd.load_model(model,"example")
> cmd.label("example","name")
> 
> 
> 
> 
> --------------------------------------------------------------------------
> ----
> Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco,
> CA
> -OSBC tackles the biggest issue in open source: Open Sourcing the
> Enterprise
> -Strategies to boost innovation and cut costs with open source
> participation
> -Receive a $600 discount off the registration fee with the source code:
> SFAD
> http://p.sf.net/sfu/XcvMzF8H
> _______________________________________________
> PyMOL-users mailing list
> PyMOL-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/pymol-users



Reply via email to