Re: JPEG info needed

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

 



On Mon, January 22, 2007 9:46 pm, Gerry D wrote:
> I need PHP to find out if a jpeg file uses progressive encoding. None
> of the standard exif or image functions seem to be able to tell me
> that. (please correct me if I'm wrong)

I don't know of any function, and the ever-populare
http://php.net/getimagesize doesn't seem to do it.

You may be able to hack it with http://php.net/exec and 'file'
built-in shell command, if that reliably/consistently reports
progressive-ness...

One other possibility is to see what happens if you do imagefromjpeg()
on a progressive JPEG -- There amy be functions in GD that will tell
you if the JPEG is progressive, once you have sucked it into PHP...

Depending on the size of the images on average, this could be slower
than exec('file') but would be faster for small images, I should
think.

-- 
Some people have a "gift" link here.
Know what I want?
I want you to buy a CD from some starving artist.
http://cdbaby.com/browse/from/lynch
Yeah, I get a buck. So?

-- 
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