获取当前鼠标图片的过程:
1. 首先获取当前HRCURSOR
GetCursor()
2. 然后查询HCURSOR信息,获取对应的HBITMAP信息
GetIconInfo()
3. 查询HBITMAP的BITMAP信息
GetBitmap()
HCURSOR hCursor = GetCursor();
if (hCursor)
{
ICONINFO cursorInfo;
GetIconInfo(hCursor, &cursorInfo);
CBitmap* pBmp = CBitmap::FromHandle(cursorInfo.hbmMask);
BITMAP bm;
if (pBmp!= NULL && pcbmp->GetBitmap(&bm))
{
bm.bmHeight;
bm.bmWidth;
}
}
原文地址:http://blog.csdn.net/chunyexiyu/article/details/39435883