Class: ImageRequest
ImageRequest specifies all information required to load and prepare an image. This includes the source of the image, if the image should be fetched from a source (e.g. from a URL), and options for how the texture the image is rendered to should be generated.
Table of contents
Constructors
Properties
Constructors
constructor
+ new ImageRequest(name
: string, source
: string, textureOptions?
: ITextureOptions): ImageRequest
Parameters:
Name | Type |
---|---|
name |
string |
source |
string |
textureOptions |
ITextureOptions |
Returns: ImageRequest
Properties
generateMipmaps
• generateMipmaps: boolean
Texture option for generating mipmaps or not. True = generate mipmaps, false = don't generate mipmaps.
magFilter
• magFilter: TextureFiltering
Texture magnification filter.
minFilter
• minFilter: TextureFiltering
Texture minification filter.
mirror
• mirror: boolean
Option for mirroring the texture when loading it (vertical and horizontal flip). True = mirror, false = don't mirror.
name
• name: string
Name of the image asset, how it is referred to throughout the system, should be unique.
source
• source: string
Source of the image, where the image exists (URL, filepath etc.).
xWrap
• xWrap: TextureWrapping
Texture wrapping along x axis.
yWrap
• yWrap: TextureWrapping
Texture wrapping along y axis.
MESSAGE_REQUEST_LOAD
▪ Readonly
Static
MESSAGE_REQUEST_LOAD: request_image_load= "request_image_load"
Message to request an image asset to be loaded.