Bitmap.onLoaded

Function/Meaning
Asynchronous loading completed
Type
Event of the Bitmap class
Syntax
onLoaded(meta, async, error, message)
Arguments
meta Tag information of the loaded image.
async Whether it was loaded asynchronously.
If the image data is in the cache, this event occurs during the execution of Bitmap.loadAsync.
error Whether an error occurred during image loading.
message Error message.
If an error occurs, the error message is passed.
Description
Occurs when asynchronous loading is completed.
The loaded image can be copied to a Layer using Layer.copyFromBitmapToMainImage.
Since the loading process is asynchronous, the Layer to which the image is passed may have already been invalidated by the time loading is complete.
When accessing other objects in this event, please check if they have been invalidated.
Alternatively, ensure that the target object is not invalidated until this event is completed.
Reference
Bitmap.loadAsync
Layer.copyFromBitmapToMainImage