Bug 150957

Summary: LibreOffice should ask user how it will save WEBP images inside ODT: as WEBP or as PNG
Product: LibreOffice Reporter: csongor
Component: WriterAssignee: Not Assigned <libreoffice-bugs>
Status: NEW ---    
Severity: enhancement CC: 79045_79045, heiko.tietze, ilmari.lauhakangas, olivier.dev, telesto
Priority: medium    
Version: 7.4.0.3 release   
Hardware: All   
OS: All   
See Also: https://bugs.documentfoundation.org/show_bug.cgi?id=115291
Whiteboard:
Crash report or crash signature: Regression By:
Bug Depends on:    
Bug Blocks: 103152    

Description csongor 2022-09-14 14:09:52 UTC
I was very happy to see that LO Writer supports webp images. 

If I use Insert -> Image in writer with JPG files then they are stored in the ODT as JPG, which is good. But if I do the same with WEBP files then they are stored as huge PNGs. I lose the benefit of WEBP.

The benefit of WEBP files over PNG is that a WEBP file uses lossy compression (and store transparency too, unlike JPG) but if they are stored as PNG internally then I lose its benefits. 

Please, store WEBP files as WEBP files, not as PNG.
Comment 1 Buovjaga 2022-09-14 14:31:49 UTC
Please read the discussion in bug 147373. It's not so simple as interoperability and backwards compatibility needs to be considered.
Comment 2 csongor 2022-09-14 14:43:27 UTC
(In reply to Buovjaga from comment #1)
> Please read the discussion in bug 147373. It's not so simple as
> interoperability and backwards compatibility needs to be considered.

I see. PNG is used in order to make it possible to open the ODT with older versions of LO, which don't support WEBP. Yeah, it makes sense. 

However, I think LO could do something what GIMP does, if you use non-legacy image layers. In that case the Save dialog of GIMP contains an alert:

------------
The image uses features from GIMP2.10 and won't be readable by older GIMP versions.
Layer mode 'Normal' was added in GIMP 2.10
------------ 

LO could do something similar, plus there could be a new checkbox where the "Automatic file name extension", "Save with password", ... checkboxes are:

"[_] convert WEBP images into PNG (larger file but more compatible)"
Comment 3 Heiko Tietze 2022-09-16 09:17:14 UTC
We could also just add another compatibility option. We had a lot of similar topics in the past, eg. bug 115291 talks about "List incompatible features when saving to alien formats in detail".
Comment 4 Roman Kuznetsov 2022-10-12 20:45:28 UTC
Let's change it to enhancement and set to NEW