EngCreateDeviceBitmap function (winddi.h)

The EngCreateDeviceBitmap function requests GDI to create a handle for a device bitmap.

Syntax

ENGAPI HBITMAP EngCreateDeviceBitmap(
  [in] DHSURF dhsurf,
  [in] SIZEL  sizl,
       ULONG  iFormatCompat
);

Parameters

[in] dhsurf

Device handle to the device bitmap to be created.

[in] sizl

Specifies a SIZEL structure that contains the width and height of the bitmap to be created. The cx and cy members of this structure contain respectively, the bitmap's width and height, in pixels. A SIZEL structure is identical to a SIZE structure.

iFormatCompat

Specifies the compatible engine format of the device surface being created. This is used by GDI if a temporary buffer is needed to simulate a complicated drawing call. The allowable values for iFormatCompat are BMF_1BPP, BMF_4BPP, BMF_8BPP, BMF_16BPP, BMF_24BPP, and BMF_32BPP.

Return value

The return value is a handle that identifies the bitmap if the function is successful. Otherwise, it is zero, and an error code is logged.

Remarks

The surface should be associated by using EngAssociateSurface. The bitmap should be deleted by calling EngDeleteSurface when it is no longer needed.

Requirements

Requirement Value
Minimum supported client Available in Windows 2000 and later versions of the Windows operating systems.
Target Platform Universal
Header winddi.h (include Winddi.h)
Library Win32k.lib
DLL Win32k.sys

See also

EngCreateBitmap