transparent colours for images

W

wanwan

I'm trying to make the background of a picture transparent, so I use
paint to fill the background with blue (0,0,255), then set the
transparent colour to it. I found a custom control that can do the
job.

Now the problem is the paint program can't seem to save the file with
the exact colour i need. every time I open the picture file again , I
see the blue background has a range of colours (<30,<30,>230)

I tried in Java and I was able to set a range of colours transparent.
How do I do it with vb.net?
I will need to have the image in the picturebox control at the end.
 
L

lord.zoltar

I'm trying to make the background of a picture transparent, so I use
paint to fill the background with blue (0,0,255), then set the
transparent colour to it. I found a custom control that can do the
job.

Now the problem is the paint program can't seem to save the file with
the exact colour i need. every time I open the picture file again , I
see the blue background has a range of colours (<30,<30,>230)

I tried in Java and I was able to set a range of colours transparent.
How do I do it with vb.net?
I will need to have the image in the picturebox control at the end.

If you are saving the image as a JPG you may lose the EXACT colour you
want to use. I think png image format is much better for this sort of
thing. TIFF images would also work but would be quite large.
 
B

Bruce W. Darby

Also, the .jpg graphic format doesn't support transparency. Another format
that would is the .gif format, but it can really make a good looking graphic
look awful if you aren't careful in how you create it.

Bruce
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top