generateMipmaps(for:)
Encodes a command that generates mipmaps for a texture from the base mipmap level up to the highest mipmap level.
Declaration
func generateMipmaps(for texture: any MTLTexture)Parameters
- texture:
A texture instance the command generates mipmaps for that has:
A Mipmaplevelcount property that’s greater than
1A Pixelformat that’s color-renderable and color-filterable
Mentioned in
Discussion
The command generates with scaled images for all levels up to the highest mipmap level.