Is it possible to chnage white image background to transparent using Java 2D API? I know how to set composite to turn whole image transparent, but I am wondering if I can set selective color of the image as transparent?? Is that possible? How can I do this?
Any pointers, suggestions would be highly appreciated.
The BufferedImage class has provisions for 4-byte images, where in addition to the color channels R, G and B there is an alpha channel A that can be used to control transparency on a pixel-by-pixel basis. I've never used its alpha channel capabilities, so I'm not sure if they get displayed that way too, or if it's just for reading/writing files.