MFC设置坐标画曲线取点

首先声明本程序不是本人全部原创,改编于一个老外的程序,下面是人家编写此程序的原因,表达对大牛的崇拜之情。原程序是一个动态曲线显示。

Author:
	Mehdi Mousavi

Email:
	mehdi_mousavi@hotmail.com
	webmaster@modemmania.com

Date of release:
	14th of April 2001

Description:
	The initial idea of doing this code has been put into my mind when my love asked me
	to go to a clinic in order to check out my heart. You know, doctors have got some
	sort of plotters that plots the information obtained from the heart on a piece of
	paper as a histogram. The idea has been dropped into my mind there!

Dedicated to:
	My love, Cindy

Copyright & disclaimer:
	Permission is granted to distribute *unmodified* version of this source code.
	You are entitled to use CHistogramCtrl for both commercial and/or educational
	purposes as far as you keep these comments intact. Please feel free to post
	any additions to the author.
*/

源程序效果:


1、下面说明自己开发的需求:

      很多同事在工程调试中,包括自己干工程的时候,经常遇到已知现场电压、电流、或者压力、流量曲线(本人电气男),我们需要去拟合出来和现场差不多的曲线,要拟合肯定得需要原始的点数据,所以特别想要一款工具,能够根据自己随手画的曲线和定义好的坐标,方便的取出曲线上任何一个点。

2、工具应该具备的功能:

      能够方便的划出曲线,能够设置横纵坐标,能够方便取点。

3、先给出实现后的效果图:顶部实时动态的显示曲线上任意点的坐标,右击能够清空曲线,设置横纵坐标的范围。这是一个发电机并网大致的升压曲线。

4、源代码

本站下载地址:http://download.csdn.net/detail/dubuzherui/7717949

可执行文件下载地址:http://download.csdn.net/detail/dubuzherui/7717989


具体实现步骤:

首先,肯定是绘制坐标:

然后,利用画线记录在客户区;

最后,捕捉鼠标的位置。


具体代码,下个博文再详细写,赶紧下班回去了。



评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值