Sprite Transparent Color

Started by rich, Tue 29/03/2005 12:09:11

Previous topic - Next topic

rich

Hi, I'm having difficulties with importing sprites in regard to the transparent color.
I have buttons I've created for a GUI, so I actually don't want any transparency. The border is a grey, so I check the "Palette index 0" so the grey border won't be transparent. It doesn't work. It makes it transparent. This could be that the graphic, a .bmp only has three actual color as specified, by photoshop, by I haven't had problems with images that had six or seven, so I don't know what it is.

I had a similar issue where I had a sprite I wanted to be a "border", in that the whole border was one color and the center was black because I actually wanted the center to be transparent. I had problems getting the border to even show up, but when I did, the middle black part wasn't transparent.

I guess I just wish I could specify the transparent color myself somehow during import, not choosing from a corner or the palette index 0. This could really be a problem if I have a button I don't want transparent at all, and it has black (index 0 color) in it! What do I do then?

I'm using 2.7prefinal, btw.

Thanks in advance,
Rich
I'm so excited!

Ashen

Add 1 pixel to the left of the image, and set that to a colour that isn't otherwise used in the image. (You could also add the extra pixel to the right, and select 'Top Right Pixel' for the Transparent colour.) Then, when you import the image either select everything but that line, or use 'Grab whole image' and then 'Crop Sprite Edges' in the Sprite manager (might've been renamed for 2.7, but it should still be there) to remove the transparent line.
For the 'Border' image, use black for the extra pixel, since that's the colour you want not to show up.
I know what you're thinking ... Don't think that.

SMF spam blocked by CleanTalk