摘要: 1.定义点函数: SetPixel(hDC,x,y,crColor); hDC为句柄,x,y为点坐标,crColor为颜色。 GetPixel(hDC,x,y)获取该点的像素点; COLORREF crColor = GetPixel(hDC,x,y); 2.画直线: a.利用MoveToEx函数和 阅读全文
posted @ 2016-08-05 20:46 xiaofeiyang 阅读(240) 评论(0) 推荐(0) 编辑
摘要: 1.获取设备描述表句柄:a. hdc = BeginPaint(hwnd,&ps); //other program lines EndPaint(hwnd,&ps); BeginPaint调用使整个客户区有效(阻止WM_PAINT消息一直发送),填充 ps结构的字段,返回的设备描述句柄。使用这个句 阅读全文
posted @ 2016-08-05 16:22 xiaofeiyang 阅读(654) 评论(0) 推荐(0) 编辑