Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / GUI / October 2004

Tip: Looking for answers? Try searching our database.

Image Transparency Problem

Thread view: 
Steel Dred - 20 Oct 2004 11:53 GMT
Greetings, I have a program that builds a window by drawing layers one on top
of the other. Each of these layers is contained in a BufferedImage object and
the Gif graphics that go on them are contained in an ImageIcon object. So i am
useing the drawImage method to put the ImageIcon on the BufferedImage layer and
then later I use another drawImage method to put that BufferedImage onto the
BufferedImage that represents the window. However a some point when the images
are being copied the black pixels are being drawn rather then being transparent
like they normally would be. I have searched, but have found no answer to this
problem. Any help will be appreciated. Thanks.
Andrei Kouznetsov - 20 Oct 2004 16:03 GMT
> Greetings, I have a program that builds a window by drawing layers one on top
> of the other. Each of these layers is contained in a BufferedImage object and
[quoted text clipped - 5 lines]
> like they normally would be. I have searched, but have found no answer to this
> problem. Any help will be appreciated. Thanks.

black pixels are not transparent in java.
to make pixel transparent you should set pixel's alpha to 0.

Signature

Andrei Kouznetsov
http://uio.dev.java.net Unified I/O for Java
http://reader.imagero.com Java image reader
http://jgui.imagero.com Java GUI components and utilities



Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.