Re: Re: Dealing with ImageMagick from PHP

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Al: Thanks, sorry for messaging this to the list. Can you point me in the direction of the official phpList forum?

Thanks a ton,
 --Eric





Al wrote:
You'd be far better off asking your questions on the phpList forum.

There are a number of hints on the forum for speeding up things. Plus, look in the examples section.

Eric Holt (PHP List) wrote:
Hello everyone.  This is my first post to the list, so bare with me :)

I have written an application for a client that is used in the Event Photography business. It handles taking photographs, categorizing them, making thumbnails of them, and allows parents(customers) to view the photos and order them. It runs on LAMP, and it really works great.

For the past two years, we've used ImageMagick v4.2.9 to process the thumbnails. Image quality was decent enough, but the main reason for 4.2.9 was SPEED. In my testing, 4.2.9 was quite a bit faster than the lastest releases (in the 6.x.x series). Anyway -- the clients decided they wanted me to do some work on the image quality, so I finally decided to move up to ImageMagick v.6.3.4.

Right now, I call ImageMagick from a "exec" call in PHP. When I first wrote the application, it was the quickest and easiest way for me to get it working. Command-line ImageMagick is pretty simple.

So, with ImageMagick 6.3.4, with the sharpening and compression I'm now using, the clients are absolutely in love with the thumbnail quality -- even though the amount of time it takes to make the thumbnails is much longer. They've asked if anything can be done about that, but I think I've optimized the shell script as much as possible.

Now, after that long rambling... My question is this: Would I see a big speed improvement by using the ImageMagick extension built into PHP (MagicWand, is it called?)? I'd hate to spend all the time recoding the application to work with MagicWand, only to find out that I dont end up with any performance increase -- or worse of all, a decrease.

I wasnt convinced either way, from the Googling I had done on the subject, so I thought I would post the question to the PHP list.

A little more background here, before I go: PHP iterates through a directory of full-sized images, directly out of the camera, and "exec"'s a shell script "thumbcreation.sh" with the details of what ImageMagick needs to do, and where it needs to store the new thumbnails. The script calls convert, which creates a medium sized thumbnail (333x500), and then from that creates a small thumbnail (80x120) from the medium. Then, the script calls composite, where is adds a watermark to the medium size thumbnail, and saves it in the watermarked directory.

In my initial testing, years ago, I found that ImageMagick v4.2.9 was faster than the internal GD library... however, I havnt touched GD since my initial testing. Perhaps GD would be faster now than IM v6.3.4(?).

Okay, I've rambled on plenty now, for my first post. I greatly appreciate any advice anyone on the list could provide.


THANKS!!!
 --Eric


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux