日期:2014-05-17 浏览次数:21756 次
public struct LPBITMAPINFOHEADER
{
public UInt32 biSize;//DWORD=UInt32
public Int32 biWidth;
public Int32 biHeight;
public UInt16 biPlanes;// WORD=UInt16
public UInt16 biBitCount;
public UInt32 biCompression;
public UInt32 biSizeImage;
public Int32 biXPelsPerMeter;
public Int32 biYPelsPerMeter;
public UInt32 biClrUsed;
public UInt32 biClrImportant;
}
unsafe static LPBITMAPINFOHEADER* lpbi;
typedef struct tagBITMAPINFOHEADER{
DWORD biSize;
LONG biWidth;
LONG biHeight;
WORD biPlanes;
WORD biBitCount;
DWORD biCompression;
DWORD biSizeImage;
LONG biXPelsPerMeter;
LONG biYPelsPerMeter;
DWORD biClrUsed;
DWORD biClrImportant;
} BITMAPINFOHEADER, FAR *LPBITMAPINFOHEADER, *PBITMAPINFOHEADER;//定义
LPBITMAPINFOHEADER lpbi;//定义
lpbi = (LPBITMAPINFOHEADER)GlobalAlloc(GPTR, 2000 * 2000 * 4 + 5120);//这句赋值是在窗体加载函数里执行的