[Digikam-users] Re: need advice re: format conversion

Gilles Caulier caulier.gilles at gmail.com
Tue Jan 25 13:55:47 GMT 2011


2011/1/25 Elle Stone <l.elle.stone at gmail.com>:
> Gilles, I think you said above that PGF stores metadata. Yet when I
> used the digikam image editor to open a jpeg with lots of embedded
> metadata and immediately save it as a PGF file (no editing done), and
> use exiftool to look at the metadata, none of the important metadata
> was written to the PGF file. Instead there were several lines of new
> metadata regarding "MPEG" with information such as AudioLayer : 1
> AudioBitrate : 48 kbps SampleRate : 8000
> which as my little jpeg isn't an audio file, is confusing - this
> metadata is totally made up out of thin air.

Exiftool do not support PGF format. report this problem to Exiftool team

Exiv2 0.21 support this format. I'm sure, i implmented it myself...

http://dev.exiv2.org/projects/exiv2/repository/entry/tags/0.21/src/pgfimage.cpp

>
> When I open the same jpeg with the digiKam image editor, but save as
> tiff or png instead of pgf, all the jpeg original metadata is written
> to the tiff and the png. Is the problem that I'm still stuck on
> livexiv2-v0.19?

As i said, update to Exiv2 0.21

>
> Tom, you asked, "what converted format would YOU use - PGF for Digikam
> and PNG for Gimp, or PNG for both, or something else?" I keep my raw
> (cr2) files as cr2 files and will continue to do so even if I
> eventually decide to also use dng. I keep my camera-generated jpegs as
> jpegs, just as they come from the camera.
>
> When I use Gimp to process a camera jpeg file, I immediately save the
> file as "file.xcf" (Gimp's native format). General advice, as others
> have suggested: never process a camera jpeg original - always work
> with a copy, and immediately save that copy in a lossless format
> before further processing. If I want to work further with a file
> outside of Gimp, I export as tiff (call me old school), but I'm
> looking into using png because there are a lot of software
> compatibility issues with tiff. If I'm done processing, I export as
> jpeg or png for the web. Regarding PGF and digiKam, I'd use png
> instead.
>
> A little experiment:
> Original jpeg: 37 KB (its an extracted preview, not a camera-generated jpeg)
> Some file size comparisons, all files saved with digikam starting with
> the original jpeg
> Saved as lossless PGF: 265 KB (7 times bigger)
> Saved as png highest quality: 251 KB
> Saved as tif: 943 KB

JPEG is lossy format. You cannot compare to lossless format as well.

It's strange than PNG and PGF size are similar. In general PGF is
sivized by 2 compared to PNG.

I'm sure that for tiff, you have not used deflate compression option.
In this case TIFF size = PNG size.

If you want to compare PGF and JPEG, turn on lossless mode in PGF and
compress data. Compare after that image quality against JPEG.

For the same image quality, PGF file size is in general 2 or 3 time
better than JPEG file size (something similar than JPEG2000)

Gilles Caulier



More information about the Digikam-users mailing list