POV-Ray : Newsgroups : povray.binaries.images : A quick povr branch micro normal image. : Re: A quick povr branch micro normal image. Server Time
30 Apr 2024 01:18:36 EDT (-0400)
  Re: A quick povr branch micro normal image.  
From: William F Pokorny
Date: 7 Mar 2022 07:42:58
Message: <6225fdd2$1@news.povray.org>
On 3/6/22 08:35, jr wrote:
> if you ever recall why, please tell.  now that I know about it, I do wonder what
> the rationale/potential benefit is when the chunk is not written.

OK. Found my related debugging newsgroup post.

Much more detail on the v3.8/v4.0 sRGB block issue being written nor not 
can be found in a Mar 20, 2021 post to povray.beta-test. "File png/ppm 
gamma issues. v3.8." See:

http://news.povray.org/povray.beta-test/thread/%3C60563168%241%40news.povray.org%3E/

or

Message: <60563168$1@news.povray.org>

The thread started after questions from ingo related to pgm/ppm file 
output. I stumbled across the png sRGB block issue during that work. 
Look for "---  png gamma issue.' for the parts of the original post 
related to png input/output.

The bug amounts to POV-Ray not being consistent with 'itself' with 
respect to png sRGB handling.

Looks like in reading the thread again I never did the detailed work to 
figure out what all changed to cause the sRGB block to be dropped on 
default writes though 'srgb' is our default output/input png gamma 
handling profile.

I'd spent many days understanding what was happening in detail and 
didn't want to spend hours to days more trying to run down the commit(s) 
where the post v3.7 srgb png output file gamma handling broke. I just 
fixed the issue - which explains why I couldn't remember the detailed 
causes(a)!

(a) This time it might not have been my old failing brain! Of course, I 
didn't remember I hadn't dug enough to determine exactly how we got into 
the buggy state... ;-)

I know clipka worked quite a bit on the image file handling code over 
years while working toward v3.71/v3.8(v4.0). It was likely broken 
sometime during those changes.

Aside: Because broken v3.71/v3.8/v4.0 versions do still write a gamma 
2.2 chunk, the differences visually be will be small / hard to 'see' - 
they're at the dark end. This probably why the bug went years not 
getting picked up. It's one of those insidious subtle bugs that cause 
confusing / hair pulling results when they do bite.

Bill P.


Post a reply to this message

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