您的位置:首页 > 编程语言

CreateDIBSection创建32*32的32位位图的代码段

2011-04-14 15:00 113 查看
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);
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  colors null bi