fromEncoded

fun fromEncoded(encodedBytes: ByteArray, rendererType: RendererType = Rive.defaultRendererType): RiveRenderImage

Creates a RiveRenderImage by decoding the encodedBytes.

The caller is in charge of the ownership of this NativeObject. It must be freed calling release.

Return

The constructed RiveRenderImage.

Parameters

encodedBytes

Encoded bytes for the image.

rendererType

The renderer for this image. This must match the renderer for the RiveAnimationView using this.

Throws

if the bytes cannot be decoded.

if the decoded bitmap is not premultiplied.