- IPicture中Render()函数的使用方法
- 这个函数的那几个参数的中文意思到底是什么?MSDN中是这样描述的
- HRESULT Render(
- HDC hdc, //Handle of device context on which to render the image
- long x, //Horizontal position of image in hdc
- long y, //Vertical position of image in hdc
- long cx, //Horizontal dimension of destination rectangle
- long cy, //Vertical dimension of destination rectangle
- OLE_XPOS_HIMETRIC xSrc, //Horizontal offset in source picture
- OLE_YPOS_HIMETRIC ySrc, //Vertical offset in source picture
- OLE_XSIZE_HIMETRIC cxSrc, //Amount to copy horizontally in source picture
- OLE_YSIZE_HIMETRIC cySrc, //Amount to copy vertically in source picture
- LPCRECT prcWBounds //Pointer to position of destination for a metafile hdc
- );
- 这个功能显示一张大图画中的一部分
- hdc:不用说了吧
- x,y是hdc上的横纵坐标起点,cx,cy是终点,也就是说,画在hdc上的是一个矩形,xy是左上角坐标,cxcy是右下角坐标。
- xsrc,ysrc,cxsrc,cysrc也是矩形的左上和右下角坐标,是说明这张大图中要显示到hdc上的部分。
- 从src这个图中取出xsrc,ysrc,cxsrc,cysrc这部分,贴在x,y,cx,cy这块区域上面
IPicture中Render()函数的使用方法
最新推荐文章于 2023-10-23 15:10:22 发布