标签:led sel 位图 obj ati sele cto oid this
void CBRUSHTESTDlg::OnPaint() { CPaintDC dc(this); CBitmap bmp; bmp.LoadBitmap(IDB_BITMAP1); BITMAP bitmap; int size = bmp.GetBitmap(&bitmap); CDC memDC; memDC.CreateCompatibleDC(&dc); memDC.SelectObject(&bmp); dc.BitBlt(10, 10, bitmap.bmWidth, bitmap.bmHeight, &memDC, 0, 0, SRCCOPY); //向窗口中绘制位图 }
void CBRUSHTESTDlg::OnPaint() { CPaintDC dc(this); CBitmap bmp; bmp.LoadBitmap(IDB_BITMAP1); BITMAP bitmap; int size = bmp.GetBitmap(&bitmap); CDC memDC; memDC.CreateCompatibleDC(&dc); memDC.SelectObject(&bmp); dc.SetStretchBltMode(STRETCH_HALFTONE); dc.StretchBlt(0, 0, bitmap.bmWidth, bitmap.bmHeight, &memDC, 0, 0, bitmap.bmWidth, bitmap.bmHeight, SRCCOPY); //向窗口中绘制位图 }
标签:led sel 位图 obj ati sele cto oid this
原文地址:https://www.cnblogs.com/veis/p/12838159.html