Package-level declarations
Types
An instantiated artboard from a RiveFile.
Base class for assets managed by a RiveWorker.
An audio asset, representing a playable sound, managed by a RiveWorker.
Marks APIs that use experimental hardware bitmap rendering.
A font asset, representing a renderable typeface, managed by a RiveWorker.
Function type for getting a Bitmap.
GPU-backed offscreen render target for realtime canvas presentation (API 29+).
An image asset, representing a renderable bitmap, managed by a RiveWorker.
The preferred GPU rendering backend to use.
Deprecated software-only legacy render buffer.
An entry point for Rive to render to a hardware accelerated Canvas using hardware bitmaps.
Exceptions related to drawing to a buffer.
A Rive file which contains one or more artboards, state machines, and view model instances.
Exceptions related to Rive file handling.
The source for a RiveFile.
Controls how often Rive advances and draws an active animation.
Exceptions related to Rive failing to initialize properly.
Controls how a Rive composable participates in Compose pointer input dispatch.
Exceptions related to Rive rendering.
Exceptions related to Rive failing to shut down properly.
Note: This class is more experimental than others. It is not recommended for use at this time.
CPU-backed offscreen render target for snapshot-style rendering.
An instantiated state machine from an Artboard.
A view model instance for data binding which has properties that can be set and observed.
The second half of a source for a ViewModelInstance. This represents the specific instance of the view model. This can be either:
One half of a source for a ViewModelInstance. This represents the view model that originates the instance. This can be either Named to refer to a specific view model, or DefaultForArtboard, which will use the default view model for the given Artboard. This is usually the one the designer has intended to be used with the artboard.
Functions
Decode audio from the given bytes on the provided RiveWorker. The decoded audio can only be used on the same RiveWorker it was created on.
Decode a font from the given bytes on the provided RiveWorker. The decoded font can only be used on the same RiveWorker it was created on.
Decode an image from the given bytes on the provided RiveWorker. The decoded image can only be used on the same RiveWorker it was created on.
Decode and register audio from the given bytes on the provided riveWorker. The decoded audio can only be used on the same RiveWorker it was created on.
Decode and register a font from the given bytes on the provided RiveWorker. The decoded font can only be used on the same RiveWorker it was created on.
Decode and register an image from the given bytes on the provided RiveWorker. The decoded image can only be used on the same RiveWorker it was created on.
A RiveWorker is the worker that runs Rive in a thread. It holds all of the state, including assets (images, audio, and fonts), RiveFiles, artboards, state machines, and view model instances.
A nullable variant of rememberRiveWorker that returns null if the Rive worker cannot be created.
Creates a StateMachine from the given Artboard.
Creates a ViewModelInstance from the given file and source.
The main composable for rendering a Rive file's artboard and state machine.