beta
cables is under heavy development.
There might be one or another bug, please let us know about it!
Ops.Patch.LoadingStatus

LoadingStatus
op id:30f01b6d-b234-4ebe-a2c3-ebffd96a31e9
get the loading progress, for displaying a loading screen

summary (oneliner)

Useful to display a loading animation while your patch is loading assets (3D-models, audio-files, …).
On the community page a spinner-icon will be shown by default, in the editor and when you export your patch there won’t – this is because you probably want to display your own loading animation. This might change in the future.

writing async loading ops

when writing ops, that load data asynchronously, you should tell cables that something is still loading:

var loadingId=cgl.patch.loading.start('texture' , filename); // loading starts
// load stuff...
cgl.patch.loading.finished(loadingId);  // loading is finished

doc

issues

youtube id

collections

related ops

Inputs

exe (Function)

Executes the op


preRenderTimes (Number)

PreRender Ops (boolean Number)

Outputs

finished (Function)

Triggers when all assets have been loaded


status (Number)

Value between 0 and 1, becomes 1 when all assets have been loaded


all loaded (Number)

Becomes true when all assets have been loaded


preRenderStatus (Number)

numAssets (Number)

loading (Function)

Triggers while there are still assets left to load, use this for your loading animations


loading finished (Function)

Triggers once when loading is finished


Credits

Caught a mistake or want to contribute to the documentation?


Edit this documentcancel save

Examples using LoadingStatus

Public Patches using LoadingStatus