View unanswered posts | View active topics It is currently Sat Apr 20, 2024 2:48 am



Reply to topic  [ 5 posts ] 
Quite Long Load Time 
Author Message
New pChart user
New pChart user

Joined: Fri Oct 14, 2011 11:50 am
Posts: 3
Post Quite Long Load Time
Hey!

I've just downloaded pChart and created my first radar graph.

I'm extremely impressed and I'll most likely implement it on my web page (and of course pay you guys a well deserved donation).

However, I have one concern. When I load the image in my browser, there's a roughly two second delay (waiting for server...)

Why is that?
Is it very cpu intensive?
Is there a way to reduce the wait, like in increasing the step size in some iteration or something?


Fri Oct 14, 2011 11:56 am
Profile
New pChart user
New pChart user

Joined: Fri Oct 14, 2011 11:50 am
Posts: 3
Post Re: Quite Long Load Time
I've turned off antialisasing in the beginning and turn it on again just before the final image is rendered.

$myPicture = new pImage(400,400,$MyData);
$myPicture->Antialias=false;

$myPicture->Antialias=true;
$SplitChart->drawRadar($myPicture,$MyData,$Options);

This helps a little bit, but not much.

I only input five arrays, each with three floating point values. So there shouldn't bee too much data either.
I'm using Hostgator VPS.

Any advice is highly appreciated ;)


Mon Oct 17, 2011 12:59 pm
Profile
Regular pChart user
Regular pChart user

Joined: Wed Feb 09, 2011 8:13 pm
Posts: 15
Post Re: Quite Long Load Time
Hi,

Same for me, on a cpu 1ghz, I need 2.5 seconds to generate (not for load from the web page) a 900x400 graph.
Cause is GD library who needs cpu time for generate image.

If you make a little debug, all waste of time is by GD functions used in pchart class.


Fri Nov 11, 2011 4:19 pm
Profile
New pChart user
New pChart user

Joined: Fri Oct 14, 2011 11:50 am
Posts: 3
Post Re: Quite Long Load Time
Tnx for sharing this :)
Do you know which changes I can make to the library for the load time to decrease?


Sun Nov 20, 2011 7:19 pm
Profile
Regular pChart user
Regular pChart user

Joined: Wed Feb 09, 2011 8:13 pm
Posts: 15
Post Re: Quite Long Load Time
No idea.
And a web search give me no results.


Sun Nov 20, 2011 8:16 pm
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 5 posts ] 

Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron