TiPlotChannelCustom.MemoryUsed

TiPlotChannelCustom

Retrieves the currently allocated memory in use by the channel.

property MemoryUsed : Integer;

Description

Use MemoryUsed to retrieve the the currently allocated bytes of memory in use by the channel.

As you are adding data points to the channel, whenever this MemoryUsed limit is reached, additional memory is allocated to enhance memory utilization performance. The amount of memory allocated is increased by 25% each time.

For example, if the MemoryUsed is 1,000,000 bytes and you have just exceeded that allocation when adding data points, the capacity will jump to 1,250,000 bytes. When you exceed 1,250,000 bytes, the capacity will jump by another 25%. What this does is allocate memory for the channel in the operating system in "chunks" instead of allocating more memory after each data point addition, saving processor time and operating system memory management overhead.

Note: This property is generally not needed by the typical application, and is for informational purposes only. Memory allocation in the channel is automatic, and this property represents the current, automatically allocated amount of memory in use by the channel.

===================================================

Actual Data Point Count
: if you simply want to know the number of actual data points added to the chart, use the Count property.

Currently Allocated Number of Data Points: if you want to know the number of data points allocated by the channel, use the Capacity property instead.

Manual Memory Allocation: If you are adding a large number of data points to the chart, you can manually allocate memory by simply setting the Count property of the channel to the number of data points you wish to add so that the memory can be allocated all at once to save operating system overhead.

===================================================

Example

Delphi

Value := iComponent.Channel[0].MemoryUsed;

C++ Builder

Value = iComponent->Channel[0]->MemoryUsed;

Note: This property is Read-Only

Contents | Index | Previous | Next