I was using GetDIBits
to get bitmap data from a screen compatible device context into a DIB of a certain format. I was under the impression that the DC was nec
In:
int SetDIBits(
__in HDC hdc,
__in HBITMAP hbmp,
__in UINT uStartScan,
__in UINT cScanLines,
__in const VOID *lpvBits,
__in const BITMAPINFO *lpbmi,
__in UINT fuColorUse
);
The second argument hbmp
is the device dependent bitmap that will be altered using the color information from the device independent bitmap. The hdc
is a handle to the device context on which this (device dependent) bitmap depends. When the call is made, Windows uses information from this device context to decide how to perform the transformation.