Texture filtering

Texture filtering is a method that is used to improve the texture quality in a scene. Without texture filtering, artifacts like aliasing generally look worse.

Texture filtering makes textures look better and less blocky. Usually, this makes the game look better.

However, texture filtering can also degrade performance. This is because better quality often means that more processing is required. Texture filtering can account for up to half of the GPU energy consumption. Choosing simpler texture filters can reduce the energy demands of an application.

There are several options available in Unity for texture filtering:

  • Nearest, or Point filtering

    When seen up close, nearest filtering makes the texture looks blocky. This is the simplest and cheapest texture filtering.

  • Bilinear filtering
    The texture is blurrier up close with bilinear filtering. The four nearest texels are sampled and then averaged to color the main pixel. Unlike nearest filtering, bilinear filtering results in less blocky pixels as the pixels have a smooth gradient, as shown in the following image:

  • Trilinear filtering
    Trilinear filtering is like bilinear filtering, but with added blend between mipmap levels. Trilinear filtering removes noticeable changes between mipmaps by smoothing the transition between mipmaps, as shown in the following image:


    Note: Bilinear and trilinear filtering requires sampling more pixels and, therefore, more computation.
  • Anisotropic filtering
    Anisotropic filtering makes textures look better when viewed at an angle. It is good for ground level textures, for example, as shown in the following image:

Texture filtering best practices

Arm recommends that you try the following texture filtering tips:

  • Use bilinear filtering for a balance between performance and visual quality.
  • Use trilinear filtering selectively. This is because trilinear filtering requires more memory bandwidth than bilinear filtering.
  • Use bilinear and 2x anisotropic filtering instead of trilinear and 1x anisotropic. This is because this combination of filtering techniques can both look and perform better.
  • Keep the anisotropic level low. Only use a level higher than two for critical game assets.
Previous Next