POV-Ray : Newsgroups : povray.general : Re: PNG output much brighter than preview... : Re: PNG output much brighter than preview... Server Time
31 Jul 2024 14:30:01 EDT (-0400)
  Re: PNG output much brighter than preview...  
From: Warp
Date: 16 Jan 2007 03:32:09
Message: <45ac8d89@news.povray.org>
Daniel Nilsson <pov### [at] daniel-nilssoncom> wrote:
> Fact remains that if all programs followed the standard's rules 
> regarding gamma (unwise or not), any given png-image would look the same 
> regardless of the target system.

  But the problem remains that if all programs followed that "guess a
gamma for a gammaless png" rule, pngs would become completely unusable
in web pages where matching some png color with a css (or whatever other)
color is necessary. The same is probably true for other similar
applications (although perhaps with less impact, given that web pages
are the single most widely viewed things in completely different
architectures).

  I think that an image telling "I want you to use this gamma correction
with me" is the wrong approach. It causes all kinds of problems with
things which do not have that kind of gamma information.

  I think that the gamma problem has been approached from the wrong end.
They try to solve gamma problems by wanting the *images* to have some
gamma correctio info.

  IMO the problem should be solved in the exact opposite way: All pixel
information should be universally the same (ie. for example a value of
128 (in a 8 bits per channel image) means exactly half the brightness,
not more, not less) and the OSes then correct it so that it will look
like that in the target monitor. If the image wants an exactly-half-bright
gray color, then it specifies 128,128,128 for that pixel and the OS then
makes sure when showing that image that it will look half-bright on the
monitor by whatever corrections are necessary to achieve that.

  Currently this problem has been solved in the completely wrong and
retarded way. If in one system "exactly half brightness" means 135,135,135
then the image will be created with that pixel value and a gamma correction
information is put in the file which in practice says "when you find the
value 135 it actually means 'exactly half brightness'". Now if in another
system 'exactly half brightness' means 120,120,120 then it has to convert
the 135s to 120s before showing them. This, of course, causes all kinds
of problems. Some programs will do that, others won't. Some programs
will not even know what is the proper correction to be applied (ie.
they don't know which value 'exactly half brightness' is in that
specific system).

  As I said, IMO "exactly half brightness" (with a 8bpp image) should
mean 128. No more, no less. The target OS can then do whatever
modifications it wants so that it will also *look* exactly half as
bright as the full brightness.

  This way if you specify 128,128,128 as a webpage background color
and you have 128,128,128 used in a png, they will always match. They
will both be corrected in the same way by the OS.

  Currently, with the reversed (and retarded) logic, this is just not
possible.

-- 
                                                          - Warp


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.