Using exiftool 9.34, I cannot have the orientation attributes removed:
$ cp rwb3.jpg rwb2.jpg
$ exiftool -s rwb3.jpg | grep -i orient
Orientation : Rotate 90 CW
CameraOrientation : Rotate 90 CW
$ exiftool -P -tagsFromFile rwb2.jpg -Orientation= -overwrite_original rwb3.jpg
1 image files updated
$ exiftool -s rwb3.jpg | grep -i orient
CameraOrientation : Rotate 90 CW
Orientation : Rotate 90 CW
This is because the Orientation tag is (oddly) in IFD1 (the thumbnail IFD):
> exiftool rwb3.jpg -G1 -a -orientation
[IFD1] Orientation : Rotate 90 CW
> exiftool rwb3.jpg -ifd1:orientation=
1 image files updated
> exiftool rwb3.jpg -G1 -a -orientation
[no output]
Deleting Orientation without specifying a group will only delete it from IFD0 or the ExifIFD.
- Phil
That would still leave me with the Sony rotation tag. By the general "-section:tag=" idea, I attempted this, as well unsuccessful:
exiftool -Sony:CameraOrientation= -overwrite_original rwb3.jpg
Warning: Can't delete Sony:CameraOrientation
Nothing to do.
I think exiftool error messages should be improved telling the actual reason why it does not want to do this operation.
Quote from: bmn on August 12, 2013, 12:17:30 PM
I think exiftool error messages should be improved telling the actual reason why it does not want to do this operation.
Thanks for the suggestion.
I'll change this message to "Can't delete Permanent tag ...", and change the appropriate section of the application documentation to read this:
2) In general, MakerNotes tags are considered "Permanent", and may be edited
but not created or deleted individually. This avoids many potential
problems including the inevitable compatibility problems with OEM software
which may be very inflexible about the information it expects to find in the
maker notes.
- Phil
I would suggest
Quote
Warning: Won't delete Sony:CameraOrientation. In general, MakerNotes tags are considered "permanent", and may be edited but not created or deleted individually, so as to keep compatbility with inflexible OEM software.
which hopefully is a bit shorter but containing the same value.
That said, if I could just set the orientation to 0 (because I already rotated it with jpegtran), but:
$ exiftool -Sony:CameraOrientation=0 -overwrite_original rwb4.jpg
Warning: Can't convert Sony:CameraOrientation (matches more than one PrintConv)
Nothing to do.
The normal user does not have an idea what a PrintConv is supposed to be, and what to do in this case.
Quote from: bmn on August 12, 2013, 12:57:42 PM
I would suggest
Quote
Warning: Won't delete Sony:CameraOrientation. In general, MakerNotes tags are considered "permanent", and may be edited but not created or deleted individually, so as to keep compatbility with inflexible OEM software.
Unfortunately, that error message is a bit lengthy. It is best if they are kept to less than 80 characters. I was hoping that just mentioning "Permanent" in the message would give something concrete to search for in the application documentation (the blue text in my last post).
QuoteThat said, if I could just set the orientation to 0 (because I already rotated it with jpegtran), but:
$ exiftool -Sony:CameraOrientation=0 -overwrite_original rwb4.jpg
Warning: Can't convert Sony:CameraOrientation (matches more than one PrintConv)
Nothing to do.
The normal user does not have an idea what a PrintConv is supposed to be, and what to do in this case.
This is FAQ number 6 (https://exiftool.org/faq.html#Q6).
- Phil
Quote from: Phil Harvey on August 12, 2013, 01:04:13 PM
Unfortunately, that error message is a bit lengthy.
Oh, I had assumed your blue text is going to be the error message (which is even longer). In that case, "Warning: Won't delete CameraOrientation (FAQ item #1234)" should do too.
Quote from: bmn on August 12, 2013, 08:43:29 AM
$ exiftool -s rwb3.jpg | grep -i orient
Just a very minor tip, you don't need to use grep to pull out the tags you want. You can use the asterisk as a wildcard for tags. So you could have used
ExifTool -s -*orient* rwb3.jpgwith same results.
Quote from: StarGeek on August 13, 2013, 10:17:37 PM
ExifTool -s -*orient* rwb3.jpg
Good suggestion. On Mac/Linux the wildcards need quoting to prevent shell globbing (Windows has no shell globbing):
ExifTool -s '-*orient*' rwb3.jpg- Phil