Class
Texture
View source Constructor
View source
Properties
changed : boolean
View sourcedata : (ArrayBuffer | undefined)[]
View sourcewidth : number
View sourceheight : number
View sourcedepth : number
View sourceformat : number
View sourcetype : number
View sourcestaticreadonly defaultSettings : Readonly<Required<TextureSettings>>
View sourceDefault texture settings.
Default: ...
Methods
apply ( settings: TextureSettings ) : void
View source Applies a new set of texture settings.
copy ( other: Texture ) : Texture
View source Copies the values from another texture into this one.
clone ( ) : Texture
View source Creates a new texture that is a copy of this one.
static default ( ) : Texture
View source Creates a default 1×1 white texture.
static getMipmapCount ( type: number , width: number , height: number , depth?: number ) : number
View source Returns the number of mip levels for the given base texture size.
static getMipLevelSize ( type: number , width: number , height: number , depth?: number , mipmapLevel?: number ) : object
View source Returns the dimensions for a specific mip level.
static generateMipmaps ( settings: TextureMipmapSettings ) : ArrayBuffer[]
View source Generates the full mip chain starting with the base level. Currently supported for uncompressed RGBA8 textures.