A key aspect of color representation is the use of
Spherical Harmonics (Spherical Harmonics, SH).
Spherical harmonics are solutions to Laplace's equation in spherical
coordinates and form a complete orthogonal basis for functions defined
on the surface of a sphere. A function
can therefore be represented as
| (10.108) |
where denotes the direction,
is the degree of the harmonic,
its order, and
the corresponding coefficient. In a numerical approximation, a finite maximum degree
is generally used.
For real spherical harmonics, which are also commonly used to represent color in Gaussian
Splatting, the following definition can be used. For
and
:
where
and are the associated Legendre polynomials, defined using the
convention that includes the Condon–Shortley phase factor 10.6
For , there is a single harmonic, constant over the sphere:
| (10.111) |
For a maximum degree of , the total number of harmonics is
| (10.112) |
Consequently, each color channel can be represented using coefficients. For example, with
, one coefficient is used; with
, four coefficients; and with
, nine coefficients.
In computer graphics, spherical harmonics are used to compactly represent direction-dependent functions. In neural rendering, they can therefore be used to describe how color depends on the viewing direction. The coefficients of the representation determine the function's variation as the direction changes.
The idea is to select a maximum degree and represent each color channel—red, green, and blue—as a linear combination of spherical harmonics, using the viewing direction
as the variable; that is, the direction of the optical ray connecting the point to the observer.
For each color channel, we obtain, for example, the following expression for the red channel:
| (10.113) |