Photo Rotates after Cropping

Moderators: XnTriq, helmut, cday, xnview, Dreamer

Post Reply
dietmar
Posts: 88
Joined: Fri Oct 25, 2013 4:55 pm

Photo Rotates after Cropping

Post by dietmar » Mon Mar 12, 2018 1:18 pm

xnview wrote:are you on Mac too?
Pierre, this isn't a Mac-only problem. It happens on Linux as well.
Like the other users I'm seeing this happen every now and then. I haven't been able to pinpoint down the exact circumstances when it happens and why.
It just happened with these images yesterday.
To the left is the original. EXIF-Orientation = left-bottom (8) ExifTool-Orientation = Rotate 270 CW
To the right is the cropped image, created using a selection and 'Save Selection'. EXIF-Orientation = left-bottom (8) ExifTool-Orientation = Rotate 270 CW
This was with 0.89 on Linux 32-bit, if that matters.

Regards
Dietmar
Attachments
Screen-2018-03-12_14-06-45.jpg
Screen-2018-03-12_14-06-45.jpg (27.51 KiB) Viewed 535 times

User avatar
xnview
Author of XnView
Posts: 29581
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: Photo Rotates after Cropping

Post by xnview » Mon Mar 12, 2018 5:27 pm

dietmar wrote: To the left is the original. EXIF-Orientation = left-bottom (8) ExifTool-Orientation = Rotate 270 CW
To the right is the cropped image, created using a selection and 'Save Selection'. EXIF-Orientation = left-bottom (8) ExifTool-Orientation = Rotate 270 CW
This was with 0.89 on Linux 32-bit, if that matters.
do you reproduce with this file?
Pierre.

dietmar
Posts: 88
Joined: Fri Oct 25, 2013 4:55 pm

Re: Photo Rotates after Cropping

Post by dietmar » Tue Mar 13, 2018 9:33 am

xnview wrote:do you reproduce with this file?
Kind of. (Just spend an hour trying to ...)
If I open the same file and highlight the exact same selection, the newly generated file is correctly oriented and EXIF-Orientation is top-left (1).
But, if I open a different file from the same folder which is in landscape mode (EXIF-Orientation=top-left (1)), then use the 'next file' button to step to the file in question (the one in portrait mode) and now select and save selection then the new file is rotated.
Thus this must be a side effect of images shown previously.
Hope this helps.

Dietmar

dietmar
Posts: 88
Joined: Fri Oct 25, 2013 4:55 pm

Re: Photo Rotates after Cropping

Post by dietmar » Wed Apr 25, 2018 11:34 am

Pierre,

in contrast to the other member, my bug report is not a user-error. So keep this open until solved.

Dietmar


dietmar wrote:
Tue Mar 13, 2018 9:33 am
xnview wrote:do you reproduce with this file?
Kind of. (Just spend an hour trying to ...)
If I open the same file and highlight the exact same selection, the newly generated file is correctly oriented and EXIF-Orientation is top-left (1).
But, if I open a different file from the same folder which is in landscape mode (EXIF-Orientation=top-left (1)), then use the 'next file' button to step to the file in question (the one in portrait mode) and now select and save selection then the new file is rotated.
Thus this must be a side effect of images shown previously.
Hope this helps.

Dietmar

User avatar
xnview
Author of XnView
Posts: 29581
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Photo Rotates after Cropping

Post by xnview » Wed Apr 25, 2018 11:54 am

dietmar wrote:
Wed Apr 25, 2018 11:34 am
in contrast to the other member, my bug report is not a user-error. So keep this open until solved.
could you send me the files used, and the exact way to reproduce it, please
Pierre.

dietmar
Posts: 88
Joined: Fri Oct 25, 2013 4:55 pm

Re: Photo Rotates after Cropping

Post by dietmar » Wed Apr 25, 2018 1:25 pm

xnview wrote:
Wed Apr 25, 2018 11:54 am
could you send me the files used, and the exact way to reproduce it, please
Pierre, here's the way to reproduce this effect. The forum software does not allow me to upload the files I used (too big). Give me an email or a place to upload if needed. Or try with some of your files.

F1.jpg: landscape-oriented photo 4896x3672, EXIF-Orientation: Horizontal (normal), Camera-orientation: top-left (1)
F2.jpg: same as F1.jpg but reduced to 1365x1024, EXIF-Orientation: Horizontal (normal), Camera-orientation: top-left (1)
F3.jpg: portrait-oriented photo 4896x3672, EXIF-Orientation: Rotate 270 CW, Camera-orientation: left-bottom (8)

XnView: MP Linux Version 0.90 64bits (Mar 5 2018) (also happens on 0.89 32bits)
OS: Linux Ubuntu 64bit (resp. 32bits)

Photo rotates after cropping

Effect: Portrait photo rotates after save selection if previously a landscape photo was viewed

To reproduce:
1. Place the three files into a new folder and open this folder in MP. Order by filename ascending.
2. Open F3.jpg (i.e. the portrait photo)
3. Highlight the top-left part of the image (e.g. from 0,0 to 2500,3500 approximately)
4. Save Selection as F4.jpg
5. Close file and look at browser pane. F4.jpg is correctly oriented.
6. Restart MP. Open the same folder.
7. Open F1.jpg
8. Next File to F2.jpg
9. Next File to F3.jpg
10. Highlight the same part of the image (e.g. from 0,0 to 2500,3500 approximately)
11. Save Selection as F5.jpg
12. Close file and look at browser pane. F5.jpg is rotated.

Actual behavior (bug): Cropped photo is incorrectly rotated. This is a side-effect of having looked at a landscape-type photo before.

Expected behavior: Photo should not rotate.

Regards
Dietmar

User avatar
xnview
Author of XnView
Posts: 29581
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: Photo Rotates after Cropping

Post by xnview » Thu Apr 26, 2018 3:13 pm

Ok, i can reproduce, it will be fixed in next release
Pierre.

dietmar
Posts: 88
Joined: Fri Oct 25, 2013 4:55 pm

Re: Photo Rotates after Cropping

Post by dietmar » Thu Apr 26, 2018 3:34 pm

xnview wrote:
Thu Apr 26, 2018 3:13 pm
Ok, i can reproduce, it will be fixed in next release
Good to hear. And please also build a 32bit Linux version when you build the next release. :)

Dietmar

User avatar
xnview
Author of XnView
Posts: 29581
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: Photo Rotates after Cropping

Post by xnview » Thu Jun 07, 2018 9:40 am

This problem is supposed to be fixed in XnView MP 0.91. Please check and confirm the bug fix here.
Pierre.

Post Reply