Transparency Colors

Discuss and post your mods and scenarios here for others to download.

Moderator: Vic

Post Reply
User avatar
Veldor
Posts: 1434
Joined: Sun Dec 29, 2002 9:32 am
Location: King's Landing

Transparency Colors

Post by Veldor »

Is it possible in the editor to control or set a transparency color? It is common place in games to have at least one pre-defined color not show up so as to allow transparency without having to resort to actual transparency such as in a transparent .png file. Does AT have that and if so can that be further customized and set to any color a scenario designer would like? If so how? Thanks.
jakobrogert
Posts: 20
Joined: Wed Nov 14, 2007 1:32 am
Contact:

RE: Transparency Colors

Post by jakobrogert »

I think I remember reading a post here that it's pink (255, 0, 255). And I'm unsure of changing it.
*how far is heaven? i go tonight*
rickier65
Posts: 14253
Joined: Thu Apr 20, 2000 8:00 am

RE: Transparency Colors

Post by rickier65 »

I bleive Vic mentioned pink as being transparent in one of the threads. You might be able to search on "pink" and find the actual values.

I beleive it was in thread about some counter mods, but not sure.

I don't really understand "graphics" type stuff, so I didn't really follow what he meant.

Rick
User avatar
Veldor
Posts: 1434
Joined: Sun Dec 29, 2002 9:32 am
Location: King's Landing

RE: Transparency Colors

Post by Veldor »

So I painted a .png file 255,0,255 pink and it shows up as pink in game. Is there some trick to this?
User avatar
Arkady
Posts: 1261
Joined: Fri May 31, 2002 1:37 pm
Location: 27th Penal Battalion
Contact:

RE: Transparency Colors

Post by Arkady »

I checked some typical transpart pictures in gam,e (bridges, roads) and all are transparent PNG

Maybe for BMP files there is defined one transparent mask color but for PNGs you need save it as transparent
Image
User avatar
Vic
Posts: 9715
Joined: Mon May 17, 2004 2:17 pm
Contact:

RE: Transparency Colors

Post by Vic »

in the systemgraphics dir you can still find a few .bmps that use 255,0,255 for transparancy.

it should work for counter and hex graphics.

never tried putting 255,0,255 in a png though. when i used png i just use ARGB format instead of RGB.
Visit www.vrdesigns.net for the latest news, polls, screenshots and blogs on Shadow Empire, Decisive Campaigns and Advanced Tactics
jakobrogert
Posts: 20
Joined: Wed Nov 14, 2007 1:32 am
Contact:

RE: Transparency Colors

Post by jakobrogert »

Since PNG's feature transparency, there would be no need to work with pink as a transp. value. So Veldor, if you can't seem to make transparency happen in your PNG files, try using another software (I would personally recommend photoshop.).
*how far is heaven? i go tonight*
User avatar
Veldor
Posts: 1434
Joined: Sun Dec 29, 2002 9:32 am
Location: King's Landing

RE: Transparency Colors

Post by Veldor »

ORIGINAL: jakobrogert

Since PNG's feature transparency, there would be no need to work with pink as a transp. value. So Veldor, if you can't seem to make transparency happen in your PNG files, try using another software (I would personally recommend photoshop.).

You should try to be less condescending in your posts. Why assume I'm a graphics idiot? Perhaps the reason I ask is because I have a large set of existing graphics files that are not transparent PNG's. And even though one can easily convert them to PNG one cannot easily remove existing colors and convert that all to transparancy. Even if you could its far less work if the color were settable, which would then require no editing whatsoever, which is why I ask.

So since your the photoshop "expert" perhaps you could tell me the easiest way to replace all of a certain colored pixel in a detailed work with transparency and/or another colored pixel. This has to be an exact swapout no approximated select similar tool etc.
User avatar
Vic
Posts: 9715
Joined: Mon May 17, 2004 2:17 pm
Contact:

RE: Transparency Colors

Post by Vic »

@veldor,
 
could you attach an example PNG with (255,)255,0,255 colour in it.
because actually i think PNG as well as BMP should make pink transparent.
 
thanks,
vic
Visit www.vrdesigns.net for the latest news, polls, screenshots and blogs on Shadow Empire, Decisive Campaigns and Advanced Tactics
PDiFolco
Posts: 1195
Joined: Mon Oct 11, 2004 8:14 am

RE: Transparency Colors

Post by PDiFolco »

Veldor,
Can't you just convert your png files to bmp and then have the pink transparency work ?
PDF
User avatar
Veldor
Posts: 1434
Joined: Sun Dec 29, 2002 9:32 am
Location: King's Landing

RE: Transparency Colors

Post by Veldor »

ORIGINAL: PDiFolco

Veldor,
Can't you just convert your png files to bmp and then have the pink transparency work ?

The pink thing I was doing was just a test. It doesn't actually matter much to me in this case. The REAL files can be whatever format but they have backgrounds already so, as explained above, the least effort would be able to set the existing background color as the transparent color (no editing) or to find a way to "swap out" one exact pixel color for another within the entire set of images.

I have the latest photoshop, as so far as I know or have found, it does not have that feature. The closest function, select similar, does not work because similar does not mean the same and it therefore picks pixels that are within a certain range as well.. which highly degraded the image quality.

If no one can answer how I might accomplish this easily with photoshop or another program then my only real choice is a pixel editor wherein I replace them a row, or even a pixel, at a time. While I could do this, I'm normally not so patient with graphics work, as Id like to get moving with other aspects of the mod instead :)

Even though .gif aren't supported another option would be to temporarily convert them to 8bit .gif and then do a pallette swap. Assuming that doesnt degrade the source (in one of my mods it probably wouldnt.. in the other its still less than ideal).

So, in this thread, was mainly looking to see if you could set the color in AT (you can't) so the only other thing would be if anyone knows an easy way to accomplish a change to pink.

Thanks all.
PDiFolco
Posts: 1195
Joined: Mon Oct 11, 2004 8:14 am

RE: Transparency Colors

Post by PDiFolco »

In this case you can maybe rather cut the part you want (ie the foreground) and paste them back on a pink background.
PDF
Post Reply

Return to “Mods and Scenarios”