Function LoadImageToTexture2DArrayLayerAsync
-
LoadImageToTexture2DArrayLayerAsync(
texture: RawTexture2DArray,
url: string,
layer: number,
options?: IUploadImageToTexture2DArrayLayerOptions,
): Promise<void>Parameters
- texture: RawTexture2DArray
defines the 2D array texture to upload into
- url: string
defines the url of the image to load
- layer: number
defines the array layer to upload into
Optionaloptions: IUploadImageToTexture2DArrayLayerOptionsdefines optional upload settings (invertY, premultiplyAlpha)
Returns Promise<void>
a promise resolved once the layer has been uploaded
- texture: RawTexture2DArray
Fetches an image from a url, decodes it and uploads it into a single layer of a 2D array texture.