User (Legacy) Posted December 7, 2006 Report Share Posted December 7, 2006 Hello, I'm using ChartFX for .NET for quite a while. It displays data from acquisitions and allows the user to create, modify, move annotations such as arrows, texts, etc... Everything works just fine, as long as the amount of data is small. But if the acquisition gets a little longer, moving an annotation in the chart is a pain in the neck: everything goes jerky. I noticed that the CPU load was very important when the mouse is located in the chart and the chart has a lot of values. Tough luck: in my application, the chart is displayed full screen and of course, the mouse is (almost) always located in the chart area. I used an old test program to try to figure out what was going on. It is included in this message as a ZIP file. With 10 curves with 3000 points each, the CPU load is around 20% when you place the mouse cursor on the chart area. But with 10 curves of 30000 points each, the CPU load sometimes goes up to 100% !!! I guess it has to do with the mouse events, but is there a way to keep it from using all the CPU power ? Thanks in advance. Bruno PS: the same thing happens with ChartFX for Visual Studio 2005. Link to comment Share on other sites More sharing options...
Software FX Posted December 11, 2006 Report Share Posted December 11, 2006 What's using the CPU power is Chart FX trying to determine which point was hit in order to highlight and display a tooltip. You can disable these by doing: chart1.Highlight.Enabled = false; chart1.ShowTips = false; -- Francisco Padron www.chartfx.com EssaiChartFX.zip Link to comment Share on other sites More sharing options...
User (Legacy) Posted December 19, 2006 Author Report Share Posted December 19, 2006 Thanks, it worked fine on the test program, but did little on the actual application. When I drag an annotation with the mouse, ChartFX repaints the whole chart at each mouse event, and because I'm using a lot of points (say 6 series of 90000 points each) , it takes ages (well, seconds) to repaint. Is there a way to tell ChartFX that it can repaint the selected annotation (the one that I'm dragging), but not the others, and especially not the curves ? Thanks in advance. Bruno Link to comment Share on other sites More sharing options...
Software FX Posted December 19, 2006 Report Share Posted December 19, 2006 Dragging the annotation should not cause any repainting until you release the mouse, if this is not the behavior you are getting please modify the sample program accordingly to show the problem. I was unable to reproduce it simply by adding an annotation object to the chart. Once you release the mouse, in order to paint the annotation it must paint what was behind the annotation and this includes the curves. -- Francisco Padron www.chartfx.com Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.