Page 1 of 1
ResizeImage() - No gamma error
Posted: Sat Aug 13, 2011 10:34 pm
by c4s
Would it be possible to tune the ResizeImage() function so that the gamma error is reduced/fixed? Maybe you could add a new flag if the calculations are too intensive.
Here is a website with extensive information about it:
http://www.4p8.com/eric.brasseur/gamma.html
The test suggested on that site tells me that ResizeImage() works
incorrectly.
Re: ResizeImage() - No gamma error
Posted: Sat Aug 13, 2011 11:51 pm
by luis
Fascinating. Great reading. This explain some things I always thought were "normal" defects.
Thanks!
Re: ResizeImage() - No gamma error
Posted: Sun Aug 14, 2011 3:11 am
by kenmo
Interesting article, but I don't agree with his labeling of resizing algorithms as "correct" or "incorrect".
The common resize algorithms (raw, bilinear, bicubic, Lanczos, etc.) are standard, and they all have advantages and disadvantages. The minor changes in gamma is negligible in 99% of cases... unless you are writing advanced photograph software, or you are dealing with strange specific cases like his "tuned" Dalai Lama picture or the RULES/SUCKS image at the end.
But in those cases, you might as well be writing and fine-tuning your own resize procedures, rather than using PB's general purpose one.
HOWEVER, I would love to see more resize options added to PureBasic. I think the only current interpolation is bilinear?
Bicubic, sinc, whatever-this-gamma-correcting-one-is-called would all be nice, just not a high priority.
Re: ResizeImage() - No gamma error
Posted: Tue May 13, 2014 9:07 pm
by NicTheQuick
+1