I have an image I'm drawing with a graphics object. I simply want to make a certain color on that image transparent. How can I do this? Thanks.
Printable View
I have an image I'm drawing with a graphics object. I simply want to make a certain color on that image transparent. How can I do this? Thanks.
See the ImageAttributes.SetRemapTable Method.
Look through the intellisense for the image item you want to draw. It may or may not have a "MakeColorTransparent()" method. I know that Bitmaps have it, can't remember if Images objects do though.
Quote:
Originally Posted by wossname
Image does not have MakeColorTransparent, but as you said Bitmap objects do. I would imagine that since Bitmap inherits from Image, that you could use a bitmap object in place of an Image object when calling the DrawImage method of the graphics object (since that method only takes an Image, and not a Bitmap type)