When processing cube maps (for example, generating a diffuse irradiance map, or spherical harmonic approximation), you need to be able to integrate the texel values over a sphere. One way of approximating this integral is to use a Monte Carlo estimator. This is a statistical technique that may...