Re: transparent background [message #35283] |
Wed, 04 June 2003 17:40  |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
Rick Towler (rtowler@u.washington.edu) writes:
> FWIW, I can create an image with a transparent background with one step and
> a PC :)
Well, how was that done? Because I didn't have any luck
at all fooling around with it the other day for 15-20 minutes.
Cheers,
David
--
David W. Fanning, Ph.D.
Fanning Software Consulting, Inc.
Phone: 970-221-0438, E-mail: david@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
|
|
|
|
|
|
|
Re: transparent background [message #35366 is a reply to message #35283] |
Thu, 05 June 2003 11:29  |
Rick Towler
Messages: 821 Registered: August 1998
|
Senior Member |
|
|
"David Fanning" wrote in message ...
> Rick Towler writes:
>
>> FWIW, I can create an image with a transparent background with one step
and
>> a PC :)
>
> Well, how was that done? Because I didn't have any luck
> at all fooling around with it the other day for 15-20 minutes.
You didn't really fool around for 20 minutes, did you?
With the B/W linear color table loaded:
IDL> test = BYTARR(200,200)
IDL> test[100:199,*] = 200
IDL> tvlct, r,g,b,/get
IDL> write_png,'test.png',test,r,g,b,TRANSPARENT=[0]
In PP, Insert -> Picture -> From File... and select 'test.png'
I have a 200x200 image, right half is lt. gray, left half is transparent.
Load test.png up in Photoshop and the left half of the image is transparent
too.
-r
|
|
|