Invisible wrote:
> I can't decide which "if" the "else" belongs to. o_O
The else always belongs to the closest if at the same scope level...
Which means it's:
if (++depth>5) {if (erand48(Xi)<p) f=f*(1/p); else return obj.e;}
I think it's part of the Russian Roulette method (which is what the
comment R.R. stands for I suppose). I don't remember the details but you
can probably look it up by yourself...
--
Vincent
Post a reply to this message
|