Lecture 5: Texture Mapping (66)

One source of confusion that I had reading these slides involved the use of u and v to refer to the texture coordinates and their derivatives. Usually u and v are between 0 and 1, and we multiply them by the width and height of our texture to get the texel coordinates. Here in the slides, u and v are being used as the texel coordinates themselves, and we want to find the number of texels per pixel in order to see how quickly a texture is changing with respect to screen space.


Is D = log_2(L) the optimal level based on Nyquist sampling, or is this just a heuristic? I feel like the fact that we use log base2 means that each level should be a 2x2 blur of the previous level, but not sure if that's correct.


@dtseng I'm not sure if "blur" is the best word, since "blur" is a filtering operation on our image. If mipmaps were just a filtering operation on our image, there wouldn't be any additional information in the smaller levels. "Downsampled" is a better word, since it implies "sampling at a lower frequency." This sort of gets at your question - is this a heuristic or something fundamental? From my point of view, mipmaps are a heuristic, trying to alleviate aliasing derived from sampling at a constant frequency (check out Moire patterns).


@dtseng There is indeed a reason behind the log_2(L); it has to do with the way that mipmap level resolution decreases as we get to higher levels. The Dth level mipmap has height of (original_height)/(2^D), similarly for width. When we calculate L, we basically get a measure of density of texels per pixel. So L = (#texels)/(#pixels) is the density of the 0th level, and the Dth level has density L/2^D. We want this to be close to 1 to mitigate aliasing; so we want to find the level D such that L/2^D = 1. This gives D = log_2(L).


I am a little confused on how each point in the original screen space is mapped onto the texture space if the texture space is how we determine what is mapped onto the screen space. I understand how for some images that are being constructed through a machine, the texture being mapped onto the image is not the original, but is texture mapping even used for images where you're mapping the image's original texture to the image. Furthermore, if that's the case, what is the point of telling the distance between each point in the texture space to determine your level of mipmap. In texture space, are points not mapped uniformly?

You must be enrolled in the course to comment