ViewPolar - linesize and memory usage

A forum dedicated to WinForms version of LightningChart Ultimate.

Moderator: Queue Moderators

Post Reply
ahe
Posts: 51
Joined: Tue Aug 11, 2015 4:33 pm
Location: Düsseldorf, DE

ViewPolar - linesize and memory usage

Post by ahe » Fri Nov 27, 2015 10:51 am

In our application the user can set the line size of each diagram at runtime. We noticed that setting linesizes > 1 resulted in much higher memory usage.

I added my sample code which creates a polar diagram with one point line series with 150.000 points and alternates the linesize between 1 and 2 every two seconds.

Memory consumption is about 300-400 MB for linesize = 1
Polar_memory_linesize1.png
Polar_memory_linesize1.png (74.07 KiB) Viewed 5695 times
and 600-900 MB with linesize = 2.
Polar_memory_linesize2.png
Polar_memory_linesize2.png (72.42 KiB) Viewed 5695 times
So far the values stay consistent after 30 minutes, so I don't think there's a memory leak.

Is there a technical explanation why larger linesizes result in such memory requirements?
Attachments
AL_Polar_Linesize.zip
(14.54 KiB) Downloaded 487 times

User avatar
ArctionPasi
Posts: 1367
Joined: Tue Mar 26, 2013 10:57 pm
Location: Finland
Contact:

Re: ViewPolar - linesize and memory usage

Post by ArctionPasi » Fri Nov 27, 2015 7:58 pm

When using LineWidth = 1, just the line end points are calculated and given to GPU.

When LineWidth > 1, the lines have to triangulated (tesselated) in LightningChart side and given as a little triangles for GPU. Memory required for that is many times larger than with line width of 1.
LightningChart Support Team, PT

Post Reply