The Texture class represents a 2-dimensional texture uploaded to a rendering context.

Defines a 2D texture for use during rendering.


Texture cannot be instantiated directly. Create instances by using Context3D createTexture() method.


uploadFromBitmapData(source, miplevel)

Uploads a texture from a BitmapData object.

source - BitmapData object.

miplevel - (default = 0) - the mip level to be loaded, level zero being the top-level full-resolution image.

uploadFromByteArray(data, byteArrayOffset, miplevel)

Uploads a texture from a ByteArray.

data - a byte array that is contains enough bytes in the textures internal format to fill the texture. rgba textures are read as bytes per texel component (1 or 4). float textures are read as floats per texel component (1 or 4). The ByteArray object must use the little endian format.

byteArrayOffset - the position in the byte array object at which to start reading the texture data. 

miplevel - (default = 0) - the mip level to be loaded, level zero is the top-level, full-resolution image.

uploadCompressedTextureFromByteArray(data, byteArrayOffset, async)

Not supported


Created with the Personal Edition of HelpNDoc: Free CHM Help documentation generator