DWORD nWidth = 32;
DWORD nHeight = 32;
PVOIL pBits = NULL;
BITMAPINFO bi;
bi.bmiHeader.biSize = sizeof(BITMAPINFOHEADER);
bi.bmiHeader.biWidth = nWidth;
bi.bmiHeader.biHeight = nHeight;
bi.bmiHeader.biPlanes = 1;
bi.bmiHeader.biBitCount = 32;
bi.bmiHeader.biCompression = BI_RGB;
bi.bmiHeader.biSizeImage = nHeight * nWidth * 4;
CreateDIBSection(NULL, &bi, DIB_RGB_COLORS, &pBits, NULL, NULL);
CreateDIBSection创建32*32的32位位图的代码段
最新推荐文章于 2020-06-03 15:46:00 发布