BSSRDF

 

Goal: Implement a BSSRDF material type providing a more realistic approximation to translucent and scattering surfaces, abilities beyond the scope of a BRDF.

 

Motivation: For highly scattering materials such as milk, skin, and marble, path tracing a participating medium can involve many scattering events, becoming quite costly.  If we can get the characteristics of participating matter for less cost, we should.  To this end the BSSRDF functions as an approximation to such materials.

 

Implementing: The basic idea of the BSSRDF is simple enough; integrate over the surface as well as directions.  This integral is split into two components: a diffuse component and a single scatter component.

 

Diffuse:  The diffuse component is the contribution of light that has undergone multiple scattering events within the material.  This is approximated by two virtual lights directly above and below the ray exit point.  The contribution of these lights falls of exponentially with distance.  To sample the diffuse approximation I chose, uniformity, a random point on the surface and a random direction.  Assuming that it is locally flat between these two points it is easy to find the distances.  This assumption is valid because of the exponential decay.

 

          

 

Single Scatter:  The single scatter component is the contribution of light that has undergone only a single scattering event (only one bounce in the medium).  I find this by tracing a refracted ray, changing direction once, through the material.  The contribution from this sampled direction is dependent on the distance traveled through the medium.  In the case of explicit direct lighting it is necessary to approximate this distance using Snell's law, as it is prohibitive to find a refracted ray that intersects the light.

 

Results: 

 

Marble sphere of radius 1

 

Marble sphere of radius 100

 

Problem Areas:  The most obvious problem is that the second image is washed out.  Further, it doesn't look like marble.  I most definitely am off with my multipliers, most likely in the diffuse part.  The probability of choosing a point is 1/A; therefore, I need to multiply the bssrdf by A, but this is causing the burnout.

 

The most difficult part in implementing the BSSRDF was understanding the paper by Jensen et. al.  It was in this pursuit that I spent most of my time. Unlike the A-S paper, Jensen spends little time explaining the implementation of the BSSRDF, favoring to discus the mathematical derivation.  This is most pronounced in the explanation of the single scattering term.  Here he does a change of variable, from an integral over the surface and directions to an integral over path distance and directions, without explanation.  This caused me confusion in choosing the sampling method.

 

Further, integrating over the surface requires a random point on the surface.  Doing this for a BVH is not trivial and I ran out of time to make this work.

 

Further Work:  I'd like to finish BVH support.  Further, my sampling technique for the diffuse component is not ideal.  Ideally, it would be better to sample with and exponential PDF.  To do that requires integrating over a local disk with a random radius determined in such a manner.  I also spent some time working on an irradiance-cached version discussed in another of Jensen's papers, but abandoned it early on.