ompf2.com Ray Tracing Discussion and Knowledge Archive 2019-05-16T02:36:46 http://ompf2.com/app.php/feed 2019-05-16T02:36:46 2019-05-16T02:36:46 http://ompf2.com/viewtopic.php?t=25&p=5951#p5951 <![CDATA[Visuals • Re: Glitch Pictures anyone?]]> Statistics: Posted by olliej — Thu May 16, 2019 2:36 am

]]>
2019-05-03T03:45:17 2019-05-03T03:45:17 http://ompf2.com/viewtopic.php?t=2126&p=5950#p5950 <![CDATA[Visuals • Re: My first Supersize-Image]]> Statistics: Posted by XMAMan — Fri May 03, 2019 3:45 am

]]>
2019-04-27T22:40:14 2019-04-27T22:40:14 http://ompf2.com/viewtopic.php?t=2166&p=5949#p5949 <![CDATA[General Development • Re: Point lights and non-diffuse brdfs]]> vchizhov. My understanding is that the delta function is an ad-hoc construct, often defined as

$$\int_{-\infty}^\infty f(x) \delta(x - x_0) \, dx = f(x_0)$$

Note that the above is not a valid Lebesgue integral. A more rigorous, Lebesgue-compatible definition is as a measure:

$$\int_{-\infty}^\infty f(x) \, \mathrm{d} \delta_{x_0}(x) = f(x_0)$$

The whole point of this exercise is, in my understanding, for notational convenience: to write a specific discrete value $$f(x_0)$$ as integral in order to avoid special-casing when you're working in an integral framework.

So if you really don't want to deal with delta functions/measures, you can explicitly special-case. For the rendering equation, this means avoiding the reflectance integral altogether and evaluating the integrand at the chosen location. So in effect you are defining the outgoing radiance at the shading point rather than defining some infinitesimally small light source. To also account for the contribution of other light sources, you'll need to sum that just-defined radiance with a proper reflectance integral. You'd do the same for plastic-like BRDFs that are the sum of perfect specular lobe and a smooth lobe. This seems like a more mathematically correct approach to me. It's more cumbersome though, that's why people prefer the more convenient (and controversial) approach of just thinking of it as defining a point light source instead.

Honestly, I like this discussion and I'd like to have a bullet-proof definition of everything that doesn't involve ad-hoc constructs. I myself try to avoid the use of delta stuff whenever I can. Volumetric null scattering is one example where I don't like the introduction of a forward-scattering delta phase function – there's a cleaner way to do it.

Statistics: Posted by ingenious — Sat Apr 27, 2019 10:40 pm

]]>
2019-04-26T22:18:10 2019-04-26T22:18:10 http://ompf2.com/viewtopic.php?t=2166&p=5948#p5948 <![CDATA[General Development • Re: Point lights and non-diffuse brdfs]]> Statistics: Posted by vchizhov — Fri Apr 26, 2019 10:18 pm

]]>
2019-04-26T21:34:58 2019-04-26T21:34:58 http://ompf2.com/viewtopic.php?t=2166&p=5947#p5947 <![CDATA[General Development • Re: Point lights and non-diffuse brdfs]]>
The issue is that I am not convinced that it is well-defined, hence why I want to see a formal proof (be it through measure theory, differential geometry, or even starting with Maxwell's equations). For one thing the brdf is defined in terms of radiance, not in terms of intensity. And if it is indeed well-defined I want to understand the details why it so, and not just rely on hand-waving arguments. As in, have a similar proof to what I did above for the diffuse case, obviously the thing I derived above does not apply to a brdf that actually depends on $\omega_i$ however.
"You didn't use real wrestling. If you use real wrestling, it's impossible to get out of that hold."
- Bobby Hill

If your concern is with undefined quantities, you might need to start by defining exactly you mean by a point light, since it's already a physically implausible entity. E.g., is it meaningful to have the dw or dA terms from your Lambertian derivation? Does it have a normal? Is it a singular point, or is it the limit of an arbitrarily small sphere? If it were me, I'd just start with a definition that is consistent with a delta distribution, because it's consistent with what I want to represent, I know it makes the math work, and I can actually start implementing something.

Beyond that, I'm not sure there's anything else I can say that will convince you without a lot more work than I have time for. Best of luck.

Statistics: Posted by friedlinguini — Fri Apr 26, 2019 9:34 pm

]]>
2019-04-26T19:27:08 2019-04-26T19:27:08 http://ompf2.com/viewtopic.php?t=2166&p=5946#p5946 <![CDATA[General Development • Re: Point lights and non-diffuse brdfs]]> $$\frac{\cos\theta}{r^2}dA = d\omega$$.
It doesn't try to evaluate the incoming radiance directly, but instead evaluates the integral over incoming radiance, which is well-defined even with deltas.
The issue is that I am not convinced that it is well-defined, hence why I want to see a formal proof (be it through measure theory, differential geometry, or even starting with Maxwell's equations). For one thing the brdf is defined in terms of radiance, not in terms of intensity. And if it is indeed well-defined I want to understand the details why it so, and not just rely on hand-waving arguments. As in, have a similar proof to what I did above for the diffuse case, obviously the thing I derived above does not apply to a brdf that actually depends on $\omega_i$ however.

Statistics: Posted by vchizhov — Fri Apr 26, 2019 7:27 pm

]]>
2019-04-26T18:51:43 2019-04-26T18:51:43 http://ompf2.com/viewtopic.php?t=2166&p=5945#p5945 <![CDATA[General Development • Re: Point lights and non-diffuse brdfs]]>
PBRT doesn't really go much further beyond implementation details, most of the arguments are of "an intuitive" nature, I want something a bit more formal. The closest thing I could find on the topic was from: http://www.oceanopticsbook.info/view/li ... f_radiance, namely:
Likewise, you cannot define the radiance emitted by the surface of a point source because $$\Delta A$$ becomes zero even though the point source is emitting a finite amount of energy.
And seeing as the rendering equation uses radiance I want to understand how a point light source for which radiance is not defined fits into this framework.
Here's what I found in PBRT after a brief search: http://www.pbr-book.org/3ed-2018/Light_ ... eIntegrand

It classifies point sources as producing delta distributions. It doesn't try to evaluate the incoming radiance directly, but instead evaluates the integral over incoming radiance, which is well-defined even with deltas.

Statistics: Posted by friedlinguini — Fri Apr 26, 2019 6:51 pm

]]>
2019-04-26T15:27:12 2019-04-26T15:27:12 http://ompf2.com/viewtopic.php?t=2166&p=5944#p5944 <![CDATA[General Development • Re: Point lights and non-diffuse brdfs]]>
If you really need academic respectability to be convinced, maybe you should take a look at ingenious' publications.
I would be very grateful if you could refer me to a publication of his that tackles this issue, I am not exactly sure how to find his publications from his username.
Yup. You know what else causes problems?
I mean purely theoretical problems, not specifically the ones you are referring to, though I meant precisely the case where you have a perfect mirror/refraction and a point light, since then you get a product of distributions.
I don't have a specific reference for this, but the first place I'd look for one is the PBRT book.
PBRT doesn't really go much further beyond implementation details, most of the arguments are of "an intuitive" nature, I want something a bit more formal. The closest thing I could find on the topic was from: http://www.oceanopticsbook.info/view/li ... f_radiance, namely:
Likewise, you cannot define the radiance emitted by the surface of a point source because $$\Delta A$$ becomes zero even though the point source is emitting a finite amount of energy.
And seeing as the rendering equation uses radiance I want to understand how a point light source for which radiance is not defined fits into this framework.

Statistics: Posted by vchizhov — Fri Apr 26, 2019 3:27 pm

]]>
2019-04-26T13:12:20 2019-04-26T13:12:20 http://ompf2.com/viewtopic.php?t=2166&p=5943#p5943 <![CDATA[General Development • Re: Point lights and non-diffuse brdfs]]>
Do you have a reference for the part where you mention that you're replacing the radiance with a delta function?
Well, you have an integral over an angle that is non-zero if and only if it includes a singular direction. That's a delta function, isn't it? If you really need academic respectability to be convinced, maybe you should take a look at ingenious' publications. That will also cause even more problems mathematically as it will turn out that you're multiplying distributions in some cases.
Yup. You know what else causes problems? Perfectly specular reflectors and refractors, which also have deltas in their BSDFs. You have two choices when dealing with them--approximate them with spikey but non-delta BSDFs, or sample them differently. In general, you don't try to evaluate those for arbitrary directions; you just cast one ray in the appropriate direction. It's exactly the same for point and directional lights. Either use light sources that subtend a small but finite solid angle, or special-case them. You evaluate the integral (for a single light source) by ignoring everything but the delta direction and then ignoring the delta factor in the integrand. You can think of it as using a Monte Carlo estimator f(x)/pdf(x), where both the f and the pdf have identical delta functions that cancel out.

I don't have a specific reference for this, but the first place I'd look for one is the PBRT book.

Statistics: Posted by friedlinguini — Fri Apr 26, 2019 1:12 pm

]]>
2019-04-25T19:11:36 2019-04-25T19:11:36 http://ompf2.com/viewtopic.php?t=2166&p=5942#p5942 <![CDATA[General Development • Re: Point lights and non-diffuse brdfs]]> What I am looking for is a reference with a mathematically robust derivation that is consistent with radiometry definitions. Papers/books suggestions are welcome.

Statistics: Posted by vchizhov — Thu Apr 25, 2019 7:11 pm

]]>
2019-04-25T17:34:19 2019-04-25T17:34:19 http://ompf2.com/viewtopic.php?t=2166&p=5941#p5941 <![CDATA[General Development • Re: Point lights and non-diffuse brdfs]]> $$L_i$$ by a an angular delta function, which makes the integral degenerate to a simple integrand evaluation. For a point light, which is a delta volume light, you would take the volume version of the rendering equation, i.e. the one where integrates over 3D space, and then again replace $$L_i$$ by a positional delta function.

Statistics: Posted by ingenious — Thu Apr 25, 2019 5:34 pm

]]>
2019-04-24T17:00:54 2019-04-24T17:00:54 http://ompf2.com/viewtopic.php?t=2166&p=5940#p5940 <![CDATA[General Development • Point lights and non-diffuse brdfs]]> $$\vec{c}$$ and intensity $$I$$, then the irradiance at point $$\vec{p}$$ at some surface can be derived as:
$$E(\vec{p}) = \frac{d\Phi}{dA} = \frac{d\Phi}{d\omega}\frac{d\omega}{dA} = I \frac{\cos\theta}{||\vec{c}-\vec{p}||^2}\frac{dA}{dA} = I \frac{\cos\theta}{||\vec{c}-\vec{p}||^2}$$
Assuming that the brdf is constant $$f(\omega_o,\vec{p},\omega_i) = C = \text{const}$$ the outgoing radiance from that surface point due to that point light can be computed as:
$$L_o(\vec{p},\omega_o) = L_e(\vec{p},\omega_o) + \int_{\Omega}{f(\omega_o,\vec{p},\omega_i)L_i(\vec{p},\omega_i)\cos\theta_i\,d\omega_i} =$$
$$L_e(\vec{p},\omega_o) + C\int_{\Omega}{L_i(\vec{p},\omega_i)\cos\theta_i\,d\omega_i} = L_e(\vec{p},\omega_o) + CE(\vec{p}) =$$
$$L_e(\vec{p},\omega_o) + CI \frac{\cos\theta}{||\vec{c}-\vec{p}||^2}$$
Which agrees with what one is used to seeing in implementations in real-time graphics. How does one motivate similar expressions for more complex brdfs considering the fact that radiance for a point light is not defined?

Statistics: Posted by vchizhov — Wed Apr 24, 2019 5:00 pm

]]>
2019-04-09T20:44:50 2019-04-09T20:44:50 http://ompf2.com/viewtopic.php?t=2132&p=5939#p5939 <![CDATA[Visuals • Re: My little path tracer]]>

Here is a another 24 h rendering. I had this fun idea to make a flat earth version of the globe figure.  The dome is filled with a thin, scattering medium. This creates the glow effect around the sun. The image has other details which I like. Like the subtle shadows cast on the surrounding walls. But it proved difficult to render, i.e. it's still noisy.

Statistics: Posted by dawelter — Tue Apr 09, 2019 8:44 pm

]]>
2019-03-28T05:12:54 2019-03-28T05:12:54 http://ompf2.com/viewtopic.php?t=2126&p=5938#p5938 <![CDATA[Visuals • Re: My first Supersize-Image]]> Statistics: Posted by XMAMan — Thu Mar 28, 2019 5:12 am

]]>
2019-03-27T21:07:18 2019-03-27T21:07:18 http://ompf2.com/viewtopic.php?t=2159&p=5937#p5937 <![CDATA[General Development • Re: Shading normal issues w. adjoint bsdf]]>
thank you. The link has a typo, but it's clear which paper you mean: "Microfacet-based Normal Mapping for Robust Monte Carlo Path Tracing". The results look really nice.

One thing bugs me though. In Figure 18th's caption, the authors state
"Our normal-mapping model ... fails the white furnace test if vertex normals are interpolated (please zoom in, bottom right). This is a separate problem not addressed in this work."
I fail to understand how vertex normals are fundamentally different from normal mapping. Because one could bake interpolated normals into a normal map. Thus interpolated normals are equivalent to a special case of a normal map, or aren't they?

Anyway, I found somewhat related work "Linear Efficient Antialiased Displacement and Reflectance Mapping". by Dupuy et al. (2013). It is really about anti aliasing. However, it involves construction of a NDF where the mean normal points in a desired direction (Eq. 8). In this regard it seems to address the same issues as the former paper. I only skimmed over the paper. So apologies if I misrepresent anything.

Through Karl Li's blog I found another interesting paper: "Consistent Normal Interpolation". https://blog.yiningkarlli.com/2015/01/c ... ation.html. Have to question compatibility with bidirectional methods because calculation of the normal needs the direction of the incident ray. So eye and light random walks would "see" different normals on a given surface point. Seems to work for Karl Li though.

Statistics: Posted by dawelter — Wed Mar 27, 2019 9:07 pm

]]>