Forum Moderators: coopster

Message Too Old, No Replies

performance of GD dynamic thumbnail generation

         

scorpion

2:16 pm on Jun 18, 2003 (gmt 0)

10+ Year Member



I'm generating thumbnails about 5-10 on the fly when the user requests a page that does not have thumbnails for the gallery (I use GD 2+).

I've noticed it is quite slow, causing a delay of several seconds before the gallery loads.

Anyone know how to optimize this process to make it faster?

Note, this is a one time thing - once the thumbs are generated for a gallery, they are not made again.

Is it a better strategy to premake all the thumbs for all the galleries in the background by calling the routine from a main page (to act like a "cache"). Although I've noticed this has its disadvantages, namely php won't load the page until it has done its "thumbing actions"

jatar_k

10:55 pm on Jun 18, 2003 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



When you upload the pick make it create the thumbnail then and save it to thumbnail dir. I usually make the name the same except it starts with "t_".

Makes serving them dynamically very simple.