[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
GIMPing and transparency
oops. of course i deleted the original message...
if i understand correctly, you have some picture that you want to replace
a certain colour with the "transparent" colour (or, set that colour to be
the transparent background, or...).
to do transparency, you will need an alpha channel with your image (so,
you will have 4 channels in total, red, green, blue, and alpha). the
alpha value for a pixel will indicate how "transparent" it will show up.
various file formats handle this in different ways. afaik, gif will let
you have only one colour specifed as transparent, while something like png
will allow a large range of values (i think they can be up to 48 bit.. not
sure though..). I do not believe jpeg has this capability, so if
you're trying to save out transparent jpeg's, it just wont work.
anyway! we need to add an alpha channel to our image, if it does not
already have one. look on the title bar for the image window. does it
say something like "foo.gif-....(indexed-alpha)" or
"bar.jpeg-...(RGB-alpha)? if there is no -alpha, go to "layers->add alpha
channel".
incidently, creating a new image with the "transparent" fill type adds an
alpha channel.
now, if there is only one colour you want to set to be transparent, go
to "select->by color". a window should pop up. clicking on a colour in
your image window will cause it to be selected, and a black and white
representation of the selected region will be drawn.
once you have picked your favorite colour, hit "edit->clear". the
selected regions should now be filled with the grey and darker grey
checkerboard pattern.
now, if you were to open this file in another program, say, xv, the
transparent sections would look very wierd (i tried it on two images, one
turned out with the areas being white, the other they were black). since
you have only one image open, what will you see when you look "through"
the transparent image? black? white? paisley? if you toss it on a quick
web page, you should see the background colour through the transparent
regions (at least in a browser that supports tramsparent gifs).
oh. i think the "magic wand" that was being referred to can be found on
left side of the toolbar, second button down from the top. there is a
little magic wand icon between a dashed box, and 4 crossed arrows. i
believe it is used for selecting areas of similar colour, like if you had
a big brown blob in the middle of your image thta you wished to select.
hope this helps!
karl
[k a r l r a s c h e] "in order to deviate successfully, one has to have
rasche@cs.hope.edu at least a passing acquaintance with whatever
norm one expects to deviate from."
- frank zappa