Jump to content
Software FX Community

How can I improve surface chart display efficiency?


Recommended Posts

Hello, I don't know what happened, my question didn't display. About surface chart in Chartfx for 2005, I need use surface chart with 40 thousand points and refresh it per 5 seconds. (computer is 2.8G CPU, 1G memory, 256M Display Card) In my attempt, chartfx build so surface chart using above 30 seconds. My code is refer to help files and set each point value in loop.How many times does Chartfx spend displaying 40 thousand poins in surface chart?How to improve surface chart display efficiency?Thanks. I look forward to your reply.

Link to comment
Share on other sites

Well this all depends.

Usually, 40,000 will take some time to draw, specially in any 3D chart.

Setting the data and painting the chart are two different things. You can measure the time you are consuming passing the data very easily since this is in your code. Unless your code is inherently slow, passing data is not usually a performance bottleneck in Chart FX.

I wrote the following sample code to create a 40,000 surface chart. The code executes immediately (93 ms) However the chart takes about 8 secs to draw in my computer at full screen size:

chart1.Gallery =

Gallery.Surface;chart1.View3D.Enabled = true;


int n = 200;

chart1.Data.Series = n;

chart1.Data.Points = n;

for (int i = 0; i < n; i++) {

 for (int j = 0; j < n; j++) {  chart1.Data[i,j] = Math.Sin((i * 3*Math.PI)/n) * Math.Cos((j * 3*Math.PI)/n) * 100;



There is not much you can do to improve this paint performance.

Some gains can be obtained by reducing the number of color levels. For example, in my code you can add:


Surface) chart1.GalleryAttributes).Step = 50;

Reducing the amount of points by compacting your data is the path that will provide the higher performance gains 



Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...