The XDK has a tool called the Bundler Utility. It is a command line utility which opens a resource definition file and performs whatever tasks the RDF file says to.
Suppose a file called "bmptoxbx.rdf" existed and had the following content:
Texture
{
Source title.bmp
Format D3DFMT_DXT1
Width 128
Height 128
}
At the command line, typing "bundler bmptoxbx.rdf -o titleimage.xbx" will convert the file "title.bmp" to "titleimage.xbx".
Now suppose you had a file called "xbxtobmp.rdf" with the following content:
Texture
{
Source titleimage.xbx
Format D3DFMT_R8G8B8
Width 128
Height 128
}
Then by running "bundler xbxtobmp.rdf -o title.bmp" it will convert it back into a 24 bit bitmap which you can then use in your application.
The other option is to create a surface in memory with the format D3DFMT_DXT1, load the XBX file into the surface using D3DXLoadSurfaceFromFileA, create a second surface in memory with the format D3DFMT_R8G8B8 and then run D3DXLoadSurfaceFromSurface. I think this function will automatically adjust the formats of the source surface to match the destination surface.
Hope this helps!