Gamma correct resizing (english, français)

Ideas for improvements and requests for new features in XnView Classic

Moderators: XnTriq, helmut, xnview

Leonidas
Posts: 7
Joined: Fri Jan 28, 2011 9:35 pm

Gamma correct resizing (english, français)

Post by Leonidas »

Hi / Bonjour,

today I checked again the site of Eric Brasseur (he seems to add examples ... some are really convincing now) concerning the gamma error in resizing methods. Tested myself with latest XnView/XnViewMP some of the pictures (again) and noticed that the problem still exists: resizing in XnView is off concerning the gamma (all methods).

The only way around in XnView seems to be the inverse gamma-method Eric suggests, with assumption of gamma 2.2 (convert to 16 bit/channel, set to gamma 0.4545, resize, set to gamma 2.2), but that does not work very well.

I found already two articles here adressing the problem: but nobody seems to have added it yet to the suggestions list.

--- (and now in bad french) ---

Aujourd'hui j'ai lu encore une fois le site du web de Eric Brasseur (il ajoute des exemples ... quelques sont tres convaicant) où il a écrit sur le erreur du gamma des algorithmes de la réduction de la taille des images. J'ai essayé avec le dernier XnView/XnViewMP (de noveau) et j'ai noté que le problème encore existe: réduction des images avec XnView a des erreurs gamma dans les resultats (tous méthodes).

Il n'y a que le "inverse gamma méthode" de Eric (convertir à 16 bit/c, mise gamma à 0.4545, reduire la taille, mise gamma à 2.2), mais ça ne marche pas trop bien.

J'ai déjà trouvé deux articles ici: mais jusqu'à ce jour personne à ajouté le problème à la liste des suggestions.
User avatar
DOS386
Posts: 291
Joined: Sun Jun 11, 2006 2:43 pm

Re: Gamma correct resizing (english, français)

Post by DOS386 »

Leonidas wrote:he seems to add examples ... some are really convincing now
I can't find any new examples, but the old ones are very sufficient (PNG is preferred, JPG is lossy, while AGIF is palettized). Still the page is being updated and bug-fixed as necessary.
The only way around in XnView seems to be the inverse gamma-method Eric suggests
NO :-(
with assumption of gamma 2.2 (convert to 16 bit/channel, set to gamma 0.4545, resize, set to gamma 2.2), but that does not work very well.
Why?

1. There is no "convert to 16 bit/channel" in NC/XN http://newsgroup.xnview.com/viewtopic.php?t=20095 . Doing the gamma hack with 8 bppc only is a very bad idea (Eric describes why, it's less bad to keep the gamma error than commit the truncation error).

2. "set to gamma 0.4545" and "set to gamma 2.2" is a good approximation, but not the optimal sRGB function.
There is indeed no WinZIP under my rock.
Leonidas
Posts: 7
Joined: Fri Jan 28, 2011 9:35 pm

Re: Gamma correct resizing (english, français)

Post by Leonidas »

Actually, you are right. Some of the 24bpp-32bpp-24bpp converted versions looked horrible enough to convince me, that this is not 16bit/channel :)