Table of contents
Collapse the table of content
Expand the table of content

Extended Surface Description Structure

Last Updated: 2/14/2017

The extended DirectDraw surface description structure, DDSURFACEDESC2, is identical to the DDSURFACEDESC structure, except that the pointer to the DDSCAPS structure at the end of the structure has been replaced with a pointer to a DDSCAPS2 structure.

The data blocks for the DdCreateSurface and DdCanCreateSurface driver calls each contain a pointer to a DDSURFACEDESC structure. Beginning with DirectX 6.0, these pointers might actually point to a DDSURFACEDESC2 structure, even though the pointers remain typed as LPDDSURFACEDESC. If a driver chooses, it can examine the dwSize member of the DDSURFACEDESC pointer, and thereby decide if the pointer actually points to a DDSURFACEDESC2 structure. If your driver must run on pre-DirectX 6.0 installations, it must make this check.

If the size returned is sizeof(DDSURFACEDESC2), the driver can then examine the dwCaps2, dwCaps3, and dwCaps4 members of the DDSCAPS2 structure.

Send comments about this topic to Microsoft

© 2017 Microsoft