CDC::LoadBitmap函数能够将基于资源的DIB转换成GDI位图。
例:
CMyView::OnDraw(CDC *pDC)
{
CBitmap bitmap;
CDC dcMemory;
bitmap.LoadBitmap(IDB_BITMAP);
dcMemory.CreateCompatibleDC(pDC);
dcMemory.SelectObject(&bitmap);
pDC->BitBlt(100,100,54,96,&dcMemory,0,0,SRCCOPY);
}
转载于:https://www.cnblogs.com/angeljicu/archive/2004/08/13/33188.html