Platform SDK: DirectX

Mode X and Mode 13 Display Modes

DirectDraw supports both Mode 13 and Mode X display modes. Mode 13 is the linear unflippable 320×200×8 bits per pixel palettized mode known widely by its hexadecimal BIOS mode number: 13. For more information, see Mode 13 Support. Mode X is a hybrid display mode derived from the standard VGA Mode 13. This mode allows the use of up to 256 kilobytes (KB) of display memory (rather than the 64 KB allowed by Mode 13) by using the VGA display adapter's EGA multiple video plane system.

DirectDraw provides two Mode X modes (320×200×8 and 320×240×8) for all display cards. Some cards also support linear low-resolution modes. In linear low-resolution modes, the primary surface can be locked and directly accessed. This is not possible in Mode X modes.

[C++]

Mode X modes are available only if an application uses the DDSCL_ALLOWMODEX, DDSCL_FULLSCREEN, and DDSCL_EXCLUSIVE flags when calling the IDirectDraw7::SetCooperativeLevel method. If DDSCL_ALLOWMODEX is not specified, the IDirectDraw7::EnumDisplayModes method will not enumerate Mode X modes, and the IDirectDraw7::SetDisplayMode method will fail if a Mode X mode is requested.

Windows 95 and Windows NT/Windows 2000 do not natively support Mode X modes; therefore, when your application is in a Mode X mode, you cannot use the IDirectDrawSurface7::Lock or IDirectDrawSurface7::Blt methods to lock or blit to the primary surface. You also cannot use either the IDirectDrawSurface7::GetDC method on the primary surface, or GDI with a screen DC. Mode X modes are indicated by the DDSCAPS_MODEX flag in the DDSCAPS2 structure, which is part of the DDSURFACEDESC2 structure returned by the IDirectDrawSurface7::GetCaps and IDirectDraw7::EnumDisplayModes methods.

[Visual Basic]

Mode X modes are available only if an application uses the DDSCL_ALLOWMODEX, DDSCL_FULLSCREEN, and DDSCL_EXCLUSIVE flags when calling the DirectDraw7.SetCooperativeLevel method. If DDSCL_ALLOWMODEX is not specified when setting the cooperative level, the DirectDraw7.GetDisplayModesEnum method will not enumerate Mode X modes, and the DirectDraw7.SetDisplayMode method will fail if a Mode X mode is requested.

Windows 95 and Windows NT/Windows 2000 do not natively support Mode X modes; therefore, when your application is in a Mode X mode, you cannot use the DirectDrawSurface7.Lock or DirectDrawSurface7.Blt methods to lock or blit to the primary surface. You also cannot use either the DirectDrawSurface7.GetDC method on the primary surface, or GDI with a screen DC. Mode X modes are indicated by the DDSCAPS_MODEX flag in the DDSCAPS2 type, which is part of the DDSURFACEDESC2 type returned by the DirectDrawSurface7.GetCaps and DirectDrawEnumModes methods.