Summary: | Support HDR DNG images from HDRMerge | ||
---|---|---|---|
Product: | [Applications] digikam | Reporter: | DrSlony <bugs> |
Component: | Thumbs-RAW | Assignee: | Digikam Developers <digikam-bugs-null> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | bugs, caulier.gilles |
Priority: | NOR | ||
Version: | 4.2.0 | ||
Target Milestone: | --- | ||
Platform: | Other | ||
OS: | Linux | ||
Latest Commit: | http://commits.kde.org/digikam/617f203acb9fec474c95c3dbd7660adb1dcc57f7 | Version Fixed In: | 4.3.0 |
Sentry Crash Report: |
Description
DrSlony
2014-08-06 23:31:58 UTC
With "[x] Embedded preview loads full-sized images" checked, thumbnails are not shown but clicking on a thumb does show the large preview. http://i.imgur.com/abRoxR9.jpg RAW preview including DNG file are processed by libraw in background. Please report this problem to Libraw team. Gilles Caulier Hi Gilles, thank your for responding. I can't find libraw's bugzilla, can you point me? I sent them a message but these are usually ignored if they're not filed in the correct place. Sound like libraw use GitHub issue manager. I can seen 8 entries closed : https://github.com/LibRaw/LibRaw/issues?q=is%3Aissue+is%3Aclosed Gilles Caulier Do you also use libraw to extract the embedded JPEG thumbnail and preview image? Because digiKam DOES show the embedded preview, but it does NOT show the thumbnail. My request is for digiKam to show the embedded preview and thumbnail so that these DNG images can be managed. ps. I wrote in comment 0 that it does not show the embedded preview - this is wrong, 4.2.0 does show the preview. Maybe I had an older version of some dependency back then. Now I'm using 4.2.0 and previews are shown after clicking on the DNG, but still no thumbs. digiKam version 4.2.0 CPU cores: 8 Demosaic GPL2 pack support: No Demosaic GPL3 pack support: No Exiv2 can write to Jp2: Yes Exiv2 can write to Jpeg: Yes Exiv2 can write to Pgf: Yes Exiv2 can write to Png: Yes Exiv2 can write to Tiff: Yes Exiv2 supports XMP metadata: Yes LibCImg: 130 LibEigen: 3.2.0 LibExiv2: 0.24 LibJPEG: 62 LibJasper: 1.900.1 LibKDE: 4.13.3 LibKExiv2: 2.3.1 LibKGeoMap: 2.0.0 LibKdcraw: 2.4.2 LibLCMS: 2060 LibLensFun: 0.2.8-0 LibPGF: 6.12.27 - external shared library LibPNG: 1.6.12 LibQt: 4.8.5 LibRaw: 0.16.0-Beta1 LibTIFF: LIBTIFF, Version 4.0.3 Copyright (c) 1988-1996 Sam Leffler Copyright (c) 1991-1996 Silicon Graphics, Inc. Marble Widget: 0.18.3 (stable release) Parallelized PGF codec: No Parallelized demosaicing: Yes RawSpeed codec support: No Database backend: QSQLITE Kipi-Plugins: 4.2.0 LibKface: 3.0.0 LibKipi: 2.1.0 LibOpenCV: 2.4.5 Yes, libraw is used in Both case. Note Exiv2 has also a method to extract preview from DNG. Please report this problem too in Exiv2 bugzilla. Gilles Caulier LibRaw refuse to support even simple extraction of the embedded JPEG thumbnail. I can already extract BOTH preview images from that DNG using exiv2-0.24. Preview-2 is large, preview-1 is small, thumbnail-sized in fact (256x172). It could be used for the thumbnail in digiKam. exiv2 -ep1 hdrmerge_045.dng To reiterate: 1- digiKam already shows the large preview when you click on the thumbnail, but it shows no thumbnail. 2- exiv2 can extract both previews, 3- so you could use it to get the small preview for the thumbnail. I removed the "resolved - upstream" status as one upstream refused to do anything (libraw), and the other already supports it (exiv2). So now it's up to digiKam to make use of exiv2's ability to get the thumb. Can you share some DNG files to test here ? Gilles Caulier Sure, there is a link to one in my original comment here: http://rawtherapee.com/shared/test_images/hdrmerge_045.dng Let me know if you need more. I discussed this with the Exiv2 devs (See comment 7 for the link) and it appears that Exiv2 is working correctly. No Exif thumbnail exists inside this image, so digiKam should use the embedded preview-1 image as the thumbnail. Yes, reproducible here : digikam(72287)/digikam (core) Digikam::DImg::load: "/Users/gilles/Pictures/photos.test/hdrmerge_045.dng" : RAW file identified digikam(72287)/digikam (core) Digikam::JPEGUtils::isJpegImage: mimetype = "TIFF" ext = "DNG" digikam(72287)/digikam (core) Digikam::ThumbnailCreator::createThumbnail: Cannot create thumbnail for "/Users/gilles/Pictures/photos.test/hdrmerge_045.dng" digikam(72287)/digikam (core) Digikam::ThumbnailCreator::load: Thumbnail is null for "/Users/gilles/Pictures/photos.test/hdrmerge_045.dng" Gilles Caulier First problem confirmed Libraw 0.16 cannot extract embedded preview and half preview with this DNG file : digikam(75049)/digikam (core) Digikam::ThumbnailCreator::load: Thumbnail is null for "/Users/gilles/Pictures/photos.test/hdrmerge_045.dng" digikam(75049)/digikam (core) Digikam::ThumbnailCreator::createThumbnail: Trying to load Embedded preview with libraw digikam(75049)/digikam (core) Digikam::ThumbnailCreator::createThumbnail: Trying to load half preview with libraw This debug statements just proof that libraw is not able to work with this file without to use a full demosaicing method. Typically this DNG is badly encoded by HDRMerge. Gilles Caulier Other point : as libraw cannot play with this DNG, Image cannot be loaded in image editor... Gilles Caulier 1- How is it "badly encoded"? 2- digiKam uses exiv2, and exiv2 can extract the preview. That would be enough for the thumbnail to let us manage these files using digiKam. "Programs using a library like libkdcraw/libraw to fully read the raw image and obtain the preview. They fail, because libraw does not know how to read the float data. Since reading the data and the preview is performed in just one call to open(), the preview is not available when reading the data fails" https://github.com/jcelaya/hdrmerge/issues/27#issuecomment-53459385 Git commit 617f203acb9fec474c95c3dbd7660adb1dcc57f7 by Gilles Caulier. Committed on 01/09/2014 at 06:05. Pushed by cgilles into branch 'master'. For dumy DNG file badbly encode and unsupported by libraw, try to use Exiv2 preview extraction to render thumbnail. FIXED-IN: 4.3.0 M +13 -1 libs/threadimageio/thumbnailcreator.cpp http://commits.kde.org/digikam/617f203acb9fec474c95c3dbd7660adb1dcc57f7 DrSlony, The RAW Demosaicing problem still here. As HDRMerge do not provide a valid DNG file which can be processed with libraw, report this problem to HDRMerge team for future fixes. This problem cannot be solved in digiKam code. Gilles Caulier CG thank you VERY much for this patch! Seeing thumbs will make things so much easier :) I don't need digiKam to read the raw data, just showing the thumbnails is enough. ps. I've been collaborating with various teams for HDR-DNG thumbnail/preview support, and I sent the report links to Javier Celaya (the HDRMerge dev). I pasted the link in comment #16. As far as I am aware the DNG files are not "badly encoded", there is nothing wrong with them. The only problem is libraw does not supporting floating point data, and attempts to read both the raw data and the thumb in one call, so if reading the raw data fails, which it will, then reading the thumb will fail too, which it should not. |