Skip to main content
Version: 9.0.2

gre.load_image

gre.load_image(
image_name,
[optional table of parameters]
)

This function will force the loading of an image into the Storyboard application. This can be used in order to avoid load time delays that may be incurred as resources are lazy loaded into the application.

This is a convenience function for calling the more generic gre.load_resource

This call can only be made from the main Lua action execution thread.

Parameters

ParameterTypeDescription
resource_name#stringThe name of the resource that is to be loaded
width#number[Optional] The width to cache the image at h The height at which to cache the image
background#boolean[Optional] Whether or not to load the image asynchronously. Asynchronous loading capabilities are determined by the hardware rendering capabilities of the system and may require serialization with the main rendering thread for a complete load to occur. On completion of a 'background' loaded resource, the following event is sent: gre.resource_loaded 1s0 resource.