PGF files in KDE

classic Classic list List threaded Threaded
11 messages Options
Reply | Threaded
Open this post in threaded view
|

PGF files in KDE

S. Burmeister
Hey everybody!

I noticed that while digikam can handle PGF files other KDE applications like
dolphin and gwenview cannot. I thought that KDE apps would share the code to
read previews from files and generate thumbnails etc.

So is that code in trunk/4.7 or simply not shared and digikam using its own
solution?

Thanks

Sven
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

Re: PGF files in KDE

Gilles Caulier-4
digiKam has a dedicated PGF loader, to be able to handle 16 bits color
depth image. It's not a QImage extension, digiKam do not use it to
manipulate image data. We use a proper image management class named
DImg.

PGF lib is included in digiKam core as 3rd party lib.

We have a PGF image loader/writer.

There is plan to share this code with the rest of KDE...

Best

Gilles Caulier

2011/5/15 Sven Burmeister <[hidden email]>:

> Hey everybody!
>
> I noticed that while digikam can handle PGF files other KDE applications like
> dolphin and gwenview cannot. I thought that KDE apps would share the code to
> read previews from files and generate thumbnails etc.
>
> So is that code in trunk/4.7 or simply not shared and digikam using its own
> solution?
>
> Thanks
>
> Sven
> _______________________________________________
> Digikam-devel mailing list
> [hidden email]
> https://mail.kde.org/mailman/listinfo/digikam-devel
>
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

Re: PGF files in KDE

Francesco Riosa
In data domenica 15 maggio 2011 22:49:03, Gilles Caulier ha scritto:

> digiKam has a dedicated PGF loader, to be able to handle 16 bits color
> depth image. It's not a QImage extension, digiKam do not use it to
> manipulate image data. We use a proper image management class named
> DImg.
>
> PGF lib is included in digiKam core as 3rd party lib.
>
> We have a PGF image loader/writer.
>
> There is plan to share this code with the rest of KDE...

very good because PGF really rocks

>
> Best
>
> Gilles Caulier
>
> 2011/5/15 Sven Burmeister <[hidden email]>:
> > Hey everybody!
> >
> > I noticed that while digikam can handle PGF files other KDE applications
> > like dolphin and gwenview cannot. I thought that KDE apps would share
> > the code to read previews from files and generate thumbnails etc.
> >
> > So is that code in trunk/4.7 or simply not shared and digikam using its
> > own solution?
> >
> > Thanks
> >
> > Sven
> > _______________________________________________
> > Digikam-devel mailing list
> > [hidden email]
> > https://mail.kde.org/mailman/listinfo/digikam-devel
>
> _______________________________________________
> Digikam-devel mailing list
> [hidden email]
> https://mail.kde.org/mailman/listinfo/digikam-devel
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

Re: PGF files in KDE

S. Burmeister
In reply to this post by Gilles Caulier-4
Am Sonntag, 15. Mai 2011, 22:49:03 schrieb Gilles Caulier:

> digiKam has a dedicated PGF loader, to be able to handle 16 bits color
> depth image. It's not a QImage extension, digiKam do not use it to
> manipulate image data. We use a proper image management class named
> DImg.
>
> PGF lib is included in digiKam core as 3rd party lib.
>
> We have a PGF image loader/writer.
>
> There is plan to share this code with the rest of KDE...

This would be really good because PGF would spread a lot easier if it was
supported across KDE and other DEs. Currently there is only one application
and that is digikam, i.e. you can not view the pictures with dolphin. JPGs are
a lot easier in that regard.

Sven
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

Re: PGF files in KDE

S. Burmeister
In reply to this post by Francesco Riosa
Am Sonntag, 15. Mai 2011, 23:23:43 schrieb Francesco R.:
> very good because PGF really rocks

To be honest I'm a bit disappointed. If I save my RAW files to lossless PGFs
they get as huge as they get with PNG. And even saving a 2.5 MB JPG to
lossless PGF increases the size to ~8 MB, that's three times the original
size.

Is there anything I'm doing wrong or that would improve over time?

Sven
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

Re: PGF files in KDE

S. Burmeister
Am Montag, 16. Mai 2011, 01:39:39 schrieb Sven Burmeister:
> Am Sonntag, 15. Mai 2011, 23:23:43 schrieb Francesco R.:
> > very good because PGF really rocks
>
> To be honest I'm a bit disappointed. If I save my RAW files to lossless PGFs
> they get as huge as they get with PNG. And even saving a 2.5 MB JPG to
> lossless PGF increases the size to ~8 MB, that's three times the original
> size.
>
> Is there anything I'm doing wrong or that would improve over time?

Why is e.g. a 8 bpp jpg saved as 16 bpp PGF? Is that maybe a bug in digikam?

Sven
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

Re: PGF files in KDE

Gilles Caulier-4
2011/5/16 Sven Burmeister <[hidden email]>:

> Am Montag, 16. Mai 2011, 01:39:39 schrieb Sven Burmeister:
>> Am Sonntag, 15. Mai 2011, 23:23:43 schrieb Francesco R.:
>> > very good because PGF really rocks
>>
>> To be honest I'm a bit disappointed. If I save my RAW files to lossless PGFs
>> they get as huge as they get with PNG. And even saving a 2.5 MB JPG to
>> lossless PGF increases the size to ~8 MB, that's three times the original
>> size.
>>
>> Is there anything I'm doing wrong or that would improve over time?
>
> Why is e.g. a 8 bpp jpg saved as 16 bpp PGF? Is that maybe a bug in digikam?

In digiKam, an original 8 bits image (as JPEG) is always saved in 8
bits as PGF...

Gilles Caulier

>
> Sven
> _______________________________________________
> Digikam-devel mailing list
> [hidden email]
> https://mail.kde.org/mailman/listinfo/digikam-devel
>
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

Re: PGF files in KDE

S. Burmeister
Am Montag, 16. Mai 2011, 07:01:43 schrieb Gilles Caulier:
> > Why is e.g. a 8 bpp jpg saved as 16 bpp PGF? Is that maybe a bug in
> > digikam?
>
> In digiKam, an original 8 bits image (as JPEG) is always saved in 8
> bits as PGF...

No. Saving a 8 bpp jpg to pgf shows a bitdepth of even 24 bpp in digikam. So
either digikam displays wrong information or increases the bpp from 8 to 24.
Tested with a git checkout of digikam compilation from some days ago.

Sven
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

Re: PGF files in KDE

Gilles Caulier-4
16 bits colors dept ==> 48 bits by pixels ( Red = 16 bits + Green = 16
bits + Blue = 16 bits)

In fact one pixel = 4*16 bits = 48 bits, not 24 bits.

24 bits by pixel want mean 3*8 = 24  ( Red = 8 bits + Green = 8 bits +
Blue = 8 bits)

Do not confound color depth by color component and and color depth for
all components for one pixel. One pixel is 3 color components...

Gilles Caulier

2011/5/16 Sven Burmeister <[hidden email]>:

> Am Montag, 16. Mai 2011, 07:01:43 schrieb Gilles Caulier:
>> > Why is e.g. a 8 bpp jpg saved as 16 bpp PGF? Is that maybe a bug in
>> > digikam?
>>
>> In digiKam, an original 8 bits image (as JPEG) is always saved in 8
>> bits as PGF...
>
> No. Saving a 8 bpp jpg to pgf shows a bitdepth of even 24 bpp in digikam. So
> either digikam displays wrong information or increases the bpp from 8 to 24.
> Tested with a git checkout of digikam compilation from some days ago.
>
> Sven
> _______________________________________________
> Digikam-devel mailing list
> [hidden email]
> https://mail.kde.org/mailman/listinfo/digikam-devel
>
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

Re: PGF files in KDE

S. Burmeister
Am Montag, 16. Mai 2011, 10:36:17 schrieb Gilles Caulier:

> 16 bits colors dept ==> 48 bits by pixels ( Red = 16 bits + Green = 16
> bits + Blue = 16 bits)
>
> In fact one pixel = 4*16 bits = 48 bits, not 24 bits.
>
> 24 bits by pixel want mean 3*8 = 24  ( Red = 8 bits + Green = 8 bits +
> Blue = 8 bits)
>
> Do not confound color depth by color component and and color depth for
> all components for one pixel. One pixel is 3 color components...

Ok, so you say that although one picture shows 24 bpp and the other 8 bpp they
are both 8 bit pictures.

So how do I get a PGF that holds the same information the JPG holds, no less,
no more and has a compareable size, i.e. not three times as big?

Sven
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

Re: PGF files in KDE

Gilles Caulier-4
2011/5/16 Sven Burmeister <[hidden email]>:

> Am Montag, 16. Mai 2011, 10:36:17 schrieb Gilles Caulier:
>> 16 bits colors dept ==> 48 bits by pixels ( Red = 16 bits + Green = 16
>> bits + Blue = 16 bits)
>>
>> In fact one pixel = 4*16 bits = 48 bits, not 24 bits.
>>
>> 24 bits by pixel want mean 3*8 = 24  ( Red = 8 bits + Green = 8 bits +
>> Blue = 8 bits)
>>
>> Do not confound color depth by color component and and color depth for
>> all components for one pixel. One pixel is 3 color components...
>
> Ok, so you say that although one picture shows 24 bpp and the other 8 bpp they
> are both 8 bit pictures.
>
> So how do I get a PGF that holds the same information the JPG holds, no less,
> no more and has a compareable size, i.e. not three times as big?

PGF do not use the same compress method than JPEG. It use wavelets compress.

If you use lossless compression, ratio will be bigger than JPEG. It's
normal. Same behavior can be see with JPEG 2000. JPEG2000 and PGF use
similar method to compress and ration are the same.

There is lossless method compress in JPEG, but this is not implemented
in libjpeg. In fact it's patented and only used in medecine world.

If you want to compare PGF and JPEG you need to use same compression
method : not lossless

Gilles Caulier
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel