Bug 202641 - Import images - always increase renaming counter by number of images imported
Summary: Import images - always increase renaming counter by number of images imported
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: AdvancedRename-Import (show other bugs)
Version: 1.0.0
Platform: Ubuntu Linux
: NOR wishlist
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-08-05 15:40 UTC by Michal Thoma
Modified: 2017-08-17 06:47 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In: 2.1.0


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michal Thoma 2009-08-05 15:40:29 UTC
Version:            (using KDE 4.3.0)
OS:                Linux
Installed from:    Ubuntu Packages

Import tool is very good feature of digikam. I recently started using it and tried renaming the files and using counter to make all image names original. It's very beneficial if there are no duplicate file names in archive and this should help prevent it.

But the setback here is that when i start counter with number 1 next time it again starts from 1! so in fact it will create duplicate file name!

I think digikam should always increase the starting number of the counter by the amount of images imported so that next use of Import tool won't create same file names.
Comment 1 Mikolaj Machowski 2009-08-05 19:30:21 UTC
For most people counter is used for current job renaming so this particular would harmful for most users.

However, interesting feature for digiKam import would be renaming images to make sure all images have unique numbers. Think about OAI and its identifiers

http://www.openarchives.org/OAI/2.0/guidelines-oai-identifier.htm

Note that for home use it is probably overkill and much more practical is schema {iso-date}_##### :)
Comment 2 Michal Thoma 2009-08-07 10:50:08 UTC
> However, interesting feature for digiKam import would be renaming images to
> make sure all images have unique numbers.

Yes, that would be nice.

> Note that for home use it is probably overkill and much more practical is
> schema {iso-date}_##### :)

Yes, that would also do, unfortunately AFAIK Import tool don't support such smart tags like {iso-date} or {original-filename} etc.
Comment 3 Andi Clemens 2009-08-07 10:58:51 UTC
That is not true. I have implemented a ManualRenameWidget , that allows such tags. It can be found in Camera-Import and in BQM.
It is not yet complete, but it features things like original filename, custom date format and custom numbering (with leading zeros and custom ranges / steps).
The only thing that is missing is the use of Metadata tags. But it will be implemented.
Comment 4 Michal Thoma 2009-08-07 11:48:28 UTC
Oh, I see now in 1.0.0b3. Before I was looking at 0.10.0 which don't have such feature still. So this is quite enough, great job and thank you!
Comment 5 Andi Clemens 2009-08-07 12:46:39 UTC
SVN commit 1008382 by aclemens:

Add the ability to only set a custom start in the ManualRenameInput
widget.
Added some test cases to verify the functionality.

CCBUG:202641

 M  +2 -1      libs/widgets/common/manualrenameinput.cpp  
 M  +12 -0     tests/manualrenameinputtest.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1008382
Comment 6 Andi Clemens 2009-08-08 15:06:26 UTC
I'm adding some quick access buttons to the rename widget:

http://farm4.static.flickr.com/3446/3800955702_0cf9a241d7_o.jpg
http://farm3.static.flickr.com/2476/3800136351_fb9853cc1d_o.jpg

Setting up individual import names should be easier then. The only thing that is not working right now is the Metadata button...
Comment 7 Michal Thoma 2009-08-10 11:06:30 UTC
Very nice! With this new manual rename widget I find the old Custom rename rather obsolete.
Comment 8 Andi Clemens 2009-08-11 17:20:15 UTC
Yes, I think it could be obsolete then.
I still need to figure out how to make it more extensible, it is working (somehow :-)), but I'm not happy.
The plan is to just add another token / parser, and the rest will work automatically.

What is working now:
- register the parser button automatically
- register the menu entry for the toolbutton automatically
- create the tooltip automatically

What is not working:
- the parser itself :) I need to abstract a lot, so that a common parse method can be used.

When all is working, I can image tokens / parser like:
- metadata (completely customizable)
- add author information
- tags information

etc...

Some rename options might not work in the cameraUI, but since we use this widget also in BQM, they could work in there, because BQM has full access to the database.

Andi
Comment 9 Andi Clemens 2009-08-11 17:30:58 UTC
This is the actual status:
http://farm3.static.flickr.com/2480/3811917860_0db6100ea8_o.jpg

But the only parsers really working are:
- File Name
- Camera Name
- Sequence Number
- Time & Date

the rest is just added at the moment to test the registration, and to show some ideas for additional parsers.
Comment 10 Andi Clemens 2009-11-09 11:23:26 UTC
This report can be closed?
I don't know if it is practical for most users to keep track of the index, but with AdvancedRename, you can set your starting index manually, see
http://www.flickr.com/photos/26732399@N05/4089342906/in/pool-digikam-labs
for example.

Is this enough for your needs?
Comment 11 Sallin 2010-02-03 18:04:36 UTC
First of all, I really enjoy digikam (current version 1.0.0-1, debian testing), so thanks for that. 

I've found a side effect of the "always increase renaming counter". When I want to use different names within one batch import, it remembers the count of the previous name. For instance, I import 10 photos according to "a###" and then import 10 photos according to "b###". The result will be a001 to a010, and b011 to b020. I can circumvent this by restarting the importer, but I think it could be done in a nicer way.
Comment 12 caulier.gilles 2011-08-09 13:51:10 UTC
Andi,

Do you see comment #11 ?

Gilles Caulier
Comment 13 Andi Clemens 2011-08-09 19:19:54 UTC
This should be fixed a long time ago, so we can close the bug.

Gilles:
By the way, the importing tool seems to be broken (CameraUI), it doesn't update the new image names and it always asks me in which folder to put the downloaded images, although I selected the album before (and then pressed CTRL+I).
Comment 14 caulier.gilles 2011-08-09 19:24:35 UTC
Thanks.

I take a look...

Gilles
Comment 15 caulier.gilles 2011-08-10 08:05:50 UTC
Git commit 6d0916343d845784de75bc60cd65b85047aa87e9 by Gilles Caulier.
Committed on 10/08/2011 at 10:04.
Pushed by cgilles into branch 'master'.

preserve download name information
CCBUGS: 202641

M  +2    -1    utilities/cameragui/items/cameraiconitem.cpp

http://commits.kde.org/digikam/6d0916343d845784de75bc60cd65b85047aa87e9
Comment 16 caulier.gilles 2011-08-10 08:06:14 UTC
Andi, 

it's fixed now. You confirm ?

Gilles Caulier
Comment 17 Sallin 2011-08-10 19:33:20 UTC
I just checked, and the behavior as described in comment 11 is still present in my version of Digikam. Like I said previously, it's not a big issue but it would be nice if it'd be handled differently.

Debian wheezy: 2.6.39-2-686-pae i686 GNU/Linux
Digikam version: 2:1.9.0-3