Bug 358577 - Maintenance tool rebuild thumbnails directory filter not working on video files
Summary: Maintenance tool rebuild thumbnails directory filter not working on video files
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: Thumbs-Video (show other bugs)
Version: 5.0.0
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-01-26 10:43 UTC by Evert Vorster
Modified: 2017-07-27 10:58 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In: 5.0.0
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Evert Vorster 2016-01-26 10:43:52 UTC
I have serious issues with thumbnails, both in the QT4 version of digikam, and the recent beta. 
I have noticed this specific bug before in the QT4 version, but since the QT5 version of digikam is slightly better at thumbnailing, I have uploaded a clip showing the issue here. 

https://youtu.be/1Mse6guHoro

In short, I can see that one of the thumbnails for a clip is wrong. I suspect that the clip got the wrong thumbnail due to a race condition that I created when importing from two sources at once. ( I don't suppose many people hit this bug )

Pressing F5 while the album is selected I would expect to see a refresh of that album, but that does not work. 
I then go into the maintenance tools, and select just that folder, and "rebuild thumbnails" When I then click OK, the process returns instantly, and the folder's thumbnails are not updated. 

Since I have terabytes of pictures and video, I am reluctant to rebuild the entire thumbnail database. 

Reproducible: Always

Steps to Reproduce:
1. Select Maintenance tools. 
2. Select one folder only, no tags. 
3. Select "Rebuild Thumbnails"
4. Select "OK"

Actual Results:  
Thumbnails for the selected folder are not re-built

Expected Results:  
Re-built thumbnails. 

I am running on Arch Linux, and rebuilding digikam from git is no sweat, so I am willing to test any fixes almost as soon as they hit git.
Comment 1 Evert Vorster 2016-01-26 10:46:03 UTC
Oh, and the slider at the bottom of video clips don't work either. 

;)
Comment 2 caulier.gilles 2016-01-26 10:57:13 UTC
video files support is delegate to Qt5::Multimedia. There is no code in digiKam to handle video file directly.

It know that  Qt5::Multimedia has problem with GStreamer. It must be fixed with qt 5.5.x

Gilles Caulier
Comment 3 Evert Vorster 2016-01-26 11:01:46 UTC
The thumbnails for this folder is cached. 

In the maintenance tool, when selecting the entire database, and selecting "Rebuild Thumbnails" All of the thumbnails are re-built. 
When selecting only one folder, NO thumbnails are re-built. 

How is this the fault of QT5?
Comment 4 Evert Vorster 2016-01-26 11:37:38 UTC
Hmm, hitting refresh on an album with photos in does indeed refresh the thumbnails of the photos, but not videos, so this behaviour is specific to video clips. 

So, how can I tell DigiKam to re-do one thumbnail of a video clip?

Opening the folder in Dolphin shows the correct thumbnail, so DigiKam has a thumbnail cached somewhere, and in this case it's for the wrong clip.
Comment 5 caulier.gilles 2016-01-26 12:27:36 UTC
digiKam do not share thumbnail with the rest of KDE. It use a dedicated database with waveltes compression to optimize space and support removable media.

Gilles Caulier
Comment 6 caulier.gilles 2016-01-26 12:29:33 UTC
Maik,

You don't have fixed this kind of dysfunction in the past, especially with last Qt4 implementation ?

Gilles
Comment 7 Maik Qualmann 2016-01-26 20:10:52 UTC
Everything works here correctly.

Have you Dolphin4 or Dolphin5 installed? You must have installed a thumbnailer for Qt5. My package for Qt5 is ffmpegthumbs.

Maik
Comment 8 Maik Qualmann 2016-01-26 20:15:24 UTC
(In reply to Evert Vorster from comment #1)
> Oh, and the slider at the bottom of video clips don't work either. 

Yes, is already on my TODO list.

Maik
Comment 9 Evert Vorster 2016-01-27 05:58:35 UTC
I have QT5 thumbnailer installed. 

How else would I get the thumbnails in the first place?

A little bit of history... 
DigiKam 4.xx started failing on thumbnails for video recently, and so I installed DigiKam 5.0.0.
I re-built my entire data base's thumbnails, and it took many hours. 
Everything looked to be fine. 

Then I imported from two sources at once, my wife's phone and an SD card reader. 
One of the video thumbnails is incorrect in DigiKam only, and shows correct on Dolphin. (5)
Refreshing the album does not fix the thumbnail in DigiKam.

Using the maintenance tools also does not delete the cached thumbnail. 

I do not want to delete ALL my thumbnails again, since it will take a very long tie to re-create all of them. It should be easy to delete a thumbnail and let DigiKam re-create it as if it is a new file.

Heeeey, I just found an easy workaround. 
I navigated to the directory in a console, and just touched the file with bad thumbnail. 
DigiKam then re-created the thumbnail, and got it right this time. 
:)
Comment 10 Maik Qualmann 2016-02-04 18:25:34 UTC
Git commit 69c310486b843f3c5dc4a40ead37bea63fc75282 by Maik Qualmann.
Committed on 04/02/2016 at 18:23.
Pushed by mqualmann into branch 'master'.

include video files in the maintenance tool rebuild thumbnails
FIXED-IN: 5.0.0

M  +3    -2    utilities/maintenance/thumbsgenerator.cpp

http://commits.kde.org/digikam/69c310486b843f3c5dc4a40ead37bea63fc75282
Comment 11 Evert Vorster 2016-02-07 21:20:10 UTC
I can confirm the fix. 
Thanks for the work!