POV-Ray : Newsgroups : povray.beta-test : Struggling with gamma... : Re: Struggling with gamma... Server Time
2 Jul 2024 10:25:18 EDT (-0400)
  Re: Struggling with gamma...  
From: clipka
Date: 26 Jun 2010 15:56:36
Message: <4c265b74$1@news.povray.org>
Am 26.06.2010 17:30, schrieb Gyscos:
> When I don't specify any gamma settings, I get a bright image. POV-Ray preview
> window shows it bright, window explorer show it bright, gimp and firefox too. So
> I guess the file is easy to read and everyone get it right.

Yup. That's how it should be. If you leave it at that, you should 
normally be happy - as soon as you get used to the fact that 50% linear 
brightness isn't percieved by the human eye as medium grey.

> Now, I put the two gamma options I said earlier : File_Gamma=1 and
> Display_Gamma=1.
> POV-Ray preview show a darker image, like one I would get with #version 3.6;
> Windows explorer and the Gimp also show the darker image.
> Firefox shows a bright image.
>
> This makes think firefox is the one to do it the wrong way... Am I wrong ?

Yes, you are:

- Display_Gamma=1 causes the preview window to lie to you about what 
POV-Ray computes.

- PNG file output /always/ gives you a PNG file containing exactly what 
POV-Ray computes, regardless of File_Gamma, because although the 
parameter affects how the binary values in the file are to be 
interpreted in terms of physical light intensities, the file header 
stores this information in an unambiguous manner.

- Any viewer displaying the PNG file properly must therefore display it 
differently than the lie you see in the preview window.


> Also, I still don't understand when and why identical values to File_Gamma and
> Display_Gamma could lead to differences between the POV-Ray preview and the
> resulting file...

This happens with each and every file format that has clearly defined 
rules how the stored binary values relate to physical light intensities: 
HDR, OpenEXR (both of which always store straightforward linear light 
intensities) and PNG (which stores exact information about how the 
linear light intensities were mapped to binary values, and therefore how 
to reconstruct the linear light intensities from the binary values).


Post a reply to this message

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