Here’s an interactive demo that lets you visualize spherical harmonic approximations,
up to 5 bands. You can interactively slide the coefficients for the first three bands,
while the other two bands can be set using the manual text entry button.

Don’t know what spherical harmonics are? Wait for the next post for a primer.

There are several different visualization modes:

- The default view is a diffuse sphere lit by the spherical function as an environment map
- A specular sphere lit by the spherical function as an environment map (which is the same as rendering the spherical function as the intensity on a sphere, with axes reversed)
- Spherical function as the radius of a shape. This is the only mode that will let you see negative values, which are shown as red. Positive values are shown in green.
- Cubemap of the spherical function (to be implemented)