DXT3 gives you 4-bit alpha, meaning 16 values evenly spaced between 0 and 1
for your entire image. DXT5 gives you 3-bit alpha that is interpolated
between 2 grayscale endpoints, meaning you get 8 values linearly spaced
differently for every 4x4 block of pixels in your image. In general, DXT5
provides better results than DXT3 because most 4x4 blocks of alpha don't
cover the full 0-1 range. However, for textures that do cover that range
well, DXT3 would be better quality.
I've thought about analyzing the alpha blocks in a texture to see which
would better represent alpha based on the content of alpha, but it
permanently lives at the bottom of my priority list. I've always defaulted
to DXT5 since it represents smooth gradient alphas better.
Thanks
Alex Vlachos
-----Original Message-----
From: gdalgorithms-list-***@lists.sourceforge.net
[mailto:gdalgorithms-list-***@lists.sourceforge.net] On Behalf Of
***@playstation.sony.com
Sent: Thursday, June 16, 2005 3:06 PM
To: gdalgorithms-***@lists.sourceforge.net
Subject: [Algorithms] DXT3 vs. DXT5 texture compression.
I just implemented DXT3 and DXT5 texture compression in our texture
conversion tool using a vendor-supplied library. I understand the
technical difference between the two formats (explicit vs. interpolated
alpha), but I can't see very much visual difference between DXT3 and DXT5
versions of identical textures. I was wondering what you guys use as your
"default" compressed format for RGBA diffuse/albedo textures, DXT3 or
DXT5, and why?
In case the above question isn't algorithm-ish enough, here's another: Do
you guys tend to use vendor-supplied libraries for texture compression, or
do you roll your own? While I have a general understanding of how to
decode the compressed textures, I have no idea how to encode them and
wouldn't really know where to start rolling my own. Do any of you have
any pointers to texture compression *encoding* algorithm explanations or
source code? Google comes up empty for me, and all the vendors tend to
give out pre-compiled libraries for this task without including source
code. It seems like one would use a variation on standard color
quantization type algorithms, but with enough differences to be, well,
different. So, what type of algorithms do you guys use for DXT style
texture compression if you do in fact write it yourself?
Thanks,
Brad...
-------------------------------------------------------
SF.Net email is sponsored by: Discover Easy Linux Migration Strategies
from IBM. Find simple to follow Roadmaps, straightforward articles,
informative Webcasts and more! Get everything you need to get up to
speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click
_______________________________________________
GDAlgorithms-list mailing list
GDAlgorithms-***@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gdalgorithms-list
Archives:
http://sourceforge.net/mailarchive/forum.php?forum_id=6188