iOS 5's hardware shutter bug gives upside-down images

In today's smartphone-crazed society, people expect their phones to do just about everything, minus making coffee in the morning. Cameras are almost second nature to all of today's phones, and so some manufacturers include a hardware shutter button to replicate a camera-like photo shooting experience.

So when the iOS 5 update was on the horizon and the plans for the iPhone 4S refresh were set in stone, instead of adding more buttons to the phone, Apple stuck to their minimalist guns and opted to rewire the hardware "volume up" button to be the shutter button while the Camera application is open.

Smart move, right? Not really, thanks to an oversight from Apple's iOS developers. The following two photos demonstrate said oversight - the first photo was taken straight from the camera, and the second shows the phone in its orientation while using the hardware shutter button:

The phone is considered "right side up" with the Home button facing to the right, and the camera lens at the back facing up. With the hardware button, it's reversed, so the lens is facing down. iOS recognizes which direction is up thanks to the device's gyroscope, so it sets an EXIF flag to assist photography software in rotating the photo in the correct orientation.

Unfortunately, the built-in Photo Viewer in Windows 7, and Windows Live Photo Gallery (amongst other Microsoft applications) cannot read this flag properly. In addition, if a user tries to use the shell or any of the aforementioned applications to rotate the photos, they get this error:

Fortunately, it's easy to get photos rotated in the correct order (more on this later). But what about videos taken with the Camera application? Yes indeed - they're also upside-down.

 

Unlike photos, rotating upside-down videos is considerably more computationally expensive. Definitely not something YouTubers would be pleased to carry out on their uploaded videos if they used the hardware shutter!

To remedy this situation, Apple should consider changing the Camera application to just save photos and videos the right way up without setting any EXIF rotate flags - or at the very least, set rotate flags for photos but not videos. Such a change will benefit regular Joes who may be confused at their phone's behaviour.

For the rest of us, consider using the software shutter button for the time being. Users that would like to rotate their photo collection the right way up should consider downloading the tools jhead and jpegtran, and invoking the command "jhead -autorot FOLDER-PATH\*.jpg" from the Command Prompt.

Or alternatively, you could hold the phone the right way up and use your left thumb to hit the shutter button. But what camera has their shutter button down on the bottom left corner?

Report a problem with article
Previous Story

New video shows more of Nokia's flexible phone concept

Next Story

Will Microsoft learn its lessons from its failed Tablet PC?

44 Comments

Commenting is disabled on this article.

My 3GS gave me upside down photos and videos the entire time I had it, and thats was before the volume rocker could even be used to take photos.

if you open the picture with the microsoft office viewer (and option in open with) you'll find that it allows you to rotate it and same the picture.

lukeslife said,
Has anyone noticed in the first image the monitor is upside down

sarcasm?... if it was the right way up there wouldn't be a problem.

Am I missing something? I just tried this out....took one picture of this thread using the software shutter and then another using the volume button.

I just connected the iphone 4s to my windows laptop and viewed them using picture viewer....they both look fine (right side up). What is the issue?

As an iPhone user on Windows for years, this has always been an "issue". In truth, it is really something Microsoft needs to fix that Windows' shell and built-in software handles the EXIF data correctly....

I have the same problem with my DSLR. When I hold it upside down its pictures are upside down. Insanity!

/sarcasm

Shutter "bug"? I see no indication that writing exif data instead of "physically" rotating it is a bug. There are two ways of getting the rotation right. Windows Live Photo Gallery don't support the second way properly. And that is that. I have never seen this bug myself, and use my iPhone daily. But then again... I am not using Windows Live products.

Northgrove said,
Shutter "bug"? I see no indication that writing exif data instead of "physically" rotating it is a bug. There are two ways of getting the rotation right. Windows Live Photo Gallery don't support the second way properly. And that is that. I have never seen this bug myself, and use my iPhone daily. But then again... I am not using Windows Live products.

This is not just about reading the exif data and displaying the image with the correct orientation.. It appears that even programs that can read the exif data are having problems.

I actually had this happen with a video I shot on Friday, on iTunes and Quicktime, they play fine, however, on any other program like VLC, it is upside down. Anyone know of a quick program to fix that?

Cask1 said,
I actually had this happen with a video I shot on Friday, on iTunes and Quicktime, they play fine, however, on any other program like VLC, it is upside down. Anyone know of a quick program to fix that?

Sounds like an Apple issue to me, not a Microsoft issue. VLC doesn't use any MS components, and as such it's definitely an Apple issue.

Here is a trick: use Picassa in windows and replace that god awful default image viewer. Apple writes their images one way and sets a tag that tells other software which way is up. Microsoft doesn't use that tag properly.

That error about not being able to rotate the image is a deeper problem than reported in this article. I was migrating some photos to a Windows 7 PC from a Mac, so I exported them from Aperture and was getting the same problem with all of them. These were pictures taken with a Canon DSLR. My solution was to process them all in Adobe Bridge (on the Mac) to remove whatever kind of trickery Apple was up to. Only images that had been processed with Apple products came over with problems.

The software reading the photo isn't the problem. For arguments sake you could blame M$ but blaming M$ would never come about if the Phone took pictures in the correct orientation. Its quite a major flaw when it comes to video as most people wont have a clue how to change that and it will take a while on average joes PC (depending on video length).

Expect to see many a confuzzled person holding their cam wrong way up!


Rosyna said,

It is a flaw in Microsoft's software.
They permanently change the data when the photo is imported using their tools which will always lead to data loss.

Actually, it's a feature and kind of a protection too. I suggest you to learn to read. Thanks for the article though, it defeats your own statements:
The reason that the Photo Gallery rotates on import, but not after that is because there are a number of applications that don't correctly update the
photo metadata after rotating. This metadata is supposed to reflect the state of the photo, but if the photo is rotated without updating this metadata,
another application using this metadata to determine whether or not to rotate it will incorrectly rotate the photo.

Coi said,

Actually, it's a feature and kind of a protection too. I suggest you to learn to read. Thanks for the article though, it defeats your own statements:

I read that and it's the same load of crap MS touts when their software doesn't correctly do something. They say it's for "backwards compatibility" by completely breaking forwards compatibility.

Auzeras said,
The software reading the photo isn't the problem. For arguments sake you could blame M$ but blaming M$ would never come about if the Phone took pictures in the correct orientation.

Just for the sake of trying it, I just took a picture with my iPhone 4 (5.0.1) like this, and plugged it into my Mac. Downloaded fine. Wasn't upside down.

Must be a flaw with Windows and the way it reads EXIF tags?

giantsnyy said,

Just for the sake of trying it, I just took a picture with my iPhone 4 (5.0.1) like this, and plugged it into my Mac. Downloaded fine. Wasn't upside down.

Must be a flaw with Windows and the way it reads EXIF tags?


That's because the pic viewer on ur Mac rotates automatdically when it shows the pic to u. But that's not the prob here. The prob is, the pic itself should be stored in its rotated state, so the pic viewer doesn't have to rotate every time it shows u the pic. Windows users r seeing the pics Up side down cuz that's the rotation the pic was saved, which shows the logical prob. It's certainly not a bug, but a design prob to me.

giantsnyy said,

Just for the sake of trying it, I just took a picture with my iPhone 4 (5.0.1) like this, and plugged it into my Mac. Downloaded fine. Wasn't upside down.

Must be a flaw with Windows and the way it reads EXIF tags?


That's because the pic viewer on ur Mac rotates automatdically when it shows the pic to u. But that's not the prob here. The prob is, the pic itself should be stored in its rotated state, so the pic viewer doesn't have to rotate every time it shows u the pic. Windows users r seeing the pics Up side down cuz that's the rotation the pic was saved, which shows the logical prob. It's certainly not a bug, but a design prob to me.

Hardware shutter? Phone being right side up? Re-wired the volume button? What? It has nothing to do with the 4S (as iOS 5 is on other devices) or what button is pushed to take the picture.
I agree with the first commenter, the "logic" of this story is a bit messed up.

If is seen as bug (rotating the images are simple, not the video), Apple will fix.

Rosyna said,
So, in other words, it's Apple's fault Microsoft's applications can't read an EXIF tag?

Windows Live Photo Viewer never seems to have an issue rotating photos with EXIF orientation information for me. I think there is something else gong on here. In any case, the phone shouldn't be taking upside-down pictures to begin with.

xTdub said,
In any case, the phone shouldn't be taking upside-down pictures to begin with.

"Upside-down pictures"? It's a matter of coordinate space which is handled at draw time, not write time.

Rosyna said,

"Upside-down pictures"? It's a matter of coordinate space which is handled at draw time, not write time.

You really don't understand the underlying problem here...

cybertimber2008 said,
You really don't understand the underlying problem here...
I love when people do this. If he's wrong and not understanding then instead of just saying "you really don't understand" why not correct him and explain it??

hmm interesting camera behavior, also for those windows phone 7 fans, I found it shocking that apple actually did implement the "swipe left from camera view" to the photo reel. a quite obvious steal from wp7

jasonon said,
hmm interesting camera behavior, also for those windows phone 7 fans, I found it shocking that apple actually did implement the "swipe left from camera view" to the photo reel. a quite obvious steal from wp7

I didn't know you could do that! Nice

The logic of this story is incorrect. I am not a fan of Apple or their products, but I use the new iPhone for work, and I happen to work with Photos all day long. I also don't feel like explaining the whole issue, but let me just say that what you are trying to say is incorrect and flawed.

Eagle101 said,
The logic of this story is incorrect. I am not a fan of Apple or their products, but I use the new iPhone for work, and I happen to work with Photos all day long. I also don't feel like explaining the whole issue, but let me just say that what you are trying to say is incorrect and flawed.
If you don't feel like explaining anything then next time don't bother saying anything at all.

Eagle101 said,
The logic of this story is incorrect. I am not a fan of Apple or their products, but I use the new iPhone for work, and I happen to work with Photos all day long. I also don't feel like explaining the whole issue, but let me just say that what you are trying to say is incorrect and flawed.

Camera shutter button right way up. Photo upside down. Seems pretty clear cut to me, doesn't take a genius to see there's something wrong with that.

Please explain...

It's not actually that complex. The sensor in the camera has a "right way up", so the pixels are written to disk in that order. If you hold the phone so the sensor is upside-down, the picture will be written to disk upside-down but with a flag saying "The picture is upside-down, flip it like this to show it correctly".

Obviously, Windows' built-in viewers don't support this flag correctly *and* end up deleting it.

iKenndac said,
It's not actually that complex. The sensor in the camera has a "right way up", so the pixels are written to disk in that order. If you hold the phone so the sensor is upside-down, the picture will be written to disk upside-down but with a flag saying "The picture is upside-down, flip it like this to show it correctly".

Obviously, Windows' built-in viewers don't support this flag correctly *and* end up deleting it.

You didn't even read the article. Wow.

THAT is the problem. Especially for videos, which can't be rotated with a "flag" code

iKenndac said,
It's not actually that complex. The sensor in the camera has a "right way up", so the pixels are written to disk in that order. If you hold the phone so the sensor is upside-down, the picture will be written to disk upside-down but with a flag saying "The picture is upside-down, flip it like this to show it correctly".

Obviously, Windows' built-in viewers don't support this flag correctly *and* end up deleting it.

So why is a flag set for right way up -- clearly if the software is able to set that flag in the first place, and software is able to read that flag and display images the right way up, it may as well just save the actual image the right way up.

Setting a flag saying "this image is upside down" seems like a stupid way of handling the problem.

iKenndac said,
It's not actually that complex. The sensor in the camera has a "right way up", so the pixels are written to disk in that order. If you hold the phone so the sensor is upside-down, the picture will be written to disk upside-down but with a flag saying "The picture is upside-down, flip it like this to show it correctly".

Obviously, Windows' built-in viewers don't support this flag correctly *and* end up deleting it.

Actually, in this case, the Windows viewers couldn't read the flags to begin with so they left them as is. Hence the need for command line tools to fix the images.