Announcement

Collapse
No announcement yet.

How can I reset the Exif rotation flag?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    How can I reset the Exif rotation flag?

    I have a problem, possibly caused by using an older version (3.90) of Irfanview (under Win XP pro). After discovering the lossless rotation plugin, I decided to go thru my entire collection of thousands of pictures and using that plugin, manually rotate all the images that appeared rotated. I believe my camera does not properly set the exif rotation flag, so this process could not be done automatically (in my meager understanding). Now after this painstaking process I can view all my images in Irfanview without having to rotate my head. (Yea!)

    But now for the bad news. The applications I've found that lets me view my pictures on my large screen TV look at the exif tags and rotates the image according to them. (At least that is my guess). Also I'm guessing that Irfanview did not properly reset these tags when rotating the image. The net result is that the images that I had rotated manually, appear rotated on my TV (I think in the opposite direction to the original rotation) despite the fact that Irfanview displays them correctly. I'm guessing I could fix the problem by a batch clearing of the exif rotation flag. Does anyone concur with this analysis, and if so, are there any tools which can do this?

    If not, any other suggestions for fixing the problem would be appreciated. I'm not interested in going thru my images one by one to correct the problem manually. I already tried that once and it took far too long and was unsuccessful in the end.

    #2
    Hi pmennen,

    It seems that your camera is able to set orientation info in the EXIF but IrfanView was not set to display images according using this info (I believe this is a rather recent feature in IV), so you rotated your images. Or maybe this feature is not always activated in your camera. If your images still contain orientation info, rotate them backwards. In irfanView, go to Options | Properties| JPEG/PCD/GIF and use (or not) Autorotate according to EXIF info, and see if IrfanView displays images correctly. You might also consider using Thumbnails viewer | Lossless transformations | Autorotate (according to EXIF orientation if available).
    I suggest you try first on some dummy images.

    Laurent
    Before you post ... fill in your OS and IV version in your profile.

    Comment


      #3
      Originally posted by Laurent View Post
      Hi pmennen,
      It seems that your camera is able to set orientation info in the EXIF but IrfanView was not set to display images according using this info (I believe this is a rather recent feature in IV), so you rotated your images.
      Laurent
      On thinking about it I think you may be correct.
      So my images probably would have displayed correctly in my other
      applications if I hadn't spent so much time painstakingly going thru
      my photos to rotate the ones that were taken with a vertical orientation.
      Now basically I've corrupted all my photos. And I was so satisfied
      with the results for awhile (as they did display fine in Irfanview) that I
      have even overwritten my backups with my corrupted versions. Arrgh!

      So I think at this point I have no choice but to uncorrupt my pictures.
      The only way I can think of to do this is to do a mass clearing
      of the exif rotation flag (to the default - upper left or whatever it's
      called), or perhaps delete all the exif data entirely. It seems likely
      that this would fix the pictures, although I haven't figured out a way
      to try this.

      Originally posted by Laurent View Post
      If your images still contain orientation info, rotate them backwards.
      Laurent
      But wouldn't this entail going thru my pictures manually, one at a
      time? (As I already mentioned, I've lost the patience for that - it
      just takes too long). I think I need a batch method for handling
      all the pictures at once.

      Thanks for any more suggestions you may have to get my out
      of this pathetic mess I blundered into.

      ~Paul

      Comment


        #4
        Hi Paul,

        Originally posted by pmennen View Post
        But wouldn't this entail going thru my pictures manually, one at a
        time? (As I already mentioned, I've lost the patience for that - it
        just takes too long). I think I need a batch method for handling
        all the pictures at once.
        What I would do is to make copy a batch of images (50 or so, including correctly and uncorrectly displayed on your TV) to a test directory, go to the thumbnails viewer, select them and use Lossless operations | Lossless rotation | Rotation according to EXIF, and see if you get the correct result.

        You might also try (firts on test images) to remove EXIF orientation info: Batch conversion | JPEG format | Options | Remove EXIF orientation mark. BUT unluckily this is not lossless!

        Another possibility is to disable (if possible) the use of EXIF data for displaying on your TV.

        Laurent
        Before you post ... fill in your OS and IV version in your profile.

        Comment


          #5
          If I understand your problem correctly you should have saved your jpeg images with Reset EXIF orientation tag checked.
          When you save a jpg the dialog box has a checkbox at the bottom marked Show options dialog. If you check Reset EXIF orientation tag in that dialog all subsequent jpg images are saved with the EXIF tag set to Top Left. The images will not then be rotated by Auto-rotate functions.

          Once checked you could run a batch process to open and resave all your files without making any changes apart from the tag. That would not be lossless though. Someone else might be able to figure out how to resave them all with a lossless operation.

          Comment


            #6
            Originally posted by Laurent View Post
            Hi Paul,
            ... Rotation according to EXIF, and see if you get the correct result.
            Laurent
            That did not seem to be the correct result.

            Originally posted by Laurent View Post
            Hi Paul,
            ... Remove EXIF orientation mark. BUT unluckily this is not lossless!
            Laurent
            That probably would have done it, although I didn't see that option.
            (I guess I should update to the latest version).

            I did try the option to clear out the EXIF data entirely and that worked
            fine. However I wasn't sure if I wanted to delete all the EXIF data, so
            I tried a program called Jhead (available free).

            Because of its flexible wildcard capability I was able to clear the
            rotation flag of all my pictures with the single command:

            Jhead -norot PictureFolder\**\*.jpg

            Jhead quickly went thru all my pictures, only changing the files that needed to. Now all many file and picture viewers show the proper orientation.

            A file viewer that uses the embedded thumbnails still sometimes show
            rotated images, but Jhead has a fix for that to (by allowing you to
            regenerate the thumbnail).

            Anyway, thanks for the help. I don't think I would have figured it out without it.

            ~Paul

            Comment

            Working...
            X