I use some test images for my iphone app, and the app mysterious breaks when it shouldn’t. I finally opened up the photo with an image viewer and noticed that the photos are rotated. I did not expect this at all.
How do I know an image is rotated?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
UIImage has an
imageOrientationproperty. That returns the orientation defined in the image’s metadata orUIImageOrientationUpas a default.But really, if your app breaks because of the orientation, you might be doing some things in a way you shouldn’t do.. (can’t remember how often i got EXEC_BAD_ACCESS oO) i suggest running leaks / zombie instruments with the xcode profiling feature.