用CDC中的这个函数可以解决缩放显示的问题。 BOOL StretchBlt(int x, int y, int nWidth, int nHeight, CDC* pSrcDC, int xSrc, int ySrc, int nSrcWidth, int nSrcHeight, DWORD dwRop); GDIPLUS中有这个函数也可以(还有几个其它的也行,个人认为这个比较好用) 另外我认为更好用的一个是 Status DrawImage( Image *image, const RectF &destRect, REAL srcx, REAL srcy, REAL srcwidth, REAL srcheight, Unit srcUnit, ImageAttributes *imageAttributes, DrawImageAbort callback, VOID *callbackData ); 这两个解决没有问题。给分吧!
BOOL StretchBlt(int x, int y, int nWidth, int nHeight, CDC* pSrcDC,
int xSrc, int ySrc, int nSrcWidth, int nSrcHeight, DWORD dwRop);
GDIPLUS中有这个函数也可以(还有几个其它的也行,个人认为这个比较好用)
另外我认为更好用的一个是
Status DrawImage( Image *image,
const RectF &destRect,
REAL srcx,
REAL srcy,
REAL srcwidth,
REAL srcheight,
Unit srcUnit,
ImageAttributes *imageAttributes,
DrawImageAbort callback,
VOID *callbackData
); 这两个解决没有问题。给分吧!