Mip mapping

from Wikipedia, the free encyclopedia

Mip mapping is an anti-aliasing technique for textures . It is used in modern 3D graphics chips to improve image quality, but also speed.

Problems with texture scaling

The problem with texture mapping objects is that you should be able to view them from near and far. Correlatively to the appearance of the object, the texture must also change its shape and size:

  • Magnification - the texture needs to be magnified a lot to cover the object when it is close to the viewer.
  • Minification - the texture has to be reduced significantly if the object is very far away from the viewer (in extreme cases the object is then only exactly 1 pixel in size)

If no countermeasures are taken, aliasing effects occur with these scalings , which are very annoying as artifacts , especially in the case of patterns with oblique or rounded lines, as distortions or flickering ( moiré effects ).

MIP map

Example of a MIP map. The edge length of the largest picture is 2 8 = 256 pixels.
This picture is intended to illustrate the efficient storage (in the sense of memory fragmentation) of pictures. Only 1 white byte is "wasted". As indicated in color in the picture, the RGB colors of an image can be divided according to this scheme, and congruent complete images (3 pieces each) can be saved together

MIP is an abbreviation for multum in parvo , which means much in a small space . A MIP map (also called an image pyramid ) is a sequence of raster images of the same motif, but with decreasing resolution. The edge length of each picture is exactly half the size of the previous picture. The smallest image has a size of 1 × 1 or 2 × 2 pixels , depending on the implementation . From this it follows that all images must be square and have a power of two as the edge length. These levels are also referred to as Level of Detail (LOD) .

Memory requirements

MIP maps require a maximum of 1/3 more memory than the largest image alone:

The exact number of bytes of memory required by the images is calculated as follows:

Here, the edge length of the picture (square adopted) and the bytes per channel (1: gray-scale image with 256 gray levels; 3: RGB image with 8 bits per color channel)


MIP maps can be calculated simply by calculating the mean value of the four corresponding pixels of the original image for each pixel of the reduced image. This has to be done recursively for all further stages. This method is often used implicitly by the graphics hardware when loading textures in order to save memory bandwidth. Fourier synthesis offers a more complex but better image quality method for MIP map calculation .

MIP mapping as a texture filter

When minifying textures in texture mapping , that LOD is selected in which a texel is large enough to completely cover a pixel.

This ensures that every texel of the original texture has an influence on the compressed texture and that no scanning-related aliasing effects occur. The jumps between the LODs in particular lead to discontinuities that are clearly visible as lines between the MIP bands . Each of these bands has a degree of severity that is very different from the neighboring bands. In addition, any compression that does not correspond to a power of two, and also with anisotropic distortions, always leads to an excessive loss of sharpness.

See also

Web links