POV-Ray : Newsgroups : povray.text.tutorials : Highlight Voodo Server Time: 19 Jan 2019 05:06:49 GMT
  Highlight Voodo (Message 1 to 10 of 10)  
From: clipka
Subject: Highlight Voodo
Date: 22 Nov 2011 18:46:02
Message: <4ecbedea@news.povray.org>
Fun fact to know:

The realistic range for the "specular" and "phong" parameters is /not/ 
limited to 0..1.

Instead, for a polished material, a value of

     specular 0.25 * ((1/ROUGHNESS)+1) * REFLECTION

or

     phong 0.5 * (PHONG_SIZE + 1) * REFLECTION

is actually realistic, e.g.

     finish {
       reflection { 0.2 }
       specular 50.05
       roughness 0.001
     }

or

     finish {
       reflection { 0.2 }
       phong 100.1
       phong_size 1000
     }


BTW there's also a similar law goverining the "diffuse" parameter: If 
you set "brilliance" to anything but 1, you should set "diffuse" to a 
maximum of

     diffuse 0.5 * (BRILLIANCE + 1)

which would correspond to a diffuse reflection of 100%.


Post a reply to this message

From: Warp
Subject: Re: Highlight Voodo
Date: 22 Nov 2011 19:18:16
Message: <4ecbf577@news.povray.org>
clipka <ano### [at] anonymousorg> wrote:
> The realistic range for the "specular" and "phong" parameters is /not/ 
> limited to 0..1.

  Using a very strong specular/phong highlight, but making the highlight
small, is a good trick to make a surface look like highly polished, such
as glass (which usually has very sharp highlights rather than smooth ones).

-- 
                                                          - Warp


Post a reply to this message

From: waggy
Subject: Re: Highlight Voodo
Date: 23 Nov 2011 14:50:01
Message: <web.4ecd074f8dbbb1aa9726a3c10@news.povray.org>
Thank you very much.  Are these "Clipka's Laws", or is there another term for
these relations?


Post a reply to this message

From: Cousin Ricky
Subject: Re: Highlight Voodo
Date: 4 Jul 2012 21:30:01
Message: <web.4ff4b52d8dbbb1aa85de7b680@news.povray.org>
clipka <ano### [at] anonymousorg> wrote:
> Instead, for a polished material, a value of
>
>      specular 0.25 * ((1/ROUGHNESS)+1) * REFLECTION
>
> or
>
>      phong 0.5 * (PHONG_SIZE + 1) * REFLECTION
>
> is actually realistic, [...]

How is this relationship affected if the material isn't "polished"?

How is this affected by variable or fresnel reflection?

Is there any relationship between reflection and roughness/phong_size?

> BTW there's also a similar law goverining the "diffuse" parameter: If
> you set "brilliance" to anything but 1, you should set "diffuse" to a
> maximum of
>
>      diffuse 0.5 * (BRILLIANCE + 1)
>
> which would correspond to a diffuse reflection of 100%.

Does this mean that you can set diffuse > 1 if brilliance is > 1?

In metals.inc and golds.inc, brilliance is increased as reflection is increased.
 Is there such a correlation in reality, or was that just the way it was decided
to define the textures?


Post a reply to this message

From: clipka
Subject: Re: Highlight Voodo
Date: 4 Jul 2012 23:24:17
Message: <4ff4d0a1$1@news.povray.org>
Am 04.07.2012 23:27, schrieb Cousin Ricky:
> clipka<ano### [at] anonymousorg>  wrote:
>> Instead, for a polished material, a value of
>>
>>       specular 0.25 * ((1/ROUGHNESS)+1) * REFLECTION
>>
>> or
>>
>>       phong 0.5 * (PHONG_SIZE + 1) * REFLECTION
>>
>> is actually realistic, [...]
>
> How is this relationship affected if the material isn't "polished"?

Mu. POV-Ray's reflection is only realistic for polished surfaces.

> How is this affected by variable or fresnel reflection?

Phong and specular currently don't respect fresnel's law, so when using 
fresnel reflection you should reduce the specular or phong parameter a 
bit to compensate; it's not the real thing though.

> Is there any relationship between reflection and roughness/phong_size?

If we're talking about polished surfaces: Yes, obviously there is a 
relationship - it's in the formulae given above.

If we're talking about dull surfaces, then mu - as stated above, POV-Ray 
does not natively support dull (aka blurred) reflections.

>> BTW there's also a similar law goverining the "diffuse" parameter: If
>> you set "brilliance" to anything but 1, you should set "diffuse" to a
>> maximum of
>>
>>       diffuse 0.5 * (BRILLIANCE + 1)
>>
>> which would correspond to a diffuse reflection of 100%.
>
> Does this mean that you can set diffuse>  1 if brilliance is>  1?

Well, you /can/ do that regardless of brilliance, except that it would 
be unrealistic at brilliance = 1; but for a material with brilliance 2, 
diffuse 1.2 isn't unrealistic.

> In metals.inc and golds.inc, brilliance is increased as reflection is increased.
>   Is there such a correlation in reality, or was that just the way it was decided
> to define the textures?

That's just the way they did it. There's not much parameterization in 
metals.inc or golds.inc that has any correlation to reality whatsoever - 
the material parameters were chosen solely for artistic reasons.


BTW, by now POV-Ray has acquired some new syntax to automatically do the 
above computations for you: Specifying

     specular albedo SPECULAR_ALBEDO
     roughness ROUGHNESS

     phong albedo PHONG_ALBEDO
     phong_size PHONG_SIZE

     diffuse albedo DIFFUSE_ALBEDO
     brilliance BRILLIANCE

is equivalent to:

     specular 0.25 * ((1/ROUGHNESS)+1) * SPECULAR_ALBEDO
     roughness ROUGHNESS

     phong 0.5 * (PHONG_SIZE + 1) * PHONG_ALBEDO
     phong_size PHONG_SIZE

     diffuse 0.5 * (BRILLIANCE + 1) * DIFFUSE_ALBEDO
     brilliance BRILLIANCE

Specular and phong albedo should be equal to reflection (for polished 
materials), while the sum of reflection and diffuse albedo should be 1 
or lower.

(Fresnel (or variable) reflection equivalent is still not supported for 
highlights though, and significantly dull reflection is still not 
available out of the box.)


Post a reply to this message

From: Cousin Ricky
Subject: Re: Highlight Voodo
Date: 6 Jul 2012 00:25:00
Message: <web.4ff62fd68dbbb1aa85de7b680@news.povray.org>
clipka <ano### [at] anonymousorg> wrote:
> Am 04.07.2012 23:27, schrieb Cousin Ricky:
> > How is this relationship affected if the material isn't "polished"?
>
> Mu. POV-Ray's reflection is only realistic for polished surfaces.

What is mu?

> > Is there any relationship between reflection and roughness/phong_size?
>
> If we're talking about polished surfaces: Yes, obviously there is a
> relationship - it's in the formulae given above.

What I'm asking is for a given reflection value, can we predict what the
roughness value will be?

> If we're talking about dull surfaces, then mu - as stated above, POV-Ray
> does not natively support dull (aka blurred) reflections.

This is probably not a good idea (yet?) anyway.  Best to let the users weigh the
various methods and tradeoffs.


Post a reply to this message

From: clipka
Subject: Re: Highlight Voodo
Date: 6 Jul 2012 10:33:43
Message: <4ff6bf07$1@news.povray.org>
Am 06.07.2012 02:22, schrieb Cousin Ricky:
> clipka<ano### [at] anonymousorg>  wrote:
>> Am 04.07.2012 23:27, schrieb Cousin Ricky:
>>> How is this relationship affected if the material isn't "polished"?
>>
>> Mu. POV-Ray's reflection is only realistic for polished surfaces.
>
> What is mu?

A concept from (AFAIK) Zen Buddhism: A reply given to questions for 
which there is no meaningful answer.

>>> Is there any relationship between reflection and roughness/phong_size?
>>
>> If we're talking about polished surfaces: Yes, obviously there is a
>> relationship - it's in the formulae given above.
>
> What I'm asking is for a given reflection value, can we predict what the
> roughness value will be?

No; the reflection value describes how /much/ of the incoming light is 
reflected (for light coming from other objects); the roughness value 
describes how /focused/ the reflection of incoming light will be (from 
light sources).

>> If we're talking about dull surfaces, then mu - as stated above, POV-Ray
>> does not natively support dull (aka blurred) reflections.
>
> This is probably not a good idea (yet?) anyway.  Best to let the users weigh the
> various methods and tradeoffs.

Well, I personally think blurred reflections are a /great/ thing to 
have. They can really make or (in case of their absence) break a scene 
(especially if they're in tune with the highlights parameters).


Post a reply to this message

From: Cousin Ricky
Subject: Re: Highlight Voodo
Date: 6 Jul 2012 14:50:00
Message: <web.4ff6fa8c8dbbb1aa85de7b680@news.povray.org>
clipka <ano### [at] anonymousorg> wrote:
> Am 06.07.2012 02:22, schrieb Cousin Ricky:
> > clipka<ano### [at] anonymousorg>  wrote:
> >> If we're talking about dull surfaces, then mu - as stated above, POV-Ray
> >> does not natively support dull (aka blurred) reflections.
> >
> > This is probably not a good idea (yet?) anyway.  Best to let the users weigh the
> > various methods and tradeoffs.
>
> Well, I personally think blurred reflections are a /great/ thing to
> have. They can really make or (in case of their absence) break a scene
> (especially if they're in tune with the highlights parameters).

I agree; I just don't know that we've agreed upon the best way to implement it.


Post a reply to this message

From: clipka
Subject: Re: Highlight Voodo
Date: 6 Jul 2012 17:34:53
Message: <4ff721bd$1@news.povray.org>
Am 06.07.2012 16:47, schrieb Cousin Ricky:
> clipka<ano### [at] anonymousorg>  wrote:
>> Am 06.07.2012 02:22, schrieb Cousin Ricky:
>>> clipka<ano### [at] anonymousorg>   wrote:
>>>> If we're talking about dull surfaces, then mu - as stated above, POV-Ray
>>>> does not natively support dull (aka blurred) reflections.
>>>
>>> This is probably not a good idea (yet?) anyway.  Best to let the users weigh the
>>> various methods and tradeoffs.
>>
>> Well, I personally think blurred reflections are a /great/ thing to
>> have. They can really make or (in case of their absence) break a scene
>> (especially if they're in tune with the highlights parameters).
>
> I agree; I just don't know that we've agreed upon the best way to implement it.

It seems plain as hell to me that the only reasonable way to implement 
it is some kind of oversampling with jitter added to the reflected ray.

And it seems also plain as hell to me that the only reasonable way to 
handle the resulting heavy blow on render performance is to integrate 
all oversampling-based mechanisms into one bigger picture, encompassing 
anti-aliasing, focal blur, media, fog, area lights, subsurface light 
transport, and blurred reflections/refractions. As it is now, all of 
these features do their own full-blown oversampling, thus having a fully 
multiplicative effect on render time each, even though oversampling 
could be much more "lazy" whenever additional oversampling is performed 
somewhere "closer" to the camera anyway.

That, in my opinion, is the only reasonable way to implement it.

As for syntax, parameterization should obviously make it easy to 
properly "synchronize" reflection and highlight parameters, ideally in 
such a way that the very same values used in both the reflection 
"blurriness parameter" and specular roughness produces the most 
realistic match (not the phong_size BTW, as specular highlights are the 
better choice when it comes to realism); adding fresnel support for 
highlights would be highly desirable as well.

Some additional parameters might be added to control the oversampling, 
though I think they can just as well be deduced from the blurriness and 
strength of reflection.


All in all, aside from the choice of keywords and other syntax details, 
I think that after giving it thorough thought, there are no notable 
things to disagree about.


(Speaking of Syntax, copying the MCPov one for the sake of scene 
portability is definitely a no-go; not only is it far away from all 
traditional POV-Ray syntax patterns - it also uses a totally 
intransparent "blurriness" parameterization, and the oversampling 
parameterization is rather poor as well.)


Post a reply to this message

From: Le Forgeron
Subject: Re: Highlight Voodo
Date: 9 Jul 2012 06:41:34
Message: <4ffa7d1e$1@news.povray.org>
Le 06/07/2012 19:34, clipka a écrit :
> Am 06.07.2012 16:47, schrieb Cousin Ricky:
>> clipka<ano### [at] anonymousorg>  wrote:
>>> Am 06.07.2012 02:22, schrieb Cousin Ricky:
>>>> clipka<ano### [at] anonymousorg>   wrote:
>>>>> If we're talking about dull surfaces, then mu - as stated above,
>>>>> POV-Ray
>>>>> does not natively support dull (aka blurred) reflections.

A bit late, but have a look at "crand".
It's not a blurred reflection, but the noise added to the usual
reflection is often enough to move away from the perfectly smooth surface.


Crand has not been re-implemented in povray 3.7RC6, but the next RC
should have it.
(so, look at it in 3.6 in the meantime)

-- 
Real software engineers work from 9 to 5, because that is
the way the job is described in the formal spec.  Working
late would feel like using an undocumented external procedure.


Post a reply to this message

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