看板 Programming 關於我們 聯絡資訊
我有一個小程式,在BitBlt那一行卻總是失敗,我想不出 原因,請問有熟悉DC操作的人能看出失敗的原因是什麼嗎? CDC * pdc; CDC dcCompatible; CDC dcCompatible2; int dWidth; int dHeight; pdc=this->GetDC(); dWidth=pdc->GetDeviceCaps(HORZRES); dHeight=pdc->GetDeviceCaps(VERTRES); //在下面這兩行都回傳成功 pdc->CreateCompatibleDC(&dcCompatible); pdc->CreateCompatibleDC(&dcCompatible2); //在這一行回傳失敗? BitBlt(dcCompatible2,0,0,dWidth,dHeight,dcCompatible,0,0,SRCCOPY); dcCompatible.DeleteDC(); dcCompatible2.DeleteDC(); pdc->DeleteDC(); -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 210.66.243.5