Getting Started
...
Glossary
H-M Terms

Mipmap

4min

A mipmap is a collection of images that represent a texture at different resolutions. Mipmaps are used to improve the quality of textures when they are rendered at different distances from the camera.

When a texture is rendered at a distance, the pixels on the texture are too small to be seen clearly. This can cause aliasing, which is a jagged or pixelated appearance. Mipmaps solve this problem by providing a lower-resolution version of the texture that is rendered when the texture is far away.

Mipmaps are created by downsampling the original texture. Downsampling is the process of reducing the resolution of an image by averaging the values of adjacent pixels. This produces a lower-resolution image that contains less detail.

Mipmaps are used in conjunction with a technique called mipmapping to improve the quality of textures when they are rendered at different distances from the camera. Mipmap filtering is a process by which the graphics card selects the most appropriate mipmap to use for a given pixel.

There are two types of mipmap filtering:

  • Nearest neighbor: Nearest neighbor mipmap filtering selects the mipmap that is closest to the current pixel. This is the simplest form of mipmap filtering, but it can produce aliasing.
  • Linear: Linear mipmap filtering selects the two mipmaps that are closest to the current pixel and averages their values. This produces smoother results than nearest neighbor mipmap filtering, but it can also produce aliasing.
  • Trilinear: Trilinear mipmap filtering selects the four mipmaps that are closest to the current pixel and averages their values. This produces the smoothest results of all three mipmap filtering methods.

Here are some of the benefits of using mipmaps in computer graphics:

  • Improved image quality: Mipmaps can improve the quality of textures when they are rendered at different distances from the camera.
  • Reduced aliasing: Mipmaps can reduce aliasing, which is a jagged or pixelated appearance that can occur when textures are rendered at a distance.
  • Efficiency: Mipmaps can be efficiently rendered by the graphics card.

Here are some of the drawbacks of using mipmaps in computer graphics:

  • Increased file size: Mipmaps require additional storage space, as they store multiple versions of the same texture at different resolutions.
  • Performance impact: Mipmap filtering can have a performance impact on the game, as the graphics card needs to select the most appropriate mipmap for each pixel.
  • Limited detail: Mipmaps can only reduce aliasing up to a certain point. For textures with a lot of detail, mipmaps may not be able to provide a smooth appearance at all distances.

Overall, mipmaps are a powerful tool that can be used to improve the quality of textures in computer graphics. However, it is important to be aware of the potential drawbacks of using mipmaps, such as increased file size and performance impact.

Here are some additional tips for using mipmaps in computer graphics:

  • Use a consistent naming convention: Using a consistent naming convention for mipmaps will make it easier to keep track of them.
  • Use high-quality textures: Using high-quality textures will produce better results with mipmaps.
  • Use the right mipmap format: The mipmap format you use will affect the performance of your game. Choose a format that is appropriate for your needs.
  • Use a mipmap streaming system: A mipmap streaming system can be used to load mipmaps only when they are needed. This can help to improve performance by reducing the amount of memory that is used.

Feedback

Please be sure to submit issues or feature requests through the embedded feedback form. In the event it is a major issue please contact us directly through Discord.

Updated 03 Apr 2024
Doc contributor
Did this page help you?