13.1 The Light Transport Equation

The light transport equation (LTE) is the governing equation that describes the equilibrium distribution of radiance in a scene. It gives the total reflected radiance at a point on a surface in terms of emission from the surface, its BSDF, and the distribution of incident illumination arriving at the point. For now we will continue to only consider the case where there are no participating media in the scene, saving those complexities for Chapter 14.

The detail that makes evaluating the LTE difficult is the fact that incident radiance at a point is affected by the geometry and scattering properties of all the objects in the scene. For example, a bright light shining on a red object may cause a reddish tint on nearby objects in the scene, or glass may focus light into caustic patterns on a tabletop. Rendering algorithms that account for this complexity are often called global illumination algorithms, to differentiate them from local illumination algorithms that use only information about the local surface properties in their shading computations.

In this section, we will first derive the LTE and describe some approaches for manipulating the equation to make it easier to solve numerically. We will then describe two generalizations of the LTE that make some of its key properties more clear and serve as the foundation for integrators that implement sophisticated light transport algorithms.

13.1.1 Basic Derivation

The light transport equation depends on the basic assumptions we have already made in choosing to use radiometry to describe light—that wave optics effects are unimportant and that the distribution of radiance in the scene is in equilibrium.

The key principle underlying the LTE is energy balance. Any change in energy has to be “charged” to some process, and we must keep track of all the energy. Since we are assuming that lighting is a linear process, the difference between the amount of energy going out of a system and the amount of energy coming in must also be equal to the difference between energy emitted and energy absorbed. This idea holds at many levels of scale. On a macro level we have conservation of power:

normal upper Phi Subscript normal o Baseline minus normal upper Phi Subscript normal i Baseline equals normal upper Phi Subscript normal e Baseline minus normal upper Phi Subscript normal a Baseline period

The difference between the power leaving an object, normal upper Phi Subscript normal o , and the power entering it, normal upper Phi Subscript normal i , is equal to the difference between the power it emits and the power it absorbs, normal upper Phi Subscript normal e Baseline minus normal upper Phi Subscript normal a .

To enforce energy balance at a surface, exitant radiance upper L Subscript normal o must be equal to emitted radiance plus the fraction of incident radiance that is scattered. Emitted radiance is given by upper L Subscript normal e , and scattered radiance is given by the scattering equation, which gives

StartLayout 1st Row 1st Column upper L Subscript normal o Baseline left-parenthesis normal p Subscript Baseline comma omega Subscript normal o Baseline right-parenthesis 2nd Column equals upper L Subscript normal e Baseline left-parenthesis normal p Subscript Baseline comma omega Subscript normal o Baseline right-parenthesis plus integral Underscript script upper S squared Endscripts f Subscript Baseline left-parenthesis normal p Subscript Baseline comma omega Subscript normal o Baseline comma omega Subscript normal i Baseline right-parenthesis upper L Subscript normal i Baseline left-parenthesis normal p Subscript Baseline comma omega Subscript normal i Baseline right-parenthesis StartAbsoluteValue cosine theta Subscript normal i Baseline EndAbsoluteValue normal d omega Subscript normal i Baseline period EndLayout

Figure 13.1: Radiance along a Ray through Free Space Is Unchanged. Therefore, to compute the incident radiance along a ray from point normal p Subscript in direction omega Subscript , we can find the first surface the ray intersects and compute exitant radiance in the direction minus omega Subscript there. The ray-casting function t left-parenthesis normal p Subscript Baseline comma omega Subscript Baseline right-parenthesis gives the point normal p prime on the first surface that the ray left-parenthesis normal p Subscript Baseline comma omega Subscript Baseline right-parenthesis intersects.

Because we have assumed for now that no participating media are present, radiance is constant along rays through the scene. We can therefore relate the incident radiance at normal p Subscript to the outgoing radiance from another point normal p prime , as shown by Figure 13.1. If we define the ray-casting function t left-parenthesis normal p Subscript Baseline comma omega Subscript Baseline right-parenthesis as a function that computes the first surface point normal p prime intersected by a ray from normal p Subscript in the direction omega Subscript , we can write the incident radiance at normal p Subscript in terms of outgoing radiance at  normal p prime :

upper L Subscript normal i Baseline left-parenthesis normal p Subscript Baseline comma omega Subscript Baseline right-parenthesis equals upper L Subscript normal o Baseline left-parenthesis t left-parenthesis normal p Subscript Baseline comma omega Subscript Baseline right-parenthesis comma minus omega Subscript Baseline right-parenthesis period

In case the scene is not closed, we will define the ray-casting function to return a special value normal upper Lamda if the ray left-parenthesis normal p Subscript Baseline comma omega Subscript Baseline right-parenthesis does not intersect any object in the scene, such that upper L Subscript normal o Superscript Baseline left-parenthesis normal upper Lamda comma omega Subscript Baseline right-parenthesis is always 0.

Dropping the subscripts from upper L Subscript normal o for brevity, this relationship allows us to write the LTE as

upper L left-parenthesis normal p Subscript Baseline comma omega Subscript normal o Baseline right-parenthesis equals upper L Subscript normal e Baseline left-parenthesis normal p Subscript Baseline comma omega Subscript normal o Baseline right-parenthesis plus integral Underscript script upper S squared Endscripts f Subscript Baseline left-parenthesis normal p Subscript Baseline comma omega Subscript normal o Baseline comma omega Subscript normal i Baseline right-parenthesis upper L left-parenthesis t left-parenthesis normal p Subscript Baseline comma omega Subscript normal i Baseline right-parenthesis comma minus omega Subscript normal i Baseline right-parenthesis StartAbsoluteValue cosine theta Subscript normal i Baseline EndAbsoluteValue normal d omega Subscript normal i Baseline period

The key to the above representation is that there is only one quantity of interest, exitant radiance from points on surfaces. Of course, it appears on both sides of the equation, so our task is still not simple, but it is certainly easier. It is important to keep in mind that we were able to arrive at this equation simply by enforcing energy balance in our scene.

13.1.2 Analytic Solutions to the LTE

The brevity of the LTE belies the fact that it is impossible to solve analytically other than in very simple cases. The complexity that comes from physically based BSDF models, arbitrary scene geometry, and the intricate visibility relationships among objects all conspire to mandate a numerical solution technique. Fortunately, the combination of ray-tracing algorithms and Monte Carlo integration gives a powerful pair of tools that can handle this complexity without needing to impose restrictions on various components of the LTE (e.g., requiring that all BSDFs be Lambertian or substantially limiting the geometric representations that are supported).

It is possible to find analytic solutions to the LTE in very simple settings. While this is of little help for general-purpose rendering, it can help with debugging the implementations of integrators. If an integrator that is supposed to solve the complete LTE does not compute a solution that matches an analytic solution, then clearly there is a bug in the integrator. As an example, consider the interior of a sphere where all points on the surface of the sphere have a Lambertian BRDF, f Subscript Baseline left-parenthesis normal p Subscript Baseline comma omega Subscript normal o Baseline comma omega Subscript normal i Baseline right-parenthesis equals c , and also emit a constant amount of radiance in all directions. We have

upper L left-parenthesis normal p Subscript Baseline comma omega Subscript normal o Baseline right-parenthesis equals upper L Subscript normal e Superscript Baseline plus c integral Underscript script upper H squared left-parenthesis bold n Subscript Baseline right-parenthesis Endscripts upper L left-parenthesis t left-parenthesis normal p Subscript Baseline comma omega Subscript normal i Baseline right-parenthesis comma minus omega Subscript normal i Baseline right-parenthesis StartAbsoluteValue cosine theta Subscript normal i Baseline EndAbsoluteValue normal d omega Subscript normal i Baseline period

The outgoing radiance distribution at any point on the sphere interior must be the same as at any other point; nothing in the environment introduces any variation among different points. Therefore, the incident radiance distribution must be the same at all points, and the cosine-weighted integral of incident radiance must be the same everywhere as well. As such, we can replace the radiance functions with constants and simplify, writing the LTE as

upper L Subscript Superscript Baseline equals upper L Subscript normal e Superscript Baseline plus c pi upper L Subscript Superscript Baseline period

While we could immediately solve this equation for upper L Subscript Superscript , it is interesting to consider successive substitution of the right hand side into the upper L Subscript Superscript term on the right hand side. If we also replace pi c with rho Subscript normal h normal h , the reflectance of a Lambertian surface, we have

StartLayout 1st Row 1st Column upper L Subscript Superscript 2nd Column equals upper L Subscript normal e Superscript Baseline plus rho Subscript normal h normal h Baseline left-parenthesis upper L Subscript normal e Superscript Baseline plus rho Subscript normal h normal h Baseline left-parenthesis upper L Subscript normal e Superscript Baseline plus midline-horizontal-ellipsis 2nd Row 1st Column Blank 2nd Column equals sigma-summation Underscript i equals 0 Overscript normal infinity Endscripts upper L Subscript normal e Superscript Baseline rho Subscript normal h normal h Superscript i Baseline period EndLayout

In other words, exitant radiance is equal to the emitted radiance at the point plus light that has been scattered by a BSDF once after emission, plus light that has been scattered twice, and so forth.

Because rho Subscript normal h normal h Baseline less-than 1 due to conservation of energy, the series converges and the reflected radiance at all points in all directions is

upper L Subscript Superscript Baseline equals StartFraction upper L Subscript normal e Baseline Over 1 minus rho Subscript normal h normal h Baseline EndFraction period

(This series is called a Neumann series.)

This process of repeatedly substituting the LTE’s right hand side into the incident radiance term in the integral can be instructive in more general cases. For example, only accounting for direct illumination effectively computes the result of making a single substitution:

upper L left-parenthesis normal p Subscript Baseline comma omega Subscript normal o Baseline right-parenthesis equals upper L Subscript normal e Superscript Baseline left-parenthesis normal p Subscript Baseline comma omega Subscript normal o Baseline right-parenthesis plus integral Underscript script upper S squared Endscripts f Subscript Baseline left-parenthesis normal p Subscript Baseline comma omega Subscript normal o Baseline comma omega Subscript normal i Baseline right-parenthesis upper L Subscript normal d Baseline left-parenthesis normal p Subscript Baseline comma omega Subscript normal i Baseline right-parenthesis StartAbsoluteValue cosine theta Subscript normal i Baseline EndAbsoluteValue normal d omega Subscript normal i Baseline comma

where

upper L Subscript normal d Baseline left-parenthesis normal p Subscript Baseline comma omega Subscript normal i Baseline right-parenthesis equals upper L Subscript normal e Superscript Baseline left-parenthesis t left-parenthesis normal p Subscript Baseline comma omega Subscript normal i Baseline right-parenthesis comma minus omega Subscript normal i Baseline right-parenthesis

and further scattering is ignored.

Over the next few pages, we will see how performing successive substitutions in this manner and then regrouping the results expresses the LTE in a more natural way for developing rendering algorithms.

13.1.3 The Surface Form of the LTE

One reason the LTE as written in Equation (13.1) is complex is that the relationship between geometric objects in the scene is implicit in the ray-tracing function t left-parenthesis normal p Subscript Baseline comma omega Subscript Baseline right-parenthesis . Making the behavior of this function explicit in the integrand will shed some light on the structure of this equation. To do this, we will rewrite Equation (13.1) as an integral over area instead of an integral over directions on the sphere.

First, we define exitant radiance from a point normal p prime to a point normal p Subscript by

upper L left-parenthesis normal p prime right-arrow normal p Subscript Baseline right-parenthesis equals upper L Subscript Superscript Baseline left-parenthesis normal p prime comma omega Subscript Baseline right-parenthesis

if normal p prime and normal p Subscript are mutually visible and omega Subscript Baseline equals ModifyingAbove normal p Subscript Baseline minus normal p Superscript prime Baseline With caret . We can also write the BSDF at normal p prime  as

f Subscript Baseline left-parenthesis normal p double-prime right-arrow normal p prime right-arrow normal p Subscript Baseline right-parenthesis equals f left-parenthesis normal p prime comma omega Subscript normal o Baseline comma omega Subscript normal i Baseline right-parenthesis comma

where omega Subscript normal i Baseline equals ModifyingAbove normal p double-prime minus normal p Superscript prime Baseline With caret and omega Subscript normal o Baseline equals ModifyingAbove normal p Subscript Baseline minus normal p Superscript prime Baseline With caret (Figure 13.2). This is sometimes called the three-point form of the BSDF.

Figure 13.2: The three-point form of the light transport equation converts the integral to be over the domain of points on surfaces in the scene, rather than over directions on the sphere. It is a key transformation for deriving the path integral form of the light transport equation.

Rewriting the terms in the LTE in this manner is not quite enough, however. We also need to multiply by the Jacobian that relates solid angle to area in order to transform the LTE from an integral over direction to one over surface area. Recall that this is StartAbsoluteValue cosine theta prime EndAbsoluteValue slash r squared .

We will combine this change-of-variables term, the original StartAbsoluteValue cosine theta EndAbsoluteValue term from the LTE, and a binary visibility function upper V ( upper V equals 1 if the two points are mutually visible, and upper V equals 0 otherwise) into a single geometric coupling term, upper G left-parenthesis normal p Subscript Baseline left-right-arrow normal p prime right-parenthesis :

upper G left-parenthesis normal p Subscript Baseline left-right-arrow normal p Superscript prime Baseline right-parenthesis equals upper V left-parenthesis normal p Subscript Baseline left-right-arrow normal p Superscript prime Baseline right-parenthesis StartFraction StartAbsoluteValue cosine theta EndAbsoluteValue StartAbsoluteValue cosine theta Superscript prime Baseline EndAbsoluteValue Over parallel-to normal p Subscript Baseline minus normal p Superscript prime Baseline parallel-to EndFraction period

Substituting these into the light transport equation and converting to an area integral, we have the three-point form of the LTE,

StartLayout 1st Row 1st Column upper L left-parenthesis normal p prime right-arrow normal p Subscript Baseline right-parenthesis equals upper L Subscript normal e Baseline left-parenthesis normal p prime right-arrow normal p Subscript Baseline right-parenthesis plus integral Underscript upper A Endscripts f Subscript Baseline left-parenthesis normal p double-prime right-arrow normal p prime right-arrow normal p Subscript Baseline right-parenthesis upper L left-parenthesis normal p double-prime right-arrow normal p prime right-parenthesis upper G left-parenthesis normal p double-prime left-right-arrow normal p prime right-parenthesis 2nd Column normal d upper A Subscript Baseline left-parenthesis normal p Superscript double-prime Baseline right-parenthesis comma 2nd Row 1st Column Blank 2nd Column Blank EndLayout

where upper A is all the surfaces of the scene.

Although Equations (13.1) and (13.3) are equivalent, they represent two different ways of approaching light transport. To evaluate Equation (13.1) with Monte Carlo, we would sample directions from a distribution of directions on the sphere and cast rays to evaluate the integrand. For Equation (13.3), however, we would sample points on surfaces according to a distribution over surface area and compute the coupling between those points to evaluate the integrand, tracing rays to evaluate the visibility term upper V left-parenthesis normal p Subscript Baseline left-right-arrow normal p prime right-parenthesis .

13.1.4 Integral over Paths

With the area integral form of Equation (13.3), we can derive a more flexible form of the LTE known as the path integral formulation of light transport, which expresses radiance as an integral over paths that are themselves points in a high-dimensional path space. One of the main motivations for using path space is that it provides an expression for the value of a measurement as an explicit integral over paths, as opposed to the unwieldy recursive definition resulting from the energy balance equation, (13.1).

The explicit form allows for considerable freedom in how these paths are found—essentially any technique for randomly choosing paths can be turned into a workable rendering algorithm that computes the right answer given a sufficient number of samples. This form of the LTE provides the foundation for bidirectional light transport algorithms.

To go from the area integral to a sum over path integrals involving light-carrying paths of different lengths, we can start to expand the three-point light transport equation, repeatedly substituting the right hand side of the equation into the upper L left-parenthesis normal p double-prime right-arrow normal p prime right-parenthesis term inside the integral. Here are the first few terms that give incident radiance at a point normal p 0 from another point normal p 1 , where normal p 1 is the first point on a surface along the ray from normal p 0 in direction normal p 1 minus normal p 0 :

StartLayout 1st Row 1st Column upper L left-parenthesis normal p 1 right-arrow normal p 0 right-parenthesis 2nd Column equals upper L Subscript normal e Baseline left-parenthesis normal p 1 right-arrow normal p 0 right-parenthesis 2nd Row 1st Column Blank 2nd Column plus integral Underscript upper A Endscripts upper L Subscript normal e Baseline left-parenthesis normal p 2 right-arrow normal p 1 right-parenthesis f Subscript Baseline left-parenthesis normal p 2 right-arrow normal p 1 right-arrow normal p 0 right-parenthesis upper G left-parenthesis normal p 2 left-right-arrow normal p 1 right-parenthesis normal d upper A Subscript Baseline left-parenthesis normal p 2 right-parenthesis 3rd Row 1st Column Blank 2nd Column plus integral Underscript upper A Endscripts integral Underscript upper A Endscripts upper L Subscript normal e Baseline left-parenthesis normal p 3 right-arrow normal p 2 right-parenthesis f Subscript Baseline left-parenthesis normal p 3 right-arrow normal p 2 right-arrow normal p 1 right-parenthesis upper G left-parenthesis normal p 3 left-right-arrow normal p 2 right-parenthesis 4th Row 1st Column Blank 2nd Column times f Subscript Baseline left-parenthesis normal p 2 right-arrow normal p 1 right-arrow normal p 0 right-parenthesis upper G left-parenthesis normal p 2 left-right-arrow normal p 1 right-parenthesis normal d upper A Subscript Baseline left-parenthesis normal p 3 right-parenthesis normal d upper A Subscript Baseline left-parenthesis normal p 2 right-parenthesis plus midline-horizontal-ellipsis EndLayout

Each term on the right side of this equation represents a path of increasing length. For example, the third term is illustrated in Figure 13.3. This path has four vertices, connected by three segments. The total contribution of all such paths of length four (i.e., a vertex at the camera, two vertices at points on surfaces in the scene, and a vertex on a light source) is given by this term. Here, the first two vertices of the path, normal p 0 and normal p 1 , are predetermined based on the camera ray origin and the point that the camera ray intersects, but normal p 2 and normal p 3 can vary over all points on surfaces in the scene. The integral over all such normal p 2 and normal p 3 gives the total contribution of paths of length four to radiance arriving at the camera.

Figure 13.3: The integral over all points normal p 2 and normal p 3 on surfaces in the scene given by the light transport equation gives the total contribution of two bounce paths to radiance leaving normal p 1 in the direction of normal p 0 . The components of the product in the integrand are shown here: the emitted radiance from the light, upper L Subscript normal e ; the geometric terms between vertices, upper G ; and scattering from the BSDFs,  f Subscript .

This infinite sum can be written compactly as

upper L left-parenthesis normal p 1 right-arrow normal p 0 right-parenthesis equals sigma-summation Underscript n equals 1 Overscript normal infinity Endscripts upper P left-parenthesis normal p Subscript Baseline overbar Subscript n Baseline right-parenthesis period

upper P left-parenthesis normal p Subscript Baseline overbar Subscript n Baseline right-parenthesis gives the amount of radiance scattered over a path normal p Subscript Baseline overbar Subscript n with n plus 1 vertices,

normal p Subscript Baseline overbar Subscript n Baseline equals normal p 0 comma normal p 1 comma ellipsis comma normal p Subscript n Baseline comma

where normal p 0 is on the film plane or front lens element and normal p Subscript Baseline Subscript n is on a light source, and

StartLayout 1st Row 1st Column upper P left-parenthesis normal p Subscript Baseline overbar Subscript n Baseline right-parenthesis 2nd Column equals ModifyingBelow integral Underscript upper A Endscripts integral Underscript upper A Endscripts midline-horizontal-ellipsis integral Underscript upper A Endscripts With bottom-brace Underscript n minus 1 Endscripts upper L Subscript normal e Baseline left-parenthesis normal p Subscript Baseline Subscript n Baseline right-arrow normal p Subscript Baseline Subscript n minus 1 Baseline right-parenthesis 2nd Row 1st Column Blank 2nd Column times left-parenthesis product Underscript i equals 1 Overscript n minus 1 Endscripts f Subscript Baseline left-parenthesis normal p Subscript Baseline Subscript i plus 1 Baseline right-arrow normal p Subscript Baseline Subscript i Baseline right-arrow normal p Subscript Baseline Subscript i minus 1 Baseline right-parenthesis upper G left-parenthesis normal p Subscript Baseline Subscript i plus 1 Baseline left-right-arrow normal p Subscript Baseline Subscript i Baseline right-parenthesis right-parenthesis normal d upper A Subscript Baseline left-parenthesis normal p 2 right-parenthesis midline-horizontal-ellipsis normal d upper A Subscript Baseline left-parenthesis normal p Subscript Baseline Subscript n Baseline right-parenthesis period EndLayout

Before we move on, we will define one additional term that will be helpful in the subsequent discussion. The product of a path’s BSDF and geometry terms is called the throughput of the path; it describes the fraction of radiance from the light source that arrives at the camera after all the scattering at vertices between them. We will denote it by

upper T left-parenthesis normal p Subscript Baseline overbar Subscript n Baseline right-parenthesis equals product Underscript i equals 1 Overscript n minus 1 Endscripts f Subscript Baseline left-parenthesis normal p Subscript Baseline Subscript i plus 1 Baseline right-arrow normal p Subscript Baseline Subscript i Baseline right-arrow normal p Subscript Baseline Subscript i minus 1 Baseline right-parenthesis upper G left-parenthesis normal p Subscript Baseline Subscript i plus 1 Baseline left-right-arrow normal p Subscript Baseline Subscript i Baseline right-parenthesis comma

so

upper P left-parenthesis normal p Subscript Baseline overbar Subscript n Baseline right-parenthesis equals ModifyingBelow integral Underscript upper A Endscripts integral Underscript upper A Endscripts midline-horizontal-ellipsis integral Underscript upper A Endscripts With bottom-brace Underscript n minus 1 Endscripts upper L Subscript normal e Baseline left-parenthesis normal p Subscript Baseline Subscript n Baseline right-arrow normal p Subscript Baseline Subscript n minus 1 Baseline right-parenthesis upper T left-parenthesis normal p Subscript Baseline overbar Subscript n Baseline right-parenthesis normal d upper A Subscript Baseline left-parenthesis normal p 2 right-parenthesis midline-horizontal-ellipsis normal d upper A Subscript Baseline left-parenthesis normal p Subscript Baseline Subscript n Baseline right-parenthesis period

Given Equation (13.4) and a particular length n , all that we need to do to compute a Monte Carlo estimate of the radiance arriving at normal p 0 due to paths of length n is to sample a set of vertices with an appropriate sampling density, normal p overbar Subscript n Baseline tilde p , to generate a path and then to evaluate an estimate of upper P left-parenthesis normal p Subscript Baseline overbar Subscript n Baseline right-parenthesis using those vertices:

upper L left-parenthesis normal p 1 right-arrow normal p 0 right-parenthesis almost-equals sigma-summation Underscript n equals 1 Overscript normal infinity Endscripts StartFraction upper P left-parenthesis normal p Subscript Baseline overbar Subscript n Baseline right-parenthesis Over p left-parenthesis normal p overbar Subscript n Baseline right-parenthesis EndFraction period

Whether we generate those vertices by starting a path from the camera, starting from the light, starting from both ends, or starting from a point in the middle is a detail that only affects how the path probability p left-parenthesis normal p overbar Subscript n Baseline right-parenthesis is computed. We will see how this formulation leads to practical light transport algorithms throughout this and the following chapters.

13.1.5 Delta Distributions in the Integrand

Delta functions may be present in upper P left-parenthesis normal p Subscript Baseline overbar Subscript i Baseline right-parenthesis terms due not only to certain types of light sources (e.g., point lights and directional lights) but also to BSDF components described by delta distributions. If present, these distributions need to be handled explicitly by the light transport algorithm. For example, it is impossible to randomly choose an outgoing direction from a point on a surface that would intersect a point light source; instead, it is necessary to explicitly choose the single direction from the point to the light source if we want to be able to include its contribution. (The same is true for sampling BSDFs with delta components.) While handling this case introduces some additional complexity to the integrators, it is generally welcome because it reduces the dimensionality of the integral to be evaluated, turning parts of it into a plain sum.

For example, consider the direct illumination term, upper P left-parenthesis normal p Subscript Baseline overbar Subscript 2 Baseline right-parenthesis , in a scene with a single point light source at point normal p Subscript normal l normal i normal g normal h normal t described by a delta distribution:

StartLayout 1st Row 1st Column upper P left-parenthesis normal p Subscript Baseline overbar Subscript 2 Baseline right-parenthesis 2nd Column equals integral Underscript upper A Endscripts upper L Subscript normal e Baseline left-parenthesis normal p 2 right-arrow normal p 1 right-parenthesis f Subscript Baseline left-parenthesis normal p 2 right-arrow normal p 1 right-arrow normal p 0 right-parenthesis upper G left-parenthesis normal p 2 left-right-arrow normal p 1 right-parenthesis normal d upper A Subscript Baseline left-parenthesis normal p 2 right-parenthesis 2nd Row 1st Column Blank 2nd Column equals StartFraction delta left-parenthesis normal p Subscript normal l normal i normal g normal h normal t Baseline minus normal p 2 right-parenthesis upper L Subscript normal e Baseline left-parenthesis normal p Subscript normal l normal i normal g normal h normal t Baseline right-arrow normal p 1 right-parenthesis Over p left-parenthesis normal p Subscript normal l normal i normal g normal h normal t Baseline right-parenthesis EndFraction f Subscript Baseline left-parenthesis normal p 2 right-arrow normal p 1 right-arrow normal p 0 right-parenthesis upper G left-parenthesis normal p 2 left-right-arrow normal p 1 right-parenthesis period EndLayout

In other words, normal p 2 must be the light’s position in the scene; the delta distribution in the numerator cancels out due to an implicit delta distribution in p left-parenthesis normal p Subscript normal l normal i normal g normal h normal t Baseline right-parenthesis (recall the discussion of sampling Dirac delta distributions in Section 12.1), and we are left with terms that can be evaluated directly, with no need for Monte Carlo. An analogous situation holds for BSDFs with delta distributions in the path throughput upper T left-parenthesis normal p Subscript Baseline overbar Subscript n Baseline right-parenthesis ; each one eliminates an integral over area from the estimate to be computed.

13.1.6 Partitioning the Integrand

Many rendering algorithms have been developed that are particularly good at solving the LTE under some conditions but do not work well (or at all) under others. For example, Whitted’s original ray-tracing algorithm only handles specular reflection from delta distribution BSDFs and ignores multiply scattered light from diffuse and glossy BSDFs.

Because we would like to be able to derive correct light transport algorithms that account for all possible modes of scattering without ignoring any contributions and without double-counting others, it is important to pay attention to which parts of the LTE a particular solution method accounts for. A nice way of approaching this problem is to partition the LTE in various ways. For example, we might expand the sum over paths to

upper L left-parenthesis normal p 1 right-arrow normal p 0 right-parenthesis equals upper P left-parenthesis normal p Subscript Baseline overbar Subscript 1 Baseline right-parenthesis plus upper P left-parenthesis normal p Subscript Baseline overbar Subscript 2 Baseline right-parenthesis plus sigma-summation Underscript i equals 3 Overscript normal infinity Endscripts upper P left-parenthesis normal p Subscript Baseline overbar Subscript i Baseline right-parenthesis comma

where the first term is trivially evaluated by computing the emitted radiance at normal p 1 , the second term is solved with an accurate direct lighting solution technique, but the remaining terms in the sum are handled with a faster but less accurate approach. If the contribution of these additional terms to the total reflected radiance is relatively small for the scene we are rendering, this may be a reasonable approach to take. The only detail is that it is important to be careful to ignore upper P left-parenthesis normal p Subscript Baseline overbar Subscript 1 Baseline right-parenthesis and upper P left-parenthesis normal p Subscript Baseline overbar Subscript 2 Baseline right-parenthesis with the algorithm that handles upper P left-parenthesis normal p Subscript Baseline overbar Subscript 3 Baseline right-parenthesis and beyond (and similarly with the other terms).

It is also useful to partition individual upper P left-parenthesis normal p Subscript Baseline overbar Subscript n Baseline right-parenthesis terms. For example, we might want to split the emission term into emission from small light sources, upper L Subscript normal e comma normal s , and emission from large light sources, upper L Subscript normal e comma normal l , giving us two separate integrals to estimate:

StartLayout 1st Row 1st Column upper P left-parenthesis normal p Subscript Baseline overbar Subscript n Baseline right-parenthesis 2nd Column equals integral Underscript upper A Superscript n minus 1 Baseline Endscripts left-parenthesis upper L Subscript normal e comma normal s Baseline left-parenthesis normal p Subscript Baseline Subscript n Baseline right-arrow normal p Subscript Baseline Subscript n minus 1 Baseline right-parenthesis plus upper L Subscript normal e comma normal l Baseline left-parenthesis normal p Subscript n Baseline right-arrow normal p Subscript n minus 1 Baseline right-parenthesis right-parenthesis upper T left-parenthesis normal p Subscript Baseline overbar Subscript n Baseline right-parenthesis normal d upper A Subscript Baseline left-parenthesis normal p 2 right-parenthesis midline-horizontal-ellipsis normal d upper A Subscript Baseline left-parenthesis normal p Subscript Baseline Subscript n Baseline right-parenthesis 2nd Row 1st Column Blank 2nd Column equals integral Underscript upper A Superscript n minus 1 Baseline Endscripts upper L Subscript normal e comma normal s Baseline left-parenthesis normal p Subscript n Baseline right-arrow normal p Subscript n minus 1 Baseline right-parenthesis upper T left-parenthesis normal p Subscript Baseline overbar Subscript n Baseline right-parenthesis normal d upper A Subscript Baseline left-parenthesis normal p 2 right-parenthesis midline-horizontal-ellipsis normal d upper A Subscript Baseline left-parenthesis normal p Subscript Baseline Subscript n Baseline right-parenthesis 3rd Row 1st Column Blank 2nd Column plus integral Underscript upper A Superscript n minus 1 Baseline Endscripts upper L Subscript normal e comma normal l Baseline left-parenthesis normal p Subscript n Baseline right-arrow normal p Subscript n minus 1 Baseline right-parenthesis upper T left-parenthesis normal p Subscript Baseline overbar Subscript n Baseline right-parenthesis normal d upper A Subscript Baseline left-parenthesis normal p 2 right-parenthesis midline-horizontal-ellipsis normal d upper A Subscript Baseline left-parenthesis normal p Subscript Baseline Subscript n Baseline right-parenthesis period EndLayout

The two integrals can be evaluated independently, possibly using completely different algorithms or different numbers of samples, selected in a way that handles the different conditions well. As long as the estimate of the upper L Subscript normal e comma normal s integral ignores any emission from large lights, the estimate of the upper L Subscript normal e comma normal l integral ignores emission from small lights, and all lights are categorized as either “large” or “small,” the correct result is computed in the end.

Finally, the BSDF terms can be partitioned as well (in fact, this application was the reason BSDF categorization with BxDFFlags values was introduced in Section 9.1.2). For example, if f Subscript normal upper Delta denotes components of the BSDF described by delta distributions and f Subscript normal not-sign normal upper Delta denotes the remaining components,

StartLayout 1st Row 1st Column upper P left-parenthesis normal p Subscript Baseline overbar Subscript n Baseline right-parenthesis equals 2nd Column integral Underscript upper A Superscript n minus 1 Endscripts upper L Subscript normal e Baseline left-parenthesis normal p Subscript n Baseline right-arrow normal p Subscript n minus 1 Baseline right-parenthesis 2nd Row 1st Column Blank 2nd Column times product Underscript i equals 1 Overscript n minus 1 Endscripts left-parenthesis f Subscript normal upper Delta Baseline left-parenthesis normal p Subscript i plus 1 Baseline right-arrow normal p Subscript i Baseline right-arrow normal p Subscript i minus 1 Baseline right-parenthesis plus f Subscript normal not-sign normal upper Delta Baseline left-parenthesis normal p Subscript i plus 1 Baseline right-arrow normal p Subscript i Baseline right-arrow normal p Subscript i minus 1 Baseline right-parenthesis right-parenthesis 3rd Row 1st Column Blank 2nd Column times upper G left-parenthesis normal p Subscript i plus 1 Baseline left-right-arrow normal p Subscript i Baseline right-parenthesis normal d upper A Subscript Baseline left-parenthesis normal p 2 right-parenthesis midline-horizontal-ellipsis normal d upper A Subscript Baseline left-parenthesis normal p Subscript n Baseline right-parenthesis period EndLayout

Note that because there are n minus 1 BSDF terms in the product, it is important to be careful not to count only terms with just f Subscript normal upper Delta components or just f Subscript normal not-sign normal upper Delta components; all the mixed terms like f Subscript normal upper Delta Baseline f Subscript normal not-sign normal upper Delta Baseline f Subscript normal not-sign normal upper Delta must be accounted for as well if a partitioning scheme like this is used.