Alexander Klenin wrote:
OK, that's working :)With linedemo: 1) Add TListChartSource component 2) Edit its DataPoints property, enter 1,2,...,10 on a separate lines 3) Set Marks.Source for bottom axis to that source 4) Set Marks.Style to smsXValue Of course, you can use UserDefinedSource instead for better efficiency.
Well of course I don't look at the entire graph at once. I zoom in to maybe 10 or 20 points at a time and use a scroll bar the pan the chart. It's a run of data that I captured from a logic analyzer. So when I'm zoomed-in, there's an appreciable distance between data points :)On the one hand, that is ridiculously large dataset -- averaging more than five data points per x-axis pixel (!). On the other hand, you are not the first user who does this, so I guess there is some reason for such datatsets ;-)
This seems counter to what I observed. I can take a data set of 100 points and zoom in so I'm displaying only 10 points and drag a vertical line around just fine. Expand the data set to 10k points and look at the same 10-point window, but now the line lags and the draw event seems to be much slower. The calls to ACanvas.Line should be the same in both cases, shouldn't they? In other words, the time to draw should be unchanged. I mostly cut and pasted the code from the draw routine for my user-defined series. What was different/what I think was faster was the mapping between the chart's logical extent and my data set.I have added simple time measurement to linedemo and performed some experiments. It turned out that the most expensive callis ACanvas.Line itself.
So before we go there, please test the current version -- maybe it is already good enough?
I tried the latest version but there's really no change as compared to before. The draw routine still takes a significant amount of time with 32x10240 series, zoomed in to a window of just 10 points. I attached a screenshot so you can see. Graphically, this should not be difficult
at all to draw. Most of the lines are even straight.
<<inline: Clipboard01.png>>
-- _______________________________________________ Lazarus mailing list [email protected] http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
