Jonathan Woithe <jwoi...@physics.adelaide.edu.au> writes:

Hi Jonathan:

>I'm not entirely sure how geeqie can be expected to detect this particular
>sequence of events, let along correct for it.  What exactly do you think
>geeqie should do in the above case?

Geeqie sees that files are changing and updates accordingly.  It should also
make sure that the thumbnail changes follow along and properly track the
images.

>> This is now a very serious issue as there does not appear to be a way to
>> fix this problem short of destroying the entire thumbnail cache and having
>> to rebuild all stored thumbnails from scratch.

>If something goes and messes with the cache in this way I think it's
>perfectly reasonable to expect that applications will behave strangely.  So
>maybe I've totally misunderstood what's being described.

Well, nothing is messing with the cache - only with the original images.
The problem is that geeqie is no updating the cache to reflect changes that
it sees are occurring to the image files.  There must be some sort of test
that identifies when the cached thumbnail no longer corresponds to the
file and updates it.

>> The solution to this problem is to force thumbnails to be updated when out
>> of date, by comparing a timestamp to the original file.

>This won't fix the problem created by the steps you outlined above unless
>you check the ctime (all other timestamps are not affected by rename
>operations).  However, even here you would need the thumbnail's ctime be set
>to that of the original image when it was created to allow unambiguous
>determination that a thumbnail is "out of date", and I don't think that's
>possible.

The thumbnail is created after the image file, so it seems to me that all
you need to do is see if the thumbnail's ctime is older than the image file
and if so, update it.  (I see no need to set the thumbnail's ctime to match
the image file exactly.)  The check should be performed every time the
thumbnail is loaded for display.  All currently displayed thumbnails would
get rechecked upon a refresh.  This already appears to be happening for
the mtime, because when I write new exif data to an image file, I see the
thumbnails being recreated in geeqie when it sees the image file changing.
But this does not account for these file renaming operations, so switching
to the ctime rather than the mtime, and looking for older timestamps would
address the problem.

>> Also, there needs to be an option ... that forces thumbnails to be
>> recreated in the current folder.

>That could be useful in some specific circumstances I guess.

>> ... but this particular problem is causing me quit a bit of difficulties

>I am curious - what real-world scenario creates a situation along the lines
>of the one you illustrated above?  About the only thing I can think of which
>is vaguely similar is that some other application clobbers geeqie's
>thumbnails, but that's quite different to the renaming magic you describe
>(and could be detected by looking at the thumbnail mtime).  In any case,
>aren't the shared thumbnail filenames generated with a hash, making such
>collisions rather unlikely (or am I thinking of something else - I'm no
>expert here)?

Actually, the sequence I described IS my real-world scenario.  I have
huge folders of unprocessed images from my camera.  I start by taking a
look at them in geeqie on one screen while I manipulate the image files
in terminal windows on an adjacent screen using many scripts that I have
written to process the renaming and renumbering of files, adding exif time
and description data, and so on.  I delete files I do not wish to keep,
rename files by subject and sequence number, edit them in gimp, and then
resequence (i.e., renumber) them as appropriate -- all the while keeping an
eye on the picture set with geeqie.  If the thumbnails get out of sequence
with the images, then abandon ship, all hope is lost, as I can no longer
successfully locate any specific picture using geeqie's thumbnails! :-)

I hope that explains things a but better.

Regards,
-- 
Jeffery Small
j...@cjsa.com


------------------------------------------------------------------------------
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
_______________________________________________
Geeqie-devel mailing list
Geeqie-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geeqie-devel

Reply via email to