D3TexConv

About
The D3TexConv tool dumps the data from 1 or more tex files, outputting dds files for the image(s) and tab delimited txt files for the embedded atlas data for each image.

Any queries or feedback can be directed to me (TheUnknownSoldier/Necrolis) on Blizzhackers.

Current Limitations
The Version 0.9 has the following limitations:


 * No cubemap support
 * Some decodes may fail due to my cheap stride/decode method stuff need a test file for these too :)
 * Two Phase decoding is not done, though I have yet to find a 2 phase file, this is the first thing on my list to add
 * Only outputs DDS files, will add other formats when the core is complete
 * Although files are semi-checked, passing non-existent files will crash the tool
 * You can only drop about 400 files at a time onto the tool, this is a Windows limit

It is coded in C using nothing but standard functions, which means it theoretically can be compiled for Mac & Linux too, as the full source is included. It also provides the most complete mapping of the tex file format to date.

Usage
Just drag and drop one or more tex files onto the executable, or use a script file if you so please. The files will be generated in the same folder as the tex file, with the same name (but different extensions).

The output files will be outputted to where the source tex file was, so if you have a file, "C:\Diablo III\Textures\MyTexture.tex" and you drop it onto D3TexConv.exe, your ouputted files will be:
 * "C:\Diablo III\Textures\MyTexture.dds"
 * "C:\Diablo III\Textures\MyTexture.txt" (if there is any atlas data)

Windows XP seems to have a problem with drag and drop processing, so output files land up in "Documents & Settings\"

Currently Supported Formats
Currently only the following input formats (internal to the tex file) are supported:
 * DXT1
 * DXT3
 * DXT5
 * A8R8G8B8
 * A1R5G5B5
 * L8

If any formats are found that do not decode (with an unsupported format message), please notify me with the file name and format

Version 0.9

 * Added support for A1R5G5B5 for the two files that use it
 * Added support for L8 for the only file in 9k textures that uses it
 * All currently used formats are now supported

Version 0.8

 * Added support for A8R8G8B8 textures (note: D3 has some non power of 2 textures, which fill fail on some readers, infranview opens them though)

Version 0.7

 * Fixed DXT1 decompression
 * Fixed some other misc bugs
 * Added proper Mip support
 * Fixed the atlas output and made it nicer, tab delimited data (you now get float and int outputs)

Version 0.6

 * Initial public version

Credits

 * plash - for pointing out various things here and there (mainly the incorrect atlas names).
 * Fiel & npd2006 - for giving me much needed testing feedback :)

Current version
Includes binary and full source code: Version 0.9

For viewing and converting of the DDS files, it is recommended you use InfranView or nVidia's Texture Tools for Photoshop

Older Versions

 * Version 0.8
 * Version 0.7
 * Version 0.6

Example Output

 * Texture Output
 * Atlas Output

ToDo

 * Add 2 phase decoding support (yet to find something that needs this though)
 * Correct header decoding, instead of the current simple method, which might have scanline stride errors and incorrect phase-2 decode info
 * DDS + Atlas to Tex conversion tool, to make one's own textures (for the modders)
 * Output in TGA and PNG formats (this will be done last, as many DDS to xxx converters already exist)
 * Support atlas-based image slicing
 * Cubemap support