Quinn-Curtis Forums
Quinn-Curtis Forums
Home | Profile | Register | Active Topics | Members | Search | FAQ
Save Password
Forgot your Password?

 All Forums
 Tools for Microsoft .Net & .Net Compact Framework
 Real-Time Graphics Tools for .Net (VB and C#)
 Questions regarding Autotruncation
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  


51 Posts

Posted - 20 Aug 2015 :  14:14:00  Show Profile  Reply with Quote
In one of my projects I am using the rtgraph in "cumulative" mode, that is, ScrollScaleModeX = ChartObj.RT_MAXEXTENT_FIXEDSTART_AUTOSCROLL. And I have AutoTruncateMaxCount = 100000 and AutoTruncateMinCount=1000. Unfortunately, the customer wants the graph to "go on forever". Of course this is not possible to due to memory constraints and performance and I have a few questions.

1. if I dont set AutoTruncateMaxCount, does it default to something? (MAX_INT perhaps?)
2. if I dont set AutoTruncateMinCount, does it default to something?
3. Is there a way to trap that an auto-truncation has occured ? (short of keeping count of the points myself)?
4. I am using an elapsed time scale for my x-axis. If a truncation has occured, I would like to shift the StartX to the new minimum. For example, say the graph is displaying from 0 to X seconds, where X is increasing, and now a truncation occurs at, say 10 seconds. I now want the graph to start displaying from 10 to 11, 10 to 12 etc as new data comes in. Is there a way to do this? Would appreciate any help.



1571 Posts

Posted - 20 Aug 2015 :  15:13:56  Show Profile  Reply with Quote
1. Default AutoTruncateMaxCount is 1000
2. Default AutoTruncateMinCount is 500
Default AutoTruncateDataset is false

3. Use the RTDatasetTruncateEventHandler or RTGroupDatasetTruncateEventHandler to trap the auto-truncate event . See the manual and the the FetalMonitor and Dynamometer example programs.

4. Then you do NOT want RT_MAXEXTENT_FIXEDSTART_AUTOSCROLL. Use RT_FIXEDEXTENT_MOVINGSTART_AUTOSCROLL with a ScrollRescaleMargin of something like 0.9. In this case, when the current data reaches the right hand edge of the graph scale, it then shift the graph scale back 90% towards the left edge of the chart.

scrollFrame = new RTScrollFrame(this, currentTemperature1, pTransform1, ChartObj.RT_FIXEDEXTENT_MOVINGSTART_AUTOSCROLL);
scrollFrame.ScrollRescaleMargin = 0.9;

Make sure you keep enough in the data buffer so that when the RTScrollFrame resets the starting and ending points of the chart, that the chart can fill from the beginning of the chart to where new data is added (10% away from the start of the graph).
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
Quinn-Curtis Forums © 2000-2018 Quinn-Curtis, Inc. Go To Top Of Page
Powered By: Snitz Forums 2000 Version 3.4.07