Directional reflectance of GGX / Trowbridge-Reitz BRDF
2026-08-30
This article derives a fast and quite accurate approximation for the
directional reflectance / albedo / split-sum BRDF lookup table of the
Trowbridge-Reitz microfacet model, also known as? GGX [1].
The directional reflectance of a BRDFfr(ωo,ωi) is defined as:
ρ(ωo)=∫Ωfr(ωo,ωi)∣n⋅ωi∣dωi
Directional reflectance is also called albedo in many sources, which is
technically correct, but can be confusing due to how albedo is usually used
specifically to refer to the color of diffuse surfaces. The reflectance is often
tabulated in a couple of lookup textures, with the horizontal axis being viewing
angle cos(θo) and vertical axis being "roughness" α.
I've also taken the square root of cos(θo) here because it produces a
significantly better approximation and emphasizes the difficult corner in the
visualizations.
Just interpolating between these two textures is enough to accurately reconstruct ρ(ωo).
Assumptions
This approximation is only valid when using this microfacet BRDF:
α∈[0,1] controls surface roughness (usually defined as α=roughness2)
ωi,ωo are incoming and outgoing direction vectors (both pointing away from surface)
For simplicity, we assume ωo⋅n>0 and ωi⋅n>0.
ωm=∣ωi+ωo∣ωi+ωo
F0=(n1+n2n1−n2)2
n1 and n2 are the indices of refraction of the two media
This is a fairly standard setup, although some opt for the non-height-correlated
masking-shadowing function instead.
Approximation
First, let's start by inserting the definition of the fresnel term to the
integral. Note that because F(ωo,ωm) is also part of the
definition of fr(ωo,ωi), the division can easily be simplified
away.
Now, we notice that we can actually split the integral due to how Schlick
s Fresnel term is formulated. (If this sounds familiar, this is similar to one
step in the split-sum approximation[4], but not the exact same.)
Therefore, ρ(ωo)=(1−F0)⋅a+F0⋅b=lerp(a,b,F0).
Now, all we have to do is find good approximations for a and b.
This is the same figure as above. The left image is a, the right is b.
Because the isotropic GGX BRDF is, well, isotropic, we don't have to concern
ourselves with ϕo (azimuthal angle of view vector) and don't care about
the tangent or bitangent. We only care about the altitude angle θo,
and specifically cos(θo)=n⋅ωo. We'll be using cos(θo)
a lot, so let's abbreviate it:
β=cos(θo)
ρ(ωo) has a diagonal ridge near the α=0, β=0 corner,
which is represented by r:
r=sin(2arctan(β2/α))=β4+α22β2α
We specifically want to avoid sin and arctan because they are slow to
evaluate. Luckily, this identity lets us get away with one reciprocal instead.
That ridge only affects near the α=0, β=0 corner, so we
define another factor, w, to diminish its effect further away:
w=(1−β)⋅(1−α)
Next, we'll approximate a value for the a integral. In addition to the ridge
r, we use a rational function for this. The numerator polynomial is:
With the rational function and ridge, we get a pretty good approximation for a:
a≈QaPa+0.32726712rw2−0.45161784rw3The left side is the lookup table, while the right side is our new fit, a. Pretty good, right?
Next, we'll approximate b. The fit I came up with is a big multivariate polynomial:
b≈1.0−0.72206968βα2−11.21080953β2α2+14.17520803β3α2−3.89135049β4α2−0.1273335βα3+21.45972561β2α3−28.42641268β3α3+7.85826656β4α3+0.60274702βα4−13.04437201β2α4+18.40509904β3α4+−5.77186108β4α4−0.292659rw+0.19974786rw2Again, ground truth on the left, fit on the right. This one's even better.
The directional reflectance is used for layering BRDFs [5] as it allows us to
determine the amount of energy that can pass into a lower layer without
violating the conservation of energy. It is also used in some cheap
approximations of multiple scattering [6].
ρ(ωo) can also be used as a prior for importance sampling. In a
material mixing multiple BRDFs, we'll want to prioritize the lobe with higher
directional reflectance, as it is more likely to contribute more.
But perhaps most famously, it is used to weigh the intensity of pre-filtered
lighting in image-based lighting, using the split-sum approximation[4].
One part of the method is the tabulation of directional reflectance. If one
approached this naively, you'd need a 3D LUT, where the axes are
n⋅ωo (view angle), α (roughness), and F0 (derived from
index of refraction).
However, they realize that when we're using Schlick's approximation (as
nearly everyone is) for the Fresnel term, one can actually separate the integral
into two components, factoring out F0:
This equation is exact as long as fr(ωo,ωi)∝F(ωo,ωm).
It is very similar to the split we performed in this article. It serves the
same purpose of making the integrals independent of F0, and served as inspiration.
However, I found the first integral quite difficult to fit analytically, as
there is just a bit too much going on:
While the second integral matches our a, the first one is a bit more complicated and resembles some kind of a saddle function.
A rational function fit for ρ(ωo) is also provided in a Ray Tracing
Gems article [7]. Unless I made an error implementing it, this fit is not that
great in my opinion... It is missing a lot of detail to the point of barely
resembling ρ(ωo) and can go above 1.