POV-Ray : Newsgroups : povray.bugreports : Strong pigment gradients, SSLT and AA : Re: Strong pigment gradients, SSLT and AA Server Time
24 Apr 2024 12:09:56 EDT (-0400)
  Re: Strong pigment gradients, SSLT and AA  
From: FlyerX
Date: 29 Nov 2013 18:10:10
Message: <52991ed2$1@news.povray.org>
On 11/29/2013 4:04 PM, clipka wrote:
> Am 29.11.2013 22:12, schrieb FlyerX:
>> On 11/29/2013 10:08 AM, clipka wrote:
>>> Am 29.11.2013 12:42, schrieb FlyerX:
>>>
>>>> With SSLT (marble):
>>>> http://imgur.com/MoGWfDq
>>>> The edges between the colors are strongly aliased. Almost looks as
>>>> if AA
>>>> is switched off but the edge of the sphere shows that AA is active.
>>>
>>> Try to avoid zero color components; for instance, you could use an
>>> "average" pigment with a small bit of white mixed in. Something like
>>> 0.001 shoud already be sufficient.
>>>
>>> What happens is that currently the SSLT code cannot yet cope with zero
>>> color components, belches out a "Not a Number" (NaN) value for that
>>> particular color channel, and the AA step is unable to handle that,
>>> computing the average of NaN and any other valid number as NaN. The
>>> image encoding algorithm then happens to encode the NaN as 0.
>>>
>> Clipka,
>>
>> Thank you very much for the tip. No wonder the red area in the render
>> was completely noisy.
>>
>> I added the following to the material:
>>
>> #declare pave=pigment{average pigment_map{
>>      [1 p_map1]
>>      [1 color rgb 0.001]
>>    }
>>    }
>
> I would instead suggest
>
>    #declare pave=pigment{average pigment_map{
>       [1 p_map1]
>       [0.001 color rgb 1]
>     }}
>
> as this leaves the resulting color almost unchanged, whereas your
> solution gives any non-black color a significant blackshift.
>
That makes sense. I noticed the darkening but I though I would have to 
live with that. Now I just see that I was averaging black with the 
original. Using the weight makes the render look as expected.

Thanks again,

FlyerX


Post a reply to this message

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