본문 바로가기

work/delphi

Re:TeeChart TFastLineSeries Leak/Memory Increase

Hello,
Thank you for your assistance David.
I am using the TeeChart component populated with multiple TFastLineSeries on two different forms for different purposes.
I have adopted David’s recommendation (calling FreeAllSeries) for freeing the set of Series for both instances.
I found that this change appears to have completely eliminated any growth in memory for one of the TeeCharts.
However, the other form that uses the TeeChart component is still experiencing memory growth. The update of the TeeChart
contents on this form happens periodically (approx. every second) as follows:
1. Clear the TeeChart data from the previous cycle by calling FreeAllSeries.
2. Create four new series and populate each with their corresponding data by calling AddXY for each data point.
I have found the following:
1. The number of series and the count of each series after Step 2 at the end of one cycle is the same as at the
beginning of the next cycle. So, I am confident that the series are not being modified between cycles and I am
freeing the set of Series correctly.
2. If I call FreeAllSeries at the end of each cycle then the memory growth stops. However, as expected the call to
FreeAllSeries empties all series and the TeeChart is always empty.
3. The number of times I call AddXY per cycle and consequently the resulting count of each series does not impact
the rate of memory growth.
My questions are as follows:
1. Are there any other resources that I need to free in addition to the Series?
2. Is there any property setting or other known reason that would contribute to memory growth?
3. Does anyone have any recommendations to eliminate the growth in memory that I am experiencing?
Thank you,
Joe