Reece,
PyMOL already has full alpha support for transparency and backgrounds.
To get that floating effect in PowerPoint, Photoshop, or Keynote:
set ray_opaque_background, off
ray
png my_alpha_image.png
That's one of the reasons I like PNG format, but beware of using transparent
images in web pages: Most current Windows versions of IE don't have alpha
channel support with PNG files (or any 32-bit image format AFAIK).
Cheers,
Warren
--
mailto:warren@...
Warren L. DeLano, Ph.D.
Principal Scientist
DeLano Scientific LLC
Voice (650)-346-1154
Fax (650)-593-4020
> -----Original Message-----
> From: pymol-users-admin@...
> [mailto:pymol-users-admin@...] On Behalf Of
> Reece Hart
> Sent: Tuesday, April 27, 2004 8:54 PM
> To: pymol-users@...
> Subject: Re: [PyMOL] True Black?
>
> On Tue, 2004-04-27 at 17:27, pdoucett@... wrote:
>
> Thanks for the suggestion. Unfortunately this still
> gives me a very light
> grey--nowhere near what you are seeing on your machine.
> The molecule is
> *clearly* visible against the black background. I am
> using pymol on win XP. I
> think I will put pymol on my linux machine and see if
> that makes a difference.
>
>
> Pete-
>
> I assume that what you're seeing is the result of minute
> scattering during ray tracing (Warren- is this correct?).
> That's just a guess.
>
> Whatever the cause, you might consider using an image editor
> like the gimp <http://www.gimp.org/> (see * below; or
> Photoshop on Windows, I guess) to select all pixels within
> some distance of black and recoloring those as exactly black.
> For a neater effect, you could add an alpha channel and make
> the pixels transparent, in which case your ray traced image
> would appear to "float" on whatever background you used.
>
> Come to think of it, perhaps this would make a useful setting
> in PyMOL itself (unless it already exists and I just haven't
> come across it): a flatten_background setting (a rgb
> distance) which would cause any pixel within the that
> distance of the background color to be set exactly to the
> background color. If background color were extended to
> include an alpha channel, then this idea would also provide
> for transparent backgrounds.
>
> -Reece
>
> * If you're using gimp, do this: load the png, add an alpha
> channel (Image > Alpha > Add Alpha Channel), then select by
> color (Select > By Color..., then click black somewhere),
> then either 1) fill with the bucket to set the color or 2)
> cut the selection to make it transparent.
>
>
>
>
> --
> Reece Hart, Ph.D. rkh@...,
> http://www.gene.com/
> Genentech, Inc. 650-225-6133 (voice),
> -5389 (fax)
> Bioinformatics and Protein Engineering
> 1 DNA Way, MS-93
> http://www.in-machina.com/~reece/
> South San Francisco, CA 94080-4990 reece@...,
> GPG: 0x25EC91A0
> <http://www.gimp.org/>
>
|