Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

Emagen

Transparent color

This topic is 6964 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I have a related question.

What is a good way to set up the color key for a Truecolor image?

I don''t want to use black (0,0,0) because I might want black in my image. But at the same time, if I use something like magenta (or green) then images you save out of a paint program will be anti-aliased to magenta on the edges. Not good.

The method I implemented in my TGAview program uses the alpha channel of the TGA to set up a magenta color key. That way the image anti-aliases to black (or the background color), but can still contain pure black. It also changes magenta to a slightly off-magenta to maintain it. This seems to work, but it has it''s problems.

Mainly, it seems that not many programs properly support the alpha channel in TGA files (including PhotoShop). I don''t want to have to set up a mask in PSP and do all this post-processing just for a silly color key.

So, I''m wondering what other people who came before me have done?

Btw, if you''re wondering why I picked Magenta, it''s because it''s not likely to be used a whole lot, and being red+blue you don''t have to worry about 565 or 555 quite as much.

- n8


Share this post


Link to post
Share on other sites
Advertisement
Well its quite simple really... Turn anti-aliasing off in your graphics program. If you use photoshops fill brush, there is an option (in the brushes window) for tolerance. Turn this to zero and no anti-aliasing will occur.

-Shadwdrak

Share this post


Link to post
Share on other sites
quote:
Original post by Shadwdrak
Well its quite simple really... Turn anti-aliasing off in your graphics program. If you use photoshops fill brush, there is an option (in the brushes window) for tolerance. Turn this to zero and no anti-aliasing will occur.



Sounds a lot simpler than my convoluted method

I was having a magenta layer behind an image in PhotoShop, and it anti-aliases between the layers. Sounds like you're saying to turn off anti-aliasing on the fill brush and paint magenta (or whatever) on the same layer [possibly flatten the image first and then fill in magenta]. Correct?

Is there anyway in PhotoShop to have a Magenta background layer and not have images on the above layers mix (anti-alias) with it?

Thanks, Nathan.



---
Visit me at nathany.com

Edited by - nathany on 4/29/00 3:56:08 AM

Share this post


Link to post
Share on other sites
Photoshop shouldent do any anti-aliasing between layers at all. If you are using photoshops tools to draw the image, each tool has its own set of options. Often anti-aliasing is one of these options. If you paste an image on top of another no anti-aliasing should occur. Another thing, unless you are planning on saving the pics in photoshops default format (I forgot what it is) then you wont be able to save layer information anyways. If you cant save the info then you might as well flatten the image and use a 0 tolerance, non anti-aliasing (aliasing?) fill brush.

-Shadwdrak

Share this post


Link to post
Share on other sites
I believe in Photoshop, you can take off anti alias by usuing the dissolve layer type, but it may leave some blank spots due to the anti alias

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!