Moai SDK  2.0
MOAITexture Class Reference
+ Inheritance diagram for MOAITexture:

Function List

load
 
- Function List inherited from MOAIGfxResource
getAge
 
purge
 
setReloader
 
- Function List inherited from MOAIInstanceEventSource
getListener
 
setListener
 

Additional Inherited Members

- Function List inherited from MOAITextureBase
getSize
 
release
 
setDebugName
 
setFilter
 
setWrap
 

Function Documentation

load

Loads a texture from a data buffer or a file. Optionally pass in an image transform (not applicable to PVR textures).


function load ( MOAITexture self, string filename [, number transform, string debugname ] )

Parameters
MOAITextureself
stringfilename
numbertransform Optional. Any bitwise combination of MOAIImage.QUANTIZE, MOAIImage.TRUECOLOR, MOAIImage.PREMULTIPLY_ALPHA
stringdebugname Optional. Name used when reporting texture debug information
Returns
nil
Note

function load ( MOAITexture self, MOAIImage image [, string debugname, boolean autoClear ] )

Parameters
MOAITextureself
MOAIImageimage
stringdebugname Optional. Name used when reporting texture debug information
booleanautoClear Optional. Default value is 'false.' Only used if there is a reloader in play.
Returns
nil
Note

function load ( MOAITexture self, MOAIDataBuffer buffer [, number transform, string debugname ] )

Parameters
MOAITextureself
MOAIDataBufferbuffer
numbertransform Optional. Any bitwise combination of MOAIImage.QUANTIZE, MOAIImage.TRUECOLOR, MOAIImage.PREMULTIPLY_ALPHA
stringdebugname Optional. Name used when reporting texture debug information
Returns
nil
Note

function load ( MOAITexture self, MOAIStream buffer [, number transform, string debugname ] )

Parameters
MOAITextureself
MOAIStreambuffer
numbertransform Optional. Any bitwise combination of MOAIImage.QUANTIZE, MOAIImage.TRUECOLOR, MOAIImage.PREMULTIPLY_ALPHA
stringdebugname Optional. Name used when reporting texture debug information
Returns
nil
Note