Why is the approximation valid, in the formula provided by Brian Karis?

I'm sorry I'm bringing this topic up again, but I need to expound some of the topics.

With reference to this question, I was wondering if someone can help me out in expanding some of the details.

In the answer to that question we have:

However, since $L_i(l_k)$ is usually not a constant, this integral is not separable. Yet, in some cases (like when dealing with diffuse lighting or, more specifically, diffuse ambient lighting), the information that $f(l_k,v)$ carries is low-frequency enough that it can reasonably be approximated as a constant with respect to the distribution of $L_i(l_k)$. Experimentally, it can be shown that the final result is not too different from what you would expect.

I'm not sure I understand the specific bit "the information that $f(l_k,v)$ carries is low-frequency enough" and also the bit "with repsect to the distribution of $L_i(l_k)$".

I've been reading something about radiometry lately. The only clue I have is that since $f(l_k,v)$ is also function of the wavelength, which is inverse w.r.t. the frequency. Therefore low frequency means high wavelength, which in turn translates some specific assumption about the colour of both incoming and reflected light I guess. Experimental results are also mentioned and I'd like to find out those if they've been published.

Is my reasoning correct? If yes, I still have the feeling I'm missing something. If not what am I missing yet? Experimental results are also mentioned, can you point out any paper so I can read about those?

Thank you.

• Just a note: "low-frequency" here refers to angular frequency, ie how rapidly the function varies with input direction—nothing to do with the wavelength of light. – Nathan Reed Feb 6 '18 at 19:04

"the information that $f(l_k,v)$ carries is low-frequency enough": As IneQuation explains, low-frequency was used to refer to the detail of the brdf function. I did actually mean that $f_r$ was low frequency though (which is the case with diffuse lighting), not $L_i$.

"with respect to $L_i$": what this means it that, since there aren't any large peaks in $f_r$, no part of $L_i$ will be wheighted much more heavily than any other in the integral.

If each function was, say, reciprocal of the other (meaning in this case that the peaks in each one would cancel out when multiplied by the other) the correct integral would be very different to the separated integral where this cancelation does not occurr. but since the two functions are not correlated (or they shouldn't be) this difference is likely to be fairly small.

Also, if you use a really high frequency BRDF that takes into acount only incident light around the normal and you separate it, you will get something that's way off. in this example the estimate using separation is 4x larger that the correct result: https://www.desmos.com/calculator/c4zgypthrc

Experimental results can be generated easily. here is an example: https://www.desmos.com/calculator/poyswojjsa it shows a low frequency brdf $f_r$ and a high frequency incident light $L_i$ function being multiplied before and after integration. the ratio between the correct result and the one obtained using separation is of about 1.6

$$\frac{1}{N}\sum^{N}_{k=1}f(L_k) = \sum^{N}_{k=1}(f(L_k)\cdot \frac{1}{N})$$

Here we have "moved" or distributed $\frac{1}{N}$ into the sum. This formulation is equivalent but looks a bit more similar to an integral. if we set $\Delta L = \frac{1}{N}$ then, we can get

$$\sum^{N}_{k=1}f(L_k)\Delta L\approx \int_{L}f(L)dL$$

keeping in mind that the separation that occurs is, conceptually, separation of integrals, and that every integral "needs" its own $dL$. it follows that every montecarlo estimator needs its own $1/N$

I hope this helps you understand where the extra$\frac{1}{N}$ comes from

• I know I'm being annoying but I still have few unclear points... First $f_r$ is actually $f_r(l,v)$, the integral is computed over the hemisphere parametrized wrt $l$ (here $v$ is fixed). If $f_r(l,v)$ is low frequency (in signal processing terms) that means, I guess, that $$f_r(l,v) = \sum_{k=0}^{N-1} \alpha_k(v) \psi_k(l)$$, I'm assuming that $psi_k$ are spherical harmonics on the unit sphere. Is this interpretation correct? I know you said you don't know the derivation, but I'm trying to work out a bit of rigour for that formula. – user8469759 Feb 6 '18 at 17:18
• Also you mention "the two functions are not correlated", which functions? And why are you saying they're not correlated? – user8469759 Feb 6 '18 at 17:28
• The two functions are $f_r$ and $L_i$. I say they are not correlated because the brdf shouldn't depend on the environment – Sebastián Mestre Feb 6 '18 at 17:34
• I'd go as far as to say that this formula cannot be found if not by eye or by some sort of probabilistic analysis. And i don't have a strong enough grasp on probability to produce a proper derivation. Keep in mind that it is often said by CG professionals that "if it looks right, it is right" so rigorous proofs are not always needed. That is, unless you are doing scientific research – Sebastián Mestre Feb 6 '18 at 17:38
• Hi Again, just a last question. From the examples you gave me I have the feeling we are actually trying to split the integral and approximate those using montecarlo technique. The importance sampling is applied to the brdf one, while standard montecarlo integration seems to be applied for the $L_i$ term. Is this correct? – user8469759 Feb 7 '18 at 12:12

In computer graphics, one rarely uses the term "frequency" to refer to the inverse of wavelength of light. Usually, the meaning from signal theory is implied instead, i.e. the frequency of signal, or detail.

"Low-frequency information" in this case means that diffuse lighting is usually "blurry," i.e. it does not carry high-resolution detail, and is approximately the same, or has a smooth gradient, over relatively large regions of space.

To put it simply, "low frequency with respect to the distribution of $L_i(l_k)$" intuitively means "the incoming light signal has low detail".

• I still struggle to understand, the incoming light is $L_i$,. Isn't $f_r$ the one that has low frequency information? – user8469759 Feb 6 '18 at 15:47
• Moreover... according to what you're saying, low frequency $f_r$ means that $f_r$ is a narrow band signal, let's assume it is very narrow... that means that $f_r$ is almost a constant, therefore it can be factorized. However in the approximation what happens is that you factor $L_i$, and moreover an extra factor $\frac{1}{N}$ comes out, which I still struggle to understand where it comes from. – user8469759 Feb 6 '18 at 15:53