关于LINEDDA的用法!

最近阅读关于蚂蚁线的一些方法,在网上找了一些相关的资料,发现在MFC中,能够利用LINEDDA绘制复杂曲线,通过该函数就能够设计蚂蚁线了。

通过查阅MSDN得到:

BOOL LineDDA(  int nXStart,             // x-coordinate of starting point
         int nYStart,             // y-coordinate of starting point
                int nXEnd,               // x-coordinate of ending point
              int nYEnd,               // y-coordinate of ending point
              LINEDDAPROC lpLineFunc,  // callback function
              LPARAM lpData            // application-defined data);

相应的回调函数: 
VOID CALLBACK LineDDAProc(  int X,          // x-coordinate of point
                 int Y,          // y-coordinate of point
                LPARAM lpData   // application-defined data);
利用回调函数中的两个点的坐标值,能够在屏幕上绘制相应的复杂曲线。
通过调用该函数,在OnTimer函数中,利用计数器可以画出蚂蚁线。



转载于:https://www.cnblogs.com/scorpions/archive/2012/12/18/2822803.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值