Dependent Origination

GD library lose EXIF data during resizing

Posted on: April 27, 2011

今天花了几乎一整天的时间,明白了以下几点:

1。 GD (不管是GD1还是GD2) library 在resize an image的时候不retain the EXIF data from the original image.

2。如果想retain EXIF during resize, 用image magic

3。mobile safari respects EXIF while most desktop browsers (webkit ones and firefox and ie) do not respect EXIF data.

4。this means, you have to rotate your own image.

5。there are two places you can rotate: on the camera or on the server.

6。android seems to have library calls to rotate the data directly off the camera sensor while i don’t seem to find similar calls for iphone.

7。so, the conclusion: rotate your image on the server for iphone so that those images will display in the correct orientation.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Advertisements
April 2011
M T W T F S S
« Mar   May »
 123
45678910
11121314151617
18192021222324
252627282930  

Twitter

Flickr Photos

%d bloggers like this: