Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Software - Troubleshooting and Discussion > Applications > iPhoto 4: Lossless rotation?

iPhoto 4: Lossless rotation?
Thread Tools
typ993
Junior Member
Join Date: Aug 2002
Location: The rainy, rainy Northwest
Status: Offline
Reply With Quote
Jan 9, 2004, 02:53 PM
 
Anyone know if iPhoto 4 has lossless JPEG rotation? I'm pretty sure the current version does not. I forgot to ask this to an Apple rep when I was at Macworld.

TIA.
     
bmedina
Mac Elite
Join Date: Jan 2000
Location: Seattle, WA, King
Status: Offline
Reply With Quote
Jan 10, 2004, 01:21 AM
 
I don't think it's possible. JPEG encodes to 8x8 blocks. In order to rotate pixel by pixel, the blocks have to be decoded and the pixels rearranged, creating different blocks. Then the file has to be re-encoded, since all the blocks are different.

Is there software that claims to do lossless rotation of JPEG encoded images?
     
Visnaut
Senior User
Join Date: Nov 2000
Location: Toronto, Ontario
Status: Offline
Reply With Quote
Jan 11, 2004, 04:38 PM
 
How does Image Capture do it?

I always thought I was being clever by rotating the pictures before importing them from the camera.

It'd be nice if there was a universal EXIF tag that notes what orientation a picture is supposed to be in. I bet digital cameras would have some mini gyro to be able to tell. That would be pretty cool.
     
wataru
Addicted to MacNN
Join Date: Oct 2001
Location: Yokohama, Japan
Status: Offline
Reply With Quote
Jan 11, 2004, 04:56 PM
 
Graphic Converter claims to do lossles JPEG rotation. I don't know the details, though.
     
bmedina
Mac Elite
Join Date: Jan 2000
Location: Seattle, WA, King
Status: Offline
Reply With Quote
Jan 11, 2004, 05:09 PM
 
Originally posted by Visnaut:
How does Image Capture do it?

I always thought I was being clever by rotating the pictures before importing them from the camera.

It'd be nice if there was a universal EXIF tag that notes what orientation a picture is supposed to be in. I bet digital cameras would have some mini gyro to be able to tell. That would be pretty cool.
Most cameras store the images in JPEG internally. So doing the rotation before importing amounts to the same thing.

Some Canon cameras (at least) do have the ability to sense the orientation of the camera and automatically rotate the image for you.

I'll take a look into Graphic Converter's to see how it is implemented. Do you know where the documentation is where it claims lossless rotation?
     
Judge_Fire
Mac Elite
Join Date: Jan 2001
Location: Helsinki, Finland
Status: Offline
Reply With Quote
Jan 11, 2004, 05:41 PM
 
Lossless rotation/flip has been part of the JPEG standard for a long time, but not a lot of software implement this feature.

From somewhere: "it is possible to do 90-degree rotations and flips losslessly, if the image dimensions are a multiple of the file's block size (typically 16x16, 16x8, or 8x8 pixels for color JPEGs)."

J
     
bmedina
Mac Elite
Join Date: Jan 2000
Location: Seattle, WA, King
Status: Offline
Reply With Quote
Jan 11, 2004, 09:51 PM
 
Well, I just rotated a JPEG (2048x1536) with Graphic Converter and iPhoto. The two resultant images have slightly different histograms, according to Photoshop. This would seem to confirm that iPhoto 4 does not perform lossless rotation of JPEGs.
     
mpercy
Fresh-Faced Recruit
Join Date: Mar 2003
Status: Offline
Reply With Quote
Jan 12, 2004, 09:07 AM
 
It sounds like the consensus is that iPhoto does not do lossless rotations.

However, it does sound like it would be possible to create a workable solution by utilizing a third party rotator (ie, jpegtran, perhaps even graphic converter) and an applescript wrapper.

I�ve been interested in learning applescript, so it may be a good test/training application.

Side issue: Has anyone noticed that the keyword handling is fairly poor in the application? It give you one list in a non-resizable window that is sorted by the entry time. I wonder if there is a way we could enhance this?

Matt
     
badtz
Mac Elite
Join Date: May 2002
Location: Los Angeles, CA.
Status: Offline
Reply With Quote
Mar 29, 2004, 10:36 AM
 
any news as to iPhoto's ability to do lossless rotations? 3rd party programs?
     
Thinine
Mac Elite
Join Date: Jul 2002
Status: Offline
Reply With Quote
Mar 29, 2004, 06:25 PM
 
Jobs said during the Keynote that iPhoto 4 does lossless rotation now.
     
mitchell_pgh
Posting Junkie
Join Date: Feb 2000
Location: Washington, DC
Status: Offline
Reply With Quote
Mar 29, 2004, 06:59 PM
 
With my Canon, it auto rotates as someone said before. iPhoto simply imports the photos with the correct orientation.
     
GeeYouEye
Junior Member
Join Date: Mar 2003
Location: Walnut Creek, CA
Status: Offline
Reply With Quote
Mar 29, 2004, 10:28 PM
 
As someone above said, the only way to do lossless rotation is if the size of the picture is a perfect multiple of the 8x8 16x16 blocks that make it up. One other thing to consider trying would be to use RLE, then flip and convert back to jpeg. You'll probably gain some file size, but it'll be, at worst the same lossyness, or else better. Trick is to find a program to do the Run Length Encoding and the the reverse.
I bring order to chaos. You are in chaos windows, you are the contradiction, a bug wishing to be an OS.
     
AJ
Dedicated MacNNer
Join Date: Oct 1999
Location: UK
Status: Offline
Reply With Quote
Mar 31, 2004, 03:44 PM
 
Originally posted by mitchell_pgh:
With my Canon, it auto rotates as someone said before. iPhoto simply imports the photos with the correct orientation.
I love that feature of my Canon Powershot S50
     
thefamousmred
Junior Member
Join Date: Mar 2002
Status: Offline
Reply With Quote
Mar 31, 2004, 06:59 PM
 
Originally posted by Visnaut:
It'd be nice if there was a universal EXIF tag that notes what orientation a picture is supposed to be in. I bet digital cameras would have some mini gyro to be able to tell. That would be pretty cool.
There is. Tag #0x0112, named "orientation".

More info here

For whatever reason it's often set incorrectly, unfortunately.
     
   
 
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Top
Privacy Policy
All times are GMT -4. The time now is 09:40 AM.
All contents of these forums © 1995-2017 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.8 © 2000-2017, Jelsoft Enterprises Ltd.,