Difference between revisions of "Texture:generateMipmaps"

(Created page)
 
m
 
Line 4: Line 4:
  
 
The Texture must be [[love.graphics.newTexture|created]] with mipmaps set to a [[MipmapMode]] other than "none" for this function to work. It should only be called while the Texture is not the active render target.
 
The Texture must be [[love.graphics.newTexture|created]] with mipmaps set to a [[MipmapMode]] other than "none" for this function to work. It should only be called while the Texture is not the active render target.
 
  
 
If the mipmap mode is set to "auto", this function is automatically called inside [[love.graphics.setCanvas]] when switching the active canvas from this Texture to another Texture or to the main screen.
 
If the mipmap mode is set to "auto", this function is automatically called inside [[love.graphics.setCanvas]] when switching the active canvas from this Texture to another Texture or to the main screen.

Latest revision as of 01:48, 14 June 2024

Available since LÖVE 12.0
It has been moved from Canvas:generateMipmaps.

Generates mipmaps for the Texture, based on the contents of the highest-resolution mipmap level.


The Texture must be created with mipmaps set to a MipmapMode other than "none" for this function to work. It should only be called while the Texture is not the active render target.

If the mipmap mode is set to "auto", this function is automatically called inside love.graphics.setCanvas when switching the active canvas from this Texture to another Texture or to the main screen.

Function

Synopsis

Texture:generateMipmaps( )

Arguments

None.

Returns

Nothing.

See Also

Other Languages