DirectX 9 Texture Image Format

eugene 101 Feb 05, 2012 at 09:23

Hello friends,

Does anybody knows what is the best image format to use for textures in DirectX 9 ?
I have read somewhere that DDS format is Microsoft format for DirectX so I guess this is most optimized format to use ?

Thanks and regards,

3 Replies

Please log in or register to post a reply.

rouncer 103 Feb 06, 2012 at 07:07

DDS is mostly unsupported by the world except direct x tools, and there arent many of them and they are really
quickly written, so i dont recommend it, i recommend using more already worldly known formats, that actually are supported by art programs etc.

use pngs, they are losslessly compressed and can contain an alpha channel.

if you want even more compression jpg is the way to go, megatexture uses lossy jpg compression.

but it doesnt matter what you use, what video memory format you load them in as can be compressed too, but its lossy
so its best to have things in vram lossless and raw data.

hellhound_01 104 Feb 06, 2012 at 08:52

As Rouncer said, there is no specific format you should use. It depends to your tasks.You should look for library like Freeimage or Devil which could handle most common formats…

mmakrzem 101 Feb 06, 2012 at 10:29

If you want to see how to load png files have a look at this video tutorial that I created:

Here is a video tutorial that shows how to integrate the png loader into OpenGL. You should be able to do the same sort of thing using DirectX.