Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Keep exif-orientation on import
#1
Hi guys,
Problem: upright picture (portrait) of a door. Exif in original jpg is right,top.
I send it to gimp. The door now is shown in landscape, the exif now is changed to top,left.
I'm not sure, but maybe once there was a popup how to threat orientation of origin.
But now this popup is gone and I cannot find the option to change this behaviour.
Any help?
Reply
#2
(03-24-2025, 10:44 PM)Pflichtfeld Wrote: Hi guys,
Problem: upright picture (portrait) of a door. Exif in original jpg is right,top.
I send it to gimp. The door now is shown in landscape, the exif now is changed to top,left.
I'm not sure, but maybe once there was a popup how to threat orientation of origin.
But now this popup is gone and I cannot find the option to change this behaviour.
Any help?

What is the exit orientation number?

AFAIK Gimp always exports the image with 1=Top,Left, because this tells how the image should be transformed before being displayed but since Gimp encodes it as displayed there is no transformation necessary.
Reply
#3
It is changed from 6 to 1.
Reply
#4
Pflichtfeld: Hi! If you go to Edit -> Preferences and then choose the "Image Import & Export" option, there will be a dropdown that's labeled as "Metadata Rotation Policy". That should let you choose how the rotation is handled on import.
Reply
#5
(03-25-2025, 12:37 PM)CmykStudent Wrote: Pflichtfeld: Hi! If you go to Edit -> Preferences and then choose the "Image Import & Export" option, there will be a dropdown that's labeled as "Metadata Rotation Policy". That should let you choose how the rotation is handled on import.

Hi CmykStudent. That should be exactly the point I am looking for. Unfortunately there is no dropdown here (GIMP 2.10.38 (Revision 1)):


   

Edit: Thanks so much. I learned, that I was working with an older version. Updated now to 3.02 and now it works like a charm!
Strange, that this option seems not to exist in earlier version.
Reply
#6
Pflichtfeld: Glad you got it figured out! And yes, people add new features based on their interest, so it's likely between 2.8 and 3.0 a contributor came along, had the same problem you did, and coded a solution. Smile
Reply
#7
(Yesterday, 02:15 AM)CmykStudent Wrote: so it's likely between 2.8 and 3.0 a contributor came along, had the same problem you did, and coded a solution. Smile

in my GIMP 2.10.38 this solution is not present...
Disadvantage of 3.x: No arrow-script yet.
Reply
#8
(Yesterday, 08:43 AM)Pflichtfeld Wrote: in my GIMP 2.10.38 this solution is not present...
Disadvantage of 3.x: No arrow-script yet.

An updated version of the arrow script has been available for some time (assuming this is the script that you mean):

http://programmer97.byethost10.com/Files/arrow.zip

(You need to use arrow_V3.scm from the zip file)
Reply
#9
(Yesterday, 10:58 AM)programmer_ceds Wrote: An updated version of the arrow script has been available for some time (assuming this is the script that you mean):
http://programmer97.byethost10.com/Files/arrow.zip
(You need to use arrow_V3.scm from the zip file)

Indeed, it works! Thanks so much!
Reply
#10
(Yesterday, 08:43 AM)Pflichtfeld Wrote:
(Yesterday, 02:15 AM)CmykStudent Wrote: so it's likely between 2.8 and 3.0 a contributor came along, had the same problem you did, and coded a solution. Smile

in my GIMP 2.10.38 this solution is not present...
Disadvantage of 3.x: No arrow-script yet.

What I don't understand is why you need it. Because in my 2.10, if I open a portrait image from my camera (right, top or left, bottom), Gimp auto-rotates it correctly, and as far as I remember EXIF orientation shenanigans have been solved a very long time ago, when Windows XP and its broken image viewer still ruled.


What I suspect is that your image has been edited and re-encoded by some utility that rotated the encoding but the left the original orientation. This was typical of the Windows image viewer (up to XP & Vista IIRC). Some ways to check:
  • Utilities (at least file and ImageMagick) show the image size as encoded, independently of the rotation. So a portrait image encoded as portrait and without rotation is 200x300 while one from a camera (always encoded as landscape, plus additional rotation) would be reported as 300x200.
  • Rotation 6 means that the image is rotated 90° clock wise. So if the image shows with its top on the right, it means it is indeed encoded with its small dimension first and there should be no rotation flag.
Changing Gimp's behavior will fix you immediate problem with this image, but create one with other unaltered images.
Reply


Forum Jump: