What is the HDC for in GetDIBits?

后端 未结 1 381
无人共我
无人共我 2021-01-05 23:04

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

相关标签:
1条回答
  • 2021-01-05 23:36

    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.

    0 讨论(0)
提交回复
热议问题