Closed Alexn117 closed 5 years ago
Thank you for the report!
Could you please attach an example image so I can reproduce the issue?
Sure! See the original post above.
I've downloaded the test image and attached it to this comment with the “small size” setting using iOS 13.1.2:
The exif command-line utility reports "Right-top" orientation for the original image and "Top-left" for the small-size-uploaded one. It looks like the original orientation tag is lost for some reason when using this option.
I also tried to open these images using GIMP and the Gnome Image Viewer. Both of them display the first image correctly while the second one is displayed rotated.
Yeah I'm seeing that iOS is changing the original orientation tag on the small-sized version. It is setting it to Orientation: 1 (Normal). While the original image had Orientation: 6 (Rotated 90° CCW). I'm seeing this data if you open each image with Preview on macOS > Tools > Show Inspector > General tab. This website explains those numbers:
https://www.impulseadventure.com/photo/exif-orientation.html
I take it that since iOS changes the original orientation tag, there's no way of solving this? Have to report to Apple and wait for iOS to preserve the original orientation tag?
I've just conducted one more test just to ensure that github uploader isn't modying the image data. I've created a simple server with an upload form and used it to save the raw uploaded bytes to a file.
The result is the same as before: the uploaded image has the wrong orientation tag and the iOS software itself displays it rotated. Looks like it's an iOS issue.
I'm closing the issue, feel free to reopen if I missed something.
I also experienced this issue. I made a [cmd shift 4] screen shot for each original iPhone photo I intended to upload. The screenshots are uploaded correctly.
I'm experiencing this issue on a completely unrelated app I'm writing - anyone found any solutions to this?
I'm afraid not. The orientation information is lost (apple device sets the orientation tag to 1 - normal), so there's no way to handle this right now :(
That's also our experience.. I think it's a bug on the Apple side..
In iOS 13 when uploading an image you are prompted with the option to "Choose Image Size" on the selected image, to reduce the size of the original file for upload. This is optional, and you can upload the original large file if you wish.
When uploading the original image file, without using this feature, the image ends up being rotated properly by use of:
But, if you choose to resize the image to "Large", "Medium", or "Small" (using the "Choose Image Size" iOS feature), the uploaded image does not correct the orientation and remains rotated.
I believe iOS is doing something to the image uploaded with "Choose Image Size", that Disintegration is not taking account of. Perhaps there are additional computations and checks that need to be ran to properly adjust the orientation data of these images.
EDIT: test image below.