long DrawImage( HDC bd, B_Rect *src, B_Rect *dst, PImg pImg)
{
}其中B_Rect的定义如下
typedef struct {
long x;
long y;
long w;//width
long h;//height
} B_Rect;PImg 的定义如下:typedef struct ImgStruct {
int w;//width
int h;//height
int bpps;//位深
void * data;//句柄
}Img, *PImg;
{
}其中B_Rect的定义如下
typedef struct {
long x;
long y;
long w;//width
long h;//height
} B_Rect;PImg 的定义如下:typedef struct ImgStruct {
int w;//width
int h;//height
int bpps;//位深
void * data;//句柄
}Img, *PImg;
解决方案 »
- 帮忙分析下,下面是哪种错误啊?在线等
- 关于无模式对话框的问题
- 求助!~~
- **********************请教关于b/s中调用c++写的dll的问题***************************
- 怎么在RedHat9.0中不能用Libpcap库?编译老报错??郁闷
- 为什么我在DLL里面DoModal()出来的对话框总在最上面,我都传了父窗口的HWND进去了还是不行???怎么办?
- 怎样根据IP地址查他的实际地址啊?
- 一个初学者的起步问题(2)
- mfc 数据库编程疑问?
- 同志们哪,哪里有Windows NetMeeting的相关资料,需要做一个与其中白板功能类似的东东
- 一个delete问题
- vc++ com 和 javascript 高手 请进
{
HDC hdcDest = bd;
HDC hdcMem;
HBITMAP hBitmap;
int nWidth = pImg->w;
int nHeight = pImg->h;
int nBits = pImg->bpps;
BYTE* pBits = (BYTE*)pImg->data; // 检查参数
if(hdcSrc == NULL || src == NULL ||
dst == NULL || pImg == NULL)
{
return -1L;
} hdcMem = CreateCompatibleDC(hSrcDC);
hBitmap = CreateBitmap(nWidth, nHeight, 1, nBits, pBits); SelectObject(hdcMem, hBitmap);
StretchBlt(hdcDest, dst->x, dst->y, dst->w, dst->h,
hdcMem, 0, 0, src->w, src->h); DelectDC(hdcMem); return 1L;
}