Phaser API Documentation

  Version: 
mipmapFilter: GLenum

Description:

The mipmap magFilter to be used when creating textures.

You can specify this as a string in the game config, i.e.:

render: { mipmapFilter: 'NEAREST_MIPMAP_LINEAR' }

The 6 options for WebGL1 are, in order from least to most computationally expensive:

NEAREST (for pixel art) LINEAR (the default) NEAREST_MIPMAP_NEAREST LINEAR_MIPMAP_NEAREST NEAREST_MIPMAP_LINEAR LINEAR_MIPMAP_LINEAR

Mipmaps only work with textures that are fully power-of-two in size.

For more details see https://webglfundamentals.org/webgl/lessons/webgl-3d-textures.html

As of v3.60 no mipmaps will be generated unless a string is given in the game config. This saves on VRAM use when it may not be required. To obtain the previous result set the property to LINEAR in the config.

Type:
GLenum
Since: 3.21.0