View Full Version : fresnel reflection terms in pbrt

05 May 2007, 05:43 AM
Hi guys !

I am struggling with some of the math in the book "Physically based rendering" and hoped that somebody here could be able to help.

My first problem is the dirac delta function (page 427, 9.2.2 "perfect specular reflection"). As far as I understood, evaluating it at x=0 gives 1 and it gives 0 at x<> 0. Is it used because we want to limit angles to the special case of perfect reflection ? So that only a reflectance of 1 is returned for rays coming from the exact reflection angle, otherwise 0 ?

And my other and also bigger problem is the first equation on the next page (p. 428) which shows that we have to divide the reflectance R and the Fresnel reflection value F_r by |cos theta_i| . I was wondering... I can follow his derivation of the equation but is there any intuitive meaning for the inverse cosine term ? I do not understand why we would need it except for its mathematical necessity.

As far as I remember, the cosine was introduced to the scattering equation to compensate for the larger "area" being lit by incident rays at larger angles (measured between normal and ray). Dividing by this cosine means that we get greater values at larger angles. But if fresnel->evaluate() returns 1.0 for the case of a total reflection and we divide by 0.3, for example, isn't there a reflection value greater than 1 and would therefore break energy conservation laws ?

I have not tested the code yet. Maybe it would be a good idea to trace some variables, before asking stupid questions. :scream: But anyways, I would be really happy if someone could explain. For those who do not have the book but are willing to help, the code for this is located in reflection.h / reflection.cpp :) in pbrt's open source code. Thanks alot !

CGTalk Moderation
05 May 2007, 05:44 AM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.