790
社区成员
发帖
与我相关
我的任务
分享
CBitmap bmp;
long tt = bmp.LoadBitmap(IDB_BG);//资源id
CPaintDC dc(this);
CDC mem;
mem.CreateCompatibleDC(&dc);
CBitmap* pOld=(CBitmap*)mem.SelectObject(&bmp);
BITMAP bm;
bmp.GetBitmap(&bm);
dc.StretchBlt(0,0,bm.bmWidth,bm.bmHeight,&mem,0,0,bm.bmWidth,bm.bmHeight,SRCCOPY);
mem.SelectObject(pOld);