Bug #12354 Updated: getImageSize() fails for some JPEGs
| From: | andy@php.net | Date: | Wed, 25 Jul 2001 02:54:07 +0000 |
| Subject: | Bug #12354 Updated: getImageSize() fails for some JPEGs | ||
| References: | 1 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-60922@lists.php.net to get a copy of this message | ||
ID: 12354
Updated by: andy
Reported By: matt@earth.care2.com
Status: Open
Bug Type: GetImageSize related
Operating System: linux
PHP Version: 4.0.6
New Comment:
works fine for me with 4.0.6 release.
Previous Comments:
------------------------------------------------------------------------
[2001-07-24 20:12:15] rasmus@php.net
... and checking the image you posted, it works fine for me with the current getimagesize() in CVS.
And I don't think it has changed since 4.0.6
------------------------------------------------------------------------
[2001-07-24 20:04:05] rasmus@php.net
Are you absolutely sure you are using PHP 4.0.6? This was a bug in 4.0.5.
------------------------------------------------------------------------
[2001-07-24 19:57:23] matt@earth.care2.com
JPEGs saved directly from some digital cameras do not contain whatever data getImageSize relies on
to produce an array of size and type data. Opening such an image and re-saving (even as JPEG) within
an image editor (photoshop or equivalent) will 'fix' the image, allowing getImageSize() to
read it.
Here's an image that causes getImageSize() to fail:
http://sitefoundry.com/php/DSC00021.JPG
Here's the same image after opening/saving; getImageSize() copes fine with this one:
http://sitefoundry.com/php/DSC00021fixed.jpg
Here's the output of ImageMagick's 'identify' utility for both images:
DSC00021fixed.jpg 640x480 DirectClass 81kb JPEG 1s
DSC00021.JPG[1] 640x480 DirectClass 88kb JPEG 2s
Here's the output of 'file':
DSC00021fixed.jpg: JPEG image data, JFIF standard
DSC00021.JPG: JPEG image data
------------------------------------------------------------------------
Edit this bug report at http://bugs.php.net/?id=12354&edit=1