After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 301819 - Rotating should make image version "Modified"
Rotating should make image version "Modified"
Status: RESOLVED WONTFIX
Product: f-spot
Classification: Other
Component: Editing
WISHLIST
Other All
: Normal enhancement
: ---
Assigned To: F-spot maintainers
F-spot maintainers
gnome[unmaintained]
Depends on:
Blocks:
 
 
Reported: 2005-04-24 19:48 UTC by Colin Marquardt
Modified: 2018-07-12 00:02 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
create-new-version-on-rotate.patch (3.29 KB, patch)
2007-12-23 12:30 UTC, Maxxer
none Details | Review
create-new-version-on-rotate.patch (3.51 KB, patch)
2007-12-23 18:22 UTC, Maxxer
none Details | Review
create-new-version-on-rotate.patch (2.63 KB, patch)
2008-01-16 18:49 UTC, Maxxer
needs-work Details | Review

Description Colin Marquardt 2005-04-24 19:48:25 UTC
When I rotate an image, the image stays as being Version: "Original". IMO,
it should be "Modified" even though it is a lossless operation in JPEG.
Comment 1 Jonas Bergler 2006-01-11 10:23:17 UTC
Would you expect the rotated photo to be a separate file or just a recording that the image has been rotated?
Comment 2 Colin Marquardt 2006-01-11 19:48:51 UTC
Not sure. If it is really 100% lossless, I guess just a recording is fine.
Comment 3 Ryan Hayle 2006-03-06 01:39:33 UTC
Well it's lossless since it doesn't modify the actual image data, it sets the exif orientation.  But does it modify the exif data in the image itself, or only in the photos.db?

This suggests to me that the modification versioning code should be extended to store exif-only modifications as binary diff-type files.  Perhaps this should be filed as a separate bug however.
Comment 4 Stephane Delcroix 2006-06-08 14:46:36 UTC
(In reply to comment #3)
> But does it modify the exif data in the image itself, or
> only in the photos.db?

It changes the image file. There's nothing about orientation in photos.db

And I can confirm, rotating jpeg in f-spot is 100% lossless. Only headers are touched. Even the file size remains the same.

My view about tagging as modified event though it's lossless: creating a version under f-spot is creating a new file. Why creating a new file (using disk space) if the content IS the same...
Comment 5 Kevin R. Page 2006-08-09 18:08:36 UTC
(In reply to comment #4)
> My view about tagging as modified event though it's lossless: creating a
> version under f-spot is creating a new file. Why creating a new file (using
> disk space) if the content IS the same...

Because some of us are paranoid about touching the original photo data? ;)

I'm attracted to f-spot because there's generally a separation between the data pulled from the camera (by whatever method) and the modifications and annotations made by f-spot. I rest easy knowing that if I wanted to switch from using f-spot I can retreive all my original photos without any mangling - I can always roll back to step 0.

Rotation is inconsistent with this approach because the image file has been changed, even though the change is only in the header. rsync would think it a different file, for instance.

(Indeed, my ideal photo manager would take this separation further. I'd be even happier if I knew that f-spot opened originals read-only; and had the option for modified images to live in a separate directory structure to the originals, which could stay in the hierarchy they inherited from the camera)
Comment 6 Ryan Hayle 2006-08-10 16:00:49 UTC
Indeed, all you have to do to make f-spot work like your "ideal photo manager" is backup your photos first!  (Doesn't everybody do this?)  After I've imported my photos to f-spot, I move the files off my memory cards into a backup server.  Just makes sense to me...

And I think it would be nice if revisions for image rotations were stored as file diffs instead of a complete copy, so that you can easily rebuild the original file.
Comment 7 Kevin R. Page 2006-08-11 22:36:28 UTC
I think there are two issues here:

1) whether a rotated image should be a modified copy
2) whether a user imports with or without Copy; and how much control a user has over where, and in what heirarchy, f-spot stores photos

and that the second influences the first:

- a user who selects "Copy" on import expects f-spot to have total control of the photos its managing, and won't be surprised when f-spot modifies an image (e.g. rotation).

- however, a user who imports _without_ copy starts with an expectation of separation between the logical management of photos (f-spot) and the storage of the original files on disk. From this perspective, any modification of the source file would be surprising.

(In reply to comment #6)
> Indeed, all you have to do to make f-spot work like your "ideal photo manager"
> is backup your photos first!  (Doesn't everybody do this?)  After I've imported
> my photos to f-spot, I move the files off my memory cards into a backup server.

Don't get me wrong, I think f-spot is excellent. And yes, I keep an archive/backup copy of the photos as they arrive from the camera. I then import into f-spot - but I care about any modifications made therein, so I also backup the f-spot Photos directory. I know disk space is cheap, but I'm making alot of copies/backups of photos which are, in the most part, the same.
Comment 8 Colin Zwiebel 2006-12-13 05:51:20 UTC
I won't take sides on how f-spot should handle image originals, but I would like to hack implement actual rotation of the image (instead of a change to EXIF data). I noticed in RotateCommand.cs there is an additional method called RotateCoefficients which seems to make a "physical" rotation of the image through JpegUtils. I changed
Rotate (original_path, direction);
in the step method of RotateOperation to:
RotateCoefficients (original_path, direction);
to test things. Unfortunately when the rotate button is pressed, the .tmp image is created and f-spot explodes explaining:
f-spot: symbol lookup error: /opt/gnome/lib/f-spot/libfspotjpegtran.so.0: undefined symbol: exif_data_new_from_data

Drilling down through the code, /f-spot/libjpegtran/jpeg-data.c is the source of the call to method exif_data_new_from_data which is defined in /f-spot/src/Exif.cs .

Any ideas about how to resolve this issue or implement "physical" rotation through other means. I'll continue to look into it, but you mono people change languages too many times and I have trouble telling where libraries connect.

Furthermore, if rotation is achieved, how would one do it through versioning. I haven't yet read through all the version and imagequery calls necessary to use such a method.

Colin
Comment 9 Stephane Delcroix 2006-12-13 09:02:21 UTC
Colin (comment #8),
RotateCoefficient works fine, but is not used in f-spot. Try to clean and re-install f-spot to fix your particular issue.
Real rotation (using coefficient) is done now using the OrientationFilter when exporting images.
Comment 10 Colin Zwiebel 2006-12-14 02:47:32 UTC
(In reply to comment #9)
> Colin (comment #8),
> RotateCoefficient works fine, but is not used in f-spot. Try to clean and
> re-install f-spot to fix your particular issue.
> Real rotation (using coefficient) is done now using the OrientationFilter when
> exporting images.
> 

Thanks, your absolutely right, it does work. I'm using arch linux and the AUR (arch user repository) has an ABS (arch build system, script based compiling and package building) which I was using, yet for some reason this system shows my experienced problem no matter the amount of package cleaning and upgrading I do. Since it works well manually from cvs (btw, abs builds from cvs), I'll probably be too lazy to hack versioning into the system. But if anyone provides a rotation versioning solution or patch, I'd love to hear it.
Comment 11 Maxxer 2007-12-23 12:30:31 UTC
Created attachment 101498 [details] [review]
create-new-version-on-rotate.patch

with this patch, F-spot creates a new photo version on rotate IF a gconf key is set. 

the patch includes also the one at bug 505125. I know that this sucks but it wouldn't have made sense without it IMHO.
Comment 12 Maxxer 2007-12-23 18:22:38 UTC
Created attachment 101514 [details] [review]
create-new-version-on-rotate.patch

I've corrected a few bugs, thanks to Nicke testing.
Comment 13 Niclas Andersson 2007-12-23 20:51:15 UTC
(In reply to comment #12)
> Created an attachment (id=101514) [edit]
> create-new-version-on-rotate.patch
> 
> I've corrected a few bugs, thanks to Nicke testing.
> 

I have successfully applied this to the Ubuntu 7.10 package (F-Spot 0.4.0), and it works for me. I hope this will be included in some form ;). Thanks!



Comment 14 Stephane Delcroix 2008-01-15 16:52:04 UTC
no need for a new gconf key, use the 'write metadata' one
Comment 15 Maxxer 2008-01-16 18:49:23 UTC
Created attachment 103011 [details] [review]
create-new-version-on-rotate.patch

Updated as per comment #14.
Comment 16 Mike 2008-09-05 06:18:19 UTC
This is just a vote in the negative. I think the current implementation makes lots of sense. Why would you need another copy of a photo that is exactly the same except for EXIF information? Plus, why would you want to revert a photo to a sideways orientation? Plus, if you did want to do that, why not alter the EXIF information back to the original, rather than making two copies? 

I see the value in the system of modifying originals when the change is lossy, but with lossless changes, I just don't see why we shouldn't just make the change....
Comment 17 Ryan Hayle 2008-09-05 07:41:50 UTC
I completely agree with not making another copy of the image and wasting disk space.  I think ideally, there would be a way to mark it as modified and only store a diff from the original file, that way if someone wanted to revert it, for whatever reason, it can simply be patched back.  The biggest scenario I can see for this, is when you are trying to compare f-spot photos with photos archives from another source, comparing md5's or something.  It just seems to "make sense" that if any kind of modification is made, it should be marked as such.
Comment 18 Ruben Vermeersch 2010-06-24 14:42:23 UTC
Comment on attachment 103011 [details] [review]
create-new-version-on-rotate.patch

Maintenance update: In the past we've been less than stellar in reviewing patches. As such we have a pile of patches in bugzilla which are outdated and don't apply anymore. Am currently marking all of these as "needs-work". My apologies for this.

Since I've become a maintainer of the project, I've set the personal rule of quickly reviewing all patches, to avoid that this happens again. If you (or anyone) wants to go through the trouble of updating this patch, please talk to us to figure out if it fits in the F-Spot long term roadmap.

Should you, in the future, notice a patch lingering around for too long, please notify us immediately and we'll look into it, to avoid situations like these from happening again.

You can filter these mails by searching for ###F-OLDPATCHCLEANUP###
Comment 19 André Klapper 2018-07-12 00:02:02 UTC
F-Spot has moved to https://github.com/f-spot/f-spot/issues

If this Bugzilla ticket is still valid in a recent version of F-Spot, please feel free to post this topic as a ticket in the F-Spot project on GitHub.

Closing this report as WONTFIX as part of Bugzilla Housekeeping as we are planning to shut down GNOME Bugzilla in favor of GNOME Gitlab.