Display of quality when saving formats that are not lossless

*** Please try to reproduce your bug and confirm the bug fix. ***

Moderators: XnTriq, helmut, xnview, Dreamer

Xn User
Posts: 217
Joined: Sat Jan 05, 2019 1:16 pm

Display of quality when saving formats that are not lossless

Post by Xn User »

Hi)
In all file types have settings for select quality level , and this setting have ranges from 0 to 100 , I think what this not correctly and can mislead because 100 means lossless , but not all formats lossless.
I offer do in formats where absent method lossless , range 1-99 , and if have method lossless range 1-100 or lossless formats as separate group
You do not have the required permissions to view the files attached to this post.
User avatar
xnview
Author of XnView
Posts: 45495
Joined: Mon Oct 13, 2003 7:31 am
Location: France

Re: Display of quality when saving formats that are not lossless

Post by xnview »

It's the same if you select quality=100 or lossless
Pierre.
Xn User
Posts: 217
Joined: Sat Jan 05, 2019 1:16 pm

Re: Display of quality when saving formats that are not lossless

Post by Xn User »

At all not same , I sayd and meant what need maximum setting 99 in formats which not support compression without lossy , for example JPEG standard , what be would people know what saving in lossy format
Simply remove value 1 and move all values to -1 and so will be understanded correctly )
What is now value 1 will set 2 and what is now value 99 will set 100
And from this logic as you sayd , is just visible flaw , because in JPEG and any lossless format have value 100 , but this not same )
You do not have the required permissions to view the files attached to this post.
Xn User
Posts: 217
Joined: Sat Jan 05, 2019 1:16 pm

Re: Display of quality when saving formats that are not lossless

Post by Xn User »

Also in XnConvert WEBP lossless and WEBP 100% quality not same

file with Lossless 14 MB
file with 100% quality 6,7 MB
You do not have the required permissions to view the files attached to this post.
cday
XnThusiast
Posts: 4289
Joined: Sun Apr 29, 2012 9:45 am
Location: Cheltenham, U.K.

Re: Display of quality when saving formats that are not lossless

Post by cday »

I think it is important to understand that:

o JPEG itself is always a lossy format;

o That Quality = 100% is a valid quality value that does not represent no loss of quality relative to the open image;

o That when 'lossless' saving is used the main part of the image is saved exactly, but some pixels at the edges of the image may be removed to allow that.
cday
XnThusiast
Posts: 4289
Joined: Sun Apr 29, 2012 9:45 am
Location: Cheltenham, U.K.

Re: Display of quality when saving formats that are not lossless

Post by cday »

My previous post rewritten, I hope it represents a correct statement of the facts! :wink:
Xn User
Posts: 217
Joined: Sat Jan 05, 2019 1:16 pm

Re: Display of quality when saving formats that are not lossless

Post by Xn User »

Good ) why WEBP 100% and WEBP Lossless not coincide ?
And my idea what be people always known what in format have loss ) that's why 99% for lossy )
User avatar
xnview
Author of XnView
Posts: 45495
Joined: Mon Oct 13, 2003 7:31 am
Location: France

Re: Display of quality when saving formats that are not lossless

Post by xnview »

:bugconfirmed: Thanks to your detailed description I can reproduce the problem.
Pierre.
User avatar
XnTriq
Moderator & Librarian
Posts: 6451
Joined: Sun Sep 25, 2005 3:00 am
Location: Ref Desk

Re: Display of quality when saving formats that are not lossless

Post by XnTriq »

XnView Classic's and MP's “JPEG functions are based in part on the work of the Independent JPEG group” (libjpeg).
The quality (Q factor) setting of their official software ranges from 0 to 100.
usage.txt (https://www.ijg.org/files/jpegsr9f.zip) wrote:We provide two programs, cjpeg to compress an image file into JPEG format, and djpeg to decompress a JPEG file back into a conventional image format.
usage.txt (https://www.ijg.org/files/jpegsr9f.zip) wrote:The basic command line switches for cjpeg are:

Code: Select all

-quality N[,...] Scale quantization tables to adjust image quality.
                 Quality is 0 (worst) to 100 (best); default is 75.
                 See below for more info.)
usage.txt (https://www.ijg.org/files/jpegsr9f.zip) wrote:The -quality switch lets you trade off compressed file size against quality of the reconstructed image: the higher the quality setting, the larger the JPEG file, and the closer the output image will be to the original input. Normally you want to use the lowest quality setting (smallest file) that decompresses into something visually indistinguishable from the original image. For this purpose the quality setting should be between 50 and 95; the default of 75 is often about right. If you see defects at -quality 75, then go up 5 or 10 counts at a time until you are happy with the output image. (The optimal setting will vary from one image to another.)
usage.txt (https://www.ijg.org/files/jpegsr9f.zip) wrote:-quality 100 will generate a quantization table of all 1's, minimizing loss in the quantization step (but there is still information loss in subsampling, as well as roundoff error). This setting is mainly of interest for experimental purposes. Quality values above about 95 are NOT recommended for normal use; the compressed file size goes up dramatically for hardly any gain in output image quality.
Xn User
Posts: 217
Joined: Sat Jan 05, 2019 1:16 pm

Re: Display of quality when saving formats that are not lossless

Post by Xn User »

Thank you ) I'm this understand , but now when option save lossless , I think what it makes sense make new standard ) before and MP3 128 also thinked as CD Quality , but now if compress music with this bitrate on old codecs and you are not very old , more likely you not want accept what 128 kbit/s is CD Quality ) that's why I try change perception to a more accurate ) and that's why I want make standard where will be unambiguous separation on without lossy or 100% quality and lossy or maximum 99% quality )

I do not insist , I simply try argumentate why so I see )
User avatar
XnTriq
Moderator & Librarian
Posts: 6451
Joined: Sun Sep 25, 2005 3:00 am
Location: Ref Desk

Re: Display of quality when saving formats that are not lossless

Post by XnTriq »

I agree. Some sort of indication to distinguish between lossless and best lossy compression would be helpful.
Xn User
Posts: 217
Joined: Sat Jan 05, 2019 1:16 pm

Re: Display of quality when saving formats that are not lossless

Post by Xn User »

Then can do in menu select format types lossless or with lossy ) , and in Lossless and separate compression formats separately for lossless mode and lossy mode )
When select lossless , display only lossless formats and absent others ) when select lossy , display all formats with lossy )
Simply two groups formats ) and all , I think this do more clear )
And in group lossless formats , all formats need make only with lossless mode compression )
For example , if I select convertation type lossless , so display BMP / PCX / PNG / TIFF (LZW/Detflate) / JPEG2000 / HEIF / AVIF / WEBP / FLIF with only preset lossless )
and if I select convertation type losy , need display all other formats and TIFF (JPEG) / JPEG2000 lossy mode / HEIF lossy mode / AVIF lossy mode / WEBP lossy mode) and with this do range losy from wrost quality to best quality )
User avatar
xnview
Author of XnView
Posts: 45495
Joined: Mon Oct 13, 2003 7:31 am
Location: France

Re: Display of quality when saving formats that are not lossless

Post by xnview »

This problem is supposed to be fixed in XnView MP 1.8.4. Please check and confirm the bug fix here.
Pierre.