Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

I'm working on some code here, and here is what I have done. It is based on the work by Ng et al. An example of what this looks like is here.

Background: Here, a "lighting cubemap" is a bunch of color values that sit on the faces of a cube.

an example of a lighting cubemap

The above lighting cubemap can be considered as a light source, where each individual pixel represents a quantity of light.

Now, say we find the visibility function at each vertex. A visibility function is just a description of what directions a vertex receives light from. Where there is geometry, set the pixel to 0 (total blockage of ambient light), and where there is no geometry, set the pixel to 1 (totally clear ambient light).

visibility from a vertex in a scene

So clearly, if you just multiply and sum (lighting cubemap function • visibility function) you will get the total light sent to that point by the lighting cubemap.

Now here is the strange part:

The massive amount of visibility maps needed for a large scene makes memory consumption enormous and the dot product extremely computationally expensive. So, take the Haar transform of the visibility maps, with the Haar transform of the lighting cube map. Drop all but 1% of the coefficients in both of these.

The result of dotting the filtered, Haar transform of the visibility function and the light function yields approximately the same result!! You don't have to "unwavelet" transform as it were-- you just multiply and add, and whammo, you get the correct color at each vertex in the scene.

Why is that?

share|improve this question
    
A hint is that you can model reflection as convolution, so conversion to the wavelet domain means convolution becomes multiplication. –  bobobobo May 3 '12 at 19:01
    
I believe joriki's answer below is correct. Consider the lighting and visibility cubemaps as vectors $\mathbf l$ and $\mathbf v$, and the Haar wavelet transform as a matrix $\mathbf W$. The dot product of the Haar transforms is $(\mathbf W\mathbf l)^T(\mathbf W\mathbf v)$, which is equal to the dot product you want, $\mathbf l^T\mathbf v$, because the Haar transform is orthogonal, i.e. $\mathbf W^T\mathbf W = \mathbf I$. –  Rahul May 26 '12 at 1:22
add comment

1 Answer 1

Isn't this just the unitarity of the Haar transform? (See e.g. here.)

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.