Texture

A Texture is an image that can be applied to Materials. The supported file formats are .png, .jpg, .hdr, .dds, .ktx, and .astc. DDS and ASTC are compressed formats, which are recommended because they're smaller and faster.

Constructor

lovr.graphics.newTextureCreate a new Texture.

Methods

Texture:getHeightGet the height of the Texture.
Texture:getDepthGet the depth of the Texture.
Texture:getWidthGet the width of the Texture.
Texture:getFilterGet the FilterMode for the Texture.
Texture:setFilterSet the FilterMode for the Texture.
Texture:getDimensionsGet the dimensions of the Texture.
Texture:getMipmapCountGet the number of mipmap levels of the Texture.
Texture:getFormatGet the format of the Texture.
Texture:getWrapGet the WrapMode for the Texture.
Texture:setWrapSet the WrapMode for the Texture.
Texture:replacePixelsReplace pixels in the Texture using a TextureData object.
Texture:getTypeGet the type of the Texture.

See also