Graphics Reference
In-Depth Information
In the end we can define two integrals:
Diffuse ( p,ω o )= L n
A ( n )
C d cos θ i i ( n ) ,
(1.11)
Specular ( p,ω o )= L n
A ( n )
D ( h ) F ( ω o ,h ) G ( ω i o ,h )
4( cosθ o )
i ( n ) .
(1.12)
To get the final form of specular integral, we need to choose functions DFG .
There are multiple sources available that discuss the best choice for a specific use
scenario [Burley 12].
Unfortunately, independent of the chosen function, the integrals from equa-
tions (1.11) and (1.12) are not easily solvable for shapes other than a sphere.
Therefore, we will focus on finding a suitable approximation for light shapes that
can be expressed as a 2D function on a quadrilateral.
1.3.3 Approximating Diffuse Integral
Monte Carlo methods and importance sampling. One of the known ways to solve
an integral is numerical integration by discretized parts. There are multiple ways
and techniques to accelerate this process. A particularly interesting one for us
is the Monte Carlo technique, which in general can be described in the following
steps:
1. Define a domain of possible inputs.
2. Generate inputs randomly from a probability distribution over the domain.
3. Calculate the function being integrated for given inputs.
4. Aggregate the results.
With a given probability distribution, the expected variance is also known as well
as the estimator for minimal acceptable error. This process can be significantly
sped up using importance sampling techniques [Pharr and Humphreys 04].
The principle of importance sampling is to prioritize samples that would have
maximum impact on the final outcome. We can find such samples using spatial
heuristics. Another solution is to run an initial pass of Monte Carlo integration
with a low number of samples to estimate the result variance and therefore decide
which regions of integration would use more important samples.
Importance sampling is an actively researched subject with multiple different
solutions. The takeaway for our reasoning is that, in any integration, there are
samples more important than others, therefore minimizing the error estimator
for a given amount of samples.
Search WWH ::




Custom Search