(Sorry for my bad English, I use a machine translator.)
This article describes some compensation for the lack of colors in borders of transparency/opacity zones of textures.
Problem: As you already know, in DXT texture compression, the image is divided into 4x4 pixel squares, and each square there are only 2 fixed color + 2 intermediate between fixed colors (total 4 colors). Therefore, in thin multi-colored elements of image some colors gets distorted. Example:
This is 'D-sprite' from this
project, zoom x2.
Looking good, but mipmap #2 looks not so good:
Wrong blue colors. Why? let's turn off trasparent mask:
The picture looks typical for Photoshop. The main thing is that there is a white background, which really does not exist in the texture (because it is hidden transparency mask).
White on mipmaps mixed with true blue (while reducing sprite) and gave this wrong white-blue color.
Now I'll show you how you can avoid the wrong colors.
Load the original sprite using a utility 'CQ'. ( http://kherson.myftp.biz/cq/
On toolbar press 'image resize'. Dont touching any controls, press 'ok'.
(In fact, resizing does not occur, we use only a side effect of the built-in CQ's algorithm reduction image: the program fills the fields under invisible colors with colors from boundaries, that we just needed.)
You can check result by press Ctrl + mouse click (and hold your click) on picture:
What happened? CQ painted over all transparent areas with color, taken from opaque border area, in this case, black.
This strategy is make easy picture for DXT compression algorithm. Let us save our sprite.
(Achtung!) Do not use .png format: built in CQ png-optimizer will erase "filled transparency" for the sake of improving compression.
(Achtung!) You need ONLY .tga and ONLY in true-color-mode: before saving, select 'TrueColor' in number-of-colors CQ's combo-box.
Then look at the finished VTF:
As you can see, the colors and even the shape of the object is much better preserved.
Probably, I chose not the best example for the sprite. I assure you, I described method is used not only for the salvation of mipmaps, but even for the main picture and very often helps save the color on the edges of the transparent areas.
Just a few another examples. These examples show how "spread out" colors of opaque areas to transparent areas.