//可以无限叠加 你可以试试 //Creater: tech_vina 2011-1-9-15:17 <Wish can help you> // CBitmap bmp0; bmp0.CreateCompatibleBitmap( pDC , rectAll.Width() , rectAll.Height() ); CDC memDC_0; memDC_0.CreateCompatibleDC( pDC ); memDC_0.SelectObject( &bmp0 ); //My Draw Function DrawRealViewLine( &memDC_0 , m_rect_1 , m_rect_2 , m_rect_3 ); pDC-> BitBlt( 0 , 0 , rectAll.Width() , rectAll.Height() , &memDC_0 , 0 , 0 , SRCCOPY ); // CBitmap bmp1; bmp1.CreateCompatibleBitmap(pDC,rectAll.Width(),rectAll.Height()); CDC memDC_1; memDC_1.CreateCompatibleDC(pDC); memDC_1.SelectObject(&bmp1); //My Draw Function DrawPointMessage(&memDC_1); memDC_1.SetBkColor( RGB(0,0,0) ); CBitmap bmp1_mask; bmp1_mask.CreateBitmap( rectAll.Width() , rectAll.Height() , 1 , 1 , NULL ); CDC memDC_1mask; memDC_1mask.CreateCompatibleDC( pDC ); memDC_1mask.SelectObject( &bmp1_mask ); memDC_1mask.BitBlt( 0 , 0 , rectAll.Width() , rectAll.Height() , &memDC_1, 0 , 0 , SRCCOPY ); pDC-> BitBlt( 0 , 0 , rectAll.Width() , rectAll.Height() , &memDC_1, 0 , 0 , SRCINVERT ); pDC-> BitBlt( 0 , 0 , rectAll.Width() , rectAll.Height() , &memDC_1mask, 0 , 0 , SRCAND ); pDC-> BitBlt( 0 , 0 , rectAll.Width() , rectAll.Height() , &memDC_1, 0 , 0 , SRCINVERT ); //
//如果有人有改进方案请回帖
//如果有人有改進方案請回帖