-
Notifications
You must be signed in to change notification settings - Fork 49
Open
Labels
Description
Description
If we use RiveUI() in our Composables, and check out the preview in Android Studio, the preview cannot render, and crashes.
java.lang.ClassNotFoundException: android.opengl.EGL14
at java.lang.ClassLoader.loadClass at java.lang.ClassLoader.loadClass at app.rive.core.CommandQueue.<init> ...
(CommandQueue.kt:434)
Provide a Repro
Just add any RiveUI() in your Composable:
val riveFileResult by rememberRiveFile(RiveFileSource.RawRes(R.raw.your_rive_animation))
if (riveFileResult is Result.Success) {
val riveFile = (riveFileResult as Result.Success<RiveFile>).value
RiveUI(
file = riveFile
)
}Expected behavior
Preview should show the Rive animaton in its initial state. At least just show a blank view, and not crash the whole Composable preview.