export should apply flip

Bug #1371826 reported by Danielle Foré
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Photos
Confirmed
Undecided
Unassigned

Bug Description

export seems to just save EXIF data for flip instead of actually flipping. This is important when I need to use a photo online or somewhere the EXIF data won't be read

Revision history for this message
Alan Pater (alan-pater) wrote :

This is a feature, not a bug. Using the orientation tag is non-destructive. Actually flipping the pixels is not.

Apps and sites which ignore the orientation tag are broken and should be fixed.

Revision history for this message
Danielle Foré (danrabbit) wrote :

In an ideal world sure. Sadly this is not an ideal world. I don't think orientation changes are really "destructive" as it can be reverted quite easily.

Revision history for this message
Alan Pater (alan-pater) wrote :

Sadly it is not. In an ideal world, pixels can be flipped non-destructively. In the real world, algorithms to do that may be imperfect. It may look to the human eye as if nothing has been lost, but that may not be the case.

The orientation tag seems safer.

Revision history for this message
Jim Nelson (yorba-jim) wrote :

This is a long-standing source of confusion with Shotwell. There are numerous issues involved.

First, Shotwell uses GDK Pixbuf to perform the rotate/flip operations in memory. Those operations are non-destructive and reversible.

Re-encoding a JPEG *is* destructive due to the lossy nature of JPEG compression. Older photo managers used generational editing, meaning they saved (re-encoded) the JPEG with each edit. This leads to loss of precision, detail, color, and more.

This is why Shotwell uses EXIF orientation whenever possible; by avoiding re-encoding the JPEG, we preserve the photo.

However, there is only one export case where Shotwell can use this technique: If the photo is being exported (a) at the same size (dimensions) as the original and (b) with no other transformations involved (cropping, red-eye, color adjustment, etc.) If either of these is not true, Shotwell must re-encode the JPEG, so it will go ahead and rotate the image along with the other transformations.

Note that there is a side-case as well: When metadata writing is turned on, Shotwell will write the Orientation out (along with keywords, titles, descriptions, etc.) This is a handy way to properly orient your master photos without re-encoding them (and losing the detail in the originals).

For most photo sharing services, the photo must be uploaded at a smaller size than the original, so the orientation issue is moot. For situations where the original is being uploaded (again, with no other transformations), then yes, only the EXIF Orientation is modified.

The problem with re-encoding every time is that we don't know the purpose of the export. If it's to share baby photos on Facebook or Instagram, then yeah, re-encoding is probably not a big deal. But if it's being exported for archival purposes (which some people use Flickr for), then we're needlessly removing detail from their photos. For some people, it's no big deal. For others, it's like we're repartitioning their hard drive.

Revision history for this message
Danielle Foré (danrabbit) wrote :

Gonna make the call here as I think Jim pointed out the distinction. We want to make sure to be as non-destructive as possible in the library. EXIF rotate makes the most sense inside of Photos.

However, since we can't predict external apps and whether or not they will respect this data, I think it makes sense that *export* should apply all changes (including rotate and flip) to the exported file.

Changed in pantheon-photos:
status: New → Confirmed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.