comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » transparent background
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: transparent background [message #35358 is a reply to message #35296] Thu, 05 June 2003 13:22 Go to previous messageGo to previous message
Rick Towler is currently offline  Rick Towler
Messages: 821
Registered: August 1998
Senior Member
"David Fanning" wrote in message..
> Rick Towler writes:
>
>> You didn't really fool around for 20 minutes, did you?
>
> Indeed I did. I thought it might take five. And now
> I've just spent another 15. :-)
>
>> 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.
>
> Well, I can see this works. But why doesn't my test
> program work?

It looks like WRITE_PNG only accepts "0" as a valid transparent pixel index
value. I can get your program to work if I load your background at 0 and
specify 0 as the transparent index but it will not work with any other
value. it looks like I was just lucky :)

Another annoying thing I noticed is that the VERBOSE keyword isn't verbose
at all. I didn't get any additional output with it set.

I would submit these as bugs.


-Rick
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: TVRD, Decomposed = ? and 24bit display
Next Topic: M-SSA

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Fri Oct 10 04:36:10 PDT 2025

Total time taken to generate the page: 0.71759 seconds