3
1
I want to losslessly rotate all JPEGs that have been shot in portrait mode and remove the rotate flag, so iPhoto doesn't stops rotating them. Any easy way to do that?
3
1
I want to losslessly rotate all JPEGs that have been shot in portrait mode and remove the rotate flag, so iPhoto doesn't stops rotating them. Any easy way to do that?
3
Found it:
jhead -autorot <filename>
does it. To rotate all the files in a directory, just do jhead -autorot *
.
You must have both jhead and jpegtran installed. jhead can be found here (OSX binary available). jpegtran can be found here (download the source and compile it using ./configure && sudo make all install
).
2
You can also use exiftran installed though homebrew, which by default will rotate the image and then remove the exif rotation data (set it to 1).
brew install exiftran
exiftran -ai *.jpg
To clarify, running
jhead -autorot *
will rotate only the files in portrait mode (which is usually what is needed). – laurent – 2014-05-07T01:01:48.223