madno2 opened this issue on Sep 26, 2009 · 82 posts
stewer posted Mon, 28 September 2009 at 4:23 PM
madno2,
after a couple of experiments, I think switching your lights from inverse square to inverse linear attenuation should make things look a lot better.
(Before I hear someone scream "but only inverse square is physically correct", I'd like to add that the inverse square law applies to infinitely small point lights - which don't exist in reality, and especially a lamp on a night stand typically has a large bulb and even larger shade - so neither of the two is 100% physically correct. Use what looks best.)
Long explanation following:
In fact, physics are the source of the problem here. Indirect light in P8 is calculated with irradiance caching, which relies on a more or less random sampling of the scene to estimate how much light gets bounced from one place to the other (Monte Carlo based method, very common for indirect light in many apps). Since a random sampling cannot find each and every singe light path, a very uneven incoming lighting (like a small and very bright spot) will result in an uneven outcome, because some of the random rays hit that small spot and many other will not. Smooth direct illumination on the other hand is much better at giving a smooth indirect light.
Now consider a point light with inverse square attenuation: the closer a surface gets to the light, the more light it receives, at exponential growth. In this case, the nightstand underneath the light has a very, very bright but small spot where it's close to the light. That small bright spot will get hit by some random rays but not all, resulting in the uneven illumination - which can only be cured by tracing a lot more rays and long render times. With an inverse linear light, surfaces also become brighter as they get closer, but not at the same exponential growth - therefore, there area near the light has much smoother illumination and it is much easier for indirect light calculations to estimate its contribution with few random rays.