In thumbnails view, when I'm importing images from my camera (Canon Powershot A710 IS) and I click on an image to activate the preview (or, that is the same, I click on the proper button in the toolbar) Digikam says it cannot load the image. The problem seems to be a wrong path: Digikam correctly retrieves the thumbnails but when needs to load a bigger preview it uses a wrong path. Here there is an example of output message if Digikam is launched from a shell: digikam(24732)/digikam (core) Digikam::PreviewLoadingTask::execute: Cannot extract preview for "/store_00010001/DCIM/IMG_7278.JPG" No location could be retrieved for url KUrl("file:///store_00010001/DCIM/IMG_7278.JPG") The correct path should be, instead, file:///store_00010001/DCIM/100CANON/IMG_7278.JPG . In fact, my camera stores photos in subfolders of a parent folder DCIM (located in the root of the SD card), and these subfolders are named 100CANON, 101 CANON, and so on. Digikam doesn't use the complete path. Reproducible: Always Steps to Reproduce: 1. Connect a camera and go to the import panel 2. Switch from thumbnails view to preview mode by clicking on a thumbnail Actual Results: Digikam says it cannot load the image Expected Results: Digikam should load a preview I think that, for reproducing this bug, you need a camera that stores files in a structured tree. For example, mine (Canon Powershot A 710 IS) stores them in a structure DCIM/100CANON/. Digikam misses to go through the whole path. This problem is only related to the import mode: preview in album view works.
Can you try and see what gphoto2 -L gives to you? Are the paths correct there?
Can confirm with Nexus7 and MTP.
The cause for this is that when you are using a MTP/PTP device the path in CamItemInfo is set to be the path inside your device. And when digikam tries to load a local file with that it of course doesn't work. Possible solutions: - Disable the preview mode completely for non-UMS devices. - Implement loading the file to a temporary file when being previewed and load it from there.
Teemu, I vote to disable preview with Gphoto camera in first. It's easy to do... If time permit, the temporary download can be done, but it's not a priority... There are more important bug to fix in first. Gilles Caulier
(In reply to comment #1) > Can you try and see what gphoto2 -L gives to you? Are the paths correct > there? Yes, they are: $ gphoto2 -L There is no file in folder '/'. There is no file in folder '/store_00010001'. There is no file in folder '/store_00010001/DCIM'. There is no file in folder '/store_00010001/DCIM/100CANON'. There are 276 files in folder '/store_00010001/DCIM/101CANON'. #1 IMG_0514.JPG rd 3129 KB 3072x2304 image/jpeg [.......] #276 STA_0511.JPG rd 4938 KB 3072x2304 image/jpeg There is no file in folder '/store_00010001/MISC'. I'm sorry for this late reply, I've access to the mentioned camera only in some periods, especially holidays, since it is not mine (it's my father's camera).
Created attachment 89913 [details] gphotopreview.patch This patch disables the preview at GPhoto driver and the context menu "Open With...".
Git commit 7b71987a7f401cf5f906e992382afb5157584630 by Gilles Caulier. Committed on 10/12/2014 at 22:00. Pushed by cgilles into branch 'master'. apply patch #89913 from Maik Qualmann about to disable preview mode with Gphoto2 camera FIXED-IN: 4.6.0 M +6 -1 utilities/importui/main/importui.cpp M +1 -0 utilities/importui/main/importui.h M +5 -0 utilities/importui/views/importview.cpp M +2 -2 utilities/importui/widgets/importcontextmenu.cpp http://commits.kde.org/digikam/7b71987a7f401cf5f906e992382afb5157584630