Wrong orientation when image captured by HTML5 file api on IOS 6.0

I am using HTML5 file api on mobile web app for image uploading utility. I am capturing image using camera and upload it to server. Problem is that if I capture portrait image the uploaded image automatically converted to Landscape.

Answers


You'll need to transform the image to correct the orientation. Fortunately, the image should include EXIF data that you can use to do that. If you like, you can do this before the image is uploaded to your server:

  1. Read the image's EXIF data
  2. Use a canvas element to transform the image as appropriate
  3. Export the canvas image into an image file

There's an excellent writeup, including code samples, in this blog post.


Need Your Help

algorithm complexity: Strassen's algorithm is polynomially faster than n-cubed regular matrix multiplication. What does “polynomially faster” mean?

algorithm matrix multiplication

Strassen's algorithm is polynomially faster than n-cubed regular matrix multiplication. What does "polynomially faster" mean?

DirectShow and openCV. Read video file and process

c++ opencv directshow

I used search on StackOverflow, but I didn't find the answer. I'm developing an application and use OpenCV, but I need to work with different videos (mostly *.avi), so I decided to use DirectShow. ...

About UNIX Resources Network

Original, collect and organize Developers related documents, information and materials, contains jQuery, Html, CSS, MySQL, .NET, ASP.NET, SQL, objective-c, iPhone, Ruby on Rails, C, SQL Server, Ruby, Arrays, Regex, ASP.NET MVC, WPF, XML, Ajax, DataBase, and so on.