Ever heard about QuteMol? It's a very nice program and the images are just astonishing. The reason why I didn't convinced myself to try it is because it's only available for the Windows and Mac platforms and I'm starting to use my Arch Linux more and more. Ok, now you are probably asking yourself what I asked myself - how do I get such images in Pymol? I was not the first who thought about it. Here's a pymolwiki recipe how it can be done. Like I sed earlier - it's just a matter of the settings. You could write a script for it but I've decided to go one step further integrating it into Pymol. After some cups of coffee I've started playing around with the Pymol GUI python modules and found the right ones - menu.py and preset.py. All modifications were done on a linux Pymol version 0.99rc6, but besically it should also work on other Pymol versions.
First I've opened the file preset.py and defined my own representation preset function called qutemollike (add the code below at the end of the file):
preset.py(Toggle Plain Text)
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 def qutemollike(selection="(all)",_self=cmd): s = tmp_sele cmd.set_color("oxygen",[1.0,0.4,0.4]) cmd.set_color("nitrogen", [0.5,0.5,1.0]) cmd.remove("solvent") cmd.as("spheres") util.cbaw() cmd.bg_color("white") cmd.set("light_count",10) cmd.set("spec_count",1) cmd.set("shininess",10) cmd.set("specular",0.25) cmd.set("ambient",0) cmd.set("direct",0) cmd.set("reflect",1.5) cmd.set("ray_shadow_decay_factor",0.1) cmd.set("ray_shadow_decay_range", 2) cmd.unset("depth_cue")
menu.py(Toggle Plain Text)
482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 def presets(s): return [[ 2, 'Preset:' ,'' ], [ 1, 'simple' ,'preset.simple("'+s+'")' ], [ 1, 'simple (no solvent)' ,'preset.simple_no_solv("'+s+'")' ], [ 1, 'ball and stick' , 'preset.ball_and_stick("'+s+'")' ], [ 1, 'b factor putty' , 'preset.b_factor_putty("'+s+'")' ], [ 1, 'technical' , 'preset.technical("'+s+'")' ], [ 1, 'ligands' , 'preset.ligands("'+s+'")' ], [ 1, 'ligand sites' , preset_ligand_sites(s) ], [ 1, 'pretty ', 'preset.pretty("'+s+'")' ], [ 1, 'pretty (with solvent)' , 'preset.pretty_solv("'+s+'")' ], [ 1, 'publication ' , 'preset.publication("'+s+'")' ], [ 1, 'publication (with solvent)' , 'preset.pub_solv("'+s+'")' ], [ 1, 'QuteMol like', 'preset.qutemollike("'+s+'")' ], [ 0, '' ,'' ], [ 1, 'default' ,'preset.default("'+s+'")' ], ]
Here is a screenshot showing the added "QuteMol like" option in the preset submenu.
As you can see I've loaded a caffeine molecule. I give it the final polish by typing in the console:
set ray_trace_mode,1
ray 800,600
And here's how it looks now.