ImageAsset

class ImageAsset(handle: ImageHandle, worker: RiveWorker) : Asset<ImageHandle>

An image asset, representing a renderable bitmap, managed by a RiveWorker.

Parameters

handle

The handle to the image on the command server.

worker

The Rive worker that owns the image.

Constructors

Link copied to clipboard
constructor(handle: ImageHandle, worker: RiveWorker)

Types

Link copied to clipboard
object Companion : AssetOps<ImageHandle, ImageAsset>

Properties

Link copied to clipboard

Functions

Link copied to clipboard
open override fun close()
Link copied to clipboard
fun register(key: String)

Register the asset with the given key. When Rive fulfills a referenced asset, it will look for an asset registered under that key. The key comes from the zip file created when exporting a Rive file.

Link copied to clipboard
fun unregister(key: String)

Unregister the asset with the given key.