Reputation: 421
I am developing an Phonegap & jQuery-Mobile Application for Android. After taking a photo - using the phonegap API - I show it in an image tag. This all works fine my problem is the orientation of the Photo.
When testing on my HTC Desire (Android-Version 2.2) the Photo is always in the right direction when holding the phone in portrait mode.
But when testing on my Galaxy Tab (Samsung GT-P1000 Android-Version 2.2) or on my GT I5800 (Samsung Android-Version 2.2) I take the pictures and when showing them while having the phone in portrait mode the picture orientation is wrong - the pictures are rotated 90 degrees clockwise.
How can I be sure which orientation the pictures have after taking them? Is this an Issue with Samsung devices ? Does every manufacturer does this in an other way?
Thanks in advance!
Upvotes: 3
Views: 774
Reputation: 23273
Well it is definitely and issue on Samsung devices as I've had to deal with it quite a bit. The problem boils down to the fact that the web browser does not look at the Exif data to see what orientation the picture was taken in. When you copy a picture that has been taken in portrait mode and view it in Preview or any other image manipulation package it shows up correctly but when you load it in your browser it will be turned on it's side.
At this point I have not found an easy way around the problem and we've been forced to recommend to people to take pictures in landscape mode whenever possible.
Upvotes: 3