Platform SDK: DirectX |
A surface can contain a bitmap to be used for texturing 3-D objects. When creating the surface you must specify the DDSCAPS_TEXTURE flag in the dwFlags member of the DDSCAPS structure.
A surface can contain a bitmap to be used for texturing 3-D objects. When creating the surface you must specify the DDSCAPS_TEXTURE flag in the lCaps member of the DDSCAPS2 type.
For more information on the use of textures in Direct3D Immediate Mode, see Textures.
In order to reduce the amount of memory consumed by textures, DirectDraw supports the compression of texture surfaces.
Some Direct3D devices support compressed texture surfaces natively. On such devices, once you have created a compressed surface and loaded the data into it, the surface can be used in Direct3D just like any other texture surface. Direct3D handles decompression when the texture is mapped to a 3-D object.
Other devices do not support compressed texture surfaces natively. When using such devices, you may still find it useful to use compressed surfaces to represent textures on disk or for textures that are loaded into memory but not currently being used. You can use DirectDraw to convert the compressed textures to an uncompressed format before giving the texture to Direct3D.
For more information on texture compression in DirectDraw, see the following topics.
For information on using compressed textures in Direct3D Immediate Mode, see Texture Compression.