bagginsbill opened this issue on Jan 15, 2010 · 271 posts
bagginsbill posted Tue, 02 February 2010 at 8:37 AM
Quote - One more thing for possible discussion. I notice that the main and rim lights in the tutorial scene have fall-off set to inverse linear, rather than inverse square. I have not yet found any mention of this in the thread. Was this simply the default, or intended that way?
And how is the light fall-off from the light box treated? I'm going away to find out....
It probably doesn't make much difference in an empty environment with a single centre-positioned subject, but with surrounding or backdrop geometry it surely would.
Correction: I suppose it would also affect the bounced light from the left hand wall.
I intended it. To fully understand light falloff would require that we discuss some serious calculus involving double integration. Do we want to or no?
The inverse square rule is 100% accurate only for point light sources - having no measurable dimension in any of the 3 spatial dimensions.
The inverse linear rule is 100% accurate only for infinite straight line light sources - an infinite tube with a diameter of 0, thus having only 1 dimension.
To truly describe the luminous intensity field created by a glowing object, we have to fully take into account the position and orientation of that object, its actual shape and size, and the actual position and orientation of the surface receiving the illumination. The correct luminance is never inverse linear nor inverse square, nor any given constant power.
Short of going back to something like my ISF light shader, however, we have only two choices - inverse linear or inverse square.
Which is more correct?
Inverse linear says luminance is proportional to (1/d)^1, and inverse square says it is proportional to (1/d)^2. Generalizing, we can say that light falls off roughly as (1/d)^p, where p is some power. For most shapes and distances, the power, p, is actually between 1 and 2.
In general, (and this is a gross oversimplification), if we're talking about some sort of finite object as a light source, the value of p is above 1.8 when the distance to the light source is at least 5 times the diameter of that light source. And regardless of shape, p is 1.95 or higher when the distance is 20 times the diameter of the light source.
But what happens when we're closer than that? What if the light source is a 6-foot umbrella and the subject is about 6 feet away? What is the falloff then?
The answer is very complicated. To the best of my knowledge, caclulating the exact answer is very difficult and/or impossible in terms of a closed-form mathematical equation, even for a flat, square sheet of light. (At least, Wolfram Alpha says there is no closed-form answer with traditional math functions.) For something that isn't flat, like an umbrella, it is even more complicated, because there is a focusing effect.
Focusing is very important, because it prevents the uniform spreading of light on an expanding sphere. In the neighborhood of the light source, it is possible to see little falloff at all within a rather large area of bounded space. In the case of an infinite sheet light source, there is no falloff anywhere - the illuminance is a constant throughout the entire universe.
So we must resort to numerical methods (approximations) for bounded 3D objects like umbrellas. I did a calculation using a parabolic square, where the depth in the center is 1/2 the diameter.
Then, for any point along the central axis defined by this virtual umbrella, I calculated the rate of light falloff as a function of distance from umbrella, from the reference point of the center of the square assuming it had no depth. (Imagine an umbrella with a shaft passing through glass, with the perimeter touching the glass. The point where the shaft passes through the glass is my reference point for distance.)
Here are the falloff results showing distance (as a multiple of diameter) and the falloff power.
.01 => .03
.05 => .13
.1 => .24
.2 => .46
.3 => .64
.4 => .79
.5 => .91
.6 => 1.01
.7 => 1.02
.8 => 1.18
.9 => 1.24
1.0 => 1.3
1.2 => 1.4
1.5 => 1.49
1.75 => 1.56
2 => 1.61
3 => 1.73
5 => 1.84
10 => 1.92
20 => 1.96
Notice the early values, where the distance is a small fraction of the light source diameter. The falloff approaches 0. That is because at such a distance, the umbrella is much closer to behaving like an infinite sheet than anything else. An infinite sheet has no falloff - the value of p = 0 in that case.
So what does this mean? Suppose you have a 6-foot umbrella and you measure falloff at a distance of 9 feet. That is 1.5 times the diameter, so look above for 1.5 and we see the falloff power is 1.49. This is halfway between inverse linear and inverse square. At this distance, neither setting is more correct.
However, remember that I'm mixing a glowing rectangle with the spot light. The glowing rectangle is going to push the results away from what we get from the spot light alone. And I found that given the choice beween p=1 and p=2, p=1 produced better results in that mixture.
So, in general, for a distance somewhere between .4 diameters and 2 diameters, inverse linear is a better approximation on the spotlight that is trying to behave like an area light. For a 6-foot umbrella, that would be 2.4 to 12 feet. This is the range I was shooting for in soft studio lighting.
Renderosity forum reply notifications are wonky. If I read a follow-up in a thread, but I don't myself reply, then notifications no longer happen AT ALL on that thread. So if I seem to be ignoring a question, that's why. (Updated September 23, 2019)