Is it possible to use animate vector drawables in ...
# compose-desktop
j
Is it possible to use animate vector drawables in desktop (vectorXmlResource)?
i
Unfortunately, no.
animatedVectorResource
is available only for android. The possible alternative is to use Lottie animations. And load them with Skija. There is also a snippet that shows how to load Gif animations in Compose. Lottie animations would have a similar implementation (didn't tried, but maybe this snippet can load Lottie animations too).
o
we hopefully will have implementation for such generic composable soon
j
@Igor Demin I asked in the Lottie GitHub repo and Lottie is not supported in Desktop Compose. Should be great that Skija approach could be integrated some day. I will try it manually. @olonho yeah, I searched in Gerrit to see if it was multiplatform, jvm or Android, I checked the samples too and there is an expect/actual approach for not animated drawables, sound great that a common composable is planned, hope for both, animated and not animated drawables.
i
Lottie GitHub repo and Lottie is not supported in Desktop Compose
Officially by Lottie team there is no support. But there is a support by skia/skija
common composable is planned, hope for both, animated and not animated drawables.
Nikolay talks about not animated drawable's, but about generic support of skia codecs. Skia codecs don't support android vector drawables.
But we can investigate this in the future, can we support animated android drawables
j
Thank you for your replies 🙂